1
0
mirror of https://github.com/pgbackrest/pgbackrest.git synced 2025-10-30 23:37:45 +02:00

Migrate CentOS 7 integration tests to Rocky 8.

CentOS 7 will be EOL on June 30 and since there is no CentOS 8 migrate instead to Rocky 8.
This commit is contained in:
David Steele
2024-06-11 15:20:04 +10:00
parent 4ac3b82c99
commit 886bb281f6
7 changed files with 24 additions and 19 deletions

View File

@@ -53,7 +53,7 @@ jobs:
- param: doc --vm=rh8
# All integration tests
- param: test --vm=rh7 --param=module=mock --param=module=integration
- param: test --vm=rh8 --param=module=mock --param=module=integration
steps:
- name: Checkout Code

View File

@@ -150,7 +150,7 @@ eval
if ($ARGV[0] eq 'doc')
{
if ($strVm eq VM_RH7 || $strVm eq VM_RH8)
if ($strVm eq VM_RH8)
{
processBegin('LaTeX install');
processExec(

View File

@@ -12,10 +12,13 @@
# - docker login -u pgbackrest
# - VM=XXX;DATE=YYYYMMDDX;BASE=pgbackrest/test:${VM?}-base;docker tag ${BASE?} ${BASE?}-${DATE?} && docker push ${BASE?}-${DATE?}
# **********************************************************************************************************************************
20240611A:
x86_64:
rh8: c3d005416527d96b5e8bcb1988c73c6f8557f48f
20240530A:
x86_64:
d10: 890b52c1c95ba3dc2d6a6535b8d9e8b273db275d
f40: c52b4f20349d8037d74a4a4543d2e33cd52bb3fa
u20: 9ac8fc879f2a7934b31d9e9df56a6a617be6cbed
u22: 3dc2ae79283af572ebe9d79c8c6a1086f9537233
rh7: bf93465740557a07914137ddc8a2156efde2646b

View File

@@ -321,7 +321,7 @@ sub entryPointSetup
if ($oVm->{$strOS}{&VM_OS_BASE} eq VM_OS_BASE_RHEL)
{
$strScript .= '/usr/sbin/sshd -D';
$strScript .= 'rm -rf /run/nologin && /usr/sbin/sshd -D';
}
else
{
@@ -388,10 +388,13 @@ sub containerBuild
if ($$oVm{$strOS}{&VM_OS_BASE} eq VM_OS_BASE_RHEL)
{
if ($strOS eq VM_RH7)
if ($strOS eq VM_RH8)
{
$strScript .=
" yum -y install centos-release-scl-rh epel-release && \\\n";
" dnf install -y dnf-plugins-core && \\\n" .
" dnf config-manager --set-enabled powertools && \\\n" .
" dnf -y install epel-release && \\\n" .
" crb enable && \\\n";
}
$strScript .=
@@ -481,12 +484,13 @@ sub containerBuild
$strScript .=
" rpm --import https://download.postgresql.org/pub/repos/yum/keys/RPM-GPG-KEY-PGDG && \\\n";
if ($strOS eq VM_RH7)
if ($strOS eq VM_RH8)
{
$strScript .=
" rpm -ivh \\\n" .
" https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-" . hostArch() . "/" .
"pgdg-redhat-repo-latest.noarch.rpm && \\\n";
" https://download.postgresql.org/pub/repos/yum/reporpms/EL-8-" . hostArch() . "/" .
"pgdg-redhat-repo-latest.noarch.rpm && \\\n" .
" dnf -qy module disable postgresql && \\\n";
}
elsif ($strOS eq VM_F40)
{

View File

@@ -76,8 +76,6 @@ use constant VM_NONE => 'none';
use constant VM_D10 => 'd10';
push @EXPORT, qw(VM_D10);
use constant VM_RH7 => 'rh7';
push @EXPORT, qw(VM_RH7);
use constant VM_RH8 => 'rh8';
push @EXPORT, qw(VM_RH8);
use constant VM_F40 => 'f40';
@@ -90,7 +88,7 @@ use constant VM_U22 => 'u22';
# VM aliases for run matrices (numbered oldest to newest)
use constant VM2 => VM_D10;
push @EXPORT, qw(VM2);
use constant VM3 => VM_RH7;
use constant VM3 => VM_RH8;
push @EXPORT, qw(VM3);
use constant VM4 => VM_U22;
push @EXPORT, qw(VM4);
@@ -148,11 +146,11 @@ my $oyVm =
],
},
# RHEL 7
&VM_RH7 =>
# RHEL 8
&VM_RH8 =>
{
&VM_OS_BASE => VM_OS_BASE_RHEL,
&VM_IMAGE => 'centos:7',
&VM_IMAGE => 'rockylinux/rockylinux:8',
&VM_ARCH => VM_ARCH_AMD64,
&VMDEF_PGSQL_BIN => '/usr/pgsql-{[version]}/bin',
@@ -161,11 +159,11 @@ my $oyVm =
&VM_DB =>
[
PG_VERSION_11,
PG_VERSION_12,
PG_VERSION_13,
PG_VERSION_14,
PG_VERSION_15,
PG_VERSION_16,
],
&VM_DB_TEST =>

View File

@@ -207,7 +207,7 @@
<p>Name of VM to run the test on.</p>
</text>
<example>rh7</example>
<example>rh8</example>
</option>
<option id="vm-id">

View File

@@ -107,7 +107,7 @@ test.pl [options]
--quiet, -q equivalent to --log-level=off
VM Options:
--vm docker container to build/test (e.g. rh7)
--vm docker container to build/test (e.g. rh8)
--vm-build build Docker containers
--vm-force force a rebuild of Docker containers
--vm-out Show VM output (default false)
@@ -917,7 +917,7 @@ eval
# Patch files in RHEL package builds
#
# Use these commands to create a new patch (may need to modify first line):
# BRDIR=/home/vagrant/pgbackrest;BRVM=rh7;BRPATCHFILE=${BRDIR?}/test/patch/rhel-package.patch
# BRDIR=/home/vagrant/pgbackrest;BRVM=rh8;BRPATCHFILE=${BRDIR?}/test/patch/rhel-package.patch
# PKDIR=${BRDIR?}/test/result/package/${BRVM}/SPECS
# diff -Naur ${PKDIR?}.old ${PKDIR}.new > ${BRPATCHFILE?}
my $strPackagePatch = "${strBackRestBase}/test/patch/rhel-package.patch";