diff --git a/tasks/keystone_credential_distribute.yml b/tasks/keystone_credential_distribute.yml index 1239de8a..8af20fae 100644 --- a/tasks/keystone_credential_distribute.yml +++ b/tasks/keystone_credential_distribute.yml @@ -19,7 +19,7 @@ -avz \ --delete \ {{ keystone_credential_key_repository }}/ \ - {{ keystone_system_user_name }}@{{ hostvars[item]['ansible_ssh_host'] }}:{{ keystone_credential_key_repository }}/ + {{ keystone_system_user_name }}@{{ hostvars[item]['ansible_host'] }}:{{ keystone_credential_key_repository }}/ become: yes become_user: "{{ keystone_system_user_name }}" with_items: "{{ groups['keystone_all'][1:] }}" diff --git a/tasks/keystone_fernet_keys_distribute.yml b/tasks/keystone_fernet_keys_distribute.yml index 807e2072..92d342d2 100644 --- a/tasks/keystone_fernet_keys_distribute.yml +++ b/tasks/keystone_fernet_keys_distribute.yml @@ -19,7 +19,7 @@ -avz \ --delete \ {{ keystone_fernet_tokens_key_repository }}/ \ - {{ keystone_system_user_name }}@{{ hostvars[item]['ansible_ssh_host'] }}:{{ keystone_fernet_tokens_key_repository }}/ + {{ keystone_system_user_name }}@{{ hostvars[item]['ansible_host'] }}:{{ keystone_fernet_tokens_key_repository }}/ become: yes become_user: "{{ keystone_system_user_name }}" with_items: "{{ groups['keystone_all'][1:] }}" diff --git a/tasks/keystone_service_setup.yml b/tasks/keystone_service_setup.yml index 5e40ffc4..0ee2821f 100644 --- a/tasks/keystone_service_setup.yml +++ b/tasks/keystone_service_setup.yml @@ -15,14 +15,14 @@ - name: Wait for keystone admin to come up wait_for: - host: "{{ ansible_ssh_host }}" + host: "{{ ansible_host }}" port: "{{ keystone_admin_port }}" timeout: 25 delay: 10 - name: Wait for keystone service to come up wait_for: - host: "{{ ansible_ssh_host }}" + host: "{{ ansible_host }}" port: "{{ keystone_service_port }}" timeout: 25 delay: 10 diff --git a/templates/keystone-credential-rotate.sh.j2 b/templates/keystone-credential-rotate.sh.j2 index 5cc07650..56f16f34 100644 --- a/templates/keystone-credential-rotate.sh.j2 +++ b/templates/keystone-credential-rotate.sh.j2 @@ -46,7 +46,7 @@ function autorotate { -avz \ --delete \ {{ keystone_credential_key_repository }}/ \ - {{ keystone_system_user_name }}@{{ hostvars[host]['ansible_ssh_host'] }}:{{ keystone_credential_key_repository }}/ + {{ keystone_system_user_name }}@{{ hostvars[host]['ansible_host'] }}:{{ keystone_credential_key_repository }}/ {%- endif %} diff --git a/templates/keystone-fernet-rotate.sh.j2 b/templates/keystone-fernet-rotate.sh.j2 index 43239027..121b383a 100644 --- a/templates/keystone-fernet-rotate.sh.j2 +++ b/templates/keystone-fernet-rotate.sh.j2 @@ -35,7 +35,7 @@ function autorotate { -avz \ --delete \ {{ keystone_fernet_tokens_key_repository }}/ \ - {{ keystone_system_user_name }}@{{ hostvars[host]['ansible_ssh_host'] }}:{{ keystone_fernet_tokens_key_repository }}/ + {{ keystone_system_user_name }}@{{ hostvars[host]['ansible_host'] }}:{{ keystone_fernet_tokens_key_repository }}/ {%- endif %} diff --git a/tests/inventory b/tests/inventory index 0039f11c..f51dd7a8 100644 --- a/tests/inventory +++ b/tests/inventory @@ -1,8 +1,8 @@ [all] localhost ansible_become=True -infra1 ansible_ssh_host=10.1.0.2 ansible_host=10.1.0.2 ansible_become=True ansible_user=root -keystone1 ansible_ssh_host=10.1.0.3 ansible_host=10.1.0.3 ansible_become=True ansible_user=root -keystone2 ansible_ssh_host=10.1.0.4 ansible_host=10.1.0.4 ansible_become=True ansible_user=root +infra1 ansible_host=10.1.0.2 ansible_become=True ansible_user=root +keystone1 ansible_host=10.1.0.3 ansible_become=True ansible_user=root +keystone2 ansible_host=10.1.0.4 ansible_become=True ansible_user=root [all_containers] infra1