diff --git a/programs.cfg b/programs.cfg index ecd5a6d..11811c9 100644 --- a/programs.cfg +++ b/programs.cfg @@ -110,6 +110,7 @@ ["libsyslog"] = { files = { ["master/syslog/OpenOS/usr/lib/syslog.lua"] = "/lib", + ["master/syslog/OpenOS/usr/man/syslog"] = "/man", }, name = "libsyslog", description = "Library for unified logging", @@ -119,6 +120,7 @@ ["syslogd"] = { files = { ["master/syslog/OpenOS/etc/rc.d/syslogd.lua"] = "//etc/rc.d", + ["master/syslog/OpenOS/usr/man/syslogd"] = "/man", }, name = "syslogd", description = "System logging daemon with network capabilities", diff --git a/syslog/OpenOS/usr/man/syslog b/syslog/OpenOS/usr/man/syslog new file mode 100644 index 0000000..77efd2a --- /dev/null +++ b/syslog/OpenOS/usr/man/syslog @@ -0,0 +1,19 @@ +# syslog Library for OpenOS + +The syslog library only provides one function, so the library can be called. In addition, the library provides a number of pre-configured event levels: + + - syslog.emergency + - syslog.alert + - syslog.critical + - syslog.error + - syslog.warning + - syslog.notice + - syslog.info + - syslog.debug + +An example using syslog as both a function and a table: + +```lua +local syslog = require "syslog" +syslog("message", syslog.emergency, "service name") +``` diff --git a/syslog/OpenOS/usr/man/syslogd b/syslog/OpenOS/usr/man/syslogd new file mode 100644 index 0000000..3078f23 --- /dev/null +++ b/syslog/OpenOS/usr/man/syslogd @@ -0,0 +1,24 @@ +# syslog Daemon for OpenOS + +The syslog daemon lives in */etc/rc.d/syslogd.lua*, and as such is managed as an rc program: + +``` +rc syslogd enable +rc syslogd start +rc syslogd reload +``` + +In addition, the daemon keeps a configuration file in */etc/syslogd.cfg*. This is stored as a Lua table and may be edited in whatever way you see fit. It has the following fields and default values: + +|Field | Default value | +| --- | --- | +|port | 514 | +|relay | false | +|relayhost | "" | +|receive | false | +|write | true | +|destination | "/dev/null" | +|minlevel | 6 | +|beeplevel | -1 | +|displevel | 2 | +|filter | {} |