.gitlab-ci.yml
image: node:lts
variables:
TEST_DISABLED: 'true'
SAST_EXCLUDED_PATHS: 'node_modules'
# CHROME_BIN: '/app/.apt/opt/google/chrome/chrome'
# CHROME_BIN: 'google-chrome'
CI: 'true'
# CV_GENERATOR_APPVEYOR_TOKEN: ''
CV_GENERATOR_AUDITING: 'false'
# CV_GENERATOR_DOCKER_TOKEN: ''
# CV_GENERATOR_DOCKER_USERNAME: ''
# CV_GENERATOR_GITHUB_TOKEN: ''
CV_GENERATOR_FE_SKIP_REDIRECT_TO_HTTPS: 'false'
GITLAB: 'true'
hosts: "['localhost', '192.168.1.2', '192.168.1.6', '192.168.99.100']"
# NODEMODULESCACHE: 'false'
# NPM_TOKEN: ''
production: 'true'
serverEndpointUri: 'https://cv-generator-project-server-eu.herokuapp.com'
DAST_WEBSITE: 'https://cv-generator-project-server-eu.herokuapp.com'
TERM: 'cygwin'
CV_GENERATOR_FE_DEBUG: 'false'
CV_GENERATOR_FE_APP_NAME: 'CV Generator'
CV_GENERATOR_FE_APP_PACKAGE_NAME: 'cv-generator-fe'
CV_GENERATOR_FE_USE_SPDY: 'false'
# before_script:
# - npm install
cache:
paths:
- node_modules/
# stages:
# - build
# include:
# - template: Jobs/Build.gitlab-ci.yml
stages:
- build
- test
# - run_pipeline
- deploy # dummy stage to follow the template guidelines
- review
- dast
- staging
- canary
- production
- incremental rollout 10%
- incremental rollout 25%
- incremental rollout 50%
- incremental rollout 100%
- performance
- cleanup
default:
timeout: 60m
run_pipeline:
# stage: run_pipeline
stage: test
tags:
# - gitlab
- linux
# name: Run pipeline
# caches:
# - node
timeout: 60m
script:
- if [ "$(date +%u)" -eq 6 ]; then echo Proceeding to pipeline on a Saturday...; else echo Skipping pipeline on a non-Saturday savings day. && exit; fi
- echo "Starting pipeline..."
# # Install Chrome
# - wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add -
# - sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list'
# - apt-get update
# - apt-get install google-chrome-stable
# #
# # Report Chrome
# # - echo 'CHROME_BIN was at:' $CHROME_BIN
# # - export CHROME_BIN=google-chrome
# # - export CHROME_BIN=$( which google-chrome )
# - echo 'CHROME_BIN now at:' $CHROME_BIN
#
- node --version
- npm --version
#
- npm install
#
- npm run build
- echo "Pipeline finished."
- echo "Everything is awesome!"
# artifacts:
# paths:
# - coverage/*
# coverage: '/(\d*.?\d+)%/'
include:
# - template: Android-Fastlane.gitlab-ci.yml
- template: Auto-DevOps.gitlab-ci.yml
### Auto DevOps config file
# gitlab
# lib
# gitlab
# ci
# templates
# Auto-DevOps.gitlab-ci.yml
#
### https://gitlab.com/gitlab-org/gitlab/blob/master/lib/gitlab/ci/templates/Auto-DevOps.gitlab-ci.yml
#
# # Auto DevOps
# # This CI/CD configuration provides a standard pipeline for
# # * building a Docker image (using a buildpack if necessary),
# # * storing the image in the container registry,
# # * running tests from a buildpack,
# # * running code quality analysis,
# # * creating a review app for each topic branch,
# # * and continuous deployment to production
# #
# # Test jobs may be disabled by setting environment variables:
# # * test: TEST_DISABLED
# # * code_quality: CODE_QUALITY_DISABLED
# # * license_management: LICENSE_MANAGEMENT_DISABLED
# # * performance: PERFORMANCE_DISABLED
# # * load_performance: LOAD_PERFORMANCE_DISABLED
# # * sast: SAST_DISABLED
# # * secret_detection: SECRET_DETECTION_DISABLED
# # * dependency_scanning: DEPENDENCY_SCANNING_DISABLED
# # * container_scanning: CONTAINER_SCANNING_DISABLED
# # * dast: DAST_DISABLED
# # * review: REVIEW_DISABLED
# # * stop_review: REVIEW_DISABLED
# #
# # In order to deploy, you must have a Kubernetes cluster configured either
# # via a project integration, or via group/project variables.
# # KUBE_INGRESS_BASE_DOMAIN must also be set on the cluster settings,
# # as a variable at the group or project level, or manually added below.
# #
# # Continuous deployment to production is enabled by default.
# # If you want to deploy to staging first, set STAGING_ENABLED environment variable.
# # If you want to enable incremental rollout, either manual or time based,
# # set INCREMENTAL_ROLLOUT_MODE environment variable to "manual" or "timed".
# # If you want to use canary deployments, set CANARY_ENABLED environment variable.
# #
# # If Auto DevOps fails to detect the proper buildpack, or if you want to
# # specify a custom buildpack, set a project variable `BUILDPACK_URL` to the
# # repository URL of the buildpack.
# # e.g. BUILDPACK_URL=https://github.com/heroku/heroku-buildpack-ruby.git#v142
# # If you need multiple buildpacks, add a file to your project called
# # `.buildpacks` that contains the URLs, one on each line, in order.
# # Note: Auto CI does not work with multiple buildpacks yet
# image: alpine:latest
# variables:
# # KUBE_INGRESS_BASE_DOMAIN is the application deployment domain and should be set as a variable at the group or project level.
# # KUBE_INGRESS_BASE_DOMAIN: domain.example.com
# POSTGRES_USER: user
# POSTGRES_PASSWORD: testing-password
# POSTGRES_ENABLED: "true"
# POSTGRES_DB: $CI_ENVIRONMENT_SLUG
# DOCKER_DRIVER: overlay2
# ROLLOUT_RESOURCE_TYPE: deployment
# DOCKER_TLS_CERTDIR: "" # https://gitlab.com/gitlab-org/gitlab-runner/issues/4501
# stages:
# - build
# - test
# - deploy # dummy stage to follow the template guidelines
# - review
# - dast
# - staging
# - canary
# - production
# - incremental rollout 10%
# - incremental rollout 25%
# - incremental rollout 50%
# - incremental rollout 100%
# - performance
# - cleanup
# workflow:
# rules:
# - if: '$BUILDPACK_URL || $AUTO_DEVOPS_EXPLICITLY_ENABLED == "1" || $DOCKERFILE_PATH'
# - exists:
# - Dockerfile
# # https://github.com/heroku/heroku-buildpack-clojure
# - exists:
# - project.clj
# # https://github.com/heroku/heroku-buildpack-go
# - exists:
# - go.mod
# - Gopkg.mod
# - Godeps/Godeps.json
# - vendor/vendor.json
# - glide.yaml
# - src/**/*.go
# # https://github.com/heroku/heroku-buildpack-gradle
# - exists:
# - gradlew
# - build.gradle
# - settings.gradle
# # https://github.com/heroku/heroku-buildpack-java
# - exists:
# - pom.xml
# - pom.atom
# - pom.clj
# - pom.groovy
# - pom.rb
# - pom.scala
# - pom.yaml
# - pom.yml
# # https://github.com/heroku/heroku-buildpack-multi
# - exists:
# - .buildpacks
# # https://github.com/heroku/heroku-buildpack-nodejs
# - exists:
# - package.json
# # https://github.com/heroku/heroku-buildpack-php
# - exists:
# - composer.json
# - index.php
# # https://github.com/heroku/heroku-buildpack-play
# # TODO: detect script excludes some scala files
# - exists:
# - '**/conf/application.conf'
# # https://github.com/heroku/heroku-buildpack-python
# # TODO: detect script checks that all of these exist, not any
# - exists:
# - requirements.txt
# - setup.py
# - Pipfile
# # https://github.com/heroku/heroku-buildpack-ruby
# - exists:
# - Gemfile
# # https://github.com/heroku/heroku-buildpack-scala
# - exists:
# - '*.sbt'
# - project/*.scala
# - .sbt/*.scala
# - project/build.properties
# # https://github.com/dokku/buildpack-nginx
# - exists:
# - .static
# include:
# - template: Jobs/Build.gitlab-ci.yml # https://gitlab.com/gitlab-org/gitlab-foss/blob/master/lib/gitlab/ci/templates/Jobs/Build.gitlab-ci.yml
# - template: Jobs/Test.gitlab-ci.yml # https://gitlab.com/gitlab-org/gitlab-foss/blob/master/lib/gitlab/ci/templates/Jobs/Test.gitlab-ci.yml
# - template: Jobs/Code-Quality.gitlab-ci.yml # https://gitlab.com/gitlab-org/gitlab-foss/blob/master/lib/gitlab/ci/templates/Jobs/Code-Quality.gitlab-ci.yml
# - template: Jobs/Deploy.gitlab-ci.yml # https://gitlab.com/gitlab-org/gitlab-foss/blob/master/lib/gitlab/ci/templates/Jobs/Deploy.gitlab-ci.yml
# - template: Jobs/DAST-Default-Branch-Deploy.gitlab-ci.yml # https://gitlab.com/gitlab-org/gitlab-foss/blob/master/lib/gitlab/ci/templates/Jobs/DAST-Default-Branch-Deploy.gitlab-ci.yml
# - template: Jobs/Browser-Performance-Testing.gitlab-ci.yml # https://gitlab.com/gitlab-org/gitlab-foss/blob/master/lib/gitlab/ci/templates/Jobs/Browser-Performance-Testing.gitlab-ci.yml
# - template: Security/DAST.gitlab-ci.yml # https://gitlab.com/gitlab-org/gitlab-foss/blob/master/lib/gitlab/ci/templates/Security/DAST.gitlab-ci.yml
# - template: Security/Container-Scanning.gitlab-ci.yml # https://gitlab.com/gitlab-org/gitlab-foss/blob/master/lib/gitlab/ci/templates/Security/Container-Scanning.gitlab-ci.yml
# - template: Security/Dependency-Scanning.gitlab-ci.yml # https://gitlab.com/gitlab-org/gitlab-foss/blob/master/lib/gitlab/ci/templates/Security/Dependency-Scanning.gitlab-ci.yml
# - template: Security/License-Scanning.gitlab-ci.yml # https://gitlab.com/gitlab-org/gitlab-foss/blob/master/lib/gitlab/ci/templates/Security/License-Scanning.gitlab-ci.yml
# - template: Security/SAST.gitlab-ci.yml # https://gitlab.com/gitlab-org/gitlab-foss/blob/master/lib/gitlab/ci/templates/Security/SAST.gitlab-ci.yml
# - template: Security/Secret-Detection.gitlab-ci.yml # https://gitlab.com/gitlab-org/gitlab-foss/blob/master/lib/gitlab/ci/templates/Security/Secret-Detection.gitlab-ci.yml
### GitLab.org > GitLabGitLab > Repository master config file
# gitlab
# .gitlab-ci.yml
#
### https://gitlab.com/gitlab-org/gitlab/blob/master/.gitlab-ci.yml
#
# stages:
# - sync
# - prepare
# - build-images
# - fixtures
# - test
# - post-test
# - review-prepare
# - review
# - dast
# - qa
# - post-qa
# - pages
# - notify
# # always use `gitlab-org` runners, however
# # in cases where jobs require Docker-in-Docker, the job
# # definition must be extended with `.use-docker-in-docker`
# default:
# image: "registry.gitlab.com/gitlab-org/gitlab-build-images:ruby-2.6.6-golang-1.14-git-2.28-lfs-2.9-chrome-84-node-12.x-yarn-1.21-postgresql-11-graphicsmagick-1.3.34"
# tags:
# - gitlab-org
# # All jobs are interruptible by default
# interruptible: true
# # Default job timeout set to 90m https://gitlab.com/gitlab-com/gl-infra/infrastructure/-/issues/10520
# timeout: 90m
# workflow:
# rules:
# # If `$FORCE_GITLAB_CI` is set, create a pipeline.
# - if: '$FORCE_GITLAB_CI'
# # As part of the process of creating RCs automatically, we update stable
# # branches with the changes of the most recent production deployment. The
# # merge requests used for this merge a branch release-tools/X into a stable
# # branch. For these merge requests we don't want to run any pipelines, as
# # they serve no purpose and will run anyway when the changes are merged.
# - if: '$CI_MERGE_REQUEST_SOURCE_BRANCH_NAME =~ /^release-tools\/\d+\.\d+\.\d+-rc\d+$/ && $CI_MERGE_REQUEST_TARGET_BRANCH_NAME =~ /^[\d-]+-stable(-ee)?$/ && $CI_PROJECT_PATH == "gitlab-org/gitlab"'
# when: never
# # For merge requests, create a pipeline.
# - if: '$CI_MERGE_REQUEST_IID'
# # For `master` branch, create a pipeline (this includes on schedules, pushes, merges, etc.).
# - if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH'
# # For tags, create a pipeline.
# - if: '$CI_COMMIT_TAG'
# # If `$GITLAB_INTERNAL` isn't set, don't create a pipeline.
# - if: '$GITLAB_INTERNAL == null'
# when: never
# # For stable, auto-deploy, and security branches, create a pipeline.
# - if: '$CI_COMMIT_BRANCH =~ /^[\d-]+-stable(-ee)?$/'
# - if: '$CI_COMMIT_BRANCH =~ /^\d+-\d+-auto-deploy-\d+$/'
# - if: '$CI_COMMIT_BRANCH =~ /^security\//'
# variables:
# RAILS_ENV: "test"
# NODE_ENV: "test"
# SIMPLECOV: "true"
# GIT_DEPTH: "20"
# GIT_SUBMODULE_STRATEGY: "none"
# GET_SOURCES_ATTEMPTS: "3"
# KNAPSACK_RSPEC_SUITE_REPORT_PATH: knapsack/report-master.json
# FLAKY_RSPEC_SUITE_REPORT_PATH: rspec_flaky/report-suite.json
# BUILD_ASSETS_IMAGE: "false"
# ES_JAVA_OPTS: "-Xms256m -Xmx256m"
# ELASTIC_URL: "http://elastic:changeme@elasticsearch:9200"
# DOCKER_VERSION: "19.03.0"
# # Preparing custom clone path to reduce space used by all random forks
# # on GitLab.com's Shared Runners. Our main forks - especially the security
# # ones - will have this variable overwritten in the project settings, so that
# # a security-related code or code using our protected variables will be never
# # stored on the same path as the community forks.
# # Part of the solution for the `no space left on device` problem described at
# # https://gitlab.com/gitlab-org/gitlab/issues/197876.
# #
# # For this purpose the https://gitlab.com/gitlab-org-forks group was created
# # to host a placeholder for the `/builds/gitlab-org-forks` path and ensure
# # that no legitimate project will ever use it and - by mistake - execute its
# # job on a shared working directory. It also requires proper configuration of
# # the Runner that executes the job (which was prepared for our shared runners
# # by https://ops.gitlab.net/gitlab-cookbooks/chef-repo/-/merge_requests/3977).
# #
# # Because of all of that PLEASE DO NOT CHANGE THE PATH.
# #
# # For more details and reasoning that brought this change please check
# # https://gitlab.com/gitlab-org/gitlab/-/merge_requests/24887
# GIT_CLONE_PATH: "/builds/gitlab-org-forks/${CI_PROJECT_NAME}"
# include:
# - local: .gitlab/ci/build-images.gitlab-ci.yml
# - local: .gitlab/ci/cache-repo.gitlab-ci.yml
# - local: .gitlab/ci/cng.gitlab-ci.yml
# - local: .gitlab/ci/docs.gitlab-ci.yml
# - local: .gitlab/ci/frontend.gitlab-ci.yml
# - local: .gitlab/ci/global.gitlab-ci.yml
# - local: .gitlab/ci/memory.gitlab-ci.yml
# - local: .gitlab/ci/pages.gitlab-ci.yml
# - local: .gitlab/ci/qa.gitlab-ci.yml
# - local: .gitlab/ci/reports.gitlab-ci.yml
# - local: .gitlab/ci/rails.gitlab-ci.yml
# - local: .gitlab/ci/review.gitlab-ci.yml
# - local: .gitlab/ci/rules.gitlab-ci.yml
# - local: .gitlab/ci/setup.gitlab-ci.yml
# - local: .gitlab/ci/dev-fixtures.gitlab-ci.yml
# - local: .gitlab/ci/test-metadata.gitlab-ci.yml
# - local: .gitlab/ci/yaml.gitlab-ci.yml
# - local: .gitlab/ci/releases.gitlab-ci.yml
# - local: .gitlab/ci/notify.gitlab-ci.yml
# - local: .gitlab/ci/dast.gitlab-ci.yml