Assets would not Compile in production
<p>I've been trying to precompile assets in production but it just keeps breaking. </p>

<p>I tried </p>

<pre><code>  RAILS_ENV=production rake assets:precompile
</code></pre>

<p>and got:</p>

<pre><code>I, [2016-06-22T15:59:02.648161 #1680]  INFO -- : Writing /Users/johndoe/Documents/be/Chak/public/assets/application-3b7afc621ec8ef5d713fe45400021fdd80041418493b774e248da6a1fcfc4052.js
I, [2016-06-22T15:59:02.939980 #1680]  INFO -- : Writing /Users/johndoe/Documents/be/Chak/public/assets/application-3b7afc621ec8ef5d713fe45400021fdd80041418493b774e248da6a1fcfc4052.js.gz
rake aborted!
NoMethodError: undefined method `[]' for nil:NilClass

Tasks: TOP =&gt; assets:precompile
(See full trace by running task with --trace)
JohnDoesMBP:Chak johndoe$ RAILS_ENV=production rake assets:precompile --trace
** Invoke assets:precompile (first_time)
** Invoke assets:environment (first_time)
** Execute assets:environment
** Invoke environment (first_time)
** Execute environment
** Execute assets:precompile
rake aborted!
NoMethodError: undefined method `[]' for nil:NilClass
/Users/johndoe/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/sprockets-3.5.2/lib/sprockets/sass_processor.rb:278:in `sprockets_context'
/Users/johndoe/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/sprockets-3.5.2/lib/sprockets/sass_processor.rb:124:in `asset_path'
/Users/johndoe/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/sprockets-3.5.2/lib/sprockets/sass_processor.rb:200:in `font_path'
/Users/johndoe/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/sass-3.4.21/lib/sass/script/tree/funcall.rb:140:in `_perform'
</code></pre>

<p>Anyone have an idea, what's wrong?</p>

<p>My production.rb file looks like this:</p>

<pre><code>config.serve_static_files = true
config.assets.js_compressor = :uglifier
config.assets.compile = true
config.assets.digest = true
config.log_level = :debug
</code></pre>

<p>Any help would be appreciated. Thanks in advance!</p>

<p>Gemfile:</p>

<pre><code>ruby '2.2.2'
gem 'figaro', '~&gt; 1.0.0'
gem 'rails_12factor', group: :production
gem 'puma'
gem 'nifty-generators', :group =&gt; :development
gem 'table_print'
gem 'omniauth-facebook'
gem 'omniauth-twitter'
gem 'omniauth-google'
gem 'devise'
gem 'devise_invitable'
gem 'carrierwave', :github =&gt; 'satoruk/carrierwave', :ref =&gt; '43179f94d6a4e62f69e812f5082d6447c9138480'
gem 'rmagick', require: false
gem 'rails', '4.2.4'
gem 'pg'
gem 'bootstrap-sass', '~&gt; 3.3.6'
gem 'sass-rails', '~&gt; 5.0'
gem 'uglifier', '&gt;= 1.3.0'
gem 'coffee-rails', '~&gt; 4.1.0'
gem 'jquery-rails'
gem 'turbolinks'
gem 'jbuilder', '~&gt; 2.0'
gem 'sdoc', '~&gt; 0.4.0', group: :doc
gem 'activemerchant'
gem 'paypal-sdk-rest'
gem 'paypal-sdk-adaptivepayments'

group :development, :test do
  gem 'byebug'
  gem 'quiet_assets'
  gem 'pry-rails'
  gem 'thin'
end

group :development do
  gem 'web-console', '~&gt; 2.0'
  gem 'spring'
end
</code></pre>