File tree Expand file tree Collapse file tree 4 files changed +16
-4
lines changed
Expand file tree Collapse file tree 4 files changed +16
-4
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,18 @@ ENV LEVEL_TYPE=FLAT
1313ENV MOTD=ShowScriptSandbox
1414ENV ALLOW_NETHER=FALSE
1515
16+ # Install OpenJDK 21
17+ RUN apt-get update && \
18+ apt-get install -y openjdk-21-jdk && \
19+ apt-get clean;
20+
21+ # Set JAVA_HOME environment variable
22+ ENV JAVA_HOME=/usr/lib/jvm/java-21-openjdk-amd64
23+ ENV PATH=$JAVA_HOME/bin:$PATH
24+
1625# Expose the Minecraft server port
1726EXPOSE 25565
1827
28+
29+
1930ENTRYPOINT [ "" ]
Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ cd "$(dirname "$0")/../.."
77./gradlew build
88
99# Ensure the plugins directory exists
10- mkdir -p /workspaces/ShowScript/sandbox/server /plugins
10+ mkdir -p /workspaces/ShowScript/sandbox/data /plugins
1111
1212# Move the built plugin jar to the plugins directory
13- mv build/libs/showscript.jar /workspaces/ShowScript/sandbox/server /plugins/
13+ mv build/libs/showscript.jar /workspaces/ShowScript/sandbox/data /plugins/
Original file line number Diff line number Diff line change 11#! /bin/bash
22
33# Navigate to the plugins directory
4- cd /workspaces/ShowScript/sandbox/server /plugins
4+ cd /workspaces/ShowScript/sandbox/data /plugins
55
66# Read each line from the CSV file
77while IFS=, read -r pluginName directDownloadUrl
Original file line number Diff line number Diff line change 11#! /bin/bash
2+ ln -s /data /workspaces/ShowScript/sandbox
23
34# Run script to build ShowScript
45bash /workspaces/ShowScript/sandbox/scripts/build-plugin.sh
@@ -11,6 +12,6 @@ bash /workspaces/ShowScript/sandbox/scripts/download-plugins.sh
1112# Start the Minecraft server
1213cd /workspaces/ShowScript/sandbox
1314
14- ln -s /data /workspaces/ShowScript/sandbox
15+
1516
1617# Attach the VSCode Console to the Minecraft server
You can’t perform that action at this time.
0 commit comments