summaryrefslogtreecommitdiffstats
path: root/salt
diff options
context:
space:
mode:
Diffstat (limited to 'salt')
-rw-r--r--salt/top.sls11
1 files changed, 11 insertions, 0 deletions
diff --git a/salt/top.sls b/salt/top.sls
new file mode 100644
index 0000000..de9b24b
--- /dev/null
+++ b/salt/top.sls
@@ -0,0 +1,11 @@
+{% set client_id = salt['grains.get']('id') %}
+{% set roles = salt['grains.get']('roles', []) %}
+
+{{ saltenv }}:
+ '*':
+ - baseline
+ {% for role in roles %}
+ 'roles:{{ role }}':
+ - match: grain
+ - role.{{ role }}
+ {% endfor %}