1.4 KiB
1.4 KiB
WordPress
WordPress with MariaDB 11.4, behind Caddy with HTTPS. The site files and the database live in Docker volumes, so they survive updates.
Files
docker-compose.yml: MariaDB, WordPress (PHP 8.3) and Caddy.Caddyfile: HTTPS forDOMAIN, uploads up to 64 MB.uploads.ini: PHP limits for uploads and memory.backup.sh: saves the database andwp-contentintobackups/..env.example: copy it to.envand setDOMAINand both database passwords.
Publish on your VPS
- From the
templatesfolder:sh deploy.sh wordpress root@<server ip>. The first run creates.envon the server and stops. - Edit
/srv/wordpress/.envon the server: setDOMAINand put long random passwords inDB_PASSWORDandDB_ROOT_PASSWORD(openssl rand -base64 24). - Run the same command again, open
https://mybusiness.co.aoand finish the WordPress setup. Choose a strong admin password.
See the main README for the IP and the DNS records.
Backups and updates
- On the server:
cd /srv/wordpress && sh backup.sh. Copy the files inbackups/to another place, too. - Update WordPress, themes and plugins from the WordPress dashboard. To update PHP or MariaDB images:
docker compose pull && docker compose up -d, after a backup. - Do not change the database passwords in
.envafter the first start: MariaDB keeps the ones it was created with.