Sha256: 5878d10203ab121c982bfe6a8b3b21e789695c93b061ff00f80bb83d440e1b01
Contents?: true
Size: 1.04 KB
Versions: 71
Compression:
Stored size: 1.04 KB
Contents
#!/usr/bin/env bash # This script verifies integrity of the Pro license # Run it before bundle install to ensure, that what you are fetching is what you expect # Run it after bundle install to ensure that the local artefact was not compromised #!/usr/bin/env bash set -e if [ "$MODE" != "after" ]; then # Check the remote license prior to bundle installing curl \ --retry 5 \ --retry-delay 1 \ --fail \ -u $KARAFKA_PRO_USERNAME:$KARAFKA_PRO_PASSWORD \ https://gems.karafka.io/gems/karafka-license-$KARAFKA_PRO_VERSION.gem \ -o ./karafka-license.gem else # Check the local cached one after bundle install cache_path=`ruby -e 'puts "#{Gem.dir}/cache/"'` cp "$cache_path/karafka-license-$KARAFKA_PRO_VERSION.gem" ./karafka-license.gem fi detected=`sha256sum ./karafka-license.gem | awk '{ print $1 }'` rm ./karafka-license.gem echo -n "Karafka Pro license artifact checksum verification result: " if [ "$detected" = "$KARAFKA_PRO_LICENSE_CHECKSUM" ]; then echo "Success" else echo -e "\033[0;31mFailure!\033[0m" exit 1 fi
Version data entries
71 entries across 71 versions & 1 rubygems