diff --git a/tests/roles/development_environment/defaults/main.yaml b/tests/roles/development_environment/defaults/main.yaml index 3775bce01..c616deadc 100644 --- a/tests/roles/development_environment/defaults/main.yaml +++ b/tests/roles/development_environment/defaults/main.yaml @@ -3,3 +3,4 @@ prelaunch_test_instance_script: pre_launch.bash edpm_privatekey_path: ~/install_yamls/out/edpm/ansibleee-ssh-key-id_rsa run_pre_adoption_validation: true os_cloud_name: standalone +os_user: root diff --git a/tests/roles/development_environment/tasks/main.yaml b/tests/roles/development_environment/tasks/main.yaml index f293f5dff..71ce4a35e 100644 --- a/tests/roles/development_environment/tasks/main.yaml +++ b/tests/roles/development_environment/tasks/main.yaml @@ -6,10 +6,11 @@ EDPM_PRIVATEKEY_PATH: "{{ edpm_privatekey_path }}" OS_CLOUD_IP: "{{ standalone_ip | default(edpm_node_ip) }}" OS_CLOUD_NAME: "{{ os_cloud_name }}" + OS_USER: "{{ os_user }}" ansible.builtin.shell: cmd: | {{ shell_header }} - alias openstack="ssh -i {{ edpm_privatekey_path }} root@${OS_CLOUD_IP} OS_CLOUD=${OS_CLOUD_NAME} openstack" + alias openstack="ssh -i {{ edpm_privatekey_path }} -o StrictHostKeyChecking=no ${OS_USER}@${OS_CLOUD_IP} OS_CLOUD=${OS_CLOUD_NAME} openstack" {{ lookup('ansible.builtin.file', prelaunch_test_instance_script) }} - name: creates Barbican secret @@ -20,10 +21,11 @@ EDPM_PRIVATEKEY_PATH: "{{ edpm_privatekey_path }}" OS_CLOUD_IP: "{{ standalone_ip | default(edpm_node_ip) }}" OS_CLOUD_NAME: "{{ os_cloud_name }}" + OS_USER: "{{ os_user }}" ansible.builtin.shell: cmd: | {{ shell_header }} - alias openstack="ssh -i {{ edpm_privatekey_path }} root@${OS_CLOUD_IP} OS_CLOUD=${OS_CLOUD_NAME} openstack" + alias openstack="ssh -i {{ edpm_privatekey_path }} -o StrictHostKeyChecking=no ${OS_USER}@${OS_CLOUD_IP} OS_CLOUD=${OS_CLOUD_NAME} openstack" ${BASH_ALIASES[openstack]} secret store --name testSecret --payload 'TestPayload' - name: saves a fernet token @@ -33,10 +35,11 @@ EDPM_PRIVATEKEY_PATH: "{{ edpm_privatekey_path }}" OS_CLOUD_IP: "{{ standalone_ip | default(edpm_node_ip) }}" OS_CLOUD_NAME: "{{ os_cloud_name }}" + OS_USER: "{{ os_user }}" ansible.builtin.shell: cmd: | {{ shell_header }} - alias openstack="ssh -i {{ edpm_privatekey_path }} root@${OS_CLOUD_IP} OS_CLOUD=${OS_CLOUD_NAME} openstack" + alias openstack="ssh -i {{ edpm_privatekey_path }} -o StrictHostKeyChecking=no ${OS_USER}@${OS_CLOUD_IP} OS_CLOUD=${OS_CLOUD_NAME} openstack" ${BASH_ALIASES[openstack]} token issue -f value -c id register: before_adoption_token