Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
J
jumpserver
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ops
jumpserver
Commits
67f52888
Commit
67f52888
authored
Nov 26, 2018
by
ibuler
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Update] 浏览器会话火气时间
parent
c4d6f325
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
0 deletions
+7
-0
conf.py
apps/jumpserver/conf.py
+1
-0
settings.py
apps/jumpserver/settings.py
+1
-0
config_example.py
config_example.py
+5
-0
No files found.
apps/jumpserver/conf.py
View file @
67f52888
...
...
@@ -310,6 +310,7 @@ defaults = {
'SESSION_COOKIE_DOMAIN'
:
None
,
'CSRF_COOKIE_DOMAIN'
:
None
,
'SESSION_COOKIE_AGE'
:
3600
*
24
,
'SESSION_EXPIRE_AT_BROWSER_CLOSE'
:
False
,
'AUTH_OPENID'
:
False
,
'EMAIL_SUFFIX'
:
'jumpserver.org'
}
...
...
apps/jumpserver/settings.py
View file @
67f52888
...
...
@@ -146,6 +146,7 @@ LOGIN_URL = reverse_lazy('users:login')
SESSION_COOKIE_DOMAIN
=
CONFIG
.
SESSION_COOKIE_DOMAIN
CSRF_COOKIE_DOMAIN
=
CONFIG
.
CSRF_COOKIE_DOMAIN
SESSION_COOKIE_AGE
=
CONFIG
.
SESSION_COOKIE_AGE
SESSION_EXPIRE_AT_BROWSER_CLOSE
=
CONFIG
.
SESSION_EXPIRE_AT_BROWSER_CLOSE
MESSAGE_STORAGE
=
'django.contrib.messages.storage.cookie.CookieStorage'
# Database
...
...
config_example.py
View file @
67f52888
...
...
@@ -44,6 +44,11 @@ class Config:
# LOG_LEVEL = 'DEBUG'
# LOG_DIR = os.path.join(BASE_DIR, 'logs')
# Session expiration setting, Default 24 hour, Also set expired on on browser close
# 浏览器Session过期时间,默认24小时, 也可以设置浏览器关闭则过期
# SESSION_COOKIE_AGE = 3600 * 24
# SESSION_EXPIRE_AT_BROWSER_CLOSE = False
# Database setting, Support sqlite3, mysql, postgres ....
# 数据库设置
# See https://docs.djangoproject.com/en/1.10/ref/settings/#databases
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment