mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-08-29 15:06:26 +02:00
Further optimisation of system user creation
This commit is contained in:
@@ -20,13 +20,13 @@ primary_domain: "{{primary_domain_sld}}.{{primary_domain_tld}}" # Primar
|
||||
_users_administrator_username: "{{ users.administrator.username | default('administrator') }}"
|
||||
_users_administrator_email: "{{ users.administrator.email | default(_users_administrator_username ~ '@' ~ primary_domain) }}"
|
||||
|
||||
# Helper Variables for bouncer
|
||||
_users_bouncer_username: "{{ users.bouncer.username | default('bouncer') }}"
|
||||
_users_bouncer_email: "{{ users.bouncer.email | default(_users_bouncer_username ~ '@' ~ primary_domain) }}"
|
||||
# Helper Variables for bounce
|
||||
_users_bounce_username: "{{ users.bounce.username | default('bounce') }}"
|
||||
_users_bounce_email: "{{ users.bounce.email | default(_users_bounce_username ~ '@' ~ primary_domain) }}"
|
||||
|
||||
# Helper Variables for no-reply
|
||||
_users_no_reply_username: "{{ users.no-reply.username | default('no-reply') }}"
|
||||
_users_no_reply_email: "{{ users.no-reply.email | default(_users_no_reply_username ~ '@' ~ primary_domain) }}"
|
||||
_users_no_reply_username: "{{ users['no-reply'].username | default('no-reply') }}"
|
||||
_users_no_reply_email: "{{ users['no-reply'].email | default(_users_no_reply_username ~ '@' ~ primary_domain) }}"
|
||||
|
||||
# Administrator
|
||||
default_users:
|
||||
@@ -38,12 +38,12 @@ default_users:
|
||||
gid: 1001 # Posix Group ID
|
||||
is_admin: true # Define as admin user
|
||||
|
||||
bouncer:
|
||||
username: "{{ _users_bouncer_username }}" # Bounce-handler account username
|
||||
email: "{{ _users_bouncer_email }}" # Email address for handling bounces
|
||||
bounce:
|
||||
username: "{{ _users_bounce_username }}" # Bounce-handler account username
|
||||
email: "{{ _users_bounce_email }}" # Email address for handling bounces
|
||||
password: "{{ansible_become_password}}" # Example initialisation password needs to be set in inventory file
|
||||
uid: 1002 # Posix User ID for bouncer
|
||||
gid: 1002 # Posix Group ID for bouncer
|
||||
uid: 1002 # Posix User ID for bounce
|
||||
gid: 1002 # Posix Group ID for bounce
|
||||
|
||||
no-reply:
|
||||
username: "{{ _users_no_reply_username }}" # No-reply account username
|
||||
|
@@ -1,12 +1,9 @@
|
||||
# Email Configuration
|
||||
default_system_email:
|
||||
local: no-reply
|
||||
domain: "{{primary_domain}}"
|
||||
username: "no-reply@{{primary_domain}}"
|
||||
host: "mail.{{primary_domain}}"
|
||||
port: 465
|
||||
tls: true
|
||||
start_tls: false
|
||||
from: "no-reply@{{primary_domain}}"
|
||||
smtp: true
|
||||
# password: # Needs to be defined in inventory file
|
Reference in New Issue
Block a user