-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Add MatrixZulipBridge #4695
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Add MatrixZulipBridge #4695
Conversation
Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
…vice.j2 - Add the license header to matrix-matrixzulipbridge.service.j2 Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
…atrixzulipbridge", respectively Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
…asks Reuse https://app.radicle.xyz/nodes/seed.radicle.garden/rad%3Az3EdzLb58oJYY4L17xrVpYtRPz4ej/tree/aa0591f8b0ff19cee5523ffe5d070ee062e09d62/tasks/main.yml Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
Run `pip install matrixzulipbridge && python3 -m matrixzulipbridge --config config.yaml --generate` to generate config.yaml Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
Reuse https://github.com/spantaleev/matrix-docker-ansible-deploy/blob/b108c8a15165cebe346c7b16cbe181a495db6bf7/docs/configuring-playbook-bridge-heisenbridge.md Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
Signed-off-by: Suguru Hirahara <acioustick@noreply.codeberg.org>
Signed-off-by: Suguru Hirahara <did:key:z6MkvVZk1A3KBApWJXv2Ju4H14ErDfRGxh8zxdXSZ4vACDg5>
dc6a9a3 to
b1c6b70
Compare
Signed-off-by: Suguru Hirahara <did:key:z6MkvVZk1A3KBApWJXv2Ju4H14ErDfRGxh8zxdXSZ4vACDg5>
0e873e2 to
313737e
Compare
Signed-off-by: Suguru Hirahara <did:key:z6MkvVZk1A3KBApWJXv2Ju4H14ErDfRGxh8zxdXSZ4vACDg5>
| # MatrixZulipBridge is a puppeting appservice bridge for Zulip | ||
| # Project source code URL: https://github.com/GearKite/MatrixZulipBridge | ||
|
|
||
| matrix_bridge_zulip_enabled: true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
matrix_zulip_bridge_* vars look more natural, IMO. Don't steam and go-skype bridge follow the same pattern?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is not a consistent pattern at all as far as I see:
- matrix-bridge-heisenbridge:
matrix_heisenbridge_* - matrix-bridge-hookshot:
matrix_hookshot_* - matrix-bridge-steam:
matrix_steam_bridge_*
I would change them into what's based on a hierarchy:
- matrix-bridge-heisenbridge:
matrix_bridge_heisenbridge_*(we won't set it tomatrix_bridge_heisen_*as "heisenbridge" is the name of the bridge) - matrix-bridge-hookshot:
matrix_bridge_hookshot_* - matrix-bridge-steam:
matrix_bridge_steam_*
Regarding to matrix-bridge-zulip, it seems confusing to switch the place of "bridge" and "zulip" like matrix_zulip_bridge_* against the name of the bridge itself, which respects the hierarchy (despite there being some exceptions like matrix-sms-bridge).
The bridge for Steam is named as matrix-steam-bridge simply because it is the same as the same of the bridge itself (see: https://github.com/jasonlaguidice/matrix-steam-bridge).
If matrix-bridge-heisenbridge variables are set to matrix_bridge_heisenbridge_*, the variables for this bridge should be set to matrix_bridge_matrixzulipbridge_* if we respect the hierarchy for the sake of predictability.
Still, it is a completely different theme, and should definitely be addressed on another occasion.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Heisenbridge, Hookshot, Matrix Steam Bridge are component names, so the vars for them are matrix_COMPONENT_*. In the case of Matrix Steam Bridge, the Matrix from the name is omitted/deduplicated to get matrix_steam_bridge_* vars, and I'd personally expect it to be the same for Zulip - matrix_zulip_bridge_*, because the project name is MatrixZulipBridge.
Your point is completely fair - currently hierarchy naming is broken for some components, but considering unique names, I, personally, don't see a big problem here - matrix_mautrix_slack_*, matrix_postmoogle_*, matrix_heisenbridge_*, matrix_hookshot_* look okay-ish
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Created an issue on naming policy here: #4705
Signed-off-by: Suguru Hirahara <did:key:z6MkvVZk1A3KBApWJXv2Ju4H14ErDfRGxh8zxdXSZ4vACDg5>
Signed-off-by: Suguru Hirahara <did:key:z6MkvVZk1A3KBApWJXv2Ju4H14ErDfRGxh8zxdXSZ4vACDg5>
Refer to spantaleev#4695 (comment) Signed-off-by: Suguru Hirahara <did:key:z6MkvVZk1A3KBApWJXv2Ju4H14ErDfRGxh8zxdXSZ4vACDg5>
…dge_owner` Signed-off-by: Suguru Hirahara <did:key:z6MkvVZk1A3KBApWJXv2Ju4H14ErDfRGxh8zxdXSZ4vACDg5>
| ```yaml | ||
| matrix_zulip_bridge_enabled: true | ||
|
|
||
| # Setting the owner is optional as the first local user to DM `@matrixzulipbridge:example.com` will be made the owner. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please adjust the bot mxid here
|
|
||
| # Setting the owner is optional as the first local user to DM `@matrixzulipbridge:example.com` will be made the owner. | ||
| # If you are not using a local user you must set it as otherwise you can't DM it at all. | ||
| matrix_zulip_bridge_owner: "@alice:{{ matrix_domain }}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add a note about matrix_admin var that is set here by default
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I do not follow- adding about which stuff?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I mean, we have the matrix_admin var that should be used by all components to consider that MXID as admin/owner by defaultb- please mention that var here, something like "alternatively you can set matrix_admin var to set admin user for all components at once"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Addressed with 8b6d2a3.
group_vars/matrix_servers
Outdated
| + | ||
| ([{'name': 'matrix-hookshot.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'hookshot', 'bridge-hookshot']}] if matrix_hookshot_enabled else []) | ||
| + | ||
| ([{'name': 'matrix-bridge-zulip.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'matrixzulipbridge']}] if matrix_zulip_bridge_enabled else []) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use matrix-zulip-bridge for service name and zulip for tags, similar to other bridges
| matrix_zulip_bridge_docker_image_force_pull: "{{ matrix_zulip_bridge_docker_image.endswith(':latest') }}" | ||
|
|
||
| # Set this to your Matrix ID if you want to enforce the owner, otherwise first _local_ user becomes one | ||
| matrix_zulip_bridge_owner: "{{ matrix_admin if matrix_admin else '' }}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please move it to group vars - the role may not have that var, that's playbook wiring
| # Besides registration information, it contains configuration (see the Zulip bridge key). | ||
| matrix_zulip_bridge_registration_yaml: | ||
| id: zulipbridge | ||
| url: http://matrix-bridge-zulip:{{ matrix_zulip_bridge_container_http_port }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use matrix-zulip-bridge
| @@ -0,0 +1,60 @@ | |||
| {# | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please rename the file (and target service) to matrix-zulip-bridge
Signed-off-by: Suguru Hirahara <did:key:z6MkvVZk1A3KBApWJXv2Ju4H14ErDfRGxh8zxdXSZ4vACDg5>
…guring-playbook-bridge-postmoogle.md Reuse https://github.com/spantaleev/matrix-docker-ansible-deploy/blob/7862fd7cddf82cc067962a6b55747c3242c05630/docs/configuring-playbook-bridge-postmoogle.md Signed-off-by: Suguru Hirahara <did:key:z6MkvVZk1A3KBApWJXv2Ju4H14ErDfRGxh8zxdXSZ4vACDg5>
No description provided.