stages: - test - build - staging - prod build: stage: build image: node:14.5.0 variables: NODE_OPTIONS: "--max_old_space_size=2048" script: - cd ./src - make build artifacts: paths: - ./src/dist/dynamicbible test: stage: test image: walljm/node-chrome-headless:14.8.0 variables: NODE_OPTIONS: "--max_old_space_size=2048" script: - cd ./src - make test deploy-staging: stage: staging image: google/cloud-sdk script: - cd ./src - make deploy-staging rules: - if: '$CI_COMMIT_BRANCH == "main"' when: on_success allow_failure: false deploy-prod: stage: prod image: google/cloud-sdk script: - cd ./src - make deploy-prod rules: - if: '$CI_COMMIT_BRANCH == "main"' when: manual allow_failure: false