diff --git a/Agent/Services/Updater.cs b/Agent/Services/Updater.cs index 1b7513217..4f6906e8d 100644 --- a/Agent/Services/Updater.cs +++ b/Agent/Services/Updater.cs @@ -69,7 +69,7 @@ public async Task CheckForUpdates() } var lastEtag = string.Empty; - + if (File.Exists("etag.txt")) { lastEtag = await File.ReadAllTextAsync("etag.txt"); diff --git a/Server/wwwroot/Downloads/Install-Linux-x64.sh b/Server/wwwroot/Downloads/Install-Linux-x64.sh index 041f71212..60515ff1d 100644 --- a/Server/wwwroot/Downloads/Install-Linux-x64.sh +++ b/Server/wwwroot/Downloads/Install-Linux-x64.sh @@ -2,6 +2,7 @@ HostName= Organization= GUID=$(cat /proc/sys/kernel/random/uuid) +ETag= if [ "$1" = "--uninstall" ]; then systemctl stop remotely-agent @@ -29,6 +30,7 @@ apt-get -y install libxtst-dev apt-get -y install xclip apt-get -y install jq apt-get -y install xterm +apt-get -y install curl if [ -f "/usr/local/bin/Remotely/ConnectionInfo.json" ]; then GUID=`cat "/usr/local/bin/Remotely/ConnectionInfo.json" | jq -r '.DeviceID'` @@ -62,7 +64,7 @@ connectionInfo="{ echo "$connectionInfo" > ./ConnectionInfo.json -curl --head $HostName/Downloads/Remotely-Linux.zip | grep etag | cut -d' ' -f 2 > etag.txt +curl --head $HostName/Downloads/Remotely-Linux.zip | grep etag | cut -d' ' -f 2 > ./etag.txt echo Creating service...