Linux 机器 docker 部署 windows 容器
Linux machine with docker deploy windows container
我有一个 Linux 服务器,16GB 内存,安装了 docker 主机。我想在其上部署一个 Windows 服务器容器。可能吗?有人刚试过这个解决方案吗?
2019 年更新
正如 duct_tape_coder in 所述:
Microsoft has improved the network options for containers and now allows multiple containers per pod with improved namespace.
理论上(2015 年 10 月的原始答案):
在 Linux 主机上没有 "Windows container" 运行ning。
Linux 容器不会 运行 直接 在 Windows 服务器上,因为 it relies on system calls to a Linux kernel.
您当然可以通过虚拟机 运行 任何 Windows 机器上的那些 Linux 容器。
那就是docker toolbox will install.
会有 support for docker on Windows soon,但那是 Windows 个容器,而不是 Linux 个容器。
Update 2017: yes, LinuxKit allows to run a linux container through aa Hyper-V isolation wrapper on a Windows platform, through a minimal Linux OS built from linuxkit.
这仍然是相同的想法:linux 运行 在 Windows.
上的 VM 内
那不是部署在 Windows 服务器上的 Linux 服务器:仅部署在 Linux 服务器内 运行ning 在 Windows.[=19= 上的虚拟机中]
实际上...(2016 年 12 月更新)
参见“Linux and Windows, living together, total chaos! (OK, Kubernetes 1.5)”
Kubernetes 1.5 includes alpha support for both Windows Server Containers, a shared kernel model similar to Docker, and Hyper-V Containers, a single-kernel model that provides better isolation for multi-tenant environments (at the cost of greater latency).
The end result is the ability to create a single Kubernetes cluster that includes not just Linux nodes running Linux containers or Windows nodes running Windows containers, but both side by side, for a truly hybrid experience.
For example, a single service can have PODs using Windows Server Containers and other PODs using Linux containers.
但是:
Though it appears fully functional, there do appear to be some limitations in this early release, including:
- The Kubernetes master must still run on Linux due to dependencies in how it’s written. It’s possible to port to Windows, but for the moment the team feels it’s better to focus their efforts on the client components.
- There is no native support for network overlays for containers in windows, so networking is limited to L3. (There are other solutions, but they’re not natively available.)
The Kubernetes Windows SIG is working with Microsoft to solve these problems, however, and they hope to have made progress by Kubernetes 1.6’s release early next year.
- Networking between Windows containers is more complicated because each container gets its own network namespace, so it’s recommended that you use single-container pods for now.
- Applications running in Windows Server Containers can run in any language supported by Windows. You CAN run .NET applications in Linux containers, but only if they’re written in .NET Core. .NET core is also supported by the Nano Server operating system, which can be deployed on Windows Server Containers.
我有一个 Linux 服务器,16GB 内存,安装了 docker 主机。我想在其上部署一个 Windows 服务器容器。可能吗?有人刚试过这个解决方案吗?
2019 年更新
正如 duct_tape_coder in
Microsoft has improved the network options for containers and now allows multiple containers per pod with improved namespace.
理论上(2015 年 10 月的原始答案):
在 Linux 主机上没有 "Windows container" 运行ning。
Linux 容器不会 运行 直接 在 Windows 服务器上,因为 it relies on system calls to a Linux kernel.
您当然可以通过虚拟机 运行 任何 Windows 机器上的那些 Linux 容器。
那就是docker toolbox will install.
会有 support for docker on Windows soon,但那是 Windows 个容器,而不是 Linux 个容器。
Update 2017: yes, LinuxKit allows to run a linux container through aa Hyper-V isolation wrapper on a Windows platform, through a minimal Linux OS built from linuxkit.
这仍然是相同的想法:linux 运行 在 Windows.
上的 VM 内
那不是部署在 Windows 服务器上的 Linux 服务器:仅部署在 Linux 服务器内 运行ning 在 Windows.[=19= 上的虚拟机中]
实际上...(2016 年 12 月更新)
参见“Linux and Windows, living together, total chaos! (OK, Kubernetes 1.5)”
Kubernetes 1.5 includes alpha support for both Windows Server Containers, a shared kernel model similar to Docker, and Hyper-V Containers, a single-kernel model that provides better isolation for multi-tenant environments (at the cost of greater latency).
The end result is the ability to create a single Kubernetes cluster that includes not just Linux nodes running Linux containers or Windows nodes running Windows containers, but both side by side, for a truly hybrid experience.
For example, a single service can have PODs using Windows Server Containers and other PODs using Linux containers.
但是:
Though it appears fully functional, there do appear to be some limitations in this early release, including:
- The Kubernetes master must still run on Linux due to dependencies in how it’s written. It’s possible to port to Windows, but for the moment the team feels it’s better to focus their efforts on the client components.
- There is no native support for network overlays for containers in windows, so networking is limited to L3. (There are other solutions, but they’re not natively available.)
The Kubernetes Windows SIG is working with Microsoft to solve these problems, however, and they hope to have made progress by Kubernetes 1.6’s release early next year.- Networking between Windows containers is more complicated because each container gets its own network namespace, so it’s recommended that you use single-container pods for now.
- Applications running in Windows Server Containers can run in any language supported by Windows. You CAN run .NET applications in Linux containers, but only if they’re written in .NET Core. .NET core is also supported by the Nano Server operating system, which can be deployed on Windows Server Containers.