main #445
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
env: | |
AWS_REGION: us-west-2 | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
PULUMI_ACCESS_TOKEN: ${{ secrets.PULUMI_ACCESS_TOKEN }} | |
PULUMI_API: https://api.pulumi-staging.io | |
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} | |
jobs: | |
lint: | |
name: Run lint | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repo | |
uses: actions/checkout@v2 | |
- name: Unshallow clone for tags | |
run: git fetch --prune --unshallow --tags | |
- name: Setup Node | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 14.17.x | |
registry-url: https://registry.npmjs.org | |
- name: Install Yarn | |
run: curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version 1.13.0 | |
- name: Install packages | |
run: yarn install | |
- name: Run lint | |
run: yarn run lint | |
build: | |
name: Build and Test | |
runs-on: ubuntu-latest | |
concurrency: build-and-test # Currently integration tests can clash across branches. | |
steps: | |
- name: Checkout Repo | |
uses: actions/checkout@v2 | |
- name: Install pulumictl | |
uses: jaxxstorm/[email protected] | |
with: | |
repo: pulumi/pulumictl | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
aws-region: ${{ env.AWS_REGION }} | |
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
role-duration-seconds: 3600 | |
role-session-name: ${{ env.PROVIDER }}@githubActions | |
role-to-assume: ${{ secrets.AWS_CI_ROLE_ARN }} | |
- name: Unshallow clone for tags | |
run: git fetch --prune --unshallow --tags | |
- name: Setup Node | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 14.17.x | |
registry-url: https://registry.npmjs.org | |
- name: Install Go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: 1.16.x | |
- name: Install Yarn | |
run: curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version 1.13.0 | |
- name: Install packages | |
run: yarn install | |
- name: Run build | |
run: yarn run build | |
- name: Run unit tests | |
run: yarn run test | |
- name: yarn link | |
run: pushd lib && yarn link && popd | |
- name: set script-shell | |
run: yarn config set script-shell /bin/bash | |
- name: Set up gotestfmt | |
uses: haveyoudebuggedit/gotestfmt-action@v2 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Run examples | |
run: yarn run test-examples-gotestfmt | |
- if: github.event_name == 'push' | |
name: Publish Dev Package | |
uses: JS-DevTools/npm-publish@v1 | |
with: | |
access: "public" | |
token: ${{ secrets.NPM_TOKEN }} | |
package: ${{github.workspace}}/lib/package.json | |
tag: dev | |
check-version: true | |
name: main | |
"on": | |
schedule: | |
- cron: '0 7 * * *' | |
push: | |
branches: | |
- main | |
paths-ignore: | |
- CHANGELOG.md | |
tags-ignore: | |
- v* | |
- sdk/* | |
- '**' |