ruby - Getting error while deploying rails app on heroku -
i m getting error while deploying app github on heroku ...
build log -->
-----> ruby app detected -----> compiling ruby/rails -----> using ruby version: ruby-2.2.0 -----> installing dependencies using bundler 1.11.2 running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin -j4 --deployment fetching gem metadata https://rubygems.org/........... fetching version metadata https://rubygems.org/... fetching dependency metadata https://rubygems.org/.. installing json 1.8.3 native extensions installing i18n 0.7.0 installing rake 10.5.0 installing minitest 5.8.3 installing thread_safe 0.3.5 installing builder 3.2.2 installing erubis 2.7.0 installing mini_portile2 2.0.0 installing rack 1.6.4 installing mime-types 2.99 installing sass 3.4.21 installing thor 0.19.1 installing coffee-script-source 1.10.0 installing formtastic_i18n 0.6.0 using bundler 1.11.2 installing arel 6.0.3 installing execjs 2.6.0 installing concurrent-ruby 1.0.0 installing tilt 1.4.1 installing bcrypt 3.1.7 native extensions installing cancan 1.6.10 installing orm_adapter 0.5.0 installing multi_json 1.11.2 installing request_store 1.3.0 installing puma 2.16.0 native extensions installing rails_serve_static_assets 0.0.4 installing rails_stdout_logging 0.0.4 installing tzinfo 1.2.2 installing rack-test 0.6.3 installing nokogiri 1.6.7.1 native extensions installing warden 1.2.6 installing rdoc 4.2.1 installing mail 2.6.3 installing bourbon 4.2.7 installing coffee-script 2.4.1 installing uglifier 2.5.3 installing autoprefixer-rails 6.3.1 installing sprockets 3.5.2 installing rails_12factor 0.0.2 installing sdoc 0.4.0 installing activesupport 4.2.2 installing bootstrap-sass 3.3.6 installing rails-deprecated_sanitizer 1.0.3 installing globalid 0.3.6 installing arbre 1.0.3 installing activemodel 4.2.2 installing jbuilder 2.2.3 installing pundit 1.1.0 installing activejob 4.2.2 installing activerecord 4.2.2 installing polyamorous 1.3.0 installing rails-dom-testing 1.0.7 installing loofah 2.0.3 installing rails-html-sanitizer 1.0.2 installing actionview 4.2.2 installing actionpack 4.2.2 installing actionmailer 4.2.2 installing railties 4.2.2 installing formtastic 3.1.4 installing has_scope 0.6.0 installing sprockets-rails 3.0.0 installing kaminari 0.16.3 installing ransack 1.7.0 installing draper 2.1.0 installing coffee-rails 4.1.0 installing responders 2.1.1 installing jquery-ui-rails 5.0.5 installing jquery-rails 4.0.3 installing rails 4.2.2 installing turbolinks 2.3.0 installing sass-rails 5.0.2 installing inherited_resources 1.6.0 installing devise 3.5.6 installing activeadmin 1.0.0.pre2 bundle complete! 24 gemfile dependencies, 74 gems installed. gems in groups development , test not installed. bundled gems installed ./vendor/bundle. post-install message rdoc: depending on version of ruby, may need install ruby rdoc/ri data: <= 1.8.6 : unsupported = 1.8.7 : gem install rdoc-data; rdoc-data --install = 1.9.1 : gem install rdoc-data; rdoc-data --install >= 1.9.2 : nothing do! yay! bundle completed (23.34s) cleaning bundler cache. sh: 2: syntax error: unterminated quoted string sh: 2: syntax error: unterminated quoted string ! ! not detect rake tasks ! ensure can run `$ bundle exec rake -p` against app ! , using production group of gemfile. ! rake aborted! ! bundler::gemrequireerror: there error while trying load gem 'activeadmin'. ! /tmp/build_e5688395917c72f2956d14c05dd2fdf5/nischaynamdev-hostel_mess_pay-a993b86d6645abbdfb41cb6de99c6900648d588f/vendor/bundle/ruby/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:80:in `rescue in block (2 levels) in require' ! /tmp/build_e5688395917c72f2956d14c05dd2fdf5/nischaynamdev-hostel_mess_pay-a993b86d6645abbdfb41cb6de99c6900648d588f/vendor/bundle/ruby/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:76:in `block (2 levels) in require' ! /tmp/build_e5688395917c72f2956d14c05dd2fdf5/nischaynamdev-hostel_mess_pay-a993b86d6645abbdfb41cb6de99c6900648d588f/vendor/bundle/ruby/2.2.0/gems/bundler-1.11
my production.rb file :
rails.application.configure # settings specified here take precedence on in config/application.rb. # code not reloaded between requests. config.cache_classes = true config.force_ssl = true config.serve_static_assets = true # eager load code on boot. eager loads of rails , # application in memory, allowing both threaded web servers # , relying on copy on write perform better. # rake tasks automatically ignore option performance. config.eager_load = true # full error reports disabled , caching turned on. config.consider_all_requests_local = false config.action_controller.perform_caching = true # enable rack::cache put simple http cache in front of application # add `rack-cache` gemfile before enabling this. # large-scale production use, consider using caching reverse proxy # nginx, varnish or squid. # config.action_dispatch.rack_cache = true # disable serving static files `/public` folder default since # apache or nginx handles this. config.serve_static_files = env['rails_serve_static_files'].present? # compress javascripts , css. config.assets.js_compressor = :uglifier # config.assets.css_compressor = :sass # not fallback assets pipeline if precompiled asset missed. config.assets.compile =true # asset digests allow set far-future http expiration dates on assets, # yet still able expire them through digest params. config.assets.digest = true # `config.assets.precompile` , `config.assets.version` have moved config/initializers/assets.rb # specifies header server uses sending files. # config.action_dispatch.x_sendfile_header = 'x-sendfile' # apache # config.action_dispatch.x_sendfile_header = 'x-accel-redirect' # nginx # force access app on ssl, use strict-transport-security, , use secure cookies. # config.force_ssl = true # use lowest log level ensure availability of diagnostic information # when problems arise. config.log_level = :debug # prepend log lines following tags. # config.log_tags = [ :subdomain, :uuid ] # use different logger distributed setups. # config.logger = activesupport::taggedlogging.new(sysloglogger.new) # use different cache store in production. # config.cache_store = :mem_cache_store # enable serving of images, stylesheets, , javascripts asset server. # config.action_controller.asset_host = 'http://assets.example.com' # ignore bad email addresses , not raise email delivery errors. # set true , configure email server immediate delivery raise delivery errors. # config.action_mailer.raise_delivery_errors = false # enable locale fallbacks i18n (makes lookups locale fall # i18n.default_locale when translation cannot found). config.i18n.fallbacks = true # send deprecation notices registered listeners. config.active_support.deprecation = :notify # use default logging formatter pid , timestamp not suppressed. config.log_formatter = ::logger::formatter.new # not dump schema after migrations. config.active_record.dump_schema_after_migration = false config.assets.precompile += %w( #{rails.root}/vendor/assets/stylesheets/active_admin.css.scss) config.assets.precompile += %w( #{rails.root}/vendor/assets/javascripts/active_admin.js.coffee) rails_env=production bundle exec rake assets:precompile config.action_mailer.raise_delivery_errors = true config.action_mailer.delivery_method = :smtp host = 'messpay.herokuapp.com' config.action_mailer.default_url_options = { host: host } actionmailer::base.smtp_settings = { :address => 'smtp.sendgrid.net', :port => '587', :authentication => :plain, :user_name => env['sendgrid_username'], :password => env['sendgrid_password'], :domain => 'heroku.com', :enable_starttls_auto => true end
rakefile
# add own tasks in files placed in lib/tasks ending in .rake, # example lib/tasks/capistrano.rake, , automatically available rake. require file.expand_path('../config/application', __file__) rails.application.load_tasks
gemfile:
source 'https://rubygems.org' gem 'jquery-ui-rails' gem 'activeadmin', '~> 1.0.0.pre2' gem 'devise' gem 'cancan' gem 'draper' gem 'pundit' gem 'rails', '4.2.2' gem 'bcrypt', '3.1.7' gem 'bootstrap-sass', '~> 3.3', '>= 3.3.6' gem 'sass-rails', '5.0.2' gem 'uglifier', '2.5.3' gem 'coffee-rails', '4.1.0' gem 'jquery-rails', '4.0.3' gem 'turbolinks', '2.3.0' gem 'jbuilder', '2.2.3' gem 'sdoc', '0.4.0', group: :doc group :development, :test gem 'byebug', '3.4.0' gem 'web-console', '2.0.0.beta3' gem 'spring', '1.1.3' end group :test gem 'minitest-reporters', '~> 1.1', '>= 1.1.7' gem 'mini_backtrace', '0.1.3' gem 'guard-minitest', '2.3.1' end group :production gem 'rails_12factor', '0.0.2' gem 'puma', '~> 2.16' end
i have tried of precompiled command options can check production.rb build logs showing problem in active admin gem !
help me plz thxx
take @ gem file. appears have issue attempting load gem activeadmin production environment, start there, possibly upload view.
**after reviewing gemfile... think may ok.
so i'm thinking change config.assets.compile =true
config.assets.compile = true
add space in case causing problem. run bundle exec rake -p
suggests in error itself. , try rake assets:precompile
, see if solves problem. need run heroku run rake db:migrate
too. had problem before heroku myself.
Comments
Post a Comment