Pino transport to log data into Logstash via HTTP, TCP, or UDP.
@noelware/pino-logstash is a library to pipe Pino into a Logstash instance using the HTTP input plugin, TCP input plugin, or UDP input plugin.
import { createTcpTransport, createUdpTransport, createHttpTransport } from '@noelware/pino-logstash';
import pino from 'pino';
const log = pino({ level: 'info' }, [
{
stream: createTcpTransport({
host: 'localhost',
port: 4040
})
},
{
stream: createUdpTransport({
host: 'localhost',
port: 6654
})
},
{
stream: createHttpTransport({
host: 'localhost',
port: 9210,
sername: 'myuser',
password: 'mypass'
})
}
]);
At the moment, using SSL with the HTTP input plugin via @noelware/pino-transport is not supported.
@noelware/pino-transport is released under the MIT License by Noelware.