Add Docker Delegated Consistency to Volume #1046
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
ISSUE: Performance for Docker runs using
sam local start-api
on Mac is horrible. I benchmarked requiring a large Ruby application at ~45seconds.FIX: Resolve Docker on Mac performance issues by allowing the project folder to be mounted as both "read only" (current behavior) and "delegated". The docs for Docker mention that a comma-separated list is an allowed value. Hence I maintained the
ro
mode and simply addeddelegated
to the list. Doc: https://docs.docker.com/v17.09/engine/admin/volumes/volumes/Please see this article for a description of the new option added. https://docs.docker.com/docker-for-mac/osxfs-caching/. If tests pass, I assume this option being added is a noop for non Mac platforms.