diff --git a/.github/workflows/build-push.yml b/.github/workflows/build-push.yml index bae8ca1..558b004 100644 --- a/.github/workflows/build-push.yml +++ b/.github/workflows/build-push.yml @@ -1,7 +1,7 @@ name: Build and push on: - pull_request: + pull_request_target: branches: [ "main" ] types: - closed @@ -9,7 +9,7 @@ on: jobs: build: - if: github.event.pull_request.merged == true + if: ${{ github.event_name == 'workflow_dispatch' || github.event.pull_request.merged == true }} runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 @@ -41,5 +41,6 @@ jobs: valueFile: 'manifests/base/deployment.yaml' propertyPath: 'spec.template.spec.containers[0].image' value: registry.nordix.org/eiffel/etos-suite-starter:${{ steps.image.outputs.version }} + branch: main commitChange: true message: Updating manifest image to version ${{ steps.image.outputs.version }}