是否可以 运行 Docker Windows 容器和编辑注册表 (regedit)?

Is it possible to run Docker Windows container and edit registry (regedit)?

我是 Docker 的新手,开始阅读官方文档并在互联网上搜索,但找不到最终答案。

我将描述我的情况,我有一个程序(在 C++ 中)作为服务在 Windows 10 Pro 上运行,并且在 windows 注册表 (regedit) 中有配置详细信息。 目前,如果我想调试它,我有一个 Win 10 Pro 虚拟机并使用远程调试。 我不在我的机器上调试它的原因是因为我的程序总是作为服务在我的机器上运行,我不想停止它,同样在 VM 上我 edit/change 注册表配置。

所以我在考虑使用 Docker 而不是 VM,但是出现了一个问题: 是否可以在没有 changing/harming 主机注册表的情况下编辑容器注册表?

在此先感谢您的帮助。

Microsoft Docs 中有提及:

While a container shares the host operating system's kernel, the container doesn't get unfettered access to it. Instead, the container gets an isolated–and in some cases virtualized–view of the system. For example, a container can access a virtualized version of the file system and registry, but any changes affect only the container and are discarded when it stops. To save data, the container can mount persistent storage such as an Azure Disk or a file share (including Azure Files).

https://docs.microsoft.com/en-us/virtualization/windowscontainers/about/#how-containers-work