From d5ffc949168ff786464d4975831223dd8d0fae95 Mon Sep 17 00:00:00 2001 From: Slavi Pantaleev Date: Tue, 3 Mar 2026 12:48:59 +0200 Subject: [PATCH] Add support for the Sable client (Cinny fork) --- README.md | 1 + docs/configuring-playbook-client-sable.md | 71 ++++++++++++++++++++++ docs/configuring-playbook.md | 2 + docs/container-images.md | 1 + docs/self-building.md | 1 + group_vars/matrix_servers | 55 +++++++++++++++++ requirements.yml | 3 + roles/custom/matrix-base/defaults/main.yml | 3 + setup.yml | 1 + 9 files changed, 138 insertions(+) create mode 100644 docs/configuring-playbook-client-sable.md diff --git a/README.md b/README.md index a46f6f50c..c859b2026 100644 --- a/README.md +++ b/README.md @@ -64,6 +64,7 @@ Web clients for Matrix that you can host on your own domains. | [Element Web](https://github.com/element-hq/element-web) | ✅ | Default Matrix web client, configured to connect to your own Synapse server | [Link](docs/configuring-playbook-client-element-web.md) | | [Hydrogen](https://github.com/element-hq/hydrogen-web) | ❌ | Lightweight Matrix client with legacy and mobile browser support | [Link](docs/configuring-playbook-client-hydrogen.md) | | [Cinny](https://github.com/ajbura/cinny) | ❌ | Simple, elegant and secure web client | [Link](docs/configuring-playbook-client-cinny.md) | +| [Sable](https://github.com/7w1/sable) | ❌ | Simple, elegant and secure web client | [Link](docs/configuring-playbook-client-sable.md) | | [SchildiChat Web](https://schildi.chat/) | ❌ | Based on Element Web, with a more traditional instant messaging experience | [Link](docs/configuring-playbook-client-schildichat-web.md) | | [FluffyChat Web](https://fluffychat.im/) | ❌ | The cutest messenger in Matrix | [Link](docs/configuring-playbook-client-fluffychat-web.md) | diff --git a/docs/configuring-playbook-client-sable.md b/docs/configuring-playbook-client-sable.md new file mode 100644 index 000000000..1ca4a8857 --- /dev/null +++ b/docs/configuring-playbook-client-sable.md @@ -0,0 +1,71 @@ + + +# Setting up Sable (optional) + +The playbook can install and configure the [Sable](https://github.com/7w1/sable) Matrix web client for you. + +Sable is a web client focusing primarily on simple, elegant and secure interface. It can be installed alongside or instead of [Element Web](./configuring-playbook-client-element-web.md), [Cinny](./configuring-playbook-client-cinny.md) and others. + +## Adjusting DNS records + +By default, this playbook installs Sable on the `sable.` subdomain (`sable.example.com`) and requires you to create a CNAME record for `sable`, which targets `matrix.example.com`. + +When setting, replace `example.com` with your own. + +## Adjusting the playbook configuration + +To enable Sable, add the following configuration to your `inventory/host_vars/matrix.example.com/vars.yml` file: + +```yaml +sable_enabled: true +``` + +### Adjusting the Sable URL (optional) + +By tweaking the `sable_hostname` variable, you can easily make the service available at a **different hostname** than the default one. + +Example additional configuration for your `vars.yml` file: + +```yaml +# Switch to a different domain (`app.example.com`) than the default one (`sable.example.com`) +sable_hostname: "app.{{ matrix_domain }}" + +# Expose under the /sable subpath +# sable_path_prefix: /sable +``` + +After changing the domain, **you may need to adjust your DNS** records to point the Sable domain to the Matrix server. + +**Note**: while there is a `sable_path_prefix` variable for changing the path where Sable is served, overriding it is [not possible](https://github.com/spantaleev/matrix-docker-ansible-deploy/issues/3701), because Sable requires an application rebuild (with a tweaked build config) to be functional under a custom path. You'd need to serve Sable at a dedicated subdomain. + +### Extending the configuration + +There are some additional things you may wish to configure about the component. + +Take a look at: + +- `roles/galaxy/sable/defaults/main.yml` for some variables that you can customize via your `vars.yml` file +- `roles/galaxy/sable/templates/config.json.j2` for the component's default configuration. You can override settings (even those that don't have dedicated playbook variables) using the `sable_configuration_extension_json` variable + +## Installing + +After configuring the playbook and [adjusting your DNS records](#adjusting-dns-records), run the playbook with [playbook tags](playbook-tags.md) as below: + + +```sh +ansible-playbook -i inventory/hosts setup.yml --tags=setup-all,start +``` + +The shortcut commands with the [`just` program](just.md) are also available: `just install-all` or `just setup-all` + +`just install-all` is useful for maintaining your setup quickly ([2x-5x faster](../CHANGELOG.md#2x-5x-performance-improvements-in-playbook-runtime) than `just setup-all`) when its components remain unchanged. If you adjust your `vars.yml` to remove other components, you'd need to run `just setup-all`, or these components will still remain installed. Note these shortcuts run the `ensure-matrix-users-created` tag too. + +## Troubleshooting + +As with all other services, you can find the logs in [systemd-journald](https://www.freedesktop.org/software/systemd/man/systemd-journald.service.html) by logging in to the server with SSH and running `journalctl -fu matrix-client-sable`. diff --git a/docs/configuring-playbook.md b/docs/configuring-playbook.md index 391ca7f02..963af9c54 100644 --- a/docs/configuring-playbook.md +++ b/docs/configuring-playbook.md @@ -87,6 +87,8 @@ Web clients for Matrix that you can host on your own domains. - [Setting up Cinny](configuring-playbook-client-cinny.md), if you've enabled [Cinny](https://github.com/ajbura/cinny), a web client focusing primarily on simple, elegant and secure interface +- [Setting up Sable](configuring-playbook-client-sable.md), if you've enabled [Sable](https://github.com/7w1/sable), a web client focusing primarily on simple, elegant and secure interface + - [Setting up SchildiChat Web](configuring-playbook-client-schildichat-web.md), if you've enabled [SchildiChat Web](https://schildi.chat/), a web client based on [Element Web](https://element.io/) with some extras and tweaks - [Setting up FluffyChat Web](configuring-playbook-client-fluffychat-web.md), if you've enabled [FluffyChat Web](https://github.com/krille-chan/fluffychat), a cute cross-platform messenger (web, iOS, Android) for Matrix written in [Flutter](https://flutter.dev/) diff --git a/docs/container-images.md b/docs/container-images.md index 97d47585d..f4fd9b62f 100644 --- a/docs/container-images.md +++ b/docs/container-images.md @@ -39,6 +39,7 @@ Web clients for Matrix that you can host on your own domains. | [Element Web](configuring-playbook-client-element-web.md) | [vectorim/element-web](https://hub.docker.com/r/vectorim/element-web/) | ✅ | Default Matrix web client, configured to connect to your own Synapse server | | [Hydrogen](configuring-playbook-client-hydrogen.md) | [element-hq/hydrogen-web](https://ghcr.io/element-hq/hydrogen-web) | ❌ | Lightweight Matrix client with legacy and mobile browser support | | [Cinny](configuring-playbook-client-cinny.md) | [ajbura/cinny](https://hub.docker.com/r/ajbura/cinny) | ❌ | Simple, elegant and secure web client | +| [Sable](configuring-playbook-client-sable.md) | [7w1/sable](https://ghcr.io/7w1/sable) | ❌ | Simple, elegant and secure web client | | [SchildiChat Web](configuring-playbook-client-schildichat-web.md) | [etke.cc/schildichat-web](https://ghcr.io/etkecc/schildichat-web) | ❌ | Based on Element Web, with a more traditional instant messaging experience | ## Server Components diff --git a/docs/self-building.md b/docs/self-building.md index 3fdd1791d..0d38e5f5a 100644 --- a/docs/self-building.md +++ b/docs/self-building.md @@ -30,6 +30,7 @@ Possibly outdated list of roles where self-building the Docker image is currentl - `matrix-client-element` - `hydrogen` - `cinny` +- `sable` - `matrix-registration` - `coturn` - `matrix-corporal` diff --git a/group_vars/matrix_servers b/group_vars/matrix_servers index d7ab159d7..1b4bcea50 100755 --- a/group_vars/matrix_servers +++ b/group_vars/matrix_servers @@ -576,6 +576,13 @@ devture_systemd_service_manager_services_list_auto: | 'groups': ['matrix', 'clients', 'cinny', 'client-cinny'], }] if cinny_enabled else []) + + ([{ + 'name': (sable_identifier + '.service'), + 'priority': 2000, + 'restart_necessary': (sable_restart_necessary | bool), + 'groups': ['matrix', 'clients', 'sable', 'client-sable'], + }] if sable_enabled else []) + + ([{ 'name': 'matrix-client-element.service', 'priority': 2000, @@ -4523,6 +4530,54 @@ cinny_hostname: "{{ matrix_server_fqn_cinny }}" # ###################################################################### +###################################################################### +# +# sable +# +###################################################################### + +sable_enabled: false + +sable_identifier: matrix-client-sable + +sable_uid: "{{ matrix_user_uid }}" +sable_gid: "{{ matrix_user_gid }}" + +sable_container_image_registry_prefix: "{{ 'localhost/' if sable_container_image_self_build else sable_container_image_registry_prefix_upstream }}" +sable_container_image_registry_prefix_upstream: "{{ matrix_container_global_registry_prefix_override if matrix_container_global_registry_prefix_override else sable_container_image_registry_prefix_upstream_default }}" + +sable_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}" + +sable_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '8771') if matrix_playbook_service_host_bind_interface_prefix else '' }}" + +sable_container_network: "{{ matrix_addons_container_network }}" + +sable_container_additional_networks: "{{ [matrix_playbook_reverse_proxyable_services_additional_network] if (sable_container_labels_traefik_enabled and matrix_playbook_reverse_proxyable_services_additional_network) else [] }}" + +sable_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}" +sable_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}" +sable_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}" +sable_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}" + +sable_container_labels_traefik_compression_middleware_enabled: "{{ matrix_playbook_reverse_proxy_traefik_middleware_compression_enabled }}" +sable_container_labels_traefik_compression_middleware_name: "{{ matrix_playbook_reverse_proxy_traefik_middleware_compression_name if matrix_playbook_reverse_proxy_traefik_middleware_compression_enabled else '' }}" + +sable_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}" + +sable_default_hs_url: "{{ matrix_homeserver_url }}" + +sable_self_check_validate_certificates: "{{ matrix_playbook_ssl_enabled }}" + +sable_base_path: "{{ matrix_base_data_path }}/client-sable" + +sable_hostname: "{{ matrix_server_fqn_sable }}" + +###################################################################### +# +# /sable +# +###################################################################### + ###################################################################### # # matrix-client-schildichat diff --git a/requirements.yml b/requirements.yml index 92e9a4cba..725d6a108 100644 --- a/requirements.yml +++ b/requirements.yml @@ -74,6 +74,9 @@ - src: git+https://github.com/mother-of-all-self-hosting/ansible-role-prometheus-postgres-exporter.git version: v0.19.1-0 name: prometheus_postgres_exporter +- src: git+https://github.com/mother-of-all-self-hosting/ansible-role-sable.git + version: v1.3.0-0 + name: sable - src: git+https://github.com/devture/com.devture.ansible.role.systemd_docker_base.git version: v1.5.0-0 name: systemd_docker_base diff --git a/roles/custom/matrix-base/defaults/main.yml b/roles/custom/matrix-base/defaults/main.yml index 15ea0ebe6..4bea791f4 100644 --- a/roles/custom/matrix-base/defaults/main.yml +++ b/roles/custom/matrix-base/defaults/main.yml @@ -116,6 +116,9 @@ matrix_server_fqn_hydrogen: "hydrogen.{{ matrix_domain }}" # This is where you access the Cinny web client from (if enabled via cinny_enabled; disabled by default). matrix_server_fqn_cinny: "cinny.{{ matrix_domain }}" +# This is where you access the Sable web client from (if enabled via sable_enabled; disabled by default). +matrix_server_fqn_sable: "sable.{{ matrix_domain }}" + # This is where you access the SchildiChat Web from (if enabled via matrix_client_schildichat_enabled; disabled by default). matrix_server_fqn_schildichat: "schildichat.{{ matrix_domain }}" diff --git a/setup.yml b/setup.yml index 3face8a68..d3a40b1a1 100644 --- a/setup.yml +++ b/setup.yml @@ -108,6 +108,7 @@ - custom/matrix-client-element - galaxy/hydrogen - galaxy/cinny + - galaxy/sable - custom/matrix-client-schildichat - custom/matrix-client-fluffychat - galaxy/jitsi