Add a bunch more java images, syntax changes
This commit is contained in:
21
java14/Dockerfile
Normal file
21
java14/Dockerfile
Normal file
@@ -0,0 +1,21 @@
|
||||
#
|
||||
# Copyright (c) 2020 Matthew Penner
|
||||
#
|
||||
# This repository is licensed under the MIT License.
|
||||
# https://github.com/matthewpi/images/blob/master/LICENSE.md
|
||||
#
|
||||
|
||||
FROM adoptopenjdk/openjdk14-openj9:alpine
|
||||
|
||||
LABEL author="Matthew Penner" maintainer="me@matthewp.io"
|
||||
|
||||
RUN apk add --update --no-cache curl ca-certificates openssl git tar bash sqlite fontconfig tzdata \
|
||||
&& adduser -D -h /home/container container \
|
||||
&& ln -s /etc/localtime /etc/timezone
|
||||
|
||||
USER container
|
||||
ENV USER=container HOME=/home/container
|
||||
WORKDIR /home/container
|
||||
|
||||
COPY ./entrypoint.sh /entrypoint.sh
|
||||
CMD [ "/bin/ash", "/entrypoint.sh" ]
|
23
java14/entrypoint.sh
Normal file
23
java14/entrypoint.sh
Normal file
@@ -0,0 +1,23 @@
|
||||
#!/bin/ash
|
||||
|
||||
#
|
||||
# Copyright (c) 2020 Matthew Penner
|
||||
#
|
||||
# This repository is licensed under the MIT License.
|
||||
# https://github.com/matthewpi/images/blob/master/LICENSE.md
|
||||
#
|
||||
|
||||
cd /home/container
|
||||
|
||||
# Set environment variable that holds the Internal Docker IP
|
||||
export INTERNAL_IP=`ip route get 1 | awk '{print $NF;exit}'`
|
||||
|
||||
# Print Java version
|
||||
java -version
|
||||
|
||||
# Replace start command variables
|
||||
MODIFIED_START=`eval echo $(echo ${STARTUP} | sed -e 's/{{/${/g' -e 's/}}/}/g')`
|
||||
echo "[container@pterodactyl ~]$ ${MODIFIED_START}"
|
||||
|
||||
# Run the modified start command
|
||||
eval ${MODIFIED_START}
|
Reference in New Issue
Block a user