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
96dd2f5c
Commit
96dd2f5c
authored
Aug 20, 2016
by
ibuler
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add config
parent
e355c7b8
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
55 additions
and
0 deletions
+55
-0
config-example.py
config-example.py
+55
-0
No files found.
config-example.py
View file @
96dd2f5c
"""
jumpserver.config
~~~~~~~~~~~~~~~~~
Jumpserver project setting file
:copyright: (c) 2014-2016 by Jumpserver Team.
:license: GPL v2, see LICENSE for more details.
"""
import
os
BASE_DIR
=
os
.
path
.
dirname
(
os
.
path
.
abspath
(
__file__
))
class
Config
:
SECRET_KEY
=
os
.
environ
.
get
(
'SECRET_KEY'
)
or
'2vym+ky!997d5kkcc64mnz06y1mmui3lut#(^wd=
%
s_qj$1
%
x'
DISPLAY_PER_PAGE
=
20
ALLOWED_HOSTS
=
[
'*'
]
DEBUG
=
False
DATABASE_ENGINE
=
'sqlite3'
HTTP_LISTEN_HOST
=
'127.0.0.1'
HTTP_LISTEN_PORT
=
8000
def
__init__
(
self
):
pass
def
__getattr__
(
self
,
item
):
return
None
class
DevelopmentConfig
(
Config
):
DEBUG
=
True
DISPLAY_PER_PAGE
=
20
DB_ENGINE
=
'sqlite'
DB_NAME
=
os
.
path
.
join
(
BASE_DIR
,
'db.sqlite3'
)
class
ProductionConfig
(
Config
):
DEBUG
=
False
DB_ENGINE
=
'mysql'
DB_HOST
=
'127.0.0.1'
DB_PORT
=
3306
DB_USER
=
'root'
DB_PASSWORD
=
''
DB_NAME
=
'jumpserver'
config
=
{
'development'
:
DevelopmentConfig
,
'production'
:
ProductionConfig
,
'default'
:
DevelopmentConfig
,
}
env
=
'development'
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