Added: ejabberd config (WIP)
This commit is contained in:
parent
afde58b884
commit
a3b0d73352
11 changed files with 402 additions and 60 deletions
|
|
@ -1,12 +1,5 @@
|
|||
---
|
||||
- name: disable access logs
|
||||
ansible.builtin.blockinfile:
|
||||
path: "{{ nginx.paths.conf_d }}/10-access_log-disabled.conf"
|
||||
block: |
|
||||
access_log off;
|
||||
create: true
|
||||
|
||||
- name: Create auto redirect to TLS
|
||||
- name: Create auto redirect to TLS for movim
|
||||
ansible.builtin.blockinfile:
|
||||
path: "{{ nginx.paths.sites_available }}/redirect_to_https"
|
||||
block: |
|
||||
|
|
@ -17,39 +10,6 @@
|
|||
}
|
||||
create: true
|
||||
|
||||
- name: Disable movim website
|
||||
ansible.builtin.file:
|
||||
path: "{{ nginx.paths.sites_enabled }}/{{ movim.domain }}"
|
||||
state: absent
|
||||
|
||||
- name: Disable auto redirect to TLS
|
||||
ansible.builtin.file:
|
||||
path: "{{ nginx.paths.sites_enabled }}/redirect_to_https"
|
||||
state: absent
|
||||
|
||||
- name: Enable default website
|
||||
ansible.builtin.file:
|
||||
dest: "{{ nginx.paths.sites_enabled }}/default"
|
||||
src: "{{ nginx.paths.sites_available }}/default"
|
||||
state: link
|
||||
|
||||
- name: Install X509 certificates
|
||||
ansible.builtin.command:
|
||||
argv:
|
||||
- certbot
|
||||
- certonly
|
||||
- --agree-tos
|
||||
- -m psotmaster@trans13nrv.eu.org
|
||||
- --nginx
|
||||
- -d
|
||||
- "{{ movim.domain }}"
|
||||
creates: "/etc/letsencrypt/live/{{ movim.domain }}/privkey.pem"
|
||||
|
||||
- name: Disable default website
|
||||
ansible.builtin.file:
|
||||
path: "{{ nginx.paths.sites_enabled }}/default"
|
||||
state: absent
|
||||
|
||||
- name: Create movim website
|
||||
ansible.builtin.template:
|
||||
dest: "{{ nginx.paths.sites_available }}/{{ movim.domain }}"
|
||||
|
|
@ -70,7 +30,14 @@
|
|||
dest: "{{ nginx.paths.sites_enabled }}/redirect_to_https"
|
||||
src: "{{ nginx.paths.sites_available }}/redirect_to_https"
|
||||
|
||||
- name: Set access logs to off
|
||||
ansible.builtin.blockinfile:
|
||||
path: "{{ nginx.paths.conf_d }}/10-access_log-disabled.conf"
|
||||
block: |
|
||||
access_log off;
|
||||
create: true
|
||||
|
||||
- name: Reload nginx service
|
||||
ansible.builtin.systemd_service:
|
||||
name: nginx
|
||||
state: reloaded
|
||||
state: restarted
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue