Skip to content

Commit

Permalink
Added/removed OS'es for Molecule (#167)
Browse files Browse the repository at this point in the history
  • Loading branch information
dj-wasabi authored Jan 30, 2023
1 parent 8c66582 commit 8ac7c14
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 5 deletions.
12 changes: 8 additions & 4 deletions .github/workflows/telegraf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,12 @@ jobs:
fail-fast: false
matrix:
molecule_distro:
- container: centos8
image: geerlingguy/docker-centos8-ansible:latest
- container: centos7
image: geerlingguy/docker-centos7-ansible:latest
- container: rocky8
image: geerlingguy/docker-rockylinux8-ansible
# - container: rocky9
# image: geerlingguy/docker-rockylinux9-ansible
- container: ubuntu2004
image: geerlingguy/docker-ubuntu2004-ansible:latest
- container: ubuntu1804
Expand All @@ -39,8 +41,10 @@ jobs:
image: geerlingguy/docker-ubuntu1604-ansible:latest
- container: debian9
image: geerlingguy/docker-debian9-ansible:latest
- container: debian8
image: geerlingguy/docker-debian8-ansible:latest
- container: debian10
image: geerlingguy/docker-debian10-ansible:latest
- container: debian11
image: geerlingguy/docker-debian11-ansible:latest
steps:
- name: Check out code
uses: actions/checkout@v1
Expand Down
14 changes: 13 additions & 1 deletion molecule/default/prepare.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,21 @@
- ansible_os_family == 'RedHat'

- name: "Apt get update"
shell: apt-get update && apt-get install -y python-apt
shell: apt-get update
when:
- ansible_os_family == 'Debian'

- name: "Installing packages on Debian"
apt:
name:
- wget
- "{{ 'gnupg-agent' if ansible_distribution_major_version in ['8', '18', '16'] else 'gpg-agent' }}"
update_cache: True
state: present
when:
- ansible_os_family == 'Debian'
- ansible_distribution_major_version not in [9, 10]

- name: "Installing packages on Debian"
apt:
name:
Expand All @@ -24,6 +35,7 @@
state: present
when:
- ansible_os_family == 'Debian'
- ansible_distribution_major_version in [9, 10]

- name: "Installing packages on Suse"
zypper:
Expand Down

0 comments on commit 8ac7c14

Please sign in to comment.