Commit Graph

61 Commits

Author SHA1 Message Date
IUCCA
49342bd3a7
added writable /tmp directory 2022-01-14 11:29:18 +01:00
Slavi Pantaleev
ac515b7f09 Fix incorrect variables being used 2022-01-10 15:11:14 +02:00
rakshazi
c191bf54ca
self-build consistency: add deprecation warnings 2022-01-07 13:17:39 +02:00
rakshazi
d9dd524db3
self-build consistency: rename vars everywhere 2022-01-07 12:18:45 +02:00
Slavi Pantaleev
b1b4ba501f Replace ExecStop with ExecStopPost
ExecStopPost should allow us to clean up (docker kill + docker rm)
even if the ExecStart (docker run ..) command failed, and not just after
a graceful service stop was initiated.

Source: https://www.freedesktop.org/software/systemd/man/systemd.service.html#ExecStopPost=
2022-01-04 17:27:25 +02:00
laszabine
dd903ffcc2
Updated signald docker image path 2021-12-11 16:16:41 +00:00
Jan
20bc3eb24b Update signal bridge configuration template 2021-12-04 22:08:59 +01:00
Slavi Pantaleev
735c966ab6 Disable systemd services when stopping to uninstall them
Until now, we were leaving services "enabled"
(symlinks in /etc/systemd/system/multi-user.target.wants/).

We clean these up now. Broken symlinks may still exist in older
installations that enabled/disabled services. We're not taking care
to fix these up. It's just a cosmetic defect anyway.
2021-11-10 17:39:21 +02:00
AtomHare
4240df6401
update link 2021-08-18 17:25:45 +02:00
AtomHare
7d0ce01792
update links 2021-08-18 17:24:54 +02:00
Wolfgang Winter
4b7506ca1a Preset the permissions inline with other bridges 2021-08-16 18:24:12 +02:00
Wolfgang Winter
b1c94efcd8 Make template generic for the pemission settings 2021-08-16 18:23:40 +02:00
Wolfgang Winter
d0b557eb6f Replace tabs to spaces to prevent problems in YAML 2021-08-15 08:42:21 +02:00
Wolfgang Winter
7486db0d1a Missing ticks 2021-08-14 17:58:08 +02:00
WobbelTheBear
f988fd3339
Change sequence of permissions
As per earlier comment (see from tulir) the sequence has been changed.
2021-08-14 17:47:31 +02:00
WobbelTheBear
d249fe874e
Update roles/matrix-bridge-mautrix-signal/templates/config.yaml.j2
Updated settings in template file:
* relay for any user
* user permissions only for HS domain users

Co-authored-by: Jan <31133207+Jaffex@users.noreply.github.com>
2021-08-14 17:36:43 +02:00
WobbelTheBear
ae9639585c
Update roles/matrix-bridge-mautrix-signal/defaults/main.yml
Improved setup through template file

Co-authored-by: Jan <31133207+Jaffex@users.noreply.github.com>
2021-08-14 17:35:49 +02:00
Wolfgang Winter
a34241e4cc Remove intial permissions seting
Permissions, when set in the template, will be augmented rahter than replaced when using matrix_mautrix_signal_configuration_extension_yaml. Therefore, permissions shall only be set in the defaults/vars.yml or in the HS specific vars.yml file
2021-08-13 21:11:41 +02:00
Wolfgang Winter
5ca28ba872 Default relay bot functionality setting
Per default relay bot functionality is disabled; the bridge user permissions depends on the relay bot, if enabled the base domain users are on level relay, else remain on user;
2021-08-13 17:48:05 +02:00
Wolfgang Winter
e6b77284f2 Relay bot configurable + permissions
Enable / disable relay bot functionality as configuratoin paramter; set bridge permissions for base domain users to user level
2021-08-13 17:46:37 +02:00
Jaffex
e90b33c4e3 Update matrix-mautrix-signal config to 0.2.0 to enable relay mode 2021-08-12 12:52:55 +02:00
Wolfgang Winter
6ecfbe98b1 New version of Mautrix Signal bridge version 0.2.0 provided through new GitLab repository location 2021-08-09 11:19:12 +02:00
Slavi Pantaleev
2697590d28 Remove some useless if conditions 2021-08-04 14:51:15 +03:00
Slavi Pantaleev
7d9ee3e2fb
Remove unnecessary if-condition 2021-07-21 15:17:17 +03:00
Slavi Pantaleev
a21696f687
Fix some if-checks
We'd rather not suppress pull errors or run self-build tasks if pulling fails.
2021-07-21 15:16:14 +03:00
Toorero
ead4b00c09 Reverted back to manual self-build detection 2021-07-21 14:05:21 +02:00
Toorero
f933ba14ae Fixed self-build functionality for mautrix-signal and added self-build functionality for signald 2021-07-16 13:27:36 +02:00
Toorero
f732a75ca5 Added selfbuild functionality to mautrix-signal bridge 2021-07-14 03:11:13 +02:00
teutat3s
0b5e903693
Updates to mautrix-signal config
See these last commits:

tulir/mautrix-signal@4fc34330c1

tulir/mautrix-signal@64bc5c36a5

