Skip to content

Commit

Permalink
Merge branch 'main' into snyk-upgrade-16cc118741fa7f73322571714388d245
Browse files Browse the repository at this point in the history
  • Loading branch information
paulushcgcj authored Jun 11, 2024
2 parents de039a2 + 7839e39 commit 61a4ec6
Show file tree
Hide file tree
Showing 24 changed files with 1,358 additions and 1,316 deletions.
5 changes: 3 additions & 2 deletions backend/.mvn/wrapper/maven-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,6 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.6/apache-maven-3.9.6-bin.zip
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar
wrapperVersion=3.3.2
distributionType=only-script
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.7/apache-maven-3.9.7-bin.zip
24 changes: 17 additions & 7 deletions backend/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,24 +1,34 @@
### Builder
FROM ghcr.io/graalvm/native-image:ol8-java17-22.3.3 AS build

# Install Maven
RUN microdnf update --nodocs -y && \
microdnf install -y wget tar && \
wget https://archive.apache.org/dist/maven/maven-3/3.8.6/binaries/apache-maven-3.8.6-bin.tar.gz && \
tar xzf apache-maven-3.8.6-bin.tar.gz -C /opt && \
ln -s /opt/apache-maven-3.8.6 /opt/maven && \
ln -s /opt/maven/bin/mvn /usr/bin/mvn && \
rm apache-maven-3.8.6-bin.tar.gz && \
microdnf clean all

# Add Maven to the PATH environment variable
ENV MAVEN_HOME /opt/maven
ENV PATH $MAVEN_HOME/bin:$PATH

# Receiving app version
ARG APP_VERSION=0.0.1

# Copy
WORKDIR /app
COPY pom.xml ./
COPY mvnw ./mvnw
COPY src ./src
COPY .mvn/ ./.mvn

RUN chmod +x mvnw

# Setting app version
RUN ./mvnw versions:set -DnewVersion=${APP_VERSION} -f pom.xml -DskipTests -Dtests.skip=true -Dskip.unit.tests=true && \
./mvnw versions:commit -f pom.xml -DskipTests -Dtests.skip=true -Dskip.unit.tests=true
RUN mvn versions:set -DnewVersion=${APP_VERSION} -f pom.xml -DskipTests -Dtests.skip=true -Dskip.unit.tests=true && \
mvn versions:commit -f pom.xml -DskipTests -Dtests.skip=true -Dskip.unit.tests=true

# Build
RUN ./mvnw -Pnative native:compile
RUN mvn -Pnative native:compile


### Deployer
Expand Down
Loading

0 comments on commit 61a4ec6

Please sign in to comment.