Skip to content

chore(deps): pin dependencies #1102

chore(deps): pin dependencies

chore(deps): pin dependencies #1102

Workflow file for this run

name: PR Validate & Preview
on:
pull_request:
branches:
- main
concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
# These permissions are needed to interact with GitHub's OIDC Token endpoint.
permissions:
id-token: write
contents: read
pull-requests: write
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
- uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4
with:
node-version: '22'
- name: Install deps, lint, build and test project
uses: ./.github/actions/install
- name: Deploy PR Preview
uses: ./.github/actions/deploy
with:
aws_role: ${{ secrets.AWS_ROLE_TEST_ACCOUNT }}
aws_deploy_path: ${{ secrets.AWS_TEST_BUCKET }}/preview/${{ github.event.number }}
aws_s3_sync_args: --include '*' --exclude '*/*'
aws_s3_cache: no-store
cloudfront_distribution_id: ${{ secrets.CLOUDFRONT_ID_TEST }}
cloudfront_invalidation_paths: '/preview/${{ github.event.number }}/*'
- name: Adding comment to PR with preview link and validation results
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7
with:
script: |
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: `Check **PR ${{ github.event.number }}** preview 👀 <br> <br> [https://x.test.empathy.co/preview/${{ github.event.number }}/index.html](https://x.test.empathy.co/preview/${{ github.event.number }}/index.html) `
})