I’m doing a ruby web service build, really nothing special in it
In the Gemfile.lock here are some of the relevant gems:
rake (13.0.3)
nokogiri (1.11.4)
the error:
Jan 17 10:58:43 PM bundler: failed to load command: rake (/opt/render/project/.gems/bin/rake)
Jan 17 10:58:43 PM /opt/render/project/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/definition.rb:481:in `materialize': Could not find nokogiri-1.11.4 in any of the sources (Bundler::GemNotFound)
yeah, it does sound like it as it uses native extensions - did you ditch the vendor cache and try adding the gems again with bundle config set force_ruby_platform true
I’m attempting to set up a staging environment. This issue was a problem for me in the regular production environment but the set force_ruby_platform true worked for me there.
However, I have all of that set on my staging services as well but it’s running into the error:
bundler: failed to load command: sidekiq (/opt/render/project/.gems/bin/sidekiq)
Jul 5 02:53:29 PM /opt/render/project/rubies/ruby-2.7.4/lib/ruby/site_ruby/2.7.0/bundler/definition.rb:484:in `materialize’: Could not find nokogiri-1.12.5-x86_64-linux in any of the sources (Bundler::GemNotFound)
Looks like a good amount of my environmental variables aren’t getting filled out correctly, which could be a cause of the issue. The following are blank on my staging environment when using printenv while they are working just fine in production:
GEM_ROOT
RUBY_VERSION
RUBY_ENGINE
RUBY_ROOT
ruby_dir
It worked for me, but also I just needed to activate require "sprockets/railtie" on config/application.rb and add app/assets/config/manifest.js empty file.