Merge pull request #617 from LK4D4/stop_transient_unit
Stop systemd unit on destroy
This commit is contained in:
commit
688ec20a4a
|
@ -259,6 +259,7 @@ func (m *Manager) Apply(pid int) error {
|
|||
func (m *Manager) Destroy() error {
|
||||
m.mu.Lock()
|
||||
defer m.mu.Unlock()
|
||||
theConn.StopUnit(getUnitName(m.Cgroups), "replace")
|
||||
if err := cgroups.RemovePaths(m.Paths); err != nil {
|
||||
return err
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue