Skip to content

Commit 20a8f61

Browse files
committed
Add jruby-openssl 0.11.0 to the Gemfile for jruby-9.0.
Just installing it isn't enough for it to be used. Fix downloading tz database releases from https://data.iana.org.
1 parent 9a537bc commit 20a8f61

File tree

2 files changed

+5
-15
lines changed

2 files changed

+5
-15
lines changed

.github/workflows/tests.yml

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -52,21 +52,6 @@ jobs:
5252
- run: ruby --version
5353
- run: gem --version
5454
- run: bundle --version
55-
- if: ${{ startsWith(matrix.ruby, 'jruby-9.0') }}
56-
name: Update jruby-openssl
57-
run: |
58-
curl --output /tmp/jruby-openssl-0.11.0-java.gem --retry 5 https://rubygems.org/downloads/jruby-openssl-0.11.0-java.gem
59-
hash=`sha256sum /tmp/jruby-openssl-0.11.0-java.gem | cut -d' ' -f1`
60-
echo "SHA-256 hash: $hash"
61-
if [[ "$hash" -eq a5ea2b925d49522ffbf191a591930c826d4e8c3e1550eaae8448ca6b0ad3169c ]]
62-
then
63-
gem install /tmp/jruby-openssl-0.11.0-java.gem --no-document
64-
rm /tmp/jruby-openssl-0.11.0-java.gem
65-
else
66-
echo 'SHA-256 hash did not match.' 1>&2
67-
rm /tmp/jruby-openssl-0.11.0-java.gem
68-
exit 1
69-
fi
7055
- id: determine_tzdata_version
7156
name: Determine tzdata version
7257
run: echo "tzdata_version=`ruby -r bundler/setup -r tzinfo/data -e 'puts TZInfo::Data::Version::TZDATA'`" >> $GITHUB_OUTPUT

Gemfile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,9 @@ end
1515
group :test do
1616
gem 'rake'
1717
gem 'minitest', '~> 5.0'
18+
19+
# Use a later version of jruby-openssl on JRuby 9.0 to allow downloads from https://data.iana.org.
20+
if RUBY_ENGINE == 'jruby' && JRUBY_VERSION < '9.1'
21+
gem 'jruby-openssl', '~> 0.11'
22+
end
1823
end

0 commit comments

Comments
 (0)