Skip to content

RedM

A new RedM egg for the latest builds due to recent changes in RedM

egg-redm.json

updated

Ports

Add an allocation on the node for each port.

  • Game 30120
  • ServerListing 30110
  • cfx join links 30130

Install

Installer image
ghcr.io/ptero-eggs/installers:debian
Install script
70 lines

Image

  • Debian ghcr.io/ptero-eggs/yolks:debian

Startup

The Panel runs this command to start the server. It replaces each variable in the command with the value of that variable.

6 variables

Startup command

$(pwd)/alpine/opt/cfx-server/ld-musl-x86_64.so.1 --library-path "$(pwd)/alpine/usr/lib/v8/:$(pwd)/alpine/lib/:$(pwd)/alpine/usr/lib/" -- $(pwd)/alpine/opt/cfx-server/FXServer +set citizen_dir $(pwd)/alpine/opt/cfx-server/citizen/ +set sv_licenseKey {{CFX_LICENSE}} +set steam_webApiKey none +set sv_maxplayers 32 +exec server.cfg +set gamename rdr3
  • Required to start the service. Get your keys at https://keymaster.fivem.net/

    CFX_LICENSEUsers can edit

    required|stringA value is required.

  • Set the fivem max play count

    MAX_PLAYERSUsers can see

    required|integer|between:1,32

  • The name that shows up in the server browser

    SERVER_HOSTNAMEUsers can edit

    required|string

  • The CFX Server version that is to be installed. Invalid versions will default to latest. an example is `1383-e5ea040353ce1b8bc86e37982bf5d888938e3096` You can the latest version from here - https://runtime.fivem.net/artifacts/fivem/build_proot_linux/master/

    CFX_VERSIONUsers can edit

    required|string|max:50

  • This is the link to download redm from. This is only used in the install script. The file you link to needs to be an fx.tar.zx file. Example: https://runtime.fivem.net/artifacts/fivem/build_proot_linux/master/1626-8c06e8bc3ed7e6690c6c2d9e0b90e29df65b3ea6/fx.tar.xz

    DOWNLOAD_URLUsers cannot see

    string|nullable

  • Use your Steam WebApiKey or set to 'none'. Get your key at https://steamcommunity.com/dev/apikey/

    STEAM_WEBAPIKEYUsers can edit

    required|string

Wings

Stop command
^C (SIGINT)
Running when the console shows
succeeded. Welcome!

Files Wings edits

Wings sets these values in these files before each start.

server.cfg file

endpoint_add_tcp
endpoint_add_tcp "0.0.0.0:{{server.build.default.port}}"
endpoint_add_udp
endpoint_add_udp "0.0.0.0:{{server.build.default.port}}"
sv_hostname
sv_hostname "{{server.build.env.SERVER_HOSTNAME}}"
sv_maxclients
sv_maxclients {{server.build.env.MAX_PLAYERS}}

Readme

Red M

From the RedM Site

RedM, for Red Dead Redemption 2 on PC. Launching now, based on the CitizenFX framework and Cfx.re technology.

Install notes

  • Only installs latest version versions are not selectable.

Server Ports

Ports required to run the server in a table format.

Port default
Game 30120
ServerListing 30110
cfx join links 30130

Changes

  1. Validate and update embedded URLs

    · Daniel Barton · bf9f3cb

  2. SteamCMD + Other fixes

    · yesBad · edbf925

  3. Add standalone games

    · Daniel Barton · 74c706a

All changes on GitHub

Problem with this egg?

Open an issue on GitHub. Include your Panel and Wings versions.

Install script 70 lines bash in ghcr.io/ptero-eggs/installers:debian Show
#!/bin/ash
# CFx Installation Script
#
# Server Files: /mnt/server
apt update -y
apt install -y tar xz-utils file jq

mkdir -p /mnt/server/resources /mnt/server/logs/

cd /mnt/server

echo "updating citizenfx resource files"
git clone https://github.com/citizenfx/cfx-server-data.git /tmp
cp -Rf /tmp/resources/* resources/

RELEASE_PAGE=$(curl -sSL https://runtime.fivem.net/artifacts/fivem/build_proot_linux/master/)
CHANGELOGS_PAGE=$(curl -sSL https://changelogs-live.fivem.net/api/changelog/versions/linux/server)

if [[ "${CFX_VERSION}" == "recommended" ]] || [[ -z ${CFX_VERSION} ]]; then
  DOWNLOAD_LINK=$(echo $CHANGELOGS_PAGE | jq -r '.recommended_download')
elif [[ "${CFX_VERSION}" == "latest" ]]; then
  DOWNLOAD_LINK=$(echo $CHANGELOGS_PAGE | jq -r '.latest_download')
else
  VERSION_LINK=$(echo -e "${RELEASE_PAGE}" | grep -Eo '".*/*.tar.xz"' | grep -Po '(?<=href=")[^"]*' | sed 's/\"//g' | sed 's/\.\///1' | grep ${CFX_VERSION})
  if [[ "${VERSION_LINK}" == "" ]]; then
    echo -e "defaulting to recommedned as the version requested was invalid."
    DOWNLOAD_LINK=$(echo $CHANGELOGS_PAGE | jq -r '.recommended_download')
  else
    DOWNLOAD_LINK=$(echo https://runtime.fivem.net/artifacts/fivem/build_proot_linux/master/${VERSION_LINK})
  fi
fi

if [ ! -z "${DOWNLOAD_URL}" ]; then
  if curl --output /dev/null --silent --head --fail ${DOWNLOAD_URL}; then
    echo -e "link is valid. setting download link to ${DOWNLOAD_URL}"
    DOWNLOAD_LINK=${DOWNLOAD_URL}
  else
    echo -e "link is invalid closing out"
    exit 2
  fi
fi

echo -e "Running curl -sSL ${DOWNLOAD_LINK} -o ${DOWNLOAD_LINK##*/}"

curl -sSL ${DOWNLOAD_LINK} -o ${DOWNLOAD_LINK##*/}

echo "Extracting fivem files"

FILETYPE=$(file -F ',' ${DOWNLOAD_LINK##*/} | cut -d',' -f2 | cut -d' ' -f2)
if [ "$FILETYPE" == "gzip" ]; then
  tar xzvf ${DOWNLOAD_LINK##*/}
elif [ "$FILETYPE" == "Zip" ]; then
  unzip ${DOWNLOAD_LINK##*/}
elif [ "$FILETYPE" == "XZ" ]; then
  tar xvf ${DOWNLOAD_LINK##*/}
else
  echo -e "unknown filetype. Exiting"
  exit 2
fi

rm -rf ${DOWNLOAD_LINK##*/} run.sh

if [ -e server.cfg ]; then
  echo "server config file exists"
else
  echo "Downloading default fivem config"
  curl https://raw.githubusercontent.com/ptero-eggs/game-eggs/main/gta/fivem/server.cfg >>server.cfg
fi

echo "install complete"