Comments (6)
Of course Googling and going through GH issues leads me to a @timkelty thread...
Just wanted to chime in that in testing my specific setup of Docker for Mac + Mutagen + Craft Docker images with opcache
enabled during local dev, enabling opcache.validate_timestamps
per @jasonmccallister's thread here seems to be the best of both worlds re: speed vs seeing things immediately.
from docker.
@timkelty we could add a build argument to the dev build to disable that by default. When I'm developing I typically don't run into issues with opcache being enabled, in fact I have been bitten by deploying to an environment with opcache enabled and my code not working as expected (aka needed a refresh).
Happy to take a PR that ads the ARG and ENV for disabling opcache on dev though: https://github.com/craftcms/docker/blob/7.4/dev.Dockerfile
from docker.
Hmmm…I wonder why I got bitten by it so quickly?
Right away, no changes were reflected unless I did an opcache_reset()
.
Maybe it was because I was exclusively testing my entry point index.php
?
Not sure, but it was the first time I ran into it locally.
Also – it looks like my concern about build cache only applies when the ARG is used in a RUN: https://docs.docker.com/engine/reference/builder/#impact-on-build-caching
from docker.
I'm fairly sure I got bitten by OPCACHE being enabled on the dev image too. Even with Craft in devMode I had to restart the app container to see changes I'd made to the twig templates.
from docker.
I'm going to look at updating the arg to disable opcache on dev images.
I still think it is useful to have a separate development image that is only used in a docker-compose.yaml
file. The build steps each team takes vary so much that it would be nice to have a single image that is more flexible, but could lead to a bad configuration going into a production environment.
from docker.
👯♂️
from docker.
Related Issues (20)
- Expat security vulnerability HOT 6
- Security vulnerabilities reported in container HOT 4
- Imagick does not limit its memory usage, can crash php-fpm processes HOT 3
- Python security vulnerability HOT 1
- libtasn1 vulnerability reported HOT 2
- High vulnerability reported in `libde265` HOT 2
- Dev image performance is 10x slower than prod HOT 3
- High vulnerability reported in `tar-1.34-r0` HOT 1
- CVEs HOT 5
- Make Nginx document root configurable
- New CVEs HOT 14
- Upgrade pgdump to 15.3 HOT 2
- github-tag-action runs too often HOT 2
- Supervisord INFO reaped unknown pid HOT 1
- Update Alpine so CVE-2023-38545 can be resolved HOT 2
- README Example for database tools to enable exports/backups needs to be updated
- Add PHP 8.3 images HOT 1
- nginx: [alert] could not open error log file HOT 1
- Deprecating this repo HOT 1
- Moving cleanup to dramatically reduce image size HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from docker.