Verify gem checksums against committed file
Only verified if env var is set. If verification fails, bundle install refuses to proceed. Add docs for developers on how to update Gemfile.checksum
... | @@ -2,6 +2,12 @@ | ... | @@ -2,6 +2,12 @@ |
source 'https://rubygems.org' | source 'https://rubygems.org' | ||
if ENV['BUNDLER_CHECKSUM_VERIFICATION_OPT_IN'] # this verification is still experimental | |||
$:.unshift(File.expand_path("vendor/gems/bundler-checksum/lib", __dir__)) | |||
require 'bundler-checksum' | |||
Bundler::Checksum.patch! | |||
end | |||
gem 'bundler-checksum', '~> 0.1.0', path: 'vendor/gems/bundler-checksum', require: false | gem 'bundler-checksum', '~> 0.1.0', path: 'vendor/gems/bundler-checksum', require: false | ||
gem 'rails', '~> 6.1.6.1' | gem 'rails', '~> 6.1.6.1' | ||
... | ... |
想要评论请 注册 或 登录