Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.
Ce dépôt est archivé. Vous pouvez voir les fichiers et le cloner, mais vous ne pouvez pas pousser ni ouvrir de ticket/demande d'ajout.

ssh.yml 523B

il y a 6 ans
il y a 6 ans
il y a 6 ans
il y a 6 ans
12345678910111213141516171819202122
  1. ---
  2. - name: ssh key
  3. user:
  4. name: root
  5. generate_ssh_key: yes
  6. ssh_key_type: ed25519
  7. when:
  8. - root_ssh_key
  9. - not root_target_directory is defined
  10. - name: ssh directory
  11. file:
  12. path: "{{ root_target_directory | default('') }}/root/.ssh"
  13. state: directory
  14. when: root_ssh_authorized_keys is defined
  15. - name: ssh authorized keys
  16. template:
  17. src: ssh_authorized_keys.j2
  18. dest: "{{ root_target_directory | default('') }}/root/.ssh/authorized_keys"
  19. when: root_ssh_authorized_keys is defined