Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F12239632
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
4 KB
Referenced Files
None
Subscribers
None
View Options
diff --git a/top.sls b/pillar/top.sls
similarity index 87%
copy from top.sls
copy to pillar/top.sls
index 1797f76..3485510 100644
--- a/top.sls
+++ b/pillar/top.sls
@@ -1,11 +1,11 @@
# -------------------------------------------------------------
# Salt configuration for Nasqueron servers
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Project: Nasqueron
# Created: 2016-04-10
# License: Trivial work, not eligible to copyright
# -------------------------------------------------------------
base:
- 'eglide':
- - roles/shellserver/userland-software
+ eglide:
+ - users.shellusers
diff --git a/pillar/users/shellusers.sls b/pillar/users/shellusers.sls
new file mode 100644
index 0000000..ce7e1c4
--- /dev/null
+++ b/pillar/users/shellusers.sls
@@ -0,0 +1,16 @@
+# -------------------------------------------------------------
+# Salt — Users accounts list
+# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+# Project: Eglide
+# Created: 2016-04-08
+# License: Trivial work, not eligible to copyright
+# -------------------------------------------------------------
+
+# -------------------------------------------------------------
+# Users accounts
+# -------------------------------------------------------------
+
+shellusers:
+ tomjerr:
+ fullname: Tommy Aditya
+ uid: 2001
diff --git a/roles/shellserver/users/users.sls b/roles/shellserver/users/init.sls
similarity index 79%
rename from roles/shellserver/users/users.sls
rename to roles/shellserver/users/init.sls
index fb3bcf3..c75cc1e 100644
--- a/roles/shellserver/users/users.sls
+++ b/roles/shellserver/users/init.sls
@@ -1,62 +1,69 @@
# -------------------------------------------------------------
# Salt — Provision users accounts
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Project: Eglide
# Created: 2016-04-08
# Description: Adds and revokes user accounts, in the relevant
# groups and with their stable SSH keys.
# License: Trivial work, not eligible to copyright
# -------------------------------------------------------------
# -------------------------------------------------------------
# Table of contents
# -------------------------------------------------------------
#
# :: Disabled accounts
# :: Active accounts
# :: Groups
# :: Managed SSH keys
#
# -------------------------------------------------------------
# -------------------------------------------------------------
# Disabled accounts
# -------------------------------------------------------------
# Currently, there is no revoked accounts on Eglide.
#
# To disable an account, remove it from the active section and
# add here the following block:
#
# orkaevash:
# user.absent
# -------------------------------------------------------------
# Active accounts
# -------------------------------------------------------------
-tomjerr:
+{% for user, args in pillar.get('shellusers', {}).iteritems() %}
+{{user}}:
user.present:
- - fullname: Tommy Aditya
+ - fullname: {{ args['fullname'] }}
- shell: /bin/bash
- - uid: 2001
+ - uid: {{ args['uid'] }}
+{% endfor %}
# -------------------------------------------------------------
# Groups
# -------------------------------------------------------------
shell:
group.present:
- system: True
- gid: 200
- members:
- - tomjerr
+{% for user, args in pillar.get('shellusers', {}).iteritems() %}
+ - {{user}}
+{% endfor %}
# -------------------------------------------------------------
# Managed SSH keys
# -------------------------------------------------------------
-sshkeys:
+{% for user, args in pillar.get('shellusers', {}).iteritems() %}
+sshkey_{{user}}:
ssh_auth.present:
- - user: tomjerr
- - source: salt://roles/shellserver/users/files/ssh_keys/tomjerr
+ - user: {{user}}
+ - source: salt://roles/shellserver/users/files/ssh_keys/{{user}}
+{% endfor %}
+
diff --git a/top.sls b/top.sls
index 1797f76..f641f71 100644
--- a/top.sls
+++ b/top.sls
@@ -1,11 +1,12 @@
# -------------------------------------------------------------
# Salt configuration for Nasqueron servers
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Project: Nasqueron
# Created: 2016-04-10
# License: Trivial work, not eligible to copyright
# -------------------------------------------------------------
base:
'eglide':
- roles/shellserver/userland-software
+ - roles/shellserver/users
File Metadata
Details
Attached
Mime Type
text/x-diff
Expires
Sat, Oct 11, 22:45 (1 d, 16 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3064238
Default Alt Text
(4 KB)
Attached To
Mode
rOPS Nasqueron Operations
Attached
Detach File
Event Timeline
Log In to Comment