This repository has been archived by the owner on May 6, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 82
/
Copy path.gitlab-ci.yml
58 lines (53 loc) · 1.53 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
cache:
paths:
- .m2/repository/
stages:
- test
- build
- staging
test:
variables:
MAVEN_CLI_OPTS: "-s .m2/settings.xml --batch-mode"
MAVEN_OPTS: "-Dmaven.repo.local=.m2/repository"
image: maven:3.6.0-jdk-8
tags:
- nlp
script:
- mvn dependency:go-offline -q
- mvn install -q -DskipTests=true -Dmaven.repo.local=.m2/repository
artifacts:
paths:
- target
- .m2/repository
build:
image: maven:3.6.0-jdk-8
tags:
- nlp
stage: build
script:
- curl -fL https://getcli.jfrog.io | sh
- ./jfrog rt config ga-artifactory --url=$ARTIFACTORY_URL --user=$ARTIFACTORY_USER --password=$ARTIFACTORY_PASSWORD
- export M2_HOME=/usr/share/maven
- ./jfrog rt mvn "clean install -q -DskipTests=true -Dmaven.repo.local=.m2/repository" configuration.yml --build-name=gitlabci-maven-artifactory --build-number=$CI_JOB_ID
# Collect the environment variables
- ./jfrog rt bce gitlabci-maven-artifactory $CI_JOB_ID
# Pass the build information to Artifactory
- ./jfrog rt bp gitlabci-maven-artifactory $CI_JOB_ID
dependencies:
- test
staging:
image: python:2.7
stage: staging
tags:
- nlp
type: deploy
script:
- apt-get update -qy
- pip install awscli
- aws configure set aws_access_key_id $HUME_S3_ACCESS_KEY
- aws configure set aws_secret_access_key $HUME_S3_SECRET_KEY
- aws s3 cp target/graphaware-nlp-3.5.1.53.17-SNAPSHOT.jar s3://graphaware-hume/plugins/graphaware-nlp-3.5.1.53.17-SNAPSHOT.jar
dependencies:
- test
only:
- develop