mirror of
https://github.com/parkervcp/eggs.git
synced 2026-06-13 01:33:58 +08:00
52 lines
3.5 KiB
JSON
52 lines
3.5 KiB
JSON
{
|
|
"_comment": "DO NOT EDIT: FILE GENERATED AUTOMATICALLY BY PTERODACTYL PANEL - PTERODACTYL.IO",
|
|
"meta": {
|
|
"version": "PTDL_v2",
|
|
"update_url": null
|
|
},
|
|
"exported_at": "2023-12-30T11:50:55+01:00",
|
|
"name": "NATS",
|
|
"author": "pterodactyl@geosk.xyz",
|
|
"description": "NATS is a simple, secure and performant communications system for digital systems, services and devices. NATS is part of the Cloud Native Computing Foundation (CNCF). NATS has over 40 client language implementations, and its server can run on-premise, in the cloud, at the edge, and even on a Raspberry Pi. NATS can secure and simplify design and operation of modern distributed systems.",
|
|
"features": null,
|
|
"docker_images": {
|
|
"ghcr.io\/parkervcp\/yolks:debian": "ghcr.io\/parkervcp\/yolks:debian"
|
|
},
|
|
"file_denylist": [],
|
|
"startup": ".\/nats-server -p {{SERVER_PORT}} `if [ ! -z $CONFIG_FILE ]; then echo \"-c $CONFIG_FILE\"; fi`;",
|
|
"config": {
|
|
"files": "{}",
|
|
"startup": "{\r\n \"done\": \"Server is ready\"\r\n}",
|
|
"logs": "{}",
|
|
"stop": "^C"
|
|
},
|
|
"scripts": {
|
|
"installation": {
|
|
"script": "#!\/bin\/bash\r\n\r\n# NATS Server installer.\r\n# Authored by Geosskk\r\n\r\nmkdir -p \/mnt\/server\r\ncd \/mnt\/server\r\n\r\n## get release info and download links\r\nLATEST_JSON=$(curl --silent \"https:\/\/api.github.com\/repos\/nats-io\/nats-server\/releases\/latest\")\r\nRELEASES=$(curl --silent \"https:\/\/api.github.com\/repos\/nats-io\/nats-server\/releases\")\r\nARCH=$([[ \"$(uname -m)\" == \"x86_64\" ]] && echo \"linux-amd64.tar.gz\" || echo \"linux-arm64.tar.gz\")\r\n\r\nif [ -z \"${VERSION}\" ] || [ \"${VERSION}\" == \"latest\" ]; then\r\n DOWNLOAD_URL=$(echo ${LATEST_JSON} | jq .assets | jq -r .[].browser_download_url | grep -i ${MATCH})\r\nelse\r\n VERSION_CHECK=$(echo ${RELEASES} | jq -r --arg VERSION \"${VERSION}\" '.[] | select(.tag_name==$VERSION) | .tag_name')\r\n if [ \"${VERSION}\" == \"${VERSION_CHECK}\" ]; then\r\n DOWNLOAD_URL=$(echo ${RELEASES} | jq -r --arg VERSION \"${VERSION}\" '.[] | select(.tag_name==$VERSION) | .assets[].browser_download_url' | grep -i ${MATCH})\r\n else\r\n echo -e \"defaulting to latest release\"\r\n DOWNLOAD_URL=$(echo ${LATEST_JSON} | jq .assets | jq -r .[].browser_download_url)\r\n fi\r\nfi\r\n\r\ncurl -sSL -o nats-server.tar.gz ${DOWNLOAD_URL}\r\ntar xvf nats-server.tar.gz --strip-components=1\r\nrm nats-server.tar.gz\r\n\r\nchmod +x nats-server\r\n\r\n## install end\r\necho \"-----------------------------------------\"\r\necho \"Installation completed...\"\r\necho \"-----------------------------------------\"",
|
|
"container": "ghcr.io\/parkervcp\/installers:debian",
|
|
"entrypoint": "bash"
|
|
}
|
|
},
|
|
"variables": [
|
|
{
|
|
"name": "Version",
|
|
"description": "The version of NATS to install.\r\nFor a specific version, example: v2.10.7",
|
|
"env_variable": "VERSION",
|
|
"default_value": "latest",
|
|
"user_viewable": true,
|
|
"user_editable": true,
|
|
"rules": "required|string|max:20",
|
|
"field_type": "text"
|
|
},
|
|
{
|
|
"name": "Configuration",
|
|
"description": "The file to use for NATS configuration.",
|
|
"env_variable": "CONFIG_FILE",
|
|
"default_value": "",
|
|
"user_viewable": true,
|
|
"user_editable": true,
|
|
"rules": "nullable|string|max:20",
|
|
"field_type": "text"
|
|
}
|
|
]
|
|
} |