gitlab: patch for openssl 3.x support (#233235)

This commit is contained in:
Yureka 2023-05-21 17:18:27 +02:00 committed by GitHub
parent 936612681e
commit cb1bce2e1c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 9 additions and 8 deletions

View file

@ -19,7 +19,7 @@ gem 'bootsnap', '~> 1.16.0', require: false
# Pin openssl to match the version bundled with our supported Rubies.
# See https://stdgems.org/openssl/#gem-version.
gem 'openssl', '2.2.2'
gem 'openssl', '3.0.2'
gem 'ipaddr', '~> 1.2.5'
# Responders respond_to and respond_with

View file

@ -1093,8 +1093,7 @@ GEM
validate_email
validate_url
webfinger (>= 1.0.1)
openssl (2.2.2)
ipaddr
openssl (3.0.2)
openssl-signature_algorithm (1.3.0)
openssl (> 2.0)
opentracing (0.5.0)
@ -1855,7 +1854,7 @@ DEPENDENCIES
omniauth_crowd (~> 2.4.0)!
omniauth_openid_connect (~> 0.6.1)
openid_connect (= 1.3.0)
openssl (= 2.2.2)
openssl (= 3.0.2)
org-ruby (~> 0.9.12)
pact (~> 1.63)
parallel (~> 1.19)
@ -1967,4 +1966,4 @@ DEPENDENCIES
yajl-ruby (~> 1.4.3)
BUNDLED WITH
2.4.12
2.4.13

View file

@ -4218,15 +4218,14 @@ src:
version = "1.3.0";
};
openssl = {
dependencies = ["ipaddr"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0xx01in25q31rpxmq2qlimi44zarsp4px7046xnc6in0pa127xsk";
sha256 = "0mcg47zz4w902cq6c8cdj62npawgwq68sfh7n7aqy7vm3pgvls9h";
type = "gem";
};
version = "2.2.2";
version = "3.0.2";
};
openssl-signature_algorithm = {
dependencies = ["openssl"];

View file

@ -144,6 +144,9 @@ def update_rubyenv():
with open(rubyenv_dir / fn, 'w') as f:
f.write(repo.get_file(fn, rev))
# patch for openssl 3.x support
subprocess.check_output(['sed', '-i', "s:'openssl', '2.*':'openssl', '3.0.2':g", 'Gemfile'], cwd=rubyenv_dir)
# Fetch vendored dependencies temporarily in order to build the gemset.nix
subprocess.check_output(['mkdir', '-p', 'vendor/gems'], cwd=rubyenv_dir)
subprocess.check_output(['sh', '-c', f'curl -L https://gitlab.com/gitlab-org/gitlab/-/archive/v{version}-ee/gitlab-v{version}-ee.tar.bz2?path=vendor/gems | tar -xj --strip-components=3'], cwd=f'{rubyenv_dir}/vendor/gems')