diff --git a/.github/workflows/develop_server_deployer.yaml b/.github/workflows/develop_server_deployer.yaml index eecc6b3a..b9863a38 100644 --- a/.github/workflows/develop_server_deployer.yaml +++ b/.github/workflows/develop_server_deployer.yaml @@ -54,6 +54,15 @@ jobs: if: github.event_name == 'workflow_run' run: echo "version=${{ steps.triggered_workflow_run.outputs.version }}" >> $GITHUB_OUTPUT + - name: Set deployed image version + id: set_version + run: | + if [[ "${{ github.event_name }}" == "workflow_run" ]]; then + echo "version=${{ steps.triggered_workflow_run.outputs.version }}" >> $GITHUB_OUTPUT + else + echo "version=${{ github.event.inputs.version }}" >> $GITHUB_OUTPUT + fi + - name: Send discord notification (develop server deploy start) uses: appleboy/discord-action@master with: @@ -64,7 +73,7 @@ jobs: > > 🛢️ Repository : ${{ github.repository }} > 🎋 Branch : ${{ github.ref }} - > 📐 Version : ${{ steps.triggered_workflow_run.outputs.version || github.event.inputs.version }} + > 📐 Version : ${{ steps.set_version.outputs.version }} > 🔁 Run Attempt : ${{ github.run_attempt }} > 🤗 Actor : ${{ github.triggering_actor }} @@ -116,10 +125,6 @@ jobs: jq -s '.[0] * .[1]' <(echo "$VARS_CONTEXT") <(echo "$SECRETS_CONTEXT") \ | jq -r 'to_entries | map("\(.key)=\(.value)") | .[]' > .env - - name: Set deployed image version - id: set_version - run: echo "version=${{ steps.triggered_workflow_run.outputs.version || github.event.inputs.version }}" >> $GITHUB_OUTPUT - - name: Run Docker Compose up id: deploy uses: appleboy/ssh-action@master