diff --git a/.github/actions/cache-db/action.yml b/.github/actions/cache-db/action.yml index 002fb7f256f22f..3e9a5585661ea7 100644 --- a/.github/actions/cache-db/action.yml +++ b/.github/actions/cache-db/action.yml @@ -15,11 +15,12 @@ runs: uses: actions/cache@v3 env: cache-name: cache-db + key-1: ${{ hashFiles('packages/prisma/**') }} with: path: ${{ inputs.path }} - key: ${{ runner.os }}-${{ env.cache-name }}-${{ inputs.path }}-${{ github.sha }} + key: ${{ runner.os }}-${{ env.cache-name }}-${{ inputs.path }}-${{ env.key-1 }}-${{ github.sha }} restore-keys: | - ${{ runner.os }}-${{ env.cache-name }}-${{ inputs.path }}-${{ github.sha }} + ${{ runner.os }}-${{ env.cache-name }}-${{ inputs.path }}-${{ env.key-1 }}-${{ github.sha }} - name: Postgres Dump Backup if: steps.cache-db.outputs.cache-hit != 'true' uses: tj-actions/pg-dump@v2.3 diff --git a/.github/workflows/production-build.yml b/.github/workflows/production-build.yml index cc6c5efaaebab3..42dacb96c205f2 100644 --- a/.github/workflows/production-build.yml +++ b/.github/workflows/production-build.yml @@ -22,8 +22,8 @@ jobs: id: cache-db - uses: ./.github/actions/yarn-install - uses: ./.github/actions/cache-build - - uses: ./.github/actions/env-read-file id: cache-build + - uses: ./.github/actions/env-read-file - run: yarn db-seed if: steps.cache-db.outputs.cache-hit != 'true' - run: yarn build