You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
Go to file
Alexandre IOOSS cd00daaad9 Merge branch 'fix_matrix_webhooks' into 'master'
Changed URL to make the Webhooks appservice work

See merge request aurore/ansible!26
5 years ago
group_vars Fix CI 5 years ago
roles Changed URL to make the Webhooks appservice work 5 years ago
.gitignore Initial commit 6 years ago
.gitlab-ci.yml Feat: update ansible-lint to version 4.0.0 5 years ago
.yamllint.yml Fix: line length 5 years ago
README.md Use YARN module from Ansible 2.7 5 years ago
ansible.cfg Do not create .retry for playbooks 5 years ago
base.yml Security policies based on ANSSI recommandations 5 years ago
codimd.yml Add matrix-appservice-webhooks and move nodejs tasks 5 years ago
dokuwiki.yml Fix: blank lines and trailing spaces 5 years ago
etherpad.yml Add matrix-appservice-webhooks and move nodejs tasks 5 years ago
hosts Merge branch 'add_matrix_services' into 'master' 5 years ago
ldap.yml Fix: line length 5 years ago
matrix.yml Add matrix-appservice-webhooks and move nodejs tasks 5 years ago
nginx-reverse-proxy.yml Use adm DNS for reverse proxy 5 years ago
upgrade.yml Fix: add a retry statement to remote package tasks 5 years ago

README.md

Playbook et rôles Ansible d'Aurore

Ces politiques de déployement nécessite Ansible 2.7 ou plus récent. Le paquet dans Debian Buster est suffisamment à jour, sinon vous pouvez l'obtenir de la façon suivante :

pip3 install --user ansible

Exécution d'un playbook

Pour appliquer le playbook base.yml :

ansible-playbook --ask-vault-pass base.yml

Il est souhaitable de faire un test avant avec --check si on a des doutes !

FAQ

Mettre sa clé SSH sur une machine

ssh-copy-id -i ~/.ssh/id_rsa_aurore.pub virtu.fede-aurore.net

Automatiquement ajouter fingerprint ECDSA (dangereux !)

Il faut changer la variable d'environnement suivante : ANSIBLE_HOST_KEY_CHECKING=0.

Configurer la connexion au bastion

Envoyer son agent SSH peut être dangereux (source).

On va utiliser plutôt ProxyJump. Dans la configuration SSH :

# Use a key to log on all Aurore servers
# and use a bastion
Host 10.128.0.* *.adm.auro.re
    IdentityFile ~/.ssh/id_rsa_aurore
    ProxyJump proxy.auro.re

Il faut savoir que depuis Ansible 2.5, des connexions persistantes sont créées vers les serveurs puis détruites à la fin de l'exécution. Il faut donc éviter de lancer une connexion SSH persistante pendant l'exécution d'Ansible.

Lister tout ce que sait Ansible sur un hôte

ansible -i hosts ldap-replica-fleming1.adm.auro.re -m setup --ask-vault-pass