A lightweight log aggregator using NATS
Start a NATS Streaming instance using docker nats-streaming image
$ docker run -d -p 4222:4222 --name nats-streaming nats-streaming
Start natslog server
$ docker run -d -e NATS_SERVER=nats://nats-streaming:4222 -p 80:80 --link nats-streaming:nats-streaming --name natslog mgumowsk/natslog
the events are written to /var/log/natslog.log
Use client to log events on natslog server
$ go run natslog-client.go
CLUSTER_NAME
NATS streaming cluster name, defaults to "test-cluster"
NATS_SERVER
NATS server URL, default is "nats://localhost:4222"
NATS_CLIENT_NAME
Client name for natslog server, default "natslog-server"
NATS_DURABLE_NAME
NATS streaming durable name, default "natslog-server"
NATSLOG_SUBSCRIBE_SUBJECT
Register new service using NATS message subject and log filename, default "natslog.subscribe"
HTTP_ENABLED
Enable optional static web server for /var/log folder, default "true"
HTTP_PORT
default "80"