Docker Community Forums

Share and learn in the Docker community.

Docker-compose not accessible from LAN

Hey guys, I’m new to docker so please be gentle.

I can’t access my docker-compose instance which is on raspberry pi (192.168.1.2) from my Desktop PC (192.168.1.4) while the website does work on the internet (it’s a ghost blog), fully accessible with lets encrypt too.

Here’s my yaml:

version: '2'

services:

  nginx:
    image: nginx
    volumes:
      - $PWD/nginx/nginx.conf:/etc/nginx/nginx.conf
      - $PWD/nginx/blog.conf:/etc/nginx/sites-enabled/blog.conf
      - /etc/letsencrypt:/etc/letsencrypt
      - /etc/ssl:/etc/ssl
    ports:
      - "80:80"
      - "443:443"
    links:
      - ghost
    restart: always

  ghost:
    build: ./ghost
    volumes:
      - ghost:/var/lib/ghost
    #ports: 
    #  - "2368:2368"
    environment:
      - NODE_ENV=production
    restart: always

volumes:
  ghost:

source --> https://github.com/gregbkr/ghost-nginx-ssl-docker

And here’s my ps -a

CONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS              PORTS                                      NAMES
b53a0f4cbd1a        nginx               "/docker-entrypoint.…"   8 minutes ago       Up 7 minutes        0.0.0.0:80->80/tcp, 0.0.0.0:443->443/tcp   blog_nginx_1
4e1be53be399        blog_ghost          "docker-entrypoint.s…"   8 minutes ago       Up 8 minutes        2368/tcp                                   blog_ghost_1

Any ideas? Thank you