diff --git a/lib/restate/vm.rb b/lib/restate/vm.rb index 5fa7da5..3c22656 100644 --- a/lib/restate/vm.rb +++ b/lib/restate/vm.rb @@ -7,8 +7,13 @@ RUBY_VERSION =~ /(\d+\.\d+)/ require_relative "#{Regexp.last_match(1)}/restate_internal" rescue LoadError - # Fall back to the default location (development builds, source gem installs) - require_relative 'restate_internal' + begin + # rake compile output (ext.lib_dir = 'lib/restate' in Rakefile) + require_relative 'restate_internal' + rescue LoadError + # gem install from source: extconf.rb builds to lib/restate_internal + require_relative '../restate_internal' + end end module Restate diff --git a/test-services/Dockerfile b/test-services/Dockerfile index a19335b..8b330fc 100644 --- a/test-services/Dockerfile +++ b/test-services/Dockerfile @@ -26,9 +26,9 @@ RUN bundle install && bundle exec rake compile # ── Runtime stage ── FROM ruby:3.3-slim-bookworm AS test-services -# Install build tools for native gem extensions (e.g. json) +# Install build tools and OpenSSL dev headers for native gem extensions RUN apt-get update -y && \ - apt-get install -y build-essential && \ + apt-get install -y build-essential libssl-dev && \ rm -rf /var/lib/apt/lists/* WORKDIR /usr/src/app