Skip to content

Commit 02fcff8

Browse files
authored
chore: fix typo (#109)
1 parent 4d74620 commit 02fcff8

1 file changed

Lines changed: 9 additions & 9 deletions

File tree

pkg/util/networkpolicy/target.go

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -215,39 +215,39 @@ func (a APIServerNetworkPolicyTarget) ApplyToCiliumEgressNetworkPolicy(
215215
return a.ApplyToCiliumIngressNetworkPolicy(ciliumPolicyPeer)
216216
}
217217

218-
type InClusterAPISeverNetworkPolicyTarget struct{}
218+
type InClusterAPIServerNetworkPolicyTarget struct{}
219219

220-
func NewInClusterAPIServerNetworkPolicyTarget() InClusterAPISeverNetworkPolicyTarget {
221-
return InClusterAPISeverNetworkPolicyTarget{}
220+
func NewInClusterAPIServerNetworkPolicyTarget() InClusterAPIServerNetworkPolicyTarget {
221+
return InClusterAPIServerNetworkPolicyTarget{}
222222
}
223223

224224
var (
225-
_ IngressNetworkPolicyTarget = InClusterAPISeverNetworkPolicyTarget{}
226-
_ EgressNetworkPolicyTarget = InClusterAPISeverNetworkPolicyTarget{}
225+
_ IngressNetworkPolicyTarget = InClusterAPIServerNetworkPolicyTarget{}
226+
_ EgressNetworkPolicyTarget = InClusterAPIServerNetworkPolicyTarget{}
227227
)
228228

229-
func (i InClusterAPISeverNetworkPolicyTarget) ApplyToKubernetesIngressNetworkPolicy(
229+
func (i InClusterAPIServerNetworkPolicyTarget) ApplyToKubernetesIngressNetworkPolicy(
230230
networkPolicyPeerApplyConfiguration *networkingv1ac.NetworkPolicyPeerApplyConfiguration,
231231
) *networkingv1ac.NetworkPolicyPeerApplyConfiguration {
232232
// In-cluster API server filtering is not supported in NetworkPolicy, so we allow traffic to anywhere.
233233
return NewCIDRNetworkPolicyTarget("0.0.0.0/0").
234234
ApplyToKubernetesIngressNetworkPolicy(networkPolicyPeerApplyConfiguration)
235235
}
236236

237-
func (i InClusterAPISeverNetworkPolicyTarget) ApplyToKubernetesEgressNetworkPolicy(
237+
func (i InClusterAPIServerNetworkPolicyTarget) ApplyToKubernetesEgressNetworkPolicy(
238238
networkPolicyPeerApplyConfiguration *networkingv1ac.NetworkPolicyPeerApplyConfiguration,
239239
) *networkingv1ac.NetworkPolicyPeerApplyConfiguration {
240240
return i.ApplyToKubernetesIngressNetworkPolicy(networkPolicyPeerApplyConfiguration)
241241
}
242242

243-
func (i InClusterAPISeverNetworkPolicyTarget) ApplyToCiliumIngressNetworkPolicy(
243+
func (i InClusterAPIServerNetworkPolicyTarget) ApplyToCiliumIngressNetworkPolicy(
244244
ciliumPolicyPeer *CiliumPolicyPeer,
245245
) *CiliumPolicyPeer {
246246
ciliumPolicyPeer.Identities = append(ciliumPolicyPeer.Identities, api.EntityKubeAPIServer)
247247
return ciliumPolicyPeer
248248
}
249249

250-
func (i InClusterAPISeverNetworkPolicyTarget) ApplyToCiliumEgressNetworkPolicy(
250+
func (i InClusterAPIServerNetworkPolicyTarget) ApplyToCiliumEgressNetworkPolicy(
251251
ciliumPolicyPeer *CiliumPolicyPeer,
252252
) *CiliumPolicyPeer {
253253
return i.ApplyToCiliumIngressNetworkPolicy(ciliumPolicyPeer)

0 commit comments

Comments
 (0)