|
||
---|---|---|
nginx | ||
docker-compose.yml.sample | ||
Dockerfile | ||
nginx.conf | ||
README.md | ||
wordpress.conf |
Simple custom template for a clean Wordpress installation.
Install
$ docker-compose build
Run
$ docker-compose up -d
Config
Database credentials may edit on ENVIRONMENT on docker-compose.yml
Auto update Wordpress
User crontab on your hoster server.
Use this script as template:
#!/bin/bash
echo "Update Wordrpress"
docker exec -it docker-wordpress-ahum_wordpress_1 sudo -u wordpress -i -- /app/wp theme update --all --path="/app/wordpress/"
docker exec -it docker-wordpress-ahum_wordpress_1 sudo -u wordpress -i -- /app/wp plugin update --all --path="/app/wordpress/"
docker exec -it docker-wordpress-ahum_wordpress_1 sudo -u wordpress -i -- /app/wp core update --path="/app/wordpress/"
Backups
....
Restore
Database restore, like this examples:
$ cat .sql | docker exec -i <docker_database_name> mysql -u <db_user> -p<db_pass>
Data restore, bulk to volume directory, like:
$ rsync -avz <backup_wordpress_dir> /var/lib/docker/volumes/<docker_wordpress_volume>/_data/wordpress/