blob: ffd7b66f569ee2406200634b0a55b956418b31f4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
# Instance configuration for Baserock OpenID provider.
#
# This playbook should be run after starting an instance of the Baserock
# OpenID Provider image.
---
- hosts: openid
gather_facts: False
sudo: yes
tasks:
- name: install database password
copy: src=../database/baserock_openid_provider.database_password.yml dest=/etc owner=cherokee group=cherokee mode=400
- name: install Django secret key
copy: src=baserock_openid_provider.secret_key.yml dest=/etc owner=cherokee group=cherokee mode=400
# This step could be part of image creation, except that because the secret
# key file wouldn't be available at that time, the 'manage.py' script would
# fail to run.
- name: install static content
django_manage: app_path=/srv/baserock_openid_provider command=collectstatic
sudo_user: cherokee
- name: run database migrations
django_manage: app_path=/srv/baserock_openid_provider command=migrate
sudo_user: cherokee
# Default configuration of Sendmail in Fedora is to only accept connections from
# localhost. This is what we want, so no extra config required.
- name: enable and start sendmail service
service: name=sendmail enabled=yes state=started
- name: enable and start Cherokee service
service: name=cherokee enabled=yes state=restarted
- name: enable and start ntpd service
service: name=ntpd enabled=yes state=restarted
|