diff --git a/jenkins_pipelines/environments/common/pipeline-pull-request.groovy b/jenkins_pipelines/environments/common/pipeline-pull-request.groovy index 8ca6cd0ce..3eb049d89 100644 --- a/jenkins_pipelines/environments/common/pipeline-pull-request.groovy +++ b/jenkins_pipelines/environments/common/pipeline-pull-request.groovy @@ -17,6 +17,10 @@ def run(params) { jenkins_workspace = '/home/jenkins/jenkins-build/workspace/' environment_workspace = null env.common_params = '' + tfvariables_file = 'susemanager-ci/terracumber_config/tf_files/variables/PR-testing-variables.tf' + tfvars_product_version = "susemanager-ci/terracumber_config/tf_files/tfvars/PR-testing-${product_version}.tfvars" + tfvars_platform_localisation = "susemanager-ci/terracumber_config/tf_files/tfvars/PR-testing-${platform_localisation}-environments.tfvars" + tf_local_variables = 'susemanager-ci/terracumber_config/tf_files/tfvars/PR-testing-additionnal-repos.tf' try { stage('Get environment') { echo "DEBUG: first environment: ${first_env}" @@ -205,8 +209,8 @@ def run(params) { // Define test environment parameters env.resultdir = "${WORKSPACE}/results" env.resultdirbuild = "${resultdir}/${BUILD_NUMBER}" - env.tf_file = "susemanager-ci/terracumber_config/tf_files/${product_name}-PR-tests-env${env_number}.tf" //TODO: Make it possible to use environments for SUMA - env.common_params = "--outputdir ${resultdir} --tf ${tf_file} --gitfolder ${resultdir}/sumaform" + env.tf_file = "susemanager-ci/terracumber_config/tf_files/PR-testing-template.tf" + env.common_params = "--outputdir ${resultdir} --tf ${tf_file} --gitfolder ${resultdir}/sumaform --tf_variables_description_file=${tfvariables_file}" if (params.terraform_parallelism) { env.common_params = "${env.common_params} --parallelism ${params.terraform_parallelism}" @@ -228,27 +232,38 @@ def run(params) { echo "DEBUG: Deploy 1" ws(environment_workspace){ if(must_test) { + // Delete old terraform.tfvars + sh "rm -f ${env.resultdir}/sumaform/terraform.tfvars" + // Merge product en platform variables into terraform.tfvars + sh "cat ${tfvars_product_version} ${tfvars_platform_localisation} >> ${env.resultdir}/sumaform/terraform.tfvars" + // Add environment to use in tfvars + sh "echo 'ENVIRONMENT = \'${env_number}\'' >> ${env.resultdir}/sumaform/terraform.tfvars" + // Copy the variable declaration file + sh "cp ${tf_local_variables} ${env.resultdir}/sumaform/" + + // Add all repositories variables // Passing the built repository by parameter using a environment variable to terraform file // TODO: We will need to add a logic to replace the host, when we use IBS for spacewalk - env.PULL_REQUEST_REPO= "http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${builder_project}:${pull_request_number}/${build_repo}/${arch}" - env.MASTER_REPO = "http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${source_project}/${build_repo}/${arch}" - env.MASTER_OTHER_REPO = "http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${other_project}/${other_build_repo}/${arch}" - env.MASTER_SUMAFORM_TOOLS_REPO = "http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${sumaform_tools_project}/${build_repo}/${arch}" - env.TEST_PACKAGES_REPO = "http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${test_packages_project}/rpm/${arch}" - env.UPDATE_REPO = update_repo + sh "echo \"############ Repositories variables ############\" >> ${env.resultdir}/sumaform/terraform.tfvars" + sh "echo PULL_REQUEST_REPO = \\\"http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${builder_project}:${pull_request_number}/${build_repo}/${arch}\\\" >> ${env.resultdir}/sumaform/terraform.tfvars" + sh "echo MASTER_REPO = \\\"http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${source_project}/${build_repo}/${arch}\\\" >> ${env.resultdir}/sumaform/terraform.tfvars" + sh "echo MASTER_OTHER_REPO = \\\"http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${other_project}/${other_build_repo}/${arch}\\\" >> ${env.resultdir}/sumaform/terraform.tfvars" + sh "echo MASTER_SUMAFORM_TOOLS_REPO = \\\"http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${sumaform_tools_project}/${build_repo}/${arch}\\\" >> ${env.resultdir}/sumaform/terraform.tfvars" + sh "echo TEST_PACKAGES_REPO = \\\"http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${test_packages_project}/rpm/${arch}\\\" >> ${env.resultdir}/sumaform/terraform.tfvars" + sh "echo UPDATE_REPO = \\\"${update_repo}\\\" >> ${env.resultdir}/sumaform/terraform.tfvars" if (additional_repo_url == '') { echo "Adding dummy repo for update repo" - env.ADDITIONAL_REPO_URL = additional_repo + sh "echo ADDITIONAL_REPO_URL = \\\"${additional_repo}\\\" >> ${env.resultdir}/sumaform/terraform.tfvars" } else { echo "Adding ${additional_repo_url}" - env.ADDITIONAL_REPO_URL = additional_repo_url + sh "echo ADDITIONAL_REPO_URL = \\\"${additional_repo_url}\\\" >> ${env.resultdir}/sumaform/terraform.tfvars" } - env.SLE_CLIENT_REPO = "http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${sles_client_repo}/SLE_15/${arch}" - env.RHLIKE_CLIENT_REPO = "http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${el_client_repo}/${EL}/${arch}" - env.DEBLIKE_CLIENT_REPO = "http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${ubuntu_client_repo}/xUbuntu_22.04/${arch}" - env.OPENSUSE_CLIENT_REPO = "http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${openSUSE_client_repo}/openSUSE_Leap_15.0/${arch}" + sh "echo SLE_CLIENT_REPO = \\\"http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${sles_client_repo}/SLE_15/${arch}\\\" >> ${env.resultdir}/sumaform/terraform.tfvars" + sh "echo RHLIKE_CLIENT_REPO = \\\"http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${el_client_repo}/${EL}/${arch}\\\" >> ${env.resultdir}/sumaform/terraform.tfvars" + sh "echo DEBLIKE_CLIENT_REPO = \\\"http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${ubuntu_client_repo}/xUbuntu_22.04/${arch}\\\" >> ${env.resultdir}/sumaform/terraform.tfvars" + sh "echo OPENSUSE_CLIENT_REPO = \\\"http://${fqdn_jenkins_node}/workspace/${short_product_name}-pr${env_number}/repos/${openSUSE_client_repo}/openSUSE_Leap_15.0/${arch}\\\" >> ${env.resultdir}/sumaform/terraform.tfvars" // Provision the environment if (terraform_init) { @@ -256,10 +271,7 @@ def run(params) { } else { env.TERRAFORM_INIT = '' } - - echo "DEBUG: Deploy 5" - sh "set +x; source /home/jenkins/.credentials set -x; export TF_VAR_SLE_CLIENT_REPO=${SLE_CLIENT_REPO};export TF_VAR_RHLIKE_CLIENT_REPO=${RHLIKE_CLIENT_REPO};export TF_VAR_DEBLIKE_CLIENT_REPO=${DEBLIKE_CLIENT_REPO};export TF_VAR_OPENSUSE_CLIENT_REPO=${OPENSUSE_CLIENT_REPO};export TF_VAR_PULL_REQUEST_REPO=${PULL_REQUEST_REPO}; export TF_VAR_MASTER_OTHER_REPO=${MASTER_OTHER_REPO};export TF_VAR_MASTER_SUMAFORM_TOOLS_REPO=${MASTER_SUMAFORM_TOOLS_REPO}; export TF_VAR_TEST_PACKAGES_REPO=${TEST_PACKAGES_REPO}; export TF_VAR_MASTER_REPO=${MASTER_REPO};export TF_VAR_UPDATE_REPO=${UPDATE_REPO};export TF_VAR_ADDITIONAL_REPO_URL=${ADDITIONAL_REPO_URL};export TF_VAR_CUCUMBER_GITREPO=${cucumber_gitrepo}; export TF_VAR_CUCUMBER_BRANCH=${cucumber_ref}; export TERRAFORM=${terraform_bin}; export TERRAFORM_PLUGINS=${terraform_bin_plugins}; ./terracumber-cli ${common_params} --logfile ${resultdirbuild}/sumaform.log ${env.TERRAFORM_INIT} --taint '.*(domain|main_disk).*' --runstep provision" - echo "DEBUG: Deploy 6" + sh "set +x; source /home/jenkins/.credentials set -x; export TF_VAR_CUCUMBER_GITREPO=${cucumber_gitrepo}; export TF_VAR_CUCUMBER_BRANCH=${cucumber_ref}; export TERRAFORM=${terraform_bin}; export TERRAFORM_PLUGINS=${terraform_bin_plugins}; ./terracumber-cli ${common_params} --logfile ${resultdirbuild}/sumaform.log ${env.TERRAFORM_INIT} --taint '.*(domain|main_disk).*' --runstep provision" deployed = true // Collect and tag Flaky tests from the GitHub Board diff --git a/jenkins_pipelines/environments/uyuni-prs-ci-tests b/jenkins_pipelines/environments/uyuni-prs-ci-tests index 7630a02be..78b92595d 100644 --- a/jenkins_pipelines/environments/uyuni-prs-ci-tests +++ b/jenkins_pipelines/environments/uyuni-prs-ci-tests @@ -4,6 +4,8 @@ node('pull-request-test') { properties([ buildDiscarder(logRotator(numToKeepStr: '30', daysToKeepStr: '15')), parameters([ + string(name: 'platform_localisation', defaultValue: 'PRV', description: 'Decide if it will be run in \'PRV\' or \'NUE\''), + string(name: 'product_version', defaultValue: 'uyuni', description: 'Select if we are using \'uyuni\' or \'manager43\' project'), string(name: 'pull_request_number', defaultValue: '', description: 'Required: Uyuni Pull Request Number'), string(name: 'email_to', defaultValue: '', description: 'Recommended: Receive a report to your e-mail when it finishes with links to the results, artifacts and logs'), booleanParam(name: 'run_all_scopes', defaultValue: false, description: 'Secondary tests: Check to run all functional scopes. List of secondary tests: https://github.com/uyuni-project/uyuni/blob/master/testsuite/features/secondary/ '), diff --git a/terracumber_config/tf_files/PR-testing-template.tf b/terracumber_config/tf_files/PR-testing-template.tf new file mode 100644 index 000000000..097cdb816 --- /dev/null +++ b/terracumber_config/tf_files/PR-testing-template.tf @@ -0,0 +1,211 @@ +terraform { + required_version = "1.0.10" + required_providers { + libvirt = { + source = "dmacvicar/libvirt" + version = "0.6.3" + } + } +} + +provider "libvirt" { + uri = "qemu+tcp://${var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].hypervisor}/system" +} + +module "cucumber_testsuite" { + source = "./modules/cucumber_testsuite" + + product_version = var.PRODUCT_VERSION + + // Cucumber repository configuration for the controller + git_username = var.GIT_USER + git_password = var.GIT_PASSWORD + git_repo = var.CUCUMBER_GITREPO + branch = var.CUCUMBER_BRANCH + + cc_username = var.SCC_USER + cc_password = var.SCC_PASSWORD + mirror = var.MIRROR + use_mirror_images = var.USE_MIRROR_IMAGES + + images = var.IMAGES + + use_avahi = false + name_prefix = "suma-pr${var.ENVIRONMENT}-" + domain = var.DOMAIN + from_email = "root@suse.de" + + no_auth_registry = "registry.${var.DOMAIN}" + auth_registry = "registry.${var.DOMAIN}:5000/cucutest" + auth_registry_username = "cucutest" + auth_registry_password = "cucusecret" + git_profiles_repo = var.GIT_PROFILES_REPO + + server_http_proxy = "http-proxy.${var.DOMAIN}:3128" + custom_download_endpoint = "ftp://${var.DOWNLOAD_ENDPOINT}:445" + + # when changing images, please also keep in mind to adjust the image matrix at the end of the README. + host_settings = { + controller = { + provider_settings = { + mac = var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].mac["controller"] + vcpu = 2 + memory = 2048 + } + } + server = { + provider_settings = { + mac = var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].mac["server"] + vcpu = 8 + memory = 32768 + } + additional_repos_only = var.ADDITIONAL_REPOS_ONLY + additional_repos = local.additional_repos["server"] + image = var.IMAGE + additional_packages = [ "venv-salt-minion" ] + install_salt_bundle = true + server_mounted_mirror = var.MIRROR + } + proxy = { + provider_settings = { + mac = var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].mac["proxy"] + vcpu = 2 + memory = 2048 + } + additional_repos_only = var.ADDITIONAL_REPOS_ONLY + additional_repos = local.additional_repos["proxy"] + image = var.IMAGE + additional_packages = [ "venv-salt-minion" ] + install_salt_bundle = true + } + suse-minion = { + image = var.SUSE_MINION_IMAGE + name = "min-suse" + provider_settings = { + mac = var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].mac["suse-minion"] + vcpu = 2 + memory = 2048 + } + additional_repos = local.additional_repos["suse-minion"] + additional_packages = [ "venv-salt-minion" ] + install_salt_bundle = true + } + suse-sshminion = { + image = var.SUSE_MINION_IMAGE + name = "minssh-suse" + provider_settings = { + mac = var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].mac["suse-sshminion"] + vcpu = 2 + memory = 2048 + } + additional_repos = local.additional_repos["suse-minion"] + additional_packages = [ "venv-salt-minion", "iptables" ] + install_salt_bundle = true + } + redhat-minion = { + image = var.RHLIKE_MINION_IMAGE + name = "min-rocky8" + provider_settings = { + mac = var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].mac["rhlike-minion"] + memory = 2048 + vcpu = 2 + } + additional_repos = { + client_repo = var.RHLIKE_CLIENT_REPO, + } + additional_packages = [ "venv-salt-minion" ] + install_salt_bundle = true + } + debian-minion = { + image = var.DEBLIKE_MINION_IMAGE + name = "min-ubuntu2204" + provider_settings = { + mac = var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].mac["deblike-minion"] + vcpu = 2 + memory = 2048 + } + additional_repos = { + client_repo = var.DEBLIKE_CLIENT_REPO, + } + additional_packages = [ "venv-salt-minion" ] + // FIXME: cloudl-init fails if venv-salt-minion is not avaiable + // We can set "install_salt_bundle = true" as soon as venv-salt-minion is available Uyuni:Stable + install_salt_bundle = true + } + build-host = { + image = "sles15sp4o" + name = "min-build" + provider_settings = { + mac = var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].mac["build-host"] + memory = 2048 + } + additional_repos = { + tools_update_pr = var.SLE_CLIENT_REPO + } + additional_packages = [ "venv-salt-minion" ] + install_salt_bundle = true + } + pxeboot-minion = { + image = "sles15sp4o" + additional_repos = { + tools_update_pr = var.SLE_CLIENT_REPO + } + additional_packages = [ "venv-salt-minion" ] + install_salt_bundle = true + } + kvm-host = { + image = var.IMAGE + name = "min-kvm" + additional_grains = { + hvm_disk_image = { + leap = { + hostname = "suma-pr${var.ENVIRONMENT}-min-nested" + image = "http://${var.DOWNLOAD_ENDPOINT}/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2" + hash = "http://${var.DOWNLOAD_ENDPOINT}/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2.sha256" + } + sles = { + hostname = "suma-pr${var.ENVIRONMENT}-min-nested" + image = "http://${var.DOWNLOAD_ENDPOINT}/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2" + hash = "http://${var.DOWNLOAD_ENDPOINT}/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2.sha256" + } + } + } + provider_settings = { + mac = var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].mac["kvm-host"] + } + additional_repos_only = var.ADDITIONAL_REPOS_ONLY + additional_repos = local.additional_repos["kvm-host"] + additional_packages = [ "venv-salt-minion", "mkisofs" ] + install_salt_bundle = true + } + } + nested_vm_host = "suma-pr${var.ENVIRONMENT}-min-nested" + nested_vm_mac = var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].mac["nested-vm"] + provider_settings = { + pool = var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].pool + network_name = null + bridge = var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].bridge + additional_network = var.ENVIRONMENT_CONFIGURATION[var.ENVIRONMENT].additional_network + } +} + + +resource "null_resource" "add_test_information" { + triggers = { + always_run = "${timestamp()}" + } + provisioner "file" { + source = "../../susemanager-ci/terracumber_config/scripts/set_custom_header.sh" + destination = "/tmp/set_custom_header.sh" + connection { + type = "ssh" + user = "root" + password = "linux" + host = "${module.cucumber_testsuite.configuration.server.hostname}" + } + } +} + +output "configuration" { + value = module.cucumber_testsuite.configuration +} diff --git a/terracumber_config/tf_files/Uyuni-PR-tests-env1.tf b/terracumber_config/tf_files/Uyuni-PR-tests-env1.tf deleted file mode 100644 index 59095d22d..000000000 --- a/terracumber_config/tf_files/Uyuni-PR-tests-env1.tf +++ /dev/null @@ -1,368 +0,0 @@ -// Mandatory variables for terracumber -variable "URL_PREFIX" { - type = string - default = "https://ci.suse.de/view/Manager/view/Uyuni/job/uyuni-prs-ci-tests" -} - -// Not really used as this is for --runall parameter, and we run cucumber step by step -variable "CUCUMBER_COMMAND" { - type = string - default = "export PRODUCT='Uyuni' && run-testsuite" -} - -variable "CUCUMBER_GITREPO" { - type = string - default = "https://github.com/uyuni-project/uyuni.git" -} - -variable "CUCUMBER_BRANCH" { - type = string - default = "master" -} - -variable "CUCUMBER_RESULTS" { - type = string - default = "/root/spacewalk/testsuite" -} - -variable "MAIL_SUBJECT" { - type = string - default = "$status acceptance tests on Pull Request: $tests scenarios ($failures failed, $errors errors, $skipped skipped, $passed passed)" -} - -variable "MAIL_TEMPLATE" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request.txt" -} - -variable "MAIL_SUBJECT_ENV_FAIL" { - type = string - default = "Failed acceptance tests on Pull Request: Environment setup failed" -} - -variable "MAIL_TEMPLATE_ENV_FAIL" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request-env-fail.txt" -} - -variable "ENVIRONMENT" { - type = string - default = "1" -} - -variable "HYPER" { - type = string - default = "romulus.mgr.prv.suse.net" -} - -variable "MAIL_FROM" { - type = string - default = "jenkins@suse.de" -} - -variable "MAIL_TO" { - type = string - default = "galaxy-ci@suse.de" -} - -// sumaform specific variables -variable "SCC_USER" { - type = string -} - -variable "SCC_PASSWORD" { - type = string -} - -variable "GIT_USER" { - type = string - default = null // Not needed for master, as it is public -} - -variable "GIT_PASSWORD" { - type = string - default = null // Not needed for master, as it is public -} - -// Repository containing the build for the tested Uyuni Pull Request -variable "PULL_REQUEST_REPO" { - type = string -} - -variable "MASTER_REPO" { - type = string -} - -variable "MASTER_OTHER_REPO" { - type = string -} - -variable "MASTER_SUMAFORM_TOOLS_REPO" { - type = string -} - -variable "UPDATE_REPO" { - type = string -} - -variable "ADDITIONAL_REPO_URL" { - type = string -} - -variable "TEST_PACKAGES_REPO" { - type = string -} - -// Repositories containing the client tools RPMs -variable "SLE_CLIENT_REPO" { - type = string -} - -variable "RHLIKE_CLIENT_REPO" { - type = string -} - -variable "DEBLIKE_CLIENT_REPO" { - type = string -} - -variable "OPENSUSE_CLIENT_REPO" { - type = string -} - -terraform { - required_version = "1.0.10" - required_providers { - libvirt = { - source = "dmacvicar/libvirt" - version = "0.6.3" - } - } -} - - -provider "libvirt" { - uri = "qemu+tcp://${var.HYPER}/system" -} - -module "cucumber_testsuite" { - source = "./modules/cucumber_testsuite" - - product_version = "uyuni-pr" - - // Cucumber repository configuration for the controller - git_username = var.GIT_USER - git_password = var.GIT_PASSWORD - git_repo = var.CUCUMBER_GITREPO - branch = var.CUCUMBER_BRANCH - - cc_username = var.SCC_USER - cc_password = var.SCC_PASSWORD - mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - use_mirror_images = true - - images = ["rocky8o", "opensuse154o", "opensuse155o", "opensuse155-ci-pro", "ubuntu2204o", "sles15sp4o"] - - use_avahi = false - name_prefix = "suma-pr${var.ENVIRONMENT}-" - domain = "mgr.prv.suse.net" - from_email = "root@suse.de" - - no_auth_registry = "registry.mgr.prv.suse.net" - auth_registry = "registry.mgr.prv.suse.net:5000/cucutest" - auth_registry_username = "cucutest" - auth_registry_password = "cucusecret" - git_profiles_repo = "https://github.com/uyuni-project/uyuni.git#:testsuite/features/profiles/internal_prv" - - server_http_proxy = "http-proxy.mgr.prv.suse.net:3128" - custom_download_endpoint = "ftp://minima-mirror-ci-bv.mgr.prv.suse.net:445" - - # when changing images, please also keep in mind to adjust the image matrix at the end of the README. - host_settings = { - controller = { - provider_settings = { - mac = "aa:b2:92:04:00:00" - } - } - server = { - provider_settings = { - mac = "aa:b2:92:04:00:01" - memory = 16384 - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - server_mounted_mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - } - proxy = { - provider_settings = { - mac = "aa:b2:92:04:00:02" - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - proxy_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Uyuni-Proxy-POOL-x86_64-Media1/", - tools_update = var.OPENSUSE_CLIENT_REPO - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-minion = { - image = "opensuse155o" - name = "min-suse" - provider_settings = { - mac = "aa:b2:92:04:00:04" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-sshminion = { - image = "opensuse155o" - name = "minssh-suse" - provider_settings = { - mac = "aa:b2:92:04:00:05" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion", "iptables" ] - install_salt_bundle = true - } - redhat-minion = { - image = "rocky8o" - name = "min-rhlike" - provider_settings = { - mac = "aa:b2:92:04:00:06" - memory = 2048 - vcpu = 2 - } - additional_repos = { - client_repo = var.RHLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - debian-minion = { - image = "ubuntu2204o" - name = "min-deblike" - provider_settings = { - mac = "aa:b2:92:04:00:07" - } - additional_repos = { - client_repo = var.DEBLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - build-host = { - image = "sles15sp4o" - name = "min-build" - provider_settings = { - mac = "aa:b2:92:04:00:09" - memory = 2048 - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - pxeboot-minion = { - image = "sles15sp4o" - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - kvm-host = { - image = "opensuse155-ci-pro" - name = "min-kvm" - additional_grains = { - hvm_disk_image = { - leap = { - hostname = "suma-pr1-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2.sha256" - } - sles = { - hostname = "suma-pr1-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2.sha256" - } - } - } - provider_settings = { - mac = "aa:b2:92:04:00:0a" - } - additional_repos_only = true - additional_repos = { - client_repo = var.OPENSUSE_CLIENT_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - } - additional_packages = [ "venv-salt-minion", "mkisofs" ] - install_salt_bundle = true - } - } - nested_vm_host = "suma-pr1-min-nested" - nested_vm_mac = "aa:b2:92:04:00:0b" - provider_settings = { - pool = "ssd" - network_name = null - bridge = "br1" - additional_network = "192.168.101.0/24" - } -} - - -resource "null_resource" "add_test_information" { - triggers = { - always_run = "${timestamp()}" - } - provisioner "file" { - source = "../../susemanager-ci/terracumber_config/scripts/set_custom_header.sh" - destination = "/tmp/set_custom_header.sh" - connection { - type = "ssh" - user = "root" - password = "linux" - host = "${module.cucumber_testsuite.configuration.server.hostname}" - } - } -} - - -output "configuration" { - value = module.cucumber_testsuite.configuration -} diff --git a/terracumber_config/tf_files/Uyuni-PR-tests-env10.tf b/terracumber_config/tf_files/Uyuni-PR-tests-env10.tf deleted file mode 100644 index 8bf5293d6..000000000 --- a/terracumber_config/tf_files/Uyuni-PR-tests-env10.tf +++ /dev/null @@ -1,368 +0,0 @@ -// Mandatory variables for terracumber -variable "URL_PREFIX" { - type = string - default = "https://ci.suse.de/view/Manager/view/Uyuni/job/uyuni-prs-ci-tests" -} - -// Not really used as this is for --runall parameter, and we run cucumber step by step -variable "CUCUMBER_COMMAND" { - type = string - default = "export PRODUCT='Uyuni' && run-testsuite" -} - -variable "CUCUMBER_GITREPO" { - type = string - default = "https://github.com/uyuni-project/uyuni.git" -} - -variable "CUCUMBER_BRANCH" { - type = string - default = "master" -} - -variable "CUCUMBER_RESULTS" { - type = string - default = "/root/spacewalk/testsuite" -} - -variable "MAIL_SUBJECT" { - type = string - default = "$status acceptance tests on Pull Request: $tests scenarios ($failures failed, $errors errors, $skipped skipped, $passed passed)" -} - -variable "MAIL_TEMPLATE" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request.txt" -} - -variable "MAIL_SUBJECT_ENV_FAIL" { - type = string - default = "Failed acceptance tests on Pull Request: Environment setup failed" -} - -variable "MAIL_TEMPLATE_ENV_FAIL" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request-env-fail.txt" -} - -variable "ENVIRONMENT" { - type = string - default = "10" -} - -variable "HYPER" { - type = string - default = "mojito.mgr.prv.suse.net" -} - -variable "MAIL_FROM" { - type = string - default = "jenkins@suse.de" -} - -variable "MAIL_TO" { - type = string - default = "galaxy-ci@suse.de" -} - -// sumaform specific variables -variable "SCC_USER" { - type = string -} - -variable "SCC_PASSWORD" { - type = string -} - -variable "GIT_USER" { - type = string - default = null // Not needed for master, as it is public -} - -variable "GIT_PASSWORD" { - type = string - default = null // Not needed for master, as it is public -} - -// Repository containing the build for the tested Uyuni Pull Request -variable "PULL_REQUEST_REPO" { - type = string -} - -variable "MASTER_REPO" { - type = string -} - -variable "MASTER_OTHER_REPO" { - type = string -} - -variable "MASTER_SUMAFORM_TOOLS_REPO" { - type = string -} - -variable "UPDATE_REPO" { - type = string -} - -variable "ADDITIONAL_REPO_URL" { - type = string -} - -variable "TEST_PACKAGES_REPO" { - type = string -} - -// Repositories containing the client tools RPMs -variable "SLE_CLIENT_REPO" { - type = string -} - -variable "RHLIKE_CLIENT_REPO" { - type = string -} - -variable "DEBLIKE_CLIENT_REPO" { - type = string -} - -variable "OPENSUSE_CLIENT_REPO" { - type = string -} - -terraform { - required_version = "1.0.10" - required_providers { - libvirt = { - source = "dmacvicar/libvirt" - version = "0.6.3" - } - } -} - - -provider "libvirt" { - uri = "qemu+tcp://${var.HYPER}/system" -} - -module "cucumber_testsuite" { - source = "./modules/cucumber_testsuite" - - product_version = "uyuni-pr" - - // Cucumber repository configuration for the controller - git_username = var.GIT_USER - git_password = var.GIT_PASSWORD - git_repo = var.CUCUMBER_GITREPO - branch = var.CUCUMBER_BRANCH - - cc_username = var.SCC_USER - cc_password = var.SCC_PASSWORD - mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - use_mirror_images = true - - images = ["rocky8o", "opensuse154o", "opensuse155o", "opensuse155-ci-pro", "ubuntu2204o", "sles15sp4o"] - - use_avahi = false - name_prefix = "suma-pr${var.ENVIRONMENT}-" - domain = "mgr.prv.suse.net" - from_email = "root@suse.de" - - no_auth_registry = "registry.mgr.prv.suse.net" - auth_registry = "registry.mgr.prv.suse.net:5000/cucutest" - auth_registry_username = "cucutest" - auth_registry_password = "cucusecret" - git_profiles_repo = "https://github.com/uyuni-project/uyuni.git#:testsuite/features/profiles/internal_prv" - - server_http_proxy = "http-proxy.mgr.prv.suse.net:3128" - custom_download_endpoint = "ftp://minima-mirror-ci-bv.mgr.prv.suse.net:445" - - # when changing images, please also keep in mind to adjust the image matrix at the end of the README. - host_settings = { - controller = { - provider_settings = { - mac = "aa:b2:92:04:00:90" - } - } - server = { - provider_settings = { - mac = "aa:b2:92:04:00:91" - memory = 16384 - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - server_mounted_mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - } - proxy = { - provider_settings = { - mac = "aa:b2:92:04:00:92" - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - proxy_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Uyuni-Proxy-POOL-x86_64-Media1/", - tools_update = var.OPENSUSE_CLIENT_REPO - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-minion = { - image = "opensuse155o" - name = "min-suse" - provider_settings = { - mac = "aa:b2:92:04:00:94" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-sshminion = { - image = "opensuse155o" - name = "minssh-suse" - provider_settings = { - mac = "aa:b2:92:04:00:95" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion", "iptables" ] - install_salt_bundle = true - } - redhat-minion = { - image = "rocky8o" - name = "min-rhlike" - provider_settings = { - mac = "aa:b2:92:04:00:96" - memory = 2048 - vcpu = 2 - } - additional_repos = { - client_repo = var.RHLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - debian-minion = { - image = "ubuntu2204o" - name = "min-deblike" - provider_settings = { - mac = "aa:b2:92:04:00:97" - } - additional_repos = { - client_repo = var.DEBLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - build-host = { - image = "sles15sp4o" - name = "min-build" - provider_settings = { - mac = "aa:b2:92:04:00:99" - memory = 2048 - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - pxeboot-minion = { - image = "sles15sp4o" - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - kvm-host = { - image = "opensuse155-ci-pro" - name = "min-kvm" - additional_grains = { - hvm_disk_image = { - leap = { - hostname = "suma-pr10-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2.sha256" - } - sles = { - hostname = "suma-pr10-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2.sha256" - } - } - } - provider_settings = { - mac = "aa:b2:92:04:00:9a" - } - additional_repos_only = true - additional_repos = { - client_repo = var.OPENSUSE_CLIENT_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - } - additional_packages = [ "venv-salt-minion", "mkisofs" ] - install_salt_bundle = true - } - } - nested_vm_host = "suma-pr10-min-nested" - nested_vm_mac = "aa:b2:92:04:00:9b" - provider_settings = { - pool = "default" - network_name = null - bridge = "br0" - additional_network = "192.168.110.0/24" - } -} - - -resource "null_resource" "add_test_information" { - triggers = { - always_run = "${timestamp()}" - } - provisioner "file" { - source = "../../susemanager-ci/terracumber_config/scripts/set_custom_header.sh" - destination = "/tmp/set_custom_header.sh" - connection { - type = "ssh" - user = "root" - password = "linux" - host = "${module.cucumber_testsuite.configuration.server.hostname}" - } - } -} - - -output "configuration" { - value = module.cucumber_testsuite.configuration -} diff --git a/terracumber_config/tf_files/Uyuni-PR-tests-env2.tf b/terracumber_config/tf_files/Uyuni-PR-tests-env2.tf deleted file mode 100644 index a9a4308a6..000000000 --- a/terracumber_config/tf_files/Uyuni-PR-tests-env2.tf +++ /dev/null @@ -1,368 +0,0 @@ -// Mandatory variables for terracumber -variable "URL_PREFIX" { - type = string - default = "https://ci.suse.de/view/Manager/view/Uyuni/job/uyuni-prs-ci-tests" -} - -// Not really used as this is for --runall parameter, and we run cucumber step by step -variable "CUCUMBER_COMMAND" { - type = string - default = "export PRODUCT='Uyuni' && run-testsuite" -} - -variable "CUCUMBER_GITREPO" { - type = string - default = "https://github.com/uyuni-project/uyuni.git" -} - -variable "CUCUMBER_BRANCH" { - type = string - default = "master" -} - -variable "CUCUMBER_RESULTS" { - type = string - default = "/root/spacewalk/testsuite" -} - -variable "MAIL_SUBJECT" { - type = string - default = "$status acceptance tests on Pull Request: $tests scenarios ($failures failed, $errors errors, $skipped skipped, $passed passed)" -} - -variable "MAIL_TEMPLATE" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request.txt" -} - -variable "MAIL_SUBJECT_ENV_FAIL" { - type = string - default = "Failed acceptance tests on Pull Request: Environment setup failed" -} - -variable "MAIL_TEMPLATE_ENV_FAIL" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request-env-fail.txt" -} - -variable "ENVIRONMENT" { - type = string - default="2" -} - -variable "HYPER" { - type = string - default = "romulus.mgr.prv.suse.net" -} - -variable "MAIL_FROM" { - type = string - default = "jenkins@suse.de" -} - -variable "MAIL_TO" { - type = string - default = "galaxy-ci@suse.de" -} - -// sumaform specific variables -variable "SCC_USER" { - type = string -} - -variable "SCC_PASSWORD" { - type = string -} - -variable "GIT_USER" { - type = string - default = null // Not needed for master, as it is public -} - -variable "GIT_PASSWORD" { - type = string - default = null // Not needed for master, as it is public -} - -// Repository containing the build for the tested Uyuni Pull Request -variable "PULL_REQUEST_REPO" { - type = string -} - -variable "MASTER_REPO" { - type = string -} - -variable "MASTER_OTHER_REPO" { - type = string -} - -variable "MASTER_SUMAFORM_TOOLS_REPO" { - type = string -} - -variable "UPDATE_REPO" { - type = string -} - -variable "ADDITIONAL_REPO_URL" { - type = string -} - -variable "TEST_PACKAGES_REPO" { - type = string -} - -// Repositories containing the client tools RPMs -variable "SLE_CLIENT_REPO" { - type = string -} - -variable "RHLIKE_CLIENT_REPO" { - type = string -} - -variable "DEBLIKE_CLIENT_REPO" { - type = string -} - -variable "OPENSUSE_CLIENT_REPO" { - type = string -} - -terraform { - required_version = "1.0.10" - required_providers { - libvirt = { - source = "dmacvicar/libvirt" - version = "0.6.3" - } - } -} - - -provider "libvirt" { - uri = "qemu+tcp://${var.HYPER}/system" -} - -module "cucumber_testsuite" { - source = "./modules/cucumber_testsuite" - - product_version = "uyuni-pr" - - // Cucumber repository configuration for the controller - git_username = var.GIT_USER - git_password = var.GIT_PASSWORD - git_repo = var.CUCUMBER_GITREPO - branch = var.CUCUMBER_BRANCH - - cc_username = var.SCC_USER - cc_password = var.SCC_PASSWORD - mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - use_mirror_images = true - - images = ["rocky8o", "opensuse154o", "opensuse155o", "opensuse155-ci-pro", "ubuntu2204o", "sles15sp4o"] - - use_avahi = false - name_prefix = "suma-pr${var.ENVIRONMENT}-" - domain = "mgr.prv.suse.net" - from_email = "root@suse.de" - - no_auth_registry = "registry.mgr.prv.suse.net" - auth_registry = "registry.mgr.prv.suse.net:5000/cucutest" - auth_registry_username = "cucutest" - auth_registry_password = "cucusecret" - git_profiles_repo = "https://github.com/uyuni-project/uyuni.git#:testsuite/features/profiles/internal_prv" - - server_http_proxy = "http-proxy.mgr.prv.suse.net:3128" - custom_download_endpoint = "ftp://minima-mirror-ci-bv.mgr.prv.suse.net:445" - - # when changing images, please also keep in mind to adjust the image matrix at the end of the README. - host_settings = { - controller = { - provider_settings = { - mac = "aa:b2:92:04:00:10" - } - } - server = { - provider_settings = { - mac = "aa:b2:92:04:00:11" - memory = 16384 - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - server_mounted_mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - } - proxy = { - provider_settings = { - mac = "aa:b2:92:04:00:12" - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - proxy_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Uyuni-Proxy-POOL-x86_64-Media1/", - tools_update = var.OPENSUSE_CLIENT_REPO - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-minion = { - image = "opensuse155o" - name = "min-suse" - provider_settings = { - mac = "aa:b2:92:04:00:14" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-sshminion = { - image = "opensuse155o" - name = "minssh-suse" - provider_settings = { - mac = "aa:b2:92:04:00:15" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion", "iptables" ] - install_salt_bundle = true - } - redhat-minion = { - image = "rocky8o" - name = "min-rhlike" - provider_settings = { - mac = "aa:b2:92:04:00:16" - memory = 2048 - vcpu = 2 - } - additional_repos = { - client_repo = var.RHLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - debian-minion = { - image = "ubuntu2204o" - name = "min-deblike" - provider_settings = { - mac = "aa:b2:92:04:00:17" - } - additional_repos = { - client_repo = var.DEBLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - build-host = { - image = "sles15sp4o" - name = "min-build" - provider_settings = { - mac = "aa:b2:92:04:00:19" - memory = 2048 - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - pxeboot-minion = { - image = "sles15sp4o" - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - kvm-host = { - image = "opensuse155-ci-pro" - name = "min-kvm" - additional_grains = { - hvm_disk_image = { - leap = { - hostname = "suma-pr2-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2.sha256" - } - sles = { - hostname = "suma-pr2-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2.sha256" - } - } - } - provider_settings = { - mac = "aa:b2:92:04:00:1a" - } - additional_repos_only = true - additional_repos = { - client_repo = var.OPENSUSE_CLIENT_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - } - additional_packages = [ "venv-salt-minion", "mkisofs" ] - install_salt_bundle = true - } - } - nested_vm_host = "suma-pr2-min-nested" - nested_vm_mac = "aa:b2:92:04:00:1b" - provider_settings = { - pool = "ssd" - network_name = null - bridge = "br1" - additional_network = "192.168.102.0/24" - } -} - - -resource "null_resource" "add_test_information" { - triggers = { - always_run = "${timestamp()}" - } - provisioner "file" { - source = "../../susemanager-ci/terracumber_config/scripts/set_custom_header.sh" - destination = "/tmp/set_custom_header.sh" - connection { - type = "ssh" - user = "root" - password = "linux" - host = "${module.cucumber_testsuite.configuration.server.hostname}" - } - } -} - - -output "configuration" { - value = module.cucumber_testsuite.configuration -} diff --git a/terracumber_config/tf_files/Uyuni-PR-tests-env3.tf b/terracumber_config/tf_files/Uyuni-PR-tests-env3.tf deleted file mode 100644 index 4c3dcfd6b..000000000 --- a/terracumber_config/tf_files/Uyuni-PR-tests-env3.tf +++ /dev/null @@ -1,368 +0,0 @@ -// Mandatory variables for terracumber -variable "URL_PREFIX" { - type = string - default = "https://ci.suse.de/view/Manager/view/Uyuni/job/uyuni-prs-ci-tests" -} - -// Not really used as this is for --runall parameter, and we run cucumber step by step -variable "CUCUMBER_COMMAND" { - type = string - default = "export PRODUCT='Uyuni' && run-testsuite" -} - -variable "CUCUMBER_GITREPO" { - type = string - default = "https://github.com/uyuni-project/uyuni.git" -} - -variable "CUCUMBER_BRANCH" { - type = string - default = "master" -} - -variable "CUCUMBER_RESULTS" { - type = string - default = "/root/spacewalk/testsuite" -} - -variable "MAIL_SUBJECT" { - type = string - default = "$status acceptance tests on Pull Request: $tests scenarios ($failures failed, $errors errors, $skipped skipped, $passed passed)" -} - -variable "MAIL_TEMPLATE" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request.txt" -} - -variable "MAIL_SUBJECT_ENV_FAIL" { - type = string - default = "Failed acceptance tests on Pull Request: Environment setup failed" -} - -variable "MAIL_TEMPLATE_ENV_FAIL" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request-env-fail.txt" -} - -variable "ENVIRONMENT" { - type = string - default = "3" -} - -variable "HYPER" { - type = string - default = "vulcan.mgr.prv.suse.net" -} - -variable "MAIL_FROM" { - type = string - default = "jenkins@suse.de" -} - -variable "MAIL_TO" { - type = string - default = "galaxy-ci@suse.de" -} - -// sumaform specific variables -variable "SCC_USER" { - type = string -} - -variable "SCC_PASSWORD" { - type = string -} - -variable "GIT_USER" { - type = string - default = null // Not needed for master, as it is public -} - -variable "GIT_PASSWORD" { - type = string - default = null // Not needed for master, as it is public -} - -// Repository containing the build for the tested Uyuni Pull Request -variable "PULL_REQUEST_REPO" { - type = string -} - -variable "MASTER_REPO" { - type = string -} - -variable "MASTER_OTHER_REPO" { - type = string -} - -variable "MASTER_SUMAFORM_TOOLS_REPO" { - type = string -} - -variable "UPDATE_REPO" { - type = string -} - -variable "ADDITIONAL_REPO_URL" { - type = string -} - -variable "TEST_PACKAGES_REPO" { - type = string -} - -// Repositories containing the client tools RPMs -variable "SLE_CLIENT_REPO" { - type = string -} - -variable "RHLIKE_CLIENT_REPO" { - type = string -} - -variable "DEBLIKE_CLIENT_REPO" { - type = string -} - -variable "OPENSUSE_CLIENT_REPO" { - type = string -} - -terraform { - required_version = "1.0.10" - required_providers { - libvirt = { - source = "dmacvicar/libvirt" - version = "0.6.3" - } - } -} - - -provider "libvirt" { - uri = "qemu+tcp://${var.HYPER}/system" -} - -module "cucumber_testsuite" { - source = "./modules/cucumber_testsuite" - - product_version = "uyuni-pr" - - // Cucumber repository configuration for the controller - git_username = var.GIT_USER - git_password = var.GIT_PASSWORD - git_repo = var.CUCUMBER_GITREPO - branch = var.CUCUMBER_BRANCH - - cc_username = var.SCC_USER - cc_password = var.SCC_PASSWORD - mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - use_mirror_images = true - - images = ["rocky8o", "opensuse154o", "opensuse155o", "opensuse155-ci-pro", "ubuntu2204o", "sles15sp4o"] - - use_avahi = false - name_prefix = "suma-pr${var.ENVIRONMENT}-" - domain = "mgr.prv.suse.net" - from_email = "root@suse.de" - - no_auth_registry = "registry.mgr.prv.suse.net" - auth_registry = "registry.mgr.prv.suse.net:5000/cucutest" - auth_registry_username = "cucutest" - auth_registry_password = "cucusecret" - git_profiles_repo = "https://github.com/uyuni-project/uyuni.git#:testsuite/features/profiles/internal_prv" - - server_http_proxy = "http-proxy.mgr.prv.suse.net:3128" - custom_download_endpoint = "ftp://minima-mirror-ci-bv.mgr.prv.suse.net:445" - - # when changing images, please also keep in mind to adjust the image matrix at the end of the README. - host_settings = { - controller = { - provider_settings = { - mac = "aa:b2:92:04:00:20" - } - } - server = { - provider_settings = { - mac = "aa:b2:92:04:00:21" - memory = 16384 - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - server_mounted_mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - } - proxy = { - provider_settings = { - mac = "aa:b2:92:04:00:22" - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - proxy_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Uyuni-Proxy-POOL-x86_64-Media1/", - tools_update = var.OPENSUSE_CLIENT_REPO - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-minion = { - image = "opensuse155o" - name = "min-suse" - provider_settings = { - mac = "aa:b2:92:04:00:24" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-sshminion = { - image = "opensuse155o" - name = "minssh-suse" - provider_settings = { - mac = "aa:b2:92:04:00:25" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion", "iptables" ] - install_salt_bundle = true - } - redhat-minion = { - image = "rocky8o" - name = "min-rhlike" - provider_settings = { - mac = "aa:b2:92:04:00:26" - memory = 2048 - vcpu = 2 - } - additional_repos = { - client_repo = var.RHLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - debian-minion = { - image = "ubuntu2204o" - name = "min-deblike" - provider_settings = { - mac = "aa:b2:92:04:00:27" - } - additional_repos = { - client_repo = var.DEBLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - build-host = { - image = "sles15sp4o" - name = "min-build" - provider_settings = { - mac = "aa:b2:92:04:00:29" - memory = 2048 - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - pxeboot-minion = { - image = "sles15sp4o" - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - kvm-host = { - image = "opensuse155-ci-pro" - name = "min-kvm" - additional_grains = { - hvm_disk_image = { - leap = { - hostname = "suma-pr3-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2.sha256" - } - sles = { - hostname = "suma-pr3-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2.sha256" - } - } - } - provider_settings = { - mac = "aa:b2:92:04:00:2a" - } - additional_repos_only = true - additional_repos = { - client_repo = var.OPENSUSE_CLIENT_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - } - additional_packages = [ "venv-salt-minion", "mkisofs" ] - install_salt_bundle = true - } - } - nested_vm_host = "suma-pr3-min-nested" - nested_vm_mac = "aa:b2:92:04:00:2b" - provider_settings = { - pool = "ssd" - network_name = null - bridge = "br1" - additional_network = "192.168.103.0/24" - } -} - - -resource "null_resource" "add_test_information" { - triggers = { - always_run = "${timestamp()}" - } - provisioner "file" { - source = "../../susemanager-ci/terracumber_config/scripts/set_custom_header.sh" - destination = "/tmp/set_custom_header.sh" - connection { - type = "ssh" - user = "root" - password = "linux" - host = "${module.cucumber_testsuite.configuration.server.hostname}" - } - } -} - - -output "configuration" { - value = module.cucumber_testsuite.configuration -} diff --git a/terracumber_config/tf_files/Uyuni-PR-tests-env4.tf b/terracumber_config/tf_files/Uyuni-PR-tests-env4.tf deleted file mode 100644 index 10f8cda69..000000000 --- a/terracumber_config/tf_files/Uyuni-PR-tests-env4.tf +++ /dev/null @@ -1,368 +0,0 @@ -// Mandatory variables for terracumber -variable "URL_PREFIX" { - type = string - default = "https://ci.suse.de/view/Manager/view/Uyuni/job/uyuni-prs-ci-tests" -} - -// Not really used as this is for --runall parameter, and we run cucumber step by step -variable "CUCUMBER_COMMAND" { - type = string - default = "export PRODUCT='Uyuni' && run-testsuite" -} - -variable "CUCUMBER_GITREPO" { - type = string - default = "https://github.com/uyuni-project/uyuni.git" -} - -variable "CUCUMBER_BRANCH" { - type = string - default = "master" -} - -variable "CUCUMBER_RESULTS" { - type = string - default = "/root/spacewalk/testsuite" -} - -variable "MAIL_SUBJECT" { - type = string - default = "$status acceptance tests on Pull Request: $tests scenarios ($failures failed, $errors errors, $skipped skipped, $passed passed)" -} - -variable "MAIL_TEMPLATE" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request.txt" -} - -variable "MAIL_SUBJECT_ENV_FAIL" { - type = string - default = "Failed acceptance tests on Pull Request: Environment setup failed" -} - -variable "MAIL_TEMPLATE_ENV_FAIL" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request-env-fail.txt" -} - -variable "ENVIRONMENT" { - type = string - default = "4" -} - -variable "HYPER" { - type = string - default = "vulcan.mgr.prv.suse.net" -} - -variable "MAIL_FROM" { - type = string - default = "jenkins@suse.de" -} - -variable "MAIL_TO" { - type = string - default = "galaxy-ci@suse.de" -} - -// sumaform specific variables -variable "SCC_USER" { - type = string -} - -variable "SCC_PASSWORD" { - type = string -} - -variable "GIT_USER" { - type = string - default = null // Not needed for master, as it is public -} - -variable "GIT_PASSWORD" { - type = string - default = null // Not needed for master, as it is public -} - -// Repository containing the build for the tested Uyuni Pull Request -variable "PULL_REQUEST_REPO" { - type = string -} - -variable "MASTER_REPO" { - type = string -} - -variable "MASTER_OTHER_REPO" { - type = string -} - -variable "MASTER_SUMAFORM_TOOLS_REPO" { - type = string -} - -variable "UPDATE_REPO" { - type = string -} - -variable "ADDITIONAL_REPO_URL" { - type = string -} - -variable "TEST_PACKAGES_REPO" { - type = string -} - -// Repositories containing the client tools RPMs -variable "SLE_CLIENT_REPO" { - type = string -} - -variable "RHLIKE_CLIENT_REPO" { - type = string -} - -variable "DEBLIKE_CLIENT_REPO" { - type = string -} - -variable "OPENSUSE_CLIENT_REPO" { - type = string -} - -terraform { - required_version = "1.0.10" - required_providers { - libvirt = { - source = "dmacvicar/libvirt" - version = "0.6.3" - } - } -} - - -provider "libvirt" { - uri = "qemu+tcp://${var.HYPER}/system" -} - -module "cucumber_testsuite" { - source = "./modules/cucumber_testsuite" - - product_version = "uyuni-pr" - - // Cucumber repository configuration for the controller - git_username = var.GIT_USER - git_password = var.GIT_PASSWORD - git_repo = var.CUCUMBER_GITREPO - branch = var.CUCUMBER_BRANCH - - cc_username = var.SCC_USER - cc_password = var.SCC_PASSWORD - mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - use_mirror_images = true - - images = ["rocky8o", "opensuse154o", "opensuse155o", "opensuse155-ci-pro", "ubuntu2204o", "sles15sp4o"] - - use_avahi = false - name_prefix = "suma-pr${var.ENVIRONMENT}-" - domain = "mgr.prv.suse.net" - from_email = "root@suse.de" - - no_auth_registry = "registry.mgr.prv.suse.net" - auth_registry = "registry.mgr.prv.suse.net:5000/cucutest" - auth_registry_username = "cucutest" - auth_registry_password = "cucusecret" - git_profiles_repo = "https://github.com/uyuni-project/uyuni.git#:testsuite/features/profiles/internal_prv" - - server_http_proxy = "http-proxy.mgr.prv.suse.net:3128" - custom_download_endpoint = "ftp://minima-mirror-ci-bv.mgr.prv.suse.net:445" - - # when changing images, please also keep in mind to adjust the image matrix at the end of the README. - host_settings = { - controller = { - provider_settings = { - mac = "aa:b2:92:04:00:30" - } - } - server = { - provider_settings = { - mac = "aa:b2:92:04:00:31" - memory = 16384 - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - server_mounted_mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - } - proxy = { - provider_settings = { - mac = "aa:b2:92:04:00:32" - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - proxy_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Uyuni-Proxy-POOL-x86_64-Media1/", - tools_update = var.OPENSUSE_CLIENT_REPO - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-minion = { - image = "opensuse155o" - name = "min-suse" - provider_settings = { - mac = "aa:b2:92:04:00:34" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-sshminion = { - image = "opensuse155o" - name = "minssh-suse" - provider_settings = { - mac = "aa:b2:92:04:00:35" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion", "iptables" ] - install_salt_bundle = true - } - redhat-minion = { - image = "rocky8o" - name = "min-rhlike" - provider_settings = { - mac = "aa:b2:92:04:00:36" - memory = 2048 - vcpu = 2 - } - additional_repos = { - client_repo = var.RHLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - debian-minion = { - image = "ubuntu2204o" - name = "min-deblike" - provider_settings = { - mac = "aa:b2:92:04:00:37" - } - additional_repos = { - client_repo = var.DEBLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - build-host = { - image = "sles15sp4o" - name = "min-build" - provider_settings = { - mac = "aa:b2:92:04:00:39" - memory = 2048 - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - pxeboot-minion = { - image = "sles15sp4o" - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - kvm-host = { - image = "opensuse155-ci-pro" - name = "min-kvm" - additional_grains = { - hvm_disk_image = { - leap = { - hostname = "suma-pr4-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2.sha256" - } - sles = { - hostname = "suma-pr4-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2.sha256" - } - } - } - provider_settings = { - mac = "aa:b2:92:04:00:3a" - } - additional_repos_only = true - additional_repos = { - client_repo = var.OPENSUSE_CLIENT_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - } - additional_packages = [ "venv-salt-minion", "mkisofs" ] - install_salt_bundle = true - } - } - nested_vm_host = "suma-pr4-min-nested" - nested_vm_mac = "aa:b2:92:04:00:3b" - provider_settings = { - pool = "ssd" - network_name = null - bridge = "br1" - additional_network = "192.168.104.0/24" - } -} - - -resource "null_resource" "add_test_information" { - triggers = { - always_run = "${timestamp()}" - } - provisioner "file" { - source = "../../susemanager-ci/terracumber_config/scripts/set_custom_header.sh" - destination = "/tmp/set_custom_header.sh" - connection { - type = "ssh" - user = "root" - password = "linux" - host = "${module.cucumber_testsuite.configuration.server.hostname}" - } - } -} - - -output "configuration" { - value = module.cucumber_testsuite.configuration -} diff --git a/terracumber_config/tf_files/Uyuni-PR-tests-env7.tf b/terracumber_config/tf_files/Uyuni-PR-tests-env7.tf deleted file mode 100644 index 89e147c53..000000000 --- a/terracumber_config/tf_files/Uyuni-PR-tests-env7.tf +++ /dev/null @@ -1,368 +0,0 @@ -// Mandatory variables for terracumber -variable "URL_PREFIX" { - type = string - default = "https://ci.suse.de/view/Manager/view/Uyuni/job/uyuni-prs-ci-tests" -} - -// Not really used as this is for --runall parameter, and we run cucumber step by step -variable "CUCUMBER_COMMAND" { - type = string - default = "export PRODUCT='Uyuni' && run-testsuite" -} - -variable "CUCUMBER_GITREPO" { - type = string - default = "https://github.com/uyuni-project/uyuni.git" -} - -variable "CUCUMBER_BRANCH" { - type = string - default = "master" -} - -variable "CUCUMBER_RESULTS" { - type = string - default = "/root/spacewalk/testsuite" -} - -variable "MAIL_SUBJECT" { - type = string - default = "$status acceptance tests on Pull Request: $tests scenarios ($failures failed, $errors errors, $skipped skipped, $passed passed)" -} - -variable "MAIL_TEMPLATE" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request.txt" -} - -variable "MAIL_SUBJECT_ENV_FAIL" { - type = string - default = "Failed acceptance tests on Pull Request: Environment setup failed" -} - -variable "MAIL_TEMPLATE_ENV_FAIL" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request-env-fail.txt" -} - -variable "ENVIRONMENT" { - type = string - default = "7" -} - -variable "HYPER" { - type = string - default = "daiquiri.mgr.prv.suse.net" -} - -variable "MAIL_FROM" { - type = string - default = "jenkins@suse.de" -} - -variable "MAIL_TO" { - type = string - default = "galaxy-ci@suse.de" -} - -// sumaform specific variables -variable "SCC_USER" { - type = string -} - -variable "SCC_PASSWORD" { - type = string -} - -variable "GIT_USER" { - type = string - default = null // Not needed for master, as it is public -} - -variable "GIT_PASSWORD" { - type = string - default = null // Not needed for master, as it is public -} - -// Repository containing the build for the tested Uyuni Pull Request -variable "PULL_REQUEST_REPO" { - type = string -} - -variable "MASTER_REPO" { - type = string -} - -variable "MASTER_OTHER_REPO" { - type = string -} - -variable "MASTER_SUMAFORM_TOOLS_REPO" { - type = string -} - -variable "UPDATE_REPO" { - type = string -} - -variable "ADDITIONAL_REPO_URL" { - type = string -} - -variable "TEST_PACKAGES_REPO" { - type = string -} - -// Repositories containing the client tools RPMs -variable "SLE_CLIENT_REPO" { - type = string -} - -variable "RHLIKE_CLIENT_REPO" { - type = string -} - -variable "DEBLIKE_CLIENT_REPO" { - type = string -} - -variable "OPENSUSE_CLIENT_REPO" { - type = string -} - -terraform { - required_version = "1.0.10" - required_providers { - libvirt = { - source = "dmacvicar/libvirt" - version = "0.6.3" - } - } -} - - -provider "libvirt" { - uri = "qemu+tcp://${var.HYPER}/system" -} - -module "cucumber_testsuite" { - source = "./modules/cucumber_testsuite" - - product_version = "uyuni-pr" - - // Cucumber repository configuration for the controller - git_username = var.GIT_USER - git_password = var.GIT_PASSWORD - git_repo = var.CUCUMBER_GITREPO - branch = var.CUCUMBER_BRANCH - - cc_username = var.SCC_USER - cc_password = var.SCC_PASSWORD - mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - use_mirror_images = true - - images = ["rocky8o", "opensuse154o", "opensuse155o", "opensuse155-ci-pro", "ubuntu2204o", "sles15sp4o"] - - use_avahi = false - name_prefix = "suma-pr${var.ENVIRONMENT}-" - domain = "mgr.prv.suse.net" - from_email = "root@suse.de" - - no_auth_registry = "registry.mgr.prv.suse.net" - auth_registry = "registry.mgr.prv.suse.net:5000/cucutest" - auth_registry_username = "cucutest" - auth_registry_password = "cucusecret" - git_profiles_repo = "https://github.com/uyuni-project/uyuni.git#:testsuite/features/profiles/internal_prv" - - server_http_proxy = "http-proxy.mgr.prv.suse.net:3128" - custom_download_endpoint = "ftp://minima-mirror-ci-bv.mgr.prv.suse.net:445" - - # when changing images, please also keep in mind to adjust the image matrix at the end of the README. - host_settings = { - controller = { - provider_settings = { - mac = "aa:b2:92:04:00:60" - } - } - server = { - provider_settings = { - mac = "aa:b2:92:04:00:61" - memory = 16384 - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - server_mounted_mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - } - proxy = { - provider_settings = { - mac = "aa:b2:92:04:00:62" - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - proxy_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Uyuni-Proxy-POOL-x86_64-Media1/", - tools_update = var.OPENSUSE_CLIENT_REPO - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-minion = { - image = "opensuse155o" - name = "min-suse" - provider_settings = { - mac = "aa:b2:92:04:00:64" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-sshminion = { - image = "opensuse155o" - name = "minssh-suse" - provider_settings = { - mac = "aa:b2:92:04:00:65" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion", "iptables" ] - install_salt_bundle = true - } - redhat-minion = { - image = "rocky8o" - name = "min-rhlike" - provider_settings = { - mac = "aa:b2:92:04:00:66" - memory = 2048 - vcpu = 2 - } - additional_repos = { - client_repo = var.RHLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - debian-minion = { - image = "ubuntu2204o" - name = "min-deblike" - provider_settings = { - mac = "aa:b2:92:04:00:67" - } - additional_repos = { - client_repo = var.DEBLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - build-host = { - image = "sles15sp4o" - name = "min-build" - provider_settings = { - mac = "aa:b2:92:04:00:69" - memory = 2048 - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - pxeboot-minion = { - image = "sles15sp4o" - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - kvm-host = { - image = "opensuse155-ci-pro" - name = "min-kvm" - additional_grains = { - hvm_disk_image = { - leap = { - hostname = "suma-pr7-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2.sha256" - } - sles = { - hostname = "suma-pr7-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2.sha256" - } - } - } - provider_settings = { - mac = "aa:b2:92:04:00:6a" - } - additional_repos_only = true - additional_repos = { - client_repo = var.OPENSUSE_CLIENT_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - } - additional_packages = [ "venv-salt-minion", "mkisofs" ] - install_salt_bundle = true - } - } - nested_vm_host = "suma-pr7-min-nested" - nested_vm_mac = "aa:b2:92:04:00:6b" - provider_settings = { - pool = "default" - network_name = null - bridge = "br1" - additional_network = "192.168.107.0/24" - } -} - - -resource "null_resource" "add_test_information" { - triggers = { - always_run = "${timestamp()}" - } - provisioner "file" { - source = "../../susemanager-ci/terracumber_config/scripts/set_custom_header.sh" - destination = "/tmp/set_custom_header.sh" - connection { - type = "ssh" - user = "root" - password = "linux" - host = "${module.cucumber_testsuite.configuration.server.hostname}" - } - } -} - - -output "configuration" { - value = module.cucumber_testsuite.configuration -} diff --git a/terracumber_config/tf_files/Uyuni-PR-tests-env8.tf b/terracumber_config/tf_files/Uyuni-PR-tests-env8.tf deleted file mode 100644 index 2e7022b50..000000000 --- a/terracumber_config/tf_files/Uyuni-PR-tests-env8.tf +++ /dev/null @@ -1,368 +0,0 @@ -// Mandatory variables for terracumber -variable "URL_PREFIX" { - type = string - default = "https://ci.suse.de/view/Manager/view/Uyuni/job/uyuni-prs-ci-tests" -} - -// Not really used as this is for --runall parameter, and we run cucumber step by step -variable "CUCUMBER_COMMAND" { - type = string - default = "export PRODUCT='Uyuni' && run-testsuite" -} - -variable "CUCUMBER_GITREPO" { - type = string - default = "https://github.com/uyuni-project/uyuni.git" -} - -variable "CUCUMBER_BRANCH" { - type = string - default = "master" -} - -variable "CUCUMBER_RESULTS" { - type = string - default = "/root/spacewalk/testsuite" -} - -variable "MAIL_SUBJECT" { - type = string - default = "$status acceptance tests on Pull Request: $tests scenarios ($failures failed, $errors errors, $skipped skipped, $passed passed)" -} - -variable "MAIL_TEMPLATE" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request.txt" -} - -variable "MAIL_SUBJECT_ENV_FAIL" { - type = string - default = "Failed acceptance tests on Pull Request: Environment setup failed" -} - -variable "MAIL_TEMPLATE_ENV_FAIL" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request-env-fail.txt" -} - -variable "ENVIRONMENT" { - type = string - default = "8" -} - -variable "HYPER" { - type = string - default = "daiquiri.mgr.prv.suse.net" -} - -variable "MAIL_FROM" { - type = string - default = "jenkins@suse.de" -} - -variable "MAIL_TO" { - type = string - default = "galaxy-ci@suse.de" -} - -// sumaform specific variables -variable "SCC_USER" { - type = string -} - -variable "SCC_PASSWORD" { - type = string -} - -variable "GIT_USER" { - type = string - default = null // Not needed for master, as it is public -} - -variable "GIT_PASSWORD" { - type = string - default = null // Not needed for master, as it is public -} - -// Repository containing the build for the tested Uyuni Pull Request -variable "PULL_REQUEST_REPO" { - type = string -} - -variable "MASTER_REPO" { - type = string -} - -variable "MASTER_OTHER_REPO" { - type = string -} - -variable "MASTER_SUMAFORM_TOOLS_REPO" { - type = string -} - -variable "UPDATE_REPO" { - type = string -} - -variable "ADDITIONAL_REPO_URL" { - type = string -} - -variable "TEST_PACKAGES_REPO" { - type = string -} - -// Repositories containing the client tools RPMs -variable "SLE_CLIENT_REPO" { - type = string -} - -variable "RHLIKE_CLIENT_REPO" { - type = string -} - -variable "DEBLIKE_CLIENT_REPO" { - type = string -} - -variable "OPENSUSE_CLIENT_REPO" { - type = string -} - -terraform { - required_version = "1.0.10" - required_providers { - libvirt = { - source = "dmacvicar/libvirt" - version = "0.6.3" - } - } -} - - -provider "libvirt" { - uri = "qemu+tcp://${var.HYPER}/system" -} - -module "cucumber_testsuite" { - source = "./modules/cucumber_testsuite" - - product_version = "uyuni-pr" - - // Cucumber repository configuration for the controller - git_username = var.GIT_USER - git_password = var.GIT_PASSWORD - git_repo = var.CUCUMBER_GITREPO - branch = var.CUCUMBER_BRANCH - - cc_username = var.SCC_USER - cc_password = var.SCC_PASSWORD - mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - use_mirror_images = true - - images = ["rocky8o", "opensuse154o", "opensuse155o", "opensuse155-ci-pro", "ubuntu2204o", "sles15sp4o"] - - use_avahi = false - name_prefix = "suma-pr${var.ENVIRONMENT}-" - domain = "mgr.prv.suse.net" - from_email = "root@suse.de" - - no_auth_registry = "registry.mgr.prv.suse.net" - auth_registry = "registry.mgr.prv.suse.net:5000/cucutest" - auth_registry_username = "cucutest" - auth_registry_password = "cucusecret" - git_profiles_repo = "https://github.com/uyuni-project/uyuni.git#:testsuite/features/profiles/internal_prv" - - server_http_proxy = "http-proxy.mgr.prv.suse.net:3128" - custom_download_endpoint = "ftp://minima-mirror-ci-bv.mgr.prv.suse.net:445" - - # when changing images, please also keep in mind to adjust the image matrix at the end of the README. - host_settings = { - controller = { - provider_settings = { - mac = "aa:b2:92:04:00:70" - } - } - server = { - provider_settings = { - mac = "aa:b2:92:04:00:71" - memory = 16384 - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - server_mounted_mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - } - proxy = { - provider_settings = { - mac = "aa:b2:92:04:00:72" - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - proxy_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Uyuni-Proxy-POOL-x86_64-Media1/", - tools_update = var.OPENSUSE_CLIENT_REPO - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-minion = { - image = "opensuse155o" - name = "min-suse" - provider_settings = { - mac = "aa:b2:92:04:00:74" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-sshminion = { - image = "opensuse155o" - name = "minssh-suse" - provider_settings = { - mac = "aa:b2:92:04:00:75" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion", "iptables" ] - install_salt_bundle = true - } - redhat-minion = { - image = "rocky8o" - name = "min-rhlike" - provider_settings = { - mac = "aa:b2:92:04:00:76" - memory = 2048 - vcpu = 2 - } - additional_repos = { - client_repo = var.RHLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - debian-minion = { - image = "ubuntu2204o" - name = "min-deblike" - provider_settings = { - mac = "aa:b2:92:04:00:77" - } - additional_repos = { - client_repo = var.DEBLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - build-host = { - image = "sles15sp4o" - name = "min-build" - provider_settings = { - mac = "aa:b2:92:04:00:79" - memory = 2048 - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - pxeboot-minion = { - image = "sles15sp4o" - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - kvm-host = { - image = "opensuse155-ci-pro" - name = "min-kvm" - additional_grains = { - hvm_disk_image = { - leap = { - hostname = "suma-pr8-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2.sha256" - } - sles = { - hostname = "suma-pr8-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2.sha256" - } - } - } - provider_settings = { - mac = "aa:b2:92:04:00:7a" - } - additional_repos_only = true - additional_repos = { - client_repo = var.OPENSUSE_CLIENT_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - } - additional_packages = [ "venv-salt-minion", "mkisofs" ] - install_salt_bundle = true - } - } - nested_vm_host = "suma-pr8-min-nested" - nested_vm_mac = "aa:b2:92:04:00:7b" - provider_settings = { - pool = "default" - network_name = null - bridge = "br1" - additional_network = "192.168.108.0/24" - } -} - - -resource "null_resource" "add_test_information" { - triggers = { - always_run = "${timestamp()}" - } - provisioner "file" { - source = "../../susemanager-ci/terracumber_config/scripts/set_custom_header.sh" - destination = "/tmp/set_custom_header.sh" - connection { - type = "ssh" - user = "root" - password = "linux" - host = "${module.cucumber_testsuite.configuration.server.hostname}" - } - } -} - - -output "configuration" { - value = module.cucumber_testsuite.configuration -} diff --git a/terracumber_config/tf_files/Uyuni-PR-tests-env9.tf b/terracumber_config/tf_files/Uyuni-PR-tests-env9.tf deleted file mode 100644 index bbf686c62..000000000 --- a/terracumber_config/tf_files/Uyuni-PR-tests-env9.tf +++ /dev/null @@ -1,369 +0,0 @@ -// Mandatory variables for terracumber -variable "URL_PREFIX" { - type = string - default = "https://ci.suse.de/view/Manager/view/Uyuni/job/uyuni-prs-ci-tests" -} - -// Not really used as this is for --runall parameter, and we run cucumber step by step -variable "CUCUMBER_COMMAND" { - type = string - default = "export PRODUCT='Uyuni' && run-testsuite" -} - -variable "CUCUMBER_GITREPO" { - type = string - default = "https://github.com/uyuni-project/uyuni.git" -} - -variable "CUCUMBER_BRANCH" { - type = string - default = "master" -} - -variable "CUCUMBER_RESULTS" { - type = string - default = "/root/spacewalk/testsuite" -} - -variable "MAIL_SUBJECT" { - type = string - default = "$status acceptance tests on Pull Request: $tests scenarios ($failures failed, $errors errors, $skipped skipped, $passed passed)" -} - -variable "MAIL_TEMPLATE" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request.txt" -} - -variable "MAIL_SUBJECT_ENV_FAIL" { - type = string - default = "Failed acceptance tests on Pull Request: Environment setup failed" -} - -variable "MAIL_TEMPLATE_ENV_FAIL" { - type = string - default = "../mail_templates/mail-template-jenkins-pull-request-env-fail.txt" -} - -variable "ENVIRONMENT" { - type = string - default = "9" -} - -variable "HYPER" { - type = string - default = "mojito.mgr.prv.suse.net" -} - -variable "MAIL_FROM" { - type = string - default = "jenkins@suse.de" -} - -variable "MAIL_TO" { - type = string - default = "galaxy-ci@suse.de" -} - -// sumaform specific variables -variable "SCC_USER" { - type = string -} - -variable "SCC_PASSWORD" { - type = string -} - -variable "GIT_USER" { - type = string - default = null // Not needed for master, as it is public -} - -variable "GIT_PASSWORD" { - type = string - default = null // Not needed for master, as it is public -} - -// Repository containing the build for the tested Uyuni Pull Request -variable "PULL_REQUEST_REPO" { - type = string -} - -variable "MASTER_REPO" { - type = string -} - -variable "MASTER_OTHER_REPO" { - type = string -} - -variable "MASTER_SUMAFORM_TOOLS_REPO" { - type = string -} - -variable "UPDATE_REPO" { - type = string -} - -variable "ADDITIONAL_REPO_URL" { - type = string -} - -variable "TEST_PACKAGES_REPO" { - type = string -} - -// Repositories containing the client tools RPMs -variable "SLE_CLIENT_REPO" { - type = string -} - -variable "RHLIKE_CLIENT_REPO" { - type = string -} - -variable "DEBLIKE_CLIENT_REPO" { - type = string -} - -variable "OPENSUSE_CLIENT_REPO" { - type = string -} - -terraform { - required_version = "1.0.10" - required_providers { - libvirt = { - source = "dmacvicar/libvirt" - version = "0.6.3" - } - } -} - - -provider "libvirt" { - uri = "qemu+tcp://${var.HYPER}/system" -} - -module "cucumber_testsuite" { - source = "./modules/cucumber_testsuite" - - product_version = "uyuni-pr" - - // Cucumber repository configuration for the controller - git_username = var.GIT_USER - git_password = var.GIT_PASSWORD - git_repo = var.CUCUMBER_GITREPO - branch = var.CUCUMBER_BRANCH - - cc_username = var.SCC_USER - cc_password = var.SCC_PASSWORD - mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - use_mirror_images = true - - images = ["rocky8o", "opensuse154o", "opensuse155o", "opensuse155-ci-pro", "ubuntu2204o", "sles15sp4o"] - - use_avahi = false - name_prefix = "suma-pr${var.ENVIRONMENT}-" - domain = "mgr.prv.suse.net" - from_email = "root@suse.de" - - no_auth_registry = "registry.mgr.prv.suse.net" - auth_registry = "registry.mgr.prv.suse.net:5000/cucutest" - auth_registry_username = "cucutest" - auth_registry_password = "cucusecret" - git_profiles_repo = "https://github.com/uyuni-project/uyuni.git#:testsuite/features/profiles/internal_prv" - - server_http_proxy = "http-proxy.mgr.prv.suse.net:3128" - custom_download_endpoint = "ftp://minima-mirror-ci-bv.mgr.prv.suse.net:445" - - # when changing images, please also keep in mind to adjust the image matrix at the end of the README. - host_settings = { - controller = { - provider_settings = { - mac = "aa:b2:92:04:00:80" - } - } - server = { - provider_settings = { - mac = "aa:b2:92:04:00:81" - memory = 16384 - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - server_mounted_mirror = "minima-mirror-ci-bv.mgr.prv.suse.net" - } - proxy = { - provider_settings = { - mac = "aa:b2:92:04:00:82" - } - additional_repos_only = true - additional_repos = { - pull_request_repo = var.PULL_REQUEST_REPO, - master_repo = var.MASTER_REPO, - master_repo_other = var.MASTER_OTHER_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - testing_overlay_devel = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/", - proxy_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Uyuni-Proxy-POOL-x86_64-Media1/", - tools_update = var.OPENSUSE_CLIENT_REPO - } - image = "opensuse155-ci-pro" - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-minion = { - image = "opensuse155o" - name = "min-suse" - provider_settings = { - mac = "aa:b2:92:04:00:84" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - suse-sshminion = { - image = "opensuse155o" - name = "minssh-suse" - provider_settings = { - mac = "aa:b2:92:04:00:85" - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion", "iptables" ] - install_salt_bundle = true - } - - /*redhat-minion = { - image = "rocky8o" - name = "min-rhlike" - provider_settings = { - mac = "aa:b2:92:04:00:86" - memory = 2048 - vcpu = 2 - } - additional_repos = { - client_repo = var.RHLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - }*/ - debian-minion = { - image = "ubuntu2204o" - name = "min-deblike" - provider_settings = { - mac = "aa:b2:92:04:00:87" - } - additional_repos = { - client_repo = var.DEBLIKE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - build-host = { - image = "sles15sp4o" - name = "min-build" - provider_settings = { - mac = "aa:b2:92:04:00:89" - memory = 2048 - } - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - pxeboot-minion = { - image = "sles15sp4o" - additional_repos = { - tools_update = var.SLE_CLIENT_REPO, - } - additional_packages = [ "venv-salt-minion" ] - install_salt_bundle = true - } - /*kvm-host = { - image = "opensuse155-ci-pro" - name = "min-kvm" - additional_grains = { - hvm_disk_image = { - leap = { - hostname = "suma-pr9-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.x86_64-Cloud.qcow2.sha256" - } - sles = { - hostname = "suma-pr9-min-nested" - image = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2" - hash = "http://minima-mirror-ci-bv.mgr.prv.suse.net/install/SLE-15-SP4-Minimal-GM/SLES15-SP4-Minimal-VM.x86_64-OpenStack-Cloud-GM.qcow2.sha256" - } - } - } - provider_settings = { - mac = "aa:b2:92:04:00:8a" - } - additional_repos_only = true - additional_repos = { - client_repo = var.OPENSUSE_CLIENT_REPO, - master_sumaform_tools_repo = var.MASTER_SUMAFORM_TOOLS_REPO, - test_packages_repo = var.TEST_PACKAGES_REPO, - non_os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/non-oss/", - os_pool = "http://minima-mirror-ci-bv.mgr.prv.suse.net/distribution/leap/15.5/repo/oss/", - os_update = var.UPDATE_REPO, - os_additional_repo = var.ADDITIONAL_REPO_URL, - } - additional_packages = [ "venv-salt-minion", "mkisofs" ] - install_salt_bundle = true - } */ - } - nested_vm_host = "suma-pr9-min-nested" - nested_vm_mac = "aa:b2:92:04:00:8b" - provider_settings = { - pool = "default" - network_name = null - bridge = "br0" - additional_network = "192.168.109.0/24" - } -} - - -resource "null_resource" "add_test_information" { - triggers = { - always_run = "${timestamp()}" - } - provisioner "file" { - source = "../../susemanager-ci/terracumber_config/scripts/set_custom_header.sh" - destination = "/tmp/set_custom_header.sh" - connection { - type = "ssh" - user = "root" - password = "linux" - host = "${module.cucumber_testsuite.configuration.server.hostname}" - } - } -} - - -output "configuration" { - value = module.cucumber_testsuite.configuration -} diff --git a/terracumber_config/tf_files/tfvars/PR-testing-NUE-environments.tfvars b/terracumber_config/tf_files/tfvars/PR-testing-NUE-environments.tfvars new file mode 100644 index 000000000..327ba1b17 --- /dev/null +++ b/terracumber_config/tf_files/tfvars/PR-testing-NUE-environments.tfvars @@ -0,0 +1,117 @@ +############ Nuremberg unique variables ############ + +DOMAIN = "mgr.suse.de" +MIRROR = "minima-mirror-ci-bv.mgr.suse.de" +DOWNLOAD_ENDPOINT = "minima-mirror-ci-bv.mgr.suse.de" +USE_MIRROR_IMAGES = false +GIT_PROFILES_REPO = "https://github.com/uyuni-project/uyuni.git#:testsuite/features/profiles/internal_nue" +ENVIRONMENT_CONFIGURATION = { + 1 = { + mac = { + controller = "aa:b2:93:01:03:50" + server = "aa:b2:93:01:03:51" + proxy = "aa:b2:93:01:03:52" + suse-minion = "aa:b2:93:01:03:54" + suse-sshminion = "aa:b2:93:01:03:55" + redhat-minion = "aa:b2:93:01:03:56" + debian-minion = "aa:b2:93:01:03:57" + build-host = "aa:b2:93:01:03:59" + kvm-host = "aa:b2:93:01:03:5a" + nested-vm = "aa:b2:93:01:03:5b" + } + hypervisor = "suma-08.mgr.suse.de" + additional_network = "192.168.111.0/24" + pool = "ssd" + bridge = "br0" + }, + 2 = { + mac = { + controller = "aa:b2:93:01:03:5c" + server = "aa:b2:93:01:03:5d" + proxy = "aa:b2:93:01:03:5e" + suse-minion = "aa:b2:93:01:03:60" + suse-sshminion = "aa:b2:93:01:03:61" + redhat-minion = "aa:b2:93:01:03:62" + debian-minion = "aa:b2:93:01:03:64" + build-host = "aa:b2:93:01:03:65" + kvm-host = "aa:b2:93:01:03:66" + nested-vm = "aa:b2:93:01:03:67" + } + hypervisor = "suma-08.mgr.suse.de" + additional_network = "192.168.112.0/24" + pool = "ssd" + bridge = "br0" + }, + 3 = { + mac = { + controller = "aa:b2:93:01:03:68" + server = "aa:b2:93:01:03:69" + proxy = "aa:b2:93:01:03:6a" + suse-minion = "aa:b2:93:01:03:6c" + suse-sshminion = "aa:b2:93:01:03:6d" + redhat-minion = "aa:b2:93:01:03:6e" + debian-minion = "aa:b2:93:01:03:70" + build-host = "aa:b2:93:01:03:71" + kvm-host = "aa:b2:93:01:03:72" + nested-vm = "aa:b2:93:01:03:73" + } + hypervisor = "suma-08.mgr.suse.de" + additional_network = "192.168.113.0/24" + pool = "ssd" + bridge = "br0" + }, + 4 = { + mac = { + controller = "aa:b2:93:01:03:74" + server = "aa:b2:93:01:03:75" + proxy = "aa:b2:93:01:03:76" + suse-minion = "aa:b2:93:01:03:78" + suse-sshminion = "aa:b2:93:01:03:79" + redhat-minion = "aa:b2:93:01:03:7a" + debian-minion = "aa:b2:93:01:03:7c" + build-host = "aa:b2:93:01:03:7d" + kvm-host = "aa:b2:93:01:03:7e" + nested-vm = "aa:b2:93:01:03:7f" + } + hypervisor = "suma-08.mgr.suse.de" + additional_network = "192.168.114.0/24" + pool = "ssd" + bridge = "br0" + }, + 5 = { + mac = { + controller = "aa:b2:93:01:03:80" + server = "aa:b2:93:01:03:81" + proxy = "aa:b2:93:01:03:82" + suse-minion = "aa:b2:93:01:03:84" + suse-sshminion = "aa:b2:93:01:03:85" + redhat-minion = "aa:b2:93:01:03:86" + debian-minion = "aa:b2:93:01:03:88" + build-host = "aa:b2:93:01:03:89" + kvm-host = "aa:b2:93:01:03:8a" + nested-vm = "aa:b2:93:01:03:8b" + } + hypervisor = "suma-08.mgr.suse.de" + additional_network = "192.168.115.0/24" + pool = "ssd" + bridge = "br0" + }, + 6 = { + mac = { + controller = "aa:b2:93:01:03:8c" + server = "aa:b2:93:01:03:8d" + proxy = "aa:b2:93:01:03:8e" + suse-minion = "aa:b2:93:01:03:90" + suse-sshminion = "aa:b2:93:01:03:91" + redhat-minion = "aa:b2:93:01:03:92" + debian-minion = "aa:b2:93:01:03:94" + build-host = "aa:b2:93:01:03:95" + kvm-host = "aa:b2:93:01:03:96" + nested-vm = "aa:b2:93:01:03:97" + } + hypervisor = "suma-08.mgr.suse.de" + additional_network = "192.168.116.0/24" + pool = "ssd" + bridge = "br0" + } +} diff --git a/terracumber_config/tf_files/tfvars/PR-testing-PRV-environments.tfvars b/terracumber_config/tf_files/tfvars/PR-testing-PRV-environments.tfvars new file mode 100644 index 000000000..266abcfdf --- /dev/null +++ b/terracumber_config/tf_files/tfvars/PR-testing-PRV-environments.tfvars @@ -0,0 +1,189 @@ +############ Provo unique variables ############ + +DOMAIN = "mgr.prv.suse.net" +MIRROR = "minima-mirror-ci-bv.mgr.prv.suse.net" +DOWNLOAD_ENDPOINT = "minima-mirror-ci-bv.mgr.prv.suse.net" +USE_MIRROR_IMAGES = true +GIT_PROFILES_REPO = "https://github.com/uyuni-project/uyuni.git#:testsuite/features/profiles/internal_prv" +ENVIRONMENT_CONFIGURATION = { + 1 = { + mac = { + controller = "aa:b2:92:04:00:00" + server = "aa:b2:92:04:00:01" + proxy = "aa:b2:92:04:00:02" + suse-minion = "aa:b2:92:04:00:04" + suse-sshminion = "aa:b2:92:04:00:05" + rhlike-minion = "aa:b2:92:04:00:06" + deblike-minion = "aa:b2:92:04:00:07" + build-host = "aa:b2:92:04:00:09" + kvm-host = "aa:b2:92:04:00:0a" + nested-vm = "aa:b2:92:04:00:0b" + } + hypervisor = "romulus.mgr.prv.suse.net" + additional_network = "192.168.101.0/24" + pool = "ssd" + bridge = "br1" + }, + 2 = { + mac = { + controller = "aa:b2:92:04:00:10" + server = "aa:b2:92:04:00:11" + proxy = "aa:b2:92:04:00:12" + suse-minion = "aa:b2:92:04:00:14" + suse-sshminion = "aa:b2:92:04:00:15" + rhlike-minion = "aa:b2:92:04:00:16" + deblike-minion = "aa:b2:92:04:00:17" + build-host = "aa:b2:92:04:00:19" + kvm-host = "aa:b2:92:04:00:1a" + nested-vm = "aa:b2:92:04:00:1b" + } + hypervisor = "romulus.mgr.prv.suse.net" + additional_network = "192.168.102.0/24" + pool = "ssd" + bridge = "br1" + }, + 3 = { + mac = { + controller = "aa:b2:92:04:00:20" + server = "aa:b2:92:04:00:21" + proxy = "aa:b2:92:04:00:22" + suse-minion = "aa:b2:92:04:00:24" + suse-sshminion = "aa:b2:92:04:00:25" + rhlike-minion = "aa:b2:92:04:00:26" + deblike-minion = "aa:b2:92:04:00:27" + build-host = "aa:b2:92:04:00:29" + kvm-host = "aa:b2:92:04:00:2a" + nested-vm = "aa:b2:92:04:00:2b" + } + hypervisor = "vulcan.mgr.prv.suse.net" + additional_network = "192.168.103.0/24" + pool = "ssd" + bridge = "br1" + }, + 4 = { + mac = { + controller = "aa:b2:92:04:00:30" + server = "aa:b2:92:04:00:31" + proxy = "aa:b2:92:04:00:32" + suse-minion = "aa:b2:92:04:00:34" + suse-sshminion = "aa:b2:92:04:00:35" + rhlike-minion = "aa:b2:92:04:00:36" + deblike-minion = "aa:b2:92:04:00:37" + build-host = "aa:b2:92:04:00:39" + kvm-host = "aa:b2:92:04:00:3a" + nested-vm = "aa:b2:92:04:00:3b" + } + hypervisor = "vulcan.mgr.prv.suse.net" + additional_network = "192.168.104.0/24" + pool = "ssd" + bridge = "br1" + }, + 5 = { + mac = { + controller = "aa:b2:92:04:00:40" + server = "aa:b2:92:04:00:41" + proxy = "aa:b2:92:04:00:42" + suse-minion = "aa:b2:92:04:00:44" + suse-sshminion = "aa:b2:92:04:00:45" + rhlike-minion = "aa:b2:92:04:00:46" + deblike-minion = "aa:b2:92:04:00:47" + build-host = "aa:b2:92:04:00:49" + kvm-host = "aa:b2:92:04:00:4a" + nested-vm = "aa:b2:92:04:00:4b" + } + hypervisor = "hyperion.mgr.prv.suse.net" + additional_network = "192.168.105.0/24" + pool = "ssd" + bridge = "br1" + }, + 6 = { + mac = { + controller = "aa:b2:92:04:00:50" + server = "aa:b2:92:04:00:51" + proxy = "aa:b2:92:04:00:52" + suse-minion = "aa:b2:92:04:00:54" + suse-sshminion = "aa:b2:92:04:00:55" + rhlike-minion = "aa:b2:92:04:00:56" + deblike-minion = "aa:b2:92:04:00:57" + build-host = "aa:b2:92:04:00:59" + kvm-host = "aa:b2:92:04:00:5a" + nested-vm = "aa:b2:92:04:00:5b" + } + hypervisor = "hyperion.mgr.prv.suse.net" + additional_network = "192.168.106.0/24" + pool = "ssd" + bridge = "br1" + }, + 7 = { + mac = { + controller = "aa:b2:92:04:00:60" + server = "aa:b2:92:04:00:61" + proxy = "aa:b2:92:04:00:62" + suse-minion = "aa:b2:92:04:00:64" + suse-sshminion = "aa:b2:92:04:00:65" + rhlike-minion = "aa:b2:92:04:00:66" + deblike-minion = "aa:b2:92:04:00:67" + build-host = "aa:b2:92:04:00:69" + kvm-host = "aa:b2:92:04:00:6a" + nested-vm = "aa:b2:92:04:00:6b" + } + hypervisor = "daiquiri.mgr.prv.suse.net" + additional_network = "192.168.107.0/24" + pool = "default" + bridge = "br1" + }, + 8 = { + mac = { + controller = "aa:b2:92:04:00:70" + server = "aa:b2:92:04:00:71" + proxy = "aa:b2:92:04:00:72" + suse-minion = "aa:b2:92:04:00:74" + suse-sshminion = "aa:b2:92:04:00:75" + rhlike-minion = "aa:b2:92:04:00:76" + deblike-minion = "aa:b2:92:04:00:77" + build-host = "aa:b2:92:04:00:79" + kvm-host = "aa:b2:92:04:00:7a" + nested-vm = "aa:b2:92:04:00:7b" + } + hypervisor = "daiquiri.mgr.prv.suse.net" + additional_network = "192.168.108.0/24" + pool = "default" + bridge = "br1" + }, + 9 = { + mac = { + controller = "aa:b2:92:04:00:80" + server = "aa:b2:92:04:00:81" + proxy = "aa:b2:92:04:00:82" + suse-minion = "aa:b2:92:04:00:84" + suse-sshminion = "aa:b2:92:04:00:85" + rhlike-minion = "aa:b2:92:04:00:86" + deblike-minion = "aa:b2:92:04:00:87" + build-host = "aa:b2:92:04:00:89" + kvm-host = "aa:b2:92:04:00:8a" + nested-vm = "aa:b2:92:04:00:8b" + } + hypervisor = "mojito.mgr.prv.suse.net" + additional_network = "192.168.109.0/24" + pool = "default" + bridge = "br0" + }, + 10 = { + mac = { + controller = "aa:b2:92:04:00:90" + server = "aa:b2:92:04:00:91" + proxy = "aa:b2:92:04:00:92" + suse-minion = "aa:b2:92:04:00:94" + suse-sshminion = "aa:b2:92:04:00:95" + rhlike-minion = "aa:b2:92:04:00:96" + deblike-minion = "aa:b2:92:04:00:97" + build-host = "aa:b2:92:04:00:99" + kvm-host = "aa:b2:92:04:00:9a" + nested-vm = "aa:b2:92:04:00:9b" + } + hypervisor = "mojito.mgr.prv.suse.net" + additional_network = "192.168.110.0/24" + pool = "default" + bridge = "br0" + } +} diff --git a/terracumber_config/tf_files/tfvars/PR-testing-additionnal-repos.tf b/terracumber_config/tf_files/tfvars/PR-testing-additionnal-repos.tf new file mode 100644 index 000000000..6e71b3e55 --- /dev/null +++ b/terracumber_config/tf_files/tfvars/PR-testing-additionnal-repos.tf @@ -0,0 +1,55 @@ +locals { + additional_repos = var.PRODUCT_VERSION == "uyuni-pr" ? { + server = { + pull_request_repo = "${var.PULL_REQUEST_REPO}" + master_repo = "${var.MASTER_REPO}" + master_repo_other = "${var.MASTER_OTHER_REPO}" + master_sumaform_tools_repo = "${var.MASTER_SUMAFORM_TOOLS_REPO}" + test_packages_repo = "${var.TEST_PACKAGES_REPO}" + non_os_pool = "http://${var.MIRROR}/distribution/leap/15.5/repo/non-oss/" + os_pool = "http://${var.MIRROR}/distribution/leap/15.5/repo/oss/" + os_update = "${var.UPDATE_REPO}" + os_additional_repo = "${var.ADDITIONAL_REPO_URL}" + testing_overlay_devel = "http://${var.MIRROR}/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/" + } + proxy = { + pull_request_repo = "${var.PULL_REQUEST_REPO}" + master_repo = "${var.MASTER_REPO}" + master_repo_other = "${var.MASTER_OTHER_REPO}" + master_sumaform_tools_repo = "${var.MASTER_SUMAFORM_TOOLS_REPO}" + test_packages_repo = "${var.TEST_PACKAGES_REPO}" + non_os_pool = "http://${var.MIRROR}/distribution/leap/15.5/repo/non-oss/" + os_pool = "http://${var.MIRROR}/distribution/leap/15.5/repo/oss/" + os_update = "${var.UPDATE_REPO}" + os_additional_repo = "${var.ADDITIONAL_REPO_URL}" + testing_overlay_devel = "http://${var.MIRROR}/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Testing-Overlay-POOL-x86_64-Media1/" + proxy_pool = "http://${var.MIRROR}/repositories/systemsmanagement:/Uyuni:/Master/images/repo/Uyuni-Proxy-POOL-x86_64-Media1/" + tools_update_pr = "${var.OPENSUSE_CLIENT_REPO}" + } + suse-minion = { + tools_update_pr = "${var.SLE_CLIENT_REPO}" + } + kvm-host = { + client_repo = "${var.OPENSUSE_CLIENT_REPO}" + master_sumaform_tools_repo = "${var.MASTER_SUMAFORM_TOOLS_REPO}" + test_packages_repo = "${var.TEST_PACKAGES_REPO}" + non_os_pool = "http://${var.MIRROR}/distribution/leap/15.5/repo/non-oss/" + os_pool = "http://${var.MIRROR}/distribution/leap/15.5/repo/oss/" + os_update = "${var.UPDATE_REPO}" + os_additional_repo = "${var.ADDITIONAL_REPO_URL}" + } + } : { + server = { + pull_request_repo = "${var.PULL_REQUEST_REPO}" + } + proxy = { + pull_request_repo = "${var.PULL_REQUEST_REPO}" + } + suse-minion = { + tools_update_pr = "${var.SLE_CLIENT_REPO}" + } + kvm-host = { + tools_update_pr = "${var.SLE_CLIENT_REPO}" + } + } +} diff --git a/terracumber_config/tf_files/tfvars/PR-testing-manager43.tfvars b/terracumber_config/tf_files/tfvars/PR-testing-manager43.tfvars new file mode 100644 index 000000000..90fc236c5 --- /dev/null +++ b/terracumber_config/tf_files/tfvars/PR-testing-manager43.tfvars @@ -0,0 +1,16 @@ +############ Spacewalk unique variables ############ + +IMAGE = "sles15sp4o" +IMAGES = ["rocky9o", "opensuse154o", "sles15sp4o", "ubuntu2204o"] +SUSE_MINION_IMAGE = "sles15sp4o" +PRODUCT_VERSION = "4.3-nightly" +MAIL_TEMPLATE_ENV_FAIL = "../mail_templates/mail-template-jenkins-suma43-pull-request-env-fail.txt" +MAIL_TEMPLATE = "../mail_templates/mail-template-jenkins-suma43-pull-request.txt" +MAIL_SUBJECT = "$status acceptance tests on SUMA 4.3 Pull Request: $tests scenarios ($failures failed, $errors errors, $skipped skipped, $passed passed)" +CUCUMBER_BRANCH = "Manager-4.3" +CUCUMBER_GITREPO = "https://github.com/SUSE/spacewalk/spacewalk.git" +CUCUMBER_COMMAND = "export PRODUCT='SUSE-Manager' && run-testsuite" +URL_PREFIX = "https://ci.suse.de/view/Manager/view/Uyuni/job/suma43-prs-ci-tests" +ADDITIONAL_REPOS_ONLY = false +RHLIKE_MINION_IMAGE = "rocky9o" +DEBLIKE_MINION_IMAGE = "ubuntu2204o" diff --git a/terracumber_config/tf_files/tfvars/PR-testing-uyuni.tfvars b/terracumber_config/tf_files/tfvars/PR-testing-uyuni.tfvars new file mode 100644 index 000000000..71fabb3f7 --- /dev/null +++ b/terracumber_config/tf_files/tfvars/PR-testing-uyuni.tfvars @@ -0,0 +1,16 @@ +############ Uyuni unique variables ############ + +IMAGE = "opensuse155-ci-pro" +IMAGES = ["rocky8o", "opensuse154o", "opensuse155o", "opensuse155-ci-pro", "ubuntu2204o", "sles15sp4o"] +SUSE_MINION_IMAGE = "opensuse155o" +PRODUCT_VERSION = "uyuni-pr" +MAIL_TEMPLATE_ENV_FAIL = "../mail_templates/mail-template-jenkins-pull-request-env-fail.txt" +MAIL_TEMPLATE = "../mail_templates/mail-template-jenkins-pull-request.txt" +MAIL_SUBJECT = "$status acceptance tests on Pull Request: $tests scenarios ($failures failed, $errors errors, $skipped skipped, $passed passed)" +CUCUMBER_BRANCH = "master" +CUCUMBER_GITREPO = "https://github.com/uyuni-project/uyuni.git" +CUCUMBER_COMMAND = "export PRODUCT='Uyuni' && run-testsuite" +URL_PREFIX = "https://ci.suse.de/view/Manager/view/Uyuni/job/uyuni-prs-ci-tests" +ADDITIONAL_REPOS_ONLY = true +RHLIKE_MINION_IMAGE = "rocky8o" +DEBLIKE_MINION_IMAGE = "ubuntu2204o" diff --git a/terracumber_config/tf_files/variables/PR-testing-variables.tf b/terracumber_config/tf_files/variables/PR-testing-variables.tf new file mode 100644 index 000000000..0b1193e63 --- /dev/null +++ b/terracumber_config/tf_files/variables/PR-testing-variables.tf @@ -0,0 +1,181 @@ +// Mandatory variables for terracumber +variable "URL_PREFIX" { + type = string + default = "This is defined in product tfvars" +} + +// Not really used as this is for --runall parameter, and we run cucumber step by step +variable "CUCUMBER_COMMAND" { + type = string + default = "This is defined in product tfvars" +} + +variable "CUCUMBER_GITREPO" { + type = string + default = "This is defined in product tfvars" +} + +variable "CUCUMBER_BRANCH" { + type = string + default = "This is defined in product tfvars" +} + +variable "CUCUMBER_RESULTS" { + type = string + default = "/root/spacewalk/testsuite" +} + +variable "MAIL_SUBJECT" { + type = string + default = "This is defined in product tfvars" +} + +variable "MAIL_TEMPLATE" { + type = string + default = "This is defined in product tfvars" +} + +variable "MAIL_SUBJECT_ENV_FAIL" { + type = string + default = "Failed acceptance tests on Pull Request: Environment setup failed" +} + +variable "MAIL_TEMPLATE_ENV_FAIL" { + type = string + default = "This is defined in product tfvars" +} + +variable "ENVIRONMENT" { + type = string +} + +variable "MAIL_FROM" { + type = string + default = "galaxy-noise@suse.de" +} + +variable "MAIL_TO" { + type = string + default = "galaxy-noise@suse.de" +} + +// sumaform specific variables +variable "SCC_USER" { + type = string +} + +variable "SCC_PASSWORD" { + type = string +} + +variable "GIT_USER" { + type = string + default = null // Not needed for master, as it is public +} + +variable "GIT_PASSWORD" { + type = string + default = null // Not needed for master, as it is public +} + +// Repository containing the build for the tested Uyuni Pull Request +variable "PULL_REQUEST_REPO" { + type = string +} + +variable "MASTER_REPO" { + type = string +} + +variable "MASTER_OTHER_REPO" { + type = string +} + +variable "MASTER_SUMAFORM_TOOLS_REPO" { + type = string +} + +variable "UPDATE_REPO" { + type = string +} + +variable "ADDITIONAL_REPO_URL" { + type = string +} + +variable "TEST_PACKAGES_REPO" { + type = string +} + +// Repositories containing the client tools RPMs +variable "SLE_CLIENT_REPO" { + type = string +} + +variable "RHLIKE_CLIENT_REPO" { + type = string +} + +variable "DEBLIKE_CLIENT_REPO" { + type = string +} + +variable "OPENSUSE_CLIENT_REPO" { + type = string +} + +variable "IMAGE" { + type = string +} + +variable "GIT_PROFILES_REPO" { + type = string +} + +variable "IMAGES" { + type = list(string) +} + +variable "SUSE_MINION_IMAGE" { + type = string +} + +variable "RHLIKE_MINION_IMAGE" { + type = string +} + +variable "DEBLIKE_MINION_IMAGE" { + type = string +} + +variable "PRODUCT_VERSION" { + type = string +} + +variable "MIRROR" { + type = string + default = null +} + +variable "USE_MIRROR_IMAGES" { + description = "use true download images from a mirror host" + type = bool +} + +variable "DOMAIN" { + type = string +} + +variable "ADDITIONAL_REPOS_ONLY" { + type = bool +} + +variable "ENVIRONMENT_CONFIGURATION" { + type = map + description = "Collection of value containing : mac addresses, hypervisor and additional network" +} + +variable "DOWNLOAD_ENDPOINT" { + type = string + description = "Download enpoint to get build images and set custom_download_endpoint. This value is equal to platform mirror" +}