summaryrefslogtreecommitdiff
path: root/sd_daemon/doc.go
diff options
context:
space:
mode:
Diffstat (limited to 'sd_daemon/doc.go')
-rw-r--r--sd_daemon/doc.go26
1 files changed, 23 insertions, 3 deletions
diff --git a/sd_daemon/doc.go b/sd_daemon/doc.go
index 665e25e..8f1fb00 100644
--- a/sd_daemon/doc.go
+++ b/sd_daemon/doc.go
@@ -1,4 +1,4 @@
-// Copyright 2015 Luke Shumaker
+// Copyright 2015-2016 Luke Shumaker
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,5 +12,25 @@
// See the License for the specific language governing permissions and
// limitations under the License.
-// Package sd provides APIs for systemd new-style daemons.
-package sd
+// Package sd_daemon provides functions for writing "new-style"
+// daemons.
+//
+// The daemon(7) manual page has historically documented the very long
+// list of things that a daemon must do at start-up to be a
+// well-behaved SysV daemon. Modern service managers allow daemons to
+// be much simpler; modern versions of the daemon(7) page on GNU/Linux
+// systems also describe "new-style" daemons. Though many of the
+// mechanisms described there and implemented here originated with
+// Systemd, they are all very simple mechanisms which can easily be
+// implemented with a variety of service managers.
+//
+// [daemon(7)]: https://www.freedesktop.org/software/systemd/man/daemon.html
+package sd_daemon
+
+import "errors"
+
+// ErrDisabled is the error returned when the service manager does not
+// want/support a mechanism; or when that mechanism has been disabled
+// for this process by setting unsetEnv=true when calling one of these
+// functions.
+var ErrDisabled = errors.New("Mechanism Disabled")