<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: CK Dev</title>
    <description>The latest articles on DEV Community by CK Dev (@psy_ck).</description>
    <link>https://dev.to/psy_ck</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3980804%2F61d44735-1198-468d-af72-f861998cf7d0.jpg</url>
      <title>DEV Community: CK Dev</title>
      <link>https://dev.to/psy_ck</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/psy_ck"/>
    <language>en</language>
    <item>
      <title>How to use docker if you are using AWS windows workspace</title>
      <dc:creator>CK Dev</dc:creator>
      <pubDate>Fri, 12 Jun 2026 08:17:16 +0000</pubDate>
      <link>https://dev.to/psy_ck/how-to-use-docker-if-you-are-using-aws-windows-workspace-2fll</link>
      <guid>https://dev.to/psy_ck/how-to-use-docker-if-you-are-using-aws-windows-workspace-2fll</guid>
      <description>&lt;p&gt;Hi everyone,&lt;/p&gt;

&lt;p&gt;I know many of you are struggling to get Docker working on your Windows AWS Workspace. One of the easiest and most reliable solutions is to connect your Workspace to a remote Docker host.&lt;/p&gt;

&lt;p&gt;An EC2 instance is probably the simplest and most practical option. If your Workspace is running in a private VPC, launch an EC2 instance in the same VPC and install Docker on it.&lt;/p&gt;

&lt;p&gt;Install Docker on Amazon Linux 2023:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;dnf update &lt;span class="nt"&gt;-y&lt;/span&gt;
&lt;span class="nb"&gt;sudo &lt;/span&gt;dnf &lt;span class="nb"&gt;install &lt;/span&gt;docker &lt;span class="nt"&gt;-y&lt;/span&gt;
&lt;span class="nb"&gt;sudo &lt;/span&gt;systemctl &lt;span class="nb"&gt;enable &lt;/span&gt;docker
&lt;span class="nb"&gt;sudo &lt;/span&gt;systemctl start docker
&lt;span class="nb"&gt;sudo &lt;/span&gt;usermod &lt;span class="nt"&gt;-aG&lt;/span&gt; docker ec2-user
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Verify the installation:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker version
docker run hello-world
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;From your AWS Workspace, create a Docker context that connects to the EC2 instance over SSH:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker context create workspace-ec2 &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--docker&lt;/span&gt; &lt;span class="s2"&gt;"host=ssh://ec2-user@&amp;lt;EC2_PRIVATE_IP&amp;gt;"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Switch to the new context:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker context use workspace-ec2
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Verify that Docker commands are being executed on the EC2 instance:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker ps
docker images
docker run hello-world

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can check the active context at any time:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker context &lt;span class="nb"&gt;ls&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To switch back:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker context use default
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Some benefits of this approach:&lt;/p&gt;

&lt;p&gt;No need to install or troubleshoot Docker Desktop on the Workspace.&lt;br&gt;
Containers run on EC2, so Workspace resources remain available for development tools.&lt;br&gt;
Better performance and scalability.&lt;br&gt;
Works well with VS Code, IntelliJ IDEA, and other Docker-enabled IDEs.&lt;br&gt;
Easy to upgrade by simply resizing the EC2 instance.&lt;/p&gt;

&lt;p&gt;I've been using this setup successfully, and it has been far more reliable than trying to run Docker directly on a Windows AWS Workspace. If anyone is interested, I can also share steps for configuring Docker Compose, VS Code Remote Development, and IntelliJ integration with the remote Docker host.&lt;/p&gt;

</description>
      <category>aws</category>
      <category>devops</category>
      <category>docker</category>
      <category>tutorial</category>
    </item>
  </channel>
</rss>
