{"meta":{"slug":"games-standalone-open-m-p","name":"Open M P","category":"gta","source":"pelican","owner":"pelican-eggs","repo":"games-standalone","branch":"main","path":"gta/openmp/egg-open-m-p.json","rawUrl":"https://raw.githubusercontent.com/pelican-eggs/games-standalone/main/gta/openmp/egg-open-m-p.json","indexedAt":1792246788483},"egg":{"_comment":"DO NOT EDIT: FILE GENERATED AUTOMATICALLY BY PANEL","meta":{"version":"PTDL_v2","update_url":null},"exported_at":"2024-06-01T00:16:57+00:00","name":"OpenMP","author":"vedrancappone@gmail.com","uuid":"c7cf92b3-1506-406d-93bf-6b3f4c5db899","description":"A multiplayer mod for Grand Theft Auto: San Andreas that is fully backwards compatible with San Andreas Multiplayer.","features":null,"docker_images":{"Samp":"ghcr.io/parkervcp/games:samp"},"file_denylist":[],"startup":"./omp-server","config":{"files":"{\r\n    \"config.json\": {\r\n        \"parser\": \"json\",\r\n        \"find\": {\r\n            \"network.port\": \"{{server.build.default.port}}\",\r\n            \"rcon.password\": \"{{server.build.env.RCON_PASSWORD}}\"\r\n        }\r\n    }\r\n}","startup":"{\r\n    \"done\": \"started on port\"\r\n}","logs":"{}","stop":"exit"},"scripts":{"installation":{"script":"#!/bin/bash\r\n\r\napt -y install curl git jq tar\r\n\r\n## get release info and download links\r\nLATEST_JSON=$(curl --silent \"https://api.github.com/repos/openmultiplayer/open.mp/releases/latest\")\r\nRELEASES=$(curl --silent \"https://api.github.com/repos/openmultiplayer/open.mp/releases\")\r\nMATCH=open.mp-linux-x86-dynssl\r\n\r\nif [ -z \"${VERSION}\" ] || [ \"${VERSION}\" == \"latest\" ]; then\r\n    DOWNLOAD_URL=$(echo ${LATEST_JSON} | jq .assets | jq -r .[].browser_download_url | grep -i ${MATCH})\r\nelse\r\n    VERSION_CHECK=$(echo ${RELEASES} | jq -r --arg VERSION \"${VERSION}\" '.[] | select(.tag_name==$VERSION) | .tag_name')\r\n    if [ \"${VERSION}\" == \"${VERSION_CHECK}\" ]; then\r\n        DOWNLOAD_URL=$(echo ${RELEASES} | jq -r --arg VERSION \"${VERSION}\" '.[] | select(.tag_name==$VERSION) | .assets[].browser_download_url' | grep -i ${MATCH})\r\n    else\r\n        echo -e \"defaulting to latest release\"\r\n        DOWNLOAD_URL=$(echo ${LATEST_JSON} | jq .assets | jq -r .[].browser_download_url | grep -linux-x86 | head -1)\r\n    fi\r\nfi\r\n\r\necho \"running: curl -sSL -o openmp.tar.gz ${DOWNLOAD_URL}\"\r\ncurl -sSL -o openmp.tar.gz ${DOWNLOAD_URL}\r\n\r\nmkdir -p /mnt/server\r\ntar -xzvf openmp.tar.gz --strip-components=1 -C /mnt/server/\r\n\r\ncd /mnt/server || exit\r\n\r\necho \"creating default config\"\r\n\r\nif [ -e config.json ]; then\r\n    echo \"server config file exists\"\r\nelse\r\n    echo \"Downloading default OpenMp config\"\r\n    curl https://raw.githubusercontent.com/parkervcp/eggs/master/game_eggs/gta/openmp/config.json >> config.json\r\nfi\r\n\r\n\r\necho \"-----------------------------------------\"\r\necho \"Installation completed...\"\r\necho \"-----------------------------------------\"","container":"ghcr.io/parkervcp/installers:debian","entrypoint":"bash"}},"variables":[{"name":"RCON Password","description":"The password for RCON","env_variable":"RCON_PASSWORD","default_value":"","user_viewable":true,"user_editable":true,"rules":"required|string|max:32","sort":null,"field_type":"text"},{"name":"Version","description":"The version you want to install","env_variable":"VERSION","default_value":"latest","user_viewable":true,"user_editable":true,"rules":"required|string|max:20","sort":null,"field_type":"text"}]},"readme":"# OpenMp\r\n\r\nThe [OpenMp](https://www.open.mp/) GTA San Andreas dedicated server\r\n\r\n## Server Ports\r\n\r\n\r\n| Port    | default |\r\n|---------|---------|\r\n| Game    | 25570   |\r\n"}