mirror of
https://github.com/DerTyp7/glassminers-server-docker.git
synced 2025-10-29 21:02:10 +01:00
Added environment variable to set version of server
This commit is contained in:
@@ -1,7 +1,15 @@
|
||||
#!/bin/bash
|
||||
|
||||
echo "[Info] Downloading latest server version..."
|
||||
wget https://github.com/surrealtm/Glassminers/releases/latest/download/GMServer.out -O "server.out"
|
||||
VERSION=${VERSION:- "latest"}
|
||||
|
||||
echo "[Info] Downloading server (${VERSION})..."
|
||||
|
||||
if [ "$VERSION" = "latest" ]; then
|
||||
wget https://github.com/surrealtm/Glassminers/releases/latest/download/GMServer.out -O "server.out"
|
||||
|
||||
else
|
||||
wget https://github.com/surrealtm/Glassminers/releases/download/${VERSION}/GMServer.out -O "server.out"
|
||||
fi
|
||||
|
||||
if [ $? -ne 0 ]; then
|
||||
echo "[Error] Download failed! Aborting."
|
||||
|
||||
Reference in New Issue
Block a user