小型手机网站建设,如何优化关键词搜索排名,设计公司企业网站详情,wordpress 加载中动画windows下DockerDesktop指定目录安装(重新安装)
因为DcokerDesktop占用内存较大, 并且拉去镜像后占用本地空间较多,所以建议安装时就更改默认安装路径和镜像存储路径
这里,展示了从下载到安装的过程:
首先下载DcokerDesktop;找到Docker Desktop Installer.exe 并重命名为 do…windows下DockerDesktop指定目录安装(重新安装)
因为DcokerDesktop占用内存较大, 并且拉去镜像后占用本地空间较多,所以建议安装时就更改默认安装路径和镜像存储路径
这里,展示了从下载到安装的过程:
首先下载DcokerDesktop;找到Docker Desktop Installer.exe 并重命名为 dockerdesk.exe , 并建议将其移动到全英文路径下(我这里放在了J:/dockerdesk.exe);阅读官方安装指南docker desktop从命令行安装install-from-the-command-line 按需要添加参数,更改默认安装目录. 可以看到, 文档中官方给出的命令行参数说明很详细;
可以在本地powershell中使用 如下方式查看dockerdesk.exe都有哪些参数: (记得重命名, .exe名称有空格,用cmd执行起来比较麻烦)
PS J:\ ./dockerdesk.exe --help
PS J:\
Installs Docker Desktopdockerdesk.exe install [--quiet] [--accept-license] [--backendwsl-2 | --backendhyper-v | --backendwindows] [--allowed-orgorg name]--quiet Suppresses information output when running the installer
--accept-license Accepts the Docker Subscription Service Agreement now, rather than requiring it to be accepted when the application is first run
--no-windows-containers Disables Windows containers integration
--allowed-orgorg name Requires the user to sign in and be part of the specified Docker Hub organization when running the application
--backendbackend name Selects the default backend to use for Docker Desktop, hyper-v, windows or wsl-2 (default)
--always-run-service Keep service always running, so regular users can switch to windows containers or hyper-v without being prompted for admin rights
--installation-dirpath Changes the default installation location (C:\Program Files\Docker\Docker)
--hyper-v-default-data-rootpath Changes the default hyper-v VM disk location
--windows-containers-default-data-rootpath Changes the default windows containers data root
--wsl-default-data-rootpath Changes the default wsl data location
--admin-settingsjson Used as admin settings for hardened desktop (needs to use --allowed-org and specify a business tier org)
--proxy-http-modemode HTTP Proxy mode, system (default) or manual
--override-proxy-httpURL URL of the HTTP proxy that must be used for outgoing HTTP requests
--override-proxy-httpsURL URL of the HTTP proxy that must be used for outgoing HTTPS requests
--override-proxy-excludehosts/domains Bypass proxy settings for these hosts domains, comma-separated list
--proxy-enable-kerberosntlm Enables Kerberos/NTLM proxy authentication要做什么? 我的需求是 指定 docker-desktop 安装位置(软件本体), 为 H:\program\DockerDesktop指定 docker-desktop-data 安装位置(本地镜像等存储路径,即为 Settings-Resources Advanced- Disk image location的路径),为H:\program\DockerDesktopWSL 编写命令行(用powershell在J:/dockerdesk.exe同级目录执行) 使用了如下参数 ./dockerdesk.exe install –accept-license --backendwsl-2 –installation-dir‘docker-desktop安装位置’ –wsl-default-data-root‘docker-desktop-data安装位置’ 命令执行前,请创建好 H:\program\DockerDesktopWSL H:\program\DockerDesktop这两个安装文件夹,不然可能出现意外的错误. 我使用的安装命令为: (使用powershell执行)
./dockerdesk.exe install --accept-license --backendwsl-2 --installation-dirH:\program\DockerDesktop --wsl-default-data-rootH:\program\DockerDesktopWSL 稍等片刻, 按照提示安装下一步next,安装完成.打开软件,查看安装设置无误: windows下DockerDesktop的安装位置迁移(不需要重新安装)
Win11 安装 Docker Desktop 和 WSL2 并进行安装位置迁移