diff --git a/lnd.update.sh b/lnd.update.sh index d44bbe6..3d85e59 100644 --- a/lnd.update.sh +++ b/lnd.update.sh @@ -6,8 +6,8 @@ ## based on https://github.com/Stadicus/guides/blob/master/raspibolt/raspibolt_40_lnd.md#lightning-lnd ## see LND releases: https://github.com/lightningnetwork/lnd/releases -lndVersion="0.6.1-beta" -home="/mnt/hdd/app" +lndVersion="0.6.1-beta" # the version you would like to be updated +home="/mnt/hdd/app" # edit your download directory echo "Check Linux base ..." isARM=$(uname -m | grep -c 'arm') @@ -22,6 +22,7 @@ else echo "OK running on $(uname -m) architecture." fi +# update the SHA256 checksum upon version change if [ ${isARM} -eq 1 ] ; then lndOSversion="armv7" lndSHA256="5541959c7fde98d76d88cc8070ca626c681ba38c44afcb85bf417a9a677e23c2" @@ -48,10 +49,10 @@ PGPcheck="BD599672C804AF2770869A048B80CD2BB8BD8132" # get LND resources cd "${home}" binaryName="lnd-linux-${lndOSversion}-v${lndVersion}.tar.gz" -sudo -u admin wget https://github.com/lightningnetwork/lnd/releases/download/v${lndVersion}/${binaryName} -sudo -u admin wget https://github.com/lightningnetwork/lnd/releases/download/v${lndVersion}/manifest-v${lndVersion}.txt -sudo -u admin wget https://github.com/lightningnetwork/lnd/releases/download/v${lndVersion}/manifest-v${lndVersion}.txt.sig -sudo -u admin wget -O "${home}/pgp_keys.asc" ${PGPpkeys} +sudo -u admin wget -N https://github.com/lightningnetwork/lnd/releases/download/v${lndVersion}/${binaryName} +sudo -u admin wget -N https://github.com/lightningnetwork/lnd/releases/download/v${lndVersion}/manifest-v${lndVersion}.txt +sudo -u admin wget -N https://github.com/lightningnetwork/lnd/releases/download/v${lndVersion}/manifest-v${lndVersion}.txt.sig +sudo -u admin wget -N -O "${home}/pgp_keys.asc" ${PGPpkeys} # check binary is was not manipulated (checksum test) binaryChecksum=$(sha256sum ${binaryName} | cut -d " " -f1)