diff --git a/basics.yml b/basics.yml index 478ee7a..52a800a 100644 --- a/basics.yml +++ b/basics.yml @@ -1,20 +1,20 @@ --- - hosts: ffhh roles: - - basics + - alxndr42.commons.basics - basics-ffhh tags: basics - hosts: nginx roles: - - nginx + - alxndr42.commons.nginx - nginx-ffhh - error-pages tags: nginx - hosts: certbot roles: - - certbot + - alxndr42.commons.certbot tags: certbot - hosts: certsync diff --git a/inventory/group_vars/all.yml b/inventory/group_vars/all.yml index 000c0ff..dc985b7 100644 --- a/inventory/group_vars/all.yml +++ b/inventory/group_vars/all.yml @@ -1,5 +1,5 @@ -ansible_python_interpreter: /usr/bin/python3 - basics_autoupdate_mail: backend@hamburg.freifunk.net +certbot_email: backend@hamburg.freifunk.net + nginx_error_log: "/dev/null error" diff --git a/inventory/host_vars/srv02.yml b/inventory/host_vars/srv02.yml index 75aa1db..c0bb90a 100644 --- a/inventory/host_vars/srv02.yml +++ b/inventory/host_vars/srv02.yml @@ -1,6 +1,5 @@ basics_autoupdate_origins: - o=Node Source,n=${distro_codename} - - o=Prosody,n=${distro_codename} - o=TorProject,n=${distro_codename} media_tls_crt: /etc/letsencrypt/live/media.hamburg.freifunk.net/fullchain.pem diff --git a/requirements-galaxy.yml b/requirements-galaxy.yml index d091cc4..2f90b52 100644 --- a/requirements-galaxy.yml +++ b/requirements-galaxy.yml @@ -1,7 +1,4 @@ --- -- src: alxndr42.basics - name: basics - version: v1.11.0 -- src: alxndr42.nginx - name: nginx - version: v1.4.0 +collections: + - name: alxndr42.commons + version: 1.0.0 diff --git a/requirements-github.yml b/requirements-github.yml index 4baac94..35f21e5 100644 --- a/requirements-github.yml +++ b/requirements-github.yml @@ -1,7 +1,5 @@ --- -- src: https://github.com/alxndr42/ansible-basics.git - name: basics - version: v1.11.0 -- src: https://github.com/alxndr42/ansible-nginx.git - name: nginx - version: v1.4.0 +collections: + - name: https://github.com/alxndr42/ansible-commons.git + type: git + version: v1.0.0 diff --git a/roles/certbot/files/cli.ini b/roles/certbot/files/cli.ini deleted file mode 100644 index c08b252..0000000 --- a/roles/certbot/files/cli.ini +++ /dev/null @@ -1,13 +0,0 @@ -# Because we are using logrotate for greater flexibility, disable the -# internal certbot logrotation. -max-log-backups = 0 - -email = backend@hamburg.freifunk.net -rsa-key-size = 4096 - -authenticator = webroot -webroot-path = /var/www/_acme-challenge - -agree-tos = True -non-interactive = True -text = True diff --git a/roles/certbot/files/reload-nginx b/roles/certbot/files/reload-nginx deleted file mode 100644 index aaaaf79..0000000 --- a/roles/certbot/files/reload-nginx +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/bash - -PATH="/bin:/usr/bin:/usr/local/bin:/sbin:/usr/sbin:/usr/local/sbin" - -systemctl reload nginx diff --git a/roles/certbot/tasks/main.yml b/roles/certbot/tasks/main.yml deleted file mode 100644 index f40f37e..0000000 --- a/roles/certbot/tasks/main.yml +++ /dev/null @@ -1,25 +0,0 @@ ---- -- name: install certbot - apt: - name: certbot - cache_valid_time: 86400 - -- name: create webroot directory - file: - path: /var/www/_acme-challenge - state: directory - -- name: copy cli.ini - copy: - src: cli.ini - dest: /etc/letsencrypt/ - -- name: populate service facts - service_facts: - -- name: copy reload-nginx hook - copy: - src: reload-nginx - dest: /etc/letsencrypt/renewal-hooks/post/ - mode: 0755 - when: "'nginx' in services" diff --git a/roles/error-pages/files/error-pages.conf b/roles/error-pages/files/error-pages.conf index aecc17c..248a804 100644 --- a/roles/error-pages/files/error-pages.conf +++ b/roles/error-pages/files/error-pages.conf @@ -1,5 +1,5 @@ -error_page 502 /_error-pages/502.html; +error_page 502 /error-pages/502.html; -location ^~ /_error-pages { +location ^~ /error-pages { root /var/www; } diff --git a/roles/error-pages/files/error-pages/502.html b/roles/error-pages/files/error-pages/502.html index 4788012..c395ba4 100644 --- a/roles/error-pages/files/error-pages/502.html +++ b/roles/error-pages/files/error-pages/502.html @@ -3,8 +3,8 @@