Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feedbin doesn't launch without AWS keys because of Fog #234

Open
wasmitnetzen opened this issue Dec 1, 2017 · 2 comments

Comments

Projects
None yet
2 participants
@wasmitnetzen
Copy link

commented Dec 1, 2017

I tried to start feedbin without an AWS key, but it aborts quite quickly with an error uninitialized constant CarrierWave::Storage::Fog (stacktrace below).

I guess this is because some fog settings are not initialized (see carrierwaveuploader/carrierwave/issues/2023) in config/initializers/carrierwave.rb when the AWS variables are not set. If I disable config.eager_load in my environment, it seems to work for now.

/var/lib/gems/2.3.0/gems/carrierwave-1.2.1/lib/carrierwave/uploader/configuration.rb:78:in

 `eval': uninitialized constant CarrierWave::Storage::Fog (NameError)
	from /var/lib/gems/2.3.0/gems/carrierwave-1.2.1/lib/carrierwave/uploader/configuration.rb:78:in `eval'
	from /var/lib/gems/2.3.0/gems/carrierwave-1.2.1/lib/carrierwave/uploader/configuration.rb:78:in `storage'
	from /var/lib/gems/2.3.0/bundler/gems/carrierwave_direct-a0bc3230e544/lib/carrierwave_direct/uploader.rb:14:in `block in <module:Uploader>'
	from /var/lib/gems/2.3.0/gems/activesupport-5.1.4/lib/active_support/concern.rb:120:in `class_eval'
	from /var/lib/gems/2.3.0/gems/activesupport-5.1.4/lib/active_support/concern.rb:120:in `append_features'
	from /opt/feedbin/app/uploaders/import_uploader.rb:2:in `include'
	from /opt/feedbin/app/uploaders/import_uploader.rb:2:in `<class:ImportUploader>'
	from /opt/feedbin/app/uploaders/import_uploader.rb:1:in `<top (required)>'
	from /var/lib/gems/2.3.0/gems/activesupport-5.1.4/lib/active_support/dependencies/interlock.rb:12:in `block in loading'
	from /var/lib/gems/2.3.0/gems/activesupport-5.1.4/lib/active_support/concurrency/share_lock.rb:149:in `exclusive'
	from /var/lib/gems/2.3.0/gems/activesupport-5.1.4/lib/active_support/dependencies/interlock.rb:11:in `loading'
	from /opt/feedbin/app/models/import.rb:2:in `<class:Import>'
	from /opt/feedbin/app/models/import.rb:1:in `<top (required)>'
	from /var/lib/gems/2.3.0/gems/activesupport-5.1.4/lib/active_support/dependencies/interlock.rb:12:in `block in loading'
	from /var/lib/gems/2.3.0/gems/activesupport-5.1.4/lib/active_support/concurrency/share_lock.rb:149:in `exclusive'
	from /var/lib/gems/2.3.0/gems/activesupport-5.1.4/lib/active_support/dependencies/interlock.rb:11:in `loading'
	from /var/lib/gems/2.3.0/gems/railties-5.1.4/lib/rails/engine.rb:476:in `block (2 levels) in eager_load!'
	from /var/lib/gems/2.3.0/gems/railties-5.1.4/lib/rails/engine.rb:475:in `each'
	from /var/lib/gems/2.3.0/gems/railties-5.1.4/lib/rails/engine.rb:475:in `block in eager_load!'
	from /var/lib/gems/2.3.0/gems/railties-5.1.4/lib/rails/engine.rb:473:in `each'
	from /var/lib/gems/2.3.0/gems/railties-5.1.4/lib/rails/engine.rb:473:in `eager_load!'
	from /var/lib/gems/2.3.0/gems/railties-5.1.4/lib/rails/engine.rb:354:in `eager_load!'
	from /var/lib/gems/2.3.0/gems/railties-5.1.4/lib/rails/application/finisher.rb:67:in `each'
	from /var/lib/gems/2.3.0/gems/railties-5.1.4/lib/rails/application/finisher.rb:67:in `block in <module:Finisher>'
	from /var/lib/gems/2.3.0/gems/railties-5.1.4/lib/rails/initializable.rb:30:in `instance_exec'
	from /var/lib/gems/2.3.0/gems/railties-5.1.4/lib/rails/initializable.rb:30:in `run'
	from /var/lib/gems/2.3.0/gems/railties-5.1.4/lib/rails/initializable.rb:59:in `block in run_initializers'
	from /usr/lib/ruby/2.3.0/tsort.rb:228:in `block in tsort_each'
	from /usr/lib/ruby/2.3.0/tsort.rb:350:in `block (2 levels) in each_strongly_connected_component'
	from /usr/lib/ruby/2.3.0/tsort.rb:431:in `each_strongly_connected_component_from'
	from /usr/lib/ruby/2.3.0/tsort.rb:349:in `block in each_strongly_connected_component'
	from /usr/lib/ruby/2.3.0/tsort.rb:347:in `each'
	from /usr/lib/ruby/2.3.0/tsort.rb:347:in `call'
	from /usr/lib/ruby/2.3.0/tsort.rb:347:in `each_strongly_connected_component'
	from /usr/lib/ruby/2.3.0/tsort.rb:226:in `tsort_each'
	from /usr/lib/ruby/2.3.0/tsort.rb:205:in `tsort_each'
	from /var/lib/gems/2.3.0/gems/railties-5.1.4/lib/rails/initializable.rb:58:in `run_initializers'
	from /var/lib/gems/2.3.0/gems/railties-5.1.4/lib/rails/application.rb:353:in `initialize!'
	from /opt/feedbin/config/environment.rb:5:in `<top (required)>'
	from /usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
	from /usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
	from /opt/feedbin/config.ru:3:in `block in <main>'
	from /var/lib/gems/2.3.0/gems/rack-2.0.3/lib/rack/builder.rb:55:in `instance_eval'
	from /var/lib/gems/2.3.0/gems/rack-2.0.3/lib/rack/builder.rb:55:in `initialize'
	from /opt/feedbin/config.ru:in `new'
	from /opt/feedbin/config.ru:in `<main>'
	from /var/lib/gems/2.3.0/gems/rack-2.0.3/lib/rack/builder.rb:49:in `eval'
	from /var/lib/gems/2.3.0/gems/rack-2.0.3/lib/rack/builder.rb:49:in `new_from_string'
	from /var/lib/gems/2.3.0/gems/rack-2.0.3/lib/rack/builder.rb:40:in `parse_file'
	from /var/lib/gems/2.3.0/gems/rack-2.0.3/lib/rack/server.rb:319:in `build_app_and_options_from_config'
	from /var/lib/gems/2.3.0/gems/rack-2.0.3/lib/rack/server.rb:219:in `app'
	from /var/lib/gems/2.3.0/gems/rack-2.0.3/lib/rack/server.rb:354:in `wrapped_app'
	from /var/lib/gems/2.3.0/gems/rack-2.0.3/lib/rack/server.rb:283:in `start'
	from /var/lib/gems/2.3.0/gems/rack-2.0.3/lib/rack/server.rb:148:in `start'
	from /var/lib/gems/2.3.0/gems/rack-2.0.3/bin/rackup:4:in `<top (required)>'
	from /usr/local/bin/rackup:22:in `load'
	from /usr/local/bin/rackup:22:in `<main>'`
@kylefrost

This comment has been minimized.

Copy link

commented Jan 17, 2018

How are you disabling config.eager_load?

@wasmitnetzen

This comment has been minimized.

Copy link
Author

commented Jan 17, 2018

Set config.eager_load = false in your config/environments/production.rb (or whichever environment you are using).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.