Skip to main content

buildbot plugin for using matrix for notifications

Project description

Buildbot Matrix Plugin

PyPI version

This Plugin for buildbot adds a reporter which sends notifications to a specified matrix room.

Inspired by buildbot-gitea by lab132.

Installation

pip install buildbot-matrix

This installs itself into buildbot, no extra imports required.

Setup

Matrix Bot

  • Create a new Matrix user which will be used to send notifications.
  • Set a meaningful display name for the user. For Example Buildbot Notifications
  • Get an access token for this user.
  • Add the user to the room you want the notifications to be in.

Buildbot

  • Add this to the buildbot configuration:
c['services'] = [
	reporters.MatrixStatusPush(
		'https://homeserver.example.com',
		'ROOM_ID:example.com',
		'BOT_ACCESS_TOKEN',
		verbose=True
	)
]
  • Change the URL of the homeserver to the homeserver you want to use.
  • Replace BOT_ACCESS_TOKEN with the acces token of the matrix user, this can be a buildbot secret.
  • Replace ROOM_ID with the id of the matrix room the bot should send the notifications to. Replace the ! at the beginning with %21.

Personalizing

You can modify the notifications by changing the following parameters:

Parameter Description Default
startDescription Short description when a build started Build started.
endDescription Short description when a build ended Build done.
context Identifier to give messages a context Interpolate('buildbot/%(prop:buildername)s')
context_pr Identifier to give messages a context, used on pull requests Interpolate('buildbot/pull_request/%(prop:buildername)s')
warningAsSuccess Treat warnings as build success False
onlyEndState Only send a message if a build has ended False

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

buildbot-matrix-0.0.4.tar.gz (4.4 kB view details)

Uploaded Source

Built Distribution

buildbot_matrix-0.0.4-py3-none-any.whl (5.6 kB view details)

Uploaded Python 3

File details

Details for the file buildbot-matrix-0.0.4.tar.gz.

File metadata

  • Download URL: buildbot-matrix-0.0.4.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.3.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.2

File hashes

Hashes for buildbot-matrix-0.0.4.tar.gz
Algorithm Hash digest
SHA256 96806b9302621874da645ac1938f7ccb8737a5ae9d41faf452fd00103421e1d6
MD5 d10d7cd1b164effd4811d2ccec833de8
BLAKE2b-256 f2d32baa431656e44b62932d4d294e9142a886b668d1114bf9e9bfb3f8a03587

See more details on using hashes here.

File details

Details for the file buildbot_matrix-0.0.4-py3-none-any.whl.

File metadata

  • Download URL: buildbot_matrix-0.0.4-py3-none-any.whl
  • Upload date:
  • Size: 5.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.3.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.2

File hashes

Hashes for buildbot_matrix-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 46fbf6219c6fb3917f3b776c1aab7cc8609dceccfc1cecf5a95e66dda4371307
MD5 8bf5372e36c701b96aa6a56c1c89232b
BLAKE2b-256 c569cdabff1b412998ee4e4211d6078a07b6a1e1b7b44950579ba479c279b481

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page