mirror of
https://github.com/opencontainers/runc.git
synced 2026-07-11 06:03:57 +08:00
Stop systemd unit on destroy
It totally fixes leftover ".scope" fails. Of course it's just workaround, real issue seems to be in go-systemd library or in systemd itself. Signed-off-by: Alexander Morozov <lk4d4@docker.com>
This commit is contained in:
@@ -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
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user