Skip to content
This repository has been archived by the owner on Apr 1, 2024. It is now read-only.

Merge pull request #164 from brave-intl/tarikdem-patch-1 #336

Merge pull request #164 from brave-intl/tarikdem-patch-1

Merge pull request #164 from brave-intl/tarikdem-patch-1 #336

Workflow file for this run

# This is a basic workflow to help you get started with Actions
name: CI
# Controls when the action will run. Triggers the workflow on push or pull request
# events but only for the master branch
on:
push:
branches:
- master
- prod
- dev
pull_request:
branches:
- master
- prod
env:
NODE_ENV: ci
DEBUG: "*,-express*,-babel*,-eslint*,-nodemon*,supertest,bat-ratios"
DEBUG_COLORS: 'true'
CURRENCY_OXR_API_ID: ${{ secrets.CURRENCY_OXR_API_ID }}
DATABASE_URL: postgres://ratios:password@localhost:5010/ratios
EARLIEST_BACKFILL: '2018-12-31'
LATEST_BACKFILL: '2019-01-04'
GRPC_ENABLED: '1'
TOKEN_LIST: e1d49630-234d-4e6c-950f-6ad773f03f86
REDIS_URL: redis://localhost:5011
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
ci:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f
- name: Setup Node.js environment
uses: actions/setup-node@c6fd00ceb9747fb23ffdf72987450a2664414867
with:
# Set always-auth in npmrc
always-auth: true
# Version Spec of the version to use. Examples: 12.x, 10.15.1, >=10.15.0
node-version: >=14.17

Check failure on line 48 in .github/workflows/ci.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/ci.yml

Invalid workflow file

You have an error in your yaml syntax on line 48
# Set this option if you want the action to check for the latest available version that satisfies the version spec
check-latest: true
- run: yarn --version
- name: Docker Compose Install
uses: KengoTODA/actions-setup-docker-compose@92cbaf8ac8c113c35e1cedd1182f217043fbdd00
with:
version: '1.25.4'
- run: docker-compose pull
- name: Cache Docker Images
uses: satackey/action-docker-layer-caching@da67a6cd88114ce3e232893dc6d946efa225aefb
# Ignore the failure of a step and avoid terminating the job.
continue-on-error: true
with:
key: docker-cache-{hash}
restore-keys: |
docker-cache-
- run: yarn
# Runs a single command using the runners shell
- name: Run security checks (audit + lint)
run: yarn run security
- name: Cache node modules
uses: actions/cache@0781355a23dac32fd3bac414512f4b903437991a
with:
path: ~/.yarn
key: v1-yarn-deps-${{ hashFiles('**/yarn.lock') }}
restore-keys: v1-yarn-deps-
# Runs a set of commands using the runners shell
- name: Stand up Postgres
run: |
yarn run docker-up-dbs
sleep 3
- name: Migrate DBs
run: yarn run docker-migrate-dbs
- name: Fill DBs
run: yarn run history
- name: Print Checks
run: |
sleep 5
docker ps
docker-compose logs
- name: Test
run: yarn run test
- name: Check Migrating Down
run: yarn run migrate-down
# - name: Coverage
# run: yarn run coverage
# - name: Submit Code Coverage
# run: npx codecov --file=./coverage/lcov.info