From 054400329c3df330f106003ab6b0249f92530163 Mon Sep 17 00:00:00 2001 From: Tim Meusel Date: Fri, 4 Aug 2023 15:35:19 +0200 Subject: [PATCH] Add OracleLinux 8 & 9 support --- lib/beaker-hostgenerator/data.rb | 4 ++-- lib/beaker-hostgenerator/hypervisor/docker.rb | 2 +- test/fixtures/per-host-settings/docker-regex-validation.yaml | 3 +++ 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/lib/beaker-hostgenerator/data.rb b/lib/beaker-hostgenerator/data.rb index 60538fa8..cdc87314 100644 --- a/lib/beaker-hostgenerator/data.rb +++ b/lib/beaker-hostgenerator/data.rb @@ -1084,9 +1084,9 @@ def generate_osinfo end end - # Oracle + # Oracle / OracleLinux yield ['oracle6-32', 'el-6-i386'] - (6..7).each do |release| + (6..9).each do |release| yield ["oracle#{release}-64", "el-#{release}-x86_64"] end diff --git a/lib/beaker-hostgenerator/hypervisor/docker.rb b/lib/beaker-hostgenerator/hypervisor/docker.rb index f6a150fb..5f180b56 100644 --- a/lib/beaker-hostgenerator/hypervisor/docker.rb +++ b/lib/beaker-hostgenerator/hypervisor/docker.rb @@ -49,7 +49,7 @@ def image(ostype) def image_commands(ostype) case ostype - when /^(almalinux|centos|rocky)/ + when /^(almalinux|centos|rocky|oracle)/ [ 'cp /bin/true /sbin/agetty', el_package_install_command(ostype.delete_prefix(Regexp.last_match(1)).to_i), diff --git a/test/fixtures/per-host-settings/docker-regex-validation.yaml b/test/fixtures/per-host-settings/docker-regex-validation.yaml index 47f8db70..b1822dbd 100644 --- a/test/fixtures/per-host-settings/docker-regex-validation.yaml +++ b/test/fixtures/per-host-settings/docker-regex-validation.yaml @@ -10,6 +10,9 @@ expected_hash: hypervisor: docker roles: - agent + docker_image_commands: + - cp /bin/true /sbin/agetty + - yum install -y crontabs initscripts iproute openssl wget which sysvinit-tools tar ss opensuse15-64-1: docker_cmd: - "/sbin/init"