fix build failures: D consolidation, csharp-openai ApiKeyCredential, go-http/go-openai, haskell imports
This commit is contained in:
parent
323294dd57
commit
c6a09db0eb
9 changed files with 153 additions and 41 deletions
|
|
@ -3,24 +3,22 @@ FROM maven:3.9-eclipse-temurin-17-alpine AS builder
|
|||
|
||||
WORKDIR /app
|
||||
|
||||
# Copy POM and source
|
||||
# Copy POM
|
||||
COPY pom.xml ./
|
||||
COPY uncloseai.java ./
|
||||
|
||||
# Build the application
|
||||
RUN mvn clean compile
|
||||
# Create Maven directory structure and copy source
|
||||
RUN mkdir -p src/main/java
|
||||
COPY uncloseai.java ./src/main/java/
|
||||
|
||||
# Build the application (package to create jar with dependencies)
|
||||
RUN mvn clean package
|
||||
|
||||
# Run stage
|
||||
FROM eclipse-temurin:17-jre-alpine
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Copy compiled classes and dependencies from builder
|
||||
COPY --from=builder /app/target/classes ./classes
|
||||
COPY --from=builder /root/.m2/repository /root/.m2/repository
|
||||
COPY --from=builder /app/pom.xml ./
|
||||
# Copy jar with dependencies from builder
|
||||
COPY --from=builder /app/target/*.jar ./uncloseai.jar
|
||||
|
||||
# Install maven to have classpath available
|
||||
RUN apk add --no-cache maven
|
||||
|
||||
CMD ["mvn", "-q", "exec:java"]
|
||||
CMD ["java", "-jar", "uncloseai.jar"]
|
||||
|
|
|
|||
|
|
@ -34,6 +34,23 @@
|
|||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>3.11.0</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-dependency-plugin</artifactId>
|
||||
<version>3.6.0</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>copy-dependencies</id>
|
||||
<phase>package</phase>
|
||||
<goals>
|
||||
<goal>copy-dependencies</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<outputDirectory>${project.build.directory}/lib</outputDirectory>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.codehaus.mojo</groupId>
|
||||
<artifactId>exec-maven-plugin</artifactId>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue