English
Panel Control Commands DPanel Version >= 1.2.2
Call Method
Please modify the example code according to the current environment when executing commands.
Container Installation
TIP
Replace dpanel in the command below with the name of your panel container.
Run on the Host
- Log in to the server via SSH.
- Use
docker execto run a control command in the DPanel container.
docker exec dpanel system:infoRun in the Console / Container
If you can log in to DPanel, run the command in Console > Local Shell.
dpanel system:infoBinary Invocation
TIP
Older versions do not include the service.sh script. You can regenerate it with the installer. On fnOS, update DPanel to the latest version.
/root/dpanel-5/service.sh system:infofnOS
/vol1/@appcenter/dpanel/server/service.sh system:infoView System Information
system:info displays the current DPanel runtime environment, access address, security entrance, and administrator account (with the password masked).
dpanel system:infoReset Admin User
Quick Reset
Use a random password to reset user
dpanel user:resetReset Password
dpanel user:reset --password 123456Reset Username
When resetting username, must specify password
dpanel user:reset user:reset --password 123456 --username rootSet the Security Entrance
WARNING
Set --entrance to none to disable access through the security entrance.
--entrancespecifies the security entrance. Leave it empty to generate a random entrance.
dpanel system:reset --entranceSystem Cleanup and Reset
--cacheclears rebuildable caches, notices, Docker events, and temporary files.--online-userinvalidates all online users.
dpanel system:reset --cache --online-userUpdate App Store Data
- --name Specify app store name
dpanel store:sync --name testReturn
{"total":151}Detect Container Updates
- --name Specify the container name to detect
- --docker-env Specify docker env environment name, default: local
Each command execution bypasses the existing check cache and queries the remote registry directly.
dpanel container:upgrade --name containerName --docker-env localReturn
upgradeset totruemeans an update is available. When a check fails,errorcontains the reason.
{"upgrade":false,"digest":"sha256:8f4ac2974ff707bace98ab14923fdf220f44a9803045b655f1d8d3e098f97e55","digestLocal":["registry.cn-hangzhou.aliyuncs.com/dpanel/dpanel@sha256:8f4ac2974ff707bace98ab14923fdf220f44a9803045b655f1d8d3e098f97e55"],"error":""}Upgrade Container
- --name Specify container name
- --docker-env Specify docker env environment name
- --enable-bak Whether to backup old container, default: true
- --disable-bak Do not backup old container, equivalent to --enable-bak=false
- --image-tag Specify new image name, this image must be fully compatible with the container's image
dpanel container:upgrade --upgrade --disable-bak --name containerNameReturn
Before upgrading, DPanel checks the container image for updates using the same logic as Detect Container Updates.
{"containerId": "14fc0a4d5e3e31f98f9179512085299b5c502ddf57d584ce39a7cadab6e3f643"}Generate Container Snapshot
- --name Specify the container name to detect
- --docker-env Specify docker env environment name
- --enable-image Whether to backup container image
- --backup-image Backup image type image or container (docker commit)
- --enable-volume Whether to backup mount directories
- --backup-volume Specify the mount directory to backup
dpanel container:backup --name ContainerName --enable-image --enable-volumeReturn
{"path":"/dpanel/backup/dpanel-doc/dpanel-dpanel-doc-20250424175215.snapshot"}Deploy or Upgrade Compose Task
- --name Compose task name, already deployed or discoverable task name in the panel
- --docker-env Specify docker env environment name
- --environment Environment variables required in yaml, can configure multiple, --environment test=1
- --pull-image Specify image pull method dpanel command
dpanel compose:deploy --name TaskName --environment name=test --environment age=10 --pull-image dpanelReturn
{"name":"test123"}Send Notification DPanel Version >= 1.9.2
- --subject Notification title
- --content Notification content
- --target Notification target, email method is mailbox.
- --channel Notification method email
dpanel system:notice --content test123 --target 914417117@qq.com --subject Test notificationReturn
{"code":200,"error":"","data":"success"}Simple Cache Data Storage DPanel Version >= 1.9.2
Using the cache data storage function, you can cache data or detect flag bits in scripts.
- --key Cache name
- --value Cache content, when empty get content of --key
- --keep Cache lifecycle (seconds), default is -1 (until main program restarts)
dpanel system:cache --key test1 --value 123Return
{"value":"123","found":true}Backup Panel Data DPanel Version >= 1.9.4
Backup DPanel panel data
- --backup-path Directory to backup, leave empty for all
- --ignore-path-prefix Skip directory prefix to backup, --ignore-path-prefix storage/temp skips directories or files starting with storage/temp
dpanel system:backupReturn
{"path":"dpanel-main-20260226191909.snapshot"}