2014-05-15 06:21:44 +08:00
|
|
|
// +build !linux
|
|
|
|
|
|
|
|
package systemd
|
|
|
|
|
|
|
|
import (
|
|
|
|
"fmt"
|
|
|
|
|
2014-06-10 23:14:16 +08:00
|
|
|
"github.com/docker/libcontainer/cgroups"
|
2014-05-15 06:21:44 +08:00
|
|
|
)
|
|
|
|
|
2015-01-13 05:54:00 +08:00
|
|
|
type Manager struct {
|
|
|
|
Cgroups *cgroups.Cgroup
|
|
|
|
}
|
|
|
|
|
2014-05-15 06:21:44 +08:00
|
|
|
func UseSystemd() bool {
|
|
|
|
return false
|
|
|
|
}
|
|
|
|
|
2015-01-13 05:54:00 +08:00
|
|
|
func (m *Manager) Apply(pid int) error {
|
|
|
|
return fmt.Errorf("Systemd not supported")
|
|
|
|
}
|
|
|
|
|
|
|
|
func (m *Manager) GetPids() ([]int, error) {
|
2014-05-22 04:48:06 +08:00
|
|
|
return nil, fmt.Errorf("Systemd not supported")
|
|
|
|
}
|
|
|
|
|
2015-01-13 05:54:00 +08:00
|
|
|
func (m *Manager) RemovePaths() error {
|
|
|
|
return fmt.Errorf("Systemd not supported")
|
|
|
|
}
|
|
|
|
|
|
|
|
func (m *Manager) GetPaths() map[string]string {
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
|
|
|
func (m *Manager) SetPaths(paths map[string]string) {
|
|
|
|
}
|
|
|
|
|
|
|
|
func (m *Manager) GetStats() (*cgroups.Stats, error) {
|
2014-05-15 06:21:44 +08:00
|
|
|
return nil, fmt.Errorf("Systemd not supported")
|
|
|
|
}
|
2014-05-31 06:09:07 +08:00
|
|
|
|
2015-01-13 19:52:14 +08:00
|
|
|
func (m *Manager) Freeze(state cgroups.FreezerState) error {
|
|
|
|
return fmt.Errorf("Systemd not supported")
|
|
|
|
}
|
|
|
|
|
2014-10-15 04:31:23 +08:00
|
|
|
func ApplyDevices(c *cgroups.Cgroup, pid int) error {
|
|
|
|
return fmt.Errorf("Systemd not supported")
|
|
|
|
}
|
|
|
|
|
2014-05-31 06:09:07 +08:00
|
|
|
func Freeze(c *cgroups.Cgroup, state cgroups.FreezerState) error {
|
|
|
|
return fmt.Errorf("Systemd not supported")
|
|
|
|
}
|