-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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 + push preview
image only on master
branch
#6507
Conversation
d576464
to
086f665
Compare
@@ -172,7 +181,7 @@ jobs: | |||
- frontend-unit-tests | |||
- frontend-e2e-tests | |||
- build-skip-check | |||
if: ${{ needs.build-skip-check.outputs.skip }} == false | |||
if: needs.build-skip-check.outputs.skip == 'false' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Turns out we don't need the {{ }}
jinja braces, and this is now actually filtering whereas it was not before.
@justinclift when you have a minute, mind giving this a look? |
Codecov Report
@@ Coverage Diff @@
## master #6507 +/- ##
=======================================
Coverage 61.10% 61.10%
=======================================
Files 158 158
Lines 12883 12883
Branches 1753 1753
=======================================
Hits 7872 7872
Misses 4765 4765
Partials 246 246 |
if [[ "${{ vars.DOCKER_USER }}" == '' ]]; then | ||
echo 'Docker user is empty. Skipping build+push' | ||
echo skip=true >> "$GITHUB_OUTPUT" | ||
elif [[ "${{ secrets.DOCKER_PASS }}" == '' ]]; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea. The extra messages will help us figure out what's going wrong, when something is not working right. 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. 😄
What type of PR is this?
Description
The CI is trying to build + push the
preview
tagged image on PRs, but we only want that to happen on themaster
branch. This change adds a condition to the CI step that runs the build+push, filtering for the ref to bemaster
as a condition of the CI step being run.How is this tested?
Added a test commit that skips the e2e/unit tests (for faster iteration) and verified that the build+push CI step does not run on this PR.
Related Tickets & Documents
#6503 , #6505 , #6420