aboutsummaryrefslogtreecommitdiff
path: root/roles/ad
diff options
context:
space:
mode:
authorB Stack <bgstack15@gmail.com>2016-09-23 10:27:15 -0400
committerB Stack <bgstack15@gmail.com>2016-09-23 10:27:15 -0400
commit5e8a7ac51e486044c8d14694e5f51173dd63f628 (patch)
tree586bba6cab996f95a39f6a4620e457cf5924d770 /roles/ad
parentInitial file upload (diff)
downloadansible01-5e8a7ac51e486044c8d14694e5f51173dd63f628.tar.gz
ansible01-5e8a7ac51e486044c8d14694e5f51173dd63f628.tar.bz2
ansible01-5e8a7ac51e486044c8d14694e5f51173dd63f628.zip
Initial file upload
Diffstat (limited to 'roles/ad')
-rw-r--r--roles/ad/handlers/main.yml3
-rw-r--r--roles/ad/main.yml9
-rw-r--r--roles/ad/tasks/main.yml39
l---------roles/ad/templates1
l---------roles/ad/vars1
5 files changed, 53 insertions, 0 deletions
diff --git a/roles/ad/handlers/main.yml b/roles/ad/handlers/main.yml
new file mode 100644
index 0000000..db92053
--- /dev/null
+++ b/roles/ad/handlers/main.yml
@@ -0,0 +1,3 @@
+---
+- name: sssd restart
+ service: name=sssd state=restarted
diff --git a/roles/ad/main.yml b/roles/ad/main.yml
new file mode 100644
index 0000000..af79d33
--- /dev/null
+++ b/roles/ad/main.yml
@@ -0,0 +1,9 @@
+---
+- hosts: all
+ vars_files:
+ - vars/default.yml
+ - hosts/default.yml
+ tasks:
+ - include: tasks/main.yml
+ handlers:
+ - handlers/main.yml
diff --git a/roles/ad/tasks/main.yml b/roles/ad/tasks/main.yml
new file mode 100644
index 0000000..a8275e5
--- /dev/null
+++ b/roles/ad/tasks/main.yml
@@ -0,0 +1,39 @@
+---
+- name: ad get vars
+ include_vars: default.yml
+
+- name: ad get OS vars
+ include_vars: '{{ item }}'
+ with_first_found:
+ - '{{ ansible_distribution }}.yml'
+ - default.yml
+
+- name: ad get host-specific vars
+ include_vars: '{{ item }}'
+ with_first_found:
+ - files:
+ - '../hosts/{{ ansible_fqdn }}.yml'
+ skip: true
+
+- name: sssd conf
+ template: src="sssd.conf.{{ ansible_distribution }}" dest="{{ sssd_dir }}/sssd.conf"
+ notify:
+ - sssd restart
+
+- name: sssd ad_access_filter
+ lineinfile: dest="{{ sssd_dir }}/sssd.conf" regexp="^ad_access_filter = .*$" line="ad_access_filter = {{ ad_access_filter }}"
+ when: ad_access_filter is defined
+ notify:
+ - sssd restart
+
+- name: sssd simple_allow_users
+ lineinfile: dest="{{ sssd_dir }}/sssd.conf" regexp="^simple_allow_users = .*$" line="simple_allow_users = {{ simple_allow_users }}"
+ when: simple_allow_users is defined
+ notify:
+ - sssd restart
+
+- name: sssd start
+ service: name=sssd state=started
+
+- name: kerberos conf
+ template: src="krb5.conf.{{ ansible_distribution }}" dest="{{ krb5_conf_dir }}/krb5.conf"
diff --git a/roles/ad/templates b/roles/ad/templates
new file mode 120000
index 0000000..714ffa6
--- /dev/null
+++ b/roles/ad/templates
@@ -0,0 +1 @@
+../../company/ad-templates \ No newline at end of file
diff --git a/roles/ad/vars b/roles/ad/vars
new file mode 120000
index 0000000..b461d44
--- /dev/null
+++ b/roles/ad/vars
@@ -0,0 +1 @@
+../../company/ad-vars \ No newline at end of file
bgstack15