logspout
                                
                                 logspout copied to clipboard
                                
                                    logspout copied to clipboard
                            
                            
                            
                        Hostname using raw adapter
Hi I'm trying to send logs on remote machine using raw adapter. On my log machine im using ELK (logstash). I have received container name in go template but i cant recevice properly hostname. A "host" field is ip number instead of hostname. I tried receive hostname in go-template with i used in raw_format variable like this:
- "RAW_FORMAT={ "container": {{ toJSON .Container.Name }},"message": {{ toJSON .Data }},"hostname": {{ toJSON .Container.Config.Hostname }} }\n" but i receive "localhost"
here is my docker-compose.yaml file version: "3" networks: logging: services: logspout: image: gliderlabs/logspout:v3.2.12 command: 'raw+tcp://some.addres:5000' environment: - DEBUG=1 - "RAW_FORMAT={ "container": {{ toJSON .Container.Name }},"message": {{ toJSON .Data }},"hostname": {{ toJSON .Container.Config.Hostname }} }\n" volumes: - /etc/hostname:/etc/hostname - /etc/hosts:/etc/hosts - /var/run/docker.sock:/var/run/docker.sock networks: - logging