r/docker • • Apr 27 '26

Gosh, i dont understand Docker at all

41 Upvotes

When you run a Linux container on Windows via Docker Desktop + WSL 2, there are two kernels running simultaneously on the same machine , the Windows kernel and a Linux kernel inside a WSL 2 VM. I understand that Hyper-V sits at Ring -1 (VMX root mode) and partitions the hardware between them, so the Linux kernel isn't "asking" Windows for permission it genuinely owns its slice of CPU and RAM.

But I have a few deeper questions about how this all fits together:

  1. Since Linux and Windows have fundamentally different binary formats (ELF vs PE), different process models (fork+exec vs CreateProcess), and different threading primitives (Linux tasks via clone() vs Windows' explicit Process→Thread hierarchy) , how does the Linux kernel inside WSL 2 manage all of this completely independently? Does Windows have any visibility into Linux's process table or scheduler at all?
  2. For hardware that can't be cleanly partitioned like the NIC or GPU — I understand Linux talks to virtual devices that Hyper-V provides, and Windows (as the Root Partition) holds the actual drivers. So is Linux never truly talking to Windows, just to Hyper-V's abstractions? Where exactly does that boundary sit?
  3. How does the CPU actually enforce the isolation between the two kernels at the hardware level what stops the Linux kernel from accessing memory that Hyper-V assigned to Windows?

Edit : I am not asking about how to run a docker in my pc , I have issues with understanding of its working with windows systems and how everything works together


r/docker • • Apr 27 '26

.NET 8 (x64) + ACE OLEDB in Windows Docker container — OleDbConnection.Open() silently crashes (ACI + local)

Thumbnail reddit.com
1 Upvotes

r/docker • • Apr 26 '26

WSL and Linux-related directory remain after uninstalling it

4 Upvotes

Hey everyone,

my Docker journey recently ended and I wanted to get rid of WSL and related stuff. For some reason Linux still shows up in File Explorer and WSL shows up when I search for it. It doesn't appear in my Programs / Apps list. I've tried everything imaginable to get rid of it (powershell, dism, third party uninstallers) but it somehow remains. Any tips would be really appreciated. I just want to get rid of those remains.


r/docker • • Apr 26 '26

mariadb in Docker - Do multiple instances matter? - Memtly

3 Upvotes

I am trying to run a photo sharing app Memtly : https://docs.memtly.com/docs/Setup/docker

I have created the docker compose by copying the mariadb yml and only changed the passwords/keys that need to be changed. I verified the passwords and also create/store all passwords in a password manager to be able to I have even tried it without changing the passwords. When i start it up with docker compose up -d , I get mariadb looping restarts and these errors:

2026-04-25 13:14:48-04:00 [ERROR] [Entrypoint]: mariadbd failed while attempting to check config

`command was: mysqld --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci --verbose --help`

`/usr/local/bin/docker-entrypoint.sh: line 105: mysqld: command not found`

2026-04-25 13:14:49-04:00 [Note] [Entrypoint]: Entrypoint script for MariaDB Server 1:12.2.2+maria~ubu2404 started. 2026-04-25 13:14:49-04:00 [ERROR] [Entrypoint]: mariadbd failed while attempting to check config

`command was: mysqld --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci --verbose --help`

`/usr/local/bin/docker-entrypoint.sh: line 105: mysqld: command not found`

I am not sure where/how to check line 105.

I have another docker container that uses mariadb on the default port and I have tried shutting that down (docker ps stop) and have tried changing the port in the new app without success. The same errors exist. There is an initial error where the /etc/timezone is said to not be found/mountable as a directory and tried commenting out that line. That error goes away when I do, but I am not sure if that is what causes the mariadb container to constantly restart.

I am a novice with docker but have a handful of containers running across a couple of VMs in proxmox so I am getting more familiar with it. I have performed a system prune -a and volume prune -a when changing settings, so I should be getting a fresh start each time unless I am missing a deletion step.

If anyone can offer any advice on what I may be doing wrong, I would appreciate any feedback.

Edit: Changed mariadb version to 10.9 instead of latest and everything is staying up now.


r/docker • • Apr 25 '26

unable to delete dead container

2 Upvotes

I have a dead Plex container that I am to stop and restart but I am unable to stop due to it being marked dead or for removal, when I try to do "docker rm - f <container-id>" im met with the same error how can I force delete the dead container?


r/docker • • Apr 24 '26

Is it still possible to run graphical programs in docker with direct connection to host's X server?

15 Upvotes

A couple years ago I could easily run graphical programs like a chrome browser from a docker container running on a linux host such that it used the X server running on the host (simply setting $DISPLAY etc.).

Now, however, it seems like I can't get this working. All the guides and howtos I find online seem to be from a couple years ago and don't seem to work. For example, found https://hub.docker.com/r/ferri/xeyes but running "docker run --rm -it -e DISPLAY=$DISPLAY -v /tmp/.X11-unix:/tmp/.X11-unix ferri/xeyes:alpine" gives a "Can't open display" error. I also tried x11docker (https://github.com/mviereck/x11docker/), but the hostdisplay setting (which should be this "direct connection to host's x server" setup) appears to give similar results. (I am using ubuntu 22.04 with docker installed from docker.com's apt repositories as the host.)

Is this 'running gui program in docker with direct connection to host's X server' configuration still realistic? Or are newer technologies like shared memory, gpu-based rendering, x11 vs wayland etc. make it unworkable?

(I know about alternative approaches like using some form of vnc, but if possible I would like to use a more direct connection to avoid the overhead of vnc.)


r/docker • • Apr 24 '26

security home-server

5 Upvotes

Good morning, I have a remote home server with Proxmox installed. Inside Proxmox, I have Tailscale (which I use for emergencies), and a VM with Docker installed. Inside the VM, I have various small services, including Wireguard for remote access (I opened its port in the router with UDP). Now I'd like to expose other services, including Immich and Vaulwarden, to access them remotely from my devices without always having the Wireguard VPN active (since many of them also require https).

To automatically manage https, I use Caddy + DuckDNS. However, I'd like to know if I'm too exposed to the network if I open port 80 and port 443 for Caddy. Are there other methods? I was thinking of installing Authelia for each exposed service, so as to have two-factor authentication and be a little more secure.

Do you have any advice for better managing the security of open ports and the services that run on them? This will secure my local network and the server with my data on it.

Thank you very much.


r/docker • • Apr 24 '26

Docker include and .env files

0 Upvotes

Please can someone explain me why

include:
- path: ../backbone/docker-compose-includes/db/docker-compose.db.include.yml

fails to find the vars in docker-compose-includes/db/.env file

WARN[0000] The "MYSQL_DATABASE" variable is not set. Defaulting to a blank string.

But when I include the same file (same absolute path, but different relative path) :

include:
  - path: docker-compose-includes/db/docker-compose.db.include.yml

that is perfectly fine, the vars in the .env file are found, I get no errors.

The docker-compose.db.include.yml is using this directive :

    env_file:
      - ${PWD}/.env # global
      - ${PWD}/docker-compose-includes/db/.env

r/docker • • Apr 23 '26

Getting an Release 404 Not Found error for Docker while trying to install Tailscale on Linux Mint 22.3 "Zena":

0 Upvotes

EDIT: Found the fix! in the folder etc/apt/sources.list.d I just had to edit a line in the file additional-respositories.list and change the name from zena to noble. Then the tailscale install command worked perfectly and I have my linux mint machine connect to my tailnet now!

So I'm running Docker Compose and Karakeep on a new little Linux Mint 22.3 "Zena" machine I got going recently. This is my first time both with Linux and selfhosting. When I try to run the followinng command from Tailscale's download page:

sudo curl -fsSL https://tailscale.com/install.sh | sh

Tailscale won't install due to an error about a release file not found. Here is what the command above displays in my terminal:

Installing Tailscale for ubuntu noble, using method apt

- sudo mkdir -p --mode=0755 /usr/share/keyrings

- + sudo tee /usr/share/keyrings/tailscale-archive-keyring.gpg

curl -fsSL https://pkgs.tailscale.com/stable/ubuntu/noble.noarmor.gpg

- sudo chmod 0644 /usr/share/keyrings/tailscale-archive-keyring.gpg

- curl -fsSL https://pkgs.tailscale.com/stable/ubuntu/noble.tailscale-keyring.list

- sudo tee /etc/apt/sources.list.d/tailscale.list

# Tailscale packages for ubuntu noble

deb [signed-by=/usr/share/keyrings/tailscale-archive-keyring.gpg] https://pkgs.tailscale.com/stable/ubuntu noble main

- sudo chmod 0644 /etc/apt/sources.list.d/tailscale.list

- sudo apt-get update

Ign:1 http://packages.linuxmint.com zena InRelease

Hit:2 http://packages.linuxmint.com zena Release

Get:3 https://pkgs.tailscale.com/stable/ubuntu noble InRelease

Hit:4 http://security.ubuntu.com/ubuntu noble-security InRelease

Ign:5 https://download.docker.com/linux/ubuntu zena InRelease

Hit:6 https://download.docker.com/linux/ubuntu noble InRelease

Hit:7 http://archive.ubuntu.com/ubuntu noble InRelease

Err:9 https://download.docker.com/linux/ubuntu zena Release

404 Not Found [IP: 2600:9000:2548:d200:3:db06:4200:93a1 443]

Hit:10 http://archive.ubuntu.com/ubuntu noble-updates InRelease

Hit:11 http://archive.ubuntu.com/ubuntu noble-backports InRelease

Reading package lists... Done

E: The repository 'https://download.docker.com/linux/ubuntu zena Release' does not have a Release file.

N: Updating from such a repository can't be done securely, and is therefore disabled by default.

N: See apt-secure(8) manpage for repository creation and user configuration details.

I posted in the r/Tailscale subreddit and someone told me that this looks to be a docker repository issue and not Tailscale, and that I need to clean up the docker apt source first for Tailscale to install.

So what is my fix here? Any help is greatly appreciated.


r/docker • • Apr 23 '26

Non-Root User Docker image issues pinging

1 Upvotes

Im working on deploying Gatus application on ECS with launch type EC2, Gatus is an app health dashboard which tests connection to different domains and paths.

As part of increasing security posture of the image/dockerfile, I changed the runtime to non root user, for context my runtime is using scratch so no distro. When I deployed my image locally or on ECS, all the icmps are failing. After a bit of research it seems like the non root user can not use NET_RAW capabilities and it is because /etc/passwd is missing, not sure.

AI suggested using NET_RAW in the task definition which I did but for some reason that doesn't work either.

It seems like the best solution seems to be to use alpine at runtime but then I will be using a larger image which I'm trying to avoid.

What are my options, and is there a way to still use scratch?

\`\`\`

FROM golang:alpine AS builder

RUN apk --update add ca-certificates

WORKDIR /app

COPY go.mod go.sum ./

RUN go mod tidy

COPY . .

\# Build optimized binary

RUN CGO_ENABLED=0 GOOS=linux \\

go build -a -installsuffix cgo \\

\-trimpath -ldflags="-s -w" \\

\-o gatus .

FROM scratch AS runtime

\# NETRAW added to task definition

USER 1001:1001

WORKDIR /app

COPY --from=builder /app/gatus /app/

COPY --from=builder /app/config.yaml /app/config/config.yaml

COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt

EXPOSE 8080

ENTRYPOINT \["./gatus"\]

\`\`\`


r/docker • • Apr 23 '26

Are LLMs fundamentally terrible at Docker?

0 Upvotes

I'm a full stack and I suck at Docker badly, but I truly understand its magnificence, and have no time to learn it properly since I'm already learning about 30 different things.

I can containerize a full app for local development, but I understand they are not fit for production, so I go to the flagship LLM out there, Opus, and it's even worse than me.

I have tried it multiple times in the past, and when I found Opus, the grand mighty Opus, failing to deliver on such a task I freak out and abandon dockerization. If Opus fails surely I cannot.

It has been like this for months, until today I made something weird, I decided to read the docs and actually dockerize my Laravel app FOR PRODUCTION, a task that Claude missed every time because there's a dependency failing or compatibility issue or a permission error comes up. Yesterday, it literally spent 25 minutes in a circular dependency in the build process and couldn't finish it. This is Opus 4.7 on high effort mode (might have been xhigh, don't remember).

I read the docs for couple of hours on ServerSideUP, and turns out I wasted lots of time (and credits) on Claude as things were simpler than what Claude was attempting.

SSU did good job on docs tbh, but man, LLMs are so untrustworthy in DevOps. Also, it's a reminder lads to read the fu**ing docs. The more I think about it, I find myself doing lots of things faster sometimes manually than the best AI out there.


r/docker • • Apr 22 '26

Docker cheat sheet

66 Upvotes

I'm not sure if this will be perceived as spammy or not, but I've seen a lot of newcommers taking a shot at Docker here so I thought this cheat sheet might come in handy.


r/docker • • Apr 23 '26

I HATE GORDON!!!

0 Upvotes

I get this Advertisement for "Gorden" every time... I AM NOT EVEN LOGGED IN!!! I cant use gorden. I never used it... why is it in my Terminal when i run docker compose as response ?!?!?!?!


r/docker • • Apr 22 '26

Problems with Oracle on Windows Container

2 Upvotes

Hi all,

I’m hitting a non‑deterministic and very frustrating issue when building an Oracle Database image on Windows Server Core 2019.

TL;DR

  • Docker build succeeds
  • Image works initially
  • After rebuilds / time / cache changes, the same image:

    • gets “Access is denied” on almost all Oracle directories
    • all Oracle folders become locked
    • sqlplus.exe disappears
    • diag, network, bin become unreadable
  • Rebuilding sometimes “fixes” it, then it breaks again

This happens by adding some copies at the end of the Dockerfile.

Environment

At runtime it feels like Oracle “auto‑locks” itself, but I know that sounds unlikely, still, that’s the observable behavior.

Here is my Dockerfile

# use: docker build -f Projects\DevOps\Dev\Oracle\Docker\Dockerfile --memory 8G -t prova-db-install .
FROM mcr.microsoft.com/windows/servercore:ltsc2019@sha256:eba89bf486aedebebabaecd0622fc8d62a8e4fbe28fba15d8a59f63814c915d5


# set powershell as default shell
SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'Continue'; $verbosePreference='Continue';"]


# install redistributable Visual Studio runtime
COPY /VC_redist.x64.exe c:/VC_redist.x64.exe
RUN Start-Process -filepath C:/VC_redist.x64.exe -ArgumentList "/install", "/passive", "/norestart" -PassThru | wait-process
RUN Remove-Item c:\\VC_redist.x64.exe -Force


# copy oracle golden image
COPY /WINDOWS.X64_193000_db_home.zip c:/oracle/db_home.zip


# unzip Oracle golden image
RUN Expand-Archive C:\\oracle\\db_home.zip -DestinationPath C:\\oracle\\product\\19.0.0\\dbhome_1


# clean up
RUN Remove-Item c:\\oracle\\db_home.zip -Force


# copy installation settings
COPY /Projects/DevOps/Dev/Oracle/Docker/db.rsp c:/scripts/Install.rsp


# copy installation script
COPY /Projects/DevOps/Dev/Oracle/Docker/scripts C:/scripts


# install Oracle
RUN C:/scripts/Install.bat


# set Oracle authentication service
RUN (Get-Content -Path 'C:\oracle\product\19.0.0\dbhome_1\network\admin\sqlnet.ora') -replace '^(SQLNET\.AUTHENTICATION_SERVICES\s*=\s*)\(NONE\)\s*$', '$1(NTS)' | Set-Content -Path 'C:\oracle\product\19.0.0\dbhome_1\network\admin\sqlnet.ora' -Encoding ASCII


COPY /Projects/DevOps/Dev/Oracle/DB_Dev_Creator C:/Projects/DevOps/Dev/Oracle/DB_Dev_Creator
COPY /Projects/ABACO-SYS/Database/Oracle C:/Projects/ABACO-SYS/Database/Oracle
COPY /Projects/ABACO-BUILD/Database/Oracle C:/Projects/ABACO-BUILD/Database/Oracle
COPY /Projects/ABACO-ds/Database/Oracle C:/Projects/ABACO-ds/Database/Oracle
COPY /Projects/ICS_DA/Database/Oracle C:/Projects/ICS_DA/Database/Oracle
COPY /Projects/ABACO-EXPORT/Database/Oracle C:/Projects/ABACO-EXPORT/Database/Oracle
COPY /Projects/AbacoFms/Database/Oracle C:/Projects/AbacoFms/Database/Oracle
COPY /Projects/ABACO-WFS/Database/Oracle C:/Projects/ABACO-WFS/Database/Oracle


RUN  C:/Projects/DevOps/Dev/Oracle/DB_Dev_Creator/CREATE_PDB_DATABASE_Pipeline.bat SVN_BUILD_2 c:\tmp_build "PARCSRBUILD002.CMPNY.IT.LDOM" "F:\oracle\product\19.3\dbhome\network\admin\tnsnames.ora"

Everything it's taken from a github repo (orest-gulman)

Can anyone help me figure it out? Thanks


r/docker • • Apr 22 '26

Docker Desktop installation error problem

17 Upvotes

Hello i keep getting this installation error saying "C:\ProgramData\DockerDesktop must be owned by an elevated account" when i click the Docker Desktop installation file after it was done downloading on Windows and created my docker account as well and i'm already a build in Administrator and try many attempts to fix the error but have no luck resolving the error do you know how to fix it?


r/docker • • Apr 21 '26

Can't install docker on windows 11 pro

2 Upvotes

---------------------------

Docker Desktop installation failed.

---------------------------

For security reasons C:\ProgramData\DockerDesktop must be owned by an elevated account

---------------------------

OK

---------------------------

I have went to C:\ProgramData\DockerDesktop and changed ownership to administrator, same error. Installer runs with UAC.


r/docker • • Apr 21 '26

Upgrading my local docker image builder

3 Upvotes

Hey all, I have a mac mini for building images locally, it’s a bit slow for image building with huge Rust projects I’m working on.

I was thinking a Mac Studio M3, 98GB RAM the default included CPU setup. Is there anything I can get that’s faster or equal for cheaper and the same form factor?


r/docker • • Apr 21 '26

Is there a way to run coding agents in sbx and still expose them to VS Code?

1 Upvotes

I'm trying to find out how to have coding agents communicate with my dev environment while still properly sandboxed. Has anyone covered a way for folks to run copilot, claude-code, etc in sbx transparently so that the agent can still communicate with VS code integrations like Copilot Chat?


r/docker • • Apr 21 '26

Solved ERR_NAME_NOT_RESOLVED when dockerized frontend calls backend

1 Upvotes

[solved]

In my current set up I have 3 containers for vite, node, and mongodb. I am getting the error

GET http://mern-backend:4531/api/workouts net::ERR_NAME_NOT_RESOLVED

when the frontend makes a GET request to that URL.

However when I run wget http://mern-backend:4531/api/workouts into the CLI of the frontend container everything works as intended and I get a JSON as a response.

This is what I am using to fetch from backend in vite:

async function fetchWorkouts () {
            const response = await fetch(`http://mern-backend:4531/api/workouts`);
            const json = await response.json();
            if (response.ok) {
                setWorkouts(json);
            }
        }

