An Ansible role that configure nginx.
ansible-galaxy install maruina.nginx
Override every parameters that you need to change.
nginx_sites:
my_blog:
- listen 80
- root /var/www/my_blog
- server_name www.myblog.com
- location / {
option value;
}
my_second_website:
- listen 81
- root /var/www/another_root
- server_name samename.com
- location / {
autoindex on;
}
- another nginx option
- hosts: all
roles:
- { role: maruina.nginx }
MIT