diff options
Diffstat (limited to 'deployment/noheat/infra-openstack/ansible/roles/destroy_keypair')
-rw-r--r-- | deployment/noheat/infra-openstack/ansible/roles/destroy_keypair/tasks/main.yml | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/deployment/noheat/infra-openstack/ansible/roles/destroy_keypair/tasks/main.yml b/deployment/noheat/infra-openstack/ansible/roles/destroy_keypair/tasks/main.yml new file mode 100644 index 000000000..6025b82b3 --- /dev/null +++ b/deployment/noheat/infra-openstack/ansible/roles/destroy_keypair/tasks/main.yml @@ -0,0 +1,12 @@ +- name: Destroy keypair + os_keypair: + state: absent + name: "{{ keypair.name }}" + +- name: Destroy local keypair + file: + state: absent + path: "{{ item }}" + loop: + - "~/.ssh/{{ keypair.name }}.pub" + - "~/.ssh/{{ keypair.name }}" |