ifconfig isn’t installed on all systems, particularly not newer ones by default.
The discourse_docker launcher.sh script relies on the presence of ifconfig on the host system.
My PR at Adds a docker_ip pipeline for /sbin/ip by lukegb · Pull Request #92 · discourse/discourse_docker · GitHub allows the use of /sbin/ip instead.