diff --git a/.github/workflows/storybook.yml b/.github/workflows/storybook.yml index 40ba574f65..2055902179 100644 --- a/.github/workflows/storybook.yml +++ b/.github/workflows/storybook.yml @@ -31,11 +31,25 @@ jobs: with: fetch-depth: 0 - - name: Install & cache node_modules - uses: ./.github/actions/shared-node-cache + - name: Get yarn cache + id: yarn-cache + run: echo "::set-output name=dir::$(yarn cache dir)" + - uses: actions/cache@v4 with: - node-version: ${{ matrix.node-version }} - ssh-private-key: ${{ secrets.KHAN_ACTIONS_BOT_SSH_PRIVATE_KEY }} + path: ${{ steps.yarn-cache.outputs.dir }} + key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} + restore-keys: | + ${{ runner.os }}-yarn- + - name: Cache node modules + uses: actions/cache@v4 + with: + path: node_modules + key: ${{ runner.OS }}-build-${{ hashFiles('**/yarn.lock') }} + restore-keys: | + ${{ runner.OS }}-node_modules- + + - name: Install + run: yarn install - name: Build Storybook run: yarn build-storybook