aboutsummaryrefslogtreecommitdiffstats
path: root/playbooks/webserver_public_example.yml
diff options
context:
space:
mode:
Diffstat (limited to 'playbooks/webserver_public_example.yml')
-rw-r--r--playbooks/webserver_public_example.yml23
1 files changed, 23 insertions, 0 deletions
diff --git a/playbooks/webserver_public_example.yml b/playbooks/webserver_public_example.yml
index b509e85..d9cb468 100644
--- a/playbooks/webserver_public_example.yml
+++ b/playbooks/webserver_public_example.yml
@@ -10,6 +10,8 @@
apache_canonical_hostname: www.example.com
apache_letsencrypt: yes
apache_document_root: /var/www/www.example.com
+ apache_config: |
+ Alias /.well-known/matrix /var/www/well-known/example.com/matrix
tags: apache
- role: archive_job
@@ -35,3 +37,24 @@
group: webmasters
mode: 02770
tags: apache
+
+ - name: create well-known directories
+ file:
+ path: '/var/www/well-known/{{ item }}'
+ state: directory
+ recurse: yes
+ loop:
+ - example.com/matrix
+ tags: apache
+
+ - name: create .well-known/matrix/server for example.com
+ copy:
+ content: '{"m.server": "matrix.example.com:8448"}'
+ dest: /var/www/well-known/example.com/matrix/server
+ tags: apache
+
+ - name: create .well-known/matrix/client for example.com
+ copy:
+ content: '{"m.homeserver": {"base_url": "https://matrix.example.com:8443"}}'
+ dest: /var/www/well-known/example.com/matrix/client
+ tags: apache