From db698b595e7ff088c96d00ef5285a0d634aff1be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Romain=20Gon=C3=A7alves?= Date: Mon, 12 Dec 2022 22:15:01 +0100 Subject: refactor: pass ansible-lint with yaml header --- roles/_workstation/cronie/tasks/main.yml | 2 ++ roles/_workstation/doas/tasks/main.yml | 2 ++ roles/_workstation/dockerd/tasks/main.yml | 2 ++ roles/_workstation/dotfiles.yml | 2 ++ roles/acme/defaults/main.yml | 2 ++ roles/acme/tasks/main.yml | 2 ++ roles/cgit/defaults/main.yml | 2 ++ roles/cgit/meta/main.yml | 2 ++ roles/cgit/tasks/dependencies.yml | 2 ++ roles/cgit/tasks/main.yml | 2 ++ roles/git/defaults/main.yml | 2 ++ roles/git/tasks/main.yml | 2 ++ roles/grafana/defaults/main.yml | 2 ++ roles/grafana/tasks/main.yml | 2 ++ roles/httpd/defaults/main.yml | 2 ++ roles/httpd/meta/main.yml | 2 ++ roles/httpd/tasks/main.yml | 2 ++ roles/httpd_pre/defaults/main.yml | 9 ++++++++- roles/httpd_pre/tasks/main.yml | 2 ++ roles/httpd_site_healthcheck/defaults/main.yml | 9 ++++++++- roles/httpd_site_healthcheck/meta/main.yml | 2 ++ roles/httpd_site_healthcheck/tasks/main.yml | 2 ++ roles/loki/defaults/main.yml | 2 ++ roles/loki/tasks/main.yml | 2 ++ roles/miniflux/defaults/main.yml | 2 ++ roles/miniflux/meta/main.yml | 2 ++ roles/miniflux/tasks/main.yml | 2 ++ roles/nfsclient/defaults/main.yml | 2 ++ roles/nfsclient/handlers/main.yml | 2 ++ roles/nfsclient/tasks/main.yml | 2 ++ roles/nfsclient/tasks/os_alpine.yml | 2 ++ roles/nfsd/defaults/main.yml | 2 ++ roles/nfsd/tasks/main.yml | 2 ++ roles/nfsd/tasks/os_freebsd.yml | 2 ++ roles/pf/defaults/main.yml | 2 ++ roles/pf/handlers/main.yml | 2 ++ roles/pf/tasks/main.yml | 2 ++ roles/postgres/defaults/main.yml | 2 ++ roles/postgres/tasks/create_db.yml | 2 ++ roles/postgres/tasks/create_user.yml | 2 ++ roles/postgres/tasks/main.yml | 2 ++ roles/prometheus/defaults/main.yml | 2 ++ roles/prometheus/tasks/main.yml | 2 ++ roles/rc/defaults/main.yml | 2 ++ roles/rc/defaults/os_alpine.yml | 2 ++ roles/rc/defaults/os_openbsd.yml | 2 ++ roles/rc/tasks/main.yml | 2 ++ roles/rc/vars/os_alpine.yml | 2 ++ roles/rc/vars/os_openbsd.yml | 2 ++ roles/relayd/defaults/main.yml | 2 ++ roles/relayd/handlers/main.yml | 2 ++ roles/relayd/tasks/main.yml | 2 ++ roles/sshd/tasks/main.yml | 2 ++ roles/sshd/tasks/synchronize_keys.yml | 2 ++ roles/vmm/defaults/main.yml | 2 ++ roles/vmm/handlers/main.yml | 2 ++ roles/vmm/meta/main.yml | 2 ++ roles/vmm/tasks/autoinstall_configuration.yml | 2 ++ roles/vmm/tasks/disk.yml | 2 ++ roles/vmm/tasks/facts.yml | 2 ++ roles/vmm/tasks/iso.yml | 2 ++ roles/vmm/tasks/main.yml | 2 ++ roles/vmm/tasks/network.yml | 2 ++ roles/wireguard/defaults/main.yml | 2 ++ roles/wireguard/tasks/configuration.yml | 2 ++ roles/wireguard/tasks/cron.yml | 2 ++ roles/wireguard/tasks/keys.yml | 2 ++ roles/wireguard/tasks/main.yml | 2 ++ roles/wireguard/tasks/service.yml | 2 ++ roles/znc/defaults/main.yml | 2 ++ roles/znc/tasks/main.yml | 2 ++ 71 files changed, 154 insertions(+), 2 deletions(-) mode change 120000 => 100644 roles/httpd_pre/defaults/main.yml mode change 120000 => 100644 roles/httpd_site_healthcheck/defaults/main.yml (limited to 'roles') diff --git a/roles/_workstation/cronie/tasks/main.yml b/roles/_workstation/cronie/tasks/main.yml index faa1095..d39abf3 100644 --- a/roles/_workstation/cronie/tasks/main.yml +++ b/roles/_workstation/cronie/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: install cronie ansible.builtin.package: name: cronie diff --git a/roles/_workstation/doas/tasks/main.yml b/roles/_workstation/doas/tasks/main.yml index e65a510..be61f74 100644 --- a/roles/_workstation/doas/tasks/main.yml +++ b/roles/_workstation/doas/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: generate doas configuration ansible.builtin.lineinfile: path: "{{ doas_configuration_file }}" diff --git a/roles/_workstation/dockerd/tasks/main.yml b/roles/_workstation/dockerd/tasks/main.yml index 76d70d6..a7ba92b 100644 --- a/roles/_workstation/dockerd/tasks/main.yml +++ b/roles/_workstation/dockerd/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: install docker ansible.builtin.package: name: diff --git a/roles/_workstation/dotfiles.yml b/roles/_workstation/dotfiles.yml index 90b9f44..d3e7855 100644 --- a/roles/_workstation/dotfiles.yml +++ b/roles/_workstation/dotfiles.yml @@ -1,3 +1,5 @@ +--- + - name: install yadm ansible.builtin.package: name: yadm diff --git a/roles/acme/defaults/main.yml b/roles/acme/defaults/main.yml index 80c091a..24201bd 100644 --- a/roles/acme/defaults/main.yml +++ b/roles/acme/defaults/main.yml @@ -1,2 +1,4 @@ +--- + acme_configuration_file: /etc/acme-client.conf acme_domain_name: null diff --git a/roles/acme/tasks/main.yml b/roles/acme/tasks/main.yml index 0f55977..6d55599 100644 --- a/roles/acme/tasks/main.yml +++ b/roles/acme/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: generate acme-client configuration ansible.builtin.template: src: acme-client.conf.j2 diff --git a/roles/cgit/defaults/main.yml b/roles/cgit/defaults/main.yml index 47d312a..cf70c5b 100644 --- a/roles/cgit/defaults/main.yml +++ b/roles/cgit/defaults/main.yml @@ -1,3 +1,5 @@ +--- + cgit_instance: cgit cgit_git_dir: /data/git cgit_chroot_dir: /var/www diff --git a/roles/cgit/meta/main.yml b/roles/cgit/meta/main.yml index a25f289..bd45503 100644 --- a/roles/cgit/meta/main.yml +++ b/roles/cgit/meta/main.yml @@ -1,3 +1,5 @@ +--- + dependencies: - role: git tags: dependency diff --git a/roles/cgit/tasks/dependencies.yml b/roles/cgit/tasks/dependencies.yml index 9c3623a..5a74d45 100644 --- a/roles/cgit/tasks/dependencies.yml +++ b/roles/cgit/tasks/dependencies.yml @@ -1,3 +1,5 @@ +--- + - name: retrieve dependencies for lowdown # noqa: no-changed-when ansible.builtin.shell: | set -o pipefail diff --git a/roles/cgit/tasks/main.yml b/roles/cgit/tasks/main.yml index 245b34f..34e394c 100644 --- a/roles/cgit/tasks/main.yml +++ b/roles/cgit/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: install cgit packages ansible.builtin.package: name: diff --git a/roles/git/defaults/main.yml b/roles/git/defaults/main.yml index f99dec3..436c46b 100644 --- a/roles/git/defaults/main.yml +++ b/roles/git/defaults/main.yml @@ -1,3 +1,5 @@ +--- + git_user: git git_group: git git_dir: /data/git diff --git a/roles/git/tasks/main.yml b/roles/git/tasks/main.yml index 193844f..28c1cbf 100644 --- a/roles/git/tasks/main.yml +++ b/roles/git/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: install git package ansible.builtin.package: name: git diff --git a/roles/grafana/defaults/main.yml b/roles/grafana/defaults/main.yml index 32309e9..425c0d9 100644 --- a/roles/grafana/defaults/main.yml +++ b/roles/grafana/defaults/main.yml @@ -1,3 +1,5 @@ +--- + grafana_dir: /data/grafana grafana_port: 3001 grafana_port_out: 3000 diff --git a/roles/grafana/tasks/main.yml b/roles/grafana/tasks/main.yml index ac27e40..96f3966 100644 --- a/roles/grafana/tasks/main.yml +++ b/roles/grafana/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: install grafana ansible.builtin.package: name: grafana diff --git a/roles/httpd/defaults/main.yml b/roles/httpd/defaults/main.yml index ce189c2..3b0acd0 100644 --- a/roles/httpd/defaults/main.yml +++ b/roles/httpd/defaults/main.yml @@ -1,3 +1,5 @@ +--- + httpd_configuration_file: /etc/httpd.conf httpd_configuration_dir: /etc/httpd.d httpd_chroot: /var/www diff --git a/roles/httpd/meta/main.yml b/roles/httpd/meta/main.yml index 20728a9..161e3b8 100644 --- a/roles/httpd/meta/main.yml +++ b/roles/httpd/meta/main.yml @@ -1,3 +1,5 @@ +--- + dependencies: - role: httpd_pre tags: dependency diff --git a/roles/httpd/tasks/main.yml b/roles/httpd/tasks/main.yml index 348ea52..ce4853a 100644 --- a/roles/httpd/tasks/main.yml +++ b/roles/httpd/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: retrieve all configuration files ansible.builtin.find: path: "{{ httpd_configuration_dir }}" diff --git a/roles/httpd_pre/defaults/main.yml b/roles/httpd_pre/defaults/main.yml deleted file mode 120000 index 52d65d9..0000000 --- a/roles/httpd_pre/defaults/main.yml +++ /dev/null @@ -1 +0,0 @@ -../../httpd/defaults/main.yml \ No newline at end of file diff --git a/roles/httpd_pre/defaults/main.yml b/roles/httpd_pre/defaults/main.yml new file mode 100644 index 0000000..3b0acd0 --- /dev/null +++ b/roles/httpd_pre/defaults/main.yml @@ -0,0 +1,8 @@ +--- + +httpd_configuration_file: /etc/httpd.conf +httpd_configuration_dir: /etc/httpd.d +httpd_chroot: /var/www + +httpd_user: www +httpd_group: www diff --git a/roles/httpd_pre/tasks/main.yml b/roles/httpd_pre/tasks/main.yml index 46475d2..39cb1c7 100644 --- a/roles/httpd_pre/tasks/main.yml +++ b/roles/httpd_pre/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: create httpd directory ansible.builtin.file: path: /etc/httpd.d diff --git a/roles/httpd_site_healthcheck/defaults/main.yml b/roles/httpd_site_healthcheck/defaults/main.yml deleted file mode 120000 index 52d65d9..0000000 --- a/roles/httpd_site_healthcheck/defaults/main.yml +++ /dev/null @@ -1 +0,0 @@ -../../httpd/defaults/main.yml \ No newline at end of file diff --git a/roles/httpd_site_healthcheck/defaults/main.yml b/roles/httpd_site_healthcheck/defaults/main.yml new file mode 100644 index 0000000..3b0acd0 --- /dev/null +++ b/roles/httpd_site_healthcheck/defaults/main.yml @@ -0,0 +1,8 @@ +--- + +httpd_configuration_file: /etc/httpd.conf +httpd_configuration_dir: /etc/httpd.d +httpd_chroot: /var/www + +httpd_user: www +httpd_group: www diff --git a/roles/httpd_site_healthcheck/meta/main.yml b/roles/httpd_site_healthcheck/meta/main.yml index 6b163d1..dd93239 100644 --- a/roles/httpd_site_healthcheck/meta/main.yml +++ b/roles/httpd_site_healthcheck/meta/main.yml @@ -1,3 +1,5 @@ +--- + dependencies: - role: httpd_pre tags: dependency diff --git a/roles/httpd_site_healthcheck/tasks/main.yml b/roles/httpd_site_healthcheck/tasks/main.yml index 4834e2d..b955e02 100644 --- a/roles/httpd_site_healthcheck/tasks/main.yml +++ b/roles/httpd_site_healthcheck/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: create httpd healthcheck directory ansible.builtin.file: path: "{{ httpd_chroot }}/htdocs/healthcheck" diff --git a/roles/loki/defaults/main.yml b/roles/loki/defaults/main.yml index 6808f54..21d7a77 100644 --- a/roles/loki/defaults/main.yml +++ b/roles/loki/defaults/main.yml @@ -1,3 +1,5 @@ +--- + loki_configuration_file: /etc/loki/loki-config.yaml loki_promtail_configuration_file: /etc/promtail/promtail-config.yaml loki_user: _loki diff --git a/roles/loki/tasks/main.yml b/roles/loki/tasks/main.yml index 7315f18..1995f12 100644 --- a/roles/loki/tasks/main.yml +++ b/roles/loki/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: install loki ansible.builtin.package: name: loki diff --git a/roles/miniflux/defaults/main.yml b/roles/miniflux/defaults/main.yml index 2fd6108..7c92963 100644 --- a/roles/miniflux/defaults/main.yml +++ b/roles/miniflux/defaults/main.yml @@ -1,3 +1,5 @@ +--- + miniflux_user: _miniflux miniflux_group: _miniflux miniflux_db_user: miniflux diff --git a/roles/miniflux/meta/main.yml b/roles/miniflux/meta/main.yml index 3ffef7b..1fc1aee 100644 --- a/roles/miniflux/meta/main.yml +++ b/roles/miniflux/meta/main.yml @@ -1,3 +1,5 @@ +--- + dependencies: - role: postgres tags: dependency diff --git a/roles/miniflux/tasks/main.yml b/roles/miniflux/tasks/main.yml index 39cf807..91ac740 100644 --- a/roles/miniflux/tasks/main.yml +++ b/roles/miniflux/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: install miniflux ansible.builtin.package: name: miniflux diff --git a/roles/nfsclient/defaults/main.yml b/roles/nfsclient/defaults/main.yml index d0ca08e..0fa26b2 100644 --- a/roles/nfsclient/defaults/main.yml +++ b/roles/nfsclient/defaults/main.yml @@ -1,3 +1,5 @@ +--- + nfsclient_dir: /data nfsclient_fstab_path: /etc/fstab nfsclient_server_dir: /data/nfs diff --git a/roles/nfsclient/handlers/main.yml b/roles/nfsclient/handlers/main.yml index ec156ea..3593da0 100644 --- a/roles/nfsclient/handlers/main.yml +++ b/roles/nfsclient/handlers/main.yml @@ -1,3 +1,5 @@ +--- + - name: reload fstab # noqa: command-instead-of-module ignore-errors ansible.builtin.command: mount -a ignore_errors: true diff --git a/roles/nfsclient/tasks/main.yml b/roles/nfsclient/tasks/main.yml index 205a7fa..9f717f4 100644 --- a/roles/nfsclient/tasks/main.yml +++ b/roles/nfsclient/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: translate server string to server dict ansible.builtin.set_fact: nfsclient_server_ip: "{{ hostvars[nfsclient_server].__ip.external }}" diff --git a/roles/nfsclient/tasks/os_alpine.yml b/roles/nfsclient/tasks/os_alpine.yml index 73aebe8..1199dc8 100644 --- a/roles/nfsclient/tasks/os_alpine.yml +++ b/roles/nfsclient/tasks/os_alpine.yml @@ -1,3 +1,5 @@ +--- + - name: install nfs-utils ansible.builtin.package: name: nfs-utils diff --git a/roles/nfsd/defaults/main.yml b/roles/nfsd/defaults/main.yml index b214a7c..60fafc9 100644 --- a/roles/nfsd/defaults/main.yml +++ b/roles/nfsd/defaults/main.yml @@ -1,3 +1,5 @@ +--- + nfsd_dir: /data/nfs nfsd_shared_dirs: "{{ vmm_vms | map(attribute='name') | list }}" nfsd_configuration_file: /etc/exports diff --git a/roles/nfsd/tasks/main.yml b/roles/nfsd/tasks/main.yml index ca562d8..7e82a8f 100644 --- a/roles/nfsd/tasks/main.yml +++ b/roles/nfsd/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: create nfsd data directory ansible.builtin.file: path: "{{ nfsd_dir }}" diff --git a/roles/nfsd/tasks/os_freebsd.yml b/roles/nfsd/tasks/os_freebsd.yml index d1601c8..1bb7fa3 100644 --- a/roles/nfsd/tasks/os_freebsd.yml +++ b/roles/nfsd/tasks/os_freebsd.yml @@ -1,3 +1,5 @@ +--- + - name: edit daemons flags ansible.builtin.lineinfile: path: /etc/rc.conf diff --git a/roles/pf/defaults/main.yml b/roles/pf/defaults/main.yml index 777717d..0523589 100644 --- a/roles/pf/defaults/main.yml +++ b/roles/pf/defaults/main.yml @@ -1 +1,3 @@ +--- + pf_configuration_file: /etc/pf.conf diff --git a/roles/pf/handlers/main.yml b/roles/pf/handlers/main.yml index 8e49812..85a0996 100644 --- a/roles/pf/handlers/main.yml +++ b/roles/pf/handlers/main.yml @@ -1,3 +1,5 @@ +--- + - name: lint pf configuration ansible.builtin.command: "pfctl -nf {{ pf_configuration_file }}" diff --git a/roles/pf/tasks/main.yml b/roles/pf/tasks/main.yml index eb6f078..fcbac06 100644 --- a/roles/pf/tasks/main.yml +++ b/roles/pf/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: generate pf configuration ansible.builtin.template: src: pf.conf.j2 diff --git a/roles/postgres/defaults/main.yml b/roles/postgres/defaults/main.yml index 963e594..856ac50 100644 --- a/roles/postgres/defaults/main.yml +++ b/roles/postgres/defaults/main.yml @@ -1,3 +1,5 @@ +--- + postgres_dir: /data/postgresql postgres_default_dir: /var/postgresql postgres_user: _postgresql diff --git a/roles/postgres/tasks/create_db.yml b/roles/postgres/tasks/create_db.yml index 5f8db70..d2f3676 100644 --- a/roles/postgres/tasks/create_db.yml +++ b/roles/postgres/tasks/create_db.yml @@ -1,3 +1,5 @@ +--- + - name: create database # noqa: no-changed-when ansible.builtin.command: createdb -U postgres -O "{{ postgres_db_user }}" "{{ postgres_db_name }}" register: result diff --git a/roles/postgres/tasks/create_user.yml b/roles/postgres/tasks/create_user.yml index 483e507..793676e 100644 --- a/roles/postgres/tasks/create_user.yml +++ b/roles/postgres/tasks/create_user.yml @@ -1,3 +1,5 @@ +--- + - name: create database user # noqa: no-changed-when ansible.builtin.command: createuser -U postgres "{{ postgres_db_user }}" register: result diff --git a/roles/postgres/tasks/main.yml b/roles/postgres/tasks/main.yml index 8046d40..302fba4 100644 --- a/roles/postgres/tasks/main.yml +++ b/roles/postgres/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: install postgres ansible.builtin.package: name: diff --git a/roles/prometheus/defaults/main.yml b/roles/prometheus/defaults/main.yml index fa8c55f..74252b8 100644 --- a/roles/prometheus/defaults/main.yml +++ b/roles/prometheus/defaults/main.yml @@ -1 +1,3 @@ +--- + prometheus_configuration_file: /etc/prometheus/prometheus.yml diff --git a/roles/prometheus/tasks/main.yml b/roles/prometheus/tasks/main.yml index 900157f..956439a 100644 --- a/roles/prometheus/tasks/main.yml +++ b/roles/prometheus/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: install prometheus ansible.builtin.package: name: diff --git a/roles/rc/defaults/main.yml b/roles/rc/defaults/main.yml index f189142..5692a78 100644 --- a/roles/rc/defaults/main.yml +++ b/roles/rc/defaults/main.yml @@ -1,3 +1,5 @@ +--- + rc_dir: null rc_name: null diff --git a/roles/rc/defaults/os_alpine.yml b/roles/rc/defaults/os_alpine.yml index 5b87a57..8ae11ed 100644 --- a/roles/rc/defaults/os_alpine.yml +++ b/roles/rc/defaults/os_alpine.yml @@ -1 +1,3 @@ +--- + rc_dir: /etc/init.d diff --git a/roles/rc/defaults/os_openbsd.yml b/roles/rc/defaults/os_openbsd.yml index 345a648..257bd1c 100644 --- a/roles/rc/defaults/os_openbsd.yml +++ b/roles/rc/defaults/os_openbsd.yml @@ -1 +1,3 @@ +--- + rc_dir: /etc/rc.d diff --git a/roles/rc/tasks/main.yml b/roles/rc/tasks/main.yml index f45e373..3e0f0b5 100644 --- a/roles/rc/tasks/main.yml +++ b/roles/rc/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: check required variables ansible.builtin.fail: when: > diff --git a/roles/rc/vars/os_alpine.yml b/roles/rc/vars/os_alpine.yml index 5b87a57..8ae11ed 100644 --- a/roles/rc/vars/os_alpine.yml +++ b/roles/rc/vars/os_alpine.yml @@ -1 +1,3 @@ +--- + rc_dir: /etc/init.d diff --git a/roles/rc/vars/os_openbsd.yml b/roles/rc/vars/os_openbsd.yml index 345a648..257bd1c 100644 --- a/roles/rc/vars/os_openbsd.yml +++ b/roles/rc/vars/os_openbsd.yml @@ -1 +1,3 @@ +--- + rc_dir: /etc/rc.d diff --git a/roles/relayd/defaults/main.yml b/roles/relayd/defaults/main.yml index 174a889..7171f53 100644 --- a/roles/relayd/defaults/main.yml +++ b/roles/relayd/defaults/main.yml @@ -1,3 +1,5 @@ +--- + relayd_configuration_file: /etc/relayd.conf relayd_domain_name: example.com relayd_transparent: true diff --git a/roles/relayd/handlers/main.yml b/roles/relayd/handlers/main.yml index 5bc6b49..58e1171 100644 --- a/roles/relayd/handlers/main.yml +++ b/roles/relayd/handlers/main.yml @@ -1,2 +1,4 @@ +--- + - name: lint relayd configuration ansible.builtin.command: "relayd -nf {{ relayd_configuration_file }}" diff --git a/roles/relayd/tasks/main.yml b/roles/relayd/tasks/main.yml index 0396789..35b456d 100644 --- a/roles/relayd/tasks/main.yml +++ b/roles/relayd/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: generate relayd configuration ansible.builtin.template: src: relayd.conf.j2 diff --git a/roles/sshd/tasks/main.yml b/roles/sshd/tasks/main.yml index d9d14ff..df5d845 100644 --- a/roles/sshd/tasks/main.yml +++ b/roles/sshd/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: generate sshd configuration ansible.builtin.template: src: sshd_config.j2 diff --git a/roles/sshd/tasks/synchronize_keys.yml b/roles/sshd/tasks/synchronize_keys.yml index 16c437c..32f6b5a 100644 --- a/roles/sshd/tasks/synchronize_keys.yml +++ b/roles/sshd/tasks/synchronize_keys.yml @@ -1,3 +1,5 @@ +--- + - name: get ssh keys for all users ansible.builtin.find: paths: files/keys diff --git a/roles/vmm/defaults/main.yml b/roles/vmm/defaults/main.yml index 91bae08..1eaf736 100644 --- a/roles/vmm/defaults/main.yml +++ b/roles/vmm/defaults/main.yml @@ -1,3 +1,5 @@ +--- + vmm_root_dir: /data/vmm vmm_autoinstall_dir: /var/www/htdocs/autoinstall vmm_iso_dir: /data/vmm/iso.d diff --git a/roles/vmm/handlers/main.yml b/roles/vmm/handlers/main.yml index a867c66..00bb0ad 100644 --- a/roles/vmm/handlers/main.yml +++ b/roles/vmm/handlers/main.yml @@ -1,2 +1,4 @@ +--- + - name: lint vmm configuration ansible.builtin.command: "vmd -nf {{ vmm_configuration_file }}" diff --git a/roles/vmm/meta/main.yml b/roles/vmm/meta/main.yml index 6b163d1..dd93239 100644 --- a/roles/vmm/meta/main.yml +++ b/roles/vmm/meta/main.yml @@ -1,3 +1,5 @@ +--- + dependencies: - role: httpd_pre tags: dependency diff --git a/roles/vmm/tasks/autoinstall_configuration.yml b/roles/vmm/tasks/autoinstall_configuration.yml index 4eccb93..71ceb6d 100644 --- a/roles/vmm/tasks/autoinstall_configuration.yml +++ b/roles/vmm/tasks/autoinstall_configuration.yml @@ -1,3 +1,5 @@ +--- + - name: include httpd role variables ansible.builtin.include_vars: "{{ inventory_dir }}/roles/httpd/defaults/main.yml" diff --git a/roles/vmm/tasks/disk.yml b/roles/vmm/tasks/disk.yml index 01fdc48..5883402 100644 --- a/roles/vmm/tasks/disk.yml +++ b/roles/vmm/tasks/disk.yml @@ -1,3 +1,5 @@ +--- + - name: create disks ansible.builtin.command: cmd: vmctl create -s "{{ item.size }}" "{{ item.name }}.{{ vmm_disk_format }}" diff --git a/roles/vmm/tasks/facts.yml b/roles/vmm/tasks/facts.yml index c3ae20c..ef1bfa6 100644 --- a/roles/vmm/tasks/facts.yml +++ b/roles/vmm/tasks/facts.yml @@ -1,3 +1,5 @@ +--- + - name: generate lladdr variable for virtual machines ansible.builtin.set_fact: vmm_vms_tmp: > diff --git a/roles/vmm/tasks/iso.yml b/roles/vmm/tasks/iso.yml index 320e7ca..70ad593 100644 --- a/roles/vmm/tasks/iso.yml +++ b/roles/vmm/tasks/iso.yml @@ -1,3 +1,5 @@ +--- + - name: download latest iso files ansible.builtin.get_url: url: "{{ item.url }}" diff --git a/roles/vmm/tasks/main.yml b/roles/vmm/tasks/main.yml index 7e1359e..a7d4621 100644 --- a/roles/vmm/tasks/main.yml +++ b/roles/vmm/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: create vmm directories ansible.builtin.file: path: "{{ item }}" diff --git a/roles/vmm/tasks/network.yml b/roles/vmm/tasks/network.yml index 82f3597..6846c05 100644 --- a/roles/vmm/tasks/network.yml +++ b/roles/vmm/tasks/network.yml @@ -1,3 +1,5 @@ +--- + - name: start ip forwarding ansible.builtin.command: sysctl net.inet.ip{{ item }}.forwarding=1 loop: "{{ vmm_network_forwarded_ips }}" diff --git a/roles/wireguard/defaults/main.yml b/roles/wireguard/defaults/main.yml index 2275c05..72cc66d 100644 --- a/roles/wireguard/defaults/main.yml +++ b/roles/wireguard/defaults/main.yml @@ -1,3 +1,5 @@ +--- + wireguard_dir: /etc/wireguard wireguard_local_dir: "{{ inventory_dir }}/files/secrets/wireguard" wireguard_local_keys: "{{ inventory_hostname }}.keys" diff --git a/roles/wireguard/tasks/configuration.yml b/roles/wireguard/tasks/configuration.yml index 6925e2a..610c191 100644 --- a/roles/wireguard/tasks/configuration.yml +++ b/roles/wireguard/tasks/configuration.yml @@ -1,3 +1,5 @@ +--- + - name: generate wireguard configuration ansible.builtin.template: src: wireguard.conf.j2 diff --git a/roles/wireguard/tasks/cron.yml b/roles/wireguard/tasks/cron.yml index 482b34f..dd70e5c 100644 --- a/roles/wireguard/tasks/cron.yml +++ b/roles/wireguard/tasks/cron.yml @@ -1,3 +1,5 @@ +--- + - name: add cronjob for keepalive ansible.builtin.cron: name: keepalive network traffic to domain controller diff --git a/roles/wireguard/tasks/keys.yml b/roles/wireguard/tasks/keys.yml index 128d943..ee42408 100644 --- a/roles/wireguard/tasks/keys.yml +++ b/roles/wireguard/tasks/keys.yml @@ -1,3 +1,5 @@ +--- + - name: generate hosts keys ansible.builtin.shell: | set -o pipefail diff --git a/roles/wireguard/tasks/main.yml b/roles/wireguard/tasks/main.yml index d780186..0e2343d 100644 --- a/roles/wireguard/tasks/main.yml +++ b/roles/wireguard/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: create local wireguard directory ansible.builtin.file: path: "{{ wireguard_local_dir }}" diff --git a/roles/wireguard/tasks/service.yml b/roles/wireguard/tasks/service.yml index c9e7f60..516cee1 100644 --- a/roles/wireguard/tasks/service.yml +++ b/roles/wireguard/tasks/service.yml @@ -1,3 +1,5 @@ +--- + - name: enable wireguard interface for OpenBSD ansible.builtin.lineinfile: path: /etc/rc.local diff --git a/roles/znc/defaults/main.yml b/roles/znc/defaults/main.yml index 879ed75..7d7b965 100644 --- a/roles/znc/defaults/main.yml +++ b/roles/znc/defaults/main.yml @@ -1,2 +1,4 @@ +--- + znc_user: _znc znc_group: _znc diff --git a/roles/znc/tasks/main.yml b/roles/znc/tasks/main.yml index 62ec909..df9a092 100644 --- a/roles/znc/tasks/main.yml +++ b/roles/znc/tasks/main.yml @@ -1,3 +1,5 @@ +--- + - name: install znc ansible.builtin.package: name: znc -- cgit v1.2.3