Skip to content

Commit

Permalink
Chore: fix release jobs (#4764)
Browse files Browse the repository at this point in the history
  • Loading branch information
katspaugh authored Jan 13, 2025
1 parent 6d697ad commit 2f14868
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 10 deletions.
15 changes: 6 additions & 9 deletions .github/workflows/web-deploy-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,18 +58,16 @@ jobs:
if: startsWith(github.ref, 'refs/heads/main')
env:
BUCKET: s3://${{ secrets.AWS_STAGING_BUCKET_NAME }}/current
run: |
cd ./apps/web
bash ./scripts/github/s3_upload.sh
working-directory: apps/web
run: bash ./scripts/github/s3_upload.sh

# Dev
- name: Deploy to the dev S3
if: startsWith(github.ref, 'refs/heads/dev')
env:
BUCKET: s3://${{ secrets.AWS_DEVELOPMENT_BUCKET_NAME }}
run: |
cd ./apps/web
bash ./scripts/github/s3_upload.sh
working-directory: apps/web
run: bash ./scripts/github/s3_upload.sh

### PRs ###

Expand All @@ -86,9 +84,8 @@ jobs:
if: github.event.number
env:
BUCKET: s3://${{ secrets.AWS_REVIEW_BUCKET_NAME }}/walletweb/${{ steps.extract_branch.outputs.branch }}
run: |
cd ./apps/web
bash ./scripts/github/s3_upload.sh
working-directory: apps/web
run: bash ./scripts/github/s3_upload.sh

# Comment
- name: Post a deployment link in the PR
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/web-deploy-production.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,11 @@ jobs:

- name: Create archive
run: tar -czf "$ARCHIVE_NAME".tar.gz out
working-directory: apps/web

- name: Create checksum
run: sha256sum "$ARCHIVE_NAME".tar.gz > ${{ env.ARCHIVE_NAME }}-sha256-checksum.txt
working-directory: apps/web

- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v4
Expand All @@ -44,10 +46,12 @@ jobs:
BUCKET: s3://${{ secrets.AWS_STAGING_BUCKET_NAME }}/releases/${{ github.event.release.tag_name }}
CHECKSUM_FILE: ${{ env.ARCHIVE_NAME }}-sha256-checksum.txt
run: bash ./scripts/github/s3_upload.sh
working-directory: apps/web

# Script to prepare production deployments
- name: Prepare deployment
run: bash ./scripts/github/prepare_production_deployment.sh
working-directory: apps/web
env:
PROD_DEPLOYMENT_HOOK_TOKEN: ${{ secrets.PROD_DEPLOYMENT_HOOK_TOKEN }}
PROD_DEPLOYMENT_HOOK_URL: ${{ secrets.PROD_DEPLOYMENT_HOOK_URL }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/web-tag-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
- name: Extract version
id: version
run: |
NEW_VERSION=$(node -p 'require("./package.json").version')
NEW_VERSION=$(node -p 'require("./apps/web/package.json").version')
echo "version=v$NEW_VERSION" >> $GITHUB_OUTPUT
- name: Create a git tag
Expand Down

0 comments on commit 2f14868

Please sign in to comment.