Skip to main content

ci-buildbot

ci-buildbot is a command line tool to do slack messaging from CodePipelines. ci-buildbot acts as a Slack App in order to do its work.

To install:

pyenv virtualenv 3.8.5 ci-buildbot
pyenv local ci-buildbot
pip install -r requirements.txt
pip install -e .

Now set up the environment:

cp etc/environment.text .env

You'll need to know two things:

  • SLACK_API_TOKEN: this your Slack app's Oath token
  • CHANNEL: this is the channel you want ci-buildbot to post into. Note that if this is a private channel, you'll need to invite the ci-buildbot app into that channel before you'll see any messages.

Now you can run the main command, buildbot:

buildbot --help

Icons

I get the icons for the Slack messages here: https://iconmonstr.com.

Get them as .pngs, 64x64px, name them appropriately to the build steps they're going to be used in, and save them to ./icons/

For the gray icons (foo-start.png), use #909090 as the icon color. For the green icons (foo-success.png), use #0D6B19 as the icon color. For the red icons (foo-failure.png), use #801B0B as the icon color.

ci-buildbot tells slack to retrieve the icons from: https://ads-utils-icons.resources.caltech.edu/. Do this to sync ./icons to S3:

make icons

Testing: CodeBuild environment variables

export CODEBUILD_START_TIME=1594856732.3577878
export CODEBUILD_VPC_AZ=us-west-2b
export CODEBUILD_LAST_EXIT=0
export CODEBUILD_START_TIME=1538752095466
export CODEBUILD_BMR_URL=https://CODEBUILD_AGENT:3000
export CODEBUILD_SOURCE_VERSION=arn:aws:s3:::bucket/pipeline/App/OGgJCVJ.zip
export CODEBUILD_KMS_KEY_ID=arn:aws:kms:us-west-2:000000011111:alias/aws/s3
export CODEBUILD_BUILD_ID=codebuild-project:40b92e01-706b-422a-9305-8bdb16f7c269
export OLDPWD=/codebuild/output/src00011222/src
export CODEBUILD_GOPATH=/codebuild/output/src084981953
export CODEBUILD_RESOLVED_SOURCE_VERSION=9e0d29404ee30b7b63258414ecccc996bbeb55c6
export CODEBUILD_BUILD_SUCCEEDING=1
export CODEBUILD_BUILD_ARN=arn:aws:codebuild:us-west-2:000000001111:build/codebuild-project:40b92e01-706b-422a-9305-8bdb16f7c269
export AWS_CONTAINER_CREDENTIALS_RELATIVE_URI=/v2/credentials/e5f23b9f-c72e-4384-9ba1-37d08aa052b7
export CODEBUILD_INITIATOR=codepipeline/pipeline-name
export AWS_DEFAULT_REGION=us-west-2
export CODEBUILD_LOG_PATH=40b92e01-706b-422a-9305-8bdb16f7c269
export CODEBUILD_BUILD_IMAGE=000011112222.dkr.ecr.us-west-2.amazonaws.com/codebuild:docker-image
export AWS_REGION=us-west-2
export CODEBUILD_SRC_DIR=/codebuild/output/src00011222/src
export CODEBUILD_AUTH_TOKEN=0730f0ab-5299-4235-a2c2-bb1f6ad07033

Metadata

Release files for ci-buildbot 0.11.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ci-buildbot 0.11.6
File Size Uploaded Provenance Actions
ci_buildbot-0.11.6.tar.gz 19.0 kB Without provenance Details for ci_buildbot-0.11.6.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for ci-buildbot 0.11.6
File Interpreter ABI Platform Actions
ci_buildbot-0.11.6-py3-none-any.whl Python 3 none any Details for ci_buildbot-0.11.6-py3-none-any.whl

Total release size: 50.2 kB

Release files / ci_buildbot-0.11.6.tar.gz

Download URL ci_buildbot-0.11.6.tar.gz
Size 19.0 kB
Tags Source
SHA-256 checksum
How to use checksums
35f20c35655d7d61eef6d3bcde02d6936b6cc7661261fc3f1e028bb88f03124d
BLAKE2b-256 checksum
How to use checksums
fd21b449b0f17362b094ee3aedecae2ccd5f082c543cb0653572eeefbfb4675e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.10

Release files / ci_buildbot-0.11.6-py3-none-any.whl

Download URL ci_buildbot-0.11.6-py3-none-any.whl
Size 31.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ff4f66e4f647b174a245cf38b5db2be637f16da768e1b09271fe0c2c742c01ff
BLAKE2b-256 checksum
How to use checksums
1b041ebd1867b611eb503d0c65e0df1bfa4eb43f879dac316ca3fa39d7d8daef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.10

Security for ci-buildbot 0.11.6

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page