Move generic eggs

This commit is contained in:
Michael Parker
2022-09-07 12:27:11 -04:00
parent 6886c001a1
commit d93502b2a1
20 changed files with 301 additions and 131 deletions

25
generic/golang/README.md Normal file
View File

@@ -0,0 +1,25 @@
# discordgo generic
This egg is designed to run any generic Golang application, allowing users to pull their own Golang discord bot from a Github repository.
The startup configs and commands may need changing to actually function properly.
Users cannot upload their own code as this is built to build the resulting bot.
`GO_PACKAGE` is the variable for the go repo i.e. `github.com/aurieh/ddg-ng`
`EXECUTABLE` is the variable for the executable that is built i.e. `ddg-ng`
## Configuration
The server will be stuck as `starting` until the egg Start Configuration is modified. You have to edit the text to match something your bot will print for Pterodactyl panel to detect it as running.
![image](https://user-images.githubusercontent.com/10975908/126516861-c5cb4630-9f25-405c-8199-97bf5ec15a7f.png)
You can use arrays to have multiple different values when different bots are being used
```json
{
"done":[
"change this text 1",
"change this text 2"
]
}

View File

@@ -0,0 +1,52 @@
{
"_comment": "DO NOT EDIT: FILE GENERATED AUTOMATICALLY BY PTERODACTYL PANEL - PTERODACTYL.IO",
"meta": {
"version": "PTDL_v2",
"update_url": null
},
"exported_at": "2022-07-25T14:20:37-04:00",
"name": "golang generic",
"author": "parker@parkervcp.com",
"description": "A generic golang egg that compiles the application and saves an executable\r\n\r\nMeant to be customized before it is used.",
"features": null,
"docker_images": {
"quay.io\/parkervcp\/pterodactyl-images:base_debian": "quay.io\/parkervcp\/pterodactyl-images:base_debian"
},
"file_denylist": [],
"startup": ".\/${EXECUTABLE}",
"config": {
"files": "{}",
"startup": "{}",
"logs": "{}",
"stop": "^C"
},
"scripts": {
"installation": {
"script": "#!\/bin\/bash\r\n# golang generic package\r\n\r\n\r\nif [ ! -d \/mnt\/server\/ ]; then\r\n mkdir -p \/mnt\/server\/\r\nfi\r\n\r\ngo get ${GO_PACKAGE}\r\n\r\ncd src\/${GO_PACKAGE}\r\n\r\ngo get\r\n\r\ngo build\r\n\r\ncp -f ${EXECUTABLE} \/mnt\/server\/",
"container": "golang:1.15-buster",
"entrypoint": "bash"
}
},
"variables": [
{
"name": "Go Package",
"description": "Go package to get and build",
"env_variable": "GO_PACKAGE",
"default_value": "",
"user_viewable": true,
"user_editable": true,
"rules": "required|string",
"field_type": "text"
},
{
"name": "Executable",
"description": "This is the executable from the build.",
"env_variable": "EXECUTABLE",
"default_value": "",
"user_viewable": true,
"user_editable": false,
"rules": "required|string",
"field_type": "text"
}
]
}