eggs/minecraft/forge/forge-generic/egg-forge-generic.json

45 lines
3.3 KiB
JSON
Raw Normal View History

{
"_comment": "DO NOT EDIT: FILE GENERATED AUTOMATICALLY BY PTERODACTYL PANEL - PTERODACTYL.IO",
"meta": {
"version": "PTDL_v1"
},
"exported_at": "2018-07-15T12:35:48-04:00",
"name": "Forge Generic",
"author": "parker@parkervcp.com",
"description": "A generic egg for a forge modpack",
"image": "quay.io\/pterodactyl\/core:java",
"startup": "java -Xms128M -Xmx{{SERVER_MEMORY}}M -jar server.jar",
"config": {
"files": "{\r\n \"server.properties\": {\r\n \"parser\": \"properties\",\r\n \"find\": {\r\n \"server-ip\": \"0.0.0.0\",\r\n \"enable-query\": \"true\",\r\n \"server-port\": \"{{server.build.default.port}}\",\r\n \"query.port\": \"{{server.build.default.port}}\"\r\n }\r\n }\r\n}",
"startup": "{\r\n \"done\": \")! For help, type \",\r\n \"userInteraction\": [\r\n \"Go to eula.txt for more info.\"\r\n ]\r\n}",
"logs": "{\r\n \"custom\": false,\r\n \"location\": \"logs\/latest.log\"\r\n}",
"stop": "stop"
},
"scripts": {
"installation": {
"script": "#!\/bin\/ash\r\n# Forge Installation Script\r\n#\r\n# Server Files: \/mnt\/server\r\napk update\r\napk add curl\r\n\r\nBASE_URL=${MODPACK_URL}\/files\r\n\r\nif [ -z \"${MODPACK_VERSION}\" ] || [ \"${MODPACK_VERSION}\" == \"latest\" ]; then\r\n ID=`curl -sl ${BASE_URL} | grep -i -A9 'title=\"release\"' | grep -m 1 -i -o 'href=\".*\"' | cut -d \"\/\" -f5 | sed s\/\\\"\/\/g`\r\n echo \"ID: ${ID}\"\r\nelse \r\n ID=`curl -sl ${BASE_URL} | grep -i -A9 \"${MODPACK_VERSION}\" | grep -m 1 -oE 'href=\"[^\\\"]+\"' | cut -d \"\/\" -f5 | grep -oE [0-9]+`\r\n echo \"ID: ${ID}\"\r\nfi\r\n\r\ncd \/mnt\/server\r\n\r\n\r\nSECONDURL=${BASE_URL}\/${ID}\r\necho \"SECONDURL: ${SECONDURL}\"\r\n\r\nGOOD_ID=`curl -sl ${SECONDURL} | grep -i server | grep -Eo 'href=\"[^\\\"]+\"' | grep -o -E \"[0-9]+\" | tail -1`\r\necho \"GOOD_ID: ${GOOD_ID}\"\r\n\r\nDL_URL=${BASE_URL}\/${GOOD_ID}\/download\r\necho \"Download_URL: ${DL_URL}\"\r\n\r\ncd \/mnt\/server\r\n\r\necho \"Executing curl -L ${DL_URL} -o server.zip\"\r\ncurl -L ${DL_URL} -o server.zip\r\n\r\nunzip server.zip\r\n\r\nrm -rf server.zip\r\n\r\necho -e \"\\nInstalling forge server usint the installer jar file.\\n\"\r\njava -jar *installer.jar --installServer\r\n\r\necho -e \"\\nDeleting installer jar file and cleaning up.\\n\"\r\nrm -rf *installer.jar\r\n\r\nmv *universal.jar server.jar",
"container": "frolvlad\/alpine-oraclejdk8:cleaned",
"entrypoint": "ash"
}
},
"variables": [
{
"name": "modpack URL",
"description": "The modpack URL from the curseforge site.\r\n\r\n(Ex. https:\/\/minecraft.curseforge.com\/projects\/sevtech-ages)",
"env_variable": "MODPACK_URL",
"default_value": "",
"user_viewable": 1,
"user_editable": 1,
"rules": "required|string|max:64"
},
{
"name": "Modpack Version",
"description": "Version of the modpack to use.",
"env_variable": "MODPACK_VERSION",
"default_value": "latest",
"user_viewable": 1,
"user_editable": 1,
"rules": "required|string|max:20"
}
]
}