17
submitted 5 days ago* (last edited 5 days ago) by girlnamedzero@piefed.zeromedia.vip to c/linux@programming.dev

On my server, I’ve noticed that I can run docker commands like docker compose up -d or docker run hello-world without root (sudo, su, etc), as if I had done the rootless setup, but docker info reveals “context: default”. I am also not using userns-remap. Any theories for what’s going on here?

Edit: [Solved] @cosmicrose@lemmy.blahaj.zone pointed out that users in the docker group can run commands without sudo, after checking, my user is indeed in the group.

you are viewing a single comment's thread
view the rest of the comments
[-] SinTan1729@programming.dev 2 points 4 days ago* (last edited 4 days ago)

For most "normal" setups, no. Networks, environment variables, volumes, permissions etc. map pretty much one-to-one.

If you're using compose, you can even keep your setup mostly unchanged and use podman compose. Although, I would recommend learning a bit about quadlets and using them instead. There's a tool called podlet that can help you translate your docker commands to quadlets, although it's not complete and does miss some features. The annoying thing can be some QoL tooling that exists for docker compose that doesn't for quadlets e.g. automatic restart for changed quadlet files. I wrote some scripts for most of these situations. I will probably release them at some point after I make sure that they don't rely on any specific properties of my setup. But you can easily write them for yourself if you know some shell scripting.

For docker run commands, you can mostly get away with changing it to podman run.

[-] IronKrill@lemmy.ca 2 points 4 days ago

That sounds promising then, thanks for the insight!

this post was submitted on 22 Aug 2026
17 points (94.7% liked)

Linux

14810 readers
310 users here now

A community for everything relating to the GNU/Linux operating system (except the memes!)

Also, check out:

Original icon base courtesy of lewing@isc.tamu.edu and The GIMP

founded 3 years ago
MODERATORS