Backup work so far.

This commit is contained in:
Maurice Makaay 2020-02-07 01:10:45 +00:00
parent 51bc75cf9e
commit c5ee01f786
1 changed files with 37 additions and 7 deletions

44
demo.md
View File

@ -81,6 +81,10 @@ sidn-demo-0X# snap install lxd
sidn-demo-0X# lxd.migrate ("no" voor automatisch verwijderen LXD)
sidn-demo-0X# apt remove --purge lxd lxd-client (want zo zie ik wel hoe ver deze is)
```
Om te zorgen dat alle tooling lxc goed kan vinden:
```
sidn-demo-0X# ln -s /snap/bin/lxc /usr/bin/lxc
```
#### LXD initialiseren
@ -597,15 +601,41 @@ De basis infrastructuur staat. Nu kan de benodigde software op de
Ansible host worden geïnstalleerd.
Op het voiceplatform wordt overal gebruik gemaakt van Python3 voor Ansible.
ansible# apt install -y python3 python3-pip
ansible# pip3 install ansible
```text
ansible# apt install -y python3 python3-pip
ansible# pip3 install ansible
```
De Ansible configuratie staat in een git repository. Go get!
ansible# apt install -y git
ansible# REPO=https://git.makaay.nl/mauricem/sidn-lxd-ansible-demo.git
ansible# git clone $REPO /etc/ansible
```text
ansible# apt install -y git
ansible# REPO=https://git.makaay.nl/mauricem/sidn-lxd-ansible-demo.git
ansible# git clone $REPO /etc/ansible
```
De configuratie van Ansible zelf is redelijk eenvoudig:
```text
ansible# vi /root/.ansible.cfg
[defaults]
inventory = /etc/ansible/environments/demo/hosts
vault_password_file = /root/.ansible-vault-password
jinja2_extensions = jinja2.ext.do
[ssh_connection]
pipelining = True
```
De vault_password_file wordt gebruikt als password file voor Ansible vault.
Met vault is het mogelijk om geheime informatie (normaliter: wachtwoorden)
op te slaan in gecrypte vorm. Het te gebruiken symmetrische wachtwoord is
opgeslagen in de password file. Bijvoorbeeld:
```text
ansible# echo "My very secret 1337 super passw0rd##" \
> /root/.ansible-vault-password
ansible# chmod 600 /root/.ansible-vault-password
```