Configuration
Specifying the Configuration File
The configuration file is specified using the -f parameter when running the panel application.
shell
dpanel server:start -f /etc/dpanel/config.yamlModify Configuration
Directly Modify config.yaml
Simply modify the corresponding configuration in the config.yaml file.
Override Configuration via Startup Command
shell
dpanel server:start -f /etc/dpanel/config.yaml -e STORAGE_LOCAL_PATH=/home/dpanelOverride Configuration via Environment Variables
shell
export STORAGE_LOCAL_PATH=/home/dpanel && dpanel server:start -f /etc/dpanel/config.yamlParameter Description
| Name | Description | Default Value | Version |
|---|---|---|---|
| APP_NAME | Program Name | dpanel | - |
| APP_VERSION | Program version | - | - |
| APP_SERVER_PORT | Program execution port | 8086 | - |
| STORAGE_LOCAL_PATH | Data directory generated by the program | ./ | - |
| DB_MODE | Database read/write mode ro|rw|rwc | rwc | - |
| DP_SYSTEM_BASEURL | Panel access baseurl | - | > 1.9.1 |
| DP_SYSTEM_DOCKER_INIT_TIMEOUT | Timeout for initializing or switching Docker servers | 10 seconds | > 1.9.1 |
Configuration file
yaml
app:
name: ${APP_NAME-dpanel}
version: ${APP_VERSION}
env: ${APP_ENV-lite}
family: ${APP_FAMILY-ce}
server: ${APP_SERVER-http}
cors:
- http://localhost:8000
server:
http:
host: 0.0.0.0
port: ${APP_SERVER_PORT-8086}
prof:
host: 0.0.0.0
port: 8087
log:
default:
driver: stack
channels:
- file
- console
file:
driver: file
path: ${STORAGE_LOCAL_PATH}/logs/dpanel.log
level: warn
console:
driver: console
level: debug
database:
default:
driver: sqlite
user_name: ${DB_USERNAME-root}
password: ${DB_PASSWORD-123456}
db_name: ${STORAGE_LOCAL_PATH}/dpanel.db
charset: utf8mb4
prefix: ims_
options:
mode: ${DB_MODE}
system:
baseurl: ${DP_SYSTEM_BASEURL}
storage:
local:
path: ${STORAGE_LOCAL_PATH}
permission:
default_username: __public__
docker:
timeout: ${DP_SYSTEM_DOCKER_TIMEOUT-10}