mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 19:56:01 +00:00
fix nits
This commit is contained in:
parent
2730d285cf
commit
778b8300bc
@ -52,7 +52,6 @@ const (
|
||||
|
||||
type PodGCController struct {
|
||||
kubeClient clientset.Interface
|
||||
ctx context.Context
|
||||
|
||||
podLister corelisters.PodLister
|
||||
podListerSynced cache.InformerSynced
|
||||
@ -82,11 +81,6 @@ func NewPodGC(ctx context.Context, kubeClient clientset.Interface, podInformer c
|
||||
return gcc
|
||||
}
|
||||
|
||||
func (gcc *PodGCController) deletePod(ctx context.Context, namespace, name string) error {
|
||||
klog.InfoS("PodGC is force deleting Pod", "pod", klog.KRef(namespace, name))
|
||||
return gcc.kubeClient.CoreV1().Pods(namespace).Delete(ctx, name, *metav1.NewDeleteOptions(0))
|
||||
}
|
||||
|
||||
func (gcc *PodGCController) Run(ctx context.Context) {
|
||||
defer utilruntime.HandleCrash()
|
||||
|
||||
@ -303,3 +297,8 @@ func (o byCreationTimestamp) Less(i, j int) bool {
|
||||
}
|
||||
return o[i].CreationTimestamp.Before(&o[j].CreationTimestamp)
|
||||
}
|
||||
|
||||
func (gcc *PodGCController) deletePod(ctx context.Context, namespace, name string) error {
|
||||
klog.InfoS("PodGC is force deleting Pod", "pod", klog.KRef(namespace, name))
|
||||
return gcc.kubeClient.CoreV1().Pods(namespace).Delete(ctx, name, *metav1.NewDeleteOptions(0))
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user