Docker for mac use hyperkit vm
just like hyperv
on windows10, the settings could be in some place like next:
/Users/<username>/Library/Group Containers/group.com.docker/settings.json
The default value is:
{
"dockerAppLaunchPath" : "/Applications/Docker.app",
"proxyHttpMode" : "system",
"buildNumber" : "31259",
"cpus" : 2,
"diskSizeMiB" : 61035,
"version" : "2.0.0.3",
"settingsVersion" : 1,
"channelID" : "stable",
"memoryMiB" : 2048,
"displayedWelcomeMessage" : true,
"displayedWelcomeWhale" : true,
"linuxDaemonConfigCreationDate" : "2019-06-26 02:32:30 +0000",
"diskPath" : "Library/Containers/com.docker.docker/Data/vms/0/Docker.qcow2"
}
So, you can use command to modify the value you want to change, next is an example to change memory to 3072M, or just use any editor to directly modify the value:
sed -i 's/"memoryMiB".*/"memoryMiB" : 3072,/g' /Users/`id -un`/Library/Group\ Containers/group.com.docker/settings.json
Finally, in command restart the docker as next:
osascript -e 'quit app "Docker"' && open -a Docker