Skip to content

Commit

Permalink
Clean up Minecraft template, add more tests
Browse files Browse the repository at this point in the history
Beacuse of how many forks there are, we are going to bring this back from the ground up
  • Loading branch information
LordRalex committed Apr 9, 2024
1 parent b18850c commit 47097d0
Show file tree
Hide file tree
Showing 2 changed files with 73 additions and 119 deletions.
71 changes: 71 additions & 0 deletions minecraft/data.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,42 @@
"type": "host"
}
},
{
"name": "minecraft-paper",
"variables": {
"memory": "2048",
"ip": "0.0.0.0",
"port": "25565",
"eula": true,
"version": "1.20.4",
"motd": "None",
"javaversion": "17",
"modlauncher": "paper",
"paperbuild": "478"
},
"environment": {
"type": "host"
}
},
{
"name": "minecraft-spigot",
"variables": {
"memory": "2048",
"ip": "0.0.0.0",
"port": "25565",
"eula": true,
"version": "1.20.4",
"motd": "None",
"javaversion": "17",
"modlauncher": "spigot"
},
"environment": {
"type": "host"
}
},



{
"name": "minecraft-vanilla-docker",
"variables": {
Expand Down Expand Up @@ -98,5 +134,40 @@
"type": "docker",
"image": "eclipse-temurin:${javaversion}"
}
},
{
"name": "minecraft-paper-docker",
"variables": {
"memory": "2048",
"ip": "0.0.0.0",
"port": "25565",
"eula": true,
"version": "1.20.4",
"motd": "None",
"javaversion": "17",
"modlauncher": "paper",
"paperbuild": "478"
},
"environment": {
"type": "docker",
"image": "eclipse-temurin:${javaversion}"
}
},
{
"name": "minecraft-spigot-docker",
"variables": {
"memory": "2048",
"ip": "0.0.0.0",
"port": "25565",
"eula": true,
"version": "1.20.4",
"motd": "None",
"javaversion": "17",
"modlauncher": "spigot"
},
"environment": {
"type": "docker",
"image": "eclipse-temurin:${javaversion}"
}
}
]
121 changes: 2 additions & 119 deletions minecraft/minecraft.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,14 +43,6 @@
"required": false,
"userEdit": false
},
"magmatag": {
"type": "string",
"value": "68e21495",
"display": "Tag",
"desc": "The alphanumeric commit ID for the build (See https://git.magmafoundation.org/magmafoundation/Magma-1-18-x/-/releases for the commit ID's for each release))",
"required": false,
"userEdit": true
},
"memory": {
"type": "integer",
"value": 1024,
Expand Down Expand Up @@ -79,48 +71,16 @@
"value": "forge",
"display": "MinecraftForge"
},
{
"value": "magma",
"display": "Magma"
},
{
"value": "mohist",
"display": "Mohist"
},
{
"value": "paper",
"display": "Paper"
},
{
"value": "pufferfish",
"display": "Pufferfish"
},
{
"value": "purpur",
"display": "Purpur"
},
{
"value": "quilt",
"display": "Quilt"
},
{
"value": "spigot",
"display": "Spigot"
},
{
"value": "ftb",
"display": "Feed The Beast Modpack"
}
]
},
"mohistversion": {
"type": "string",
"value": "latest",
"display": "Mohist Version",
"desc": "Mohist version to install (may be located <a href='https://mohistmc.com/download/' target='_blank'>here</a>).",
"required": false,
"userEdit": true
},
"motd": {
"type": "string",
"value": "A Minecraft Server\\n\\u00A79 hosted on PufferPanel",
Expand All @@ -131,7 +91,7 @@
},
"paperbuild": {
"type": "string",
"value": "96",
"value": "478",
"display": "build",
"desc": "Build of Paper to install (<a href='https://papermc.io/downloads'>Paper version build</a>). Must be specified as a build number, e.g. 484",
"required": false,
Expand Down Expand Up @@ -189,32 +149,14 @@
],
"order": 2
},
{
"if": "modlauncher == 'magma'",
"display": "Magma",
"description": "Settings specific if using Magma",
"variables": [
"magmatag"
],
"order": 3
},
{
"if": "modlauncher == 'mohist'",
"display": "Mohist",
"description": "Settings specific if using Mohist",
"variables": [
"mohistversion"
],
"order": 4
},
{
"if": "modlauncher == 'paper'",
"display": "Paper",
"description": "Settings specific if using Paper",
"variables": [
"paperbuild"
],
"order": 5
"order": 3
}
],
"install": [
Expand Down Expand Up @@ -281,32 +223,6 @@
"source": "forge-${forgebuild}.jar",
"target": "server.jar"
},
{
"if": "modlauncher == 'magma'",
"type": "download",
"files": [
"https://api.magmafoundation.org/api/v2/${version}/latest/${tag}/download"
]
},
{
"if": "modlauncher == 'magma'",
"type": "move",
"target": "server.jar",
"source": "Magma-*.jar"
},
{
"if": "modlauncher == 'mohist'",
"type": "download",
"files": [
"https://mohistmc.com/api/${version}/${mohistversion}/download/"
]
},
{
"if": "modlauncher == 'mohist'",
"type": "move",
"target": "server.jar",
"source": "mohist-*-server.jar"
},
{
"if": "modlauncher == 'paper'",
"type": "download",
Expand All @@ -320,39 +236,6 @@
"target": "server.jar",
"source": "paper-*.jar"
},
{
"if": "modlauncher == 'quilt'",
"type": "download",
"files": [
"https://maven.quiltmc.org/repository/release/org/quiltmc/quilt-installer/latest/quilt-installer-latest.jar"
]
},
{
"if": "modlauncher == 'quilt'",
"type": "move",
"target": "quilt-installer.jar",
"source": "quilt-installer-*.jar"
},
{
"if": "modlauncher == 'quilt' && env == 'host'",
"type": "command",
"commands": [
"java${javaversion} -jar quilt-installer.jar install server ${version} --download-server --install-dir=."
]
},
{
"if": "modlauncher == 'quilt' && env != 'host'",
"type": "command",
"commands": [
"java -jar quilt-installer.jar install server ${version} --download-server --install-dir=."
]
},
{
"if": "modlauncher == 'quilt'",
"type": "move",
"target": "server.jar",
"source": "quilt-server-launch.jar"
},
{
"if": "modlauncher == 'spigot'",
"type": "download",
Expand Down

0 comments on commit 47097d0

Please sign in to comment.