diff --git a/gatekeeperv2.kvp b/gatekeeperv2.kvp index 043c247..9953837 100644 --- a/gatekeeperv2.kvp +++ b/gatekeeperv2.kvp @@ -20,7 +20,7 @@ App.DisplayName=GatekeeperV2 Bot App.RootDir=./gatekeeperv2/ App.BaseDirectory=./gatekeeperv2/ App.ExecutableWin=$PATH/python3 -App.ExecutableLinux=/usr/bin/python3 +App.ExecutableLinux=venv/bin/python3 App.WorkingDir=GatekeeperV2-main App.LinuxCommandLineArgs= App.WindowsCommandLineArgs= @@ -54,7 +54,8 @@ App.RCONConnectRetrySeconds=5 App.RCONHeartbeatMinutes=0 App.RCONHeartbeatCommand=ping App.TelnetLoginFormat={0} -App.UpdateSources=[{"UpdateStageName":"Bot Download","UpdateSourcePlatform":"All","UpdateSource":"FetchURL","UpdateSourceData":"https://github.com/k8thekat/GatekeeperV2/archive/refs/heads/main.zip","UnzipUpdateSource":true,"OverwriteExistingFiles":true,"DeleteAfterExtract":true},{"UpdateStageName":"Pip & Discord.py Script","UpdateSourcePlatform":"Linux","UpdateSource":"Executable","UpdateSourceData":"/bin/bash","UpdateSourceArgs":"-c \"pip install --upgrade pip && pip install numpy requests && git clone https://github.com/Rapptz/discord.py && cd discord.py && python3 -m pip install discord.py\""}] +App.UpdateSources=@IncludeJson[gatekeepverv2updates.json] +App.PreStartStages=[{"UpdateStageName":"Create Virtual Environment","UpdateSourcePlatform":"Linux","UpdateSource":"Executable","UpdateSourceData":"/bin/bash","UpdateSourceArgs":"-c \"source '{{$FullRootDir}}venv/bin/activate'\""}] App.Compatibility=None App.SteamUpdateAnonymousLogin=True App.SteamForceLoginPrompt=False diff --git a/gatekeepverv2updates.json b/gatekeepverv2updates.json new file mode 100644 index 0000000..108d5ca --- /dev/null +++ b/gatekeepverv2updates.json @@ -0,0 +1,25 @@ +[ + { + "UpdateStageName": "Bot Download", + "UpdateSourcePlatform": "All", + "UpdateSource": "FetchURL", + "UpdateSourceData": "https://github.com/k8thekat/GatekeeperV2/archive/refs/heads/main.zip", + "UnzipUpdateSource": true, + "OverwriteExistingFiles": true, + "DeleteAfterExtract": true + }, + { + "UpdateStageName": "Create Virtual Environment", + "UpdateSourcePlatform": "Linux", + "UpdateSource": "Executable", + "UpdateSourceData": "/bin/bash", + "UpdateSourceArgs": "-c \"rm -rf '{{$FullRootDir}}venv' && /usr/bin/python3 -m venv '{{$FullRootDir}}venv'\"" + }, + { + "UpdateStageName": "Pip & Discord.py Script", + "UpdateSourcePlatform": "Linux", + "UpdateSource": "Executable", + "UpdateSourceData": "/bin/bash", + "UpdateSourceArgs": "-c \"source '{{$FullRootDir}}venv/bin/activate' && python3 -m pip install --upgrade pip && python3 -m pip install numpy requests && git clone https://github.com/Rapptz/discord.py && cd discord.py && python3 -m pip install discord.py\"" + } +] \ No newline at end of file