diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000000000000000000000000000000000000..f1d9c0fd08cba018cdb4e275ce51ab0b5254cdd0 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,57 @@ +image: docker.gitlab.gwdg.de/fontane-notizbuecher/build:latest + +stages: + - build + - test + - deploy + +build-develop: + except: + - master + - tags + stage: build + script: + - ant + artifacts: + paths: + - build/*.xar + +build-master: + only: + - master + stage: build + script: + - cp master.build.properties local.build.properties + - ant + artifacts: + paths: + - build/*.xar + +installation: + except: + - tags + stage: test + script: + - ant test + - bash test/eXist-db-*/bin/startup.sh | tee output.log & + # wait for eXist + - while [ $(curl --head --silent http://localhost:8080 | grep -c "200 OK") == 0 ]; do sleep 2s; done + # shutdown eXist + - bash test/eXist-db-*/bin/shutdown.sh + artifacts: + paths: + - output.log + - test/eXist-db-*/webapp/WEB-INF/logs/expath-repo.log + reports: + junit: tests-*.xml + +upload: + only: + - master + - develop + except: + - tags + stage: deploy + script: + - FILENAME=$(ls build/*.xar) + - curl -u ci:${EXIST_UPLOAD_PW} -X POST -F file=@${FILENAME} https://ci.de.dariah.eu/exist-upload