Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions lib/restate/vm.rb
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
4 changes: 2 additions & 2 deletions test-services/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
Loading