I am using Jupyterhub 0.9.4 with DockerSpawner.
My goal is to pass every container spawned by the Spawner an additional host name, so make an additional entry in /etc/hosts
.
I first tried via my docker-compose.yml
file, which does not work, as the container are created by Jupyterhub.
I also tried it in the Dockerfile
itself, but there it got overwritten.
I further tried it with changes in the jupyterhub_config.py
file, by adding:
c.DockerSpawner.extra_create_kwargs.update({'command': '--add-host="<ip-address> <hostname>"'})
Still I do not see an entry in the /etc/hosts
file in the container.
Anyone has a clue where I have to add it?
Thanks, Max