make forceSystemd private

pull/7815/head
Priya Wadhwa 2020-04-23 16:56:30 -07:00
parent cfb1d21982
commit 52b57374fc
4 changed files with 2 additions and 14 deletions

View File

@ -429,8 +429,3 @@ func addRepoTagToImageName(imgName string) string {
} // else it already has repo name dont add anything
return imgName
}
// TODO: Implement for containerd
func (r *Containerd) ForceSystemd() error {
return nil
}

View File

@ -229,8 +229,3 @@ func (r *CRIO) Preload(cfg config.KubernetesConfig) error {
}
return fmt.Errorf("not yet implemented for %s", r.Name())
}
// ForceSystemd does nothing for crio since it already uses systemd as cgroup manager
func (r *CRIO) ForceSystemd() error {
return nil
}

View File

@ -104,8 +104,6 @@ type Manager interface {
SystemLogCmd(int) string
// Preload preloads the container runtime with k8s images
Preload(config.KubernetesConfig) error
// ForceSystemd forces the container runtime to use systemd as cgroup manager
ForceSystemd() error
}
// Config is runtime configuration

View File

@ -111,7 +111,7 @@ func (r *Docker) Enable(disOthers, forceSystemd bool) error {
}
if forceSystemd {
if err := r.ForceSystemd(); err != nil {
if err := r.forceSystemd(); err != nil {
return err
}
}
@ -281,7 +281,7 @@ func (r *Docker) SystemLogCmd(len int) string {
}
// ForceSystemd forces the docker daemon to use systemd as cgroup manager
func (r *Docker) ForceSystemd() error {
func (r *Docker) forceSystemd() error {
daemonConfig := `{
"exec-opts": ["native.cgroupdriver=systemd"],
"log-driver": "json-file",