ssh-key should land in $HOME

During a gate test I discovered that the ssh key wasn't
generated in /root/.ssh but /home/zuul - causing an error.
This will create the key in the home directory of the user.

Change-Id: Ic095d0d05342c93f6be52b7f44bf2082d2556780
This commit is contained in:
German Eichberger 2018-08-03 22:13:42 +02:00
parent 56ebc6b36e
commit f4e3670971
1 changed files with 2 additions and 2 deletions

View File

@ -91,7 +91,7 @@
shell: > shell: >
cat /dev/zero | ssh-keygen -q -N "" cat /dev/zero | ssh-keygen -q -N ""
args: args:
creates: /root/.ssh/id_rsa.pub creates: "{{ lookup('env', 'HOME') }}/.ssh/id_rsa"
tags: tags:
- skip_ansible_lint - skip_ansible_lint
- name: Upload key to nova - name: Upload key to nova
@ -106,7 +106,7 @@
endpoint_type: "{{ octavia_ansible_endpoint_type }}" endpoint_type: "{{ octavia_ansible_endpoint_type }}"
state: present state: present
name: "octavia_key" name: "octavia_key"
public_key_file: "/root/.ssh/id_rsa.pub" public_key_file: "{{ lookup('env', 'HOME') }}/.ssh/id_rsa.pub"
run_once: true run_once: true
- name: Create a loadbalancer - name: Create a loadbalancer