How to build task 'assets:precompile'

后端 未结 5 1982
不知归路
不知归路 2020-12-25 11:00

I\'m getting that error on my production server, and can\'t figure out why. It happens when running this command:

bundle exec rake assets:precompile RAILS_EN         


        
5条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-12-25 11:44

    I know this is an old post but I thought it might help someone (probably my future self) if I added this to the answers.

    add to Capfile (or deploy.rb)

    load 'deploy/assets'
    

    add this to application.rb

    require 'sprockets/railtie'
    

提交回复
热议问题