Skip to content

Commit

Permalink
Update cucumber testsuite module to match new naming
Browse files Browse the repository at this point in the history
  • Loading branch information
maximenoel8 committed Nov 11, 2024
1 parent c540e04 commit 3ff930b
Show file tree
Hide file tree
Showing 3 changed files with 64 additions and 64 deletions.
16 changes: 8 additions & 8 deletions README_ADVANCED.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ Note: on clients and minions only, the version number can be omitted to take the
A libvirt example follows:

```hcl
module "suse-minion" {
module "suse_minion" {
source = "./modules/minion"
base_configuration = module.base.configuration
Expand Down Expand Up @@ -108,7 +108,7 @@ ln -sfn ../backend_modules/<BACKEND> modules/backend
Some modules, for example clients and minions, support a `quantity` variable that allows you to create several instances at once. For example:

```hcl
module "suse-minion" {
module "suse_minion" {
source = "./modules/minion"
base_configuration = module.base.configuration
Expand Down Expand Up @@ -493,7 +493,7 @@ User root
You can specify an Activation Key string for minions to use at onboarding time to a SUSE Manager Server. An example follows:

```hcl
module "suse-minion" {
module "suse_minion" {
source = "./modules/minion"
base_configuration = module.base.configuration
Expand Down Expand Up @@ -526,7 +526,7 @@ module "proxy" {
server_configuration = module.server.configuration
}
module "suse-client" {
module "suse_client" {
source = "./modules/client"
base_configuration = module.base.configuration
Expand Down Expand Up @@ -626,7 +626,7 @@ Building Kiwi images is needed for starting PXE boot hosts (see below) in Retail
An example follows:

```hcl
module "build-host"
module "build_host"
{
source = "./modules/build_host"
base_configuration = module.base.configuration
Expand All @@ -649,7 +649,7 @@ They are connected only to the private network.
An example follows:

```hcl
module "pxeboot-minion"
module "pxeboot_minion"
{
source = "./modules/pxe_boot"
base_configuration = module.base.configuration
Expand Down Expand Up @@ -682,7 +682,7 @@ module "server" {
You can specify additional custom repos and packages to be installed at deploy time for a specific host:

```hcl
module "suse-minion" {
module "suse_minion" {
source = "./modules/minion"
base_configuration = module.base.configuration
Expand Down Expand Up @@ -977,7 +977,7 @@ module "cucumber_testsuite" {
A libvirt example is:

```hcl
module "opensuse155arm-minion" {
module "opensuse155arm_minion" {
source = "./modules/minion"
...
name = "nue-min-opensuse155arm"
Expand Down
28 changes: 14 additions & 14 deletions README_TESTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -112,11 +112,11 @@ host_settings = {
additional_packages = [ "venv-salt-minion" ]
install_salt_bundle = true
}
suse-client = {
suse_client = {
additional_packages = [ "venv-salt-minion" ]
install_salt_bundle = true
}
suse-minion = {
suse_minion = {
additional_packages = [ "venv-salt-minion" ]
install_salt_bundle = true
}
Expand All @@ -132,23 +132,23 @@ Several test hosts are optional and can be activated via a `host_settings` block
host_settings = {
proxy = {
}
suse-client = {
suse_client = {
}
suse-minion = {
suse_minion = {
}
suse-sshminion = {
suse_sshminion = {
}
redhat-minion = {
redhat_minion = {
}
debian-minion = {
debian_minion = {
}
build-host = {
build_host = {
}
pxeboot-minion = {
pxeboot_minion = {
}
kvm-host = {
kvm_host = {
}
monitoring-server = {
monitoring_server = {
}
}
```
Expand All @@ -157,9 +157,9 @@ The default value for `host_settings` block has a SUSE family traditional client

```hcl
host_settings = {
suse-client = {
suse_client = {
}
suse-minion = {
suse_minion = {
}
}
```
Expand Down Expand Up @@ -290,7 +290,7 @@ You may need to change the KVM image download. To do it, use the `additional_gra

```hcl
host_settings = {
kvm-host = {
kvm_host = {
additional_grains = {
hvm_disk_image = {
leap = {
Expand Down
84 changes: 42 additions & 42 deletions modules/cucumber_testsuite/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -230,20 +230,20 @@ module "proxy_containerized" {
database_disk_size = lookup(local.database_disk_size, "proxy_containerized", 0)
}

module "dhcp-dns" {
module "dhcp_dns" {
source = "../dhcp_dns"

quantity = contains(local.hosts, "dhcp-dns") ? 1 : 0
base_configuration = module.base.configuration
image = lookup(local.images, "dhcp-dns", "opensuse155o")
name = lookup(local.names, "dhcp-dns", "dhcp-dns")

private_hosts = [ local.proxy_configuration, module.pxeboot-minion.configuration ]
private_hosts = [ local.proxy_configuration, module.pxeboot_minion.configuration ]

hypervisor = lookup(local.hypervisors, "dhcp-dns", null)
}

module "suse-client" {
module "suse_client" {
source = "../client"

quantity = contains(local.hosts, "suse-client") ? 1 : 0
Expand All @@ -265,7 +265,7 @@ module "suse-client" {
provider_settings = lookup(local.provider_settings_by_host, "suse-client", {})
}

module "suse-minion" {
module "suse_minion" {
source = "../minion"

quantity = contains(local.hosts, "suse-minion") ? 1 : 0
Expand All @@ -288,7 +288,7 @@ module "suse-minion" {
provider_settings = lookup(local.provider_settings_by_host, "suse-minion", {})
}

module "suse-sshminion" {
module "suse_sshminion" {
source = "../sshminion"

quantity = contains(local.hosts, "suse-sshminion") ? 1 : 0
Expand All @@ -309,7 +309,7 @@ module "suse-sshminion" {
provider_settings = lookup(local.provider_settings_by_host, "suse-sshminion", {})
}

module "slemicro-minion" {
module "slemicro_minion" {
source = "../minion"

quantity = contains(local.hosts, "slemicro-minion") ? 1 : 0
Expand All @@ -331,7 +331,7 @@ module "slemicro-minion" {
provider_settings = lookup(local.provider_settings_by_host, "slemicro-minion", {})
}

module "redhat-minion" {
module "redhat_minion" {
source = "../minion"

quantity = contains(local.hosts, "redhat-minion") ? 1 : 0
Expand All @@ -353,7 +353,7 @@ module "redhat-minion" {
provider_settings = lookup(local.provider_settings_by_host, "redhat-minion", {})
}

module "debian-minion" {
module "debian_minion" {
source = "../minion"

quantity = contains(local.hosts, "debian-minion") ? 1 : 0
Expand All @@ -375,7 +375,7 @@ module "debian-minion" {
provider_settings = lookup(local.provider_settings_by_host, "debian-minion", {})
}

module "build-host" {
module "build_host" {
source = "../build_host"

quantity = contains(local.hosts, "build-host") ? 1 : 0
Expand All @@ -397,7 +397,7 @@ module "build-host" {
provider_settings = lookup(local.provider_settings_by_host, "build-host", {})
}

module "pxeboot-minion" {
module "pxeboot_minion" {
source = "../pxe_boot"

quantity = contains(local.hosts, "pxeboot-minion") ? 1 : 0
Expand All @@ -411,7 +411,7 @@ module "pxeboot-minion" {
provider_settings = lookup(local.provider_settings_by_host, "pxeboot-minion", {})
}

module "kvm-host" {
module "kvm_host" {
source = "../virthost"

quantity = contains(local.hosts, "kvm-host") ? 1 : 0
Expand All @@ -435,28 +435,28 @@ module "kvm-host" {
provider_settings = lookup(local.provider_settings_by_host, "kvm-host", {})
}

module "monitoring-server" {
module "monitoring_server" {
source = "../minion"

quantity = contains(local.hosts, "monitoring-server") ? 1 : 0
quantity = contains(local.hosts, "monitoring_server") ? 1 : 0

base_configuration = module.base.configuration
image = lookup(local.images, "monitoring-server", "sles15sp4o")
name = lookup(local.names, "monitoring-server", "min-monitoring")
image = lookup(local.images, "monitoring_server", "sles15sp4o")
name = lookup(local.names, "monitoring_server", "min-monitoring")

server_configuration = local.minimal_configuration
sles_registration_code = lookup(local.sles_registration_code, "monitoring-server", null)
sles_registration_code = lookup(local.sles_registration_code, "monitoring_server", null)

auto_connect_to_master = false
use_os_released_updates = true
ssh_key_path = "./salt/controller/id_rsa.pub"
install_salt_bundle = lookup(local.install_salt_bundle, "monitoring-server", false)
install_salt_bundle = lookup(local.install_salt_bundle, "monitoring_server", false)

additional_repos = lookup(local.additional_repos, "monitoring-server", {})
additional_repos_only = lookup(local.additional_repos_only, "monitoring-server", false)
additional_packages = lookup(local.additional_packages, "monitoring-server", [])
additional_grains = lookup(local.additional_grains, "monitoring-server", {})
provider_settings = lookup(local.provider_settings_by_host, "monitoring-server", {})
additional_repos = lookup(local.additional_repos, "monitoring_server", {})
additional_repos_only = lookup(local.additional_repos_only, "monitoring_server", false)
additional_packages = lookup(local.additional_packages, "monitoring_server", [])
additional_grains = lookup(local.additional_grains, "monitoring_server", {})
provider_settings = lookup(local.provider_settings_by_host, "monitoring_server", {})
}

module "controller" {
Expand All @@ -466,16 +466,16 @@ module "controller" {
base_configuration = module.base.configuration
server_configuration = local.server_configuration
proxy_configuration = local.proxy_configuration
client_configuration = contains(local.hosts, "suse-client") ? module.suse-client.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
minion_configuration = contains(local.hosts, "suse-minion") ? module.suse-minion.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
sshminion_configuration = contains(local.hosts, "suse-sshminion") ? module.suse-sshminion.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
slemicro_minion_configuration = contains(local.hosts, "slemicro-minion") ? module.slemicro-minion.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
redhat_configuration = contains(local.hosts, "redhat-minion") ? module.redhat-minion.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
debian_configuration = contains(local.hosts, "debian-minion") ? module.debian-minion.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
buildhost_configuration = contains(local.hosts, "build-host") ? module.build-host.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
pxeboot_configuration = contains(local.hosts, "pxeboot-minion") ? module.pxeboot-minion.configuration : { private_mac = null, private_ip = null, private_name = null, image = null }
kvmhost_configuration = contains(local.hosts, "kvm-host") ? module.kvm-host.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
monitoringserver_configuration = contains(local.hosts, "monitoring-server") ? module.monitoring-server.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
client_configuration = contains(local.hosts, "suse_client") ? module.suse_client.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
minion_configuration = contains(local.hosts, "suse_minion") ? module.suse_minion.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
sshminion_configuration = contains(local.hosts, "suse_sshminion") ? module.suse_sshminion.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
slemicro_minion_configuration = contains(local.hosts, "slemicro_minion") ? module.slemicro_minion.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
redhat_configuration = contains(local.hosts, "redhat_minion") ? module.redhat_minion.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
debian_configuration = contains(local.hosts, "debian_minion") ? module.debian_minion.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
buildhost_configuration = contains(local.hosts, "build_host") ? module.build_host.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
pxeboot_configuration = contains(local.hosts, "pxeboot_minion") ? module.pxeboot_minion.configuration : { private_mac = null, private_ip = null, private_name = null, image = null }
kvmhost_configuration = contains(local.hosts, "kvm_host") ? module.kvm_host.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }
monitoringserver_configuration = contains(local.hosts, "monitoring_server") ? module.monitoring_server.configuration : { hostnames = [], ids = [], ipaddrs = [], macaddrs = [], private_macs = [] }

branch = var.branch
git_username = var.git_username
Expand All @@ -501,16 +501,16 @@ output "configuration" {
base = module.base.configuration
server = var.container_server ? module.server_containerized[0].configuration : module.server[0].configuration
proxy = var.container_proxy ? module.proxy_containerized[0].configuration : module.proxy[0].configuration
suse-client = module.suse-client.configuration
slemicro-minion = module.slemicro-minion.configuration
suse-minion = module.suse-minion.configuration
suse-sshminion = module.suse-sshminion.configuration
redhat-minion = module.redhat-minion.configuration
debian-minion = module.debian-minion.configuration
build-host = module.build-host.configuration
pxeboot-minion = module.pxeboot-minion.configuration
kvm-host = module.kvm-host.configuration
monitoring-server = module.monitoring-server.configuration
suse_client = module.suse_client.configuration
slemicro_minion = module.slemicro_minion.configuration
suse_minion = module.suse_minion.configuration
suse_sshminion = module.suse_sshminion.configuration
redhat_minion = module.redhat_minion.configuration
debian_minion = module.debian_minion.configuration
build_host = module.build_host.configuration
pxeboot_minion = module.pxeboot_minion.configuration
kvm_host = module.kvm_host.configuration
monitoring_server = module.monitoring_server.configuration
controller = module.controller.configuration
}
}

0 comments on commit 3ff930b

Please sign in to comment.