ocr-service/.gitlab-ci.yml
2024-01-15 15:02:37 +01:00

43 lines
1.1 KiB
YAML

include:
- project: 'gitlab/gitlab'
ref: 'gradle-cache'
file: 'ci-templates/gradle_java.yml'
deploy:
stage: deploy
tags:
- dind
variables:
TEST_BUILDVERSION: testing-build-cache-${CI_PIPELINE_ID}
script:
- docker stats
- cat .tmp/hello-world.txt || true
- mkdir -p .tmp
- ls -al /tmp
- echo `pwd`
- mv .gradleBuildCache/ /tmp/.gradleBuildCache/ || true
- echo "Building with gradle version ${TEST_BUILDVERSION}"
- gradle -Pversion=${TEST_BUILDVERSION} publish
- gradle bootBuildImage --publishImage -PbuildbootDockerHostNetwork=true -Pversion=${TEST_BUILDVERSION}
after_script:
- mkdir -p .gradleBuildCache
- ls -al .tmp/
- ls -al /tmp
- ls -al
- ls -al `pwd`/.gradle
- du -sh `pwd`/.gradle/* | sort -h
- du -sh `pwd`/.tmp/.gradle/* | sort -h
- mv /tmp/.gradleBuildCache/ .gradleBuildCache/ || true
- echo "hello-world" > .tmp/hello-world.txt
- docker image ls
- docker volume ls
artifacts:
reports:
dotenv: version.env
cache:
key: gradle-build-cache
paths:
- .gradleBuildCache/
- .gradle/
- .tmp/