Adding a shared path through command line
Question
Is there a way to add a shared path in Docker for Mac through the command line? (i.e. command or an API)
In 17.09.0 there is a new configuration file called settings.json available. There are already lot of settings in this file but the file sharing part is missing there. Any idea whether this will be added soon? This would be already a huge improvement for us where we need to provision automatically couple of mac nodes.
@nchazlett any feedback on this? Thanks!
Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale comment.
Stale issues will be closed after an additional 30d of inactivity.
Prevent issues from auto-closing with an /lifecycle frozen comment.
If this issue is safe to close now please do so.
Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. /lifecycle stale
The shared folders list displayed in the GUI can also be edited in ~/Library/Group Containers/group.com.docker/settings.json.
If the user has already modified shared folders, the "filesharingDirectories" array will already exist in settings.json, you can just add the path in the json array. If not modified, the array is not present in settings.json, but you can add it with your path in addition to the default ones :
"filesharingDirectories" : [
"/Users",
"/Volumes",
"/private",
"/tmp",
"/usr/local/share/dotnet/sdk/NuGetFallbackFolder"
]
Eventually the app needs restarting so that folders are visible in the VM.
Credit: @gtardif
Closed issues are locked after 30 days of inactivity. This helps our team focus on active issues.
If you have found a problem that seems similar to this, please open a new issue.
Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. /lifecycle locked