cicd + tool

This commit is contained in:
2026-01-07 16:51:12 +03:00
parent 3be81fc7a5
commit e7af1ffb0b
6 changed files with 195 additions and 0 deletions

29
aitools/Dockerfile Normal file
View File

@@ -0,0 +1,29 @@
# Stage 1: Build the application
FROM maven:3.9.11-eclipse-temurin-25 AS build
WORKDIR /app
# Copy pom.xml and download dependencies
COPY pom.xml .
RUN mvn dependency:go-offline
# Copy source code
COPY src ./src
# Build the application
RUN mvn package -DskipTests
# Stage 2: Create the runtime image
FROM eclipse-temurin:25-jdk
WORKDIR /app
# Copy the built JAR file
COPY --from=build /app/target/*.jar app.jar
# Set environment variables
ENV JAVA_OPTS=""
# Expose the application port
EXPOSE 8080
# Run the application
ENTRYPOINT ["sh", "-c", "java $JAVA_OPTS -jar app.jar"]