<p>No, Network works different on both Operating System. So you cant</p>
<p>If your using Windows,</p>
<p><a href="https://learn.microsoft.com/en-us/windows/wsl/install#install-wsl-command" rel="nofollow noreferrer">To install WSL , Click Here</a></p>

CC BY-SA 4.0
2024-09-02T12:58:04.097Z
2024-09-02T12:58:04.097Z
playwithcode
<p>Containers run sharing resources from the host operating system in a controlled manner, so you can't run Windows containers on Linux as you can't run Linux containers on Windows.</p>
<p>That said, you <em>can</em> run Linux on Windows through WSL (Windows Subsystem from Linux) and then you can run a Linux container in it.</p>
<p>See: <a href="https://docs.docker.com/desktop/windows/wsl/" rel="nofollow noreferrer">Docker Desktop WSL 2 backend</a></p>

CC BY-SA 4.0
2022-08-12T20:25:23.063Z
2022-08-12T20:25:23.063Z
lpacheco
<p>what I'm trying to achieve is running a Linux(ubuntu LST) container inside a windows server 2019 OS.
The problem is that the windows OS runs as an AWS instance.</p>
<p>There have been problem for me trying to achieve this and I've been reading somewhat different opinions on the internet regarding whether or not it is possible. Some say it will be possible on a .metal instance which is bare metal. Currently I've been trying running it on a regular t3 instance with has virtualization type HVM.</p>
<p>To sum up my questions are:</p>
<ol>
<li>Is running a linux container on windows aws instance possible?</li>
<li>If yes, how?</li>
<li>If not, will it be possible on a bare metal instance?</li>
</ol>
<p>Please keep in mind that I need the container to run in a Windows environment due to multiple tasks the the OS needs to achieve (and I don't want multiple instances)</p>

CC BY-SA 4.0
2021-01-31T10:33:45.657Z
Have you tried setting up WSL2 on the windows ec2 instance? This might answer your requirement
Meir Gabay
<docker><amazon-web-services><linux><windows><virtualization>
Is running linux container on windows aws instance possible?
dor00012
# Is running linux container on windows aws instance possible?

(Asked by: username_0 on 2020-11-08)

what I'm trying to achieve is running a Linux(ubuntu LST) container inside a windows server 2019 OS.
The problem is that the windows OS runs as an AWS instance.

There have been problem for me trying to achieve this and I've been reading somewhat different opinions on the internet regarding whether or not it is possible. Some say it will be possible on a .metal instance which is bare metal. Currently I've been trying running it on a regular t3 instance with has virtualization type HVM.

To sum up my questions are:

1. Is running a linux container on windows aws instance possible?
2. If yes, how?
3. If not, will it be possible on a bare metal instance?

Please keep in mind that I need the container to run in a Windows environment due to multiple tasks the the OS needs to achieve (and I don't want multiple instances)

**Tags:** docker, amazon-web-services, linux, windows, virtualization

> **Comments:**
> **username_1**: Have you tried setting up WSL2 on the windows ec2 instance? This might answer your requirement  

---

## 2 answers

### Answer by username_2 on 2024-09-02. Score: 0

No, Network works different on both Operating System. So you cant

If your using Windows,

[To install WSL , Click Here](https://learn.microsoft.com/en-us/windows/wsl/install#install-wsl-command)


---

### Answer by username_3 on 2022-08-12. Score: 0

Containers run sharing resources from the host operating system in a controlled manner, so you can't run Windows containers on Linux as you can't run Linux containers on Windows.

That said, you *can* run Linux on Windows through WSL (Windows Subsystem from Linux) and then you can run a Linux container in it.

See: [Docker Desktop WSL 2 backend](https://docs.docker.com/desktop/windows/wsl/)


---

