diff options
author | Christian Franke <nobody@nowhere.ws> | 2015-08-25 19:23:43 +0200 |
---|---|---|
committer | Christian Franke <nobody@nowhere.ws> | 2015-08-25 19:23:43 +0200 |
commit | af66612e6014bea48458125cda72d73c51bc3c20 (patch) | |
tree | 49cee76d579149a9fd800225303ee31be79cf3eb /roles/subdap/tasks/main.yaml |
Initial commit
Diffstat (limited to 'roles/subdap/tasks/main.yaml')
-rw-r--r-- | roles/subdap/tasks/main.yaml | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/roles/subdap/tasks/main.yaml b/roles/subdap/tasks/main.yaml new file mode 100644 index 0000000..6375e6e --- /dev/null +++ b/roles/subdap/tasks/main.yaml @@ -0,0 +1,34 @@ +--- +- apt: name={{ item }} state=present + with_items: + - git + - python-ldap + - python-lxml + - python-m2crypto + - virtualenv + +- name: Create subdap group + group: name=subdap + +- name: Create subdap user + user: name=subdap group=subdap home=/var/subdap + +- include: as_subdap.yaml + become: yes + become_method: su + become_user: subdap + notify: + - Restart subdap + +- name: Create systemd service + template: + src=subdap.service.j2 + dest=/etc/systemd/system/subdap.service + notify: + - Reload systemd daemons + - Restart subdap + +- name: Enable systemd service + service: + name: subdap + enabled: yes |