ci-buildbot


Nameci-buildbot JSON
Version 0.11.3 PyPI version JSON
download
home_pageNone
SummarySlack client for reporting on CodePipeline runs
upload_time2024-09-12 23:53:16
maintainerNone
docs_urlNone
authorNone
requires_python>=3.9
licenseNone
keywords aws ecs docker devops
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # 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:

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

Now set up the environment:

```bash
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`:

```bash
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 an S3 bucket: ads-utils-icons.s3.amanzonaws.com.  Do this to sync `./icons` to S3:

```bash
make icons
```

## Testing: CodeBuild environment variables

```bash
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
```

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "ci-buildbot",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.9",
    "maintainer_email": "Christopher Malek <cmalek@caltech.edu>, Glenn Bach <glenn@caltech.edu>",
    "keywords": "aws, ecs, docker, devops",
    "author": null,
    "author_email": "Caltech IMSS ADS <imss-ads-staff@caltech.edu>",
    "download_url": "https://files.pythonhosted.org/packages/cc/b4/3aa751fa02d8e6609482e3b37d2c61d21446ad594c73d0148e4d5af9b16c/ci_buildbot-0.11.3.tar.gz",
    "platform": null,
    "description": "# ci-buildbot\n\n`ci-buildbot` is a command line tool to do slack messaging from CodePipelines.  `ci-buildbot` acts as a Slack App in\norder to do its work.\n\nTo install:\n\n```bash\npyenv virtualenv 3.8.5 ci-buildbot\npyenv local ci-buildbot\npip install -r requirements.txt\npip install -e .\n```\n\nNow set up the environment:\n\n```bash\ncp etc/environment.text .env\n```\n\nYou'll need to know two things:\n\n* `SLACK_API_TOKEN`: this your Slack app's Oath token\n* `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.\n\nNow you can run the main command, `buildbot`:\n\n```bash\nbuildbot --help\n```\n\n## Icons\n\nI get the icons for the Slack messages here: https://iconmonstr.com.\n\nGet them as .pngs, 64x64px, name them appropriately to the build steps they're going to be used in, and save them to `./icons/`\n\nFor the gray icons (`foo-start.png`), use #909090 as the icon color.\nFor the green icons (`foo-success.png`), use #0D6B19 as the icon color.\nFor the red icons (`foo-failure.png`), use #801B0B as the icon color.\n\n`ci-buildbot` tells slack to retrieve the icons from an S3 bucket: ads-utils-icons.s3.amanzonaws.com.  Do this to sync `./icons` to S3:\n\n```bash\nmake icons\n```\n\n## Testing: CodeBuild environment variables\n\n```bash\nexport CODEBUILD_START_TIME=1594856732.3577878\nexport CODEBUILD_VPC_AZ=us-west-2b\nexport CODEBUILD_LAST_EXIT=0\nexport CODEBUILD_START_TIME=1538752095466\nexport CODEBUILD_BMR_URL=https://CODEBUILD_AGENT:3000\nexport CODEBUILD_SOURCE_VERSION=arn:aws:s3:::bucket/pipeline/App/OGgJCVJ.zip\nexport CODEBUILD_KMS_KEY_ID=arn:aws:kms:us-west-2:000000011111:alias/aws/s3\nexport CODEBUILD_BUILD_ID=codebuild-project:40b92e01-706b-422a-9305-8bdb16f7c269\nexport OLDPWD=/codebuild/output/src00011222/src\nexport CODEBUILD_GOPATH=/codebuild/output/src084981953\nexport CODEBUILD_RESOLVED_SOURCE_VERSION=9e0d29404ee30b7b63258414ecccc996bbeb55c6\nexport CODEBUILD_BUILD_SUCCEEDING=1\nexport CODEBUILD_BUILD_ARN=arn:aws:codebuild:us-west-2:000000001111:build/codebuild-project:40b92e01-706b-422a-9305-8bdb16f7c269\nexport AWS_CONTAINER_CREDENTIALS_RELATIVE_URI=/v2/credentials/e5f23b9f-c72e-4384-9ba1-37d08aa052b7\nexport CODEBUILD_INITIATOR=codepipeline/pipeline-name\nexport AWS_DEFAULT_REGION=us-west-2\nexport CODEBUILD_LOG_PATH=40b92e01-706b-422a-9305-8bdb16f7c269\nexport CODEBUILD_BUILD_IMAGE=000011112222.dkr.ecr.us-west-2.amazonaws.com/codebuild:docker-image\nexport AWS_REGION=us-west-2\nexport CODEBUILD_SRC_DIR=/codebuild/output/src00011222/src\nexport CODEBUILD_AUTH_TOKEN=0730f0ab-5299-4235-a2c2-bb1f6ad07033\n```\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "Slack client for reporting on CodePipeline runs",
    "version": "0.11.3",
    "project_urls": {
        "Issues": "https://github.com/caltechads/ci-buildbot/issues",
        "Repository": "https://github.com/caltechads/ci-buildbot"
    },
    "split_keywords": [
        "aws",
        " ecs",
        " docker",
        " devops"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "3167d1fb213cb966ae2aa552f42b55a59cfc4c90cd2c8256adbc171a473e21e2",
                "md5": "fb3e583192dac2694d2709273a17543e",
                "sha256": "abe3afe251be7a8308dc0883798496c660aabed3df8da1da365070e074eb8ed7"
            },
            "downloads": -1,
            "filename": "ci_buildbot-0.11.3-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "fb3e583192dac2694d2709273a17543e",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.9",
            "size": 29706,
            "upload_time": "2024-09-12T23:53:15",
            "upload_time_iso_8601": "2024-09-12T23:53:15.887852Z",
            "url": "https://files.pythonhosted.org/packages/31/67/d1fb213cb966ae2aa552f42b55a59cfc4c90cd2c8256adbc171a473e21e2/ci_buildbot-0.11.3-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "ccb43aa751fa02d8e6609482e3b37d2c61d21446ad594c73d0148e4d5af9b16c",
                "md5": "b5925578591cc6405c7f194d493ede1b",
                "sha256": "1548045337385819ccca742519afc744ec3cbc431c35e4f5f71fc7a2a267b86b"
            },
            "downloads": -1,
            "filename": "ci_buildbot-0.11.3.tar.gz",
            "has_sig": false,
            "md5_digest": "b5925578591cc6405c7f194d493ede1b",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.9",
            "size": 18350,
            "upload_time": "2024-09-12T23:53:16",
            "upload_time_iso_8601": "2024-09-12T23:53:16.929555Z",
            "url": "https://files.pythonhosted.org/packages/cc/b4/3aa751fa02d8e6609482e3b37d2c61d21446ad594c73d0148e4d5af9b16c/ci_buildbot-0.11.3.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-09-12 23:53:16",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "caltechads",
    "github_project": "ci-buildbot",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "requirements": [],
    "tox": true,
    "lcname": "ci-buildbot"
}
        
Elapsed time: 0.54576s