Skip to content

Commit 31745a1

Browse files
committed
fix: Unset OS volume when deplying on ECMWF site
1 parent 4b3b52d commit 31745a1

4 files changed

Lines changed: 11 additions & 3 deletions

File tree

playbooks/ipa-client-provisioning/ipa-client-provisioning.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,9 @@
172172
# by Ansible via ssh from localhost. It'll be removed after successful start if not requested by the user!
173173
instance_has_fip = true
174174
175+
{% if hostvars['localhost']['ewc_tf_module_openstack_compute']['os_volume'] is not none %}
175176
os_volume = {{ hostvars['localhost']['ewc_tf_module_openstack_compute']['os_volume'] | to_json }}
177+
{% endif %}
176178
177179
tags = {
178180
provisioning-tool = "terraform"
@@ -244,7 +246,7 @@
244246
ansible_host: "{{ remote_host_public_ip_fact }}"
245247
ansible_user: "{{ 'ubuntu' if image_name | lower | regex_search('^ubuntu') else 'cloud-user' }}"
246248
ansible_ssh_private_key_file: "{{ hostvars['localhost']['private_keypair_path_fact'] }}"
247-
ansible_ssh_common_args: "-o StrictHostKeyChecking=accept-new"
249+
ansible_ssh_common_args: "-o StrictHostKeyChecking=no"
248250

249251
- name: Install IPA client and enroll into an IPA server's LDAP/DNS services
250252
hosts: ipa_client

playbooks/ipa-server-provisioning/ipa-server-provisioning.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,9 @@
176176
# by Ansible via ssh from localhost. It'll be removed after successful start!
177177
instance_has_fip = true
178178
179+
{% if hostvars['localhost']['ewc_tf_module_openstack_compute']['os_volume'] is not none %}
179180
os_volume = {{ hostvars['localhost']['ewc_tf_module_openstack_compute']['os_volume'] | to_json }}
181+
{% endif %}
180182
181183
tags = {
182184
provisioning-tool = "terraform"

playbooks/remote-desktop-provisioning/remote-desktop-provisioning.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,9 @@
155155
# by Ansible via ssh from localhost. It'll be removed after successful start!
156156
instance_has_fip = true
157157
158+
{% if hostvars['localhost']['ewc_tf_module_openstack_compute']['os_volume'] is not none %}
158159
os_volume = {{ hostvars['localhost']['ewc_tf_module_openstack_compute']['os_volume'] | to_json }}
160+
{% endif %}
159161
160162
tags = {
161163
provisioning-tool = "terraform"
@@ -228,7 +230,7 @@
228230
ansible_host: "{{ remote_host_public_ip_fact }}"
229231
ansible_user: "cloud-user"
230232
ansible_ssh_private_key_file: "{{ hostvars['localhost']['private_keypair_path_fact'] }}"
231-
ansible_ssh_common_args: "-o StrictHostKeyChecking=accept-new"
233+
ansible_ssh_common_args: "-o StrictHostKeyChecking=no"
232234

233235
- name: Configure Remote Desktop server
234236
hosts: remote_desktop

playbooks/ssh-bastion-provisioning/ssh-bastion-provisioning.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,9 @@
149149
# by Ansible via ssh from localhost. It'll be removed after successful start!
150150
instance_has_fip = true
151151
152+
{% if hostvars['localhost']['ewc_tf_module_openstack_compute']['os_volume'] is not none %}
152153
os_volume = {{ hostvars['localhost']['ewc_tf_module_openstack_compute']['os_volume'] | to_json }}
154+
{% endif %}
153155
154156
tags = {
155157
provisioning-tool = "terraform"
@@ -222,7 +224,7 @@
222224
ansible_host: "{{ remote_host_public_ip_fact }}"
223225
ansible_user: "cloud-user"
224226
ansible_ssh_private_key_file: "{{ hostvars['localhost']['private_keypair_path_fact'] }}"
225-
ansible_ssh_common_args: "-o StrictHostKeyChecking=accept-new"
227+
ansible_ssh_common_args: "-o StrictHostKeyChecking=no"
226228

227229
- name: Configure SSH bastion server
228230
hosts: "ssh_bastion"

0 commit comments

Comments
 (0)