Refactor ci pipeline.
This commit is contained in:
parent
99a0c39eb7
commit
5e74238df2
113
.gitlab-ci.yml
113
.gitlab-ci.yml
@ -34,17 +34,20 @@ install_dependencies:
|
|||||||
|
|
||||||
build:
|
build:
|
||||||
stage: build
|
stage: build
|
||||||
image: trion/ng-cli
|
image: node:15-alpine3.10
|
||||||
tags:
|
tags:
|
||||||
- docker
|
- docker
|
||||||
before_script:
|
|
||||||
- npm ci
|
|
||||||
script:
|
script:
|
||||||
- ng build --prod
|
- npm ng build --prod
|
||||||
|
after_script:
|
||||||
|
- mv $PROJECT_PATH/nginx.conf $PROJECT_PATH/default.conf
|
||||||
|
- cp $PROJECT_PATH/default.conf $APP_OUTPUT_PATH
|
||||||
|
- cp $PROJECT_PATH/Dockerfile $APP_OUTPUT_PATH
|
||||||
artifacts:
|
artifacts:
|
||||||
|
name: "cic-staff-client-pipeline"
|
||||||
expire_in: 1 days
|
expire_in: 1 days
|
||||||
paths:
|
paths:
|
||||||
- dist/cic-staff-client
|
- $APP_OUTPUT_PATH
|
||||||
cache:
|
cache:
|
||||||
key:
|
key:
|
||||||
files:
|
files:
|
||||||
@ -53,56 +56,56 @@ build:
|
|||||||
- node_modules
|
- node_modules
|
||||||
policy: pull
|
policy: pull
|
||||||
|
|
||||||
#test:karma:
|
test:karma:
|
||||||
# stage: test
|
stage: test
|
||||||
# image: trion/ng-cli-karma
|
image: node:15-alpine3.10
|
||||||
# allow_failure: false
|
allow_failure: false
|
||||||
# tags:
|
tags:
|
||||||
# - docker
|
- docker
|
||||||
# script:
|
script:
|
||||||
# - ng test --code-coverage --progress false --watch false
|
- npm ng test --code-coverage --progress false --watch false
|
||||||
# coverage: '/Lines \W+: (\d+\.\d+)%.*/'
|
coverage: '/Lines \W+: (\d+\.\d+)%.*/'
|
||||||
# artifacts:
|
artifacts:
|
||||||
# paths:
|
paths:
|
||||||
# - coverage/
|
- coverage/
|
||||||
# cache:
|
cache:
|
||||||
# key:
|
key:
|
||||||
# files:
|
files:
|
||||||
# - package-lock.json
|
- package-lock.json
|
||||||
# paths:
|
paths:
|
||||||
# - node_modules
|
- node_modules
|
||||||
# policy: pull
|
policy: pull
|
||||||
#
|
|
||||||
#test:e2e:
|
test:e2e:
|
||||||
# stage: test
|
stage: test
|
||||||
# image: trion/ng-cli-e2e
|
image: node:15-alpine3.10
|
||||||
# allow_failure: false
|
allow_failure: false
|
||||||
# tags:
|
tags:
|
||||||
# - docker
|
- docker
|
||||||
# script:
|
script:
|
||||||
# - ng e2e
|
- npm ng e2e
|
||||||
# cache:
|
cache:
|
||||||
# key:
|
key:
|
||||||
# files:
|
files:
|
||||||
# - package-lock.json
|
- package-lock.json
|
||||||
# paths:
|
paths:
|
||||||
# - node_modules
|
- node_modules
|
||||||
# policy: pull
|
policy: pull
|
||||||
#
|
|
||||||
#test:nglint:
|
test:nglint:
|
||||||
# stage: test
|
stage: test
|
||||||
# image: trion/ng-cli
|
image: node:15-alpine3.10
|
||||||
# tags:
|
tags:
|
||||||
# - docker
|
- docker
|
||||||
# script:
|
script:
|
||||||
# - ng lint
|
- npm ng lint
|
||||||
# cache:
|
cache:
|
||||||
# key:
|
key:
|
||||||
# files:
|
files:
|
||||||
# - package-lock.json
|
- package-lock.json
|
||||||
# paths:
|
paths:
|
||||||
# - node_modules
|
- node_modules
|
||||||
# policy: pull
|
policy: pull
|
||||||
|
|
||||||
build_app:
|
build_app:
|
||||||
stage: build_and_test
|
stage: build_and_test
|
||||||
|
Loading…
Reference in New Issue
Block a user