-
-
Notifications
You must be signed in to change notification settings - Fork 196
[Question] Isn't making /var/cache read-only ironic? #144
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
Comments
@lukasz-zaroda I understood this as "var/cache/" is read-only for you, dear developer, but it's a read-write dir for Symfony. But as you said, the "read-write" part is tricky, because you only write once, during app bootstrap/compilation, and read that forever. So, creating a different dir for this, as you propose, could make sense. |
Maybe something could be done during container compilation: separate "forever" directories and "maybe could be updated" ones. For example, templates can be compiled and saved by the templates cache warmer and saved forever, because it finds every template in your app, and you're never likely to create templates on-the-fly and save them in cache at runtime. Contrary to application cache (the default Is there any statistics/documentation about the things that are warmed-up by Symfony and that are 100% sure to be fixed in time (until next deploy)? |
Closing as this is not related to Flex and @nicolas-grekas referenced an issue discussing the matter on symfony/symfony. |
I was making myself up to date with Symfony 4, and here Fabien wrote this:
First thought:
I didn't find anyone complaining so I decided to write this. Isn't it a problem? By making
var/cache
read-only aren't we introducing a new, important type of code - compiled code, which deserves its own directory, likebuild
for example? Maybe that directory could also contain CSS compiled from SASS in the long run and such? This directory could be read-only and be build only once before deploying the app.I'm not suggesting that it should be the case, just asking what the community thinks, because I'm curious.
The text was updated successfully, but these errors were encountered: