

For example when a developer uses the Symfony PHP framework, edits the source code and then reloads the page in the browser, the web-server in the container must re-read many PHP files stored on the host. Performance is vital when application source code is shared between the host and container. This is where file sharing performance is absolutely critical. Changes made to files located on the host system must propagate quickly and reliably to the container file system for the developer to optimize productivity and have a good user experience. This allows the developer to edit their source code, save the changes and immediately see the results in their browser. The source code is shared between the host and the container by using Docker volumes, with a command like the following:ĭocker run -v /Users/me:/code -p 8080:8080 my-symfony-app During testing with our amazing macOS community of users, we have observed that these changes have reduced the time taken to complete filesystem operations by up to 98%.įor developers, these incredible gains in speed mean less time waiting for filesystem operations to complete (or building project-specific workarounds to improve performance) and more time focusing on innovation! Understanding common developer workflowsĪ common developer workflow when using technologies like Symfony or React is to edit source code located on the macOS host while running the app itself in a Docker container. Secondly, improvements have been made to the way that files are synced between the macOS host and Docker VM.

Firstly, developers now have the option of using a new experimental file sharing implementation called virtiofs (the current default is gRPC-FUSE).

The 4.6 release of Docker Desktop for Mac contains a number of changes that drastically improve file sharing performance for macOS users.
