Skip to content

fix github action ci test #91

fix github action ci test

fix github action ci test #91

Workflow file for this run

name: Dockerfile CI
on: [pull_request]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16.x]
services:
redis:
image: redis
ports:
- "0.0.0.0:6379:6379"
postgres:
image: postgres:14
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: postgres
ports:
- "0.0.0.0:5432:5432"
# needed because the postgres container does not provide a healthcheck
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 ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
# - name: "Run docker backend build"
# run:
# docker build --build-arg APP=backend --build-arg START_COMMAND=start -t celluloid-backend:latest .

Check failure on line 40 in .github/workflows/dockerfile-ci.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/dockerfile-ci.yml

Invalid workflow file

You have an error in your yaml syntax on line 40
- name: "Run docker frontend build"
run:
docker build --build-arg APP=frontend --build-arg START_COMMAND=start -t celluloid-frontend:latest .
- name: "Start docker server"
run:
docker run -p 3000:3000 -e PORT=3000 celluloid-frontend:latest
- name: "Test docker"
run: node .github/workflows/test-docker.js
- name: "Tear down docker"
run: docker kill celluloid-frontend