Changing writing of ssh priv key for EOF at the end of the file

Signed-off-by: Alexis Pentori <alexis@status.im>
This commit is contained in:
Alexis Pentori 2023-06-01 14:50:52 +02:00
parent c44ac9d541
commit c72eaafe47
No known key found for this signature in database
GPG Key ID: 65250D2801E47A10
1 changed files with 3 additions and 1 deletions

View File

@ -22,10 +22,12 @@
mode: 0750
when: github_webhook_ssh_key is defined
# The field content need the literral block style ( `|` ) to keep the EOF at the end and ensure the validity of the key.
- name: Create SSH private key
copy:
dest: '{{ github_webhook_home }}/.ssh/id_rsa'
content: '{{ github_webhook_ssh_key }}'
content: |
{{ github_webhook_ssh_key }}
owner: '{{ github_webhook_service_user }}'
group: '{{ github_webhook_service_user }}'
mode: 0400