Skip to content

Commit

Permalink
pino: Stdout+syslog doesn't currently work
Browse files Browse the repository at this point in the history
  • Loading branch information
bmaupin committed Jan 18, 2022
1 parent ee4f0a8 commit ae5947a
Show file tree
Hide file tree
Showing 4 changed files with 111 additions and 735 deletions.
6 changes: 4 additions & 2 deletions pino/README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
## Sending Node.js logs to Graylog via syslog using pino

⚠ This is subject to change as [Pino v7](https://github.com/pinojs/pino) is still under development
> ⚠ This is subject to change as [Pino v7](https://github.com/pinojs/pino) is still under development
1. Install Pino

[https://github.com/pinojs/pino#readme](https://github.com/pinojs/pino#readme)

```
npm install pino@next
npm install pino
```

1. Install pino-socket and pino-syslog
Expand Down Expand Up @@ -45,6 +45,8 @@

You can also send logs to stdout and syslog; the example below requires pino-pretty (`npm install pino-pretty`):

> ⚠ The below example does not currently work ([https://github.com/pinojs/pino/issues/1302](https://github.com/pinojs/pino/issues/1302))
```javascript
const logger = pino({
transport: {
Expand Down
7 changes: 4 additions & 3 deletions pino/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ const pino = require('pino');
const logger = pino({
transport: {
pipeline: [
{
target: 'pino-pretty',
},
// This does not currently work
// {
// target: 'pino-pretty',
// },
{
target: 'pino-syslog',
options: {
Expand Down
Loading

0 comments on commit ae5947a

Please sign in to comment.