In this guide we'll use [old-host] for the source Docker host and [new-host] for the destination. Both should be running the same version of Dradis before you begin. If you need to upgrade at the same time, migrate first, then upgrade on the new host.
With Docker, Dradis content is stored in Docker Volumes rather than in the container itself. As such, your volumes are accessible from outside the container, so you can back up or move them as you like.
When migrating to a new Docker host, simply copy or move the volumes over to the new host.
Run the installer on the new host with the same configuration as the source. Do not start the stack yet after install — stop it before the application initialises for the first time:
$ ssh deployer@[new-host] 'docker compose down'
$ ssh deployer@[new-host] 'docker compose up -d'
Navigate to https://[new-host]/pro and confirm your projects, attachments, and templates are present before decommissioning the old host.
docker compose logs on the new host.
The following volumes contain data that must be included in any backup for full disaster recovery. See the volume reference for the complete list of what each volume holds.
Where are the export scripts? The dp-export-* commands (dp-export-mysql, dp-export-attachments, dp-export-templates, dp-export-storage) are included inside the running app container. You do not need to install them separately — run them via docker exec app <command> as shown below. Note that dp-export-storage already contains templates and attachments. The templates and attachments scripts remain in case you want to back those up separately or individually.
Run these commands from your local machine:
$ ssh deployer@[dradispro] -- 'docker exec app dp-export-attachments' > dradis-attachments.tar $ ssh deployer@[dradispro] -- 'docker exec app dp-export-mysql' | gzip > dradis-mysql-backup.sql.gz $ ssh deployer@[dradispro] -- 'docker exec app dp-export-templates' > dradis-templates.tar $ ssh deployer@[dradispro] 'docker exec app dp-export-storage' > dradis-storage.tar
Also back up the credentials volume separately, as it holds the encryption keys required to restore any of the above:
$ ssh deployer@[dradispro] 'docker run --rm -v dradis-credentials:/data busybox tar -cf - -C /data .' > dradis-credentials.tar
You can script this and combine it with your standard backup software to make sure all your Dradis data is safe.
In addition, you should consider the additional step of encrypting your backups for good measure (something simple like openssl should do the trick):
$ openssl enc -aes-256-cbc -salt -in file.plain -out file.enc
Great job, you reached the end of the guide! Have you read all of them?
Loading form...
Your email is kept private. We don't do the spam thing.