Send Heroku Log Drains logs to Axiom
Log Drains make it easy to collect logs from your deployments and forward them to archival, search, and alerting services by sending them via HTTPS, HTTP, TLS, and TCP.
Heroku Log Drains
With Heroku log drains you can forward logs from your applications, and deployments to Axiom by sending them via HTTPS.
Sign up and login to your account on Heroku, and download the Heroku CLI
Heroku log drains configuration consists of three main components
heroku drains:add https://:<$API_TOKEN>@cloud.axiom.co/api/v1/datasets/<$DATASET_NAME>/ingest -a <$HEROKU_APPLICATION_NAME>
- API_TOKEN: is used to send data to your dataset. API token can be generated from settings on Axiom dashboard.
See creating an API token for more
- DATASET_NAME: name of your dataset. When logs are sent from your Heroku App it is stored in a dataset on Axiom.
Dataset can be created from the settings page on Axiom.
See creating a dataset for more
- HEROKU_APPLICATION_NAME: is the name of your application created on the Heroku dashboard or on the Heroku CLI.
See creating an Heroku application for more
Back in your dataset you will see your Heroku logs