Skip to content

Allow downgrades using apt when version specified #266

Allow downgrades using apt when version specified

Allow downgrades using apt when version specified #266

Workflow file for this run

---
name: 'PR Tests'
on:
push:
branches:
- main
pull_request:
branches:
- main
env:
# Environment variables needed when running the task install scripts
# manually.
PT__installdir: ${{ github.workspace }}
jobs:
shellcheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install ShellCheck
run: sudo apt-get install shellcheck
- name: Run ShellCheck
run: shellcheck -x tasks/*.sh files/*.sh
test-install-task-on-ubuntu:
strategy:
matrix:
os-version:
- 22.04
- 24.04
runs-on: ${{ format('ubuntu-{0}', matrix.os-version) }}
needs: shellcheck
steps:
- uses: actions/checkout@v4
- id: install-bolt
uses: ./.github/actions/bolt
with:
os-version: ${{ matrix.os-version }}
- name: Run install task for openvox-agent
run: bolt task run openvox_bootstrap::install --targets localhost --run-as root
- name: Verify openvox-agent is installed
run: bolt task run openvox_bootstrap::check --targets localhost --run-as root
- name: Verify idempotency
run: bolt task run openvox_bootstrap::install --targets localhost --run-as root
test-install-task-on-other-os-via-containers:
strategy:
matrix:
image:
- almalinux:8
- almalinux:9
- almalinux:10
- rockylinux:8
- rockylinux:9
- rockylinux/rockylinux:10
- debian:11
- debian:12
- debian:13
- fedora:43
# Need to pull in the repo GPG keys for sles
# - registry.suse.com/suse/sle15:15.6
needs: shellcheck
runs-on: ubuntu-latest
container: ${{ matrix.image }}
steps:
- uses: actions/checkout@v4
with:
path: openvox_bootstrap
- id: prep
uses: ./openvox_bootstrap/.github/actions/container_task_prep
- name: Run install task manually for openvox-agent
env:
PT_collection: openvox8
run: ./openvox_bootstrap/tasks/install_linux.sh
- name: Verify openvox-agent is installed
env:
PT_version: '8'
PT_test: 'gt'
run: ./openvox_bootstrap/tasks/check_linux.sh
- name: Verify idempotency
env:
PT_collection: openvox8
run: ./openvox_bootstrap/tasks/install_linux.sh
test-install-version:
strategy:
matrix:
image:
- rockylinux/rockylinux:10
- fedora:43
- debian:13
- ubuntu:24.04
# Need to pull in the repo GPG keys for sles
# - registry.suse.com/suse/sle15:15.6
needs: shellcheck
runs-on: ubuntu-latest
container: ${{ matrix.image }}
steps:
- uses: actions/checkout@v4
with:
path: openvox_bootstrap
- id: prep
uses: ./openvox_bootstrap/.github/actions/container_task_prep
- name: Run install task manually for openvox-agent
env:
PT_version: "8.18.0"
run: ./openvox_bootstrap/tasks/install_linux.sh
- name: Verify openvox-agent is installed
env:
PT_version: "8.18.0"
run: ./openvox_bootstrap/tasks/check_linux.sh
- name: Verify idempotency
env:
PT_version: "8.18.0"
run: ./openvox_bootstrap/tasks/install_linux.sh
test-install-package:
strategy:
matrix:
image:
- rockylinux/rockylinux:10
# openvox-server not currently built for fedora
# - fedora:41
- debian:13
- ubuntu:24.04
# Need to pull in the repo GPG keys for sles
# - registry.suse.com/suse/sle15:15.6
needs: shellcheck
runs-on: ubuntu-latest
container: ${{ matrix.image }}
steps:
- uses: actions/checkout@v4
with:
path: openvox_bootstrap
- id: prep
uses: ./openvox_bootstrap/.github/actions/container_task_prep
- name: Run install task manually for openvox-server
env:
PT_package: "openvox-server"
run: ./openvox_bootstrap/tasks/install_linux.sh
- name: Verify openvox-server is installed
run: /opt/puppetlabs/bin/puppetserver --version | grep -E '8\.[0-9]+'
- name: Verify idempotency
env:
PT_package: "openvox-server"
run: ./openvox_bootstrap/tasks/install_linux.sh
test-install-package-version:
strategy:
matrix:
image:
- rockylinux/rockylinux:10
# openvox-server not currently built for fedora
#- fedora:41
- debian:13
- ubuntu:24.04
# Need to pull in the repo GPG keys for sles
# - registry.suse.com/suse/sle15:15.6
needs: shellcheck
runs-on: ubuntu-latest
container: ${{ matrix.image }}
steps:
- uses: actions/checkout@v4
with:
path: openvox_bootstrap
- id: prep
uses: ./openvox_bootstrap/.github/actions/container_task_prep
- name: Run install task manually for openvox-server
env:
PT_package: "openvox-server"
PT_version: "8.11.0"
run: ./openvox_bootstrap/tasks/install_linux.sh
- name: Verify openvox-server is installed
run: /opt/puppetlabs/bin/puppetserver --version | grep '8.11.0'
- name: Verify idempotency
env:
PT_package: "openvox-server"
PT_version: "8.11.0"
run: ./openvox_bootstrap/tasks/install_linux.sh
test-downgrade:
strategy:
matrix:
image:
- almalinux:8
- almalinux:9
- almalinux:10
- rockylinux:8
- rockylinux:9
- rockylinux/rockylinux:10
- debian:11
- debian:12
- debian:13
- fedora:43
# Need to pull in the repo GPG keys for sles
# - registry.suse.com/suse/sle15:15.6
needs: shellcheck
runs-on: ubuntu-latest
container: ${{ matrix.image }}
steps:
- uses: actions/checkout@v4
with:
path: openvox_bootstrap
- id: prep
uses: ./openvox_bootstrap/.github/actions/container_task_prep
- name: Install latest agent
env:
PT_collection: openvox8
run: ./openvox_bootstrap/tasks/install_linux.sh
- name: Verify later openvox-agent is installed
env:
PT_version: '8.18.0'
PT_test: 'gt'
run: ./openvox_bootstrap/tasks/check_linux.sh
- name: Install older version of agent
shell: bash
env:
PT_collection: openvox8
PT_version: "8.18.0"
run: ./openvox_bootstrap/tasks/install_linux.sh
- name: Verify openvox-agent is downgraded
env:
PT_version: "8.18.0"
run: ./openvox_bootstrap/tasks/check_linux.sh