tulir/mautrix-signal@ddda1666d4
2021-03-31 02:51:23 +02:00
dbae18fd6a
feat: push ephemeral events to appservices
This adds https://github.com/matrix-org/matrix-doc/pull/2409 to the
appservice registrations, enabling synapse to push EDUs to appservices.
2021-03-25 18:49:54 +01:00
rakshazi
2f887f292c
added "matrix_%SERVICE%_version" variable to all roles, use it in "matrix_%SERVICE%_docker_image" var (preserving backward-compatibility) 2021-02-20 19:08:28 +02:00
efraimbart
b7e68cb779
Fix wrong docker image being pulled
Changed `matrix_mautrix_signal_docker_image_force_pull` to `matrix_mautrix_signal_daemon_docker_image_force_pull` when force pulling the daemon
2021-02-11 22:56:37 -05:00
Slavi Pantaleev
c4a05b760a Make mautrix bridges not overwrite their config
If they do, our next playbook runs would simply revert it
and report "changed" for that task.

There's no benefit to letting the bridge spew a new config file.

This does not apply to the mautrix whatsapp bridge, because that one
is written in Go (not Python) and takes different flags. There's no
equivalent flag there.
2021-02-03 13:23:18 +02:00
Slavi Pantaleev
e3290d8bcb Remove |to_json causing trouble
Fixes a regression introduced in f6097fbba1, which was cauing Synapse
to die with this error message:

> ValueError: sender_localpart needs characters which are not URL encoded.
2021-01-27 15:48:35 +02:00
Slavi Pantaleev
f6097fbba1 E2BE not working for mautrix bridges
Fixes https://github.com/spantaleev/matrix-docker-ansible-deploy/issues/806
2021-01-27 15:43:33 +02:00
Slavi Pantaleev
512f42aa76 Do not report docker kill/rm attempts as errors
These are just defensive cleanup tasks that we run.
In the good case, there's nothing to kill or remove, so they trigger an
error like this:

> Error response from daemon: Cannot kill container: something: No such container: something

and:

> Error: No such container: something

People often ask us if this is a problem, so instead of always having to
answer with "no, this is to be expected", we'd rather eliminate it now
and make logs cleaner.

In the event that:
- a container is really stuck and needs cleanup using kill/rm
- and cleanup fails, and we fail to report it because of error
suppression (`2>/dev/null`)

.. we'd still get an error when launching ("container name already in use .."),
so it shouldn't be too hard to investigate.
2021-01-27 10:22:46 +02:00
Slavi Pantaleev
6fc214480c
Fix Signal role using incorrect database string variable
Fixes https://github.com/spantaleev/matrix-docker-ansible-deploy/issues/823
2021-01-25 10:42:23 +02:00
Slavi Pantaleev
f3dd346724 Try to tighten Signal bridge security 2021-01-22 18:56:08 +02:00
Slavi Pantaleev
8ec975e3c8 Use matrix:matrix for Signal bridge (not root) 2021-01-22 18:52:20 +02:00
Slavi Pantaleev
37909aa7a9 Create signald/{avatars,attachments,data} and rename config dir 2021-01-22 18:40:51 +02:00
Slavi Pantaleev
1692a28fe4 Work around annoying Docker warning about undefined $HOME
> WARNING: Error loading config file: .dockercfg: $HOME is not defined

.. which appeared in Docker 20.10.
2021-01-15 00:23:01 +02:00
Slavi Pantaleev
05ca9357a8 Add .service suffix to systemd units list
We'll be adding `.timer` units later on, so it's good to be
more explicit.
2021-01-14 23:02:10 +02:00
Slavi Pantaleev
3b524ee815 Make mautrix-signal bridge not log to files
We try to only use console logging (going to journald) for everything,
instead of logging things twice (or more).
2021-01-03 08:20:43 +02:00
Slavi Pantaleev
274f23f668 Make matrix-mautrix-signal-daemon.service depend on docker.service 2021-01-03 08:16:49 +02:00
Slavi Pantaleev
da2a6682b3 Get rid of matrix_mautrix_signal_configuration_permissions
While it's kind of nice having it, it's also somewhat raw
and unnecessary.

Having a good default and not even mentioning it seems better
for most users.

People who need a more exposed bridge (rare) can use
override the default configuration using
`matrix_mautrix_signal_configuration_extension_yaml`.
2021-01-03 08:06:32 +02:00
Slavi Pantaleev
df8d9cfd34 Remove some TODOs
The answer to these is: it's good to have them in both places.
The role defines the obvious things it depends on (not knowing
what setup it will find itself into), and then
`group_vars/matrix_servers` "extends" it based on everything else it
knows (the homeserver being Synapse, whether or not the internal
Postgres server is being used, etc.)
2021-01-03 07:46:55 +02:00
Sabine Laszakovits
84cac25c11 added config data_dir (else in ~, which isn't set) 2021-01-02 19:01:21 +01:00
Sabine Laszakovits
56af2b1a8c small fixes 2021-01-02 00:56:45 +01:00
Sabine Laszakovits
89f7f3c3b8 added log level configuration 2021-01-02 00:55:55 +01:00
Sabine Laszakovits
ffb837d4bc made the bridge use the default postgres db 2021-01-02 00:39:11 +01:00