Docker applications have permission issue

On a fresh install of Leap 16.0, I installed docker and docker compose. I am using a compose file that worked on another machine. It’s throwing permission error on Leap. I have added my user to docker group. How do I fix this?

services:

  dozzle:
    container_name: dozzle-agent
    image: amir20/dozzle:latest
    command: agent
    networks:
      - local_dozzle
    restart: unless-stopped
    ports:
      - 7007:7007
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock:ro

networks:
  local_dozzle:
    name: local_dozzle

The error I get:

dozzle-agent  | {"level":"fatal","version":"v8.14.12","error":"failed to create docker client: permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get \"http://%2Fvar%2Frun%2Fdocker.sock/v1.51/info\": dial unix /var/run/docker.sock: connect: permission denied","time":"2025-12-16T20:04:48Z","message":"Failed to run command"}

User info:

> groups
username docker wheel

First question is, did you log out of that session after you made the group change.

Yes. I have rebooted the system as well.

I had that once under 15.6 too.
I think I did the following:
Systemctl stop docker.
Then /var/run/docker.sock was still there.
I deleted docker.sock and restarted docker.
Hope that helps you.

Thanks for the suggestion! That didn’t help though. When I stop docker.service, docker.sock is no longer there in docker.sock. So, nothing to delete.

I re-installed docker and docker compose which solved the issue.

Nevermind, that didn’t resolve the issue. It’s still the same.

What does sudo systemctl status docker say?

Sounds like it could be SELinux… Run ausearch -ts boot -m avc
https://en.opensuse.org/Portal:SELinux

I had a similar issue – looks like it is indeed SELinux. I don’t know what the proper solution is, but this person on Reddit has a band-aid. I’ve added this to my compose.yaml:

      security_opt:
        - label=disable

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.