FROM eclipse-temurin:21-jdk-alpine AS build WORKDIR /workspace/app COPY . /workspace/app RUN ./gradlew clean build RUN mkdir -p build/dependency && (cd build/dependency; jar -xf ../libs/*.jar) FROM eclipse-temurin:21-jdk-alpine ARG DEPENDENCY=/workspace/app/build/dependency COPY --from=build ${DEPENDENCY}/BOOT-INF/lib /app/lib COPY --from=build ${DEPENDENCY}/META-INF /app/META-INF COPY --from=build ${DEPENDENCY}/BOOT-INF/classes /app ENTRYPOINT ["java","-cp","app:app/lib/*","net.Broken.MainBot"] LABEL org.opencontainers.image.source=https://git.sebclem.fr/sebclem/ClaptrapBot