Rename openwrt-image role to openwrt/image
[noc.git] / ansible / roles / openwrt / openwrt-image / templates / group.j2
diff --git a/ansible/roles/openwrt/openwrt-image/templates/group.j2 b/ansible/roles/openwrt/openwrt-image/templates/group.j2
new file mode 100644 (file)
index 0000000..cb433b8
--- /dev/null
@@ -0,0 +1,21 @@
+{{ ansible_managed | comment }}
+root:x:0:
+daemon:x:1:
+adm:x:4:
+mail:x:8:
+audio:x:29:
+www-data:x:33:
+ftp:x:55:
+users:x:100:
+network:x:101:
+{% for name, opt in openwrt_users.items() %}
+{% if 'group_id' not in opt %}
+{{ name }}:x:{{ opt.id | default(loop.index + 110) }}:
+{% endif %}
+{% endfor %}
+{% if openwrt_groups is defined %}
+{% for name, opt in openwrt_groups.items() %}
+{{ name }}:x:{{ opt.id | default(loop.index + 200) }}:
+{% endfor %}
+{% endif %}
+nogroup:x:65534: