24 lines
482 B
Bash
Executable File
24 lines
482 B
Bash
Executable File
# Lifecycle adapter API 1. Quadlet remains the owner of container construction,
|
|
# init/maintenance command, signal settings and service restart/exit policies.
|
|
MC_LIFECYCLE_API=1
|
|
|
|
mc_lifecycle_start()
|
|
{
|
|
as_service_user systemctl --user start "$1"
|
|
}
|
|
|
|
mc_lifecycle_stop()
|
|
{
|
|
as_service_user systemctl --user stop "$1"
|
|
}
|
|
|
|
mc_lifecycle_running()
|
|
{
|
|
as_service_user systemctl --user is-active --quiet "$1"
|
|
}
|
|
|
|
mc_lifecycle_cat()
|
|
{
|
|
as_service_user systemctl --user cat "$1"
|
|
}
|