Skip to content

Commit

Permalink
Test JDK 20 image
Browse files Browse the repository at this point in the history
  • Loading branch information
RikoDEV authored Jul 2, 2023
1 parent 8592e54 commit dbf1b02
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ jobs:
- 11
- 17
- 19
- 20-JDK
- 11-EE
- 17-EE
steps:
Expand Down
48 changes: 48 additions & 0 deletions 20-JDK/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# ----------------------------------
# Pterodactyl Core Dockerfile
# Environment: Java
# Minimum Panel Version: 1.7.0
# ----------------------------------
FROM ubuntu:22.04

ARG TARGETPLATFORM
ARG GRAAL_VERSION=20.0.1
ARG JAVA_VERSION=20

MAINTAINER RikoDEV, <kontakt@riko.dev>

ENV DEBIAN_FRONTEND=noninteractive

# Default to UTF-8 file.encoding
ENV LANG='en_US.UTF-8' LANGUAGE='en_US:en' LC_ALL='en_US.UTF-8'

RUN apt-get update -y \
&& apt-get install -y curl ca-certificates openssl git tar sqlite3 fontconfig tzdata locales iproute2 \
&& echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen \
&& locale-gen en_US.UTF-8 \
&& case ${TARGETPLATFORM} in \
"linux/amd64") ARCH=x86 ;; \
"linux/arm64") ARCH=aarch64 ;; \
esac \
&& curl --retry 3 -Lfso /tmp/graalvm.tar.gz https://github.com/graalvm/graalvm-ce-builds/releases/download/jdk-${GRAAL_VERSION}/graalvm-community-jdk-${GRAAL_VERSION}_linux-${ARCH}_bin.tar.gz \
&& mkdir -p /opt/java/graalvm \
&& cd /opt/java/graalvm \
&& tar -xf /tmp/graalvm.tar.gz --strip-components=1 \
&& export PATH="/opt/java/graalvm/bin:$PATH" \
&& rm -rf /var/lib/apt/lists/* \
&& rm -rf /tmp/graalvm.tar.gz

ENV JAVA_HOME=/opt/java/graalvm \
PATH="/opt/java/graalvm/bin:$PATH"

# Step 2 - add pterodactyl stuff
RUN useradd -d /home/container -m container

USER container
ENV USER=container HOME=/home/container

WORKDIR /home/container

COPY ./../entrypoint.sh /entrypoint.sh

CMD ["/bin/bash", "/entrypoint.sh"]

0 comments on commit dbf1b02

Please sign in to comment.