When logging with udp on a syslog server, localhost is used as the hostname in the log instead of the actual machine name. Example of invalid host name:
Jun 11 12:19:55 localhost elixir<0.335.0>: 2019-06-11 12:19:55.420 module=supervisor pid=<0.418.0> [info] : Child Postgrex.Parameters of Supervisor Postgrex.Supervisor started#012Pid: #PID<0.422.0>#012Start Call: Postgrex.Parameters.start_link()
This is due to the pre variable not using the hostname (destructured as _hostname) variable when formatting the output.