Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build and deploy docker images. #268

Merged
merged 19 commits into from
Jan 4, 2022

Conversation

VJalili
Copy link
Member

@VJalili VJalili commented Dec 1, 2021

This PR refactors and updates the GitHub actions for building docker images as follows.

  • Refactors the job for testing the build of Docker images (test_build) into two jobs:
    • build_args_job: this job determines the images to be built (based on the delta between two commit SHAs) and composes a tag to be used for the images;
    • build_job: this job will run for pull requests (PR) only (i.e., it will be triggered only when a commit is pushed to an open PR), and it will only test if the determined target images are built successfully.
  • This PR adds a third job, publish_job, which is run only when a commit is pushed to the master branch (e.g., merging the PR). This job builds the images and pushes them to Google cloud Container Registry (GCR). This job runs in the Deploy environment that contains encrypted GCP service account credentials required to push images to GCR. The job uses gcloud to configure Docker credentials. The execution of this job is paused until its execution is approved by the maintainers.

@VJalili VJalili requested a review from mwalker174 December 1, 2021 05:31
@VJalili VJalili force-pushed the push_docker_images branch from 3024ccf to 2d860f2 Compare December 1, 2021 05:43
Copy link
Collaborator

@mwalker174 mwalker174 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @VJalili this is really excellent! And very well documented as well. I have mostly minor grammatical suggestions.

README.md Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
.github/workflows/README.md Outdated Show resolved Hide resolved
.github/workflows/README.md Outdated Show resolved Hide resolved
.github/workflows/README.md Outdated Show resolved Hide resolved
.github/workflows/README.md Outdated Show resolved Hide resolved
.github/workflows/README.md Outdated Show resolved Hide resolved
.github/workflows/README.md Outdated Show resolved Hide resolved
.github/workflows/README.md Outdated Show resolved Hide resolved
.github/workflows/README.md Outdated Show resolved Hide resolved
@VJalili VJalili merged commit 7afce15 into broadinstitute:master Jan 4, 2022
@VJalili VJalili deleted the push_docker_images branch January 4, 2022 21:22
@VJalili
Copy link
Member Author

VJalili commented Jan 4, 2022

@mwalker174 Thanks for reviewing this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants