From 6881a44e911030483fa50f0fe98d64101c8fb8fc Mon Sep 17 00:00:00 2001 From: Sonia Zorba <sonia.zorba@inaf.it> Date: Tue, 20 Jul 2021 13:59:37 +0200 Subject: [PATCH] Added CI --- .gitlab-ci.yml | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 .gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..1611f18 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,37 @@ +stages: + - build + - deploy + +build: + stage: build + tags: + - docker + image: maven:3.6.3-openjdk-14 + script: + - mvn clean package -Pbuild-jar + artifacts: + paths: + - target/vospace-parent*.jar + - pom.xml + expire_in: 7 days + only: + - master + +deploy: + stage: deploy + tags: + - docker + script: + - mvn deploy:deploy-file + -Dfile=pom.xml + -DrepositoryId=ia2.snapshots + -DpomFile=pom.xml + -Durl=${IA2_MVN_REPO_SNAPSHOTS} + - file=$(ls target/vospace-parent*.jar) + - mvn deploy:deploy-file + -Dfile=$file + -DrepositoryId=ia2.snapshots + -DpomFile=pom.xml + -Durl=${IA2_MVN_REPO_SNAPSHOTS} + only: + - master -- GitLab