Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
FFDS-register-front
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
EOSC-Pillar
FFDS
FFDS-register-front
Commits
38161208
Commit
38161208
authored
4 years ago
by
Marco Lorini
Browse files
Options
Downloads
Patches
Plain Diff
2021-03-26 ML: CI/CD - add .gitlab-ci file to run pipeline
parent
da88de3c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
.gitlab-ci.yml
+88
-0
88 additions, 0 deletions
.gitlab-ci.yml
with
88 additions
and
0 deletions
.gitlab-ci.yml
0 → 100644
+
88
−
0
View file @
38161208
stages
:
-
build
-
test
-
package
-
deploy
build
:
stage
:
build
image
:
node:12.7-alpine
only
:
-
master
before_script
:
-
npm install -g @angular/cli@8.3.26
-
npm ci
script
:
-
ng build
artifacts
:
paths
:
-
dist/
expire_in
:
1 hours
cache
:
paths
:
-
node_modules/
tags
:
-
kubernetes
-
register-front
# unit_test:
# stage: test
# image: node:latest
# only:
# - master
# before_script:
# - apt-get update
# - wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
# - apt-get install -y ./google-chrome-stable_current_amd64.deb
# - export CHROME_BIN=/usr/bin/google-chrome
# - npm install -g @angular/cli@8.3.26
# - npm ci
# script:
# - ng test
# tags:
# - kubernetes
# - register-front
# e2e_test:
# stage: test
# image: trion/ng-cli-e2e
# only:
# - master
# allow_failure: false
# before_script:
# - npm ci
# script:
# - ng e2e
# tags:
# - kubernetes
# - register-front
package
:
stage
:
package
image
:
docker:latest
only
:
-
master
services
:
-
docker:dind
before_script
:
-
docker info
-
docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_TOKEN $CI_REGISTRY
script
:
-
docker build -t $CI_REGISTRY/$CI_REGISTRY_IMAGE:$CI_REGISTRY_IMAGE_TAG .
-
docker push $CI_REGISTRY/$CI_REGISTRY_IMAGE:$CI_REGISTRY_IMAGE_TAG
tags
:
-
kubernetes
-
register-front
deploy
:
stage
:
deploy
image
:
bitnami/kubectl:latest
only
:
-
master
before_script
:
-
echo -n $KUBE_CONFIG | base64 -d > .kube/config
script
:
-
kubectl --kubeconfig .kube/config --namespace $KUBE_NAMESPACE set image deployment/$KUBE_DEPLOYMENT $KUBE_CONTAINER=$CI_REGISTRY/$CI_REGISTRY_IMAGE:$CI_REGISTRY_IMAGE_TAG
tags
:
-
kubernetes
-
register-front
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment