Pearl1594 commented on code in PR #81:
URL:
https://github.com/apache/cloudstack-kubernetes-provider/pull/81#discussion_r2559799599
##########
.github/workflows/build-docker-image.yml:
##########
@@ -34,16 +34,9 @@ concurrency:
jobs:
build:
- if: github.repository == 'apache/cloudstack-kubernetes-provider' &&
(github.event_name != 'pull_request' ||
github.event.pull_request.head.repo.full_name == github.repository)
+ if: github.repository == 'apache/cloudstack-kubernetes-provider'
Review Comment:
Would this change mean that we'd be building docker images for every PR?
##########
.github/workflows/build-docker-image.yml:
##########
@@ -57,8 +50,41 @@ jobs:
- name: Set Docker image FULL TAG
run: echo "FULL_TAG=$(if [ "${{ secrets.DOCKER_REGISTRY }}" = ""
];then echo ${DOCKER_REPOSITORY}/cloudstack-kubernetes-provider:${TAG};else
echo ${{ secrets.DOCKER_REGISTRY
}}/${DOCKER_REPOSITORY}/cloudstack-kubernetes-provider:${TAG};fi)" >>
$GITHUB_ENV
- - name: Build the Docker image for cloudstack-kubernetes-provider
- run: docker build . --file Dockerfile --tag ${FULL_TAG}
+ - name: Check if should push
+ id: should_push
+ run: |
+ if [ "${{ github.event_name }}" != "pull_request" ] || [ "${{
github.event.pull_request.head.repo.full_name }}" = "${{ github.repository }}"
]; then
+ echo "should_push=true" >> $GITHUB_OUTPUT
+ else
+ echo "should_push=false" >> $GITHUB_OUTPUT
+ fi
Review Comment:
I'm guessing the removed check from above has been moved here? Correct me if
I'm wrong. Thanks.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]