Skip to content

Commit beafd54

Browse files
committed
Fix openstack driver private address retrieval
In ansible 2.19, the template for retrieving the public(floating) address of a molecule instance returns a NoneType value, which in turn evaluates to False when compared to , which cause the private address of the instance to never get picker up as fallback. This commit changes the condition to not address | bool which in both case will evaluate to True if the retrieval of the public ip failed.
1 parent 9dfa726 commit beafd54

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/molecule_plugins/openstack/playbooks/tasks/server_addr.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
- name: Set to first addr if no floating
1818
ansible.builtin.set_fact:
1919
address: "{{ item.addresses[item.metadata.get('network', 'public')][0].addr }}"
20-
when: address == ""
20+
when: not address
2121

2222
- name: Populate instance config dict
2323
ansible.builtin.set_fact:

0 commit comments

Comments
 (0)