system-config/playbooks/roles/static/tasks/main.yaml

89 lines
1.7 KiB
YAML

- name: Check AFS mounted
stat:
path: "/afs/openstack.org/project"
register: afs_root
- name: Sanity check AFS
assert:
that:
- afs_root.stat.exists
- name: Install apache2
apt:
name:
- apache2
- apache2-utils
state: present
- name: Rewrite module
apache2_module:
state: present
name: rewrite
- name: Substitute module
apache2_module:
state: present
name: substitute
- name: Cache module
apache2_module:
state: present
name: cache
- name: Cache disk module
apache2_module:
state: present
name: cache_disk
- name: Apache macro module
apache2_module:
state: present
name: macro
- name: Apache 2 ssl module
apache2_module:
state: present
name: ssl
- name: Apache 2 headers module
apache2_module:
state: present
name: headers
- name: Make sure default site disabled
command: a2dissite 000-default.conf
args:
removes: /etc/apache2/sites-enabled/000-default.conf
# governance.openstack.org
- name: Install governance.openstack.org
copy:
src: 50-governance.openstack.org.conf
dest: /etc/apache2/sites-available/
owner: root
group: root
mode: 0644
- name: Enable governance.openstack.org
command: a2ensite 50-governance.openstack.org
args:
creates: /etc/apache2/sites-enabled/50-governance.openstack.org
notify:
- Reload apache2
# security.openstack.org
- name: Install security.openstack.org
copy:
src: 50-security.openstack.org.conf
dest: /etc/apache2/sites-available/
owner: root
group: root
mode: 0644
- name: Enable security.openstack.org
command: a2ensite 50-security.openstack.org
args:
creates: /etc/apache2/sites-enabled/50-security.openstack.org
notify:
- Reload apache2