config.assets.compile=true in Rails production, why not?

前端 未结 7 1750
闹比i
闹比i 2020-11-22 07:17

The default Rails app installed by rails new has config.assets.compile = false in production.

And the ordinary way to do things is to run

7条回答
  •  失恋的感觉
    2020-11-22 08:13

    It won't be the same as precompiling, even after that first hit: because the files aren't written to the filesystem they can't be served directly by the web server. Some ruby code will always be involved, even if it just reads a cache entry.

提交回复
热议问题