Skip to content

Commit

Permalink
Add amazon-2023-x86_64
Browse files Browse the repository at this point in the history
  • Loading branch information
yachub authored Sep 22, 2023
1 parent ea5de16 commit e4cb325
Show file tree
Hide file tree
Showing 7 changed files with 99 additions and 1 deletion.
3 changes: 3 additions & 0 deletions lib/beaker-hostgenerator/data.rb
Original file line number Diff line number Diff line change
Expand Up @@ -1098,6 +1098,9 @@ def generate_osinfo
yield ["freebsd#{release}-64", "freebsd-#{release}-amd64"]
end

# Amazon Linux
yield %w[amazon2023-64 amazon-2023-x86_64]

# AlmaLinux and Rocky
%w[almalinux rocky].each do |os|
(8..9).each do |release|
Expand Down
2 changes: 1 addition & 1 deletion lib/beaker-hostgenerator/hypervisor/abs.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ def generate_node(node_info, base_config, bhg_version)
case node_info['ostype']
when /^(almalinux|centos|oracle|redhat|rocky|scientific)/
base_config['template'] ||= base_config['platform'].gsub(/^el/, ::Regexp.last_match(1))
when /^fedora/, /^opensuse/, /^panos/
when /^amazon/, /^fedora/, /^opensuse/, /^panos/
base_config['template'] ||= base_config['platform']
when /^(debian|ubuntu)/
os = Regexp.last_match(1)
Expand Down
14 changes: 14 additions & 0 deletions test/fixtures/generated/default/amazon2023-64d
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
arguments_string: amazon2023-64d
environment_variables: {}
expected_hash:
HOSTS:
amazon2023-64-1:
platform: amazon-2023-x86_64
hypervisor: vmpooler
roles:
- agent
- database
CONFIG:
pooling_api: https://vmpooler-prod.k8s.infracore.puppet.net/
expected_exception:
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
---
arguments_string: amazon2023-64d-vro71-64-amazon2023-64c
environment_variables: {}
expected_hash:
HOSTS:
amazon2023-64-1:
platform: amazon-2023-x86_64
hypervisor: vmpooler
roles:
- agent
- database
vro71-64-1:
platform: sles-11-x86_64
template: vro-71-x86_64
hypervisor: vmpooler
roles:
- agent
amazon2023-64-2:
platform: amazon-2023-x86_64
hypervisor: vmpooler
roles:
- agent
- dashboard
CONFIG:
pooling_api: https://vmpooler-prod.k8s.infracore.puppet.net/
expected_exception:
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
---
arguments_string: vro71-64c-amazon2023-64-vro71-64d
environment_variables: {}
expected_hash:
HOSTS:
vro71-64-1:
platform: sles-11-x86_64
template: vro-71-x86_64
hypervisor: vmpooler
roles:
- agent
- dashboard
amazon2023-64-1:
platform: amazon-2023-x86_64
hypervisor: vmpooler
roles:
- agent
vro71-64-2:
platform: sles-11-x86_64
template: vro-71-x86_64
hypervisor: vmpooler
roles:
- agent
- database
CONFIG:
pooling_api: https://vmpooler-prod.k8s.infracore.puppet.net/
expected_exception:
14 changes: 14 additions & 0 deletions test/fixtures/generated/osinfo-version-0/amazon2023-64d
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
arguments_string: "--osinfo-version 0 amazon2023-64d"
environment_variables: {}
expected_hash:
HOSTS:
amazon2023-64-1:
platform: amazon-2023-x86_64
hypervisor: vmpooler
roles:
- agent
- database
CONFIG:
pooling_api: https://vmpooler-prod.k8s.infracore.puppet.net/
expected_exception:
14 changes: 14 additions & 0 deletions test/fixtures/generated/osinfo-version-1/amazon2023-64d
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
arguments_string: "--osinfo-version 1 amazon2023-64d"
environment_variables: {}
expected_hash:
HOSTS:
amazon2023-64-1:
platform: amazon-2023-x86_64
hypervisor: vmpooler
roles:
- agent
- database
CONFIG:
pooling_api: https://vmpooler-prod.k8s.infracore.puppet.net/
expected_exception:

0 comments on commit e4cb325

Please sign in to comment.