mirror of
https://github.com/2martens/cloud-configuration.git
synced 2026-10-17 16:46:51 +02:00
17 lines
384 B
YAML
17 lines
384 B
YAML
---
|
|
- name: Install nginx
|
|
ansible.builtin.apt:
|
|
name: nginx
|
|
update_cache: true
|
|
- name: Allow nginx through firewall
|
|
community.general.ufw:
|
|
name: Nginx Full
|
|
rule: allow
|
|
- name: Disable server tokens
|
|
notify: Restart nginx
|
|
ansible.builtin.lineinfile:
|
|
backrefs: true
|
|
regexp: "(\\s+)# (server_tokens off;)"
|
|
path: /etc/nginx/nginx.conf
|
|
line: "\\1\\2"
|