package logs-syslog
Install
Dune Dependency
Authors
Maintainers
Sources
sha256=af1ee692c03ccb5042122b0d4d0c12b0969eb78d9e47bb59de0633bc2aab60d4
sha512=199b34bdc86ce1cad91d9458b67db999cd1cad23c1ea1568ec0349ee3b4cd3bd526ccd5fa51774dd7e3dd0f750938df2e46e08717da3190d37a1e7f5cec701e3
README.md.html
Logs-syslog - Logs output via syslog
v0.5.0
This library provides log reporters using syslog over various transports (UDP, TCP, TLS) with various effectful layers: Unix, Lwt, MirageOS. It integrates the Logs library, which provides logging infrastructure for OCaml, with the syslog-message library, which provides encoding and decoding of syslog messages (RFC 3164).
Six ocamlfind libraries are provided: the bare Logs-syslog
, a minimal dependency Unix Logs-syslog-unix
, a Lwt one Logs-syslog-lwt
, another one with Lwt and TLS (RFC 5425) support Logs-syslog-lwt-tls
, a MirageOS one Logs-syslog-mirage
, and a MirageOS one using TLS Logs-syslog-mirage-tls
.
Since MirageOS3, syslog is well integrated:
let logger =
syslog_udp
(syslog_config ~truncate:1484 "nqsb.io" (Ipaddr.V4.of_string_exn "192.168.0.1"))
net
...
register "myunikernel" [
foreign
~deps:[abstract logger]
Documentation
API documentation is available online.
Installation
This is targeting other libraries (apart from syslog-message) which are released to opam-repository.
opam pin add syslog-message --dev-repo
opam pin add logs-syslog https://github.com/hannesm/logs-syslog.git