sablierapp / sablier

Start your containers on demand, shut them down automatically when there's no activity. Docker, Docker Swarm Mode and Kubernetes compatible.
https://sablierapp.dev/
GNU Affero General Public License v3.0
1.46k stars 48 forks source link

page not found and could not get groupsCannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running? #383

Open deepakbandela opened 2 months ago

deepakbandela commented 2 months ago

Describe the bug while running sablier from yaml config file i'm getting the following error

$ docker run -it -p 10000:10000 -v $PWD/sablier.yml:/etc/sablier/sablier.yml acouvreur/sablier:1.7.0 INFO[0000] (version=1.7.0, branch=HEAD, revision=0f58751390f2439f03c851f76ef9b9a410346b58) INFO[0000] using provider "docker" INFO[0000] initialized storage to /etc/sablier/state.json WARN[0000] could not get groupsCannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running? INFO[0000] server listening :10000 WARN[0002] could not get groupsCannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running? WARN[0012] 49.204.31.206 - 2e1390417e03 [02/Sep/2024:12:00:22 +0000] "GET /" 404 0 "" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36 Edg/128.0.0.0" (1ms) clientIP=49.204.31.206 dataLength=0 hostname=2e1390417e03 latency=1 method=GET path=/ referer= statusCode=404 userAgent="Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36 Edg/128.0.0.0" WARN[0014] could not get groupsCannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

when opened the port 10000 on the server it says 404 page not found. Not sure what is the expected behaviour. below is my yaml config file provider: name: docker services: sablier: image: acouvreur/sablier:1.7.0 command:

server: port: 10000 base-path: / storage: file: sessions: default-duration: 5m expiration-interval: 20s logging: level: info strategy: dynamic: custom-themes-path: show-details-by-default: true default-theme: hacker-terminal default-refresh-frequency: 5s blocking: default-timeout: 1m

Context

Expected behavior The expected bahaviour is to have the webpage opened up in my browser which gives whoami content.

Additional context I'm new to sablier and want to run this file.

acouvreur commented 2 months ago

Hello!

When running sablier with the following command: docker run -it -p 10000:10000 -v $PWD/sablier.yml:/etc/sablier/sablier.yml acouvreur/sablier:1.7.0 you are missing the the docker socket volume.

Can you try with the following command instead ?

docker run -it -p 10000:10000 -v $PWD/sablier.yml:/etc/sablier/sablier.yml -v /var/run/docker.sock:/var/run/docker.sock acouvreur/sablier:1.7.0