Commit Graph

6 Commits

Author SHA1 Message Date
Haikel Guemar 54bf1abaa4 Add-sshkey: ensure that ssh home directory exists
Some images might not have pre-created that directory, hence failing the task.
This simple step will prevent that.

Change-Id: Id2b63e84ef047f02127772c4d45b55ec360436f8
2020-09-01 14:43:15 +02:00
James E. Blair b8b54ab701 add-sshkey: make the private key owner-writable
Otherwise, it is necessary to change perms to remove it later.

Change-Id: I405cec0a1434a95a0a0e3b60b660cdcadc9e9b24
2017-10-19 14:23:28 -07:00
James E. Blair 361b11f3e3 Add-sshkey: remove pubkey if present
A mismatched private/public pair causes openssh to fail.  Go figure.

Change-Id: Ic5a51cc5a0b0d04bb2bb617c08f7d5425c9cf36f
2017-10-19 11:52:15 -07:00
Jens Harbott 66940dc5f5 The copy module needs dest instead of path
Change-Id: I797766dc8406039732d5343fa63c6bb9e4221af6
2017-10-19 18:15:13 +00:00
Jens Harbott a1fda7fb7a Use copy instead of file for add-sshkey task
Also set a safe mode just in case.

Change-Id: Ica6ca8f5e39f64f8d944d1b7b9fd9a7229e8b988
2017-10-19 17:22:27 +00:00
Monty Taylor b214e276ec
Add role for adding ssh key to remote nodes
Some tasks, such as proposal tasks, need to make outbound ssh
connections via non-ansible means. Add a role that takes a secret and
writes out a private key and optionally a known hosts entry.

Change-Id: I569b93ba0e775896b5a4f59b544fe32d1e2dce9b
2017-08-25 17:18:27 -05:00