17 #ifndef __SYSTEMD_HPP__ 18 #define __SYSTEMD_HPP__ 42 static const char MESOS_EXECUTORS_SLICE[] =
"mesos_executors.slice";
57 namespace socket_activation {
215 #endif // __SYSTEMD_HPP__ bool enabled()
Check if systemd exists, and whether we have initialized it.
Try< std::vector< int > > listenFds()
Try< Nothing > extendLifetime(pid_t child)
A hook that is executed in the parent process.
Try< Nothing > create(const Path &path, const std::string &data)
Creates a slice configuration with the provided contents at the given path.
std::string runtime_directory
Definition: systemd.hpp:129
Try< Nothing > start(const std::string &name)
Starts the slice with the given name (via 'systemctl start <name>').
Definition: systemd.hpp:28
Path runtimeDirectory()
Returns the path to the runtime directory for systemd units.
DWORD pid_t
Definition: windows.hpp:181
bool enabled
Definition: systemd.hpp:128
Try< Nothing > initialize(const Flags &flags)
Initialized state for support of systemd functions in this file.
Represents a POSIX or Windows file system path and offers common path manipulations.
Definition: path.hpp:212
constexpr int SD_LISTEN_FDS_START
Definition: systemd.hpp:115
Try< Nothing > daemonReload()
Runs systemctl daemon-reload.
std::string cgroups_hierarchy
Definition: systemd.hpp:130
Path hierarchy()
Return the path to the systemd hierarchy.
Try< std::vector< int > > listenFdsWithNames(const hashset< std::string > &names)
Flags to initialize systemd state.
Definition: systemd.hpp:123
bool exists()
Check if we are on a systemd environment by: (1) Testing whether /sbin/init links to systemd...
constexpr const char * name
Definition: shell.hpp:41