I never managed to make "bundle" update the collection under Tomcat. It always updated the collection under Ruby.
But I could use "gem install" to add gems under Tomcat.
So I tried to supply the missing pieces. (Probably too new.)
(If I try again to make jobsworth run under Windows, I think I will try an older version of Ruby.)
Tomcat said: "Could not find gem 'sass-rails java' in any of the gem sources listed in your Gemfile. Run `bundle install` to install missing gems."
So I did: gem install sass-rails -include-dependencies --install-dir D:\apache-tomcat-9.0.14\webapps\ROOT\WEB-INF\gems
Tomcat said: "Could not find gem ..."
So I did: gem install i18n -include-dependencies --install-dir D:\apache-tomcat-9.0.14\webapps\ROOT\WEB-INF\gems
(I had 0.7.0.) (It added the latest 1.5.3. That did not clear the error.)
So I did: gem install i18n -v '0.9.5' ...
(It added the needed 0.905.)
I didn't need 1.5.3, so I did: gem uninstall i18n -v '1.5.3' ...
(It didn't uninstall 1.5.3. It said "Gem 'i18n' is not installed".)
Tomcat said: "Could not find gem ..."
So I did: gem install activesupport -v '4.2.11' ...
Tomcat said: "Could not find nokogiri-1.10.1-java in any of the sources"
(I had nokogiri-1.6.8-java.)
So I did: gem install nokogiri -v '1.10.11' ...
gem said: "ERROR: Could not find a valid gem 'nokogiri' (= 1.10.11) in any repository ERROR: Possible alternatives: nokogiri" (WHAT? It can't not be there.)
So I did: gem install nokogiri --version '1.10.11'
gem said: ERROR: Could not find a valid gem 'nokogiri' (= 1.10.11) in any repository ..." (WHAT? It can't not be there.)
So I did: gem install nokogiri ...
gem said: "Successfully installed nokogiri-1.10.1-x64-mingw32" (it went into folder "nokogiri-1.10.1-x64-mingw32") (WHAT? It couldn't find it when I specified the version, but it found that exact version when I didn't specify!)
Tomcat said: "Could not find nokogiri-1.10.1-java in any of the sources" (still haven't fixed it.)
So I did: gem install nokogiri-1.10.11-java ... (I made a bad guess of the name format.)
gem said: "ERROR: Could not find a valid gem 'nokogiri-1.10.11-java' (>= 0) in any repository ..." (of course that failed.)
So I did: gem install nokogiri --platform java ....
gem said: "Successfully installed nokogiri-1.10.1" (it went into folder "nokogiri-1.10.1") (IT WORKED!) (but WHY does the folder name not include "-java"?)
Tomcat said: "Could not find nokogiri-1.10.1-java in any of the sources ..." (still haven't fixed it.)
So I did: gem install nokogiri --platform ruby (another guess)
gem said: "Done installing documentation for after 0 seconds" (WHAT? Is it already installed? Does --platform ruby imply java or x64-mingw32?)
So I did: gem install nokogiri --platform ruby --version '1.10.11'
gem said: "ERROR: Could not find a valid gem 'nokogiri' (= 1.10.11) in any repository ERROR: Possible alternatives: nokogiri" (same impossible absence)
Tomcat said: "Could not find nokogiri-1.10.1-java in any of the sources ..." (still haven't fixed it.)
I fooled with: gem install bundler
I fooled with: bundle lock --add-platform ruby
and numerous other attempted hacks.
Some gave illusions of progress, and then it got stuck somewhere else.
Too many dead ends.
Tomcat still says: "Could not find nokogiri-1.10.1-java in any of the sources ..." (still haven't fixed it.)
The webpage at
http://localhost:8080/ still says: "exit from org/jruby/RubyKernel.java:714:in `exit' from org/jruby/RubyKernel.java:677:in `exit' from D:/apache-tomcat-9.0.14/webapps/ROOT/WEB-INF/gems/gems/bundler-2.0.1/lib/bundler/setup.rb:17:in `<main>' from org/jruby/RubyKernel.java:956:in `require' from uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:1:in `(root)' from uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:133:in `<main>' from org/jruby/RubyKernel.java:956:in `require' from D:/apache-tomcat-9.0.14/webapps/ROOT/WEB-INF/config/boot.rb:6:in `(root)' from uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:1:in `(root)' from uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:55:in `require' from uri:classloader:/jruby/rack/rails/environment3.rb:23:in `<main>' "
My next stab at hosting jobsworth will be the install script, on a Linux (in a virtual machine). I wonder how that will blow up - maybe any safe, current Linux will be too new.
(If I try again to make jobsworth run under Windows, I think I will try an older version of Ruby.) (Or maybe learn how to "rebuild" it with an added require. I wonder how that will blow up - maybe an obvious update of one outdated gem will blow it away - or create a latent defect.)