我正在尝试使用Warbler
从我的Rails项目创建war文件。
这是我的Gemfile:
source 'https://rubygems.org'
ruby '1.9.3', :engine => 'jruby', :engine_version => '1.7.4'
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '4.0.0'
# Use mysql as the database for Active Record
#gem 'mysql2'
gem 'jdbc-mysql'
gem 'activerecord-jdbcmysql-adapter'
# Use SCSS for stylesheets
gem 'sass-rails', '~> 4.0.0'
# Use Uglifier as compressor for JavaScript assets
gem 'uglifier', '>= 1.3.0'
# Use CoffeeScript for .js.coffee assets and views
gem 'coffee-rails', '~> 4.0.0'
# See https://github.com/sstephenson/execjs#readme for more supported runtimes
# gem 'therubyracer', platforms: :ruby
# Use jquery as the JavaScript library
gem 'jquery-rails'
gem 'jquery-ui-rails'
# Turbolinks makes following links in your web application faster. Read more: https://github.com/rails/turbolinks
gem 'turbolinks'
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
gem 'jbuilder', '~> 1.2'
group :doc do
# bundle exec rake doc:rails generates the API under doc/api.
gem 'sdoc', require: false
end
gem 'haml-rails'
gem 'chosen-rails'
gem "compass-rails", "~> 2.0.alpha.0"
gem 'twitter-bootstrap-rails'
gem 'less-rails'
#gem 'therubyracer'
gem 'therubyrhino'
gem 'rails-erd'
gem 'faker'
gem 'devise'
gem 'cancan'
gem 'kaminari'
gem 'paperclip'
gem 'remotipart', '~> 1.0'
gem 'cancan'
gem 'rails_admin'
gem 'puma'
gem 'rubyzip', :require => 'zip/zip'
gem 'warbler'
# Use ActiveModel has_secure_password
# gem 'bcrypt-ruby', '~> 3.0.0'
# Use unicorn as the app server
# gem 'unicorn'
# Use Capistrano for deployment
# gem 'capistrano', group: :development
# Use debugger
# gem 'debugger', group: [:development, :test]
gem 'gibberish'
# gem 'jquery-turbolinks'
gem "paper_trail", "~> 3.0.0.beta1"
应用程序在Puma服务器上成功运行(在添加warbler之前)。
我刚刚使用
安装了warbler gem install warbler
然后我跑了warble
。但我得到了错误:
LoadError: no such file to load -- zip/zip
require at org/jruby/RubyKernel.java:1054
(root) at /home/stever/.rvm/gems/jruby-1.7.4/gems/warbler-1.3.8/lib/warbler/jar.rb:8
require at org/jruby/RubyKernel.java:1054
(root) at /home/stever/.rvm/gems/jruby-1.7.4/gems/warbler-1.3.8/lib/warbler/task.rb:1
require at org/jruby/RubyKernel.java:1054
(root) at /home/stever/.rvm/gems/jruby-1.7.4/gems/warbler-1.3.8/lib/warbler/task.rb:11
require at org/jruby/RubyKernel.java:1054
(root) at /home/stever/.rvm/gems/jruby-1.7.4/gems/warbler-1.3.8/lib/warbler.rb:1
load at org/jruby/RubyKernel.java:1073
(root) at /home/stever/.rvm/gems/jruby-1.7.4/gems/warbler-1.3.8/lib/warbler.rb:35
eval at org/jruby/RubyKernel.java:1093
(root) at /home/stever/.rvm/gems/jruby-1.7.4/bin/ruby_noexec_wrapper:14
然后我尝试将其添加到Gemfile中,如上所述。即使这样我也会收到错误。我现在也无法启动我的Puma服务器。
我确实安装了rubyzip。