Ansible playbook to deploy one or more Wordpress instances.
It installs and configures Nginx, PHP 8.1, and Certbot for the SSL certificates. This playbook does not install the database service, and instead it expects variables to connect to a remote database.
- For each site the following will get created
- a directory in
/var/www/$NAME
withwww
,tmp
andlogs
subdirectories - a user associated to the directory above
- separate php fpm pools
- a directory in
- Uses certbot-dns-cloudflare plugin to validate your domains and generate the ssl certificates
- If you set env=dev it creates self-signed SSL certitifactes
- You can provide a dhparams.pem file in
roles/nginx/files/dhparams.pem
to be copied, or it will generate one for you (it'll take some time though)
- Ansible
- Cloudflare API token for the sites you want to manage
- Copy
vars.example
tovars.yaml
and update the configuration paramaters - Copy
inventory.example
toinventory
and update theservers
section to figure your targeted servers - Run
ansible-playbook -i inventory playbook.yaml
For a complete run:
vagrant up
Targeting specific vars
vagrant --tags=nginx up
Main available tags
- system
- php
- nginx
- certbot
- wordpress
👤 Alex Budurovici
- Website: w0rldart.com
- Github: @w0rldart
Contributions, issues and feature requests are welcome!
Feel free to check issues page. You can also take a look at the contributing guide.
Give a ⭐️ if this project helped you!
Copyright © 2022 Alex Budurovici.
This project is AGPL-3.0-or-later licensed.
This README was generated with ❤️ by readme-md-generator