From 865e2f05621fc10f3d332d3840707997c0b94abf Mon Sep 17 00:00:00 2001 From: Stonewall Jackson Date: Mon, 12 Jun 2023 21:02:22 -0400 Subject: add mastodon role --- playbooks/mastodon.yml | 17 +++++++++++++++++ playbooks/populate_domain.yml | 2 ++ playbooks/site.yml | 1 + playbooks/webserver_public_example.yml | 1 + 4 files changed, 21 insertions(+) create mode 100644 playbooks/mastodon.yml (limited to 'playbooks') diff --git a/playbooks/mastodon.yml b/playbooks/mastodon.yml new file mode 100644 index 0000000..8c7b381 --- /dev/null +++ b/playbooks/mastodon.yml @@ -0,0 +1,17 @@ +- name: configure mastodon servers + hosts: mastodon_servers + roles: + - role: common + tags: common + + - role: mastodon + tags: mastodon + + - role: apache_vhost + apache_server_name: '{{ mastodon_web_domain }}' + apache_server_aliases: [] + apache_letsencrypt: yes + apache_redirect_to_https: yes + apache_document_root: '{{ mastodon_webroot }}' + apache_config: '{{ mastodon_apache_config }}' + tags: apache diff --git a/playbooks/populate_domain.yml b/playbooks/populate_domain.yml index acb1ec7..c118af9 100644 --- a/playbooks/populate_domain.yml +++ b/playbooks/populate_domain.yml @@ -24,6 +24,8 @@ attributes: mailAlternateAddress: '{{ item.mail_aliases | default([]) }}' jid: '{{ item.jid | default([]) }}' + mastodonUsername: '{{ item.mastodon_id | default([]) }}' + matrixUsername: '{{ item.mxid | default([]) }}' bind_dn: uid={{ ipa_user }},{{ freeipa_user_basedn }} bind_pw: '{{ ipa_pass }}' server_uri: ldaps://{{ ipa_host }} diff --git a/playbooks/site.yml b/playbooks/site.yml index fa79f8d..48b6144 100644 --- a/playbooks/site.yml +++ b/playbooks/site.yml @@ -36,3 +36,4 @@ - import_playbook: xmpp.yml - import_playbook: asterisk.yml - import_playbook: matrix.yml +- import_playbook: mastodon.yml diff --git a/playbooks/webserver_public_example.yml b/playbooks/webserver_public_example.yml index d9cb468..69a3254 100644 --- a/playbooks/webserver_public_example.yml +++ b/playbooks/webserver_public_example.yml @@ -11,6 +11,7 @@ apache_letsencrypt: yes apache_document_root: /var/www/www.example.com apache_config: | + Redirect permanent /.well-known/webfinger https://mastodon.example.com/.well-known/webfinger Alias /.well-known/matrix /var/www/well-known/example.com/matrix tags: apache -- cgit