Skip to content

chore: Upgrade dependencies for cli #4279

chore: Upgrade dependencies for cli

chore: Upgrade dependencies for cli #4279

Workflow file for this run

name: Build
on:
merge_group:
types: [checks_requested]
pull_request:
paths:
- packages/**
- package.json
- yarn.lock
concurrency:
group: build-${{ github.head_ref }}
cancel-in-progress: true
jobs:
build-and-package:
runs-on: ubuntu-latest
container:
image: docker.mirror.hashicorp.services/hashicorp/jsii-terraform
env:
CHECKPOINT_DISABLE: "1"
timeout-minutes: 60
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- name: "Add Git safe.directory" # Go 1.18+ started embedding repo info in the build and e.g. building @cdktf/hcl2json fails without this
run: git config --global --add safe.directory /__w/terraform-cdk/terraform-cdk
- name: ensure correct user
run: chown -R root /__w/terraform-cdk
# Setup caches for yarn, and go
- name: Get cache directory paths
id: global-cache-dir-path
run: |
echo "yarn=$(yarn cache dir)" >> $GITHUB_OUTPUT
mkdir -p /usr/local/share/.cache/go
echo "go=/usr/local/share/.cache/go" >> $GITHUB_OUTPUT
- uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
with:
path: ${{ steps.global-cache-dir-path.outputs.yarn }}
key: yarn-${{ runner.os }}-${{ hashFiles('**/yarn.lock') }}-build
restore-keys: |
yarn-${{ runner.os }}-${{ hashFiles('**/yarn.lock') }}-
yarn-${{ runner.os }}-
- uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
with:
path: ${{ steps.global-cache-dir-path.outputs.go }}
key: go-${{ runner.os }}-${{ hashFiles('**/go.sum') }}-build
restore-keys: |
go-${{ runner.os }}-${{ hashFiles('**/go.sum') }}-
go-${{ runner.os }}-
- name: install dependencies
run: yarn install
- name: build and package
run: |
yarn build
yarn package
env:
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
GOCACHE: ${{ steps.global-cache-dir-path.outputs.go }}