Docker portainer tcp 127.0.0.1:2375: connect: connection refused

Viewed 2412

I am trying to use portainer/portainer:1.24.1-alpine. My docker in my windows, my container is linux.

portainer | 2020/09/04 12:42:57 Get http://localhost:2375/_ping: dial tcp 127.0.0.1:2375: connect: connection refused

My docker-compose.yml, i tried it on linux as host and #command: -H unix:///var/run/docker.sock works fine, but now I am using do windows as HOST.

version: "3.7"
services:
  web:
    container_name: portainer
    image: portainer/portainer:1.24.1-alpine
    #command: -H unix:///var/run/docker.sock << i am not using linux as HOST.
    command: -H tcp://localhost:2375 
    restart: always
    ports:
      - 9999:9000
    volumes:
    # - /var/run/docker.sock:/var/run/docker.sock
      - web_data:/data

volumes:
  web_data:
    driver: local

What should I used on line command: -H ????????

0 Answers
Related