Skip to content

Commit f28635b

Browse files
committed
Update server config sample
1 parent 91c2ae2 commit f28635b

File tree

1 file changed

+110
-38
lines changed
  • roles/custom/matrix-bridge-appservice-irc/defaults

1 file changed

+110
-38
lines changed

roles/custom/matrix-bridge-appservice-irc/defaults/main.yml

Lines changed: 110 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -66,20 +66,25 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
6666
# # It is also used in the Third Party Lookup API as the instance `desc`
6767
# # property, where each server is an instance.
6868
# name: "ExampleNet"
69-
69+
# # Additional addresses to connect to, used for load balancing between IRCDs.
7070
# additionalAddresses: [ "irc2.example.com" ]
71+
# # Typically additionalAddresses would be in addition to the address key given above,
72+
# # but some configurations wish to exclusively use additional addresses while reserving
73+
# # the top key for identification purposes. Set this to true to exclusively use the
74+
# # additionalAddresses array when connecting to servers.
75+
# onlyAdditionalAddresses: false
7176
# #
7277
# # [DEPRECATED] Use `name`, above, instead.
7378
# # A human-readable description string
7479
# # description: "Example.com IRC network"
75-
80+
#
7681
# # An ID for uniquely identifying this server amongst other servers being bridged.
7782
# # networkId: "example"
78-
79-
# # URL to an icon used as the network icon whenever this network appear in
80-
# # a network list. (Like in the Riot room directory, for instance.)
81-
# # icon: https://example.com/images/hash.png
82-
83+
#
84+
# # MXC URL to an icon used as the network icon whenever this network appear in
85+
# # a network list. (Like in the Element room directory, for instance.)
86+
# # icon: mxc://matrix.org/LpsSLrbANVrEIEOgEaVteItf
87+
#
8388
# # The port to connect to. Optional.
8489
# port: 6697
8590
# # Whether to use SSL or not. Default: false.
@@ -92,19 +97,25 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
9297
# # Whether to allow expired certs when connecting to the IRC server.
9398
# # Usually this should be off. Default: false.
9499
# allowExpiredCerts: false
95-
# # A specific CA to trust instead of the default CAs. Optional.
96-
# #ca: |
97-
# # -----BEGIN CERTIFICATE-----
98-
# # ...
99-
# # -----END CERTIFICATE-----
100-
100+
# # Set additional TLS options for the connections to the IRC server.
101+
# #tlsOptions:
102+
# # A specific CA to trust instead of the default CAs. Optional.
103+
# #ca: |
104+
# # -----BEGIN CERTIFICATE-----
105+
# # ...
106+
# # -----END CERTIFICATE-----
107+
# # Server name for the SNI (Server Name Indication) TLS extension. If the address you
108+
# # are using does not report the correct certificate name, you can override it here.
109+
# # servername: real.server.name
110+
# # ...or any options in https://nodejs.org/api/tls.html#tls_tls_connect_options_callback
111+
#
101112
# #
102113
# # The connection password to send for all clients as a PASS (or SASL, if enabled above) command. Optional.
103114
# # password: 'pa$$w0rd'
104115
# #
105116
# # Whether or not to send connection/error notices to real Matrix users. Default: true.
106117
# sendConnectionMessages: true
107-
118+
#
108119
# quitDebounce:
109120
# # Whether parts due to net-splits are debounced for delayMs, to allow
110121
# # time for the netsplit to resolve itself. A netsplit is detected as being
@@ -124,13 +135,13 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
124135
# delayMinMs: 3600000 # 1h
125136
# # Default: 7200000, = 2h
126137
# delayMaxMs: 7200000 # 2h
127-
138+
#
128139
# # A map for conversion of IRC user modes to Matrix power levels. This enables bridging
129140
# # of IRC ops to Matrix power levels only, it does not enable the reverse. If a user has
130141
# # been given multiple modes, the one that maps to the highest power level will be used.
131142
# modePowerMap:
132143
# o: 50
133-
144+
# v: 1
134145
# botConfig:
135146
# # Enable the presence of the bot in IRC channels. The bot serves as the entity
136147
# # which maps from IRC -> Matrix. You can disable the bot entirely which
@@ -153,6 +164,8 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
153164
# enabled: true
154165
# # The nickname to give the AS bot.
155166
# nick: "MatrixBot"
167+
# # The username to give to the AS bot. Defaults to "matrixbot"
168+
# username: "matrixbot"
156169
# # The password to give to NickServ or IRC Server for this nick. Optional.
157170
# # password: "helloworld"
158171
# #
@@ -161,7 +174,7 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
161174
# # real Matrix users in them, even if there is a mapping for the channel.
162175
# # Default: true
163176
# joinChannelsIfNoUsers: true
164-
177+
#
165178
# # Configuration for PMs / private 1:1 communications between users.
166179
# privateMessages:
167180
# # Enable the ability for PMs to be sent to/from IRC/Matrix.
@@ -170,12 +183,12 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
170183
# # Prevent Matrix users from sending PMs to the following IRC nicks.
171184
# # Optional. Default: [].
172185
# # exclude: ["Alice", "Bob"] # NOT YET IMPLEMENTED
173-
186+
#
174187
# # Should created Matrix PM rooms be federated? If false, only users on the
175188
# # HS attached to this AS will be able to interact with this room.
176189
# # Optional. Default: true.
177190
# federate: true
178-
191+
#
179192
# # Configuration for mappings not explicitly listed in the 'mappings'
180193
# # section.
181194
# dynamicChannels:
@@ -189,27 +202,34 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
189202
# # Should the AS publish the new Matrix room to the public room list so
190203
# # anyone can see it? Default: true.
191204
# published: true
205+
# # Publish the rooms to the homeserver directory, as oppose to the appservice
206+
# # room directory. Only used if `published` is on.
207+
# # Default: false
208+
# useHomeserverDirectory: true
192209
# # What should the join_rule be for the new Matrix room? If 'public',
193210
# # anyone can join the room. If 'invite', only users with an invite can
194211
# # join the room. Note that if an IRC channel has +k or +i set on it,
195212
# # join_rules will be set to 'invite' until these modes are removed.
196213
# # Default: "public".
197214
# joinRule: public
198-
# # This will set the m.room.related_groups state event in newly created rooms
199-
# # with the given groupId. This means flares will show up on IRC users in those rooms.
200-
# # This should be set to the same thing as namespaces.users.group_id in irc_registration.
201-
# # This does not alter existing rooms.
202-
# # Leaving this option empty will not set the event.
203-
# groupId: +myircnetwork:localhost
204215
# # Should created Matrix rooms be federated? If false, only users on the
205216
# # HS attached to this AS will be able to interact with this room.
206217
# # Default: true.
207218
# federate: true
219+
# # Force this room version when creating IRC channels. Beware if the homeserver doesn't
220+
# # support the room version then the request will fail. By default, no version is requested.
221+
# # roomVersion: "1"
208222
# # The room alias template to apply when creating new aliases. This only
209223
# # applies if createAlias is 'true'. The following variables are exposed:
210224
# # $SERVER => The IRC server address (e.g. "irc.example.com")
211225
# # $CHANNEL => The IRC channel (e.g. "#python")
212226
# # This MUST have $CHANNEL somewhere in it.
227+
# #
228+
# # In certain circumstances you might want to bridge your whole IRC network as a
229+
# # homeserver (e.g. #matrix:libera.chat). For these use cases, you can set the
230+
# # template to just be $CHANNEL. Doing so will preclude you from supporting
231+
# # other prefix characters though.
232+
# #
213233
# # Default: '#irc_$SERVER_$CHANNEL'
214234
# aliasTemplate: "#irc_$CHANNEL"
215235
# # A list of user IDs which the AS bot will send invites to in response
@@ -221,7 +241,11 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
221241
# # Prevent the given list of channels from being mapped under any
222242
# # circumstances.
223243
# # exclude: ["#foo", "#bar"]
224-
244+
#
245+
# # excludedUsers:
246+
# # - regex: "@.*:evilcorp.com"
247+
# # kickReason: "We don't like Evilcorp"
248+
#
225249
# # Configuration for controlling how Matrix and IRC membership lists are
226250
# # synced.
227251
# membershipLists:
@@ -230,12 +254,12 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
230254
# # synced. This must be enabled for anything else in this section to take
231255
# # effect. Default: false.
232256
# enabled: false
233-
257+
#
234258
# # Syncing membership lists at startup can result in hundreds of members to
235259
# # process all at once. This timer drip feeds membership entries at the
236260
# # specified rate. Default: 10000. (10s)
237261
# floodDelayMs: 10000
238-
262+
#
239263
# global:
240264
# ircToMatrix:
241265
# # Get a snapshot of all real IRC users on a channel (via NAMES) and
@@ -244,7 +268,14 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
244268
# # Make virtual Matrix clients join and leave rooms as their real IRC
245269
# # counterparts join/part channels. Default: false.
246270
# incremental: false
247-
271+
# # Should the bridge check if all Matrix users are connected to IRC and
272+
# # joined to the channel before relaying messages into the room.
273+
# #
274+
# # This is considered a safety net to avoid any leakages by the bridge to
275+
# # unconnected users, but given it ignores all IRC messages while users
276+
# # are still connecting it may be overkill.
277+
# requireMatrixJoined: false
278+
#
248279
# matrixToIrc:
249280
# # Get a snapshot of all real Matrix users in the room and join all of
250281
# # them to the mapped IRC channel on startup. Default: false.
@@ -253,21 +284,32 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
253284
# # counterparts join/leave rooms. Make sure your 'maxClients' value is
254285
# # high enough! Default: false.
255286
# incremental: false
256-
287+
#
257288
# # Apply specific rules to Matrix rooms. Only matrix-to-IRC takes effect.
258289
# rooms:
259290
# - room: "!qporfwt:localhost"
260291
# matrixToIrc:
261292
# initial: false
262293
# incremental: false
263-
294+
#
264295
# # Apply specific rules to IRC channels. Only IRC-to-matrix takes effect.
265296
# channels:
266297
# - channel: "#foo"
267298
# ircToMatrix:
268299
# initial: false
269300
# incremental: false
270-
301+
# requireMatrixJoined: false
302+
#
303+
# # Should the bridge ignore users which are not considered active on the bridge
304+
# # during startup
305+
# ignoreIdleUsersOnStartup:
306+
# enabled: true
307+
# # How many hours can a user be considered idle for before they are considered
308+
# # ignoreable
309+
# idleForHours: 720
310+
# # A regex which will exclude matching MXIDs from this check.
311+
# exclude: "foobar"
312+
#
271313
# mappings:
272314
# # 1:many mappings from IRC channels to room IDs on this IRC server.
273315
# # The Matrix room must already exist. Your Matrix client should expose
@@ -277,27 +319,27 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
277319
# # Channel key/password to use. Optional. If provided, Matrix users do
278320
# # not need to know the channel key in order to join the channel.
279321
# # key: "secret"
280-
322+
#
281323
# # Configuration for virtual Matrix users. The following variables are
282324
# # exposed:
283325
# # $NICK => The IRC nick
284326
# # $SERVER => The IRC server address (e.g. "irc.example.com")
285327
# matrixClients:
286328
# # The user ID template to use when creating virtual Matrix users. This
287-
# # MUST have $NICK somewhere in it.
329+
# # MUST start with an @ and have $NICK somewhere in it.
288330
# # Optional. Default: "@$SERVER_$NICK".
289331
# # Example: "@irc.example.com_Alice:example.com"
290332
# userTemplate: "@irc_$NICK"
291333
# # The display name to use for created Matrix clients. This should have
292334
# # $NICK somewhere in it if it is specified. Can also use $SERVER to
293335
# # insert the IRC domain.
294-
# # Optional. Default: "$NICK (IRC)". Example: "Alice (IRC)"
295-
# displayName: "$NICK (IRC)"
336+
# # Optional. Default: "$NICK". Example: "Alice"
337+
# displayName: "$NICK"
296338
# # Number of tries a client can attempt to join a room before the request
297339
# # is discarded. You can also use -1 to never retry or 0 to never give up.
298340
# # Optional. Default: -1
299341
# joinAttempts: -1
300-
342+
#
301343
# # Configuration for virtual IRC users. The following variables are exposed:
302344
# # $LOCALPART => The user ID localpart ("alice" in @alice:localhost)
303345
# # $USERID => The user ID
@@ -326,9 +368,20 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
326368
# # connected user. If not specified, all users will connect from the same
327369
# # (default) address. This may require additional OS-specific work to allow
328370
# # for the node process to bind to multiple different source addresses
329-
# # e.g IP_FREEBIND on Linux, which requires an LD_PRELOAD with the library
371+
# # Linux kernels 4.3+ support sysctl net.ipv6.ip_nonlocal_bind=1
372+
# # Older kernels will need IP_FREEBIND, which requires an LD_PRELOAD with the library
330373
# # https://github.com/matrix-org/freebindfree as Node does not expose setsockopt.
331374
# # prefix: "2001:0db8:85a3::" # modify appropriately
375+
#
376+
# # Optional. Define blocks of IPv6 addresses for different homeservers
377+
# # which can be used to restrict users of those homeservers to a given
378+
# # IP. These blocks should be considered immutable once set, as changing
379+
# # the startFrom value will NOT adjust existing IP addresses.
380+
# # Changing the startFrom value to a lower value may conflict with existing clients.
381+
# # Multiple homeservers may NOT share blocks.
382+
# blocks:
383+
# - homeserver: another-server.org
384+
# startFrom: '10:0000'
332385
# #
333386
# # The maximum amount of time in seconds that the client can exist
334387
# # without sending another message before being disconnected. Use 0 to
@@ -365,6 +418,25 @@ matrix_appservice_irc_ircService_servers: [] # noqa var-naming
365418
# # through the bridge e.g. caller ID as there is no way to /ACCEPT.
366419
# # Default: "" (no user modes)
367420
# # userModes: "R"
421+
# # The format of the realname defined for users, either mxid or reverse-mxid
422+
# realnameFormat: "mxid"
423+
# # The minimum time to wait between connection attempts if we were disconnected
424+
# # due to throttling.
425+
# # pingTimeoutMs: 600000
426+
# # The rate at which to send pings to the IRCd if the client is being quiet for a while.
427+
# # Whilst the IRCd *should* be sending pings to us to keep the connection alive, it appears
428+
# # that sometimes they don't get around to it and end up ping timing us out.
429+
# # pingRateMs: 60000
430+
# # Choose which conditions the IRC bridge should kick Matrix users for. Decisions to this from
431+
# # defaults should be taken with care as it may dishonestly repesent Matrix users on the IRC
432+
# # network, and cause your bridge to be banned.
433+
# kickOn:
434+
# # Kick a Matrix user from a bridged room if they fail to join the IRC channel.
435+
# channelJoinFailure: true
436+
# # Kick a Matrix user from ALL rooms if they are unable to get connected to IRC.
437+
# ircConnectionFailure: true
438+
# # Kick a Matrix user from ALL rooms if they choose to QUIT the IRC network.
439+
# userQuit: true
368440

369441
# Controls whether the matrix-appservice-discord container exposes its HTTP port (tcp/9999 in the container).
370442
#

0 commit comments

Comments
 (0)