From 533a595cf9d033679449178b8838ed62aa19376e Mon Sep 17 00:00:00 2001 From: Lightning Date: Tue, 23 Jul 2024 13:56:55 +0200 Subject: [PATCH 1/2] update os support and workflow/testing environment --- .github/workflows/ci.yaml | 6 +++--- metadata.json | 3 ++- provision.yaml | 16 +++++++++++----- 3 files changed, 16 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 6dcb018..1b20c86 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -16,7 +16,7 @@ jobs: puppet_version: [7] name: Check / Puppet ${{ matrix.puppet_version }} - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 container: puppet/pdk:latest steps: @@ -39,11 +39,11 @@ jobs: strategy: fail-fast: false matrix: - os: ['rocky8', 'ub2204', 'deb11'] + os: ['rocky8', 'ub2004', 'ub2204', 'ub2404', 'deb11', 'deb12'] puppet_version: [7] name: Acceptance / ${{ matrix.os }} / Puppet ${{ matrix.puppet_version }} - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 needs: - check diff --git a/metadata.json b/metadata.json index 7e6cbc5..e8a98a4 100644 --- a/metadata.json +++ b/metadata.json @@ -49,7 +49,8 @@ "operatingsystem": "Ubuntu", "operatingsystemrelease": [ "20.04", - "22.04" + "22.04", + "24.04" ] } ], diff --git a/provision.yaml b/provision.yaml index d4611bd..446157a 100644 --- a/provision.yaml +++ b/provision.yaml @@ -1,24 +1,24 @@ --- default: provisioner: docker_exp - images: ['waffleimage/centos7'] + images: ['litmusimage/rockylinux:8'] vagrant: provisioner: vagrant - images: ['centos/7', 'generic/ubuntu2004'] + images: ['centos/8', 'generic/ubuntu2404'] deb_all: provisioner: docker - images: ['litmusimage/debian:10', 'litmusimage/debian:11'] + images: ['litmusimage/debian:11', 'litmusimage/debian:12'] el_all: provisioner: docker - images: ['litmusimage/centos:7', 'litmusimage/centos:8'] + images: ['litmusimage/centos:7', 'litmusimage/rockylinux:8'] # The most reliable workaround for the docker/systemd incompatibility. # see https://github.com/docker/for-linux/issues/835 # see https://github.com/moby/moby/issues/38749 vars: '{docker_run_opts: ["-v /sys/fs/cgroup:/sys/fs/cgroup:ro"]}' ub_all: provisioner: docker - images: ['litmusimage/ubuntu:20.04', 'litmusimage/ubuntu:22.04'] + images: ['litmusimage/ubuntu:20.04', 'litmusimage/ubuntu:22.04', 'litmusimage/ubuntu:24.04'] gha_deb10: provisioner: docker @@ -26,6 +26,9 @@ gha_deb10: gha_deb11: provisioner: docker images: ['litmusimage/debian:11'] +gha_deb12: + provisioner: docker + images: ['litmusimage/debian:12'] gha_el7: provisioner: docker images: ['litmusimage/centos:7'] @@ -53,3 +56,6 @@ gha_ub2004: gha_ub2204: provisioner: docker images: ['litmusimage/ubuntu:22.04'] +gha_ub2404: + provisioner: docker + images: ['litmusimage/ubuntu:24.04'] From 4fff273f18698562fd2c9ef25b30b0cf6451d715 Mon Sep 17 00:00:00 2001 From: Lightning Date: Tue, 23 Jul 2024 16:50:16 +0200 Subject: [PATCH 2/2] fix unit tests --- spec/spec_helper_acceptance_local.rb | 31 +++++++++++++++++++--------- 1 file changed, 21 insertions(+), 10 deletions(-) diff --git a/spec/spec_helper_acceptance_local.rb b/spec/spec_helper_acceptance_local.rb index 0118b12..95235d9 100644 --- a/spec/spec_helper_acceptance_local.rb +++ b/spec/spec_helper_acceptance_local.rb @@ -24,15 +24,26 @@ def setup_webserver MANIFEST if os[:family].eql?('debian') - php_extensions = <<-MANIFEST - gd => {}, - json => {}, - pdo => {}, - pgsql => {}, - mysqlnd => {}, - posix => {}, - sqlite3 => {}, - MANIFEST + php_extensions = if os[:release].to_i >= 12 + <<-MANIFEST + gd => {}, + pdo => {}, + pgsql => {}, + mysqlnd => {}, + posix => {}, + sqlite3 => {}, + MANIFEST + else + <<-MANIFEST + gd => {}, + json => {}, + pdo => {}, + pgsql => {}, + mysqlnd => {}, + posix => {}, + sqlite3 => {}, + MANIFEST + end end if os[:family].eql?('ubuntu') @@ -137,7 +148,7 @@ class { 'apache::mod::fcgid': } apache::vhost { 'bacula_web': - servername => $fqdn, + servername => $facts['networking']['fqdn'], port => 80, docroot => '/var/www/html/bacula-web/public', manage_docroot => false,