-
Notifications
You must be signed in to change notification settings - Fork 74
Expand file tree
/
Copy pathconfig_example.yml
More file actions
64 lines (52 loc) · 1.98 KB
/
config_example.yml
File metadata and controls
64 lines (52 loc) · 1.98 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
# SECURITY WARNING: keep the secret key used in production secret!
# 加密密钥 生产服必须保证唯一性,你必须保证这个值的安全,否则攻击者可以用它来生成自己的签名值
# $ cat /dev/urandom | tr -dc A-Za-z0-9 | head -c 49;echo
SECRET_KEY:
# Development env open this, when error occur display the full process track, Production disable it
# DEBUG 模式 开启DEBUG后遇到错误时可以看到更多日志,正式服要禁用,开发阶段,需要取消该注释,否则会导致前端ws连接失败
# DEBUG: true
# DEBUG, INFO, WARNING, ERROR, CRITICAL can set. See https://docs.djangoproject.com/zh-hans/5.0/topics/logging/
# 日志级别
# LOG_LEVEL: DEBUG
# 用于DEBUG模式下,输出sql日志
# DEBUG_DEV: true
# Database setting, Support sqlite3, mysql, postgres ....
# 数据库设置
# ### 更多数据库配置,参考官方文档:https://docs.djangoproject.com/zh-hans/5.0/ref/databases/
# 创建竖数据库sql
# create database xadmin default character set utf8mb4 COLLATE utf8mb4_bin;
# grant all on xadmin.* to server@'127.0.0.1' identified by 'KGzKjZpWBp4R4RSa';
# SQLite setting:
# 使用单文件sqlite数据库
# DB_ENGINE: sqlite3
# DB_DATABASE:
# MySQL or postgres setting like:
# DB_ENGINE can set mysql, oracle, postgresql, sqlite3
# 使用 Mariadb 作为数据库
#DB_ENGINE: mysql
#DB_HOST: mysql
#DB_PORT: 3306
# 使用 postgresql 作为数据库[默认数据库]
DB_ENGINE: postgresql
DB_HOST: postgresql
DB_PORT: 5432
DB_USER: server
DB_DATABASE: xadmin
#DB_PASSWORD: KGzKjZpWBp4R4RSa
# Use Redis as broker for celery and web socket
# Redis配置
REDIS_HOST: redis
REDIS_PORT: 6379
#REDIS_PASSWORD: nineven
#DEFAULT_CACHE_ID: 1
#CHANNEL_LAYERS_CACHE_ID: 2
#CELERY_BROKER_CACHE_ID: 3
# When Django start it will bind this host and port
# ./manage.py runserver 127.0.0.1:8896
# 运行时绑定端口
HTTP_BIND_HOST: 0.0.0.0
HTTP_LISTEN_PORT: 8896
GUNICORN_MAX_WORKER: 4
CELERY_WORKER_COUNT: 4
# 需要将创建的应用写到里面
XADMIN_APPS: