File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change 4
4
FROM ubuntu:jammy as build
5
5
6
6
# hadolint ignore=DL3008
7
- RUN apt-get update && apt-get install --no-install-recommends -y maven python3 python3-venv && \
7
+ RUN apt-get update && apt-get install --no-install-recommends -y openjdk-11-jdk python3 python3-venv && \
8
8
apt-get clean && \
9
9
rm -rf /var/lib/apt/lists/*
10
10
11
11
# Create a first layer to cache the "Maven World" in the local repository.
12
12
# Incremental docker builds will always resume after that, unless you update the pom
13
13
WORKDIR /mvn
14
14
COPY pom.xml /mvn/
15
+ COPY mvnw /mvn/
16
+ COPY .mvn /mvn/.mvn
15
17
COPY opengrok-indexer/pom.xml /mvn/opengrok-indexer/
16
18
COPY opengrok-web/pom.xml /mvn/opengrok-web/
17
19
COPY plugins/pom.xml /mvn/plugins/
@@ -26,18 +28,18 @@ RUN sed -i 's:<module>distribution</module>::g' /mvn/pom.xml && \
26
28
touch /mvn/opengrok-web/src/main/webapp/WEB-INF/web.xml
27
29
28
30
# dummy build to cache the dependencies
29
- RUN mvn -DskipTests -Dcheckstyle.skip -Dmaven.antrun.skip package
31
+ RUN ./mvnw -DskipTests -Dcheckstyle.skip -Dmaven.antrun.skip package
30
32
31
33
# build the project
32
34
COPY ./ /opengrok-source
33
35
WORKDIR /opengrok-source
34
36
35
- RUN mvn -DskipTests=true -Dmaven.javadoc.skip=true -B -V package
37
+ RUN / mvn/mvnw -DskipTests=true -Dmaven.javadoc.skip=true -B -V package
36
38
# hadolint ignore=SC2012,DL4006
37
39
RUN cp `ls -t distribution/target/*.tar.gz | head -1` /opengrok.tar.gz
38
40
39
41
# Store the version in a file so that the tools can report it.
40
- RUN mvn help:evaluate -Dexpression=project.version -q -DforceStdout > /mvn/VERSION
42
+ RUN / mvn/mvnw help:evaluate -Dexpression=project.version -q -DforceStdout > /mvn/VERSION
41
43
42
44
FROM tomcat:10.1-jdk11
43
45
LABEL maintainer="https://github.com/oracle/opengrok"
You can’t perform that action at this time.
0 commit comments