Skip to content
Open
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
8 changes: 7 additions & 1 deletion .github/workflows/push_image_pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,13 +52,18 @@ jobs:
needs: extract-data
name: push PR image
runs-on: ubuntu-latest
outputs:
commands_url: ${{ steps.commands-url.outputs.commands_url }}
steps:
- name: download artifact
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8
with:
name: pr
run-id: ${{ github.event.workflow_run.id }}
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: read commands URL
id: commands-url
run: echo "commands_url=$(cat ./commands-url)" >> $GITHUB_OUTPUT
- name: load images
env:
MAIN_IMAGE: ${{ needs.extract-data.outputs.main_image }}
Expand Down Expand Up @@ -88,12 +93,13 @@ jobs:
MAIN_IMAGE: ${{ needs.extract-data.outputs.main_image }}
SHORT_SHA: ${{ needs.extract-data.outputs.short_sha }}
PR_ID: ${{ needs.extract-data.outputs.pr_id }}
COMMANDS_URL: ${{ needs.push.outputs.commands_url }}
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const mainImage = process.env.MAIN_IMAGE;
const shortSHA = process.env.SHORT_SHA;
const commandsURL = fs.readFileSync('./commands-url');
const commandsURL = process.env.COMMANDS_URL;
github.rest.issues.createComment({
issue_number: parseInt(process.env.PR_ID, 10),
owner: context.repo.owner,
Expand Down
Loading