This repository was archived by the owner on Apr 8, 2024. It is now read-only.
- Notifications
You must be signed in to change notification settings - Fork2
A simple .NET Core multi-threaded Syslog server, which saves Syslog entries to Azure Table Storage, Azure ServiceBus or a Local File.
License
NotificationsYou must be signed in to change notification settings
jhueppauff/AzureSyslog
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
A simple .NET Core multi-threaded Syslog server, which saves Syslog entries to Azure Table Storage, Azure ServiceBus or a Local File.
- Visual Studio, Visual Studio Code, or other .NET IDE's
- DotNet Core 2.2
- Open UDP Port 514 (syslog)
- DotNet Core 2.2
- Open UDP Port 514 (syslog)
- Configure the AppSettings with your Storage Connection String
- Clone the Repo
- Use the Visual Studio Publish function (right click on the project -> publish)
There are 3 Options to save the Messages to.
- Azure Storage Account
- Azure Service Bus
- Local FileSystem (JSON File, not intended for production use)
- You can disable output actions by setting the config value "Enabled" to false
- Create Azure Storage Account. SeeMicrosoft Docs
- Retrieve the Azure Storage Connection String from the Azure Resource
- Add your Azure Storage Connection string to the appsettings.json
{"StorageEndpointConfiguration": [ {"ConnectionString":"[Your ConnectionString]","Enabled":true,"ConnectionType":"TableStorage","Name" :"syslogMessages" } ]}
- Create an Azure ServiceBus SeeMicrosoft Docs
- Retrieve the Connection String from the Azure ServiceBus (Hidden under "Shared access policy")
- Add your Connection string to the appsettings.json
- Create a Queue in the Service Bus
{"StorageEndpointConfiguration": [ {"ConnectionString":"[Your ConnectionString]","Enabled":true,"ConnectionType":"ServiceBus","Name" :"[your queue name]" } ]}
- Create an empty File somewhere in your FileSystem and ensure access
- Add the File Path and File Name to the config
{"StorageEndpointConfiguration": [ {"ConnectionString":"[Path to the File]","Enabled":true,"ConnectionType":"ServiceBus","Name" :"[File name]" } ]}
You can configure multiple outputs (even multiple times the same output type, e.g. 2 table storages)Just add every output you like to the config and choose the correctConnectionType
.
{"StorageEndpointConfiguration": [ {"ConnectionString":"","Enabled":true,"ConnectionType":"ServiceBus","Name":"syslogMessages" }, {"ConnectionString":"","Enabled":true,"ConnectionType":"TableStorage","Name" :"syslogMessages" }, {"ConnectionString":"","Enabled":true,"ConnectionType":"LocalFile","Name" :"log.txt" } ]}
- Run
dotnet Syslog.Server.dll
on the command line
About
A simple .NET Core multi-threaded Syslog server, which saves Syslog entries to Azure Table Storage, Azure ServiceBus or a Local File.
Topics
Resources
License
Stars
Watchers
Forks
Packages0
No packages published