diff --git a/hack/update-codegen.sh b/hack/update-codegen.sh index 74211e31b..2f97f0d55 100755 --- a/hack/update-codegen.sh +++ b/hack/update-codegen.sh @@ -36,6 +36,10 @@ chmod +x ${CODEGEN_PKG}/kube_codegen.sh source ${CODEGEN_PKG}/kube_codegen.sh +kube::codegen::gen_helpers \ + --boilerplate "${SCRIPT_ROOT}/hack/boilerplate.go.txt" \ + ./pkg/apis + kube::codegen::gen_client \ --output-dir "${TEMP_DIR}/${PACKAGE_PATH_BASE}/pkg/client" \ --output-pkg "${PACKAGE_PATH_BASE}/pkg/client" \ diff --git a/pkg/apis/gatewayapi/v1beta1/doc.go b/pkg/apis/gatewayapi/v1beta1/doc.go index 6ab038a17..c75f64de1 100644 --- a/pkg/apis/gatewayapi/v1beta1/doc.go +++ b/pkg/apis/gatewayapi/v1beta1/doc.go @@ -1,4 +1,6 @@ // Package v1beta1 contains API Schema definitions for the // gateway.networking.k8s.io API group. +// +k8s:deepcopy-gen=package + package v1beta1 diff --git a/pkg/apis/gatewayapi/v1beta1/httproute_types.go b/pkg/apis/gatewayapi/v1beta1/httproute_types.go index 9da2eae8f..4b0d950ef 100644 --- a/pkg/apis/gatewayapi/v1beta1/httproute_types.go +++ b/pkg/apis/gatewayapi/v1beta1/httproute_types.go @@ -18,6 +18,7 @@ import ( ) // +genclient +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +kubebuilder:object:root=true // +kubebuilder:resource:categories=gateway-api // +kubebuilder:storageversion @@ -40,6 +41,7 @@ type HTTPRoute struct { Status HTTPRouteStatus `json:"status,omitempty"` } +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +kubebuilder:object:root=true // HTTPRouteList contains a list of HTTPRoute. diff --git a/pkg/apis/gatewayapi/v1beta1/zz_generated.deepcopy.go b/pkg/apis/gatewayapi/v1beta1/zz_generated.deepcopy.go index 269e40365..7938a9141 100644 --- a/pkg/apis/gatewayapi/v1beta1/zz_generated.deepcopy.go +++ b/pkg/apis/gatewayapi/v1beta1/zz_generated.deepcopy.go @@ -2,11 +2,14 @@ // +build !ignore_autogenerated /* -Copyright The Kubernetes Authors. +Copyright 2020 The Flux authors + Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at + http://www.apache.org/licenses/LICENSE-2.0 + Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. @@ -14,13 +17,13 @@ See the License for the specific language governing permissions and limitations under the License. */ -// Code generated by controller-gen. DO NOT EDIT. +// Code generated by deepcopy-gen. DO NOT EDIT. package v1beta1 import ( v1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" + runtime "k8s.io/apimachinery/pkg/runtime" ) // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. @@ -46,6 +49,7 @@ func (in *BackendObjectReference) DeepCopyInto(out *BackendObjectReference) { *out = new(PortNumber) **out = **in } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackendObjectReference. @@ -67,6 +71,7 @@ func (in *BackendRef) DeepCopyInto(out *BackendRef) { *out = new(int32) **out = **in } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackendRef. @@ -89,6 +94,7 @@ func (in *CommonRouteSpec) DeepCopyInto(out *CommonRouteSpec) { (*in)[i].DeepCopyInto(&(*out)[i]) } } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CommonRouteSpec. @@ -112,6 +118,7 @@ func (in *HTTPBackendRef) DeepCopyInto(out *HTTPBackendRef) { (*in)[i].DeepCopyInto(&(*out)[i]) } } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPBackendRef. @@ -127,6 +134,7 @@ func (in *HTTPBackendRef) DeepCopy() *HTTPBackendRef { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *HTTPHeader) DeepCopyInto(out *HTTPHeader) { *out = *in + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPHeader. @@ -157,6 +165,7 @@ func (in *HTTPHeaderFilter) DeepCopyInto(out *HTTPHeaderFilter) { *out = make([]string, len(*in)) copy(*out, *in) } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPHeaderFilter. @@ -177,6 +186,7 @@ func (in *HTTPHeaderMatch) DeepCopyInto(out *HTTPHeaderMatch) { *out = new(HeaderMatchType) **out = **in } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPHeaderMatch. @@ -202,6 +212,7 @@ func (in *HTTPPathMatch) DeepCopyInto(out *HTTPPathMatch) { *out = new(string) **out = **in } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPPathMatch. @@ -227,6 +238,7 @@ func (in *HTTPPathModifier) DeepCopyInto(out *HTTPPathModifier) { *out = new(string) **out = **in } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPPathModifier. @@ -247,6 +259,7 @@ func (in *HTTPQueryParamMatch) DeepCopyInto(out *HTTPQueryParamMatch) { *out = new(QueryParamMatchType) **out = **in } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPQueryParamMatch. @@ -263,6 +276,7 @@ func (in *HTTPQueryParamMatch) DeepCopy() *HTTPQueryParamMatch { func (in *HTTPRequestMirrorFilter) DeepCopyInto(out *HTTPRequestMirrorFilter) { *out = *in in.BackendRef.DeepCopyInto(&out.BackendRef) + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPRequestMirrorFilter. @@ -303,6 +317,7 @@ func (in *HTTPRequestRedirectFilter) DeepCopyInto(out *HTTPRequestRedirectFilter *out = new(int) **out = **in } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPRequestRedirectFilter. @@ -322,6 +337,7 @@ func (in *HTTPRoute) DeepCopyInto(out *HTTPRoute) { in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) in.Spec.DeepCopyInto(&out.Spec) in.Status.DeepCopyInto(&out.Status) + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPRoute. @@ -375,6 +391,7 @@ func (in *HTTPRouteFilter) DeepCopyInto(out *HTTPRouteFilter) { *out = new(LocalObjectReference) **out = **in } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPRouteFilter. @@ -399,6 +416,7 @@ func (in *HTTPRouteList) DeepCopyInto(out *HTTPRouteList) { (*in)[i].DeepCopyInto(&(*out)[i]) } } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPRouteList. @@ -446,6 +464,7 @@ func (in *HTTPRouteMatch) DeepCopyInto(out *HTTPRouteMatch) { *out = new(HTTPMethod) **out = **in } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPRouteMatch. @@ -482,6 +501,7 @@ func (in *HTTPRouteRule) DeepCopyInto(out *HTTPRouteRule) { (*in)[i].DeepCopyInto(&(*out)[i]) } } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPRouteRule. @@ -510,6 +530,7 @@ func (in *HTTPRouteSpec) DeepCopyInto(out *HTTPRouteSpec) { (*in)[i].DeepCopyInto(&(*out)[i]) } } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPRouteSpec. @@ -526,6 +547,7 @@ func (in *HTTPRouteSpec) DeepCopy() *HTTPRouteSpec { func (in *HTTPRouteStatus) DeepCopyInto(out *HTTPRouteStatus) { *out = *in in.RouteStatus.DeepCopyInto(&out.RouteStatus) + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPRouteStatus. @@ -551,6 +573,7 @@ func (in *HTTPURLRewriteFilter) DeepCopyInto(out *HTTPURLRewriteFilter) { *out = new(HTTPPathModifier) (*in).DeepCopyInto(*out) } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPURLRewriteFilter. @@ -566,6 +589,7 @@ func (in *HTTPURLRewriteFilter) DeepCopy() *HTTPURLRewriteFilter { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *LocalObjectReference) DeepCopyInto(out *LocalObjectReference) { *out = *in + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalObjectReference. @@ -606,6 +630,7 @@ func (in *ParentReference) DeepCopyInto(out *ParentReference) { *out = new(PortNumber) **out = **in } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParentReference. @@ -629,6 +654,7 @@ func (in *RouteParentStatus) DeepCopyInto(out *RouteParentStatus) { (*in)[i].DeepCopyInto(&(*out)[i]) } } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RouteParentStatus. @@ -651,6 +677,7 @@ func (in *RouteStatus) DeepCopyInto(out *RouteStatus) { (*in)[i].DeepCopyInto(&(*out)[i]) } } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RouteStatus. @@ -681,6 +708,7 @@ func (in *SecretObjectReference) DeepCopyInto(out *SecretObjectReference) { *out = new(Namespace) **out = **in } + return } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecretObjectReference. diff --git a/pkg/apis/gloo/v1/zz_generated.deepcopy.go b/pkg/apis/gloo/v1/zz_generated.deepcopy.go index 6f2313c32..3cae4a9db 100644 --- a/pkg/apis/gloo/v1/zz_generated.deepcopy.go +++ b/pkg/apis/gloo/v1/zz_generated.deepcopy.go @@ -1,6 +1,22 @@ //go:build !ignore_autogenerated // +build !ignore_autogenerated +/* +Copyright 2020 The Flux authors + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + // Code generated by deepcopy-gen. DO NOT EDIT. package v1