Preface: I understand that Docker for Mac has file syncing performance issues, but everything I've read about the issues is related to slow read access. I don't really have a problem with slow read access. My problem is that updates I make to files on my host machine can sometimes take 10+ seconds to update on the running container!
Here's my docker-compose file:
version: '2'
services:
ps-cms:
image: [obfuscated]
container_name: ps-cms
mem_limit: 2048M
ports:
- "9080:80"
- "9443:443"
volumes:
- .:/var/www/html/site:cached
- ./xdebug.ini:/etc/php/conf.d/docker-php-ext-xdebug.ini
environment:
- MYSQL_HOST=ps-db
networks:
- connector
extra_hosts:
- "mysite.localhost:127.0.0.1"
ps-db:
image: mysql:5.6
container_name: ps-db
mem_limit: 512M
environment:
- MYSQL_ALLOW_EMPTY_PASSWORD=yes
ports:
- 33006:3306
networks:
- connector
networks:
connector:
Software:
Docker Engine: 18.03.1-ce Docker Compose: 1.21.1 Docker Machine: 0.14.0 PHP Storm: 2018.1
In the Docker for Mac preferences, under "file sharing", I removed everything there and just added my one project folder, since I heard that can affect performance.
Does anyone have advice on what could be causing this sync delay?
docker-composeversion 3. – Benyamin Jafari Jun 29 '18 at 07:08