Skip to content

Commit

Permalink
chore: Satisfy yamllint
Browse files Browse the repository at this point in the history
  • Loading branch information
Salvoxia committed Nov 29, 2024
1 parent 62ab9bd commit 0745e40
Show file tree
Hide file tree
Showing 25 changed files with 175 additions and 173 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/molecule.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
name: Molecule

on:
'on':
push:
pull_request:
branches:
Expand All @@ -16,4 +17,4 @@ jobs:
- name: Molecule
uses: gofrolist/molecule-action@v2
env:
ANSIBLE_FORCE_COLOR: '1'
ANSIBLE_FORCE_COLOR: '1'
2 changes: 1 addition & 1 deletion handlers/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@

- name: Systemctl daemon-reload
ansible.builtin.systemd:
daemon_reload: true
daemon_reload: true
38 changes: 19 additions & 19 deletions molecule/install_from_pkgmgr/converge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,22 @@
dest: "/etc/nut/dummy-ups2.dev"
mode: '0755'
roles:
- role: nut
nut_users:
- name: monitor
password: changeme
role: secondary
- name: second_user
password: insecure_password
role: primary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
- name: dummy_ups2
monitoruser: second_user
driver: dummy-ups
device: /etc/nut/dummy-ups2.dev
description: "Dummy UPS 2 for testing"
- role: nut

Check failure on line 22 in molecule/install_from_pkgmgr/converge.yml

View workflow job for this annotation

GitHub Actions / Lint

syntax-check[specific]

the role 'nut' was not found in /home/runner/work/ansible-role-nut/ansible-role-nut/molecule/install_from_pkgmgr/roles:/home/runner/.cache/ansible-compat/14eb40/roles:/home/runner/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles:/home/runner/work/ansible-role-nut/ansible-role-nut/molecule/install_from_pkgmgr
nut_users:
- name: monitor
password: changeme
role: secondary
- name: second_user
password: insecure_password
role: primary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
- name: dummy_ups2
monitoruser: second_user
driver: dummy-ups
device: /etc/nut/dummy-ups2.dev
description: "Dummy UPS 2 for testing"
2 changes: 1 addition & 1 deletion molecule/install_from_pkgmgr/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,4 @@
- -a second_user
- -p insecure_password
- dummy_ups2
- load.off
- load.off
32 changes: 16 additions & 16 deletions molecule/install_from_source/converge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,19 +14,19 @@
dest: "/etc/nut/dummy-ups.dev"
mode: '0755'
roles:
- role: nut
nut_install_from_source: true
nut_source_repository: https://git.local.salvoxia.de/Github/nut.git
nut_source_tag: v2.8.2
nut_drivers:
- dummy-ups
nut_users:
- name: monitor
password: changeme
role: secondary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
- role: nut

Check failure on line 17 in molecule/install_from_source/converge.yml

View workflow job for this annotation

GitHub Actions / Lint

syntax-check[specific]

the role 'nut' was not found in /home/runner/work/ansible-role-nut/ansible-role-nut/molecule/install_from_source/roles:/home/runner/.cache/ansible-compat/14eb40/roles:/home/runner/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles:/home/runner/work/ansible-role-nut/ansible-role-nut/molecule/install_from_source
nut_install_from_source: true
nut_source_repository: https://git.local.salvoxia.de/Github/nut.git
nut_source_tag: v2.8.2
nut_drivers:
- dummy-ups
nut_users:
- name: monitor
password: changeme
role: secondary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
16 changes: 8 additions & 8 deletions molecule/install_from_source/molecule.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@ platforms:
privileged: true
volumes:
- /sys/fs/cgroup:/sys/fs/cgroup:rw
#- name: debian-11
# image: geerlingguy/docker-debian11-ansible
# command: ${MOLECULE_DOCKER_COMMAND:-""}
# pre_build_image: true
# cgroupns_mode: host
# privileged: true
# volumes:
# - /sys/fs/cgroup:/sys/fs/cgroup:rw
- name: debian-11
image: geerlingguy/docker-debian11-ansible
command: ${MOLECULE_DOCKER_COMMAND:-""}
pre_build_image: true
cgroupns_mode: host
privileged: true
volumes:
- /sys/fs/cgroup:/sys/fs/cgroup:rw
provisioner:
name: ansible
verifier:
Expand Down
8 changes: 4 additions & 4 deletions molecule/install_from_source/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@

