Github actions #10
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# @file rockylinux9.yml | |
--- | |
name: Tests on Rocky Linux 9 | |
# Trigger the workflow on push or pull request | |
on: [push, pull_request] | |
jobs: | |
help: | |
name: Launch plugin with --help | |
runs-on: ubuntu-latest | |
container: | |
image: rockylinux/rockylinux:9 | |
steps: | |
- uses: actions/checkout@v1 | |
- name: Enable EPEL | |
run: | | |
dnf install -y dnf-plugins-core | |
dnf config-manager --set-enabled crb | |
dnf install -y epel-release | |
- name: Install dependencies | |
run: | | |
dnf -y install nagios-plugins-perl perl-FindBin perl-lib | |
- name: Move Plugin to nagios-plugins dir | |
run: | | |
mv check_ro_mounts.pl /usr/lib64/nagios/plugins/ | |
- name: Launch plugin with --help | |
run: | | |
/usr/lib64/nagios/plugins/check_ro_mounts.pl --help | |
tests: | |
runs-on: ubuntu-latest | |
container: | |
image: rockylinux/rockylinux:9 | |
steps: | |
- uses: actions/checkout@v1 | |
- name: Enable EPEL | |
run: | | |
dnf install -y dnf-plugins-core | |
dnf config-manager --set-enabled crb | |
dnf install -y epel-release | |
- name: Install dependencies | |
run: | | |
dnf -y install nagios-plugins-perl perl-FindBin perl-lib | |
- name: Move Plugin to nagios-plugins dir | |
run: | | |
mv check_ro_mounts.pl /usr/lib64/nagios/plugins/ | |
- name: Execute in debug mode (should detect read-only mounts) | |
run: | | |
/usr/lib64/nagios/plugins/check_ro_mounts.pl -d | |
continue-on-error: true | |
- name: Execute with include overlay file system (should not detect any read-only mounts) | |
run: | | |
/usr/lib64/nagios/plugins/check_ro_mounts.pl -T overlay | |
- name: Execute with excluded file systems (should not detect any read-only mounts) | |
run: | | |
/usr/lib64/nagios/plugins/check_ro_mounts.pl -X tmpfs -X proc -X devpts -X sysfs -X cgroup -X cgroup2 -x "/dev/root /__e" |