Overview
Mounting in Docker for Mac is slow. npm and other operations are painfully slow. This is a memo.
Cause
Refer to the comments from Docker staff. (See the middle section of the linked page)
Docker - File access in mounted volumes extremely slow, CPU bound
It seems related to the file system API of MacOS.
Solutions
- Use Windows or Linux
- docker-sync
- Set up a virtual environment built on an OS different from MacOS (like Vagrant)
- Utilize options like cached, delegated, consistent (
Docker - Performance tuning for volume mounts (shared filesystems))
Thoughts
I feel like I want to use Linux.