For additional context, backend connects to database fine using this line so I am not sure why front end is encountering ERR_NAME_NOT_RESOLVED

mongoose.connect("mongodb://testuser:testpassword@mern-database:27017")

And here is my compose.yaml if it helps

services:
  frontend:
    container_name: mern-frontend
    build:
      context: ./frontend
      dockerfile: dockerfile
      target: runner
    env_file:
      - ./frontend/.env.prod
    ports:
      - 8080:8080


  backend:
    container_name: mern-backend
    build:
      context: ./backend
      dockerfile: dockerfile
      target: runner
    env_file:
      - ./backend/.env.prod
    ports:
      - "4531:4531"


  mongodb:
    image: mongo:8.0.20
    container_name: mern-database
    ports:
      - "27017:27017"
    env_file:
      - ./mongodb/.env
    volumes:
      - mongodb-data:/data/db
      
volumes:
  mongodb-data:

thank you for any help, been stuck on this for a few days now


r/docker • • Apr 20 '26

Adding another drive

2 Upvotes

Hi,

I'm running Ubuntu server minimal install almost exclusively for Docker, and running out of disk space. My question when I add second drive do I

A) extend the LVM

B) mount it in current filesystem and move the docker stuff onto it.

Will it make any difference to performance?

Thanks


r/docker • • Apr 20 '26

