Closed fosskers closed 7 years ago
@fosskers you don't need to expose ports if you use --net=host
flag, though I'm wondering what else it's necessary to forward to make it work without --net=host
.
I don't know. Without --net=host
it just doesn't work.
Investigated: should be correctly setuped binding hostname in server config.
A possible container launch would be smth like that:
docker run -d -p 8777:8777 -h <hostname> chatta:latest
Where <hostname>
is a host machine name, different from localhost (for example ip-172-31-13-105
). It's akka http feature. As a workaround it is possible to use host machine network from the container (as you described, using --net=host
flag):
docker run -d --net=host chatta:latest
Everything should be explained in docs.
Yup, setting -Dgeotrellis.hostname=chatta
in the Dockerfile, then running with docker run --rm -p 8777:8777 -h chatta -t chatta:latest
works.
TODO
Motivation
We're updating these old demos to run in a containerized environment, so that they can be ran elsewhere easier.
Note: At least on my machine, I needed to include
--net=host
when running the image:Note: Depends on #27