Skip to content

Commit

Permalink
Use dotnet image for terraria
Browse files Browse the repository at this point in the history
  • Loading branch information
LordRalex committed Apr 12, 2024
1 parent 2502b4c commit 2d8eedc
Show file tree
Hide file tree
Showing 3 changed files with 48 additions and 12 deletions.
7 changes: 5 additions & 2 deletions pocketmine/pocketmine.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,11 +59,14 @@
},
{
"type": "docker",
"image": "ubuntu"
"image": "pufferpanel/ubuntu"
}
],
"requirements": {
"os": "linux",
"arch": "amd64"
"arch": "amd64",
"binaries": [
"curl"
]
}
}
28 changes: 24 additions & 4 deletions terraria-tmodloader/terraria-tmodloader.json
Original file line number Diff line number Diff line change
Expand Up @@ -296,27 +296,47 @@
},
"install": [
{
"if": "env == 'host'",
"type": "download",
"files": [
"https://github.com/tModLoader/tModLoader/releases/download/${tversion}/tModLoader.zip",
"https://dotnetcli.azureedge.net/dotnet/Runtime/${dotnetversion}/dotnet-runtime-${dotnetversion}-linux-${arch}.tar.gz"
]
},
{
"if": "env == 'host'",
"type": "command",
"commands": [
"rm -rf dotnet",
"mkdir -p dotnet",
"tar -xzf dotnet-runtime-${dotnetversion}-linux-${arch}.tar.gz -C dotnet",
"rm -rf dotnet-runtime-linux-${arch}.tar.gz",
"rm -rf dotnet-runtime-linux-${arch}.tar.gz"
]
},
{
"type": "download",
"files": [
"https://github.com/tModLoader/tModLoader/releases/download/${tversion}/tModLoader.zip"
]
},
{
"type": "command",
"commands": [
"unzip tModLoader.zip -d .",
"rm tModLoader.zip",
"mkdir -p ./${wp}"
]
}
],
"run": {
"command": "dotnet/dotnet tModLoader.dll -server ${steam} -ip ${ip} ${disableannouncementbox} -announcementboxrange ${abr} -config ./serverconfig.txt -autocreate ${size}",
"command": [
{
"if": "env == 'docker'",
"command": "dotnet tModLoader.dll -server ${steam} -ip ${ip} ${disableannouncementbox} -announcementboxrange ${abr} -config ./serverconfig.txt -autocreate ${size}",
},
{
"command": "dotnet/dotnet tModLoader.dll -server ${steam} -ip ${ip} ${disableannouncementbox} -announcementboxrange ${abr} -config ./serverconfig.txt -autocreate ${size}",
}
],
"stop": "exit",
"pre": [
{
Expand All @@ -341,7 +361,7 @@
},
{
"type": "docker",
"image": "pufferpanel/ubuntu"
"image": "mcr.microsoft.com/dotnet/runtime:${dotnetversion}"
}
],
"requirements": {
Expand Down
25 changes: 19 additions & 6 deletions terraria-tshock/terraria-tshock.json
Original file line number Diff line number Diff line change
Expand Up @@ -108,23 +108,36 @@
},
"install": [
{
"if": "env == 'host'",
"type": "download",
"files": [
"https://github.com/Pryaxis/TShock/releases/download/v${tshockversion}/TShock-${tshockversion}-for-Terraria-${version}-linux-${arch}-Release.zip",
"https://dotnetcli.azureedge.net/dotnet/Runtime/${dotnetversion}/dotnet-runtime-${dotnetversion}-linux-${arch}.tar.gz"
]
},
{
"if": "env == 'host'",
"type": "command",
"commands": [
"rm -rf dotnet",
"mkdir -p dotnet",
"tar -xzf dotnet-runtime-${dotnetversion}-linux-${arch}.tar.gz -C dotnet",
"rm -rf dotnet-runtime-linux-${arch}.tar.gz"
]
},
{
"type": "download",
"files": [
"https://github.com/Pryaxis/TShock/releases/download/v${tshockversion}/TShock-${tshockversion}-for-Terraria-${version}-linux-${arch}-Release.zip"
]
},
{
"type": "command",
"commands": [
"unzip TShock-${tshockversion}-for-Terraria-${version}-linux-${arch}-Release.zip",
"tar xf TShock-Beta-linux-${arch}-Release.tar",
"mkdir worlds",
"mkdir dotnet",
"tar xzf dotnet-runtime-${dotnetversion}-linux-${arch}.tar.gz -C dotnet",
"rm -rf TShock-${tshockversion}-for-Terraria-${version}-linux-${arch}-Release.zip",
"rm -rf TShock-Beta-linux-${arch}-Release.tar",
"rm -rf dotnet-runtime-linux-${arch}.tar.gz"
"rm -rf TShock-Beta-linux-${arch}-Release.tar"
]
}
],
Expand All @@ -150,7 +163,7 @@
},
{
"type": "docker",
"image": "pufferpanel/ubuntu"
"image": "mcr.microsoft.com/dotnet/runtime:${dotnetversion}"
}
],
"requirements": {
Expand Down

0 comments on commit 2d8eedc

Please sign in to comment.