Update action.yml

pull/7267/head
zomars 2023-02-20 15:41:07 -07:00
parent 271fe44bf0
commit e92ad12b54
1 changed files with 3 additions and 10 deletions

View File

@ -66,25 +66,17 @@ inputs:
runs: runs:
using: "composite" using: "composite"
services:
postgres:
image: postgres:12.1
env:
POSTGRES_USER: postgres
POSTGRES_DB: calendso
ports:
- 5432:5432
steps: steps:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
- uses: ./.github/actions/yarn-install - uses: ./.github/actions/yarn-install
with: with:
node_version: ${{ secrets.NODE_VERSION }} node_version: ${{ inputs.node_version }}
- name: Cache production build - name: Cache production build
id: prod-build-cache id: prod-build-cache
uses: actions/cache@v3 uses: actions/cache@v3
env: env:
cache-name: prod-build cache-name: prod-build
key-1: ${{ secrets.NODE_VERSION }}-${{ hashFiles('yarn.lock') }} key-1: ${{ inputs.node_version }}-${{ hashFiles('yarn.lock') }}
key-2: ${{ hashFiles('apps/web/next.config.js') }} key-2: ${{ hashFiles('apps/web/next.config.js') }}
with: with:
path: | path: |
@ -95,6 +87,7 @@ runs:
${{ runner.os }}-${{ env.cache-name }}-${{ env.key-1 }}- ${{ runner.os }}-${{ env.cache-name }}-${{ env.key-1 }}-
- name: Next.js production build - name: Next.js production build
if: steps.prod-build-cache.outputs.cache-hit != 'true' if: steps.prod-build-cache.outputs.cache-hit != 'true'
shell: bash
run: | run: |
yarn db-seed yarn db-seed
yarn build yarn build