aboutsummaryrefslogtreecommitdiffstats
path: root/playbooks
diff options
context:
space:
mode:
Diffstat (limited to 'playbooks')
-rw-r--r--playbooks/p.yml13
-rw-r--r--playbooks/site.yml2
-rw-r--r--playbooks/wireguard.yml20
3 files changed, 33 insertions, 2 deletions
diff --git a/playbooks/p.yml b/playbooks/p.yml
new file mode 100644
index 0000000..49c3200
--- /dev/null
+++ b/playbooks/p.yml
@@ -0,0 +1,13 @@
+
+# p.yml
+# Execute only one role
+
+---
+
+- hosts: "{{ host }}"
+
+ tasks:
+
+ - include_role:
+ name: "{{ role }}"
+ tasks_from: "{{ task }}.yml"
diff --git a/playbooks/site.yml b/playbooks/site.yml
index 29f4033..f493eb1 100644
--- a/playbooks/site.yml
+++ b/playbooks/site.yml
@@ -2,7 +2,7 @@
# site.yml
# Deploy configuration to all servers.
-- hosts: all
+- hosts: servers
roles:
- common
diff --git a/playbooks/wireguard.yml b/playbooks/wireguard.yml
index d995b5c..320fd31 100644
--- a/playbooks/wireguard.yml
+++ b/playbooks/wireguard.yml
@@ -4,8 +4,26 @@
---
-- hosts: all
+- hosts: servers
gather_facts: no
roles:
- wireguard
+- hosts: alpine
+ vars:
+ rc_name: "wireguard"
+ rc_cmd: "/usr/bin/wg-quick"
+ rc_args: "up {{ _i.dcontroller }}"
+ rc_user: "root"
+ roles:
+ - rc
+ ignore_errors: true
+
+- hosts: openbsd
+ vars:
+ rc_name: "wireguard"
+ rc_cmd: "/usr/local/bin/wg-quick"
+ rc_args: "up {{ _i.dcontroller }}"
+ rc_user: "root"
+ roles:
+ - rc
remember that computers suck.