.gitlab-ci.yml 1014 Bytes
Newer Older
Cypres TAC's avatar
Cypres TAC committed
1
image: maven:3.6-jdk-11
Merisier Tac's avatar
Merisier Tac committed
2 3 4

stages:
  - build
5
  - test
Merisier Tac's avatar
Merisier Tac committed
6 7
  - deploy

Merisier Tac's avatar
Merisier Tac committed
8
build:
Merisier Tac's avatar
Merisier Tac committed
9
  stage: build
Merisier Tac's avatar
Merisier Tac committed
10 11
  tags:
    - ci
Merisier Tac's avatar
Merisier Tac committed
12
  script:
Cypres TAC's avatar
Cypres TAC committed
13
    - cd CLEA-lib/java
Merisier Tac's avatar
Merisier Tac committed
14 15
    # build all (for other phase such as docker) but skip tests
    - mvn -DskipTests=true package
Merisier Tac's avatar
Merisier Tac committed
16 17
  artifacts:
    paths:
Cypres TAC's avatar
Cypres TAC committed
18
      - CLEA-lib/java/target/*.jar
Merisier Tac's avatar
Merisier Tac committed
19

20 21
test-java:
  stage: test
Merisier Tac's avatar
Merisier Tac committed
22 23 24
  tags:
    - ci
  script:
Cypres TAC's avatar
Cypres TAC committed
25
    - cd CLEA-lib/java
Merisier Tac's avatar
Merisier Tac committed
26 27 28
    - mvn verify
  artifacts:
    paths:
Cypres TAC's avatar
Cypres TAC committed
29
      - CLEA-lib/java/target/*.jar
Merisier Tac's avatar
Merisier Tac committed
30

31 32 33 34 35 36 37 38 39 40 41 42
test-interop:
  stage: test
  tags:
    - ci
  image: python:3-buster
  before_script: 
    - apt-get update
    - apt-get install -y -qq openjdk-11-jre
  script:
    - cd CLEA-lib/test
    - python test_clea.py

Merisier Tac's avatar
Merisier Tac committed
43
deploy:
Merisier Tac's avatar
Merisier Tac committed
44
  stage: deploy
Merisier Tac's avatar
Merisier Tac committed
45 46
  tags:
    - ci
Merisier Tac's avatar
Merisier Tac committed
47
  script:
Cypres TAC's avatar
Cypres TAC committed
48
    - cd CLEA-lib/java
Cypres TAC's avatar
Cypres TAC committed
49
    - mvn $MAVEN_CLI_OPTS -DskipTests=true  -DnexusReleasesUrl=$CI_SERVER_URL/api/v4/projects/$CI_PROJECT_ID/packages/maven -DnexusSnapshotsUrl=$CI_SERVER_URL/api/v4/projects/$CI_PROJECT_ID/packages/maven -s ../../.gitlab-ci/ci_settings.xml deploy
Merisier Tac's avatar
Merisier Tac committed
50 51
  only:
    - master
Merisier Tac's avatar
Merisier Tac committed
52
    - tags