first push with basic outline
This commit is contained in:
21
roles/nginx/tasks/main.yml
Normal file
21
roles/nginx/tasks/main.yml
Normal file
@@ -0,0 +1,21 @@
|
||||
---
|
||||
- name: Install nginx
|
||||
ansible.builtin.apt:
|
||||
name: nginx
|
||||
state: present
|
||||
|
||||
- name: Ensure nginx is running and enabled
|
||||
ansible.builtin.service:
|
||||
name: nginx
|
||||
state: started
|
||||
enabled: true
|
||||
|
||||
# TODO: template out vhosts from the `nginx_sites` var defined in
|
||||
# group_vars/webservers.yml, e.g.:
|
||||
#
|
||||
# - name: Deploy vhost configs
|
||||
# ansible.builtin.template:
|
||||
# src: vhost.conf.j2
|
||||
# dest: "/etc/nginx/sites-available/{{ item.name }}"
|
||||
# loop: "{{ nginx_sites }}"
|
||||
# notify: Reload nginx
|
||||
Reference in New Issue
Block a user