Procházet zdrojové kódy

Add new global variable for controlling federation regardless of homeserver implementation

The old variables still work. The global lets us avoid
auto-detection logic like we're currently doing for
`matrix_nginx_proxy_proxy_matrix_federation_api_enabled`.

In the future, we'd just be able to reference
`matrix_homeserver_federation_enabled` and know the up-to-date value
regardless of homeserver.
pull/3093/head
Slavi Pantaleev před 2 roky
rodič
revize
c238978ac8
4 změnil soubory, kde provedl 12 přidání a 2 odebrání
  1. +1
    -1
      docs/configuring-playbook-dimension.md
  2. +1
    -1
      docs/configuring-playbook-federation.md
  3. +6
    -0
      group_vars/matrix_servers
  4. +4
    -0
      roles/custom/matrix-base/defaults/main.yml

+ 1
- 1
docs/configuring-playbook-dimension.md Zobrazit soubor

@@ -5,7 +5,7 @@ If you're just installing Matrix services for the first time, please continue wi


**Note**: Dimension is **[officially unmaintained](https://github.com/spantaleev/matrix-docker-ansible-deploy/issues/2806#issuecomment-1673559299)**. We recommend not bothering with installing it. **Note**: Dimension is **[officially unmaintained](https://github.com/spantaleev/matrix-docker-ansible-deploy/issues/2806#issuecomment-1673559299)**. We recommend not bothering with installing it.


**Note**: This playbook now supports running [Dimension](https://dimension.t2bot.io) in both a federated and [unfederated](https://github.com/turt2live/matrix-dimension/blob/master/docs/unfederated.md) environments. This is handled automatically based on the value of `matrix_synapse_federation_enabled`. Enabling Dimension, means that the `openid` API endpoints will be exposed on the Matrix Federation port (usually `8448`), even if [federation](configuring-playbook-federation.md) is disabled. It's something to be aware of, especially in terms of firewall whitelisting (make sure port `8448` is accessible).
**Note**: This playbook now supports running [Dimension](https://dimension.t2bot.io) in both a federated and [unfederated](https://github.com/turt2live/matrix-dimension/blob/master/docs/unfederated.md) environments. This is handled automatically based on the value of `matrix_homeserver_federation_enabled`. Enabling Dimension, means that the `openid` API endpoints will be exposed on the Matrix Federation port (usually `8448`), even if [federation](configuring-playbook-federation.md) is disabled. It's something to be aware of, especially in terms of firewall whitelisting (make sure port `8448` is accessible).




## Decide on a domain and path ## Decide on a domain and path


+ 1
- 1
docs/configuring-playbook-federation.md Zobrazit soubor

@@ -33,7 +33,7 @@ matrix_synapse_allow_public_rooms_over_federation: true
To completely disable federation, isolating your server from the rest of the Matrix network, add this to your configuration file (`inventory/host_vars/matrix.<your-domain>/vars.yml`): To completely disable federation, isolating your server from the rest of the Matrix network, add this to your configuration file (`inventory/host_vars/matrix.<your-domain>/vars.yml`):


```yaml ```yaml
matrix_synapse_federation_enabled: false
matrix_homeserver_federation_enabled: false
``` ```


With that, your server's users will only be able to talk among themselves, but not to anyone who is on another server. With that, your server's users will only be able to talk among themselves, but not to anyone who is on another server.


+ 6
- 0
group_vars/matrix_servers Zobrazit soubor

@@ -4105,6 +4105,8 @@ matrix_synapse_username: "{{ matrix_user_username }}"
matrix_synapse_uid: "{{ matrix_user_uid }}" matrix_synapse_uid: "{{ matrix_user_uid }}"
matrix_synapse_gid: "{{ matrix_user_gid }}" matrix_synapse_gid: "{{ matrix_user_gid }}"


matrix_synapse_federation_enabled: "{{ matrix_homeserver_federation_enabled }}"

matrix_synapse_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}" matrix_synapse_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"


matrix_synapse_account_threepid_delegates_msisdn_mas1sd_url: "{{ ('http://matrix-ma1sd:' + matrix_ma1sd_container_port| string) }}" matrix_synapse_account_threepid_delegates_msisdn_mas1sd_url: "{{ ('http://matrix-ma1sd:' + matrix_ma1sd_container_port| string) }}"
@@ -4809,6 +4811,8 @@ matrix_dendrite_enabled: "{{ matrix_homeserver_implementation == 'dendrite' }}"


matrix_dendrite_hostname: "{{ matrix_server_fqn_matrix }}" matrix_dendrite_hostname: "{{ matrix_server_fqn_matrix }}"


matrix_dendrite_federation_enabled: "{{ matrix_homeserver_federation_enabled }}"

matrix_dendrite_container_network: "{{ matrix_homeserver_container_network }}" matrix_dendrite_container_network: "{{ matrix_homeserver_container_network }}"


matrix_dendrite_container_additional_networks: | matrix_dendrite_container_additional_networks: |
@@ -4908,6 +4912,8 @@ matrix_conduit_enabled: "{{ matrix_homeserver_implementation == 'conduit' }}"


matrix_conduit_hostname: "{{ matrix_server_fqn_matrix }}" matrix_conduit_hostname: "{{ matrix_server_fqn_matrix }}"


matrix_conduit_allow_federation: "{{ matrix_homeserver_federation_enabled }}"

matrix_conduit_container_network: "{{ matrix_homeserver_container_network }}" matrix_conduit_container_network: "{{ matrix_homeserver_container_network }}"


matrix_conduit_container_additional_networks_auto: | matrix_conduit_container_additional_networks_auto: |


+ 4
- 0
roles/custom/matrix-base/defaults/main.yml Zobrazit soubor

@@ -150,6 +150,10 @@ matrix_homeserver_url: "https://{{ matrix_server_fqn_matrix }}"
# Specifies on which container network the homeserver is. # Specifies on which container network the homeserver is.
matrix_homeserver_container_network: "matrix-homeserver" matrix_homeserver_container_network: "matrix-homeserver"


# Specifies whether the homeserver will federate at all.
# Disable this to completely isolate your server from the rest of the Matrix network.
matrix_homeserver_federation_enabled: true

# Specifies which systemd services are responsible for the homeserver # Specifies which systemd services are responsible for the homeserver
matrix_homeserver_systemd_services_list: [] matrix_homeserver_systemd_services_list: []




Načítá se…
Zrušit
Uložit