Skip to content

Configuration Parameters

Specify Configuration File

Specify the configuration file using the -f parameter when running the panel program.

shell
dpanel server:start -f /etc/dpanel/config.yaml

Modify Configuration

Directly Modify config.yaml

Directly modify the corresponding configuration in the config.yaml file.

Override Configuration Through Startup Command

shell
dpanel server:start -f /etc/dpanel/config.yaml -e STORAGE_LOCAL_PATH=/home/dpanel

Override Configuration Through Environment Variables

shell
export STORAGE_LOCAL_PATH=/home/dpanel && dpanel server:start -f /etc/dpanel/config.yaml

Parameter Description

NameDescriptionDefault ValueVersion
APP_NAMEProgram namedpanel-
APP_VERSIONProgram version--
APP_SERVER_PORTProgram running binding port8086-
STORAGE_LOCAL_PATHData directory generated by program running./-
DP_DB_MODEDatabase read/write mode ro|rw|rwcrwc-
DP_ACME_COMMAND_NAMEOverride acme command path/root/.acme/acme.sh-
DP_ACME_CONFIG_HOMEOverride acme configuration directory/root/.acme/-
DP_SYSTEM_BASEURLPanel access baseurl-> 1.9.1
DP_LOG_CONSOLE_LEVELLog level info|debuginfo> 1.10.0
DP_RUN_IN_CONTAINERWhether to run in container1> 1.10.0
DP_DB_JOURNALsqlite mode WAL | DELETEDELETE> 1.10.0

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: ${DP_DB_MODE}
system:
  baseurl: ${DP_SYSTEM_BASEURL}
  storage:
    local:
      path: ${STORAGE_LOCAL_PATH}
  permission:
    default_username: __public__
  docker:
    timeout: ${DP_SYSTEM_DOCKER_TIMEOUT-10}