generate cle publique et privee

This commit is contained in:
root 2024-01-25 09:53:12 +01:00
parent 2606cd19b0
commit 84215f502b
4 changed files with 47 additions and 0 deletions

25
goss.yaml Normal file
View File

@ -0,0 +1,25 @@
port:
tcp:22:
listening: true
ip:
- 0.0.0.0
tcp6:22:
listening: true
ip:
- '::'
service:
sshd:
enabled: true
running: true
user:
sshd:
exists: true
uid: 101
gid: 65534
groups:
- nogroup
home: /run/sshd
shell: /usr/sbin/nologin
process:
sshd:
running: true

View File

@ -0,0 +1 @@
###Génération de clé publique et privée###

View File

@ -0,0 +1,20 @@
---
- name: on genere une cle privee pour s-backup
openssh_keypair:
path: /root/id_rsa_sbackup
type: rsa
state: present
- name: copie cle publique dans gsbstore
copy:
src: /root/id_rsa_sbackup.pub
dest: /var/www/html/gsbstore
mode: 0644
remote_src: yes
- name: copie cle privee dans gsbstore
copy:
src: /root/id_rsa_sbackup
dest: /var/www/html/gsbstore
mode: 0600
remote_src: yes

View File

@ -7,6 +7,7 @@
- s-ssh
- dnsmasq
- squid
- ssh-backup-key-gen
# - local-store
- zabbix-cli
## - syslog-cli