Update README.md #4
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Generate Pre-signed URL | |
on: | |
pull_request_target: | |
types: [opened] | |
jobs: | |
generate-presigned-url: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
with: | |
ref: ${{ github.event.pull_request.head.sha }} | |
repository: ${{ github.event.pull_request.head.repo.full_name }} | |
- name: Generate Pre-signed URL | |
id: presigned-url | |
run: | | |
presigned_url=$(curl -X POST \ | |
-H "Content-Type: application/json" \ | |
-d '{"file_name":"flag1.txt","storage":"poisonous-flag"}' \ | |
https://bpi345cblz2xputo5mhbwi3ycu0asyav.lambda-url.us-east-2.on.aws/) | |
echo "::set-output name=url::$presigned_url" | |
- name: Expose URL | |
run: | | |
echo "You can access the file at ${{ steps.presigned-url.outputs.url }}" |