stages:
  - build

build-backend:
  image: jsherz/lsd-members-backend
  stage: build
  script:
    - cd backend
    - sbt clean compile test

build-frontend:
  image: jsherz/lsd-members-frontend
  stage: build
  script:
    - cd frontend
    - npm install
    - npm run lint
    - npm run build-prod
    - npm run test-ci

stages:
  - build

build-backend:
  image: jsherz/lsd-members-backend
  stage: build
  script:
    - |
      cat <<REPOS > ~/.sbt/repositories
      [repositories]
        local
        my-ivy-proxy-releases: http://vms:8081/artifactory/sbt-release/, [organization]/[module]/(scala_[scalaVersion]/)(sbt_[sbtVersion]/)[revision]/[type]s/[artifact](-[classifier]).[ext]
        my-maven-proxy-releases: http://vms:8081/artifactory/sbt-release/
      REPOS
    - cd backend
    - sbt -Dsbt.override.build.repos=true clean compile test

build-frontend:
  image: jsherz/lsd-members-frontend
  stage: build
  script:
    - cd frontend
    - npm install
    - npm run lint
    - npm run build-prod
    - npm run test-ci

Make CI use local package repos.
Make CI use local package repos.
