user2439278
user2439278

Reputation: 1214

Windows Docker in Linux machine

Is it possible to create and run windows docker inside the Linux OS?

I got succeeded by running RHEL docker inside ubuntu OS. Need to know whether there is a possibility to run Windows docker inside any linux flavor OS

Upvotes: 1

Views: 207

Answers (2)

eiichi
eiichi

Reputation: 136

This question actually touches crucial difference between container and VM. VM is a whole machine (kernel, user space program, and devices like nic packed into one). On the other hand, container lacks kernel and it has to share host's kernel with other containers. That makes Docker container very much kernel dependent.

Because Linux from different distro (say CentOs and Ubuntu) share the same Linux Kernel, they could be on the same host. However, Linux kernel is not compatible to Windows applications, so this is not possible.

To make things a bit more complex, you can actually run Linux containers on Windows host though it is very much in experimental stage (yes, i know this is opposite of what you want...). Google LCOW (Linux Container On Windows). It is essentially hyper-v based VM running Linux kernel and container on top of Windows host. Having separate kernel means extra resource, but it opens for Windows admin to run Linux only container apps and Windows ones on the same network.

Upvotes: 1

VonC
VonC

Reputation: 1324248

I got succeeded by running RHEL docker inside ubuntu OS.

Both are based on a common Linux kernel, so any system call from the REHL docker can be addressed by the host (Ubuntu) kernel.

Need to know whether there is a possibility to run Windows docker inside any linux flavor OS

No, no more than you can run a Linux docker directly on Windows: Today, for Linux docker on Windows, you need a VirtualBox and a Linux host able to support docker.

Similarly, you would need a virtual machine on your Linux host, simulating the right OS (in your case, a Windows Server 2006 TP3 or more) in order to run a docker windows.


Update Dec. 2016: Kubernetes 1.5 might offer a solution: see "Linux machine with docker deploy windows container"

Upvotes: 3

Related Questions