Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions docs/static/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,11 @@ is_command() {
# example: check_sha256 "${TMP_DIR}" checksums.txt
validate_checksums_file() {
cd "$1"
grep "$FILENAME" "$2" > checksum.txt
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does this do exactly? What was the problem with alpine?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The problem is that sha256sum does not recognize the following options on Alpine: --ignore-missing, --quiet . More info in the #587 issue.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added more context in the PR

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does this do exactly?

It gets just one line referencing a Chainloop tarball and saves it in checksum.txt. We use that output file later so --ignore-missing is not required.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the context :)

if is_command sha256sum; then
sha256sum --ignore-missing --quiet --check "$2"
sha256sum -c checksum.txt
elif is_command shasum; then
shasum -a 256 --ignore-missing --quiet --check checksums.txt
shasum -a 256 -q -c checksum.txt
else
fancy_print 1 "We were not able to verify checksums. Commands sha256sum, shasum are not found."
return 1
Expand Down