Connect Livebook to a Phoenix app running in Docker Swarm with automatic node discovery.
- Erlang node names must match exactly: if Phoenix runs as
myapp@10.0.1.5, you must connect tomyapp@10.0.1.5 - Docker Swarm assigns dynamic IPs to containers
- Livebook's
LIVEBOOK_DEFAULT_RUNTIMEexpects a static node name - Solution: Use
/app/user/env.shto discover the Phoenix node IP at Livebook startup