Skip to content

Commit

Permalink
chore: publish a next-release-unstable tag (#4672)
Browse files Browse the repository at this point in the history
  • Loading branch information
reesscot authored Nov 8, 2023
1 parent 6f1fae6 commit 26dd8de
Show file tree
Hide file tree
Showing 2 changed files with 75 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build-system-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,9 @@ jobs:
language: ts
node-version: 20
- framework: react
framework-version: 17
framework-version: 18
build-tool: next
build-tool-version: 11
build-tool-version: 12
pkg-manager: npm
language: ts
node-version: 20
Expand Down
73 changes: 73 additions & 0 deletions .github/workflows/publish-next-release-unstable.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
# Description: This workflow runs unit + e2e tests, then publishes UI packages
# to `@next-release` NPM tag.
#
# Triggered by: merge to `next-release/main`

name: Test and Publish / next-release-unstable

on:
push:
branches: [next-release/main]

permissions:
id-token: write # This is required for requesting the JWT
contents: read # This is required for actions/checkout

jobs:
setup-cache:
uses: aws-amplify/amplify-ui/.github/workflows/reusable-setup-cache.yml@next-release/main
with:
commit: ${{ github.sha }}
repository: ${{ github.repository }}

publish:
uses: ./.github/workflows/reusable-tagged-publish.yml
with:
dist-tag: next-release-unstable
secrets:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

build-test:
needs: publish
runs-on: ubuntu-latest
environment: ci
steps:
- name: Checkout repo
uses: actions/checkout@24cb9080177205b6e8c946b17badbe402adc938f # v3.4.0 https://github.com/actions/checkout/commit/24cb9080177205b6e8c946b17badbe402adc938f
- name: Setup Node.js 20
uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3.6.0 https://github.com/actions/setup-node/commit/64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c
with:
node-version: 20
cache: 'yarn'
env:
SEGMENT_DOWNLOAD_TIMEOUT_MINS: 2
- name: Add Amplify CLI
run: yarn global add @aws-amplify/cli
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-region: us-east-2
role-to-assume: ${{ secrets.AUTH_E2E_ROLE_ARN }}
# Amplify CLI does not support headless pull with temporary credentials
# when useProfile is false.
# See: https://github.com/aws-amplify/amplify-cli/issues/11009.
- name: Create temp AWS profile
run: |
aws configure set aws_access_key_id $AWS_ACCESS_KEY_ID && \
aws configure set aws_secret_access_key $AWS_SECRET_ACCESS_KEY && \
aws configure set aws_session_token $AWS_SESSION_TOKEN && \
aws configure set default.region $AWS_REGION
- name: Pull down AWS environments
run: yarn pull
working-directory: ./canary
- name: Delete AWS Profile
run: rm -rf ~/.aws
- name: Setup canary apps against @next-release-unstable
run: yarn setup:next-release-unstable
working-directory: ./canary
- name: Run yarn install on each sample app
run: yarn install
working-directory: ./canary
- name: Run yarn build on each sample app
run: yarn build
working-directory: ./canary

0 comments on commit 26dd8de

Please sign in to comment.