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

Fix and minor improvements to all-in-one github action #2667

Merged
merged 1 commit into from
Nov 30, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .github/workflows/all-in-one-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@ jobs:

- name: Export BRANCH variable for pull_request event
run: |
echo "BRANCH=${GITHUB_HEAD_REF}" >> $GITHUB_ENV
export BRANCH=${GITHUB_HEAD_REF}
echo "we are on branch=$BRANCH"
echo "BRANCH=${BRANCH}" >> $GITHUB_ENV
Copy link
Member

Choose a reason for hiding this comment

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

The next step could also echo the value

Copy link
Contributor Author

Choose a reason for hiding this comment

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

sure, I will do that while moving this to its own action as you suggested. Since it can be shared with other docker build and push jobs for all jaeger components.

if: github.event_name == 'pull_request'

- name: Export BRANCH variable for push event
Expand Down
2 changes: 1 addition & 1 deletion scripts/travis/build-all-in-one-image.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ run_integration_test() {

upload_to_docker() {
# Only push the docker container to Docker Hub for master branch
if [[ ("$BRANCH" == "master" || $BRANCH =~ ^v[0-9]+\.[0-9]+\.[0-9]+$) && "DOCKERHUB_LOGIN" == "true" ]]; then
if [[ ("$BRANCH" == "master" || $BRANCH =~ ^v[0-9]+\.[0-9]+\.[0-9]+$) && "$DOCKERHUB_LOGIN" == "true" ]]; then
echo "upload $1 to Docker Hub"
export REPO=$1
bash ./scripts/travis/upload-to-docker.sh
Expand Down