Egg Repository

Pterodactyl Community Egg Repository

SA-MP

SA-MP is a free Massively Multiplayer Online game mod for the PC version of Rockstar Games Grand Theft Auto: San Andreas (tm).

Read Me

SA:MP

The SA:MP GTA San Andreas dedicated server

Yolks
NameTag
Sampghcr.io/ptero-eggs/games:samp
Variables
NameDescriptionEnvironment VariableDefault ValueUser ViewableUser Editable
VersionExample: if the download url is https://sampcenter.com/download/server/linux/0.3.7.tar.gz then the variable should be: `0.3.7`Version0.3.7YesYes
Rcon passwordThe password used for rconRCON_PASSYesYes
Install Script
#!/bin/bash

# Check if VERSION is set and starts with an uppercase "R"
if [[ -n "$VERSION" && "$VERSION" == R* ]]; then
    VERSION="0.3.7"
    echo "Updated VERSION: $VERSION"
fi

cd /tmp || exit
echo "running: curl -sSL -o samp.tar.gz https://sampcenter.com/download/server/linux/${VERSION}.tar.gz"
curl -sSL -o samp.tar.gz https://sampcenter.com/download/server/linux/${VERSION}.tar.gz

mkdir -p /mnt/server
tar -xzvf samp.tar.gz --strip-components=1 -C /mnt/server/

cd /mnt/server || exit

sed -i '3d' /mnt/server/server.cfg
echo "rcon_password ${RCON_PASS}" >> /mnt/server/server.cfg

chown -R root:root /mnt

export HOME=/mnt/server


## install end
echo "-----------------------------------------"
echo "Installation completed..."
echo "-----------------------------------------"