Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

Github CodeBuild Webhook

This project will setup an api gateway endpoint, which you can have your github repository connect to. This will start and update a commit with the current build status. This will be triggered for any PR update, on any branch.


This repo is no longer maintained, codebuild nowadays has native Github integration, please use that.


Use the steps below to launch the stack directly into your AWS account. You can setup as much stacks as you want, as the stack is currently connected to 1 CodeBuild project.

  1. First, we'll need to setup an AWS CodeBuild project. Create a new project in the AWS console, and be sure to add a buildspec.yml file to your project with some steps. Here's an example.

  2. Create a github api token in your account here, so that the stack is allowed to use your account: You can ofcourse choose to setup a seperate account for this.

  3. Deploy the stack:

    Launch Awesomeness

    (or use sls deploy).

  4. Create a Pull Request on your project, and see the magic be invoked 😎

  5. ...

  6. Profit!



When you create a PR, a notification is send to the Api Gateway endpoint and the lambda step function is triggered. This will trigger the start of a build for your project, and set a status of pending on your specific commit. Then it will start checking your build status every X seconds. When the status of the build changes to done or failed, the github api is called and the PR status will be updated accordingly.

Example output

In the Example below, a PR is create, and a build is run which fails. Then, a new commit is pushed, which fixes the build. When you click on the 'details' link of the PR status, it will take you to the CodeBuild build log.

AWS Codebuild Triggered after PR update


  • Add (optional) junit parsing, so it can comment on files with (possible) issues.
  • Perhaps make build project dynamic through apigateway variable if possible


Run a codebuild project on every commit in a repository






No releases published


No packages published