Skip to content

IdentityStream/Serilog.Sinks.Humio

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Serilog.Sinks.Humio2

A Serilog sink for Humio.

How to use

  1. Grab the ingest token from Humio. (inside settings => Ingest => API Tokens)
  2. Install the Serilog.Sinks.Humio2 package from NuGet.
  3. If you are using the cloud version of Humio:
var log = new LoggerConfiguration()
	.WriteTo.Humio(ingestToken: "yourIngestTokenHere")
	.CreateLogger();
  1. If you use Humio on-prem:
var log = new LoggerConfiguration()
	.WriteTo.Humio(url:"https://url.onprem.com", ingestToken: "yourIngestTokenHere")
	.CreateLogger();
  1. If you configure the solution via appsettings in web.config:
<appSettings>
	<add key="serilog:using:Humio" value="Serilog.Sinks.Humio" />
	<add key="serilog:write-to:Humio" />
	<add key="serilog:write-to:Humio.ingestToken" value="yourIngestTokenHere" />
</appSettings>

Credits

This work is derived from the following users GitHub gists: