@@ -11,24 +11,34 @@ jobs:
1111 - uses : actions/checkout@v2
1212 - name : 📣 Deprecation notice
1313 run : echo "We will most likely run integration tests only with security so this build will be removed."
14- - name : Set up JDK 15
15- uses : actions/setup-java@v2
16- with :
17- java-version : ' 15'
18- distribution : ' adopt'
1914 - name : Cache Maven packages
2015 uses : actions/cache@v2
2116 with :
2217 path : ~/.m2
2318 key : ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
2419 restore-keys : ${{ runner.os }}-m2
20+ - name : Set up JDK 15 and Maven Central Repository
21+ uses : actions/setup-java@v2
22+ with :
23+ java-version : ' 15'
24+ distribution : ' adopt'
25+ server-id : sonatype-nexus-snapshots
26+ server-username : MAVEN_USERNAME
27+ server-password : MAVEN_CENTRAL_TOKEN
28+ - name : Docker Layer Caching
29+ uses : satackey/action-docker-layer-caching@v0.0.11
30+ # Ignore the failure of a step and avoid terminating the job.
31+ continue-on-error : true
32+ with :
33+ key : fscrawler-docker-cache-{hash}
34+ restore-keys : |
35+ fscrawler-docker-cache-
2536 - name : Build the project
26- run : mvn --batch-mode verify -DskipTests
37+ run : mvn --batch-mode install -DskipTests -Ddocker.skip
2738
2839 deploy :
2940 needs : build
3041 runs-on : ubuntu-latest
31-
3242 steps :
3343 - uses : actions/checkout@v2
3444 - name : Cache Maven packages
@@ -37,19 +47,27 @@ jobs:
3747 path : ~/.m2
3848 key : ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
3949 restore-keys : ${{ runner.os }}-m2
40- - name : Set up JDK 14 and Maven Central Repository
50+ - name : Set up JDK 15 and Maven Central Repository
4151 uses : actions/setup-java@v2
4252 with :
43- java-version : ' 14 '
53+ java-version : ' 15 '
4454 distribution : ' adopt'
4555 server-id : sonatype-nexus-snapshots
4656 server-username : MAVEN_USERNAME
47- server-password : MAVEN_PASSWORD
57+ server-password : MAVEN_CENTRAL_TOKEN
58+ - name : Docker Layer Caching
59+ uses : satackey/action-docker-layer-caching@v0.0.11
60+ # Ignore the failure of a step and avoid terminating the job.
61+ continue-on-error : true
62+ with :
63+ key : fscrawler-docker-cache-{hash}
64+ restore-keys : |
65+ fscrawler-docker-cache-
4866 - name : Deploy with Maven
4967 run : mvn deploy -DskipTests
5068 env :
5169 MAVEN_USERNAME : ${{ secrets.OSSRH_USERNAME }}
52- MAVEN_PASSWORD : ${{ secrets.OSSRH_TOKEN }}
70+ MAVEN_CENTRAL_TOKEN : ${{ secrets.OSSRH_TOKEN }}
5371 DOCKER_USERNAME : ${{ secrets.DOCKER_USERNAME }}
5472 DOCKER_PASSWORD : ${{ secrets.DOCKER_PASSWORD }}
5573
0 commit comments