forked from geotools/geotools
-
Notifications
You must be signed in to change notification settings - Fork 0
78 lines (73 loc) · 3.81 KB
/
integration.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
name: Downstream integration build (GeoWebCache and GeoServer)
on:
# trigger on PR, but only on main branch, the checkouts of the downstream projects are also targeting main (default branch)
pull_request:
branches:
- main
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Set up JDK 11
uses: actions/setup-java@v2
with:
java-version: 11
distribution: 'temurin'
- uses: actions/checkout@v2
- name: Maven repository caching
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: gt-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
gt-maven-
- name: Disable checksum offloading
# See: https://github.com/actions/virtual-environments/issues/1187#issuecomment-686735760
run: |
sudo ethtool -K eth0 tx off rx off
- name: Build GeoTools (no tests, prepare fresh artifacts)
run: |
mvn -B -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn clean install -T2 -Dall --file pom.xml -DskipTests
- name: Checkout GeoWebCache, GeoServer and ...
run: |
cd ~
echo "Preparing git ssh checkouts"
mkdir ~/.ssh/ && echo -e "Host github.com\n\tStrictHostKeyChecking no\n" > ~/.ssh/config
echo "Checking out GeoWebCache"
mkdir geowebcache
git clone https://github.com/GeoWebCache/geowebcache.git geowebcache
echo "Checking out GeoServer"
mkdir geoserver
git clone https://github.com/geoserver/geoserver.git geoserver
echo "Checking out mapfish-print-v2"
mkdir mapfish-print-v2
git clone https://github.com/mapfish/mapfish-print-v2.git mapfish-print-v2
- name: Build Mapfish-print v2 with tests
run: |
cd ~
mvn -B -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn -f mapfish-print-v2/pom.xml install -nsu -DskipTests -T2
mvn -B -f mapfish-print-v2/pom.xml test -fae -nsu -T2
- name: Build GeoWebCache with tests
run: |
export TEST_OPTS="-XX:+UseStringDeduplication -XX:+UseG1GC -XX:MaxHeapFreeRatio=30 -XX:MinHeapFreeRatio=10"
export MAVEN_OPTS="-Xmx1024m $TEST_OPTS"
cd ~
mvn -B -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn -f geowebcache/geowebcache/pom.xml install -nsu -Dspotless.apply.skip=true -DskipTests -T2
mvn -B -f geowebcache/geowebcache/pom.xml test -fae -nsu -T2 -Dspotless.apply.skip=true
- name: Build GeoServer with tests
run: |
echo "Building GeoServer"
export TEST_OPTS="-XX:+UseStringDeduplication -XX:+UseG1GC -XX:MaxHeapFreeRatio=30 -XX:MinHeapFreeRatio=10"
export MAVEN_OPTS="-Xmx512m $TEST_OPTS"
cd ~
sed -i "s/<mf.version>2.2.0<\/mf.version>/<mf.version>2.3-SNAPSHOT<\/mf.version>/g" geoserver/src/pom.xml
sed -i "s/<gf.version>3.6.0<\/gf.version>/<gf.version>3.6-SNAPSHOT<\/gf.version>/g" geoserver/src/pom.xml
mvn -B -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn -f geoserver/src/pom.xml install -nsu -Prelease -Dspotless.apply.skip=true -DskipTests -T2
mvn -B -f geoserver/src/community/pom.xml install -nsu -DcommunityRelease -Dspotless.apply.skip=true -DskipTests -T2
mvn -B -f geoserver/src/pom.xml test -fae -T2 -nsu -Dtest.maxHeapSize=512m -Djvm.opts="$TEST_OPTS" -Prelease -Dspotless.apply.skip=true
- name: Remove SNAPSHOT jars from repository
run: |
find ~/.m2/repository -name "*SNAPSHOT*" -type d | xargs rm -rf {}