Skip to content
Snippets Groups Projects

[PM] initial commit platform-maintainer

Merged Tino Harnisch requested to merge (removed):master into master
3 files
+ 109
4
Compare changes
  • Side-by-side
  • Inline
Files
3
.gitlab-ci.yml 0 → 100644
+ 103
0
variables:
FF_USE_FASTZIP: "true" # enable fastzip - a faster zip implementation that also supports level configuration.
ARTIFACT_COMPRESSION_LEVEL: default
CACHE_COMPRESSION_LEVEL: default
TRANSFER_METER_FREQUENCY: 5s # will display transfer progress every 5 seconds for artifacts and remote caches.
SONAR_USER_HOME: ${CI_PROJECT_DIR}/.sonar # Defines the location of the analysis task cache
GIT_DEPTH: 0 # Tells git to fetch all the branches of the project, required by the analysis task
CLI_VERSION: latest
image: node:14
#image: node:14:alpine3.13
cache:
key: $CI_COMMIT_REF_SLUG-$CI_PROJECT_DIR
paths:
- node_modules/
#-----------------------------------------------------------------------------------------------------------------------
stages:
- install_dependencies
- build
- test
- sonarqube
- dockerimage-ext-job
#-----------------------------------------------------------------------------------------------------------------------
install_dependencies:
#-----------------------------------------------------------------------------------------------------------------------
stage: install_dependencies
cache:
key: $CI_COMMIT_REF_SLUG-$CI_PROJECT_DIR
paths:
- node_modules/
script:
- npm ci
only:
changes:
- package-lock.json
#-----------------------------------------------------------------------------------------------------------------------
build:
#-----------------------------------------------------------------------------------------------------------------------
stage: build
dependencies:
- install_dependencies
cache:
key: $CI_COMMIT_REF_SLUG-$CI_PROJECT_DIR
paths:
- node_modules/
policy: pull
script:
- npm run build
artifacts:
paths:
- dist/
before_script:
- echo "Pipeline ID = $CI_PIPELINE_ID"
- echo "Project name = $CI_PROJECT_NAME"
- echo "Build ref = $CI_BUILD_REF_NAME"
- echo "CI_COMMIT_REF_SLUG = $CI_COMMIT_REF_SLUG"
- echo "CI_PROJECT_DIR = $CI_PROJECT_DIR"
#-----------------------------------------------------------------------------------------------------------------------
test:karma:
#-----------------------------------------------------------------------------------------------------------------------
stage: test
image: trion/ng-cli-karma:${CLI_VERSION}
allow_failure: false
cache:
key: $CI_COMMIT_REF_SLUG-$CI_PROJECT_DIR
paths:
- node_modules/
policy: pull
script:
- ./node_modules/@angular/cli/bin/ng test --code-coverage --progress false --watch false
coverage: '/Lines \W+: (\d+\.\d+)%.*/'
artifacts:
paths:
- coverage/
#-----------------------------------------------------------------------------------------------------------------------
sonarqube:
#-----------------------------------------------------------------------------------------------------------------------
stage: sonarqube
image:
name: sonarsource/sonar-scanner-cli:4.6
entrypoint: [""]
cache:
key: ${CI_JOB_NAME}
paths:
- .sonar/cache
script:
- echo ${CI_PROJECT_DIR}
- sonar-scanner -Dsonar.qualitygate.wait=true -Dsonar.branch.name="${CI_COMMIT_REF_NAME}"
allow_failure: true
dependencies:
- test:karma
staging-external:
stage: dockerimage-ext-job
trigger: openkonsequenz/qa/portal-build-job
variables:
ARTIFACTS_DOWNLOAD_REF: $CI_COMMIT_BRANCH
Loading