Thanks to visit codestin.com
Credit goes to github.com

Skip to content

pcarthuran/logpipe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 

Repository files navigation

logpipe

Lightweight structured log aggregator with pluggable backends for local dev environments.


Installation

go install github.com/yourorg/logpipe@latest

Or build from source:

git clone https://github.com/yourorg/logpipe.git && cd logpipe && go build ./...

Usage

Start logpipe and point your services at it:

logpipe --port 5170 --backend console

Send structured logs from your application:

import "github.com/yourorg/logpipe/client"

logger := client.New("localhost:5170")
logger.Info("server started", client.Fields{
    "port": 8080,
    "env":  "development",
})

Available backends:

Backend Flag Description
console --backend console Pretty-prints logs to stdout
file --backend file Writes JSON lines to a log file
memory --backend memory Stores logs in-memory for tests

Pipe logs from an existing process:

./my-service | logpipe --backend console

Configuration

Flag Default Description
--port 5170 TCP port to listen on
--backend console Output backend to use
--format json Input log format

License

MIT © yourorg

About

Lightweight structured log aggregator with pluggable backends for local dev environments.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages