In my case I’m running an Elixir app, so is it best to just use a Elixir package like https://github.com/larskrantz/logger_papertrail_backend, or is there a more “Fly” way of doing things that doesn’t require changes to the app?
You can specify which specific app you’d like by setting a different SUBJECT env var. This takes a NATS subject.
The format is: logs.{app-name}.{region}.{instance-id}. Using logs.> means you want logs from all regions for all apps and instances. If you just want 1 app, you can use logs.{app-name}.>.
Crash course:
Subject “parts” are delimited by dots (.).
* in a NATS subject means “match everything for this part of the subject”
> means “match everything from any number of subject parts”
@jerome I was able to get this running, and delivering to S3. Thanks for working on this. Can I deploy another instance to send the same org logs to a different sink or do I just add other secrets to the existing one?
Thanks for all of the help on this thread. I thought that I was successfully sending logs from all apps to Papertrail, but logs from some of my apps aren’t getting through. I checked the logs for my fly-log-shipper instance and saw this: