Skip to content

Commit

Permalink
CI: use SCC mirror
Browse files Browse the repository at this point in the history
* Configure the server to use SCC mirror
* Review tests:
  * Review base channels for sle minions
  * Review activation keys
  * Sync channels
  * Enable tests that now pass, related to channels, and
    other tests that now pass
  * Fix: cobbler "get logs". Remote and local file can't
    have the same name, because containers share tmp volume
  * Review default channels for uyuni and sle (in constants.rb)
  * Fix buildhost

There are some things left for a new iteration:
  * i586 archs
  * SUSE Manager related channels in SCC mirror
  * Build profiles
  * Patches and CVEs in SCC mirror
  * Some tests that still fail

CI: remove mgrctl from server container, or the testsuite things
this is the server host

fixes SUSE/spacewalk#25220

Signed-off-by: Jordi Massaguer Pla <[email protected]>
  • Loading branch information
jordimassaguerpla committed Dec 9, 2024
1 parent 7f10c32 commit 5dd95d6
Show file tree
Hide file tree
Showing 41 changed files with 156 additions and 76 deletions.
1 change: 0 additions & 1 deletion susemanager/susemanager.changes.oholecek.fix_ci_tests

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,3 @@ Feature: Bootstrap a Salt minion via the GUI
And I wait until I see the name of "sle_minion", refreshing the page
Then the Salt master can reach "sle_minion"

Scenario: Subscribe the SLE minion to a base channel
Given I am on the Systems overview page of this "sle_minion"
When I follow "Software" in the content area
And I follow "Software Channels" in the content area
And I wait until I do not see "Loading..." text
And I check radio button "Fake-Base-Channel-SUSE-like"
And I wait until I do not see "Loading..." text
And I check "Fake-RPM-SUSE-Channel"
And I click on "Next"
Then I should see a "Confirm Software Channel Change" text
When I click on "Confirm"
Then I should see a "Changing the channels has been scheduled." text
And I wait until event "Subscribe channels scheduled by admin" is completed
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,15 @@ Feature: Bootstrap a Salt host managed via salt-ssh
When I follow "Software" in the content area
And I follow "Software Channels" in the content area
And I wait until I do not see "Loading..." text
And I check radio button "Fake-Base-Channel-SUSE-like"
And I check radio button "openSUSE Leap 15.5 (x86_64)"
And I wait until I do not see "Loading..." text
And I check "Fake-RPM-SUSE-Channel"
And I check "openSUSE 15.5 non oss (x86_64)"
And I check "openSUSE Leap 15.5 non oss Updates (x86_64)"
And I check "openSUSE Leap 15.5 Updates (x86_64)"
And I check "Update repository of openSUSE Leap 15.5 Backports (x86_64)"
And I check "Update repository with updates from SUSE Linux Enterprise 15 for openSUSE Leap 15.5 (x86_64)"
And I check "Uyuni Client Tools for openSUSE Leap 15.5 (x86_64) (Development)"
And I click on "Next"
Then I should see a "Confirm Software Channel Change" text
When I click on "Confirm"
Expand Down
41 changes: 39 additions & 2 deletions testsuite/features/reposync/allcli_update_activationkeys.feature
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# Copyright (c) 2022-2024 SUSE LLC
# Licensed under the terms of the MIT license.

@skip_if_github_validation
Feature: Update activation keys
In order to register systems to the spacewalk server
As admin
Expand Down Expand Up @@ -111,7 +110,7 @@ Feature: Update activation keys
And I wait until "Fake-RPM-SUSE-Channel" has been checked
And I click on "Update Activation Key"
Then I should see a "Activation key SUSE SSH Tunnel Test Key x86_64 has been modified" text

@uyuni
Scenario: Update openSUSE Leap SSH tunnel key with synced base product
When I follow the left menu "Systems > Activation Keys"
Expand Down Expand Up @@ -182,6 +181,7 @@ Feature: Update activation keys
And I click on "Update Activation Key"
Then I should see a "Activation key Proxy Key x86_64 has been modified" text

@susemanager
@scc_credentials
Scenario: Update build host key with synced base product
When I follow the left menu "Systems > Activation Keys"
Expand All @@ -205,6 +205,26 @@ Feature: Update activation keys
And I click on "Update Activation Key"
Then I should see a "Activation key Build host Key x86_64 has been modified" text

@uyuni
@scc_credentials
Scenario: Update build host key with synced base product
When I follow the left menu "Systems > Activation Keys"
And I follow "Build host Key x86_64" in the content area
And I wait until I do not see "Loading..." text
And I select the parent channel for the "buildhost" from "selectedBaseChannel"
And I wait until I do not see "Loading..." text
And I check "openSUSE 15.5 non oss (x86_64)"
And I check "openSUSE Leap 15.5 non oss Updates (x86_64)"
And I check "openSUSE Leap 15.5 Updates (x86_64)"
And I check "Update repository of openSUSE Leap 15.5 Backports (x86_64)"
And I check "Update repository with updates from SUSE Linux Enterprise 15 for openSUSE Leap 15.5 (x86_64)"
And I check "Uyuni Client Tools for openSUSE Leap 15.5 (x86_64) (Development)"
And I check "Fake-RPM-SUSE-Channel"
And I wait until "Fake-RPM-SUSE-Channel" has been checked
And I click on "Update Activation Key"
Then I should see a "Activation key Build host Key x86_64 has been modified" text

@susemanager
@scc_credentials
Scenario: Update terminal key with synced base product
When I follow the left menu "Systems > Activation Keys"
Expand All @@ -226,6 +246,23 @@ Feature: Update activation keys
And I click on "Update Activation Key"
Then I should see a "Activation key Terminal Key x86_64 has been modified" text

@uyuni
@scc_credentials
Scenario: Update terminal key with synced base product
When I follow the left menu "Systems > Activation Keys"
And I follow "Terminal Key x86_64" in the content area
And I wait until I do not see "Loading..." text
And I select the parent channel for the "pxeboot_minion" from "selectedBaseChannel"
And I wait until I do not see "Loading..." text
And I check "openSUSE 15.5 non oss (x86_64)"
And I check "openSUSE Leap 15.5 non oss Updates (x86_64)"
And I check "openSUSE Leap 15.5 Updates (x86_64)"
And I check "Update repository of openSUSE Leap 15.5 Backports (x86_64)"
And I check "Update repository with updates from SUSE Linux Enterprise 15 for openSUSE Leap 15.5 (x86_64)"
And I check "Uyuni Client Tools for openSUSE Leap 15.5 (x86_64) (Development)"
And I click on "Update Activation Key"
Then I should see a "Activation key Terminal Key x86_64 has been modified" text

@susemanager
@scc_credentials
Scenario: Update terminal key with normal SUSE fake channel
Expand Down
16 changes: 8 additions & 8 deletions testsuite/features/reposync/srv_sync_channels.feature
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ Feature: Be able to list available channels and enable them
As root user
I want to be able to list available channels and enable them

@susemanager
Scenario: List available channels
# Order matters here, refresh first
When I refresh SCC
Expand All @@ -16,34 +15,35 @@ Feature: Be able to list available channels and enable them
And I should get " [ ] SLE-Product-SLES15-SP4-Updates for x86_64 SUSE Linux Enterprise Server 15 SP4 x86_64 [sle-product-sles15-sp4-updates-x86_64]"
And I should get " [ ] SLE15-SP4-Installer-Updates for x86_64 SUSE Linux Enterprise Server 15 SP4 x86_64 [sle15-sp4-installer-updates-x86_64]"

@susemanager
Scenario: List available mandatory channels
When I execute mgr-sync "list channels -e --no-optional"
Then I should get "[ ] SLE-Product-SLES15-SP4-Pool for x86_64 SUSE Linux Enterprise Server 15 SP4 x86_64 [sle-product-sles15-sp4-pool-x86_64]"
And I should get " [ ] SLE-Product-SLES15-SP4-Updates for x86_64 SUSE Linux Enterprise Server 15 SP4 x86_64 [sle-product-sles15-sp4-updates-x86_64]"
And I shouldn't get " [ ] SLE15-SP4-Installer-Updates for x86_64 SUSE Linux Enterprise Server 15 SP4 x86_64 [sle15-sp4-installer-updates-x86_64]"

@susemanager
Scenario: List products
Scenario: List Server product
When I execute mgr-sync "list products"
Then I should get "[ ] SUSE Linux Enterprise Server 15 SP4 x86_64"
And I should get "[ ] SUSE Manager Proxy 4.3 x86_64"

@proxy
Scenario: List Proxy product
When I execute mgr-sync "list products"
Then I should get "[ ] SUSE Manager Proxy 4.3 x86_64"

@susemanager
# The SCC mirror in github validation does not contain SUSE Manager products
@skip_if_github_validation
Scenario: List all products for SUSE Manager
When I execute mgr-sync "list products --expand"
Then I should get "[ ] SUSE Linux Enterprise Server 15 SP4 x86_64"
And I should get "[ ] SUSE Manager Proxy 4.3 x86_64"
And I should get " [ ] (R) SUSE Manager Client Tools for RHEL, Liberty and Clones 7 x86_64"
And I should get " [ ] (R) SUSE Manager Client Tools for SLE 15 x86_64"

@susemanager
Scenario: List products with filter
When I execute mgr-sync "list products --expand --filter x86_64"
Then I should get "[ ] SUSE Linux Enterprise Server 15 SP4 x86_64"
And I shouldn't get "ppc64"
And I shouldn't get "s390x"

Scenario: Let mgr-sync time out
When I remove the mgr-sync cache file
And I execute mgr-sync refresh
Expand Down
2 changes: 1 addition & 1 deletion testsuite/features/reposync/srv_sync_fake_channels.feature
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Feature: Synchronize fake channels
Scenario: Verify state of Fake-RPM-SUSE-Channel channel
Then "orion-dummy-1.1-1.1.x86_64.rpm" package should have been stored
And solver file for "fake-rpm-suse-channel" should reference "orion-dummy-1.1-1.1.x86_64.rpm"

@skip_if_github_validation
Scenario: Synchronize Fake-Child-Channel-i586 channel
Given I am authorized for the "Admin" section
When I follow the left menu "Software > Manage > Channels"
Expand Down
37 changes: 29 additions & 8 deletions testsuite/features/reposync/srv_sync_products.feature
Original file line number Diff line number Diff line change
Expand Up @@ -27,21 +27,31 @@ Feature: Synchronize products in the products page of the Setup Wizard
Then I should see a "RHEL and Liberty 8 Base" text

@scc_credentials
@susemanager
Scenario: View the channels list in the products page
Scenario: View the mandatory channels list in the products page
When I follow the left menu "Admin > Setup Wizard > Products"
And I wait until I do not see "currently running" text
And I wait until I do not see "Loading" text
And I enter "SUSE Linux Enterprise Server for SAP Applications 15 x86_64" as the filtered product description
And I click the channel list of product "SUSE Linux Enterprise Server for SAP Applications 15 x86_64"
Then I should see a "Product Channels" text
And I should see a "Mandatory Channels" text
When I close the modal dialog

# In gh the fake scc does not have optional channels
@skip_if_github_validation
@scc_credentials
Scenario: View the optional channels list in the products page
When I follow the left menu "Admin > Setup Wizard > Products"
And I wait until I do not see "currently running" text
And I wait until I do not see "Loading" text
And I enter "SUSE Linux Enterprise Server for SAP Applications 15 x86_64" as the filtered product description
And I click the channel list of product "SUSE Linux Enterprise Server for SAP Applications 15 x86_64"
Then I should see a "Product Channels" text
And I should see a "Optional Channels" text
When I close the modal dialog

@scc_credentials
@susemanager
Scenario: Synchronize SLES 15 SP4 product with recommended sub-products, including SUMA Client Tools
Scenario: Synchronize SLES 15 SP4 product with recommended sub-products, excluding SUMA Client Tools
Given I am authorized for the "Admin" section
When I follow the left menu "Admin > Setup Wizard > Products"
And I wait until I do not see "currently running" text
Expand All @@ -51,15 +61,12 @@ Feature: Synchronize products in the products page of the Setup Wizard
And I open the sub-list of the product "SUSE Linux Enterprise Server 15 SP4 x86_64"
And I open the sub-list of the product "Basesystem Module 15 SP4 x86_64"
And I open the sub-list of the product "Desktop Applications Module 15 SP4 x86_64"
And I open the sub-list of the product "SUSE Manager Client Tools for SLE 15 x86_64" if present
Then I should see that the "Basesystem Module 15 SP4 x86_64" product is "recommended"
And I should see that the "Server Applications Module 15 SP4 x86_64" product is "recommended"
And I should see that the "SUSE Manager Client Tools for SLE 15 x86_64" product is "recommended"
When I select "SUSE Linux Enterprise Server 15 SP4 x86_64" as a product
Then I should see the "SUSE Linux Enterprise Server 15 SP4 x86_64" selected
And I should see the "Basesystem Module 15 SP4 x86_64" selected
And I should see the "Server Applications Module 15 SP4 x86_64" selected
And I should see the "SUSE Manager Client Tools for SLE 15 x86_64" selected
When I select "Desktop Applications Module 15 SP4 x86_64" as a product
And I select "Development Tools Module 15 SP4 x86_64" as a product
Then I should see the "Desktop Applications Module 15 SP4 x86_64" selected
Expand All @@ -73,6 +80,21 @@ Feature: Synchronize products in the products page of the Setup Wizard
Then the SLE15 SP4 product should be added
When I wait until all synchronized channels for "sles15-sp4" have finished

# Fake SCC in gh does not contain SUMA client tools
@skip_if_github_validation
@scc_credentials
Scenario: Synchronize SLES 15 SP4 product with recommended sub-products, including SUMA Client Tools
Given I am authorized for the "Admin" section
When I follow the left menu "Admin > Setup Wizard > Products"
And I wait until I do not see "currently running" text
And I wait until I do not see "Loading" text
And I enter "SUSE Linux Enterprise Server 15 SP4" as the filtered product description
And I wait until I see "SUSE Linux Enterprise Server 15 SP4 x86_64" text
And I open the sub-list of the product "SUSE Manager Client Tools for SLE 15 x86_64" if present
Then I should see that the "SUSE Manager Client Tools for SLE 15 x86_64" product is "recommended"

# in github validation, the retail feature is not tested
@skip_if_github_validation
@scc_credentials
@uyuni
Scenario: Synchronize SLES 15 SP4 product with recommended sub-products for Retail feature
Expand Down Expand Up @@ -170,7 +192,6 @@ Scenario: Add openSUSE Leap Micro 5.5 Proxy, including Uyuni Client Tools


@scc_credentials
@susemanager
Scenario: Installer update channels got enabled when products were added
When I execute mgr-sync "list channels" with user "admin" and password "admin"
And I should get " [I] SLE15-SP4-Installer-Updates for x86_64 SUSE Linux Enterprise Server 15 SP4 x86_64 [sle15-sp4-installer-updates-x86_64]"
Expand Down
1 change: 0 additions & 1 deletion testsuite/features/secondary/allcli_action_chain.feature
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

# Skip if container because action chains fail on containers
# This needs to be fixed

@ssh_minion
@sle_minion
@scope_action_chains
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Copyright (c) 2018-2024 SUSE LLC
# Licensed under the terms of the MIT license.

# bootstrap channels do not work in gh validation yet
@scope_changing_software_channels
@scc_credentials
Feature: Channel subscription via SSM
Expand Down
1 change: 0 additions & 1 deletion testsuite/features/secondary/allcli_system_group.feature
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# Copyright (c) 2017-2024 SUSE LLC
# Licensed under the terms of the MIT license.

@skip_if_github_validation
@scope_visualization
Feature: Manage a group of systems

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#
# This feature depends on:
# - features/secondary/min_docker_api.feature

@skip_if_github_validation
@buildhost
@scope_building_container_images
@auth_registry
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
# This feature leaves a JeOS image built that is used in the "PXE boot a Retail terminal" feature.
# - features/secondary/srv_docker_cve_audit.feature
# If the image is not created, the message shown is "There are no entries to show."

