|
1
|
|
{
|
|
2
|
|
"_comment": "DO NOT EDIT: FILE GENERATED AUTOMATICALLY BY PANEL",
|
|
3
|
|
"meta": {
|
|
展开 75 行未改动
|
|
4
|
|
"update_url": "https://eggs.pterodactyl.top/eggs/192/download/egg-velocity.json",
|
|
5
|
|
"version": "PTDL_v2"
|
|
6
|
|
},
|
|
7
|
|
"exported_at": "2024-06-01T19:40:07+00:00",
|
|
8
|
|
"name": "Velocity",
|
|
9
|
|
"author": "parker@parkervcp.com",
|
|
10
|
|
"description": "Velocity is a Minecraft server proxy with unparalleled server support, scalability, and flexibility.",
|
|
11
|
|
"features": [
|
|
12
|
|
"eula",
|
|
13
|
|
"java_version",
|
|
14
|
|
"pid_limit"
|
|
15
|
|
],
|
|
16
|
|
"docker_images": {
|
|
17
|
|
"Java 8": "registry.cn-shanghai.aliyuncs.com/pterodactyl-images/yolks:java_8",
|
|
18
|
|
"Java 11": "registry.cn-shanghai.aliyuncs.com/pterodactyl-images/yolks:java_11",
|
|
19
|
|
"Java 16": "registry.cn-shanghai.aliyuncs.com/pterodactyl-images/yolks:java_16",
|
|
20
|
|
"Java 17": "registry.cn-shanghai.aliyuncs.com/pterodactyl-images/yolks:java_17",
|
|
21
|
|
"Java 21": "registry.cn-shanghai.aliyuncs.com/pterodactyl-images/yolks:java_21",
|
|
22
|
|
"Java 25": "registry.cn-shanghai.aliyuncs.com/pterodactyl-images/yolks:java_25"
|
|
23
|
|
},
|
|
24
|
|
"file_denylist": [],
|
|
25
|
|
"startup": "java -Xms128M -Xmx{{SERVER_MEMORY}}M -XX:+UseG1GC -XX:G1HeapRegionSize=4M -XX:+UnlockExperimentalVMOptions -XX:+ParallelRefProcEnabled -XX:+AlwaysPreTouch -XX:MaxInlineLevel=15 -jar {{SERVER_JARFILE}}",
|
|
26
|
|
"config": {
|
|
27
|
|
"files": "{\r\n \"velocity.toml\": {\r\n \"parser\": \"file\",\r\n \"find\": {\r\n \"bind = \": \"bind = \\\"0.0.0.0:{{server.build.default.port}}\\\"\"\r\n }\r\n }\r\n}",
|
|
28
|
|
"logs": "{}",
|
|
29
|
|
"startup": "{\r\n \"done\": \"Done (\"\r\n}",
|
|
30
|
|
"stop": "end"
|
|
31
|
|
},
|
|
32
|
|
"scripts": {
|
|
33
|
|
"installation": {
|
|
34
|
|
"container": "registry.cn-shanghai.aliyuncs.com/pterodactyl-images/installers:alpine",
|
|
35
|
|
"entrypoint": "ash",
|
|
36
|
|
"script": "#!/bin/ash\r\n# Velocity Proxy Installation Script\r\n#\r\n# Server Files: /mnt/server\r\nPROJECT=velocity\r\n\r\nif [[ -z ${VELOCITY_VERSION} ]] || [[ ${VELOCITY_VERSION} == \"latest\" ]]; then\r\n VELOCITY_VERSION=\"latest\"\r\nfi\r\n\r\nif [[ -n \"${DOWNLOAD_LINK}\" ]]; then\r\n echo -e \"Using supplied download url: ${DOWNLOAD_LINK}\"\r\n DOWNLOAD_URL=$(eval echo $(echo ${DL_PATH} | sed -e 's/{{/${/g' -e 's/}}/}/g'))\r\nelse\r\n VER_EXISTS=$(curl -s https://api.papermc.io/v2/projects/${PROJECT} | jq -r --arg VERSION $VELOCITY_VERSION '.versions[] | contains($VERSION)' | grep true)\r\n LATEST_VERSION=$(curl -s https://api.papermc.io/v2/projects/${PROJECT} | jq -r '.versions' | jq -r '.[-1]')\r\n\r\nif [[ \"${VER_EXISTS}\" == \"true\" ]]; then\r\n echo -e \"Version is valid. Using version ${VELOCITY_VERSION}\"\r\nelse\r\n echo -e \"Using the latest ${PROJECT} version\"\r\n VELOCITY_VERSION=${LATEST_VERSION}\r\nfi\r\n\r\nBUILD_EXISTS=$(curl -s https://api.papermc.io/v2/projects/${PROJECT}/versions/${VELOCITY_VERSION} | jq -r --arg BUILD ${BUILD_NUMBER} '.builds[] | tostring | contains($BUILD)' | grep true)\r\nLATEST_BUILD=$(curl -s https://api.papermc.io/v2/projects/${PROJECT}/versions/${VELOCITY_VERSION} | jq -r '.builds' | jq -r '.[-1]')\r\n\r\nif [[ \"${BUILD_EXISTS}\" == \"true\" ]]; then\r\n echo -e \"Build is valid for version ${VELOCITY_VERSION}. Using build ${BUILD_NUMBER}\"\r\nelse\r\n echo -e \"Using the latest ${PROJECT} build for version ${VELOCITY_VERSION}\"\r\n BUILD_NUMBER=${LATEST_BUILD}\r\nfi\r\n\r\nJAR_NAME=${PROJECT}-${VELOCITY_VERSION}-${BUILD_NUMBER}.jar\r\necho \"Version being downloaded\"\r\necho -e \"Velocity Version: ${VELOCITY_VERSION}\"\r\necho -e \"Build: ${BUILD_NUMBER}\"\r\necho -e \"JAR Name of Build: ${JAR_NAME}\"\r\nDOWNLOAD_URL=https://api.papermc.io/v2/projects/${PROJECT}/versions/${VELOCITY_VERSION}/builds/${BUILD_NUMBER}/downloads/${JAR_NAME}\r\n\r\nfi\r\ncd /mnt/server\r\necho -e \"Running curl -o ${SERVER_JARFILE} ${DOWNLOAD_URL}\"\r\n\r\nif [[ -f ${SERVER_JARFILE} ]]; then\r\nmv ${SERVER_JARFILE} ${SERVER_JARFILE}.old\r\nfi\r\n\r\ncurl -o ${SERVER_JARFILE} ${DOWNLOAD_URL}\r\n\r\nif [[ -f velocity.toml ]]; then\r\n echo -e \"velocity config file exists\"\r\nelse\r\n echo -e \"downloading velocity config file.\"\r\n curl https://raw.githubusercontent.com/parkervcp/eggs/master/game_eggs/minecraft/proxy/java/velocity/velocity.toml -o velocity.toml\r\nfi\r\n\r\nif [[ -f forwarding.secret ]]; then\r\n echo -e \"velocity forwarding secret file already exists\"\r\nelse\r\n echo -e \"creating forwarding secret file\"\r\n touch forwarding.secret\r\n date +%s | sha256sum | base64 | head -c 12 > forwarding.secret\r\nfi\r\n\r\necho -e \"install complete\""
|
|
37
|
|
}
|
|
38
|
|
},
|
|
39
|
|
"variables": [
|
|
40
|
|
{
|
|
41
|
|
"name": "Velocity Version",
|
|
42
|
|
"description": "The Velocity Proxy version to download.\r\n\r\nSet to 'latest ' the download the last stable build.",
|
|
43
|
|
"env_variable": "VELOCITY_VERSION",
|
|
44
|
|
"default_value": "latest",
|
|
45
|
|
"user_viewable": true,
|
|
46
|
|
"user_editable": false,
|
|
47
|
|
"rules": "required|string|max:20",
|
|
48
|
|
"field_type": "text"
|
|
49
|
|
},
|
|
50
|
|
{
|
|
51
|
|
"name": "Server Jar File",
|
|
52
|
|
"description": "Server Jarfile, by default this is set to 'velocity.jar'.\r\nSet it to otherwise if you wish to have a different jarfile name.",
|
|
53
|
|
"env_variable": "SERVER_JARFILE",
|
|
54
|
|
"default_value": "velocity.jar",
|
|
55
|
|
"user_viewable": true,
|
|
56
|
|
"user_editable": false,
|
|
57
|
|
"rules": "required|string|max:32|regex:/^([\\w\\d._-]+)(\\.jar)$/",
|
|
58
|
|
"field_type": "text"
|
|
59
|
|
},
|
|
60
|
|
{
|
|
61
|
|
"name": "Download Path",
|
|
62
|
|
"description": "A URL to use to download a server.jar rather than the ones in the install script. This is not user viewable.",
|
|
63
|
|
"env_variable": "DL_PATH",
|
|
64
|
|
"default_value": "",
|
|
65
|
|
"user_viewable": false,
|
|
66
|
|
"user_editable": false,
|
|
67
|
|
"rules": "nullable|string",
|
|
68
|
|
"field_type": "text"
|
|
69
|
|
},
|
|
70
|
|
{
|
|
71
|
|
"name": "Build Number",
|
|
72
|
|
"description": "The build number for the velocity release.\r\n\r\nLeave at latest to always get the latest version. Invalid versions will default to latest.",
|
|
73
|
|
"env_variable": "BUILD_NUMBER",
|
|
74
|
|
"default_value": "latest",
|
|
75
|
|
"user_viewable": true,
|
|
76
|
|
"user_editable": true,
|
|
77
|
|
"rules": "required|string|max:20",
|
|
78
|
|
"field_type": "text"
|
|
79
|
|
}
|
|
80
|
|
]
|
|
81
|
|
}
|