This repository has been archived by the owner on Feb 1, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathmain.yaml
46 lines (41 loc) · 1.39 KB
/
main.yaml
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
37
38
39
40
41
42
43
44
45
46
---
- hosts: all
become: yes
remote_user: root # If you are a sudoer without access to root, put your username here!
handlers:
- import_tasks: handlers/main.yml
tasks:
- include_vars: dir=defaults
- import_tasks: tasks/nginx.yml
- import_tasks: tasks/pre_install_fetch.yml
- name: Set Debconf values for matrix-synapse
debconf:
name: matrix-synapse
question: "{{ item.question }}"
value: "{{ item.value }}"
vtype: "{{ item.vtype }}"
with_items:
- {question: 'matrix-synapse/report-stats', value: '{{ reportStats }}', vtype: 'boolean' }
- {question: 'matrix-synapse/server-name', value: '{{ hostname }}', vtype: 'string' }
- name: Install matrix-synapse
apt:
name: matrix-synapse
state: present
notify: restart matrix-synapse
- name: Set Synapse Cache Factor
lineinfile:
path: /etc/default/matrix-synapse
regexp: SYNAPSE_CACHE_FACTOR
state: present
line: "SYNAPSE_CACHE_FACTOR={{ synapseCacheFactor }}"
notify: restart matrix-synapse
- name: Change enable_registration state
lineinfile:
path: /etc/matrix-synapse/homeserver.yaml
regexp: "enable_registration: False"
state: present
line: "enable_registration: {{ enableRegistration }}"
notify: restart matrix-synapse
- name: Setup postgreSQL
when: postgresEnable == true
import_tasks: tasks/postgresql.yml