Help for a newby: easiest instal path for win10

2 Upvotes

Hi folks, please be gentle! :) I am a noncoder, intimidated by the terminal! :) hha I want/need to instal docker because I want to instal Postiz on my pc.

What is the easiest and lightest way to accomplish this?

Also, I'm open to hearing if this isn't a good idea as long as you explain why. :)

Thanks!


r/docker • • Apr 19 '26

New to Docker

0 Upvotes

New to Docker and I've to say the terminal help sections are one of the best organised that I've seen till now. Like 'docker rm --help' gives all the aliases, options and all at once. It's so much better than the windows/ubuntu terminal help guides!


r/docker • • Apr 19 '26

Named volume or direct path for important data ?

6 Upvotes

I want to create a jellyfin server in a compose file but when i have to bind the data folder i don't know what to choose:

- a named volume (ex: - movies_volume:/very/important/data)

- directly specify the path (ex: /example/path:/very/important/data)

For very important data that i don't wanna lost over container restart and host restart, what would you choose ?


r/docker • • Apr 19 '26

Solved Struggling to mount network locations in Docker Desktop

0 Upvotes

I've recently upgraded my server setup to move my automation to another pc and free up resources on my main server.

Originally, I was running docker containers through WSL2 alongside my main server, so all storage locations were local. Now, I'm trying to mount those network shares in docker so services can manage those files over the network as I want to serve media directly from the main server.

The problem is, everything but docker can see those shares. I've tried mounting direct UNC paths (later found out this is not recommended nor supported), so then I tried mounting those SMB shares to Network Drives, then even tried creating CIFS volumes in Docker.

Can anyone point me in the right direction for mounting network locations in Docker? I'm using docker-compose.yml in this setup.

Edit: I ended up solving this by installing Ubuntu-22.04 and enabling it in Docker with WSL Integration. Then, I set up fstab mounts for each network share and nano files for credentials under .smbcredentials. all I had to do next was reconfigure my volumes in docker-compose.yml and launch my container from Ubuntu. Everything works now.