See Remote Runner Introduction for more details on the benefits of Workflows.
Enable workflows for a repo
To enable workflows, take the following steps:Log in and select organization
Log in to the BuildBuddy app, and use the organization picker in the sidebar to select your preferred organization.
Running workflows
After you’ve linked a repository, there are two ways to start running Workflows:- Default Config
- Custom Config
The default workflow config runs
bazel test //... whenever a commit is pushed to your repo’s default branch or a pull request branch is updated.In order to enable this, click Enable default workflow config in the three-dot dropdown for your repository on the Workflows page.Setting up branch protection rules
After you have created a workflow and you’ve pushed at least one commit to the repo, you can configure your repo so that branches cannot be merged unless the workflow succeeds.Enable status checks
Select the box Require status checks to pass before merging and enable the check corresponding to the BuildBuddy workflow (by default, this should be Test all targets).
Building in the workflow runner environment
BuildBuddy workflows execute using a Firecracker MicroVM on an Ubuntu 18.04-based image, with some commonly used tools and libraries pre-installed. If you would like to test whether your build will succeed on BuildBuddy workflows without having to set up and trigger the workflow, you can get a good approximation of the workflow VM environment by running the image locally with Docker, cloning your Git repo, and invokingbazel to run your tests:
The Dockerfile we use to build the image (at
HEAD) is here.