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/data/common.yaml b/data/common.yaml index a016b0b..f80c8b5 100644 --- a/data/common.yaml +++ b/data/common.yaml @@ -31,4 +31,4 @@ thumbor::statefile: 'thumbor.version' thumbor::update_enabled: true thumbor::user: 'thumbor' thumbor::version: 'present' -thumbor::venv_path: ~ +thumbor::venv_path: /opt/thumbor diff --git a/manifests/install.pp b/manifests/install.pp index 143c689..a64718e 100644 --- a/manifests/install.pp +++ b/manifests/install.pp @@ -18,7 +18,7 @@ before => [Python::Pip[$thumbor::package_name], Python::Pip[[$thumbor::plugins]]], } } - ensure_packages($thumbor::additional_packages) + stdlib::ensure_packages($thumbor::additional_packages) $venv = $thumbor::venv_path ? { undef => 'system', diff --git a/metadata.json b/metadata.json index 35b74cc..e9e1a90 100644 --- a/metadata.json +++ b/metadata.json @@ -40,14 +40,16 @@ { "operatingsystem": "Debian", "operatingsystemrelease": [ - "11" + "11", + "12" ] }, { "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'] diff --git a/spec/acceptance/thumbor_spec.rb b/spec/acceptance/thumbor_spec.rb index 65def4b..72dcd9e 100644 --- a/spec/acceptance/thumbor_spec.rb +++ b/spec/acceptance/thumbor_spec.rb @@ -5,10 +5,10 @@ apply_manifest(%( # be_listening() tests will fail if `ss` is not installed. if ($facts['os']['family'] == 'RedHat') and (versioncmp($facts['os']['release']['major'], '8') >= 0) { - ensure_packages('iproute') + stdlib::ensure_packages('iproute') } # cURL is needed to send requests to Thumbor - ensure_packages('curl') + stdlib::ensure_packages('curl') ), catch_failures: true) end context 'with default parameters' do @@ -33,7 +33,7 @@ it 'responds to requests' do # Thumbor may take a while to start up - sleep(5) + sleep(15) # Use the test image from Thumbor's documentation run_shell('curl -v http://localhost:8000/unsafe/300x200/https%3A%2F%2Fgithub.com%2Fthumbor%2Fthumbor%2Fraw%2Fmaster%2Fexample.jpg --output /dev/null') do |r| expect(r.stderr).to match(%r{200 OK}) diff --git a/spec/classes/thumbor_spec.rb b/spec/classes/thumbor_spec.rb index d5b6a22..586def0 100644 --- a/spec/classes/thumbor_spec.rb +++ b/spec/classes/thumbor_spec.rb @@ -31,8 +31,8 @@ } end - it { is_expected.to contain_file('/etc/thumbor.key').with(mode: '0600') } - it { is_expected.to contain_file('/etc/thumbor.key').with_content(%r{AAAAABBBBCCCCC111112222233333}) } + it { is_expected.to contain_file('/opt/thumbor/thumbor.key').with(mode: '0600') } + it { is_expected.to contain_file('/opt/thumbor/thumbor.key').with_content(%r{AAAAABBBBCCCCC111112222233333}) } end context 'when setting config' do @@ -46,9 +46,9 @@ } end - it { is_expected.to contain_file('/etc/thumbor.conf').with_content(%r{AUTO_WEBP = True}) } - it { is_expected.to contain_file('/etc/thumbor.conf').with_content(%r{ENGINE_THREADPOOL_SIZE = 4}) } - it { is_expected.to contain_file('/etc/thumbor.conf').with_content(%r{HTTP_LOADER_MAX_CLIENTS = 1024}) } + it { is_expected.to contain_file('/opt/thumbor/thumbor.conf').with_content(%r{AUTO_WEBP = True}) } + it { is_expected.to contain_file('/opt/thumbor/thumbor.conf').with_content(%r{ENGINE_THREADPOOL_SIZE = 4}) } + it { is_expected.to contain_file('/opt/thumbor/thumbor.conf').with_content(%r{HTTP_LOADER_MAX_CLIENTS = 1024}) } end context 'when setting ports' do @@ -65,17 +65,6 @@ end end - context 'when declaring manage_python is false' do - let(:params) do - { - manage_python: false - } - end - - it { is_expected.to contain_class('thumbor::python') } - it { is_expected.not_to contain_class('python') } - end - context 'when setting venv_path' do let(:params) do {