Create dhparams only for gateways or standalone servers
Fix lint warnings
This commit is contained in:
parent
0cdb3c6792
commit
719fc93598
2 changed files with 6 additions and 5 deletions
|
@ -3,6 +3,7 @@
|
||||||
community.crypto.openssl_dhparam:
|
community.crypto.openssl_dhparam:
|
||||||
path: "{{ dhparam_path }}"
|
path: "{{ dhparam_path }}"
|
||||||
size: "{{ dhparam_size | default(4096) }}"
|
size: "{{ dhparam_size | default(4096) }}"
|
||||||
|
when: nginx_type == 'gateway' or nginx_type == 'standalone'
|
||||||
|
|
||||||
- name: "Configuration | Get bad user agents"
|
- name: "Configuration | Get bad user agents"
|
||||||
ansible.builtin.shell: "curl {{ bad_user_agents_url }}"
|
ansible.builtin.shell: "curl {{ bad_user_agents_url }}"
|
||||||
|
@ -12,14 +13,14 @@
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
src: nginx.conf.j2
|
src: nginx.conf.j2
|
||||||
dest: /etc/nginx/nginx.conf
|
dest: /etc/nginx/nginx.conf
|
||||||
mode: 0644
|
mode: "0644"
|
||||||
notify: reload nginx
|
notify: reload nginx
|
||||||
|
|
||||||
- name: "Configuration | Copy configuration snippets"
|
- name: "Configuration | Copy configuration snippets"
|
||||||
ansible.builtin.copy:
|
ansible.builtin.copy:
|
||||||
src: "{{ item }}"
|
src: "{{ item }}"
|
||||||
dest: "/etc/nginx/snippets/{{ item }}"
|
dest: "/etc/nginx/snippets/{{ item }}"
|
||||||
mode: 0644
|
mode: "0644"
|
||||||
loop:
|
loop:
|
||||||
- add_headers.conf
|
- add_headers.conf
|
||||||
- letsencrypt.conf
|
- letsencrypt.conf
|
||||||
|
@ -29,7 +30,7 @@
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
src: "{{ item }}.j2"
|
src: "{{ item }}.j2"
|
||||||
dest: "/etc/nginx/conf.d/{{ item }}"
|
dest: "/etc/nginx/conf.d/{{ item }}"
|
||||||
mode: 0644
|
mode: "0644"
|
||||||
loop:
|
loop:
|
||||||
- bad_clients.conf
|
- bad_clients.conf
|
||||||
- bad_bots.conf
|
- bad_bots.conf
|
||||||
|
@ -42,6 +43,6 @@
|
||||||
ansible.builtin.copy:
|
ansible.builtin.copy:
|
||||||
src: request_limits.conf
|
src: request_limits.conf
|
||||||
dest: /etc/nginx/conf.d/
|
dest: /etc/nginx/conf.d/
|
||||||
mode: 0644
|
mode: "0644"
|
||||||
notify: reload nginx
|
notify: reload nginx
|
||||||
when: nginx_type == 'gateway' or nginx_type == 'standalone'
|
when: nginx_type == 'gateway' or nginx_type == 'standalone'
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
ansible.builtin.copy:
|
ansible.builtin.copy:
|
||||||
src: "fail2ban/{{ item }}"
|
src: "fail2ban/{{ item }}"
|
||||||
dest: "/etc/fail2ban/{{ item }}"
|
dest: "/etc/fail2ban/{{ item }}"
|
||||||
mode: 0644
|
mode: "0644"
|
||||||
notify: reload fail2ban
|
notify: reload fail2ban
|
||||||
loop:
|
loop:
|
||||||
- "filter.d/nginx-req-limit.conf"
|
- "filter.d/nginx-req-limit.conf"
|
||||||
|
|
Loading…
Reference in a new issue