- name: Get installed NUT version
ansible.builtin.include_tasks: ../../tasks/get_installed_nut_version.yml

- name: Verify installed version matches desired version
ansible.builtin.assert:
that:
that:
- nut_installed_version is defined
- nut_installed_version == "v2.8.2"

- name: Gather installed services
ansible.builtin.service_facts:

Expand All @@ -44,6 +44,6 @@

- name: Verify no NUT packages are installed
ansible.builtin.assert:
that:
that:
- ansible_facts.packages['nut-client'] is not defined
- ansible_facts.packages['nut-server'] is not defined
32 changes: 16 additions & 16 deletions molecule/switch_from_pkgmgr_to_source/converge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,19 +14,19 @@
dest: "/etc/nut/dummy-ups.dev"
mode: '0755'
roles:
- role: nut
nut_install_from_source: true
nut_source_repository: https://git.local.salvoxia.de/Github/nut.git
nut_source_tag: v2.8.2
nut_drivers:
- dummy-ups
nut_users:
- name: monitor
password: changeme
role: secondary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
- role: nut

Check failure on line 17 in molecule/switch_from_pkgmgr_to_source/converge.yml

View workflow job for this annotation

GitHub Actions / Lint

syntax-check[specific]

the role 'nut' was not found in /home/runner/work/ansible-role-nut/ansible-role-nut/molecule/switch_from_pkgmgr_to_source/roles:/home/runner/.cache/ansible-compat/14eb40/roles:/home/runner/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles:/home/runner/work/ansible-role-nut/ansible-role-nut/molecule/switch_from_pkgmgr_to_source
nut_install_from_source: true
nut_source_repository: https://git.local.salvoxia.de/Github/nut.git
nut_source_tag: v2.8.2
nut_drivers:
- dummy-ups
nut_users:
- name: monitor
password: changeme
role: secondary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
38 changes: 19 additions & 19 deletions molecule/switch_from_pkgmgr_to_source/prepare.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,22 @@
dest: "/etc/nut/dummy-ups2.dev"
mode: '0755'
roles:
- role: nut
nut_users:
- name: monitor
password: changeme
role: secondary
- name: second_user
password: insecure_password
role: primary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
- name: dummy_ups2
monitoruser: second_user
driver: dummy-ups
device: /etc/nut/dummy-ups2.dev
description: "Dummy UPS 2 for testing"
- role: nut

Check failure on line 22 in molecule/switch_from_pkgmgr_to_source/prepare.yml

View workflow job for this annotation

GitHub Actions / Lint

syntax-check[specific]

the role 'nut' was not found in /home/runner/work/ansible-role-nut/ansible-role-nut/molecule/switch_from_pkgmgr_to_source/roles:/home/runner/.cache/ansible-compat/14eb40/roles:/home/runner/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles:/home/runner/work/ansible-role-nut/ansible-role-nut/molecule/switch_from_pkgmgr_to_source
nut_users:
- name: monitor
password: changeme
role: secondary
- name: second_user
password: insecure_password
role: primary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
- name: dummy_ups2
monitoruser: second_user
driver: dummy-ups
device: /etc/nut/dummy-ups2.dev
description: "Dummy UPS 2 for testing"
8 changes: 4 additions & 4 deletions molecule/switch_from_pkgmgr_to_source/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@

- name: Get installed NUT version
ansible.builtin.include_tasks: ../../tasks/get_installed_nut_version.yml

- name: Verify installed version matches desired version
ansible.builtin.assert:
that:
that:
- nut_installed_version is defined
- nut_installed_version == "v2.8.2"

- name: Gather installed services
ansible.builtin.service_facts:

Expand All @@ -44,6 +44,6 @@

- name: Verify no NUT packages are installed
ansible.builtin.assert:
that:
that:
- ansible_facts.packages['nut-client'] is not defined
- ansible_facts.packages['nut-server'] is not defined
39 changes: 20 additions & 19 deletions molecule/switch_from_source_to_pkgmgr/converge.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
- name: Uninstall NUT
hosts: all
gather_facts: true
Expand All @@ -18,22 +19,22 @@
dest: "/etc/nut/dummy-ups2.dev"
mode: '0755'
roles:
- role: nut
nut_users:
- name: monitor
password: changeme
role: secondary
- name: second_user
password: insecure_password
role: primary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
- name: dummy_ups2
monitoruser: second_user
driver: dummy-ups
device: /etc/nut/dummy-ups2.dev
description: "Dummy UPS 2 for testing"
- role: nut

