Skip to content

Commit 3ddad0c

Browse files
committed
Changed default to true but not erroring out when gpg binary is not found.
1 parent de72e59 commit 3ddad0c

File tree

2 files changed

+12
-9
lines changed

2 files changed

+12
-9
lines changed

Diff for: tasks/download.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"check_download": {
1313
"type": "Boolean",
1414
"description": "Whether to check the integrity of the downloaded file",
15-
"default": false
15+
"default": true
1616
}
1717
},
1818
"input_method": "environment",

Diff for: tasks/download.sh

+11-8
Original file line numberDiff line numberDiff line change
@@ -17,26 +17,29 @@ if [[ "$PT_check_download" != "true" ]]; then
1717
fi
1818

1919
if ! which gpg ; then
20-
echo "gpg binary required in path for checking download"
21-
exit 1
20+
echo "gpg binary required in path for checking download. Skipping check."
21+
exit 0
2222
fi
23+
2324
echo "Importing Puppet gpg public key"
2425
gpg --keyserver hkp://keyserver.ubuntu.com:11371 --recv-key 4528B6CD9E61EF26
2526
if gpg --list-key --fingerprint 4528B6CD9E61EF26 | grep -q -E "D681 +1ED3 +ADEE +B844 +1AF5 +AA8F +4528 +B6CD +9E61 +EF26" ; then
26-
echo "gpg public key imported successfully!"
27+
echo "gpg public key imported successfully."
2728
else
28-
echo "Could not import gpg public key - wrong fingerprint"
29+
echo "Could not import gpg public key - wrong fingerprint."
2930
exit 1
3031
fi
32+
3133
sigpath=${PT_path}.asc
3234
sigsource=${PT_source}.asc
33-
echo "Downloading tarball signature from ${sigsource}"
35+
36+
echo "Downloading tarball signature from ${sigsource}..."
3437
curl -f -L -o "${sigpath}" "${sigsource}"
35-
echo "Downloaded tarball signature to ${sigpath}"
36-
echo "Checking tarball signature at ${sigpath}"
38+
echo "Downloaded tarball signature to ${sigpath}."
39+
echo "Checking tarball signature at ${sigpath}..."
3740
if gpg --verify "${sigpath}" "${PT_path}" | grep "Good signature" ; then
3841
echo "Signature verification failed, please re-run the installation."
3942
exit 1
4043
else
41-
echo "Signature verification suceeded!"
44+
echo "Signature verification suceeded."
4245
fi

0 commit comments

Comments
 (0)