Skip to content

Commit

Permalink
Fix server download
Browse files Browse the repository at this point in the history
  • Loading branch information
PepeCitron committed Aug 26, 2024
1 parent ba24623 commit ce58b37
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 9 deletions.
2 changes: 0 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
version: "3.8"

services:
project-zomboid:
container_name: pzserver
Expand Down
12 changes: 7 additions & 5 deletions entry.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,21 @@ then
mkdir -p /home/steam/
cd /home/steam/
curl -sqL "https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz" | tar zxvf -
chown -R pzombie:pzombie /home/steam
chown -R pzombie:pzombie /data/server-file
fi

# Update pzserver
echo "Updating Project Zomboid..."
if [ "$SERVER_BRANCH" == "" ]
if [ "$SERVER_BRANCH" -eq "" ]
then
su pzombie -s /bin/sh -p -c "/home/steam/steamcmd.sh +force_install_dir /data/server-file +login anonymous +app_update 380870 +quit"
su root -s /bin/sh -p -c "/home/steam/steamcmd.sh +force_install_dir /data/server-file +login anonymous +app_update 380870 +quit"
else
su pzombie -s /bin/sh -p -c "/home/steam/steamcmd.sh +force_install_dir /data/server-file +login anonymous +app_update 380870 -beta ${SERVER_BRANCH} +quit"
su root -s /bin/sh -p -c "/home/steam/steamcmd.sh +force_install_dir /data/server-file +login anonymous +app_update 380870 -beta ${SERVER_BRANCH} +quit"
fi

# Permissions
chown -R pzombie:pzombie /home/steam
chown -R pzombie:pzombie /data/server-file

# Symlink
echo "Creating symlink for config folder..."
if [ ! -d /data/config ]
Expand Down
2 changes: 0 additions & 2 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@
Example of docker compose file

```yaml
version: "3.8"

services:
project-zomboid:
container_name: pzserver
Expand Down

0 comments on commit ce58b37

Please sign in to comment.