Skip to content

fix copy ci

fix copy ci #9

Workflow file for this run

name: production
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
testing:
runs-on: ubuntu-latest
timeout-minutes: 5
# services:
# postgres:
# image: postgres:latest
# env:
# POSTGRES_USER: postgres
# POSTGRES_PASSWORD: postgres
# POSTGRES_DB: test
# ports:
# - 5432:5432
# options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Use Node.js
uses: actions/setup-node@v2
with:
node-version: "14.x"
- name: Install dependencies
run: cd ./server && npm install
# - name: Run database migrations
# run: cd ./server && npm run migrate:up
# env:
# NODE_ENV: test
# DB_NAME: test
# DB_USER: postgres
# DB_PASSWORD: postgres
# DB_HOST: localhost
# DB_PORT: 5432
# DB_LOGGING: false
- name: Run tests
run: cd ./server && npm run test:ci
env:
NODE_ENV: test
PORT: 5000
SECRET_OR_KEY: test_secret
building:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Use Node.js
uses: actions/setup-node@v2
with:
node-version: "14.x"
- name: Install dependencies
run: cd ./client && npm install
- name: Build
run: cd ./client && npm run build
- name: Copy
run: cd ./client && cp -r build/ ../server/src