Implement shutting down status

This commit is contained in:
2025-10-28 23:53:11 +01:00
parent e5baedb776
commit 7ee22fee51

View File

@@ -14,20 +14,23 @@ const (
Running Running
Failed Failed
Restarting Restarting
ShuttingDown
) )
var nameToStatus = map[string]Status{ var nameToStatus = map[string]Status{
"stopped": Stopped, "stopped": Stopped,
"running": Running, "running": Running,
"failed": Failed, "failed": Failed,
"restarting": Restarting, "restarting": Restarting,
"shutting_down": ShuttingDown,
} }
var statusToName = map[Status]string{ var statusToName = map[Status]string{
Stopped: "stopped", Stopped: "stopped",
Running: "running", Running: "running",
Failed: "failed", Failed: "failed",
Restarting: "restarting", Restarting: "restarting",
ShuttingDown: "shutting_down",
} }
// Status enum JSON marshaling methods // Status enum JSON marshaling methods