Check failure on line 22 in molecule/switch_from_source_to_pkgmgr/converge.yml

View workflow job for this annotation

GitHub Actions / Lint

syntax-check[specific]

the role 'nut' was not found in /home/runner/work/ansible-role-nut/ansible-role-nut/molecule/switch_from_source_to_pkgmgr/roles:/home/runner/.cache/ansible-compat/14eb40/roles:/home/runner/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles:/home/runner/work/ansible-role-nut/ansible-role-nut/molecule/switch_from_source_to_pkgmgr
nut_users:
- name: monitor
password: changeme
role: secondary
- name: second_user
password: insecure_password
role: primary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
- name: dummy_ups2
monitoruser: second_user
driver: dummy-ups
device: /etc/nut/dummy-ups2.dev
description: "Dummy UPS 2 for testing"
28 changes: 14 additions & 14 deletions molecule/switch_from_source_to_pkgmgr/prepare.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,17 @@
hosts: all
gather_facts: true
roles:
- role: nut
nut_install_from_source: false
nut_drivers:
- dummy-ups
nut_users:
- name: monitor
password: changeme
role: secondary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
- role: nut

Check failure on line 6 in molecule/switch_from_source_to_pkgmgr/prepare.yml

View workflow job for this annotation

GitHub Actions / Lint

syntax-check[specific]

the role 'nut' was not found in /home/runner/work/ansible-role-nut/ansible-role-nut/molecule/switch_from_source_to_pkgmgr/roles:/home/runner/.cache/ansible-compat/14eb40/roles:/home/runner/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles:/home/runner/work/ansible-role-nut/ansible-role-nut/molecule/switch_from_source_to_pkgmgr
nut_install_from_source: false
nut_drivers:
- dummy-ups
nut_users:
- name: monitor
password: changeme
role: secondary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
2 changes: 1 addition & 1 deletion molecule/switch_from_source_to_pkgmgr/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,6 @@

- name: Verify NUT packages are installed
ansible.builtin.assert:
that:
that:
- ansible_facts.packages['nut-client'] is defined
- ansible_facts.packages['nut-server'] is defined
5 changes: 3 additions & 2 deletions molecule/uninstall_from_pkgmgr/converge.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
- name: Converge part two
hosts: all
gather_facts: true
roles:
- role: nut
nut_state: absent
- role: nut

Check failure on line 6 in molecule/uninstall_from_pkgmgr/converge.yml

View workflow job for this annotation

GitHub Actions / Lint

syntax-check[specific]

the role 'nut' was not found in /home/runner/work/ansible-role-nut/ansible-role-nut/molecule/uninstall_from_pkgmgr/roles:/home/runner/.cache/ansible-compat/14eb40/roles:/home/runner/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles:/home/runner/work/ansible-role-nut/ansible-role-nut/molecule/uninstall_from_pkgmgr
nut_state: absent
38 changes: 19 additions & 19 deletions molecule/uninstall_from_pkgmgr/prepare.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,22 @@
dest: "/etc/nut/dummy-ups2.dev"
mode: '0755'
roles:
- role: nut
nut_users:
- name: monitor
password: changeme
role: secondary
- name: second_user
password: insecure_password
role: primary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
- name: dummy_ups2
monitoruser: second_user
driver: dummy-ups
device: /etc/nut/dummy-ups2.dev
description: "Dummy UPS 2 for testing"
- role: nut

Check failure on line 22 in molecule/uninstall_from_pkgmgr/prepare.yml

View workflow job for this annotation

GitHub Actions / Lint

syntax-check[specific]

the role 'nut' was not found in /home/runner/work/ansible-role-nut/ansible-role-nut/molecule/uninstall_from_pkgmgr/roles:/home/runner/.cache/ansible-compat/14eb40/roles:/home/runner/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles:/home/runner/work/ansible-role-nut/ansible-role-nut/molecule/uninstall_from_pkgmgr
nut_users:
- name: monitor
password: changeme
role: secondary
- name: second_user
password: insecure_password
role: primary
nut_ups:
- name: dummy_ups
monitoruser: monitor
driver: dummy-ups
device: /etc/nut/dummy-ups.dev
description: "Dummy UPS for testing"
- name: dummy_ups2
monitoruser: second_user
driver: dummy-ups
device: /etc/nut/dummy-ups2.dev
description: "Dummy UPS 2 for testing"
Loading

0 comments on commit 0745e40

Please sign in to comment.