Reputation: 3850
I am using image_tag in Rails. Locally it resolves to /assets/image.img. On Heroku it resolves to /images/image.img.
I have the asset pipeline turned off (this project will eventually leave Rails).
How can I make local resolve the same as production?
Upvotes: 3
Views: 3669
Reputation: 3850
# config/environments/production.rb
...
config.assets.compile = true
...
This fixed my problem. I guess this has something to do with the pipeline being turned off. Any comments on this are appreciated to help my understanding.
Upvotes: 4
Reputation: 21559
what's your complete image_tag ?
does it use
image_tag(asset_path('image.img'))
, or
image_tag('image.img')
?
If you turned the asset pipeline off, I suggest you don't use the asset_path
form.
Upvotes: 4