Connecting a local Elixir/Erlang to a running application inside a Docker container
Wouldn't an easier solution be to change the outward port of the docker container? Just change it to something like 4368
$ docker run -itd -p 4000:4000 4368:4369 9000:9000 <docker_image_name> iex \ --name test@1.2.3.4 \ --cookie secret \ --erl '-kernel inet_dist_listen_min 9000' \ --erl '-kernel inet_dist_listen_max 9000' \ -S mix phx.server`