Skip to content

Commit

Permalink
Bump to 1.31.1 kube
Browse files Browse the repository at this point in the history
Signed-off-by: Surya Seetharaman <[email protected]>
  • Loading branch information
tssurya committed Nov 18, 2024
1 parent dfafbc5 commit 483d905
Show file tree
Hide file tree
Showing 35 changed files with 308 additions and 813 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/conformance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ on:
workflow_dispatch:

env:
GO_VERSION: "1.22.0"
K8S_VERSION: "v1.29.2"
KIND_VERSION: "v0.22.0"
GO_VERSION: "1.23"
K8S_VERSION: "v1.31.2"
KIND_VERSION: "v0.25.0"
IMAGE_NAME: registry.k8s.io/networking/kube-network-policies
KIND_CLUSTER_NAME: kind

Expand Down Expand Up @@ -79,7 +79,7 @@ jobs:
/usr/local/bin/kubectl apply -f ./config/crd/experimental/policy.networking.k8s.io_adminnetworkpolicies.yaml
/usr/local/bin/kubectl apply -f ./config/crd/experimental/policy.networking.k8s.io_baselineadminnetworkpolicies.yaml
# install kube-network-policies
/usr/local/bin/kubectl apply -f https://raw.githubusercontent.com/kubernetes-sigs/kube-network-policies/v0.2.0/install-anp.yaml
/usr/local/bin/kubectl apply -f https://raw.githubusercontent.com/kubernetes-sigs/kube-network-policies/v0.6.1/install-anp.yaml
- name: Get Cluster status
run: |
Expand All @@ -93,7 +93,7 @@ jobs:
- name: Run tests
run: |
go mod download
go test -v ./conformance -run TestConformanceProfiles -args --conformance-profiles=AdminNetworkPolicy,BaselineAdminNetworkPolicy --organization=kubernetes --project=kube-network-policies --url=https://github.com/kubernetes-sigs/kube-network-policies --version=0.2.0 [email protected] --additional-info=https://github.com/kubernetes-sigs/kube-network-policies
go test -v ./conformance -run TestConformanceProfiles -args --conformance-profiles=AdminNetworkPolicy,BaselineAdminNetworkPolicy --organization=kubernetes --project=kube-network-policies --url=https://github.com/kubernetes-sigs/kube-network-policies --version=0.6.1 [email protected] --additional-info=https://github.com/kubernetes-sigs/kube-network-policies
- name: Upload Junit Reports
if: always()
Expand Down
6 changes: 3 additions & 3 deletions apis/v1alpha1/shared_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ type AdminNetworkPolicyPort struct {
type Port struct {
// Protocol is the network protocol (TCP, UDP, or SCTP) which traffic must
// match. If not specified, this field defaults to TCP.
// +kubebuilder:default=TCP
//
// Support: Core
//
Expand All @@ -96,6 +97,7 @@ type Port struct {
type PortRange struct {
// Protocol is the network protocol (TCP, UDP, or SCTP) which traffic must
// match. If not specified, this field defaults to TCP.
// +kubebuilder:default=TCP
//
// Support: Core
//
Expand Down Expand Up @@ -145,8 +147,6 @@ type AdminNetworkPolicyIngressPeer struct {
}

// CIDR is an IP address range in CIDR notation (for example, "10.0.0.0/8" or "fd00::/8").
// This string must be validated by implementations using net.ParseCIDR
// TODO: Introduce CEL CIDR validation regex isCIDR() in Kube 1.31 when it is available.
// +kubebuilder:validation:XValidation:rule="self.contains(':') != self.contains('.')",message="CIDR must be either an IPv4 or IPv6 address. IPv4 address embedded in IPv6 addresses are not supported"
// +kubebuilder:validation:XValidation:rule="isCIDR(self)",message="Invalid CIDR format provided"
// +kubebuilder:validation:MaxLength=43
type CIDR string
Loading

0 comments on commit 483d905

Please sign in to comment.