diff --git a/.github/workflows/deploy-action.yml b/.github/workflows/deploy-action.yml index d944478a5b..f72bf952c1 100644 --- a/.github/workflows/deploy-action.yml +++ b/.github/workflows/deploy-action.yml @@ -21,7 +21,7 @@ jobs: echo $FILES echo "file_list=$FILES" >> $GITHUB_OUTPUT - extract-version: + read-version: runs-on: ubuntu-latest outputs: okr-docker-image: ${{ vars.NEW_VALUE_URL }}:${{ steps.store-version.outputs.version}}-PROD @@ -35,7 +35,7 @@ jobs: id: store-version build-docker-image: - needs: extract-version + needs: read-version runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v4 @@ -68,7 +68,7 @@ jobs: with: context: . file: docker/Dockerfile - tags: ${{ needs.extract-version.outputs.okr-docker-image}} + tags: ${{ needs.read-version.outputs.okr-docker-image}} load: true push: false outputs: type=docker,dest=/tmp/okr-docker-image.tar @@ -80,12 +80,12 @@ jobs: path: /tmp/okr-docker-image.tar - name: print imagetags - run: echo ${{ needs.extract-version.outputs.okr-docker-image}} + run: echo ${{ needs.read-version.outputs.okr-docker-image}} e2e-docker: runs-on: ubuntu-24.04 - needs: [build-docker-image, extract-version, get-e2e-files] + needs: [build-docker-image, read-version, get-e2e-files] strategy: fail-fast: false matrix: @@ -132,7 +132,7 @@ jobs: okr-deploy: runs-on: ubuntu-latest - needs: [e2e-docker, extract-version] + needs: [e2e-docker, read-version] steps: - name: Checkout project uses: actions/checkout@v4 @@ -157,7 +157,7 @@ jobs: password: ${{ secrets.QUAY_TOKEN }} - name: Push - run: docker push ${{ needs.extract-version.outputs.okr-docker-image}} + run: docker push ${{ needs.read-version.outputs.okr-docker-image}} - name: Install yq shell: bash @@ -174,7 +174,7 @@ jobs: COMMITPREFIX: '[CTS]' run: | curl -s --header "PRIVATE-TOKEN: ${{secrets.GITLAB_ACCESS_TOKEN}}" "${{vars.TARGET_GITLAB_REPOSITORY}}/files/${{vars.GITLAB_FILEPATH}}?ref=${{vars.TARGET_GITLAB_REFERENCE}}" -H "Accept: application/json" -H "Content-Type: application/json" | jq -r '.content' | base64 --decode > response.yaml - yq -i "${{vars.YAML_PATH}} = \"${{needs.extract-version.outputs.okr-docker-image}}\"" response.yaml + yq -i "${{vars.YAML_PATH}} = \"${{needs.read-version.outputs.okr-docker-image}}\"" response.yaml UPDATED_CONTENT=$(cat response.yaml) curl --request PUT --header 'PRIVATE-TOKEN: ${{secrets.GITLAB_ACCESS_TOKEN}}' -F "branch=${{vars.TARGET_GITLAB_REFERENCE}}" -F "author_email=actions@gitlab.com" -F "author_name=GitLab Actions" -F "content=${UPDATED_CONTENT}" -F "commit_message=$COMMITPREFIX Automated changes to ${{vars.FILEPATH_COMMIT}}" "${{vars.TARGET_GITLAB_REPOSITORY}}/files/${{vars.GITLAB_FILEPATH}}" diff --git a/.github/workflows/staging-deploy-action.yml b/.github/workflows/staging-deploy-action.yml index 7f09d023dc..3b777d3725 100644 --- a/.github/workflows/staging-deploy-action.yml +++ b/.github/workflows/staging-deploy-action.yml @@ -109,7 +109,7 @@ jobs: e2e-docker: runs-on: ubuntu-24.04 - needs: [build-docker-image,update-version] + needs: [build-docker-image,update-version,get-e2e-files] strategy: fail-fast: false matrix: @@ -135,6 +135,11 @@ jobs: -e SPRING_PROFILES_ACTIVE=integration-test \ ${{ needs.update-version.outputs.okr-docker-image}} & + - name: set node version + uses: actions/setup-node@v2 + with: + node-version: ${{vars.NODE_VERSION}} + - name: Cypress run e2e tests uses: cypress-io/github-action@v6 with: