Connect to existing Matrix rooms

Related to https://github.com/matrix-org/matrix-appservice-gitter/issues/104

Some people already have existing Matrix rooms bridged to their Gitter community using the old matrixbot bridge. How do we want to support/handle these old rooms?

In any case, if a room exists on Gitter, it should also be accessible in some room on Matrix under the #*:gitter.im alias.

Examples:

We don't plan to support the old matrix.org =2F Gitter rooms, ex. #gitter_community=2Froom:matrix.org. See #2675 (closed)

Option 1: No support

People can archive/read-only their old rooms and point to the new Gitter room. Setup a m.room.tombstone to point to the new room

Option 2: Add Gitter cross-server aliases to the old rooms

Delete our new #*:gitter.im room and setup the cross-server alias to the old room.

Ex: Add #matrix-org_bridging:gitter.im to #bridges:matrix.org

  • Do we handle these on a case by case basis? Or add some option the Gitter UI?
    • Self-service at some point.
  • We won't necessarily have admin control of the Matrix room to be able to do all the bridging things (blocking users/bans, etc)
    • We're not going to worry about something happening to their room
  • Discussed this a little in the weekly Gitter sync
    • We're going to write a script to cut everyone who is using the old bridge over to the new bridge

Steps:

  1. Remove old matrixbot bridging connection
  2. Update the matrixRoomId in the Gitter MongoDB
    db.matricesbridgedroom.update({ troupeId: db.troupes.findOne({ lcUri: 'matrix-org/matrix-hq' })._id }, {
        $set: {
            "matrixRoomId" : "!OGEhHVWSdvArJzumhm:matrix.org",
        }
    });
  3. Grab the access token of an admin on the gitter.im homeserver, Settings > Help & About > Access Token
  4. Remove the #*:gitter.im alias from the existing room and add it to the new one
    • curl -X DELETE -H "Authorization: Bearer YOUR_AT" https://gitter.ems.host/_matrix/client/r0/directory/room/%23matrix-org_matrix-hq%3Agitter.im
    • Alias can be added via the Element UI

Future

How do we want people to self-service this in the future?

  1. Build it into the Gitter bridge
  2. Maybe https://github.com/matrix-org/matrix-doc/pull/2923

TODO:

Edited by Eric Eastwood