aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorColin Wilk <colin.wilk@tum.de>2023-05-29 21:20:16 +0200
committerColin Wilk <colin.wilk@tum.de>2023-05-29 21:50:08 +0200
commit4565318b0f305a4872967672ab22426ac1c2bc44 (patch)
treec7a33147b8ee3465f64c9fbd87f847894a488a6a
parent6d6ef19c5b04660101530468e5dcc082604eee42 (diff)
downloadansible-role-prometheus-target-4565318b0f305a4872967672ab22426ac1c2bc44.tar.gz
ansible-role-prometheus-target-4565318b0f305a4872967672ab22426ac1c2bc44.zip
Add alpine, rockylinux and fedora to testing pipeline
Add more distros to CI/CD and include them in the galaxy meta file. Signed-off-by: Colin Wilk <colin.wilk@tum.de>
-rw-r--r--.github/workflows/ci.yml21
-rw-r--r--meta/main.yml12
-rw-r--r--molecule/default/Dockerfile.j225
3 files changed, 51 insertions, 7 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index d42b8b2..096e4ac 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -52,11 +52,32 @@ jobs:
distro:
- debian:10
- debian:11
+ - debian:latest
+ - debian:testing
+ - debian:unstable
- ubuntu:18.04
- ubuntu:20.04
- ubuntu:22.04
- ubuntu:23.04
+ - ubuntu:latest
+
+ - alpine:3.15
+ - alpine:3.16
+ - alpine:3.17
+ - alpine:3.18
+ - alpine:latest
+
+ - rockylinux:8
+ - rockylinux:9
+
+ - fedora:36
+ - fedora:37
+ - fedora:38
+ - fedora:39
+ - fedora:latest
+
+ - archlinux:latest
steps:
- name: Check out the codebase.
diff --git a/meta/main.yml b/meta/main.yml
index d25ab40..d4c098a 100644
--- a/meta/main.yml
+++ b/meta/main.yml
@@ -15,5 +15,17 @@ galaxy_info:
- name: Ubuntu
versions:
- all
+ - name: Alpine
+ versions:
+ - all
+ - name: Fedora
+ versions:
+ - all
+ - name: ArchLinux
+ versions:
+ - all
+ - name: EL
+ versions:
+ - all
galaxy_tags:
- prometheus
diff --git a/molecule/default/Dockerfile.j2 b/molecule/default/Dockerfile.j2
index 42750e4..74be8a0 100644
--- a/molecule/default/Dockerfile.j2
+++ b/molecule/default/Dockerfile.j2
@@ -1,12 +1,23 @@
FROM {{ item.image }}
# Install dependencies.
-RUN apt-get update \
- && apt-get install -y --no-install-recommends \
- sudo wget \
- python3-pip python3-dev python3-setuptools python3-wheel python3-apt \
- && rm -rf /var/lib/apt/lists/* \
- && rm -Rf /usr/share/doc && rm -Rf /usr/share/man \
- && apt-get clean
+RUN if [ $(command -v apt-get) ]; then \
+ apt-get update \
+ && apt-get install -y --no-install-recommends \
+ sudo wget \
+ python3-pip python3-dev python3-setuptools python3-wheel python3-apt \
+ && rm -rf /var/lib/apt/lists/* \
+ && rm -Rf /usr/share/doc && rm -Rf /usr/share/man \
+ && apt-get clean; \
+ elif [ $(command -v apk) ]; then \
+ apk update && apk add --no-cache python3 sudo bash ca-certificates; \
+ elif [ $(command -v yum) ]; then \
+ yum -y update && yum -y install sudo python3; \
+ elif [ $(command -v dnf) ]; then \
+ dnf makecache && dnf --assumeyes install \
+ python sudo python-devel python3-dnf bash iproute && dnf clean all; \
+ elif [ $(command -v pacman) ]; then \
+ pacman -Syu --noconfirm python3 sudo; \
+ fi
ENTRYPOINT ["bash", "-c", "sleep infinity"]