A third party monitoring app expects the host header to be set to a certain value in order to recognise the message I send it (it defaults to localhost when sending locally). So I need to set it manually. 
My syslog message is sent via simple python socket connection (socket.send) and I have tried prepending date time followed by host to the message string I pass in as parameter. However the 3rd party system still detects it as localhost, indicating that is not setting the header.
How do I set the header of a syslog message via python?
The hostname is added to the message by the local syslog server, i.e. is not set inside Python at all. Thus, your local system needs to be configured properly in order to send the correct hostname when forwarding syslog messages to other systems.
How to set host header field in a syslog message?