sdnotify

package
v13.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 30, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package sdnotify provides methods for sending notifications to systemd

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

func Connect

func Connect() error

❗ Connect connects systemd to socket

Example
err := Connect()

if err != nil {
	panic(err.Error())
}

Status("Loading data %d%%", 50)
Ready()
Output:

func ExtendTimeout

func ExtendTimeout(sec float64) error

❗ ExtendTimeout sends EXTEND_TIMEOUT_USEC message to systemd

func MainPID

func MainPID(pid int) error

❗ MainPID sends MAINPID message with PID to systemd

func Notify

func Notify(msg string) error

❗ Notify sends provided message to systemd

func Ready

func Ready() error

❗ Ready sends READY message to systemd

func Reloading

func Reloading() error

❗ Reloading sends RELOADING message to systemd

func Status

func Status(format string, a ...any) error

❗ Status sends status message to systemd

func Stopping

func Stopping() error

❗ Stopping sends STOPPING message to systemd

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL