-
Notifications
You must be signed in to change notification settings - Fork 8
Lumberjack Locally
Lumberjack needs to work over SSL, which means in order to work locally you will need to create your own SSL certificates inside the VM and use them when with the lumberjack client.
-
Be sure to install lumberjack on the host.
-
Create a certificate pair within the VM. So
vagrant up && vagrant ssh
into the VM and run:openssl req -x509 -newkey rsa:2048 -keyout /app/data/lumberjack.key -out /app/data/lumberjack.crt -nodes -days 3650
You will be asked to input information (the values don't really matter when testing):
- Country code
- Some state
- Organization name
- Unit name
- Common name (use
localhost
) - email address (e.g.
root@localhost
)
-
The previous step creates two files on the VM, but you'll only be interested in
/app/data/lumberjack.crt
when shipping. Copylumberjack.crt
to your host (it's probably easiest to put it alongside yourlumberjack.conf
file) and update your config to use the certificate. For example:{ "network": { "servers": [ "localhost:5043" ], "ssl certificate" : "./lumberjack.crt", "ssl ca" : "./lumberjack.crt" }, ...
-
Once you've created the certificates, you'll need to restart the lumberjack service. On the VM, you can do that with:
sudo service app-lumberjack_redis restart
-
Now you're ready to run lumberjack on the host (it may take a couple minutes for the VM service to start processing events though). For example, on a ubuntu machine run:
/opt/lumberjack/lumberjack.sh -config lumberjack.json
-
Once events start shipping, pull up kibana to check them out: localhost:4567.