Skip to content

Use AWS Amplify to deploy PRs#3133

Open
jpzwarte wants to merge 12 commits into
mainfrom
chore/3094-add-aws-amplify-deploy
Open

Use AWS Amplify to deploy PRs#3133
jpzwarte wants to merge 12 commits into
mainfrom
chore/3094-add-aws-amplify-deploy

Conversation

@jpzwarte
Copy link
Copy Markdown
Member

@jpzwarte jpzwarte commented Mar 25, 2026

Closes #3094

Changes

Storybook (storybook.yml)

  • Replace Chromatic/existing deployment with AWS Amplify for PR previews
  • Deploy PR builds to storybook-{PR number} branches on Amplify
  • Deploy main branch pushes to the main Amplify branch
  • Clean up Amplify branch when PR is closed
  • Remove secrets from env block; reference secrets directly in steps

Website (website.yml)

  • Replace Azure Static Web Apps with AWS Amplify for PR previews
  • Deploy PR builds to website-{PR number} branches on Amplify
  • Clean up Amplify branch when PR is closed
  • Keep GitHub Pages deployment for production (main push)

Shared PR comment

  • Both Storybook and Website workflows now share a single PR comment (### 🕸 Preview deploys)
  • Each workflow preserves the other's line item when updating the comment (using edit-mode: replace with body reconstruction)

Housekeeping (all workflows)

  • Upgrade Node.js from 22 → 24 across all workflows
  • Remove unused CHROMATIC_PROJECT_TOKEN from ci.yml env
  • Remove unused FIGMA_TOKEN from ci.yml, chromatic.yml, and release.yml env
  • Consistent quote style for branch patterns in chromatic.yml and ci.yml
  • Minor formatting cleanup in ci.yml

New secrets required

  • AWS_ACCESS_KEY_ID
  • AWS_SECRET_ACCESS_KEY
  • AWS_REGION
  • AWS_AMPLIFY_APP_ID

Copilot AI review requested due to automatic review settings March 25, 2026 12:54
@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Mar 25, 2026

⚠️ No Changeset found

Latest commit: 2dbbafc

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Mar 25, 2026

🕸 Website preview

You can view a preview here (commit 7c0ee54fcd33b2a1f2c6a877c1377fbd27f7787b).

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the Storybook GitHub Actions workflow to deploy Storybook previews to AWS Amplify (including per-PR preview URLs) and to clean up Amplify branches when PRs close.

Changes:

  • Replaces Azure Static Web Apps deployment with an AWS Amplify deployment flow (create branch/deployment, upload ZIP, start deployment).
  • Posts the Amplify preview URL back to the pull request as a comment.
  • Updates the cleanup job to delete the corresponding Amplify branch on PR close.

Comment thread .github/workflows/storybook.yml Outdated
Comment thread .github/workflows/storybook.yml
Comment thread .github/workflows/storybook.yml Outdated
Comment thread .github/workflows/storybook.yml Outdated
Comment thread .github/workflows/storybook.yml Outdated
Copilot AI review requested due to automatic review settings March 25, 2026 13:16
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 4 comments.

Comment thread .github/workflows/storybook.yml Outdated
Comment thread .github/workflows/storybook.yml Outdated
Comment thread .github/workflows/storybook.yml Outdated
Comment thread .github/workflows/storybook.yml
Copilot AI review requested due to automatic review settings March 26, 2026 09:43
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 5 comments.

Comment thread .github/workflows/storybook.yml Outdated
Comment thread .github/workflows/storybook.yml Outdated
Comment thread .github/workflows/storybook.yml
Comment thread .github/workflows/storybook.yml Outdated
Comment thread .github/workflows/storybook.yml Outdated
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Mar 26, 2026

🕸 Storybook preview

You can view a preview here (commit 7c0ee54fcd33b2a1f2c6a877c1377fbd27f7787b).

Copilot AI review requested due to automatic review settings April 2, 2026 09:29
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 2 comments.

Comment thread .github/workflows/storybook.yml Outdated
Comment thread .github/workflows/storybook.yml Outdated
Copilot AI review requested due to automatic review settings April 2, 2026 09:52
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 5 comments.

Comments suppressed due to low confidence (1)

.github/workflows/website.yml:65

  • This workflow still deploys PR previews (and cleanup) via Azure Static Web Apps. Since this PR is titled "Use AWS Amplify to deploy PRs" and closes #3094 (which aims to move away from Azure preview environment limits), consider migrating the Website preview job to Amplify as well (or update the PR scope/title/issue closure so it doesn't imply the Website has been migrated).
          node-version: 24
          cache: 'yarn'
      - run: yarn install --immutable
      - run: NODE_ENV=production yarn website
      - uses: azure/static-web-apps-deploy@v1

Comment thread .github/workflows/website.yml
Comment thread .github/workflows/website.yml
Comment thread .github/workflows/storybook.yml Outdated
Comment thread .github/workflows/storybook.yml
Comment thread .github/workflows/storybook.yml
@sl-design-system sl-design-system deleted a comment from github-actions Bot Apr 2, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 2, 2026

Copilot AI review requested due to automatic review settings April 2, 2026 10:35
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 6 comments.

Comment thread .github/workflows/website.yml
Comment thread .github/workflows/website.yml
Comment thread .github/workflows/website.yml
Comment thread .github/workflows/storybook.yml
Comment thread .github/workflows/storybook.yml Outdated
Comment thread .github/workflows/storybook.yml
@jpzwarte jpzwarte marked this pull request as ready for review April 2, 2026 10:49
Copilot AI review requested due to automatic review settings April 2, 2026 10:49
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.

Comment thread .github/workflows/website.yml
Comment thread .github/workflows/website.yml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Change the way we deploy PRs

5 participants