Skip to content

Commit

Permalink
Add Ubuntu 22.04 support
Browse files Browse the repository at this point in the history
Add Ubuntu 22.04 in metadata.json
skip acceptance for zabbix version 5.0 because not supported

Fix voxpupuli#925
  • Loading branch information
Valantin committed Mar 7, 2024
1 parent 8242ce9 commit fcc628a
Show file tree
Hide file tree
Showing 9 changed files with 17 additions and 2 deletions.
3 changes: 2 additions & 1 deletion metadata.json
Expand Up @@ -124,7 +124,8 @@
{
"operatingsystem": "Ubuntu",
"operatingsystemrelease": [
"20.04"
"20.04",
"22.04"
]
},
{
Expand Down
2 changes: 2 additions & 0 deletions spec/acceptance/server_spec.rb
Expand Up @@ -43,6 +43,8 @@ class { 'zabbix::database': }
next if zabbix_version >= '5.2' && default[:platform] == 'el-7-x86_64'
# < 6.0 server packages are not available for RHEL 9
next if zabbix_version < '6.0' && default[:platform] == 'el-9-x86_64'
# <6.0 server packages are not available for ubuntu 22.04
next if zabbix_version < '6.0' && default[:platform] =~ %r{ubuntu-22}

context "deploys a zabbix #{zabbix_version} server" do
# Using puppet_apply as a helper
Expand Down
2 changes: 2 additions & 0 deletions spec/acceptance/zabbix_application_spec.rb
Expand Up @@ -9,6 +9,8 @@
next if zabbix_version >= '5.4'
# < 6.0 server packages are not available for RHEL 9
next if zabbix_version < '6.0' && default[:platform] == 'el-9-x86_64'
# <6.0 server packages are not available for ubuntu 22.04
next if zabbix_version < '6.0' && default[:platform] =~ %r{ubuntu-22}

template = case zabbix_version
when '5.0'
Expand Down
2 changes: 2 additions & 0 deletions spec/acceptance/zabbix_host_spec.rb
Expand Up @@ -10,6 +10,8 @@
next if zabbix_version >= '5.2' && default[:platform] == 'el-7-x86_64'
# < 6.0 server packages are not available for RHEL 9
next if zabbix_version < '6.0' && default[:platform] == 'el-9-x86_64'
# <6.0 server packages are not available for ubuntu 22.04
next if zabbix_version < '6.0' && default[:platform] =~ %r{ubuntu-22}

context "create zabbix_host resources with zabbix version #{zabbix_version}" do
# This will deploy a running Zabbix setup (server, web, db) which we can
Expand Down
2 changes: 2 additions & 0 deletions spec/acceptance/zabbix_hostgroup_spec.rb
Expand Up @@ -9,6 +9,8 @@
next if zabbix_version >= '5.2' && default[:platform] == 'el-7-x86_64'
# < 6.0 server packages are not available for RHEL 9
next if zabbix_version < '6.0' && default[:platform] == 'el-9-x86_64'
# <6.0 server packages are not available for ubuntu 22.04
next if zabbix_version < '6.0' && default[:platform] =~ %r{ubuntu-22}

context "create zabbix_hostgroup resources with zabbix version #{zabbix_version}" do
# This will deploy a running Zabbix setup (server, web, db) which we can
Expand Down
2 changes: 2 additions & 0 deletions spec/acceptance/zabbix_proxy_spec.rb
Expand Up @@ -10,6 +10,8 @@
next if zabbix_version >= '5.2' && default[:platform] == 'el-7-x86_64'
# < 6.0 server packages are not available for RHEL 9
next if zabbix_version < '6.0' && default[:platform] == 'el-9-x86_64'
# <6.0 server packages are not available for ubuntu 22.04
next if zabbix_version < '6.0' && default[:platform] =~ %r{ubuntu-22}

context "create zabbix_proxy resources with zabbix version #{zabbix_version}" do
# This will deploy a running Zabbix setup (server, web, db) which we can
Expand Down
2 changes: 2 additions & 0 deletions spec/acceptance/zabbix_template_host_spec.rb
Expand Up @@ -11,6 +11,8 @@
next if zabbix_version >= '5.2' && default[:platform] == 'el-7-x86_64'
# < 6.0 server packages are not available for RHEL 9
next if zabbix_version < '6.0' && default[:platform] == 'el-9-x86_64'
# <6.0 server packages are not available for ubuntu 22.04
next if zabbix_version < '6.0' && default[:platform] =~ %r{ubuntu-22}

context "create zabbix_template_host resources with zabbix version #{zabbix_version}" do
template = case zabbix_version
Expand Down
2 changes: 2 additions & 0 deletions spec/acceptance/zabbix_template_spec.rb
Expand Up @@ -9,6 +9,8 @@
next if zabbix_version >= '5.2' && default[:platform] == 'el-7-x86_64'
# < 6.0 server packages are not available for RHEL 9
next if zabbix_version < '6.0' && default[:platform] == 'el-9-x86_64'
# <6.0 server packages are not available for ubuntu 22.04
next if zabbix_version < '6.0' && default[:platform] =~ %r{ubuntu-22}

context "create zabbix_template resources with zabbix version #{zabbix_version}" do
# This will deploy a running Zabbix setup (server, web, db) which we can
Expand Down
2 changes: 1 addition & 1 deletion spec/spec_helper_methods.rb
Expand Up @@ -13,7 +13,7 @@ def baseline_os_hash
},
{
'operatingsystem' => 'Ubuntu',
'operatingsystemrelease' => %w[20.04]
'operatingsystemrelease' => %w[20.04 22.04]
},
{
'operatingsystem' => 'Archlinux',
Expand Down

0 comments on commit fcc628a

Please sign in to comment.