run_service library
Everything bin/service.dart does, so the code hash covers what runs:
that file only calls runLogbookService and exits with what it returns.
It reads its settings from the environment it is given:
LOGBOOK_DIR=/var/lib/intersyntactic-logbook \
LOGBOOK_SOCKET=/run/intersyntactic-logbook/logbook.sock \
LOGBOOK_SENDERS=/opt/intersyntactic-logbook/current/etc/senders \
LOGBOOK_READ_SOCKET=/run/intersyntactic-logbook-read/logbook.sock \
dart run is_logbook:service
LOGBOOK_READ_SOCKET is optional: without it, nothing can read through
the service.
Constants
- cannotStart → const int
- The exit code when the service cannot start as configured.
Functions
-
runLogbookService(
Map< String, String> env, {IOSink? out, IOSink? err, Future<void> ? stop}) → Future<int> -
Runs a logbook's one writer (see
package:is_logbook/service.dart) asenvconfigures it, untilstopcompletes, and returns the exit code: 0 once it has closed, cannotStart when it could not start, having written why toerr.