Merge pull request #11929 from docker/stephen-turner-patch-1

Add more filesharing tips
This commit is contained in:
Usha Mandya 2020-12-18 17:47:01 +00:00 committed by GitHub
commit 4a8f654e49
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 14 additions and 0 deletions

View File

@ -93,12 +93,21 @@ File share settings are:
bind mount (`-v`) feature. bind mount (`-v`) feature.
> Tips on shared folders, permissions, and volume mounts > Tips on shared folders, permissions, and volume mounts
>
* Share only the directories that you need with the container. File sharing
introduces overhead as any changes to the files on the host need to be notified
to the Linux VM. Sharing too many files can lead to high CPU load and slow
filesystem performance.
> >
* Shared folders are designed to allow application code to be edited * Shared folders are designed to allow application code to be edited
on the host while being executed in containers. For non-code items on the host while being executed in containers. For non-code items
such as cache directories or databases, the performance will be much such as cache directories or databases, the performance will be much
better if they are stored in the Linux VM, using a [data volume](../storage/volumes.md) better if they are stored in the Linux VM, using a [data volume](../storage/volumes.md)
(named volume) or [data container](../storage/volumes.md). (named volume) or [data container](../storage/volumes.md).
>
* If you share the whole of your home directory into a container, MacOS may
prompt you to give Docker access to personal areas of your home directory such as
your Reminders or Downloads.
> >
* By default, Mac file systems are case-insensitive while Linux is case-sensitive. * By default, Mac file systems are case-insensitive while Linux is case-sensitive.
On Linux, it is possible to create 2 separate files: `test` and `Test`, On Linux, it is possible to create 2 separate files: `test` and `Test`,

View File

@ -105,6 +105,11 @@ File share settings are:
bind mount (`-v`) feature. bind mount (`-v`) feature.
> Tips on shared folders, permissions, and volume mounts > Tips on shared folders, permissions, and volume mounts
>
* Share only the directories that you need with the container. File sharing
introduces overhead as any changes to the files on the host need to be notified
to the Linux VM. Sharing too many files can lead to high CPU load and slow
filesystem performance.
> >
* Shared folders are designed to allow application code to be edited on the host while being executed in containers. For non-code items * Shared folders are designed to allow application code to be edited on the host while being executed in containers. For non-code items
such as cache directories or databases, the performance will be much better if they are stored in such as cache directories or databases, the performance will be much better if they are stored in