3 ms·
BTW, copying the entire app to a new directory did begin to take a while after a couple years, and I never got around to solving that. However, I believe it's q
by aasasd 7y ago
BTW, copying the entire app to a new directory did begin to take a while after a couple years, and I never got around to solving that. However, I believe it's quite possible to implement COW: hardlink the hell out of the current version, then beat rsync into replacing differing files instead of updating them in-place. The hardlinking part could be done before the deployment even begins—or you could copy the files instead of hardlinking to avoid altering them accidentally.
Or could probably just use overlayfs or something like that.
Note that, while containers can give you COW, they shouldn't really be necessary for the files of the app. And with php-fpm, changing the app dir is faster than restarting containers: it's actually done via changing the Nginx config.
- arpa 7y agoHmmm... restarting container is usually on par with changing directory speed (i.e. there is no perceivable difference), unless you do some heavy lifting in your entrypoint which you shouldn't, at least in prod. We also used to do a symlink method, but proper kubernetes ci/cd setup is so much more better.