Skip to content

Commit

Permalink
Merge pull request #45 from s1061123/dev/remove-old-status
Browse files Browse the repository at this point in the history
Remove old network status annotation
  • Loading branch information
phoracek authored Feb 21, 2022
2 parents 9bd9a5d + 78b3280 commit 2fd7267
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 3 deletions.
2 changes: 0 additions & 2 deletions pkg/apis/k8s.cni.cncf.io/v1/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,6 @@ const (
NetworkAttachmentAnnot = "k8s.v1.cni.cncf.io/networks"
// Pod annotation for network status
NetworkStatusAnnot = "k8s.v1.cni.cncf.io/network-status"
// Old Pod annotation for network status (which is used before but it will be obsolated)
OldNetworkStatusAnnot = "k8s.v1.cni.cncf.io/networks-status"
)

// NoK8sNetworkError indicates error, no network in kubernetes
Expand Down
1 change: 0 additions & 1 deletion pkg/utils/net-attach-def.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,6 @@ func setPodNetworkStatus(client kubernetes.Interface, pod *corev1.Pod, networkst
pod.Annotations = make(map[string]string)
}
pod.Annotations[v1.NetworkStatusAnnot] = networkstatus
pod.Annotations[v1.OldNetworkStatusAnnot] = networkstatus
_, err = coreClient.Pods(namespace).UpdateStatus(context.TODO(), pod, metav1.UpdateOptions{})
return err
})
Expand Down

0 comments on commit 2fd7267

Please sign in to comment.