summaryrefslogtreecommitdiff
path: root/roles/vault
diff options
context:
space:
mode:
authorThedro Neely <thedroneely@gmail.com>2020-03-14 04:02:59 -0400
committerThedro Neely <thedroneely@gmail.com>2020-03-14 04:02:59 -0400
commit05f1f7494fbcaa319dc70e4ddeae437c13975d0d (patch)
tree3d7ba63ead49d59f356b3e5d6900aede77efa93d /roles/vault
parentf92c43c7e3e7540a72092a2870c900aff9a9f40b (diff)
downloadplaybooks-05f1f7494fbcaa319dc70e4ddeae437c13975d0d.tar.gz
playbooks-05f1f7494fbcaa319dc70e4ddeae437c13975d0d.tar.bz2
playbooks-05f1f7494fbcaa319dc70e4ddeae437c13975d0d.zip
roles/vault/lxc: Setup lxc container
Diffstat (limited to 'roles/vault')
-rw-r--r--roles/vault/lxc.yml29
1 files changed, 29 insertions, 0 deletions
diff --git a/roles/vault/lxc.yml b/roles/vault/lxc.yml
new file mode 100644
index 0000000..0302804
--- /dev/null
+++ b/roles/vault/lxc.yml
@@ -0,0 +1,29 @@
+---
+- name: Install Vault to LXC
+ hosts: local
+
+ vars_files:
+ - ../variables.yml
+
+ tasks:
+
+ - name: Creating container
+ lxc_container:
+ name: ansible-alpine3.11
+ clone_name: "{{ vault_user }}"
+ backing_store: dir
+ state: stopped
+
+ - name: Starting container
+ lxc_container:
+ name: "{{ vault_user }}"
+ state: started
+
+ - name: Waiting for container
+ shell: until ping -c1 {{ vault_user }}.lxc; do :; done
+ changed_when: false
+
+ become: true
+ become_user: root
+
+- import_playbook: main.yml