Skip to content

Always create availability #466

Always create availability

Always create availability #466

Workflow file for this run

name: CI
on: push
jobs:
build:
runs-on: ubuntu-latest
services:
# Label used to access the service container
postgres:
# Docker Hub image
image: postgres
# Provide the password for postgres
env:
POSTGRES_USER: merochat_test
POSTGRES_PASSWORD: merochat_test
# Set health checks to wait until postgres has started
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
# Maps tcp port 5432 on service container to the host
- 5432:5432
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: '16'
cache: 'npm'
- uses: purescript-contrib/setup-purescript@main
- name: Cache PureScript dependencies
uses: actions/cache@v2
# This cache uses the .dhall files to know when it should reinstall
# and rebuild packages. It caches both the installed packages from
# the `.spago` directory and compilation artifacts from the `output`
# directory. When restored the compiler will rebuild any files that
# have changed. If you do not want to cache compiled output, remove
# the `output` path.
with:
key: ${{ runner.os }}-spago-${{ hashFiles('**/*.dhall') }}
path: |
.spago
output
- run: psql -f src/Server/sql/index.sql postgresql://merochat_test:merochat_test@localhost:5432/merochat_test
- run: mkdir -p file/upload
- run: npm install
- run: spago build
- run: spago test