2024-06-22 13:32:53 +03:00
|
|
|
FROM epicmorg/astralinux:1.7-main
|
|
|
|
LABEL maintainer="EpicMorg DevTeam, developer@epicm.org"
|
|
|
|
ARG DEBIAN_FRONTEND=noninteractive
|
|
|
|
|
|
|
|
ARG K_JDK_MAJOR_VERSION=22
|
|
|
|
ARG K_JDK_FULL_VERSION=jdk-22.0.1
|
|
|
|
ARG K_JDK_VERSION=22.0.1
|
|
|
|
ARG K_JDK_BUILD_VERSION=8
|
|
|
|
ARG K_JDK_URL=https://github.com/adoptium/temurin${K_JDK_MAJOR_VERSION}-binaries/releases/download/${K_JDK_FULL_VERSION}+${K_JDK_BUILD_VERSION}/OpenJDK${K_JDK_MAJOR_VERSION}U-jdk_x64_linux_hotspot_${K_JDK_VERSION}_${K_JDK_BUILD_VERSION}.tar.gz
|
2024-06-23 20:48:58 +03:00
|
|
|
ARG K_JDK_TEMP=/tmp/OpenJDK${K_JDK_MAJOR_VERSION}U-jdk_x64_linux_hotspot_${K_JDK_VERSION}_${K_JDK_BUILD_VERSION}.tar.gz
|
2024-06-22 13:32:53 +03:00
|
|
|
|
2024-06-23 20:48:58 +03:00
|
|
|
ENV JAVA_HOME=/usr/local/${K_JDK_FULL_VERSION}+${K_JDK_BUILD_VERSION}
|
2024-06-22 13:32:53 +03:00
|
|
|
ENV PATH=$PATH:${JAVA_HOME}/bin
|
|
|
|
|
|
|
|
##################################################################
|
|
|
|
# installing java21
|
|
|
|
##################################################################
|
2024-06-23 01:33:00 +03:00
|
|
|
ADD ${K_JDK_URL} /tmp
|
2024-06-23 20:48:58 +03:00
|
|
|
RUN tar -xvzf ${K_JDK_TEMP} --directory /usr/local && \
|
2024-06-22 13:32:53 +03:00
|
|
|
java -version
|
|
|
|
|
|
|
|
##################################################################
|
|
|
|
# Additional settings
|
|
|
|
##################################################################
|
2024-06-23 20:48:58 +03:00
|
|
|
ENV MAVEN_VERSION=3.9.8
|
2024-06-22 13:32:53 +03:00
|
|
|
ENV MAVEN_LINK=https://dlcdn.apache.org/maven/maven-3/${MAVEN_VERSION}/binaries/apache-maven-${MAVEN_VERSION}-bin.zip
|
2024-06-23 20:48:58 +03:00
|
|
|
ENV MAVEN_ROOT=/usr/local/maven
|
2024-06-22 13:32:53 +03:00
|
|
|
ENV MAVEN_PATH=${MAVEN_ROOT}/apache-maven-${MAVEN_VERSION}
|
|
|
|
ENV MAVEN_BIN=${MAVEN_PATH}/bin
|
2024-06-23 01:33:00 +03:00
|
|
|
ARG MAVEN_TEMP=/tmp/apache-maven-${MAVEN_VERSION}-bin.zip
|
2024-06-22 13:32:53 +03:00
|
|
|
|
2024-06-23 20:48:58 +03:00
|
|
|
ENV GRADLE_VERSION=8.8
|
2024-06-22 13:32:53 +03:00
|
|
|
ENV GRADLE_LINK=https://services.gradle.org/distributions/gradle-${GRADLE_VERSION}-all.zip
|
2024-06-23 20:48:58 +03:00
|
|
|
ENV GRADLE_ROOT=/usr/local/gradle
|
2024-06-22 13:32:53 +03:00
|
|
|
ENV GRADLE_PATH=${GRADLE_ROOT}/gradle-${GRADLE_VERSION}
|
|
|
|
ENV GRADLE_BIN=${GRADLE_PATH}/bin
|
2024-06-23 01:33:00 +03:00
|
|
|
ARG GRADLE_TEMP=/tmp/gradle-${GRADLE_VERSION}-all.zip
|
2024-06-22 13:32:53 +03:00
|
|
|
|
2024-06-23 20:48:58 +03:00
|
|
|
ENV KTC_VERSION=2.0.0
|
2024-06-22 13:32:53 +03:00
|
|
|
ENV KTC_LINK=https://github.com/JetBrains/kotlin/releases/download/v${KTC_VERSION}/kotlin-compiler-${KTC_VERSION}.zip
|
2024-06-23 01:33:00 +03:00
|
|
|
ARG KTC_TEMP=/tmp/kotlin-compiler-${KTC_VERSION}.zip
|
2024-06-23 20:48:58 +03:00
|
|
|
ENV KTC_ROOT=/usr/local/kotlin
|
2024-06-22 13:32:53 +03:00
|
|
|
ENV KTC_PATH=${KTC_ROOT}/kotlinc
|
|
|
|
ENV KTC_BIN=${KTC_PATH}/bin
|
|
|
|
|
2024-06-23 20:48:58 +03:00
|
|
|
ENV KNPL_VERSION=${KTC_VERSION}
|
|
|
|
ENV KNPL_LINK=https://github.com/JetBrains/kotlin/releases/download/v${KNPL_VERSION}/kotlin-native-prebuilt-linux-x86_64-${KNPL_VERSION}.tar.gz
|
|
|
|
ARG KNPL_TEMP=/tmp/kotlin-native-prebuilt-linux-x86_64-${KNPL_VERSION}.tar.gz
|
|
|
|
ENV KNPL_ROOT=/usr/local/kotlin
|
|
|
|
ENV KNPL_PATH=${KNPL_ROOT}/kotlin-native-prebuilt-linux-x86_64-${KNPL_VERSION}
|
|
|
|
ENV KNPL_BIN=${KNPL_PATH}/bin
|
|
|
|
|
|
|
|
RUN mkdir -p ${MAVEN_PATH} ${KTC_PATH} ${KNPL_PATH} ${GRADLE_PATH}
|
|
|
|
ENV PATH=${PATH}:${MAVEN_BIN}:${GRADLE_BIN}:${KTC_BIN}:${KNPL_BIN}
|
2024-06-22 13:32:53 +03:00
|
|
|
|
|
|
|
##################################################################
|
|
|
|
# Maven
|
|
|
|
##################################################################
|
|
|
|
ENV MAVEN_HOME=${MAVEN_ROOT}
|
|
|
|
ENV M2_HOME=${MAVEN_ROOT}
|
|
|
|
|
2024-06-23 01:33:00 +03:00
|
|
|
ADD ${MAVEN_LINK} /tmp
|
2024-06-23 20:48:58 +03:00
|
|
|
RUN 7zz x ${MAVEN_TEMP} -o${MAVEN_ROOT}
|
2024-06-22 13:32:53 +03:00
|
|
|
RUN chmod +x -R ${MAVEN_BIN}
|
|
|
|
RUN mvn -v
|
|
|
|
|
|
|
|
##################################################################
|
|
|
|
# GRADLE
|
|
|
|
##################################################################
|
2024-06-23 01:33:00 +03:00
|
|
|
ADD ${GRADLE_LINK} /tmp
|
2024-06-23 20:48:58 +03:00
|
|
|
RUN 7zz x ${GRADLE_TEMP} -o${GRADLE_ROOT}
|
2024-06-22 13:32:53 +03:00
|
|
|
RUN chmod +x -R ${GRADLE_BIN}
|
|
|
|
RUN gradle -v
|
|
|
|
|
|
|
|
##################################################################
|
2024-06-23 20:48:58 +03:00
|
|
|
# kotlin-compiler
|
2024-06-22 13:32:53 +03:00
|
|
|
##################################################################
|
2024-06-23 01:33:00 +03:00
|
|
|
ADD ${KTC_LINK} /tmp
|
2024-06-23 20:48:58 +03:00
|
|
|
RUN 7zz x ${KTC_TEMP} -o${KTC_ROOT}
|
2024-06-22 13:32:53 +03:00
|
|
|
RUN chmod +x -R ${KTC_BIN}
|
|
|
|
RUN kotlin -version
|
|
|
|
|
2024-06-23 20:48:58 +03:00
|
|
|
##################################################################
|
|
|
|
# kotlin-native-prebuilt-linux
|
|
|
|
##################################################################
|
|
|
|
ADD ${KNPL_LINK} /tmp
|
|
|
|
RUN tar -xvzf ${KNPL_TEMP} --directory ${KTC_ROOT}
|
|
|
|
RUN chmod +x -R ${KNPL_BIN}
|
|
|
|
|
2024-06-22 13:32:53 +03:00
|
|
|
##################################################################
|
|
|
|
# cleanup
|
|
|
|
##################################################################
|
|
|
|
RUN echo "clean up" && \
|
|
|
|
apt-get clean -y && \
|
|
|
|
apt-get autoclean -y && \
|
|
|
|
rm -rfv /var/lib/apt/lists/* && \
|
|
|
|
rm -rfv /tmp/* && \
|
|
|
|
rm -rfv /var/cache/apt/archives/*.deb
|
2024-07-28 01:48:50 +03:00
|
|
|
|
|
|
|
RUN updatedb
|