@skip_if_github_validation
@skip_if_cloud
@buildhost
@scope_retail
Expand Down
5 changes: 0 additions & 5 deletions testsuite/features/secondary/min_action_chain.feature
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@
# - features/secondary/allcli_action_chain.feature
# If the action chain fails to be completed and run.
#
# skip on container. Running actions chains fail on container.
# This needs to be fixed

@sle_minion
@scope_action_chains
Feature: Action chains on Salt minions
Expand Down Expand Up @@ -118,7 +115,6 @@ Feature: Action chains on Salt minions
And I click on "Continue"
And I click on "Update Channel Rankings"
Then I should see a "Channel Subscriptions successfully changed for" text

Scenario: Add a configuration file deployment to the action chain on Salt minion
When I follow the left menu "Configuration > Channels"
And I follow "Action Chain Channel"
Expand Down Expand Up @@ -155,7 +151,6 @@ Feature: Action chains on Salt minions
And I check radio button "schedule-by-action-chain"
And I click on "Schedule"
Then I should see a "Action has been successfully added to the Action Chain" text

Scenario: Verify the action chain list on Salt minion
When I follow "Schedule"
And I follow "Action Chains"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
# - features/secondary/allcli_software_channels.feature
# If "SLE15-SP4-Installer-Updates for x86_64" fails to be unchecked

@skip_if_github_validation
@scc_credentials
@scope_changing_software_channels
@sle_minion
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Copyright (c) 2015-2024 SUSE LLC
# Licensed under the terms of the MIT license.

@skip_if_github_validation
@scope_onboarding
Feature: Display patches

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
# - features/secondary/min_config_state_channel_subscriptions.feature
# If the state channel fails to be deleted.

@skip_if_github_validation
@scope_configuration_channels
Feature: Configuration state channels
In order to configure systems through Salt
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# Copyright (c) 2018-2024 SUSE LLC.
# Licensed under the terms of the MIT license.

@skip_if_github_validation
@sle_minion
@scope_configuration_channels
Feature: State Configuration channels
Expand Down
2 changes: 1 addition & 1 deletion testsuite/features/secondary/min_cve_audit.feature
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Copyright (c) 2015-2022 SUSE LLC
# Licensed under the terms of the MIT license.

@skip_if_github_validation
@sle_minion
@scope_cve_audit
Feature: CVE Audit on SLE Salt Minions
Expand Down
5 changes: 4 additions & 1 deletion testsuite/features/secondary/min_recurring_action.feature
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# Copyright (c) 2020-2024 SUSE LLC
# Licensed under the terms of the MIT license.

@skip_if_github_validation
@scope_recurring_actions
Feature: Recurring Actions

Expand Down Expand Up @@ -65,6 +64,8 @@ Feature: Recurring Actions
And I follow the event "Apply recurring states [util.syncstates] scheduled" completed during last minute
And I should see a "SLS: util.syncstates" text

# This fails in github actions...
@skip_if_github_validation
Scenario: Cleanup: Disable IP forwarding
When I follow the left menu "Salt > Remote Commands"
Then I should see a "Remote Commands" text in the content area
Expand Down Expand Up @@ -163,6 +164,8 @@ Feature: Recurring Actions
Then I should see a "bunch was scheduled" text
And I wait until the table contains "FINISHED" or "SKIPPED" followed by "FINISHED" in its first rows

# Skip until we have updates in the SCC fake
@skip_if_github_validation
Scenario: Pre-requisite: check that there are updates available
Given I am on the Systems overview page of this "sle_minion"
And I wait until I see "Software Updates Available" text, refreshing the page
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
# java.salt_content_staging_advance = 0.05 (3 minutes)
# which means "beetwen 3 and 1 minutes before package installation or patching"

@skip_if_github_validation
@sle_minion
@scope_content_staging
Feature: Install a package on the SLES minion with staging enabled
Expand Down
Loading

0 comments on commit 5dd95d6

Please sign in to comment.