image: ${CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX}/node:12.16.3 before_script: - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY variables: MONGODB_VERSION: '4.2.6' MONGODB_URL: 'mongodb://mongodb:27017/test' PORT: '3002' JWT_SECRET: 'test' # http://docs.gitlab.com/ee/ci/yaml/README.html#cache cache: paths: - node_modules/ test_client: script: - cd app/client - npm install - npm run test test_server: # Info: http://docs.gitlab.com/ee/ci/docker/using_docker_images.html#what-is-a-service services: - name: ${CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX}/mongo:$MONGODB_VERSION alias: mongodb script: - cd app/server - npm install - npm run test