MCPcopy Create free account
hub / github.com/1Panel-dev/1Panel / IsActive

Method IsActive

core/utils/controller/manager/openrc.go:25–28  ·  view source on GitHub ↗
(serviceName string)

Source from the content-addressed store, hash-verified

23 return "openrc"
24}
25func (s *Openrc) IsActive(serviceName string) (bool, error) {
26 _, err := cmd.NewCommandMgr().RunWithStdout("service", serviceName, "status")
27 return err == nil, nil
28}
29func (s *Openrc) IsEnable(serviceName string) (bool, error) {
30 return isSysvServiceEnabled(serviceName)
31}

Callers

nothing calls this directly

Calls 1

RunWithStdoutMethod · 0.45

Tested by

no test coverage detected