MichaelAng / dnd-char-gen

A basic dnd application built on angular 2
MIT License
1 stars 0 forks source link

I can't the application when running in the context of docker #20

Closed MichaelAng closed 7 years ago

MichaelAng commented 7 years ago

When I start up a webpack-dev-server on the host machine I am able to see the application. But when I do this through docker I get a This site can’t be reached.

Docker compose

...

  client:
    container_name: client
    build: ./client
    ports:
      - "8080:8080"

...

command to start webpack-dev-server

webpack-dev-server --inline --progress --port 8080
MichaelAng commented 7 years ago

Solved it.

I needed to add --host 0.0.0.0 to the webpack-de-server command

Full command

webpack-dev-server --host 0.0.0.0 --inline --progress --port 8080

Source: https://github.com/webpack/webpack-dev-server/issues/143#issuecomment-246984811