diff --git a/.github/actions/yarn-build/action.yml b/.github/actions/yarn-build/action.yml deleted file mode 100644 index e2f2ac2556de2c..00000000000000 --- a/.github/actions/yarn-build/action.yml +++ /dev/null @@ -1,20 +0,0 @@ -name: Production Build -description: "Creates a production build, caches it and restores if necessary" -runs: - using: "composite" - steps: - - uses: ./.github/actions/env-read-file - - uses: ./.github/actions/cache-db - id: cache-db - with: - DATABASE_URL: ${{ env.DATABASE_URL }} - - uses: ./.github/actions/cache-build - id: prod-build-cache - - name: Next.js production build - if: steps.cache-db.outputs.cache-hit != 'true' - shell: bash - run: yarn db-seed - - name: Prisma DB seed - if: steps.prod-build-cache.outputs.cache-hit != 'true' - shell: bash - run: yarn build diff --git a/.github/workflows/production-build.yml b/.github/workflows/production-build.yml index 11c12e3271ce9f..a3c5415becfe1d 100644 --- a/.github/workflows/production-build.yml +++ b/.github/workflows/production-build.yml @@ -20,4 +20,9 @@ jobs: - uses: actions/checkout@v3 - uses: ./.github/actions/yarn-install - uses: ./.github/actions/env-read-file - - uses: ./.github/actions/yarn-build + - uses: ./.github/actions/cache-db + with: + DATABASE_URL: ${{ secrets.DATABASE_URL }} + - uses: ./.github/actions/cache-build + - run: yarn db-seed + - run: yarn build