Revive role

Update role to Leap 15.4 and switch molecule tests to internal
Dockerfiles instead of external test images.
This commit is contained in:
Felix Niederwanger 2022-06-27 16:45:31 +02:00
parent c9657a7a3c
commit 311ef3bf16
Signed by: phoenix
GPG key ID: 31860289A704FB3C
7 changed files with 38 additions and 7 deletions

View file

@ -5,6 +5,7 @@
Easy ansible role for setup of `grafana` with a custom backend. Currently only `influxdb` is supported. This ansible role works with
- openSUSE Leap 15.3
- openSUSE Leap 15.4
## Role Variables

View file

@ -1,6 +1,8 @@
---
galaxy_info:
author: Felix Niederwanger
role_name: nginx
namespace: grafana
description: Configurable grafana installation role
company: SUSE
issue_tracker_url: https://github.com/GeekOops/geekoops-grafana/issues

View file

@ -0,0 +1,7 @@
FROM registry.opensuse.org/opensuse/leap:15.3
# Install systemd and development tools, clear cache
RUN zypper in -y systemd systemd-sysvinit firewalld python3 python3-firewall curl && rm -rf /var/cache/* && rm -f /etc/machine-id /var/lib/dbus/machine-id
# Start container with systemd
ENTRYPOINT ["/usr/sbin/init"]

View file

@ -0,0 +1,7 @@
FROM registry.opensuse.org/opensuse/leap:15.4
# Install systemd and development tools, clear cache
RUN zypper in -y systemd systemd-sysvinit firewalld python3 python3-firewall curl && rm -rf /var/cache/* && rm -f /etc/machine-id /var/lib/dbus/machine-id
# Start container with systemd
ENTRYPOINT ["/usr/sbin/init"]

View file

@ -4,14 +4,23 @@ dependency:
driver:
name: docker
platforms:
- name: leap15_2
image: grisu48/leap-ansible
pre_build_image: true
- name: leap15_3
image: registry.opensuse.org/opensuse/leap:15.3
dockerfile: Dockerfile.leap15_3
command: ${MOLECULE_DOCKER_COMMAND:-"/usr/sbin/init"}
privileged: true
volumes:
- /sys/fs/cgroup:/sys/fs/cgroup:ro
capabilities:
- SYS_ADMIN
tmpfs:
- /run
- /tmp
- name: leap15_4
image: registry.opensuse.org/opensuse/leap:15.4
dockerfile: Dockerfile.leap15_4
command: ${MOLECULE_DOCKER_COMMAND:-"/usr/sbin/init"}
privileged: true
volumes:
- /sys/fs/cgroup:/sys/fs/cgroup:ro
tmpfs:
- /run
- /tmp
@ -19,8 +28,9 @@ provisioner:
name: ansible
inventory:
host_vars:
leap15_2:
ansible_python_interpreter: /usr/bin/python3
leap15_3:
influxdb: true
leap15_4:
influxdb: true
verifier:
name: testinfra

View file

@ -1,3 +1,5 @@
---
# openSUSE Leap 15.3 specific variables
packages_grafana: ['grafana', 'grafana-piechart-panel', 'grafana-status-panel']
packages_influxdb: ['influxdb']

View file

@ -1,3 +1,5 @@
---
# openSUSE Leap 15.3 specific variables
packages_grafana: ['grafana', 'grafana-piechart-panel', 'grafana-status-panel']
packages_influxdb: ['influxdb']