@scope_ansible
@scope_salt_ssh
@ssh_minion
@susemanager
Feature: 0125 - Operate an Ansible control node in SSH minion
File name: minssh_ansible_control_node.feature
Relative path: secondary/minssh_ansible_control_node.feature
@scope_ansible
@scope_salt_ssh
@ssh_minion
@susemanager
Scenario: Pre-requisite: Subscribe SUSE minions to SLE-Module-Python3-15-SP7-Pool for x86_64
Given
I am on the Systems overview page of this "ssh_minion"
0s
When
I follow "Software" in the content area
0s
And
I follow "Software Channels" in the content area
0s
And
I check "SLE-Module-Python3-15-SP7-Pool for x86_64" by label
0s
And
I click on "Next"
0s
And
I click on "Confirm"
0s
And
I wait until I see "Changing the channels has been scheduled." text
0s
And
I follow "scheduled"
0s
And
I wait until I see "1 system successfully completed this action" text, refreshing the page
0s
@scope_ansible
@scope_salt_ssh
@ssh_minion
Scenario: Enable "Ansible control node" system type
Given
I am on the Systems overview page of this "ssh_minion"
00:00:01.560
When
I follow "Properties" in the content area
00:00:00.073
And
I check "ansible_control_node"
00:00:00.081
And
I click on "Update Properties"
00:00:01.801
Then
I wait until I see "Ansible Control Node type has been applied." text
00:00:00.087
@scope_ansible
@scope_salt_ssh
@ssh_minion
Scenario: Apply highstate and check that Ansible is installed
Given
I am on the Systems overview page of this "ssh_minion"
00:00:01.869
When
I follow "States" in the content area
00:00:00.069
And
I click on "Apply Highstate"
00:00:00.063
And
I wait until event "Apply highstate scheduled" is completed
00:01:16.077
+ Show Error
+ Show Info
+ Screenshot
unknown error - Event failed (SystemCallError) ./features/step_definitions/navigation_steps.rb:107:in `block (2 levels) in (top (required))' ./features/support/commonlib.rb:100:in `block in repeat_until_timeout' ./features/support/commonlib.rb:89:in `repeat_until_timeout' ./features/step_definitions/navigation_steps.rb:99:in `/^I wait at most (\d+) seconds until the event is completed, refreshing the page$/' ./features/step_definitions/common_steps.rb:157:in `/^I wait (\d+) seconds until the event is picked up and (\d+) seconds until the event "([^"]*)" is completed$/' ./features/step_definitions/common_steps.rb:174:in `/^I wait at most (\d+) seconds until event "([^"]*)" is completed$/' ./features/step_definitions/common_steps.rb:151:in `/^I wait until event "([^"]*)" is completed$/' features/secondary/minssh_ansible_control_node.feature:38:in `I wait until event "Apply highstate scheduled" is completed'
Event Details:
Failed to apply state(s): highstate
----------
ID: sync_states
Function: saltutil.sync_states
Name: sync_states
Result: true
Comment: No updates to sync
Started: 00:10:50.885818
Duration: 1195.232
SLS: util.syncstates
Changed: {}
----------
ID: mgr_absent_ca_package
Function: pkg.removed
Name: rhn-org-trusted-ssl-cert
Result: true
Comment: All specified packages are already absent
Started: 00:10:53.331689
Duration: 1040.298
SLS: certs
Changed: {}
----------
ID: mgr_ca_cert
Function: file.managed
Name: /etc/pki/trust/anchors/RHN-ORG-TRUSTED-SSL-CERT
Result: true
Comment: File /etc/pki/trust/anchors/RHN-ORG-TRUSTED-SSL-CERT is in the correct state
Started: 00:10:54.374619
Duration: 91.474
SLS: certs
Changed: {}
----------
ID: update-ca-certificates
Function: cmd.run
Name: /usr/sbin/update-ca-certificates
Result: true
Comment: State was not run because none of the onchanges reqs changed
Started: 00:10:54.467198
Duration: 0.005
SLS: certs
Changed: {}
----------
ID: mgr_proxy_ca_cert_symlink
Function: file.symlink
Name: /usr/share/rhn/RHN-ORG-TRUSTED-SSL-CERT
Result: true
Comment: onlyif condition is false
Started: 00:10:54.467284
Duration: 685.263
SLS: certs
Changed: {}
----------
ID: mgr_deploy_tools_uyuni_key
Function: file.managed
Name: /etc/pki/rpm-gpg/uyuni-tools-gpg-pubkey-0d20833e.key
Result: true
Comment: File /etc/pki/rpm-gpg/uyuni-tools-gpg-pubkey-0d20833e.key is in the correct state
Started: 00:10:55.152671
Duration: 84.712
SLS: channels.gpg-keys
Changed: {}
----------
ID: mgr_deploy_suse_addon_key
Function: file.managed
Name: /etc/pki/rpm-gpg/suse-addon-97a636db0bad8ecc.key
Result: true
Comment: File /etc/pki/rpm-gpg/suse-addon-97a636db0bad8ecc.key is in the correct state
Started: 00:10:55.237496
Duration: 61.612
SLS: channels.gpg-keys
Changed: {}
----------
ID: mgr_deploy_suse16_gpg_key
Function: file.managed
Name: /etc/pki/rpm-gpg/suse16-gpg-pubkey-09d9ea69.key
Result: true
Comment: File /etc/pki/rpm-gpg/suse16-gpg-pubkey-09d9ea69.key is in the correct state
Started: 00:10:55.299228
Duration: 62.39
SLS: channels.gpg-keys
Changed: {}
----------
ID: file_///etc/pki/rpm-gpg/uyuni-tools-gpg-pubkey-0d20833e.key
Function: module.run
Name: pkg.add_repo_key
Result: true
Comment: Module function pkg.add_repo_key executed
Started: 00:10:55.361740
Duration: 57.579
SLS: channels.gpg-keys
Changed: ret: true
----------
ID: file_///usr/lib/rpm/gnupg/keys/gpg-pubkey-29b700a4-62b07e22.asc
Function: module.run
Name: pkg.add_repo_key
Result: true
Comment: Module function pkg.add_repo_key executed
Started: 00:10:55.419438
Duration: 58.656
SLS: channels.gpg-keys
Changed: ret: true
----------
ID: mgrchannels_repo
Function: file.managed
Name: /etc/zypp/repos.d/susemanager:channels.repo
Result: true
Comment: File /etc/zypp/repos.d/susemanager:channels.repo is in the correct state
Started: 00:10:55.478309
Duration: 192.888
SLS: channels
Changed: {}
----------
ID: pkg_installed
Function: pkg.installed
Name: pkg_installed
Result: true
Comment: No packages to install provided
Started: 00:10:55.671775
Duration: 0.831
SLS: packages.packages_939f6e6a0154555271c8926e6a0ef62c
Changed: {}
----------
ID: pkg_removed
Function: pkg.removed
Name: pkg_removed
Result: true
Comment: All specified packages are already absent
Started: 00:10:55.672752
Duration: 12.046
SLS: packages.packages_939f6e6a0154555271c8926e6a0ef62c
Changed: {}
----------
ID: pkg_latest
Function: pkg.latest
Name: pkg_latest
Result: true
Comment: No packages to install provided
Started: 00:10:55.685013
Duration: 0.608
SLS: packages.packages_939f6e6a0154555271c8926e6a0ef62c
Changed: {}
----------
ID: disable_spacewalksd
Function: service.dead
Name: rhnsd
Result: true
Comment: The named service rhnsd is not available
Started: 00:10:55.685683
Duration: 16.075
SLS: services.salt-minion
Changed: {}
----------
ID: disable_spacewalk-update-status
Function: service.dead
Name: spacewalk-update-status
Result: true
Comment: The named service spacewalk-update-status is not available
Started: 00:10:55.701893
Duration: 11.154
SLS: services.salt-minion
Changed: {}
----------
ID: disable_osad
Function: service.dead
Name: osad
Result: true
Comment: The named service osad is not available
Started: 00:10:55.713153
Duration: 12.57
SLS: services.salt-minion
Changed: {}
----------
ID: remove_traditional_stack_all
Function: pkg.removed
Name: remove_traditional_stack_all
Result: true
Comment: All specified packages are already absent
Started: 00:10:55.725831
Duration: 11.46
SLS: services.salt-minion
Changed: {}
----------
ID: remove_traditional_stack
Function: pkg.removed
Name: remove_traditional_stack
Result: true
Comment: All specified packages are already absent
Started: 00:10:55.737381
Duration: 44.73
SLS: services.salt-minion
Changed: {}
----------
ID: logrotate_configuration
Function: file.managed
Name: /etc/logrotate.d/salt-ssh
Result: true
Comment: File /etc/logrotate.d/salt-ssh is in the correct state
Started: 00:10:55.782203
Duration: 80.282
SLS: services.salt-minion
Changed: {}
----------
ID: /etc/sysconfig/rhn/systemid
Function: file.managed
Name: /etc/sysconfig/rhn/systemid
Result: true
Comment: File /etc/sysconfig/rhn/systemid exists with proper permissions. No changes made.
Started: 00:10:55.862581
Duration: 1.477
SLS: services.salt-minion
Changed: {}
----------
ID: mgr_ansible_installed
Function: pkg.installed
Name: mgr_ansible_installed
Result: false
Comment: An error was encountered while installing package(s): Zypper command failure: Running as unit: run-p21142-i18884.scope; invocation ID: 66956dbb73fb495e8c96c59feedc53b3
Package 'ansible' not found.Loading repository data...
Reading installed packages...
Started: 00:10:55.864153
Duration: 2358.816
SLS: ansible
Changed: {}
Then
"ansible" should be installed on "ssh_minion"
0s
@scope_ansible
@scope_salt_ssh
@ssh_minion
Scenario: The Ansible tab appears in the system overview page
Given
I am on the Systems overview page of this "ssh_minion"
00:00:01.559
When
I follow "Ansible" in the content area
00:00:00.077
Then
I should see a "Ansible Control Node Configuration" text
00:00:00.062
@scope_ansible
@scope_salt_ssh
@ssh_minion
Scenario: Configure some inventory and playbooks path
Given
I am on the Systems overview page of this "ssh_minion"
00:00:01.587
When
I follow "Ansible" in the content area
00:00:00.065
Then
I should see a "Ansible Control Node Configuration" text
00:00:00.063
And
I enter "/srv/playbooks/" as "new_playbook_path_input"
00:00:00.269
And
I click on "new_playbook_path_save"
00:00:00.060
And
I enter "/srv/playbooks/orion_dummy/hosts" as "new_inventory_path_input"
00:00:00.101
And
I click on "new_inventory_path_save"
00:00:00.062
Given
I am on the Systems overview page of this "ssh_minion"
00:00:02.139
When
I follow "Ansible" in the content area
00:00:00.062
And
I follow "Inventories" in the content area
00:00:00.062
And
I wait until I see "/srv/playbooks/orion_dummy/hosts" text
00:00:00.368
And
I click on the inventory accordion for "/srv/playbooks/orion_dummy/hosts"
00:00:00.050
Text 'myself' not found (ScriptError) ./features/step_definitions/navigation_steps.rb:40:in `/^I wait until I see "([^"]*)" text$/' features/secondary/minssh_ansible_control_node.feature:61:in `I wait until I see "myself" text'
@scope_ansible
@scope_salt_ssh
@ssh_minion
Scenario: Discover playbooks and display them
Given
I am on the Systems overview page of this "ssh_minion"
00:00:01.587
When
I follow "Ansible" in the content area
00:00:00.074
And
I follow "Playbooks" in the content area
00:00:00.067
And
I wait until I see "/srv/playbooks" text
00:00:00.245
And
I click on "/srv/playbooks"
00:00:00.057
Then
I wait until I see "/srv/playbooks/orion_dummy/playbook_orion_dummy.yml" text
00:04:10.073
+ Show Error
+ Screenshot
Text '/srv/playbooks/orion_dummy/playbook_orion_dummy.yml' not found (ScriptError) ./features/step_definitions/navigation_steps.rb:40:in `/^I wait until I see "([^"]*)" text$/' features/secondary/minssh_ansible_control_node.feature:69:in `I wait until I see "/srv/playbooks/orion_dummy/playbook_orion_dummy.yml" text'
@scope_ansible
@scope_salt_ssh
@ssh_minion
Scenario: Run a playbook using custom inventory
Given
I am on the Systems overview page of this "ssh_minion"
00:00:01.782
When
I follow "Ansible" in the content area
00:00:00.080
And
I follow "Playbooks" in the content area
00:00:00.065
And
I wait until I see "/srv/playbooks" text
00:00:00.249
And
I click on "/srv/playbooks"
00:00:00.057
And
I wait until I see "/srv/playbooks/orion_dummy/playbook_orion_dummy.yml" text
00:04:10.043
+ Show Error
+ Screenshot
Text '/srv/playbooks/orion_dummy/playbook_orion_dummy.yml' not found (ScriptError) ./features/step_definitions/navigation_steps.rb:40:in `/^I wait until I see "([^"]*)" text$/' features/secondary/minssh_ansible_control_node.feature:77:in `I wait until I see "/srv/playbooks/orion_dummy/playbook_orion_dummy.yml" text'
And
I click on "orion_dummy/playbook_orion_dummy.yml"
0s
And
I wait until I see "Playbook Content" text
0s
And
I select "/srv/playbooks/orion_dummy/hosts" from "inventory-path-select"
0s
And
I click on "Schedule"
0s
Then
I should see a "Playbook execution has been scheduled" text
0s
And
I wait until event "Execute playbook 'playbook_orion_dummy.yml' scheduled" is completed
0s
And
file "/tmp/file.txt" should exist on "ssh_minion"
0s
@scope_ansible
@scope_salt_ssh
@ssh_minion
Scenario: Cleanup: Disable Ansible and remove test playbooks and inventory file
Given
I am on the Systems overview page of this "ssh_minion"
00:00:01.553
When
I follow "Properties" in the content area
00:00:00.074
And
I uncheck "ansible_control_node"
00:00:10.083
And
I click on "Update Properties"
00:00:01.239
Then
I should see a "System properties changed" text
00:00:00.092
And
I remove package "orion-dummy" from this "ssh_minion" without error control
00:00:01.164
And
I remove "/tmp/file.txt" from "ssh_minion"
00:00:00.422
@scope_ansible
@scope_salt_ssh
@ssh_minion
@susemanager
Scenario: Cleanup: Unsubscribe SUSE minions from SLE-Module-Python3-15-SP7-Pool for x86_64
Given
I am on the Systems overview page of this "ssh_minion"
0s
When
I follow "Software" in the content area
0s
And
I follow "Software Channels" in the content area
0s
And
I uncheck "SLE-Module-Python3-15-SP7-Pool for x86_64" by label
0s
And
I click on "Next"
0s
And
I click on "Confirm"
0s
And
I wait until I see "Changing the channels has been scheduled." text
0s
And
I follow "scheduled"
0s
And
I wait until I see "1 system successfully completed this action" text, refreshing the page
0s
@scope_ansible
@scope_salt_ssh
@ssh_minion
Scenario: Cleanup: Disable "Ansible control node" system type
Given
I am on the Systems overview page of this "ssh_minion"
00:00:01.533
When
I follow "Properties" in the content area
00:00:00.065
And
I uncheck "ansible_control_node"
00:00:10.037
And
I click on "Update Properties"
00:00:00.853
@scope_ansible
@scope_salt_ssh
@ssh_minion
Scenario: Cleanup: Apply highstate to disable the minion as an "Ansible control node"
Given
I am on the Systems overview page of this "ssh_minion"
00:00:01.628
When
I follow "States" in the content area
00:00:00.085
And
I click on "Apply Highstate"
00:00:00.089
And
I wait until event "Apply highstate scheduled" is completed
00:00:38.799