diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md index e48e95f33bc14..249646017adae 100644 --- a/.github/ISSUE_TEMPLATE.md +++ b/.github/ISSUE_TEMPLATE.md @@ -1,6 +1,6 @@ -**Is this a request for help?** (If yes, you should use our troubleshooting guide and community support channels, see http://kubernetes.io/docs/troubleshooting/.): +**Is this a request for help?** (If yes, you should use our troubleshooting guide and community support channels, see https://kubernetes.io/docs/tasks/debug-application-cluster/troubleshooting/.): **Note:** Please file issues for subcomponents under the appropriate repo diff --git a/CHANGELOG.md b/CHANGELOG.md index 9a5acf2285b96..a89e7747f5204 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1801,7 +1801,7 @@ Features for this release were tracked via the use of the [kubernetes/features]( * PodSecurityPolicy resource is now enabled by default in the extensions API group. ([#39743](https://github.com/kubernetes/kubernetes/pull/39743), [@pweil-](https://github.com/pweil-)) ### RBAC -* the `attributeRestrictions` field has been removed from the PolicyRule type in the rbac.authorization.k8s.io/v1alpha1 API. The field was not used by the RBAC authorizer. ([#39625](https://github.com/kubernetes/kubernetes/pull/39625), [@deads2k](https://github.com/deads2k)) +* The `attributeRestrictions` field has been removed from the PolicyRule type in the rbac.authorization.k8s.io/v1alpha1 API. The field was not used by the RBAC authorizer. ([#39625](https://github.com/kubernetes/kubernetes/pull/39625), [@deads2k](https://github.com/deads2k)) * A user can now be authorized to bind a particular role by having permission to perform the `bind` verb on the referenced role ([#39383](https://github.com/kubernetes/kubernetes/pull/39383), [@liggitt](https://github.com/liggitt)) ### ReplicaSet @@ -1844,7 +1844,7 @@ Features for this release were tracked via the use of the [kubernetes/features]( ## Changes to Major Components ### API Server * **`--anonymous-auth` is enabled by default, unless the API server is started with the `AlwaysAllow` authorizer. ([#38706](https://github.com/kubernetes/kubernetes/pull/38706), [@deads2k](https://github.com/deads2k))** -* **when using OIDC authentication and specifying --oidc-username-claim=email, an `"email_verified":true` claim must be returned from the identity provider. ([#36087](https://github.com/kubernetes/kubernetes/pull/36087), [@ericchiang](https://github.com/ericchiang))** +* **When using OIDC authentication and specifying --oidc-username-claim=email, an `"email_verified":true` claim must be returned from the identity provider. ([#36087](https://github.com/kubernetes/kubernetes/pull/36087), [@ericchiang](https://github.com/ericchiang))** * `--basic-auth-file` supports optionally specifying groups in the fourth column of the file ([#39651](https://github.com/kubernetes/kubernetes/pull/39651), [@liggitt](https://github.com/liggitt)) * API server now has two separate limits for read-only and mutating inflight requests. ([#36064](https://github.com/kubernetes/kubernetes/pull/36064), [@gmarek](https://github.com/gmarek)) * Restored normalization of custom `--etcd-prefix` when `--storage-backend` is set to etcd3 ([#42506](https://github.com/kubernetes/kubernetes/pull/42506), [@liggitt](https://github.com/liggitt)) @@ -2238,9 +2238,9 @@ Features for this release were tracked via the use of the [kubernetes/features]( * Added support for creating HA clusters for centos using kube-up.sh. ([#39462](https://github.com/kubernetes/kubernetes/pull/39462), [@Shawyeok](https://github.com/Shawyeok)) * Enable lazy inode table and journal initialization for ext3 and ext4 ([#38865](https://github.com/kubernetes/kubernetes/pull/38865), [@codablock](https://github.com/codablock)) * Since `kubernetes.tar.gz` no longer includes client or server binaries, `cluster/kube-{up,down,push}.sh` now automatically download released binaries if they are missing. ([#38730](https://github.com/kubernetes/kubernetes/pull/38730), [@ixdy](https://github.com/ixdy)) -* fix broken cluster/centos and enhance the style ([#34002](https://github.com/kubernetes/kubernetes/pull/34002), [@xiaoping378](https://github.com/xiaoping378)) +* Fix broken cluster/centos and enhance the style ([#34002](https://github.com/kubernetes/kubernetes/pull/34002), [@xiaoping378](https://github.com/xiaoping378)) * Set kernel.softlockup_panic =1 based on the flag. ([#38001](https://github.com/kubernetes/kubernetes/pull/38001), [@dchen1107](https://github.com/dchen1107)) -* configure local-up-cluster.sh to handle auth proxies ([#36838](https://github.com/kubernetes/kubernetes/pull/36838), [@deads2k](https://github.com/deads2k)) +* Configure local-up-cluster.sh to handle auth proxies ([#36838](https://github.com/kubernetes/kubernetes/pull/36838), [@deads2k](https://github.com/deads2k)) * `kube-up.sh`/`kube-down.sh` no longer force update gcloud for provider=gce|gke. ([#36292](https://github.com/kubernetes/kubernetes/pull/36292), [@jlowdermilk](https://github.com/jlowdermilk)) * Collect logs for dead kubelets too ([#37671](https://github.com/kubernetes/kubernetes/pull/37671), [@mtaufen](https://github.com/mtaufen)) diff --git a/Godeps/Godeps.json b/Godeps/Godeps.json index cc4c30ff8ea03..58ab4b3491c4a 100644 --- a/Godeps/Godeps.json +++ b/Godeps/Godeps.json @@ -2739,6 +2739,10 @@ "ImportPath": "golang.org/x/time/rate", "Rev": "f51c12702a4d776e4c1fa9b0fabab841babae631" }, + { + "ImportPath": "golang.org/x/tools/container/intsets", + "Rev": "2382e3994d48b1d22acc2c86bcad0a2aff028e32" + }, { "ImportPath": "google.golang.org/api/cloudmonitoring/v2beta2", "Rev": "e3824ed33c72bf7e81da0286772c34b987520914" diff --git a/Godeps/LICENSES b/Godeps/LICENSES index 26cba7a370cdc..57cb8e1b842d3 100644 --- a/Godeps/LICENSES +++ b/Godeps/LICENSES @@ -83172,6 +83172,41 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ================================================================================ +================================================================================ += vendor/golang.org/x/tools/container/intsets licensed under: = + +Copyright (c) 2009 The Go Authors. All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google Inc. nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + += vendor/golang.org/x/tools/LICENSE 5d4950ecb7b26d2c5e4e7b4e0dd74707 - +================================================================================ + + ================================================================================ = vendor/google.golang.org/api/cloudmonitoring/v2beta2 licensed under: = diff --git a/api/openapi-spec/swagger.json b/api/openapi-spec/swagger.json index 8e3ac81abe989..0dff8e7808959 100644 --- a/api/openapi-spec/swagger.json +++ b/api/openapi-spec/swagger.json @@ -102,11 +102,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ComponentStatus" + "group": "", + "version": "v1", + "kind": "ComponentStatus" } }, "parameters": [ @@ -190,11 +190,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ComponentStatus" + "group": "", + "version": "v1", + "kind": "ComponentStatus" } }, "parameters": [ @@ -246,11 +246,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "parameters": [ @@ -336,11 +336,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Endpoints" + "group": "", + "version": "v1", + "kind": "Endpoints" } }, "parameters": [ @@ -426,11 +426,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "parameters": [ @@ -516,11 +516,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "LimitRange" + "group": "", + "version": "v1", + "kind": "LimitRange" } }, "parameters": [ @@ -650,11 +650,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "post": { @@ -695,90 +695,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" - } - }, - "delete": { - "description": "delete collection of Namespace", - "consumes": [ - "*/*" - ], - "produces": [ - "application/json", - "application/yaml", - "application/vnd.kubernetes.protobuf" - ], - "schemes": [ - "https" - ], - "tags": [ - "core_v1" - ], - "operationId": "deleteCoreV1CollectionNamespace", - "parameters": [ - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "name": "fieldSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "If true, partially initialized resources are included in the response.", - "name": "includeUninitialized", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - "name": "labelSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", - "name": "resourceVersion", - "in": "query" - }, - { - "uniqueItems": true, - "type": "integer", - "description": "Timeout for the list/watch call.", - "name": "timeoutSeconds", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - "name": "watch", - "in": "query" - } - ], - "responses": { - "200": { - "description": "OK", - "schema": { - "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Status" - } - }, - "401": { - "description": "Unauthorized" - } - }, - "x-kubernetes-action": "DELETECOLLECTION", - "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "parameters": [ @@ -830,11 +751,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Binding" + "group": "", + "version": "v1", + "kind": "Binding" } }, "parameters": [ @@ -930,11 +851,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "post": { @@ -975,11 +896,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "delete": { @@ -1054,11 +975,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "parameters": [ @@ -1124,11 +1045,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "put": { @@ -1169,11 +1090,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "delete": { @@ -1235,11 +1156,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "patch": { @@ -1282,11 +1203,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "parameters": [ @@ -1390,11 +1311,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Endpoints" + "group": "", + "version": "v1", + "kind": "Endpoints" } }, "post": { @@ -1435,11 +1356,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Endpoints" + "group": "", + "version": "v1", + "kind": "Endpoints" } }, "delete": { @@ -1514,11 +1435,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Endpoints" + "group": "", + "version": "v1", + "kind": "Endpoints" } }, "parameters": [ @@ -1584,11 +1505,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Endpoints" + "group": "", + "version": "v1", + "kind": "Endpoints" } }, "put": { @@ -1629,11 +1550,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Endpoints" + "group": "", + "version": "v1", + "kind": "Endpoints" } }, "delete": { @@ -1695,11 +1616,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Endpoints" + "group": "", + "version": "v1", + "kind": "Endpoints" } }, "patch": { @@ -1742,11 +1663,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Endpoints" + "group": "", + "version": "v1", + "kind": "Endpoints" } }, "parameters": [ @@ -1850,11 +1771,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "post": { @@ -1895,11 +1816,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "delete": { @@ -1974,11 +1895,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "parameters": [ @@ -2044,11 +1965,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "put": { @@ -2089,11 +2010,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "delete": { @@ -2155,11 +2076,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "patch": { @@ -2202,11 +2123,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "parameters": [ @@ -2310,11 +2231,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "LimitRange" + "group": "", + "version": "v1", + "kind": "LimitRange" } }, "post": { @@ -2355,11 +2276,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "LimitRange" + "group": "", + "version": "v1", + "kind": "LimitRange" } }, "delete": { @@ -2434,11 +2355,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "LimitRange" + "group": "", + "version": "v1", + "kind": "LimitRange" } }, "parameters": [ @@ -2504,11 +2425,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "LimitRange" + "group": "", + "version": "v1", + "kind": "LimitRange" } }, "put": { @@ -2549,11 +2470,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "LimitRange" + "group": "", + "version": "v1", + "kind": "LimitRange" } }, "delete": { @@ -2615,11 +2536,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "LimitRange" + "group": "", + "version": "v1", + "kind": "LimitRange" } }, "patch": { @@ -2662,11 +2583,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "LimitRange" + "group": "", + "version": "v1", + "kind": "LimitRange" } }, "parameters": [ @@ -2770,11 +2691,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "post": { @@ -2815,11 +2736,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "delete": { @@ -2894,11 +2815,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "parameters": [ @@ -2964,11 +2885,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "put": { @@ -3009,11 +2930,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "delete": { @@ -3075,11 +2996,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "patch": { @@ -3122,11 +3043,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "parameters": [ @@ -3184,11 +3105,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "put": { @@ -3229,11 +3150,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "patch": { @@ -3276,11 +3197,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "parameters": [ @@ -3384,11 +3305,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "post": { @@ -3429,11 +3350,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "delete": { @@ -3508,11 +3429,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -3578,11 +3499,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "put": { @@ -3623,11 +3544,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "delete": { @@ -3689,11 +3610,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "patch": { @@ -3736,11 +3657,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -3796,11 +3717,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "post": { @@ -3829,11 +3750,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -3929,11 +3850,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Binding" + "group": "", + "version": "v1", + "kind": "Binding" } }, "parameters": [ @@ -4001,11 +3922,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "Eviction" + "group": "policy", + "version": "v1beta1", + "kind": "Eviction" } }, "parameters": [ @@ -4061,11 +3982,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "post": { @@ -4094,11 +4015,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -4192,11 +4113,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -4301,11 +4222,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "post": { @@ -4334,11 +4255,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -4394,11 +4315,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "put": { @@ -4427,11 +4348,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "post": { @@ -4460,11 +4381,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "delete": { @@ -4493,11 +4414,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "options": { @@ -4526,11 +4447,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "head": { @@ -4559,11 +4480,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "patch": { @@ -4592,11 +4513,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -4652,11 +4573,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "put": { @@ -4685,11 +4606,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "post": { @@ -4718,11 +4639,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "delete": { @@ -4751,11 +4672,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "options": { @@ -4784,11 +4705,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "head": { @@ -4817,11 +4738,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "patch": { @@ -4850,11 +4771,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -4920,11 +4841,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "put": { @@ -4965,11 +4886,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "patch": { @@ -5012,11 +4933,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -5120,11 +5041,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PodTemplate" + "group": "", + "version": "v1", + "kind": "PodTemplate" } }, "post": { @@ -5165,11 +5086,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PodTemplate" + "group": "", + "version": "v1", + "kind": "PodTemplate" } }, "delete": { @@ -5244,11 +5165,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PodTemplate" + "group": "", + "version": "v1", + "kind": "PodTemplate" } }, "parameters": [ @@ -5314,11 +5235,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PodTemplate" + "group": "", + "version": "v1", + "kind": "PodTemplate" } }, "put": { @@ -5359,11 +5280,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PodTemplate" + "group": "", + "version": "v1", + "kind": "PodTemplate" } }, "delete": { @@ -5425,11 +5346,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PodTemplate" + "group": "", + "version": "v1", + "kind": "PodTemplate" } }, "patch": { @@ -5472,11 +5393,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PodTemplate" + "group": "", + "version": "v1", + "kind": "PodTemplate" } }, "parameters": [ @@ -5580,11 +5501,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "post": { @@ -5625,11 +5546,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "delete": { @@ -5704,11 +5625,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "parameters": [ @@ -5774,11 +5695,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "put": { @@ -5819,11 +5740,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "delete": { @@ -5885,11 +5806,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "patch": { @@ -5932,11 +5853,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "parameters": [ @@ -5994,11 +5915,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "Scale" + "group": "autoscaling", + "version": "v1", + "kind": "Scale" } }, "put": { @@ -6039,11 +5960,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "Scale" + "group": "autoscaling", + "version": "v1", + "kind": "Scale" } }, "patch": { @@ -6086,11 +6007,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "Scale" + "group": "autoscaling", + "version": "v1", + "kind": "Scale" } }, "parameters": [ @@ -6148,11 +6069,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "put": { @@ -6193,11 +6114,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "patch": { @@ -6240,11 +6161,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "parameters": [ @@ -6348,11 +6269,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "post": { @@ -6393,11 +6314,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "delete": { @@ -6472,11 +6393,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "parameters": [ @@ -6542,11 +6463,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "put": { @@ -6587,11 +6508,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "delete": { @@ -6653,11 +6574,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "patch": { @@ -6700,11 +6621,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "parameters": [ @@ -6762,11 +6683,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "put": { @@ -6807,11 +6728,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "patch": { @@ -6854,11 +6775,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "parameters": [ @@ -6962,11 +6883,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "post": { @@ -7007,11 +6928,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "delete": { @@ -7086,11 +7007,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "parameters": [ @@ -7156,11 +7077,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "put": { @@ -7201,11 +7122,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "delete": { @@ -7267,11 +7188,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "patch": { @@ -7314,11 +7235,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "parameters": [ @@ -7422,11 +7343,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ServiceAccount" + "group": "", + "version": "v1", + "kind": "ServiceAccount" } }, "post": { @@ -7467,11 +7388,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ServiceAccount" + "group": "", + "version": "v1", + "kind": "ServiceAccount" } }, "delete": { @@ -7546,11 +7467,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ServiceAccount" + "group": "", + "version": "v1", + "kind": "ServiceAccount" } }, "parameters": [ @@ -7616,11 +7537,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ServiceAccount" + "group": "", + "version": "v1", + "kind": "ServiceAccount" } }, "put": { @@ -7661,11 +7582,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ServiceAccount" + "group": "", + "version": "v1", + "kind": "ServiceAccount" } }, "delete": { @@ -7727,11 +7648,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ServiceAccount" + "group": "", + "version": "v1", + "kind": "ServiceAccount" } }, "patch": { @@ -7774,11 +7695,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ServiceAccount" + "group": "", + "version": "v1", + "kind": "ServiceAccount" } }, "parameters": [ @@ -7882,11 +7803,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "post": { @@ -7927,11 +7848,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -7997,11 +7918,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "put": { @@ -8042,11 +7963,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "delete": { @@ -8077,11 +7998,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "patch": { @@ -8124,11 +8045,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -8184,11 +8105,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "put": { @@ -8217,11 +8138,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "post": { @@ -8250,11 +8171,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "delete": { @@ -8283,11 +8204,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "options": { @@ -8316,11 +8237,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "head": { @@ -8349,11 +8270,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "patch": { @@ -8382,11 +8303,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -8442,11 +8363,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "put": { @@ -8475,11 +8396,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "post": { @@ -8508,11 +8429,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "delete": { @@ -8541,11 +8462,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "options": { @@ -8574,11 +8495,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "head": { @@ -8607,11 +8528,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "patch": { @@ -8640,11 +8561,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -8710,11 +8631,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "put": { @@ -8755,11 +8676,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "patch": { @@ -8802,11 +8723,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -8880,11 +8801,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "put": { @@ -8925,11 +8846,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "delete": { @@ -8991,11 +8912,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "patch": { @@ -9038,11 +8959,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "parameters": [ @@ -9102,11 +9023,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "parameters": [ @@ -9156,11 +9077,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "put": { @@ -9201,11 +9122,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "patch": { @@ -9248,11 +9169,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "parameters": [ @@ -9348,11 +9269,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "post": { @@ -9393,11 +9314,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "delete": { @@ -9472,11 +9393,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "parameters": [ @@ -9534,11 +9455,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "put": { @@ -9579,11 +9500,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "delete": { @@ -9645,11 +9566,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "patch": { @@ -9692,11 +9613,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "parameters": [ @@ -9744,11 +9665,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "put": { @@ -9777,11 +9698,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "post": { @@ -9810,11 +9731,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "delete": { @@ -9843,11 +9764,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "options": { @@ -9876,11 +9797,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "head": { @@ -9909,11 +9830,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "patch": { @@ -9942,11 +9863,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "parameters": [ @@ -9994,11 +9915,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "put": { @@ -10027,11 +9948,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "post": { @@ -10060,11 +9981,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "delete": { @@ -10093,11 +10014,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "options": { @@ -10126,11 +10047,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "head": { @@ -10159,11 +10080,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "patch": { @@ -10192,11 +10113,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "CONNECT", + "x-kubernetes-action": "connect", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "parameters": [ @@ -10254,11 +10175,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "put": { @@ -10299,11 +10220,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "patch": { @@ -10346,11 +10267,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "parameters": [ @@ -10402,11 +10323,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "parameters": [ @@ -10536,11 +10457,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolume" + "group": "", + "version": "v1", + "kind": "PersistentVolume" } }, "post": { @@ -10581,11 +10502,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolume" + "group": "", + "version": "v1", + "kind": "PersistentVolume" } }, "delete": { @@ -10660,11 +10581,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolume" + "group": "", + "version": "v1", + "kind": "PersistentVolume" } }, "parameters": [ @@ -10722,11 +10643,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolume" + "group": "", + "version": "v1", + "kind": "PersistentVolume" } }, "put": { @@ -10767,11 +10688,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolume" + "group": "", + "version": "v1", + "kind": "PersistentVolume" } }, "delete": { @@ -10833,11 +10754,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolume" + "group": "", + "version": "v1", + "kind": "PersistentVolume" } }, "patch": { @@ -10880,11 +10801,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolume" + "group": "", + "version": "v1", + "kind": "PersistentVolume" } }, "parameters": [ @@ -10934,11 +10855,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolume" + "group": "", + "version": "v1", + "kind": "PersistentVolume" } }, "put": { @@ -10979,11 +10900,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolume" + "group": "", + "version": "v1", + "kind": "PersistentVolume" } }, "patch": { @@ -11026,11 +10947,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolume" + "group": "", + "version": "v1", + "kind": "PersistentVolume" } }, "parameters": [ @@ -11082,11 +11003,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -11172,11 +11093,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PodTemplate" + "group": "", + "version": "v1", + "kind": "PodTemplate" } }, "parameters": [ @@ -11258,11 +11179,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "put": { @@ -11291,11 +11212,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "post": { @@ -11324,11 +11245,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "delete": { @@ -11357,11 +11278,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "options": { @@ -11390,11 +11311,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "head": { @@ -11423,11 +11344,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "patch": { @@ -11456,11 +11377,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -11509,11 +11430,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "put": { @@ -11542,11 +11463,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "post": { @@ -11575,11 +11496,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "delete": { @@ -11608,11 +11529,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "options": { @@ -11641,11 +11562,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "head": { @@ -11674,11 +11595,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "patch": { @@ -11707,11 +11628,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -11768,11 +11689,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "put": { @@ -11801,11 +11722,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "post": { @@ -11834,11 +11755,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "delete": { @@ -11867,11 +11788,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "options": { @@ -11900,11 +11821,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "head": { @@ -11933,11 +11854,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "patch": { @@ -11966,11 +11887,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -12019,11 +11940,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "put": { @@ -12052,11 +11973,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "post": { @@ -12085,11 +12006,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "delete": { @@ -12118,11 +12039,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "options": { @@ -12151,11 +12072,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "head": { @@ -12184,11 +12105,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "patch": { @@ -12217,11 +12138,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -12278,11 +12199,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "put": { @@ -12311,11 +12232,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "post": { @@ -12344,11 +12265,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "delete": { @@ -12377,11 +12298,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "options": { @@ -12410,11 +12331,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "head": { @@ -12443,11 +12364,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "patch": { @@ -12476,11 +12397,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "parameters": [ @@ -12521,11 +12442,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "put": { @@ -12554,11 +12475,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "post": { @@ -12587,11 +12508,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "delete": { @@ -12620,11 +12541,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "options": { @@ -12653,11 +12574,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "head": { @@ -12686,11 +12607,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "patch": { @@ -12719,11 +12640,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PROXY", + "x-kubernetes-action": "proxy", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "parameters": [ @@ -12776,11 +12697,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "parameters": [ @@ -12866,11 +12787,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "parameters": [ @@ -12956,11 +12877,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "parameters": [ @@ -13046,11 +12967,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ServiceAccount" + "group": "", + "version": "v1", + "kind": "ServiceAccount" } }, "parameters": [ @@ -13136,11 +13057,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -13226,11 +13147,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "parameters": [ @@ -13316,11 +13237,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Endpoints" + "group": "", + "version": "v1", + "kind": "Endpoints" } }, "parameters": [ @@ -13406,11 +13327,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "parameters": [ @@ -13496,11 +13417,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "LimitRange" + "group": "", + "version": "v1", + "kind": "LimitRange" } }, "parameters": [ @@ -13586,11 +13507,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "parameters": [ @@ -13676,11 +13597,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "parameters": [ @@ -13774,11 +13695,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "parameters": [ @@ -13880,11 +13801,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Endpoints" + "group": "", + "version": "v1", + "kind": "Endpoints" } }, "parameters": [ @@ -13978,11 +13899,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Endpoints" + "group": "", + "version": "v1", + "kind": "Endpoints" } }, "parameters": [ @@ -14084,11 +14005,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "parameters": [ @@ -14182,11 +14103,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "parameters": [ @@ -14288,11 +14209,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "LimitRange" + "group": "", + "version": "v1", + "kind": "LimitRange" } }, "parameters": [ @@ -14386,11 +14307,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "LimitRange" + "group": "", + "version": "v1", + "kind": "LimitRange" } }, "parameters": [ @@ -14492,11 +14413,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "parameters": [ @@ -14590,11 +14511,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "parameters": [ @@ -14696,11 +14617,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -14794,11 +14715,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -14900,11 +14821,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PodTemplate" + "group": "", + "version": "v1", + "kind": "PodTemplate" } }, "parameters": [ @@ -14998,11 +14919,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PodTemplate" + "group": "", + "version": "v1", + "kind": "PodTemplate" } }, "parameters": [ @@ -15104,11 +15025,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "parameters": [ @@ -15202,11 +15123,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "parameters": [ @@ -15308,11 +15229,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "parameters": [ @@ -15406,11 +15327,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "parameters": [ @@ -15512,11 +15433,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "parameters": [ @@ -15610,11 +15531,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "parameters": [ @@ -15716,11 +15637,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ServiceAccount" + "group": "", + "version": "v1", + "kind": "ServiceAccount" } }, "parameters": [ @@ -15814,11 +15735,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ServiceAccount" + "group": "", + "version": "v1", + "kind": "ServiceAccount" } }, "parameters": [ @@ -15920,11 +15841,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -16018,11 +15939,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -16124,11 +16045,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "parameters": [ @@ -16222,11 +16143,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "parameters": [ @@ -16312,11 +16233,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } }, "parameters": [ @@ -16410,11 +16331,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } }, "parameters": [ @@ -16500,11 +16421,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolume" + "group": "", + "version": "v1", + "kind": "PersistentVolume" } }, "parameters": [ @@ -16590,11 +16511,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolume" + "group": "", + "version": "v1", + "kind": "PersistentVolume" } }, "parameters": [ @@ -16688,11 +16609,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } }, "parameters": [ @@ -16778,11 +16699,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "PodTemplate" + "group": "", + "version": "v1", + "kind": "PodTemplate" } }, "parameters": [ @@ -16868,11 +16789,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } }, "parameters": [ @@ -16958,11 +16879,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } }, "parameters": [ @@ -17048,11 +16969,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "parameters": [ @@ -17138,11 +17059,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ServiceAccount" + "group": "", + "version": "v1", + "kind": "ServiceAccount" } }, "parameters": [ @@ -17228,11 +17149,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -17320,7 +17241,7 @@ } } }, - "/apis/apps/": { + "/apis/admissionregistration.k8s.io/": { "get": { "description": "get information of a group", "consumes": [ @@ -17337,9 +17258,9 @@ "https" ], "tags": [ - "apps" + "admissionregistration" ], - "operationId": "getAppsAPIGroup", + "operationId": "getAdmissionregistrationAPIGroup", "responses": { "200": { "description": "OK", @@ -17353,7 +17274,7 @@ } } }, - "/apis/apps/v1beta1/": { + "/apis/admissionregistration.k8s.io/v1alpha1/": { "get": { "description": "get available resources", "consumes": [ @@ -17370,9 +17291,9 @@ "https" ], "tags": [ - "apps_v1beta1" + "admissionregistration_v1alpha1" ], - "operationId": "getAppsV1beta1APIResources", + "operationId": "getAdmissionregistrationV1alpha1APIResources", "responses": { "200": { "description": "OK", @@ -17386,9 +17307,9 @@ } } }, - "/apis/apps/v1beta1/deployments": { + "/apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations": { "get": { - "description": "list or watch objects of kind Deployment", + "description": "list or watch objects of kind ExternalAdmissionHookConfiguration", "consumes": [ "*/*" ], @@ -17403,99 +17324,133 @@ "https" ], "tags": [ - "apps_v1beta1" + "admissionregistration_v1alpha1" + ], + "operationId": "listAdmissionregistrationV1alpha1ExternalAdmissionHookConfiguration", + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } ], - "operationId": "listAppsV1beta1DeploymentForAllNamespaces", "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.DeploymentList" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfigurationList" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "ExternalAdmissionHookConfiguration" } }, - "parameters": [ - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "name": "fieldSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "If true, partially initialized resources are included in the response.", - "name": "includeUninitialized", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - "name": "labelSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "If 'true', then the output is pretty printed.", - "name": "pretty", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", - "name": "resourceVersion", - "in": "query" - }, - { - "uniqueItems": true, - "type": "integer", - "description": "Timeout for the list/watch call.", - "name": "timeoutSeconds", - "in": "query" + "post": { + "description": "create an ExternalAdmissionHookConfiguration", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "admissionregistration_v1alpha1" + ], + "operationId": "createAdmissionregistrationV1alpha1ExternalAdmissionHookConfiguration", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfiguration" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfiguration" + } + }, + "401": { + "description": "Unauthorized" + } }, - { - "uniqueItems": true, - "type": "boolean", - "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - "name": "watch", - "in": "query" + "x-kubernetes-action": "post", + "x-kubernetes-group-version-kind": { + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "ExternalAdmissionHookConfiguration" } - ] - }, - "/apis/apps/v1beta1/namespaces/{namespace}/deployments": { - "get": { - "description": "list or watch objects of kind Deployment", + }, + "delete": { + "description": "delete collection of ExternalAdmissionHookConfiguration", "consumes": [ "*/*" ], "produces": [ "application/json", "application/yaml", - "application/vnd.kubernetes.protobuf", - "application/json;stream=watch", - "application/vnd.kubernetes.protobuf;stream=watch" + "application/vnd.kubernetes.protobuf" ], "schemes": [ "https" ], "tags": [ - "apps_v1beta1" + "admissionregistration_v1alpha1" ], - "operationId": "listAppsV1beta1NamespacedDeployment", + "operationId": "deleteAdmissionregistrationV1alpha1CollectionExternalAdmissionHookConfiguration", "parameters": [ { "uniqueItems": true, @@ -17544,22 +17499,33 @@ "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.DeploymentList" + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Status" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "ExternalAdmissionHookConfiguration" } }, - "post": { - "description": "create a Deployment", + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + } + ] + }, + "/apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations/{name}": { + "get": { + "description": "read the specified ExternalAdmissionHookConfiguration", "consumes": [ "*/*" ], @@ -17572,16 +17538,67 @@ "https" ], "tags": [ - "apps_v1beta1" + "admissionregistration_v1alpha1" ], - "operationId": "createAppsV1beta1NamespacedDeployment", + "operationId": "readAdmissionregistrationV1alpha1ExternalAdmissionHookConfiguration", + "parameters": [ + { + "uniqueItems": true, + "type": "boolean", + "description": "Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'.", + "name": "exact", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Should this value be exported. Export strips fields that a user can not specify.", + "name": "export", + "in": "query" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfiguration" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "get", + "x-kubernetes-group-version-kind": { + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "ExternalAdmissionHookConfiguration" + } + }, + "put": { + "description": "replace the specified ExternalAdmissionHookConfiguration", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "admissionregistration_v1alpha1" + ], + "operationId": "replaceAdmissionregistrationV1alpha1ExternalAdmissionHookConfiguration", "parameters": [ { "name": "body", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfiguration" } } ], @@ -17589,22 +17606,22 @@ "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfiguration" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "ExternalAdmissionHookConfiguration" } }, "delete": { - "description": "delete collection of Deployment", + "description": "delete an ExternalAdmissionHookConfiguration", "consumes": [ "*/*" ], @@ -17617,9 +17634,267 @@ "https" ], "tags": [ - "apps_v1beta1" + "admissionregistration_v1alpha1" ], - "operationId": "deleteAppsV1beta1CollectionNamespacedDeployment", + "operationId": "deleteAdmissionregistrationV1alpha1ExternalAdmissionHookConfiguration", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.DeleteOptions" + } + }, + { + "uniqueItems": true, + "type": "integer", + "description": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.", + "name": "gracePeriodSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.", + "name": "orphanDependents", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.", + "name": "propagationPolicy", + "in": "query" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Status" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "delete", + "x-kubernetes-group-version-kind": { + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "ExternalAdmissionHookConfiguration" + } + }, + "patch": { + "description": "partially update the specified ExternalAdmissionHookConfiguration", + "consumes": [ + "application/json-patch+json", + "application/merge-patch+json", + "application/strategic-merge-patch+json" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "admissionregistration_v1alpha1" + ], + "operationId": "patchAdmissionregistrationV1alpha1ExternalAdmissionHookConfiguration", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Patch" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfiguration" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "patch", + "x-kubernetes-group-version-kind": { + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "ExternalAdmissionHookConfiguration" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "name of the ExternalAdmissionHookConfiguration", + "name": "name", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + } + ] + }, + "/apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations": { + "get": { + "description": "list or watch objects of kind InitializerConfiguration", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "admissionregistration_v1alpha1" + ], + "operationId": "listAdmissionregistrationV1alpha1InitializerConfiguration", + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.InitializerConfigurationList" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "list", + "x-kubernetes-group-version-kind": { + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "InitializerConfiguration" + } + }, + "post": { + "description": "create an InitializerConfiguration", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "admissionregistration_v1alpha1" + ], + "operationId": "createAdmissionregistrationV1alpha1InitializerConfiguration", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.InitializerConfiguration" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.InitializerConfiguration" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "post", + "x-kubernetes-group-version-kind": { + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "InitializerConfiguration" + } + }, + "delete": { + "description": "delete collection of InitializerConfiguration", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "admissionregistration_v1alpha1" + ], + "operationId": "deleteAdmissionregistrationV1alpha1CollectionInitializerConfiguration", "parameters": [ { "uniqueItems": true, @@ -17675,22 +17950,14 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "InitializerConfiguration" } }, "parameters": [ - { - "uniqueItems": true, - "type": "string", - "description": "object name and auth scope, such as for teams and projects", - "name": "namespace", - "in": "path", - "required": true - }, { "uniqueItems": true, "type": "string", @@ -17700,9 +17967,9 @@ } ] }, - "/apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}": { + "/apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations/{name}": { "get": { - "description": "read the specified Deployment", + "description": "read the specified InitializerConfiguration", "consumes": [ "*/*" ], @@ -17715,9 +17982,9 @@ "https" ], "tags": [ - "apps_v1beta1" + "admissionregistration_v1alpha1" ], - "operationId": "readAppsV1beta1NamespacedDeployment", + "operationId": "readAdmissionregistrationV1alpha1InitializerConfiguration", "parameters": [ { "uniqueItems": true, @@ -17738,22 +18005,22 @@ "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.InitializerConfiguration" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "InitializerConfiguration" } }, "put": { - "description": "replace the specified Deployment", + "description": "replace the specified InitializerConfiguration", "consumes": [ "*/*" ], @@ -17766,16 +18033,16 @@ "https" ], "tags": [ - "apps_v1beta1" + "admissionregistration_v1alpha1" ], - "operationId": "replaceAppsV1beta1NamespacedDeployment", + "operationId": "replaceAdmissionregistrationV1alpha1InitializerConfiguration", "parameters": [ { "name": "body", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.InitializerConfiguration" } } ], @@ -17783,22 +18050,22 @@ "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.InitializerConfiguration" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "InitializerConfiguration" } }, "delete": { - "description": "delete a Deployment", + "description": "delete an InitializerConfiguration", "consumes": [ "*/*" ], @@ -17811,9 +18078,9 @@ "https" ], "tags": [ - "apps_v1beta1" + "admissionregistration_v1alpha1" ], - "operationId": "deleteAppsV1beta1NamespacedDeployment", + "operationId": "deleteAdmissionregistrationV1alpha1InitializerConfiguration", "parameters": [ { "name": "body", @@ -17856,15 +18123,15 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "InitializerConfiguration" } }, "patch": { - "description": "partially update the specified Deployment", + "description": "partially update the specified InitializerConfiguration", "consumes": [ "application/json-patch+json", "application/merge-patch+json", @@ -17879,9 +18146,9 @@ "https" ], "tags": [ - "apps_v1beta1" + "admissionregistration_v1alpha1" ], - "operationId": "patchAppsV1beta1NamespacedDeployment", + "operationId": "patchAdmissionregistrationV1alpha1InitializerConfiguration", "parameters": [ { "name": "body", @@ -17896,37 +18163,29 @@ "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.InitializerConfiguration" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "InitializerConfiguration" } }, "parameters": [ { "uniqueItems": true, "type": "string", - "description": "name of the Deployment", + "description": "name of the InitializerConfiguration", "name": "name", "in": "path", "required": true }, - { - "uniqueItems": true, - "type": "string", - "description": "object name and auth scope, such as for teams and projects", - "name": "namespace", - "in": "path", - "required": true - }, { "uniqueItems": true, "type": "string", @@ -17936,68 +18195,65 @@ } ] }, - "/apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/rollback": { - "post": { - "description": "create rollback of a DeploymentRollback", + "/apis/admissionregistration.k8s.io/v1alpha1/watch/externaladmissionhookconfigurations": { + "get": { + "description": "watch individual changes to a list of ExternalAdmissionHookConfiguration", "consumes": [ "*/*" ], "produces": [ "application/json", "application/yaml", - "application/vnd.kubernetes.protobuf" + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" ], "schemes": [ "https" ], "tags": [ - "apps_v1beta1" - ], - "operationId": "createAppsV1beta1NamespacedDeploymentRollbackRollback", - "parameters": [ - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.DeploymentRollback" - } - } + "admissionregistration_v1alpha1" ], + "operationId": "watchAdmissionregistrationV1alpha1ExternalAdmissionHookConfigurationList", "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.DeploymentRollback" + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "DeploymentRollback" + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "ExternalAdmissionHookConfiguration" } }, "parameters": [ { "uniqueItems": true, "type": "string", - "description": "name of the DeploymentRollback", - "name": "name", - "in": "path", - "required": true + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" }, { "uniqueItems": true, "type": "string", - "description": "object name and auth scope, such as for teams and projects", - "name": "namespace", - "in": "path", - "required": true + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" }, { "uniqueItems": true, @@ -18005,151 +18261,283 @@ "description": "If 'true', then the output is pretty printed.", "name": "pretty", "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" } ] }, - "/apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/scale": { + "/apis/admissionregistration.k8s.io/v1alpha1/watch/externaladmissionhookconfigurations/{name}": { "get": { - "description": "read scale of the specified Scale", + "description": "watch changes to an object of kind ExternalAdmissionHookConfiguration", "consumes": [ "*/*" ], "produces": [ "application/json", "application/yaml", - "application/vnd.kubernetes.protobuf" + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" ], "schemes": [ "https" ], "tags": [ - "apps_v1beta1" + "admissionregistration_v1alpha1" ], - "operationId": "readAppsV1beta1NamespacedScaleScale", + "operationId": "watchAdmissionregistrationV1alpha1ExternalAdmissionHookConfiguration", "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Scale" + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Scale" + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "ExternalAdmissionHookConfiguration" } }, - "put": { - "description": "replace scale of the specified Scale", + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "name of the ExternalAdmissionHookConfiguration", + "name": "name", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/admissionregistration.k8s.io/v1alpha1/watch/initializerconfigurations": { + "get": { + "description": "watch individual changes to a list of InitializerConfiguration", "consumes": [ "*/*" ], "produces": [ "application/json", "application/yaml", - "application/vnd.kubernetes.protobuf" + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" ], "schemes": [ "https" ], "tags": [ - "apps_v1beta1" - ], - "operationId": "replaceAppsV1beta1NamespacedScaleScale", - "parameters": [ - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Scale" - } - } + "admissionregistration_v1alpha1" ], + "operationId": "watchAdmissionregistrationV1alpha1InitializerConfigurationList", "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Scale" + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Scale" + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "InitializerConfiguration" } }, - "patch": { - "description": "partially update scale of the specified Scale", + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/admissionregistration.k8s.io/v1alpha1/watch/initializerconfigurations/{name}": { + "get": { + "description": "watch changes to an object of kind InitializerConfiguration", "consumes": [ - "application/json-patch+json", - "application/merge-patch+json", - "application/strategic-merge-patch+json" + "*/*" ], "produces": [ "application/json", "application/yaml", - "application/vnd.kubernetes.protobuf" + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" ], "schemes": [ "https" ], "tags": [ - "apps_v1beta1" - ], - "operationId": "patchAppsV1beta1NamespacedScaleScale", - "parameters": [ - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Patch" - } - } + "admissionregistration_v1alpha1" ], + "operationId": "watchAdmissionregistrationV1alpha1InitializerConfiguration", "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Scale" + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Scale" + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "InitializerConfiguration" } }, "parameters": [ { "uniqueItems": true, "type": "string", - "description": "name of the Scale", - "name": "name", - "in": "path", - "required": true + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" }, { "uniqueItems": true, "type": "string", - "description": "object name and auth scope, such as for teams and projects", - "name": "namespace", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "name of the InitializerConfiguration", + "name": "name", "in": "path", "required": true }, @@ -18159,14 +18547,37 @@ "description": "If 'true', then the output is pretty printed.", "name": "pretty", "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" } ] }, - "/apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/status": { + "/apis/apps/": { "get": { - "description": "read status of the specified Deployment", + "description": "get information of a group", "consumes": [ - "*/*" + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" ], "produces": [ "application/json", @@ -18177,31 +18588,29 @@ "https" ], "tags": [ - "apps_v1beta1" + "apps" ], - "operationId": "readAppsV1beta1NamespacedDeploymentStatus", + "operationId": "getAppsAPIGroup", "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.APIGroup" } }, "401": { "description": "Unauthorized" } - }, - "x-kubernetes-action": "GET", - "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" } - }, - "put": { - "description": "replace status of the specified Deployment", + } + }, + "/apis/apps/v1beta1/": { + "get": { + "description": "get available resources", "consumes": [ - "*/*" + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" ], "produces": [ "application/json", @@ -18214,46 +18623,32 @@ "tags": [ "apps_v1beta1" ], - "operationId": "replaceAppsV1beta1NamespacedDeploymentStatus", - "parameters": [ - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" - } - } - ], + "operationId": "getAppsV1beta1APIResources", "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.APIResourceList" } }, "401": { "description": "Unauthorized" } - }, - "x-kubernetes-action": "PUT", - "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" } - }, - "patch": { - "description": "partially update status of the specified Deployment", + } + }, + "/apis/apps/v1beta1/controllerrevisions": { + "get": { + "description": "list or watch objects of kind ControllerRevision", "consumes": [ - "application/json-patch+json", - "application/merge-patch+json", - "application/strategic-merge-patch+json" + "*/*" ], "produces": [ "application/json", "application/yaml", - "application/vnd.kubernetes.protobuf" + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" ], "schemes": [ "https" @@ -18261,51 +18656,46 @@ "tags": [ "apps_v1beta1" ], - "operationId": "patchAppsV1beta1NamespacedDeploymentStatus", - "parameters": [ - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Patch" - } - } - ], + "operationId": "listAppsV1beta1ControllerRevisionForAllNamespaces", "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.ControllerRevisionList" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "apps", + "version": "v1beta1", + "kind": "ControllerRevision" } }, "parameters": [ { "uniqueItems": true, "type": "string", - "description": "name of the Deployment", - "name": "name", - "in": "path", - "required": true + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" }, { "uniqueItems": true, "type": "string", - "description": "object name and auth scope, such as for teams and projects", - "name": "namespace", - "in": "path", - "required": true + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" }, { "uniqueItems": true, @@ -18313,12 +18703,33 @@ "description": "If 'true', then the output is pretty printed.", "name": "pretty", "in": "query" - } - ] - }, - "/apis/apps/v1beta1/namespaces/{namespace}/statefulsets": { + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/deployments": { "get": { - "description": "list or watch objects of kind StatefulSet", + "description": "list or watch objects of kind Deployment", "consumes": [ "*/*" ], @@ -18335,7 +18746,97 @@ "tags": [ "apps_v1beta1" ], - "operationId": "listAppsV1beta1NamespacedStatefulSet", + "operationId": "listAppsV1beta1DeploymentForAllNamespaces", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.DeploymentList" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "list", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions": { + "get": { + "description": "list or watch objects of kind ControllerRevision", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "listAppsV1beta1NamespacedControllerRevision", "parameters": [ { "uniqueItems": true, @@ -18384,22 +18885,22 @@ "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSetList" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.ControllerRevisionList" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "ControllerRevision" } }, "post": { - "description": "create a StatefulSet", + "description": "create a ControllerRevision", "consumes": [ "*/*" ], @@ -18414,14 +18915,14 @@ "tags": [ "apps_v1beta1" ], - "operationId": "createAppsV1beta1NamespacedStatefulSet", + "operationId": "createAppsV1beta1NamespacedControllerRevision", "parameters": [ { "name": "body", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.ControllerRevision" } } ], @@ -18429,22 +18930,22 @@ "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.ControllerRevision" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "ControllerRevision" } }, "delete": { - "description": "delete collection of StatefulSet", + "description": "delete collection of ControllerRevision", "consumes": [ "*/*" ], @@ -18459,7 +18960,7 @@ "tags": [ "apps_v1beta1" ], - "operationId": "deleteAppsV1beta1CollectionNamespacedStatefulSet", + "operationId": "deleteAppsV1beta1CollectionNamespacedControllerRevision", "parameters": [ { "uniqueItems": true, @@ -18515,11 +19016,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "ControllerRevision" } }, "parameters": [ @@ -18540,9 +19041,9 @@ } ] }, - "/apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}": { + "/apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions/{name}": { "get": { - "description": "read the specified StatefulSet", + "description": "read the specified ControllerRevision", "consumes": [ "*/*" ], @@ -18557,7 +19058,7 @@ "tags": [ "apps_v1beta1" ], - "operationId": "readAppsV1beta1NamespacedStatefulSet", + "operationId": "readAppsV1beta1NamespacedControllerRevision", "parameters": [ { "uniqueItems": true, @@ -18578,22 +19079,22 @@ "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.ControllerRevision" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "ControllerRevision" } }, "put": { - "description": "replace the specified StatefulSet", + "description": "replace the specified ControllerRevision", "consumes": [ "*/*" ], @@ -18608,14 +19109,14 @@ "tags": [ "apps_v1beta1" ], - "operationId": "replaceAppsV1beta1NamespacedStatefulSet", + "operationId": "replaceAppsV1beta1NamespacedControllerRevision", "parameters": [ { "name": "body", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.ControllerRevision" } } ], @@ -18623,22 +19124,22 @@ "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.ControllerRevision" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "ControllerRevision" } }, "delete": { - "description": "delete a StatefulSet", + "description": "delete a ControllerRevision", "consumes": [ "*/*" ], @@ -18653,7 +19154,7 @@ "tags": [ "apps_v1beta1" ], - "operationId": "deleteAppsV1beta1NamespacedStatefulSet", + "operationId": "deleteAppsV1beta1NamespacedControllerRevision", "parameters": [ { "name": "body", @@ -18696,15 +19197,15 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "ControllerRevision" } }, "patch": { - "description": "partially update the specified StatefulSet", + "description": "partially update the specified ControllerRevision", "consumes": [ "application/json-patch+json", "application/merge-patch+json", @@ -18721,7 +19222,7 @@ "tags": [ "apps_v1beta1" ], - "operationId": "patchAppsV1beta1NamespacedStatefulSet", + "operationId": "patchAppsV1beta1NamespacedControllerRevision", "parameters": [ { "name": "body", @@ -18736,25 +19237,25 @@ "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.ControllerRevision" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "ControllerRevision" } }, "parameters": [ { "uniqueItems": true, "type": "string", - "description": "name of the StatefulSet", + "description": "name of the ControllerRevision", "name": "name", "in": "path", "required": true @@ -18776,16 +19277,18 @@ } ] }, - "/apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}/status": { + "/apis/apps/v1beta1/namespaces/{namespace}/deployments": { "get": { - "description": "read status of the specified StatefulSet", + "description": "list or watch objects of kind Deployment", "consumes": [ "*/*" ], "produces": [ "application/json", "application/yaml", - "application/vnd.kubernetes.protobuf" + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" ], "schemes": [ "https" @@ -18793,27 +19296,71 @@ "tags": [ "apps_v1beta1" ], - "operationId": "readAppsV1beta1NamespacedStatefulSetStatus", + "operationId": "listAppsV1beta1NamespacedDeployment", + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ], "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.DeploymentList" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" } }, - "put": { - "description": "replace status of the specified StatefulSet", + "post": { + "description": "create a Deployment", "consumes": [ "*/*" ], @@ -18828,14 +19375,14 @@ "tags": [ "apps_v1beta1" ], - "operationId": "replaceAppsV1beta1NamespacedStatefulSetStatus", + "operationId": "createAppsV1beta1NamespacedDeployment", "parameters": [ { "name": "body", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" } } ], @@ -18843,26 +19390,24 @@ "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" } }, - "patch": { - "description": "partially update status of the specified StatefulSet", + "delete": { + "description": "delete collection of Deployment", "consumes": [ - "application/json-patch+json", - "application/merge-patch+json", - "application/strategic-merge-patch+json" + "*/*" ], "produces": [ "application/json", @@ -18875,44 +19420,70 @@ "tags": [ "apps_v1beta1" ], - "operationId": "patchAppsV1beta1NamespacedStatefulSetStatus", + "operationId": "deleteAppsV1beta1CollectionNamespacedDeployment", "parameters": [ { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Patch" - } + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" } ], "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Status" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ - { - "uniqueItems": true, - "type": "string", - "description": "name of the StatefulSet", - "name": "name", - "in": "path", - "required": true - }, { "uniqueItems": true, "type": "string", @@ -18930,18 +19501,16 @@ } ] }, - "/apis/apps/v1beta1/statefulsets": { + "/apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}": { "get": { - "description": "list or watch objects of kind StatefulSet", + "description": "read the specified Deployment", "consumes": [ "*/*" ], "produces": [ "application/json", "application/yaml", - "application/vnd.kubernetes.protobuf", - "application/json;stream=watch", - "application/vnd.kubernetes.protobuf;stream=watch" + "application/vnd.kubernetes.protobuf" ], "schemes": [ "https" @@ -18949,89 +19518,50 @@ "tags": [ "apps_v1beta1" ], - "operationId": "listAppsV1beta1StatefulSetForAllNamespaces", + "operationId": "readAppsV1beta1NamespacedDeployment", + "parameters": [ + { + "uniqueItems": true, + "type": "boolean", + "description": "Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'.", + "name": "exact", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Should this value be exported. Export strips fields that a user can not specify.", + "name": "export", + "in": "query" + } + ], "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSetList" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" } }, - "parameters": [ - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "name": "fieldSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "If true, partially initialized resources are included in the response.", - "name": "includeUninitialized", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - "name": "labelSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "If 'true', then the output is pretty printed.", - "name": "pretty", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", - "name": "resourceVersion", - "in": "query" - }, - { - "uniqueItems": true, - "type": "integer", - "description": "Timeout for the list/watch call.", - "name": "timeoutSeconds", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - "name": "watch", - "in": "query" - } - ] - }, - "/apis/apps/v1beta1/watch/deployments": { - "get": { - "description": "watch individual changes to a list of Deployment", + "put": { + "description": "replace the specified Deployment", "consumes": [ "*/*" ], "produces": [ "application/json", "application/yaml", - "application/vnd.kubernetes.protobuf", - "application/json;stream=watch", - "application/vnd.kubernetes.protobuf;stream=watch" + "application/vnd.kubernetes.protobuf" ], "schemes": [ "https" @@ -19039,89 +19569,112 @@ "tags": [ "apps_v1beta1" ], - "operationId": "watchAppsV1beta1DeploymentListForAllNamespaces", + "operationId": "replaceAppsV1beta1NamespacedDeployment", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + } + } + ], "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" } }, - "parameters": [ - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "name": "fieldSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "If true, partially initialized resources are included in the response.", - "name": "includeUninitialized", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - "name": "labelSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "If 'true', then the output is pretty printed.", - "name": "pretty", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", - "name": "resourceVersion", - "in": "query" - }, - { - "uniqueItems": true, - "type": "integer", - "description": "Timeout for the list/watch call.", - "name": "timeoutSeconds", - "in": "query" + "delete": { + "description": "delete a Deployment", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "deleteAppsV1beta1NamespacedDeployment", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.DeleteOptions" + } + }, + { + "uniqueItems": true, + "type": "integer", + "description": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.", + "name": "gracePeriodSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.", + "name": "orphanDependents", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.", + "name": "propagationPolicy", + "in": "query" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Status" + } + }, + "401": { + "description": "Unauthorized" + } }, - { - "uniqueItems": true, - "type": "boolean", - "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - "name": "watch", - "in": "query" + "x-kubernetes-action": "delete", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" } - ] - }, - "/apis/apps/v1beta1/watch/namespaces/{namespace}/deployments": { - "get": { - "description": "watch individual changes to a list of Deployment", + }, + "patch": { + "description": "partially update the specified Deployment", "consumes": [ - "*/*" + "application/json-patch+json", + "application/merge-patch+json", + "application/strategic-merge-patch+json" ], "produces": [ "application/json", "application/yaml", - "application/vnd.kubernetes.protobuf", - "application/json;stream=watch", - "application/vnd.kubernetes.protobuf;stream=watch" + "application/vnd.kubernetes.protobuf" ], "schemes": [ "https" @@ -19129,32 +19682,1574 @@ "tags": [ "apps_v1beta1" ], - "operationId": "watchAppsV1beta1NamespacedDeploymentList", + "operationId": "patchAppsV1beta1NamespacedDeployment", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Patch" + } + } + ], "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ { "uniqueItems": true, "type": "string", - "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "name": "fieldSelector", - "in": "query" + "description": "name of the Deployment", + "name": "name", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/rollback": { + "post": { + "description": "create rollback of a DeploymentRollback", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "createAppsV1beta1NamespacedDeploymentRollbackRollback", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.DeploymentRollback" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.DeploymentRollback" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "post", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "DeploymentRollback" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "name of the DeploymentRollback", + "name": "name", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/scale": { + "get": { + "description": "read scale of the specified Scale", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "readAppsV1beta1NamespacedScaleScale", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Scale" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "get", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "Scale" + } + }, + "put": { + "description": "replace scale of the specified Scale", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "replaceAppsV1beta1NamespacedScaleScale", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Scale" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Scale" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "put", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "Scale" + } + }, + "patch": { + "description": "partially update scale of the specified Scale", + "consumes": [ + "application/json-patch+json", + "application/merge-patch+json", + "application/strategic-merge-patch+json" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "patchAppsV1beta1NamespacedScaleScale", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Patch" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Scale" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "patch", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "Scale" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "name of the Scale", + "name": "name", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/status": { + "get": { + "description": "read status of the specified Deployment", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "readAppsV1beta1NamespacedDeploymentStatus", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "get", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" + } + }, + "put": { + "description": "replace status of the specified Deployment", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "replaceAppsV1beta1NamespacedDeploymentStatus", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "put", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" + } + }, + "patch": { + "description": "partially update status of the specified Deployment", + "consumes": [ + "application/json-patch+json", + "application/merge-patch+json", + "application/strategic-merge-patch+json" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "patchAppsV1beta1NamespacedDeploymentStatus", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Patch" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "patch", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "name of the Deployment", + "name": "name", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/namespaces/{namespace}/statefulsets": { + "get": { + "description": "list or watch objects of kind StatefulSet", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "listAppsV1beta1NamespacedStatefulSet", + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSetList" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "list", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" + } + }, + "post": { + "description": "create a StatefulSet", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "createAppsV1beta1NamespacedStatefulSet", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "post", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" + } + }, + "delete": { + "description": "delete collection of StatefulSet", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "deleteAppsV1beta1CollectionNamespacedStatefulSet", + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Status" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "deletecollection", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}": { + "get": { + "description": "read the specified StatefulSet", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "readAppsV1beta1NamespacedStatefulSet", + "parameters": [ + { + "uniqueItems": true, + "type": "boolean", + "description": "Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'.", + "name": "exact", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Should this value be exported. Export strips fields that a user can not specify.", + "name": "export", + "in": "query" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "get", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" + } + }, + "put": { + "description": "replace the specified StatefulSet", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "replaceAppsV1beta1NamespacedStatefulSet", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "put", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" + } + }, + "delete": { + "description": "delete a StatefulSet", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "deleteAppsV1beta1NamespacedStatefulSet", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.DeleteOptions" + } + }, + { + "uniqueItems": true, + "type": "integer", + "description": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.", + "name": "gracePeriodSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.", + "name": "orphanDependents", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.", + "name": "propagationPolicy", + "in": "query" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Status" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "delete", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" + } + }, + "patch": { + "description": "partially update the specified StatefulSet", + "consumes": [ + "application/json-patch+json", + "application/merge-patch+json", + "application/strategic-merge-patch+json" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "patchAppsV1beta1NamespacedStatefulSet", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Patch" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "patch", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "name of the StatefulSet", + "name": "name", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}/status": { + "get": { + "description": "read status of the specified StatefulSet", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "readAppsV1beta1NamespacedStatefulSetStatus", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "get", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" + } + }, + "put": { + "description": "replace status of the specified StatefulSet", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "replaceAppsV1beta1NamespacedStatefulSetStatus", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "put", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" + } + }, + "patch": { + "description": "partially update status of the specified StatefulSet", + "consumes": [ + "application/json-patch+json", + "application/merge-patch+json", + "application/strategic-merge-patch+json" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "patchAppsV1beta1NamespacedStatefulSetStatus", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Patch" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSet" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "patch", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "name of the StatefulSet", + "name": "name", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/statefulsets": { + "get": { + "description": "list or watch objects of kind StatefulSet", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "listAppsV1beta1StatefulSetForAllNamespaces", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.StatefulSetList" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "list", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/watch/controllerrevisions": { + "get": { + "description": "watch individual changes to a list of ControllerRevision", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "watchAppsV1beta1ControllerRevisionListForAllNamespaces", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "watchlist", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "ControllerRevision" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/watch/deployments": { + "get": { + "description": "watch individual changes to a list of Deployment", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "watchAppsV1beta1DeploymentListForAllNamespaces", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "watchlist", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/watch/namespaces/{namespace}/controllerrevisions": { + "get": { + "description": "watch individual changes to a list of ControllerRevision", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "watchAppsV1beta1NamespacedControllerRevisionList", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "watchlist", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "ControllerRevision" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/watch/namespaces/{namespace}/controllerrevisions/{name}": { + "get": { + "description": "watch changes to an object of kind ControllerRevision", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "watchAppsV1beta1NamespacedControllerRevision", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "watch", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "ControllerRevision" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "name of the ControllerRevision", + "name": "name", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/apps/v1beta1/watch/namespaces/{namespace}/deployments": { + "get": { + "description": "watch individual changes to a list of Deployment", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "apps_v1beta1" + ], + "operationId": "watchAppsV1beta1NamespacedDeploymentList", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "watchlist", + "x-kubernetes-group-version-kind": { + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" }, { "uniqueItems": true, @@ -19239,11 +21334,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ @@ -19345,11 +21440,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" } }, "parameters": [ @@ -19443,11 +21538,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" } }, "parameters": [ @@ -19549,11 +21644,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" } }, "parameters": [ @@ -19713,11 +21808,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "authentication.k8s.io", - "Version": "v1", - "Kind": "TokenReview" + "group": "authentication.k8s.io", + "version": "v1", + "kind": "TokenReview" } }, "parameters": [ @@ -19802,11 +21897,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "authentication.k8s.io", - "Version": "v1beta1", - "Kind": "TokenReview" + "group": "authentication.k8s.io", + "version": "v1beta1", + "kind": "TokenReview" } }, "parameters": [ @@ -19924,11 +22019,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "authorization.k8s.io", - "Version": "v1", - "Kind": "LocalSubjectAccessReview" + "group": "authorization.k8s.io", + "version": "v1", + "kind": "LocalSubjectAccessReview" } }, "parameters": [ @@ -19988,11 +22083,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "authorization.k8s.io", - "Version": "v1", - "Kind": "SelfSubjectAccessReview" + "group": "authorization.k8s.io", + "version": "v1", + "kind": "SelfSubjectAccessReview" } }, "parameters": [ @@ -20044,11 +22139,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "authorization.k8s.io", - "Version": "v1", - "Kind": "SubjectAccessReview" + "group": "authorization.k8s.io", + "version": "v1", + "kind": "SubjectAccessReview" } }, "parameters": [ @@ -20133,11 +22228,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "authorization.k8s.io", - "Version": "v1beta1", - "Kind": "LocalSubjectAccessReview" + "group": "authorization.k8s.io", + "version": "v1beta1", + "kind": "LocalSubjectAccessReview" } }, "parameters": [ @@ -20197,11 +22292,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "authorization.k8s.io", - "Version": "v1beta1", - "Kind": "SelfSubjectAccessReview" + "group": "authorization.k8s.io", + "version": "v1beta1", + "kind": "SelfSubjectAccessReview" } }, "parameters": [ @@ -20253,11 +22348,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "authorization.k8s.io", - "Version": "v1beta1", - "Kind": "SubjectAccessReview" + "group": "authorization.k8s.io", + "version": "v1beta1", + "kind": "SubjectAccessReview" } }, "parameters": [ @@ -20367,11 +22462,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -20501,11 +22596,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "post": { @@ -20546,11 +22641,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "delete": { @@ -20625,11 +22720,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -20695,11 +22790,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "put": { @@ -20740,11 +22835,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "delete": { @@ -20806,11 +22901,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "patch": { @@ -20853,11 +22948,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -20915,11 +23010,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "put": { @@ -20960,11 +23055,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "patch": { @@ -21007,11 +23102,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -21071,11 +23166,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -21161,11 +23256,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -21259,11 +23354,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -21398,11 +23493,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -21532,11 +23627,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "post": { @@ -21577,11 +23672,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "delete": { @@ -21656,11 +23751,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -21726,11 +23821,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "put": { @@ -21771,11 +23866,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "delete": { @@ -21837,11 +23932,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "patch": { @@ -21884,11 +23979,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -21946,11 +24041,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "put": { @@ -21991,11 +24086,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "patch": { @@ -22038,11 +24133,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -22102,11 +24197,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -22192,11 +24287,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -22290,11 +24385,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } }, "parameters": [ @@ -22462,11 +24557,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "parameters": [ @@ -22596,11 +24691,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "post": { @@ -22641,11 +24736,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "delete": { @@ -22720,11 +24815,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "parameters": [ @@ -22790,11 +24885,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "put": { @@ -22835,11 +24930,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "delete": { @@ -22901,11 +24996,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "patch": { @@ -22948,11 +25043,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "parameters": [ @@ -23010,11 +25105,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "put": { @@ -23055,11 +25150,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "patch": { @@ -23102,11 +25197,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "parameters": [ @@ -23166,11 +25261,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "parameters": [ @@ -23256,11 +25351,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "parameters": [ @@ -23354,11 +25449,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } }, "parameters": [ @@ -23493,11 +25588,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "parameters": [ @@ -23627,11 +25722,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "post": { @@ -23672,11 +25767,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "delete": { @@ -23751,11 +25846,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "parameters": [ @@ -23821,11 +25916,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "put": { @@ -23866,11 +25961,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "delete": { @@ -23932,11 +26027,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "patch": { @@ -23979,11 +26074,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "parameters": [ @@ -24041,11 +26136,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "put": { @@ -24086,11 +26181,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "patch": { @@ -24133,11 +26228,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "parameters": [ @@ -24241,11 +26336,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "post": { @@ -24286,11 +26381,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "delete": { @@ -24365,11 +26460,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "parameters": [ @@ -24435,11 +26530,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "put": { @@ -24480,11 +26575,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "delete": { @@ -24546,11 +26641,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "patch": { @@ -24593,11 +26688,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "parameters": [ @@ -24655,11 +26750,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "put": { @@ -24700,11 +26795,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "patch": { @@ -24747,11 +26842,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "parameters": [ @@ -24811,11 +26906,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "parameters": [ @@ -24901,11 +26996,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "parameters": [ @@ -24991,11 +27086,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "parameters": [ @@ -25089,11 +27184,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" } }, "parameters": [ @@ -25195,11 +27290,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "parameters": [ @@ -25293,11 +27388,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "parameters": [ @@ -25399,11 +27494,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } }, "parameters": [ @@ -25599,11 +27694,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "certificates.k8s.io", - "Version": "v1beta1", - "Kind": "CertificateSigningRequest" + "group": "certificates.k8s.io", + "version": "v1beta1", + "kind": "CertificateSigningRequest" } }, "post": { @@ -25644,11 +27739,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "certificates.k8s.io", - "Version": "v1beta1", - "Kind": "CertificateSigningRequest" + "group": "certificates.k8s.io", + "version": "v1beta1", + "kind": "CertificateSigningRequest" } }, "delete": { @@ -25723,11 +27818,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "certificates.k8s.io", - "Version": "v1beta1", - "Kind": "CertificateSigningRequest" + "group": "certificates.k8s.io", + "version": "v1beta1", + "kind": "CertificateSigningRequest" } }, "parameters": [ @@ -25785,11 +27880,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "certificates.k8s.io", - "Version": "v1beta1", - "Kind": "CertificateSigningRequest" + "group": "certificates.k8s.io", + "version": "v1beta1", + "kind": "CertificateSigningRequest" } }, "put": { @@ -25830,11 +27925,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "certificates.k8s.io", - "Version": "v1beta1", - "Kind": "CertificateSigningRequest" + "group": "certificates.k8s.io", + "version": "v1beta1", + "kind": "CertificateSigningRequest" } }, "delete": { @@ -25896,11 +27991,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "certificates.k8s.io", - "Version": "v1beta1", - "Kind": "CertificateSigningRequest" + "group": "certificates.k8s.io", + "version": "v1beta1", + "kind": "CertificateSigningRequest" } }, "patch": { @@ -25943,11 +28038,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "certificates.k8s.io", - "Version": "v1beta1", - "Kind": "CertificateSigningRequest" + "group": "certificates.k8s.io", + "version": "v1beta1", + "kind": "CertificateSigningRequest" } }, "parameters": [ @@ -26007,11 +28102,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "certificates.k8s.io", - "Version": "v1beta1", - "Kind": "CertificateSigningRequest" + "group": "certificates.k8s.io", + "version": "v1beta1", + "kind": "CertificateSigningRequest" } }, "parameters": [ @@ -26071,11 +28166,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "certificates.k8s.io", - "Version": "v1beta1", - "Kind": "CertificateSigningRequest" + "group": "certificates.k8s.io", + "version": "v1beta1", + "kind": "CertificateSigningRequest" } }, "parameters": [ @@ -26127,11 +28222,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "certificates.k8s.io", - "Version": "v1beta1", - "Kind": "CertificateSigningRequest" + "group": "certificates.k8s.io", + "version": "v1beta1", + "kind": "CertificateSigningRequest" } }, "parameters": [ @@ -26217,11 +28312,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "certificates.k8s.io", - "Version": "v1beta1", - "Kind": "CertificateSigningRequest" + "group": "certificates.k8s.io", + "version": "v1beta1", + "kind": "CertificateSigningRequest" } }, "parameters": [ @@ -26381,11 +28476,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "parameters": [ @@ -26471,11 +28566,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ @@ -26561,11 +28656,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "parameters": [ @@ -26695,11 +28790,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "post": { @@ -26740,11 +28835,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "delete": { @@ -26819,11 +28914,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "parameters": [ @@ -26889,11 +28984,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "put": { @@ -26934,11 +29029,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "delete": { @@ -27000,11 +29095,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "patch": { @@ -27047,11 +29142,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "parameters": [ @@ -27109,11 +29204,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "put": { @@ -27154,11 +29249,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "patch": { @@ -27201,11 +29296,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "parameters": [ @@ -27309,11 +29404,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "post": { @@ -27354,11 +29449,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "delete": { @@ -27433,11 +29528,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ @@ -27503,11 +29598,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "put": { @@ -27548,11 +29643,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "delete": { @@ -27614,11 +29709,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "patch": { @@ -27661,11 +29756,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ @@ -27733,11 +29828,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DeploymentRollback" + "group": "extensions", + "version": "v1beta1", + "kind": "DeploymentRollback" } }, "parameters": [ @@ -27795,11 +29890,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "put": { @@ -27840,11 +29935,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "patch": { @@ -27887,11 +29982,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "parameters": [ @@ -27949,11 +30044,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "put": { @@ -27994,11 +30089,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "patch": { @@ -28041,11 +30136,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ @@ -28149,11 +30244,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "post": { @@ -28194,11 +30289,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "delete": { @@ -28273,11 +30368,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "parameters": [ @@ -28343,11 +30438,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "put": { @@ -28388,11 +30483,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "delete": { @@ -28454,11 +30549,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "patch": { @@ -28501,11 +30596,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "parameters": [ @@ -28563,11 +30658,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "put": { @@ -28608,11 +30703,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "patch": { @@ -28655,11 +30750,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "parameters": [ @@ -28763,11 +30858,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "NetworkPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "NetworkPolicy" } }, "post": { @@ -28808,11 +30903,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "NetworkPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "NetworkPolicy" } }, "delete": { @@ -28887,11 +30982,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "NetworkPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "NetworkPolicy" } }, "parameters": [ @@ -28957,11 +31052,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "NetworkPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "NetworkPolicy" } }, "put": { @@ -29002,11 +31097,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "NetworkPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "NetworkPolicy" } }, "delete": { @@ -29068,11 +31163,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "NetworkPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "NetworkPolicy" } }, "patch": { @@ -29115,11 +31210,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "NetworkPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "NetworkPolicy" } }, "parameters": [ @@ -29223,11 +31318,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "post": { @@ -29268,11 +31363,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "delete": { @@ -29347,11 +31442,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "parameters": [ @@ -29417,11 +31512,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "put": { @@ -29462,11 +31557,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "delete": { @@ -29528,11 +31623,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "patch": { @@ -29575,11 +31670,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "parameters": [ @@ -29637,11 +31732,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "put": { @@ -29682,11 +31777,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "patch": { @@ -29729,11 +31824,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "parameters": [ @@ -29791,11 +31886,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "put": { @@ -29836,11 +31931,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "patch": { @@ -29883,11 +31978,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "parameters": [ @@ -29945,11 +32040,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "put": { @@ -29990,11 +32085,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "patch": { @@ -30037,11 +32132,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "parameters": [ @@ -30101,11 +32196,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "NetworkPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "NetworkPolicy" } }, "parameters": [ @@ -30235,11 +32330,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "PodSecurityPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "PodSecurityPolicy" } }, "post": { @@ -30280,11 +32375,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "PodSecurityPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "PodSecurityPolicy" } }, "delete": { @@ -30359,11 +32454,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "PodSecurityPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "PodSecurityPolicy" } }, "parameters": [ @@ -30421,11 +32516,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "PodSecurityPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "PodSecurityPolicy" } }, "put": { @@ -30466,11 +32561,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "PodSecurityPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "PodSecurityPolicy" } }, "delete": { @@ -30532,11 +32627,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "PodSecurityPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "PodSecurityPolicy" } }, "patch": { @@ -30579,11 +32674,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "PodSecurityPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "PodSecurityPolicy" } }, "parameters": [ @@ -30635,11 +32730,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "parameters": [ @@ -30769,11 +32864,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ThirdPartyResource" + "group": "extensions", + "version": "v1beta1", + "kind": "ThirdPartyResource" } }, "post": { @@ -30814,11 +32909,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ThirdPartyResource" + "group": "extensions", + "version": "v1beta1", + "kind": "ThirdPartyResource" } }, "delete": { @@ -30893,11 +32988,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ThirdPartyResource" + "group": "extensions", + "version": "v1beta1", + "kind": "ThirdPartyResource" } }, "parameters": [ @@ -30955,11 +33050,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ThirdPartyResource" + "group": "extensions", + "version": "v1beta1", + "kind": "ThirdPartyResource" } }, "put": { @@ -31000,11 +33095,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ThirdPartyResource" + "group": "extensions", + "version": "v1beta1", + "kind": "ThirdPartyResource" } }, "delete": { @@ -31066,11 +33161,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ThirdPartyResource" + "group": "extensions", + "version": "v1beta1", + "kind": "ThirdPartyResource" } }, "patch": { @@ -31113,11 +33208,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ThirdPartyResource" + "group": "extensions", + "version": "v1beta1", + "kind": "ThirdPartyResource" } }, "parameters": [ @@ -31169,11 +33264,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "parameters": [ @@ -31259,11 +33354,493 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", + "x-kubernetes-group-version-kind": { + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/extensions/v1beta1/watch/ingresses": { + "get": { + "description": "watch individual changes to a list of Ingress", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "extensions_v1beta1" + ], + "operationId": "watchExtensionsV1beta1IngressListForAllNamespaces", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "watchlist", + "x-kubernetes-group-version-kind": { + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/extensions/v1beta1/watch/namespaces/{namespace}/daemonsets": { + "get": { + "description": "watch individual changes to a list of DaemonSet", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "extensions_v1beta1" + ], + "operationId": "watchExtensionsV1beta1NamespacedDaemonSetList", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "watchlist", + "x-kubernetes-group-version-kind": { + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/extensions/v1beta1/watch/namespaces/{namespace}/daemonsets/{name}": { + "get": { + "description": "watch changes to an object of kind DaemonSet", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "extensions_v1beta1" + ], + "operationId": "watchExtensionsV1beta1NamespacedDaemonSet", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "watch", + "x-kubernetes-group-version-kind": { + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "name of the DaemonSet", + "name": "name", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/extensions/v1beta1/watch/namespaces/{namespace}/deployments": { + "get": { + "description": "watch individual changes to a list of Deployment", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "extensions_v1beta1" + ], + "operationId": "watchExtensionsV1beta1NamespacedDeploymentList", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "watchlist", + "x-kubernetes-group-version-kind": { + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/extensions/v1beta1/watch/namespaces/{namespace}/deployments/{name}": { + "get": { + "description": "watch changes to an object of kind Deployment", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "extensions_v1beta1" + ], + "operationId": "watchExtensionsV1beta1NamespacedDeployment", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ @@ -31288,6 +33865,22 @@ "name": "labelSelector", "in": "query" }, + { + "uniqueItems": true, + "type": "string", + "description": "name of the Deployment", + "name": "name", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, { "uniqueItems": true, "type": "string", @@ -31318,7 +33911,7 @@ } ] }, - "/apis/extensions/v1beta1/watch/ingresses": { + "/apis/extensions/v1beta1/watch/namespaces/{namespace}/ingresses": { "get": { "description": "watch individual changes to a list of Ingress", "consumes": [ @@ -31337,7 +33930,7 @@ "tags": [ "extensions_v1beta1" ], - "operationId": "watchExtensionsV1beta1IngressListForAllNamespaces", + "operationId": "watchExtensionsV1beta1NamespacedIngressList", "responses": { "200": { "description": "OK", @@ -31349,11 +33942,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "parameters": [ @@ -31378,6 +33971,14 @@ "name": "labelSelector", "in": "query" }, + { + "uniqueItems": true, + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, { "uniqueItems": true, "type": "string", @@ -31408,9 +34009,9 @@ } ] }, - "/apis/extensions/v1beta1/watch/namespaces/{namespace}/daemonsets": { + "/apis/extensions/v1beta1/watch/namespaces/{namespace}/ingresses/{name}": { "get": { - "description": "watch individual changes to a list of DaemonSet", + "description": "watch changes to an object of kind Ingress", "consumes": [ "*/*" ], @@ -31427,7 +34028,7 @@ "tags": [ "extensions_v1beta1" ], - "operationId": "watchExtensionsV1beta1NamespacedDaemonSetList", + "operationId": "watchExtensionsV1beta1NamespacedIngress", "responses": { "200": { "description": "OK", @@ -31439,11 +34040,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "parameters": [ @@ -31468,6 +34069,14 @@ "name": "labelSelector", "in": "query" }, + { + "uniqueItems": true, + "type": "string", + "description": "name of the Ingress", + "name": "name", + "in": "path", + "required": true + }, { "uniqueItems": true, "type": "string", @@ -31506,9 +34115,9 @@ } ] }, - "/apis/extensions/v1beta1/watch/namespaces/{namespace}/daemonsets/{name}": { + "/apis/extensions/v1beta1/watch/namespaces/{namespace}/networkpolicies": { "get": { - "description": "watch changes to an object of kind DaemonSet", + "description": "watch individual changes to a list of NetworkPolicy", "consumes": [ "*/*" ], @@ -31525,7 +34134,7 @@ "tags": [ "extensions_v1beta1" ], - "operationId": "watchExtensionsV1beta1NamespacedDaemonSet", + "operationId": "watchExtensionsV1beta1NamespacedNetworkPolicyList", "responses": { "200": { "description": "OK", @@ -31537,11 +34146,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "NetworkPolicy" } }, "parameters": [ @@ -31569,7 +34178,105 @@ { "uniqueItems": true, "type": "string", - "description": "name of the DaemonSet", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true + }, + { + "uniqueItems": true, + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/extensions/v1beta1/watch/namespaces/{namespace}/networkpolicies/{name}": { + "get": { + "description": "watch changes to an object of kind NetworkPolicy", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "extensions_v1beta1" + ], + "operationId": "watchExtensionsV1beta1NamespacedNetworkPolicy", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "watch", + "x-kubernetes-group-version-kind": { + "group": "extensions", + "version": "v1beta1", + "kind": "NetworkPolicy" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "name of the NetworkPolicy", "name": "name", "in": "path", "required": true @@ -31612,9 +34319,9 @@ } ] }, - "/apis/extensions/v1beta1/watch/namespaces/{namespace}/deployments": { + "/apis/extensions/v1beta1/watch/namespaces/{namespace}/replicasets": { "get": { - "description": "watch individual changes to a list of Deployment", + "description": "watch individual changes to a list of ReplicaSet", "consumes": [ "*/*" ], @@ -31631,7 +34338,7 @@ "tags": [ "extensions_v1beta1" ], - "operationId": "watchExtensionsV1beta1NamespacedDeploymentList", + "operationId": "watchExtensionsV1beta1NamespacedReplicaSetList", "responses": { "200": { "description": "OK", @@ -31643,11 +34350,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "parameters": [ @@ -31710,9 +34417,9 @@ } ] }, - "/apis/extensions/v1beta1/watch/namespaces/{namespace}/deployments/{name}": { + "/apis/extensions/v1beta1/watch/namespaces/{namespace}/replicasets/{name}": { "get": { - "description": "watch changes to an object of kind Deployment", + "description": "watch changes to an object of kind ReplicaSet", "consumes": [ "*/*" ], @@ -31729,7 +34436,7 @@ "tags": [ "extensions_v1beta1" ], - "operationId": "watchExtensionsV1beta1NamespacedDeployment", + "operationId": "watchExtensionsV1beta1NamespacedReplicaSet", "responses": { "200": { "description": "OK", @@ -31741,11 +34448,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "parameters": [ @@ -31773,7 +34480,7 @@ { "uniqueItems": true, "type": "string", - "description": "name of the Deployment", + "description": "name of the ReplicaSet", "name": "name", "in": "path", "required": true @@ -31816,9 +34523,9 @@ } ] }, - "/apis/extensions/v1beta1/watch/namespaces/{namespace}/ingresses": { + "/apis/extensions/v1beta1/watch/networkpolicies": { "get": { - "description": "watch individual changes to a list of Ingress", + "description": "watch individual changes to a list of NetworkPolicy", "consumes": [ "*/*" ], @@ -31835,7 +34542,7 @@ "tags": [ "extensions_v1beta1" ], - "operationId": "watchExtensionsV1beta1NamespacedIngressList", + "operationId": "watchExtensionsV1beta1NetworkPolicyListForAllNamespaces", "responses": { "200": { "description": "OK", @@ -31847,11 +34554,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "NetworkPolicy" } }, "parameters": [ @@ -31879,10 +34586,92 @@ { "uniqueItems": true, "type": "string", - "description": "object name and auth scope, such as for teams and projects", - "name": "namespace", - "in": "path", - "required": true + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/extensions/v1beta1/watch/podsecuritypolicies": { + "get": { + "description": "watch individual changes to a list of PodSecurityPolicy", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "extensions_v1beta1" + ], + "operationId": "watchExtensionsV1beta1PodSecurityPolicyList", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "watchlist", + "x-kubernetes-group-version-kind": { + "group": "extensions", + "version": "v1beta1", + "kind": "PodSecurityPolicy" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" }, { "uniqueItems": true, @@ -31914,9 +34703,9 @@ } ] }, - "/apis/extensions/v1beta1/watch/namespaces/{namespace}/ingresses/{name}": { + "/apis/extensions/v1beta1/watch/podsecuritypolicies/{name}": { "get": { - "description": "watch changes to an object of kind Ingress", + "description": "watch changes to an object of kind PodSecurityPolicy", "consumes": [ "*/*" ], @@ -31933,7 +34722,7 @@ "tags": [ "extensions_v1beta1" ], - "operationId": "watchExtensionsV1beta1NamespacedIngress", + "operationId": "watchExtensionsV1beta1PodSecurityPolicy", "responses": { "200": { "description": "OK", @@ -31945,11 +34734,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "PodSecurityPolicy" } }, "parameters": [ @@ -31977,7 +34766,7 @@ { "uniqueItems": true, "type": "string", - "description": "name of the Ingress", + "description": "name of the PodSecurityPolicy", "name": "name", "in": "path", "required": true @@ -31985,10 +34774,92 @@ { "uniqueItems": true, "type": "string", - "description": "object name and auth scope, such as for teams and projects", - "name": "namespace", - "in": "path", - "required": true + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ] + }, + "/apis/extensions/v1beta1/watch/replicasets": { + "get": { + "description": "watch individual changes to a list of ReplicaSet", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "schemes": [ + "https" + ], + "tags": [ + "extensions_v1beta1" + ], + "operationId": "watchExtensionsV1beta1ReplicaSetListForAllNamespaces", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "watchlist", + "x-kubernetes-group-version-kind": { + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" + } + }, + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" }, { "uniqueItems": true, @@ -32020,9 +34891,9 @@ } ] }, - "/apis/extensions/v1beta1/watch/namespaces/{namespace}/networkpolicies": { + "/apis/extensions/v1beta1/watch/thirdpartyresources": { "get": { - "description": "watch individual changes to a list of NetworkPolicy", + "description": "watch individual changes to a list of ThirdPartyResource", "consumes": [ "*/*" ], @@ -32039,7 +34910,7 @@ "tags": [ "extensions_v1beta1" ], - "operationId": "watchExtensionsV1beta1NamespacedNetworkPolicyList", + "operationId": "watchExtensionsV1beta1ThirdPartyResourceList", "responses": { "200": { "description": "OK", @@ -32051,11 +34922,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "NetworkPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "ThirdPartyResource" } }, "parameters": [ @@ -32080,14 +34951,6 @@ "name": "labelSelector", "in": "query" }, - { - "uniqueItems": true, - "type": "string", - "description": "object name and auth scope, such as for teams and projects", - "name": "namespace", - "in": "path", - "required": true - }, { "uniqueItems": true, "type": "string", @@ -32118,9 +34981,9 @@ } ] }, - "/apis/extensions/v1beta1/watch/namespaces/{namespace}/networkpolicies/{name}": { + "/apis/extensions/v1beta1/watch/thirdpartyresources/{name}": { "get": { - "description": "watch changes to an object of kind NetworkPolicy", + "description": "watch changes to an object of kind ThirdPartyResource", "consumes": [ "*/*" ], @@ -32137,7 +35000,7 @@ "tags": [ "extensions_v1beta1" ], - "operationId": "watchExtensionsV1beta1NamespacedNetworkPolicy", + "operationId": "watchExtensionsV1beta1ThirdPartyResource", "responses": { "200": { "description": "OK", @@ -32149,11 +35012,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "NetworkPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "ThirdPartyResource" } }, "parameters": [ @@ -32181,19 +35044,11 @@ { "uniqueItems": true, "type": "string", - "description": "name of the NetworkPolicy", + "description": "name of the ThirdPartyResource", "name": "name", "in": "path", "required": true }, - { - "uniqueItems": true, - "type": "string", - "description": "object name and auth scope, such as for teams and projects", - "name": "namespace", - "in": "path", - "required": true - }, { "uniqueItems": true, "type": "string", @@ -32224,9 +35079,75 @@ } ] }, - "/apis/extensions/v1beta1/watch/namespaces/{namespace}/replicasets": { + "/apis/networking.k8s.io/": { "get": { - "description": "watch individual changes to a list of ReplicaSet", + "description": "get information of a group", + "consumes": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "networking" + ], + "operationId": "getNetworkingAPIGroup", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.APIGroup" + } + }, + "401": { + "description": "Unauthorized" + } + } + } + }, + "/apis/networking.k8s.io/v1/": { + "get": { + "description": "get available resources", + "consumes": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "networking_v1" + ], + "operationId": "getNetworkingV1APIResources", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.APIResourceList" + } + }, + "401": { + "description": "Unauthorized" + } + } + } + }, + "/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies": { + "get": { + "description": "list or watch objects of kind NetworkPolicy", "consumes": [ "*/*" ], @@ -32241,49 +35162,196 @@ "https" ], "tags": [ - "extensions_v1beta1" + "networking_v1" + ], + "operationId": "listNetworkingV1NamespacedNetworkPolicy", + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } ], - "operationId": "watchExtensionsV1beta1NamespacedReplicaSetList", "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicyList" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "networking.k8s.io", + "version": "v1", + "kind": "NetworkPolicy" } }, - "parameters": [ - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "name": "fieldSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "If true, partially initialized resources are included in the response.", - "name": "includeUninitialized", - "in": "query" + "post": { + "description": "create a NetworkPolicy", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "networking_v1" + ], + "operationId": "createNetworkingV1NamespacedNetworkPolicy", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicy" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicy" + } + }, + "401": { + "description": "Unauthorized" + } }, - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - "name": "labelSelector", - "in": "query" + "x-kubernetes-action": "post", + "x-kubernetes-group-version-kind": { + "group": "networking.k8s.io", + "version": "v1", + "kind": "NetworkPolicy" + } + }, + "delete": { + "description": "delete collection of NetworkPolicy", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "networking_v1" + ], + "operationId": "deleteNetworkingV1CollectionNamespacedNetworkPolicy", + "parameters": [ + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "name": "fieldSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "If true, partially initialized resources are included in the response.", + "name": "includeUninitialized", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "name": "labelSelector", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "name": "resourceVersion", + "in": "query" + }, + { + "uniqueItems": true, + "type": "integer", + "description": "Timeout for the list/watch call.", + "name": "timeoutSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "name": "watch", + "in": "query" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Status" + } + }, + "401": { + "description": "Unauthorized" + } }, + "x-kubernetes-action": "deletecollection", + "x-kubernetes-group-version-kind": { + "group": "networking.k8s.io", + "version": "v1", + "kind": "NetworkPolicy" + } + }, + "parameters": [ { "uniqueItems": true, "type": "string", @@ -32298,33 +35366,248 @@ "description": "If 'true', then the output is pretty printed.", "name": "pretty", "in": "query" + } + ] + }, + "/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}": { + "get": { + "description": "read the specified NetworkPolicy", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "networking_v1" + ], + "operationId": "readNetworkingV1NamespacedNetworkPolicy", + "parameters": [ + { + "uniqueItems": true, + "type": "boolean", + "description": "Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'.", + "name": "exact", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Should this value be exported. Export strips fields that a user can not specify.", + "name": "export", + "in": "query" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicy" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "get", + "x-kubernetes-group-version-kind": { + "group": "networking.k8s.io", + "version": "v1", + "kind": "NetworkPolicy" + } + }, + "put": { + "description": "replace the specified NetworkPolicy", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "networking_v1" + ], + "operationId": "replaceNetworkingV1NamespacedNetworkPolicy", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicy" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicy" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "put", + "x-kubernetes-group-version-kind": { + "group": "networking.k8s.io", + "version": "v1", + "kind": "NetworkPolicy" + } + }, + "delete": { + "description": "delete a NetworkPolicy", + "consumes": [ + "*/*" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "networking_v1" + ], + "operationId": "deleteNetworkingV1NamespacedNetworkPolicy", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.DeleteOptions" + } + }, + { + "uniqueItems": true, + "type": "integer", + "description": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.", + "name": "gracePeriodSeconds", + "in": "query" + }, + { + "uniqueItems": true, + "type": "boolean", + "description": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.", + "name": "orphanDependents", + "in": "query" + }, + { + "uniqueItems": true, + "type": "string", + "description": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.", + "name": "propagationPolicy", + "in": "query" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Status" + } + }, + "401": { + "description": "Unauthorized" + } + }, + "x-kubernetes-action": "delete", + "x-kubernetes-group-version-kind": { + "group": "networking.k8s.io", + "version": "v1", + "kind": "NetworkPolicy" + } + }, + "patch": { + "description": "partially update the specified NetworkPolicy", + "consumes": [ + "application/json-patch+json", + "application/merge-patch+json", + "application/strategic-merge-patch+json" + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "schemes": [ + "https" + ], + "tags": [ + "networking_v1" + ], + "operationId": "patchNetworkingV1NamespacedNetworkPolicy", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Patch" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicy" + } + }, + "401": { + "description": "Unauthorized" + } }, + "x-kubernetes-action": "patch", + "x-kubernetes-group-version-kind": { + "group": "networking.k8s.io", + "version": "v1", + "kind": "NetworkPolicy" + } + }, + "parameters": [ { "uniqueItems": true, "type": "string", - "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", - "name": "resourceVersion", - "in": "query" + "description": "name of the NetworkPolicy", + "name": "name", + "in": "path", + "required": true }, { "uniqueItems": true, - "type": "integer", - "description": "Timeout for the list/watch call.", - "name": "timeoutSeconds", - "in": "query" + "type": "string", + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true }, { "uniqueItems": true, - "type": "boolean", - "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - "name": "watch", + "type": "string", + "description": "If 'true', then the output is pretty printed.", + "name": "pretty", "in": "query" } ] }, - "/apis/extensions/v1beta1/watch/namespaces/{namespace}/replicasets/{name}": { + "/apis/networking.k8s.io/v1/networkpolicies": { "get": { - "description": "watch changes to an object of kind ReplicaSet", + "description": "list or watch objects of kind NetworkPolicy", "consumes": [ "*/*" ], @@ -32339,25 +35622,25 @@ "https" ], "tags": [ - "extensions_v1beta1" + "networking_v1" ], - "operationId": "watchExtensionsV1beta1NamespacedReplicaSet", + "operationId": "listNetworkingV1NetworkPolicyForAllNamespaces", "responses": { "200": { "description": "OK", "schema": { - "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicyList" } }, "401": { "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "networking.k8s.io", + "version": "v1", + "kind": "NetworkPolicy" } }, "parameters": [ @@ -32382,22 +35665,6 @@ "name": "labelSelector", "in": "query" }, - { - "uniqueItems": true, - "type": "string", - "description": "name of the ReplicaSet", - "name": "name", - "in": "path", - "required": true - }, - { - "uniqueItems": true, - "type": "string", - "description": "object name and auth scope, such as for teams and projects", - "name": "namespace", - "in": "path", - "required": true - }, { "uniqueItems": true, "type": "string", @@ -32428,7 +35695,7 @@ } ] }, - "/apis/extensions/v1beta1/watch/networkpolicies": { + "/apis/networking.k8s.io/v1/watch/namespaces/{namespace}/networkpolicies": { "get": { "description": "watch individual changes to a list of NetworkPolicy", "consumes": [ @@ -32445,9 +35712,9 @@ "https" ], "tags": [ - "extensions_v1beta1" + "networking_v1" ], - "operationId": "watchExtensionsV1beta1NetworkPolicyListForAllNamespaces", + "operationId": "watchNetworkingV1NamespacedNetworkPolicyList", "responses": { "200": { "description": "OK", @@ -32459,11 +35726,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "NetworkPolicy" + "group": "networking.k8s.io", + "version": "v1", + "kind": "NetworkPolicy" } }, "parameters": [ @@ -32491,92 +35758,10 @@ { "uniqueItems": true, "type": "string", - "description": "If 'true', then the output is pretty printed.", - "name": "pretty", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", - "name": "resourceVersion", - "in": "query" - }, - { - "uniqueItems": true, - "type": "integer", - "description": "Timeout for the list/watch call.", - "name": "timeoutSeconds", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - "name": "watch", - "in": "query" - } - ] - }, - "/apis/extensions/v1beta1/watch/podsecuritypolicies": { - "get": { - "description": "watch individual changes to a list of PodSecurityPolicy", - "consumes": [ - "*/*" - ], - "produces": [ - "application/json", - "application/yaml", - "application/vnd.kubernetes.protobuf", - "application/json;stream=watch", - "application/vnd.kubernetes.protobuf;stream=watch" - ], - "schemes": [ - "https" - ], - "tags": [ - "extensions_v1beta1" - ], - "operationId": "watchExtensionsV1beta1PodSecurityPolicyList", - "responses": { - "200": { - "description": "OK", - "schema": { - "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" - } - }, - "401": { - "description": "Unauthorized" - } - }, - "x-kubernetes-action": "WATCHLIST", - "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "PodSecurityPolicy" - } - }, - "parameters": [ - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "name": "fieldSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "If true, partially initialized resources are included in the response.", - "name": "includeUninitialized", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - "name": "labelSelector", - "in": "query" + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true }, { "uniqueItems": true, @@ -32608,9 +35793,9 @@ } ] }, - "/apis/extensions/v1beta1/watch/podsecuritypolicies/{name}": { + "/apis/networking.k8s.io/v1/watch/namespaces/{namespace}/networkpolicies/{name}": { "get": { - "description": "watch changes to an object of kind PodSecurityPolicy", + "description": "watch changes to an object of kind NetworkPolicy", "consumes": [ "*/*" ], @@ -32625,9 +35810,9 @@ "https" ], "tags": [ - "extensions_v1beta1" + "networking_v1" ], - "operationId": "watchExtensionsV1beta1PodSecurityPolicy", + "operationId": "watchNetworkingV1NamespacedNetworkPolicy", "responses": { "200": { "description": "OK", @@ -32639,11 +35824,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "PodSecurityPolicy" + "group": "networking.k8s.io", + "version": "v1", + "kind": "NetworkPolicy" } }, "parameters": [ @@ -32671,7 +35856,7 @@ { "uniqueItems": true, "type": "string", - "description": "name of the PodSecurityPolicy", + "description": "name of the NetworkPolicy", "name": "name", "in": "path", "required": true @@ -32679,182 +35864,10 @@ { "uniqueItems": true, "type": "string", - "description": "If 'true', then the output is pretty printed.", - "name": "pretty", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", - "name": "resourceVersion", - "in": "query" - }, - { - "uniqueItems": true, - "type": "integer", - "description": "Timeout for the list/watch call.", - "name": "timeoutSeconds", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - "name": "watch", - "in": "query" - } - ] - }, - "/apis/extensions/v1beta1/watch/replicasets": { - "get": { - "description": "watch individual changes to a list of ReplicaSet", - "consumes": [ - "*/*" - ], - "produces": [ - "application/json", - "application/yaml", - "application/vnd.kubernetes.protobuf", - "application/json;stream=watch", - "application/vnd.kubernetes.protobuf;stream=watch" - ], - "schemes": [ - "https" - ], - "tags": [ - "extensions_v1beta1" - ], - "operationId": "watchExtensionsV1beta1ReplicaSetListForAllNamespaces", - "responses": { - "200": { - "description": "OK", - "schema": { - "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" - } - }, - "401": { - "description": "Unauthorized" - } - }, - "x-kubernetes-action": "WATCHLIST", - "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" - } - }, - "parameters": [ - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "name": "fieldSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "If true, partially initialized resources are included in the response.", - "name": "includeUninitialized", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - "name": "labelSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "If 'true', then the output is pretty printed.", - "name": "pretty", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", - "name": "resourceVersion", - "in": "query" - }, - { - "uniqueItems": true, - "type": "integer", - "description": "Timeout for the list/watch call.", - "name": "timeoutSeconds", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - "name": "watch", - "in": "query" - } - ] - }, - "/apis/extensions/v1beta1/watch/thirdpartyresources": { - "get": { - "description": "watch individual changes to a list of ThirdPartyResource", - "consumes": [ - "*/*" - ], - "produces": [ - "application/json", - "application/yaml", - "application/vnd.kubernetes.protobuf", - "application/json;stream=watch", - "application/vnd.kubernetes.protobuf;stream=watch" - ], - "schemes": [ - "https" - ], - "tags": [ - "extensions_v1beta1" - ], - "operationId": "watchExtensionsV1beta1ThirdPartyResourceList", - "responses": { - "200": { - "description": "OK", - "schema": { - "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent" - } - }, - "401": { - "description": "Unauthorized" - } - }, - "x-kubernetes-action": "WATCHLIST", - "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ThirdPartyResource" - } - }, - "parameters": [ - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "name": "fieldSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "If true, partially initialized resources are included in the response.", - "name": "includeUninitialized", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - "name": "labelSelector", - "in": "query" + "description": "object name and auth scope, such as for teams and projects", + "name": "namespace", + "in": "path", + "required": true }, { "uniqueItems": true, @@ -32886,9 +35899,9 @@ } ] }, - "/apis/extensions/v1beta1/watch/thirdpartyresources/{name}": { + "/apis/networking.k8s.io/v1/watch/networkpolicies": { "get": { - "description": "watch changes to an object of kind ThirdPartyResource", + "description": "watch individual changes to a list of NetworkPolicy", "consumes": [ "*/*" ], @@ -32903,9 +35916,9 @@ "https" ], "tags": [ - "extensions_v1beta1" + "networking_v1" ], - "operationId": "watchExtensionsV1beta1ThirdPartyResource", + "operationId": "watchNetworkingV1NetworkPolicyListForAllNamespaces", "responses": { "200": { "description": "OK", @@ -32917,11 +35930,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ThirdPartyResource" + "group": "networking.k8s.io", + "version": "v1", + "kind": "NetworkPolicy" } }, "parameters": [ @@ -32946,14 +35959,6 @@ "name": "labelSelector", "in": "query" }, - { - "uniqueItems": true, - "type": "string", - "description": "name of the ThirdPartyResource", - "name": "name", - "in": "path", - "required": true - }, { "uniqueItems": true, "type": "string", @@ -33125,11 +36130,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "post": { @@ -33170,11 +36175,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "delete": { @@ -33249,11 +36254,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "parameters": [ @@ -33319,11 +36324,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "put": { @@ -33364,11 +36369,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "delete": { @@ -33430,11 +36435,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "patch": { @@ -33477,11 +36482,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "parameters": [ @@ -33539,11 +36544,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "put": { @@ -33584,11 +36589,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "patch": { @@ -33631,11 +36636,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "parameters": [ @@ -33695,11 +36700,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "parameters": [ @@ -33785,11 +36790,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "parameters": [ @@ -33883,11 +36888,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "parameters": [ @@ -33989,11 +36994,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } }, "parameters": [ @@ -34189,11 +37194,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRoleBinding" } }, "post": { @@ -34234,11 +37239,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRoleBinding" } }, "delete": { @@ -34313,11 +37318,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRoleBinding" } }, "parameters": [ @@ -34359,11 +37364,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRoleBinding" } }, "put": { @@ -34404,11 +37409,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRoleBinding" } }, "delete": { @@ -34470,11 +37475,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRoleBinding" } }, "patch": { @@ -34517,11 +37522,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRoleBinding" } }, "parameters": [ @@ -34617,11 +37622,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRole" } }, "post": { @@ -34662,11 +37667,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRole" } }, "delete": { @@ -34741,11 +37746,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRole" } }, "parameters": [ @@ -34787,11 +37792,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRole" } }, "put": { @@ -34832,11 +37837,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRole" } }, "delete": { @@ -34898,11 +37903,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRole" } }, "patch": { @@ -34945,11 +37950,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRole" } }, "parameters": [ @@ -35045,11 +38050,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleBinding" } }, "post": { @@ -35090,11 +38095,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleBinding" } }, "delete": { @@ -35169,11 +38174,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleBinding" } }, "parameters": [ @@ -35223,11 +38228,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleBinding" } }, "put": { @@ -35268,11 +38273,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleBinding" } }, "delete": { @@ -35334,11 +38339,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleBinding" } }, "patch": { @@ -35381,11 +38386,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleBinding" } }, "parameters": [ @@ -35489,11 +38494,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "Role" } }, "post": { @@ -35534,11 +38539,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "Role" } }, "delete": { @@ -35613,11 +38618,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "Role" } }, "parameters": [ @@ -35667,11 +38672,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "Role" } }, "put": { @@ -35712,11 +38717,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "Role" } }, "delete": { @@ -35778,11 +38783,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "Role" } }, "patch": { @@ -35825,11 +38830,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "Role" } }, "parameters": [ @@ -35889,11 +38894,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleBinding" } }, "parameters": [ @@ -35979,11 +38984,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "Role" } }, "parameters": [ @@ -36069,11 +39074,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRoleBinding" } }, "parameters": [ @@ -36159,11 +39164,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRoleBinding" } }, "parameters": [ @@ -36257,11 +39262,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRole" } }, "parameters": [ @@ -36347,11 +39352,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRole" } }, "parameters": [ @@ -36445,11 +39450,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleBinding" } }, "parameters": [ @@ -36543,11 +39548,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleBinding" } }, "parameters": [ @@ -36649,11 +39654,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "Role" } }, "parameters": [ @@ -36747,11 +39752,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "Role" } }, "parameters": [ @@ -36853,11 +39858,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleBinding" } }, "parameters": [ @@ -36943,11 +39948,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "Role" } }, "parameters": [ @@ -37110,11 +40115,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRoleBinding" } }, "post": { @@ -37155,11 +40160,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRoleBinding" } }, "delete": { @@ -37234,11 +40239,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRoleBinding" } }, "parameters": [ @@ -37280,11 +40285,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRoleBinding" } }, "put": { @@ -37325,11 +40330,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRoleBinding" } }, "delete": { @@ -37391,11 +40396,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRoleBinding" } }, "patch": { @@ -37438,11 +40443,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRoleBinding" } }, "parameters": [ @@ -37538,11 +40543,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRole" } }, "post": { @@ -37583,11 +40588,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRole" } }, "delete": { @@ -37662,11 +40667,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRole" } }, "parameters": [ @@ -37708,11 +40713,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRole" } }, "put": { @@ -37753,11 +40758,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRole" } }, "delete": { @@ -37819,11 +40824,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRole" } }, "patch": { @@ -37866,11 +40871,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRole" } }, "parameters": [ @@ -37966,11 +40971,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleBinding" } }, "post": { @@ -38011,11 +41016,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleBinding" } }, "delete": { @@ -38090,11 +41095,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleBinding" } }, "parameters": [ @@ -38144,11 +41149,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleBinding" } }, "put": { @@ -38189,11 +41194,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleBinding" } }, "delete": { @@ -38255,11 +41260,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleBinding" } }, "patch": { @@ -38302,11 +41307,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleBinding" } }, "parameters": [ @@ -38410,11 +41415,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "Role" } }, "post": { @@ -38455,11 +41460,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "Role" } }, "delete": { @@ -38534,11 +41539,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "Role" } }, "parameters": [ @@ -38588,11 +41593,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "Role" } }, "put": { @@ -38633,11 +41638,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "Role" } }, "delete": { @@ -38699,11 +41704,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "Role" } }, "patch": { @@ -38746,11 +41751,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "Role" } }, "parameters": [ @@ -38810,11 +41815,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleBinding" } }, "parameters": [ @@ -38900,11 +41905,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "Role" } }, "parameters": [ @@ -38990,11 +41995,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRoleBinding" } }, "parameters": [ @@ -39080,11 +42085,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRoleBinding" } }, "parameters": [ @@ -39178,11 +42183,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRole" } }, "parameters": [ @@ -39268,11 +42273,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRole" } }, "parameters": [ @@ -39366,11 +42371,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleBinding" } }, "parameters": [ @@ -39464,11 +42469,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleBinding" } }, "parameters": [ @@ -39570,11 +42575,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "Role" } }, "parameters": [ @@ -39668,11 +42673,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "Role" } }, "parameters": [ @@ -39774,11 +42779,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleBinding" } }, "parameters": [ @@ -39864,11 +42869,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "Role" } }, "parameters": [ @@ -40064,11 +43069,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "settings.k8s.io", - "Version": "v1alpha1", - "Kind": "PodPreset" + "group": "settings.k8s.io", + "version": "v1alpha1", + "kind": "PodPreset" } }, "post": { @@ -40109,11 +43114,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "settings.k8s.io", - "Version": "v1alpha1", - "Kind": "PodPreset" + "group": "settings.k8s.io", + "version": "v1alpha1", + "kind": "PodPreset" } }, "delete": { @@ -40188,11 +43193,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "settings.k8s.io", - "Version": "v1alpha1", - "Kind": "PodPreset" + "group": "settings.k8s.io", + "version": "v1alpha1", + "kind": "PodPreset" } }, "parameters": [ @@ -40258,11 +43263,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "settings.k8s.io", - "Version": "v1alpha1", - "Kind": "PodPreset" + "group": "settings.k8s.io", + "version": "v1alpha1", + "kind": "PodPreset" } }, "put": { @@ -40303,11 +43308,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "settings.k8s.io", - "Version": "v1alpha1", - "Kind": "PodPreset" + "group": "settings.k8s.io", + "version": "v1alpha1", + "kind": "PodPreset" } }, "delete": { @@ -40369,11 +43374,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "settings.k8s.io", - "Version": "v1alpha1", - "Kind": "PodPreset" + "group": "settings.k8s.io", + "version": "v1alpha1", + "kind": "PodPreset" } }, "patch": { @@ -40416,11 +43421,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "settings.k8s.io", - "Version": "v1alpha1", - "Kind": "PodPreset" + "group": "settings.k8s.io", + "version": "v1alpha1", + "kind": "PodPreset" } }, "parameters": [ @@ -40480,11 +43485,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "settings.k8s.io", - "Version": "v1alpha1", - "Kind": "PodPreset" + "group": "settings.k8s.io", + "version": "v1alpha1", + "kind": "PodPreset" } }, "parameters": [ @@ -40570,11 +43575,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "settings.k8s.io", - "Version": "v1alpha1", - "Kind": "PodPreset" + "group": "settings.k8s.io", + "version": "v1alpha1", + "kind": "PodPreset" } }, "parameters": [ @@ -40668,11 +43673,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "settings.k8s.io", - "Version": "v1alpha1", - "Kind": "PodPreset" + "group": "settings.k8s.io", + "version": "v1alpha1", + "kind": "PodPreset" } }, "parameters": [ @@ -40774,11 +43779,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "settings.k8s.io", - "Version": "v1alpha1", - "Kind": "PodPreset" + "group": "settings.k8s.io", + "version": "v1alpha1", + "kind": "PodPreset" } }, "parameters": [ @@ -40974,11 +43979,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1", + "kind": "StorageClass" } }, "post": { @@ -41019,11 +44024,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1", + "kind": "StorageClass" } }, "delete": { @@ -41098,11 +44103,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1", + "kind": "StorageClass" } }, "parameters": [ @@ -41160,11 +44165,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1", + "kind": "StorageClass" } }, "put": { @@ -41205,11 +44210,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1", + "kind": "StorageClass" } }, "delete": { @@ -41271,11 +44276,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1", + "kind": "StorageClass" } }, "patch": { @@ -41318,11 +44323,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1", + "kind": "StorageClass" } }, "parameters": [ @@ -41374,11 +44379,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1", + "kind": "StorageClass" } }, "parameters": [ @@ -41464,11 +44469,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1", + "kind": "StorageClass" } }, "parameters": [ @@ -41639,11 +44644,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1beta1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1beta1", + "kind": "StorageClass" } }, "post": { @@ -41684,11 +44689,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1beta1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1beta1", + "kind": "StorageClass" } }, "delete": { @@ -41763,11 +44768,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1beta1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1beta1", + "kind": "StorageClass" } }, "parameters": [ @@ -41825,11 +44830,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1beta1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1beta1", + "kind": "StorageClass" } }, "put": { @@ -41870,11 +44875,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1beta1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1beta1", + "kind": "StorageClass" } }, "delete": { @@ -41936,11 +44941,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1beta1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1beta1", + "kind": "StorageClass" } }, "patch": { @@ -41983,11 +44988,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1beta1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1beta1", + "kind": "StorageClass" } }, "parameters": [ @@ -42039,11 +45044,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1beta1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1beta1", + "kind": "StorageClass" } }, "parameters": [ @@ -42129,11 +45134,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "storage.k8s.io", - "Version": "v1beta1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1beta1", + "kind": "StorageClass" } }, "parameters": [ @@ -43028,9 +46033,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "Binding" + "group": "", + "version": "v1", + "kind": "Binding" } ] }, @@ -43160,9 +46165,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ComponentStatus" + "group": "", + "version": "v1", + "kind": "ComponentStatus" } ] }, @@ -43194,9 +46199,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ComponentStatusList" + "group": "", + "version": "v1", + "kind": "ComponentStatusList" } ] }, @@ -43225,9 +46230,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } ] }, @@ -43292,9 +46297,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ConfigMapList" + "group": "", + "version": "v1", + "kind": "ConfigMapList" } ] }, @@ -43700,6 +46705,10 @@ "medium": { "description": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", "type": "string" + }, + "sizeLimit": { + "description": "Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.api.resource.Quantity" } } }, @@ -43802,9 +46811,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "Endpoints" + "group": "", + "version": "v1", + "kind": "Endpoints" } ] }, @@ -43836,9 +46845,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "EndpointsList" + "group": "", + "version": "v1", + "kind": "EndpointsList" } ] }, @@ -43955,9 +46964,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } ] }, @@ -43989,9 +46998,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "EventList" + "group": "", + "version": "v1", + "kind": "EventList" } ] }, @@ -44363,9 +47372,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "LimitRange" + "group": "", + "version": "v1", + "kind": "LimitRange" } ] }, @@ -44441,9 +47450,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "LimitRangeList" + "group": "", + "version": "v1", + "kind": "LimitRangeList" } ] }, @@ -44555,9 +47564,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } ] }, @@ -44589,9 +47598,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "NamespaceList" + "group": "", + "version": "v1", + "kind": "NamespaceList" } ] }, @@ -44642,9 +47651,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "Node" + "group": "", + "version": "v1", + "kind": "Node" } ] }, @@ -44751,9 +47760,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "NodeList" + "group": "", + "version": "v1", + "kind": "NodeList" } ] }, @@ -45043,9 +48052,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolume" + "group": "", + "version": "v1", + "kind": "PersistentVolume" } ] }, @@ -45075,9 +48084,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaim" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaim" } ] }, @@ -45109,9 +48118,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeClaimList" + "group": "", + "version": "v1", + "kind": "PersistentVolumeClaimList" } ] }, @@ -45210,9 +48219,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "PersistentVolumeList" + "group": "", + "version": "v1", + "kind": "PersistentVolumeList" } ] }, @@ -45386,9 +48395,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "Pod" + "group": "", + "version": "v1", + "kind": "Pod" } ] }, @@ -45511,9 +48520,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "PodList" + "group": "", + "version": "v1", + "kind": "PodList" } ] }, @@ -45759,9 +48768,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "PodTemplate" + "group": "", + "version": "v1", + "kind": "PodTemplate" } ] }, @@ -45793,9 +48802,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "PodTemplateList" + "group": "", + "version": "v1", + "kind": "PodTemplateList" } ] }, @@ -46011,9 +49020,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ReplicationController" + "group": "", + "version": "v1", + "kind": "ReplicationController" } ] }, @@ -46074,9 +49083,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ReplicationControllerList" + "group": "", + "version": "v1", + "kind": "ReplicationControllerList" } ] }, @@ -46194,9 +49203,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuota" + "group": "", + "version": "v1", + "kind": "ResourceQuota" } ] }, @@ -46228,9 +49237,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ResourceQuotaList" + "group": "", + "version": "v1", + "kind": "ResourceQuotaList" } ] }, @@ -46399,9 +49408,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } ] }, @@ -46466,9 +49475,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "SecretList" + "group": "", + "version": "v1", + "kind": "SecretList" } ] }, @@ -46573,9 +49582,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } ] }, @@ -46617,9 +49626,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ServiceAccount" + "group": "", + "version": "v1", + "kind": "ServiceAccount" } ] }, @@ -46651,9 +49660,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ServiceAccountList" + "group": "", + "version": "v1", + "kind": "ServiceAccountList" } ] }, @@ -46685,9 +49694,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ServiceList" + "group": "", + "version": "v1", + "kind": "ServiceList" } ] }, @@ -47065,6 +50074,355 @@ } } }, + "io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.AdmissionHookClientConfig": { + "description": "AdmissionHookClientConfig contains the information to make a TLS connection with the webhook", + "required": [ + "service", + "caBundle" + ], + "properties": { + "caBundle": { + "description": "CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. Required", + "type": "string", + "format": "byte" + }, + "service": { + "description": "Service is a reference to the service for this webhook. If there is only one port open for the service, that port will be used. If there are multiple ports open, port 443 will be used if it is open, otherwise it is an error. Required", + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ServiceReference" + } + } + }, + "io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHook": { + "description": "ExternalAdmissionHook describes an external admission webhook and the resources and operations it applies to.", + "required": [ + "name", + "clientConfig" + ], + "properties": { + "clientConfig": { + "description": "ClientConfig defines how to communicate with the hook. Required", + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.AdmissionHookClientConfig" + }, + "failurePolicy": { + "description": "FailurePolicy defines how unrecognized errors from the admission endpoint are handled - allowed values are Ignore or Fail. Defaults to Ignore.", + "type": "string" + }, + "name": { + "description": "The name of the external admission webhook. Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where \"imagepolicy\" is the name of the webhook, and kubernetes.io is the name of the organization. Required.", + "type": "string" + }, + "rules": { + "description": "Rules describes what operations on what resources/subresources the webhook cares about. The webhook cares about an operation if it matches _any_ Rule.", + "type": "array", + "items": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.RuleWithOperations" + } + } + } + }, + "io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfiguration": { + "description": "ExternalAdmissionHookConfiguration describes the configuration of initializers.", + "properties": { + "apiVersion": { + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources", + "type": "string" + }, + "externalAdmissionHooks": { + "description": "ExternalAdmissionHooks is a list of external admission webhooks and the affected resources and operations.", + "type": "array", + "items": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHook" + }, + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge" + }, + "kind": { + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "type": "string" + }, + "metadata": { + "description": "Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta" + } + }, + "x-kubernetes-group-version-kind": [ + { + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "ExternalAdmissionHookConfiguration" + } + ] + }, + "io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfigurationList": { + "description": "ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration.", + "required": [ + "items" + ], + "properties": { + "apiVersion": { + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources", + "type": "string" + }, + "items": { + "description": "List of ExternalAdmissionHookConfiguration.", + "type": "array", + "items": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfiguration" + } + }, + "kind": { + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "type": "string" + }, + "metadata": { + "description": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ListMeta" + } + }, + "x-kubernetes-group-version-kind": [ + { + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "ExternalAdmissionHookConfigurationList" + } + ] + }, + "io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.Initializer": { + "description": "Initializer describes the name and the failure policy of an initializer, and what resources it applies to.", + "required": [ + "name" + ], + "properties": { + "failurePolicy": { + "description": "FailurePolicy defines what happens if the responsible initializer controller fails to takes action. Allowed values are Ignore, or Fail. If \"Ignore\" is set, initializer is removed from the initializers list of an object if the timeout is reached; If \"Fail\" is set, admissionregistration returns timeout error if the timeout is reached.", + "type": "string" + }, + "name": { + "description": "Name is the identifier of the initializer. It will be added to the object that needs to be initialized. Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where \"alwayspullimages\" is the name of the webhook, and kubernetes.io is the name of the organization. Required", + "type": "string" + }, + "rules": { + "description": "Rules describes what resources/subresources the initializer cares about. The initializer cares about an operation if it matches _any_ Rule.", + "type": "array", + "items": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.Rule" + } + } + } + }, + "io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.InitializerConfiguration": { + "description": "InitializerConfiguration describes the configuration of initializers.", + "properties": { + "apiVersion": { + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources", + "type": "string" + }, + "initializers": { + "description": "Initializers is a list of resources and their default initializers Order-sensitive. When merging multiple InitializerConfigurations, we sort the initializers from different InitializerConfigurations by the name of the InitializerConfigurations; the order of the initializers from the same InitializerConfiguration is preserved.", + "type": "array", + "items": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.Initializer" + }, + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge" + }, + "kind": { + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "type": "string" + }, + "metadata": { + "description": "Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta" + } + }, + "x-kubernetes-group-version-kind": [ + { + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "InitializerConfiguration" + } + ] + }, + "io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.InitializerConfigurationList": { + "description": "InitializerConfigurationList is a list of InitializerConfiguration.", + "required": [ + "items" + ], + "properties": { + "apiVersion": { + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources", + "type": "string" + }, + "items": { + "description": "List of InitializerConfiguration.", + "type": "array", + "items": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.InitializerConfiguration" + } + }, + "kind": { + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "type": "string" + }, + "metadata": { + "description": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ListMeta" + } + }, + "x-kubernetes-group-version-kind": [ + { + "group": "admissionregistration.k8s.io", + "version": "v1alpha1", + "kind": "InitializerConfigurationList" + } + ] + }, + "io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.Rule": { + "description": "Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended to make sure that all the tuple expansions are valid.", + "properties": { + "apiGroups": { + "description": "APIGroups is the API groups the resources belong to. '*' is all groups. If '*' is present, the length of the slice must be one. Required.", + "type": "array", + "items": { + "type": "string" + } + }, + "apiVersions": { + "description": "APIVersions is the API versions the resources belong to. '*' is all versions. If '*' is present, the length of the slice must be one. Required.", + "type": "array", + "items": { + "type": "string" + } + }, + "resources": { + "description": "Resources is a list of resources this rule applies to.\n\nFor example: 'pods' means pods. 'pods/log' means the log subresource of pods. '*' means all resources, but not subresources. 'pods/*' means all subresources of pods. '*/scale' means all scale subresources. '*/*' means all resources and their subresources.\n\nIf '*' or '*/*' is present, the length of the slice must be one. Required.", + "type": "array", + "items": { + "type": "string" + } + } + } + }, + "io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.RuleWithOperations": { + "description": "RuleWithOperations is a tuple of Operations and Resources. It is recommended to make sure that all the tuple expansions are valid.", + "properties": { + "apiGroups": { + "description": "APIGroups is the API groups the resources belong to. '*' is all groups. If '*' is present, the length of the slice must be one. Required.", + "type": "array", + "items": { + "type": "string" + } + }, + "apiVersions": { + "description": "APIVersions is the API versions the resources belong to. '*' is all versions. If '*' is present, the length of the slice must be one. Required.", + "type": "array", + "items": { + "type": "string" + } + }, + "operations": { + "description": "Operations is the operations the admission hook cares about - CREATE, UPDATE, or * for all operations. If '*' is present, the length of the slice must be one. Required.", + "type": "array", + "items": { + "type": "string" + } + }, + "resources": { + "description": "Resources is a list of resources this rule applies to.\n\nFor example: 'pods' means pods. 'pods/log' means the log subresource of pods. '*' means all resources, but not subresources. 'pods/*' means all subresources of pods. '*/scale' means all scale subresources. '*/*' means all resources and their subresources.\n\nIf '*' or '*/*' is present, the length of the slice must be one. Required.", + "type": "array", + "items": { + "type": "string" + } + } + } + }, + "io.k8s.kubernetes.pkg.apis.admissionregistration.v1alpha1.ServiceReference": { + "description": "ServiceReference holds a reference to Service.legacy.k8s.io", + "required": [ + "namespace", + "name" + ], + "properties": { + "name": { + "description": "Name is the name of the service Required", + "type": "string" + }, + "namespace": { + "description": "Namespace is the namespace of the service Required", + "type": "string" + } + } + }, + "io.k8s.kubernetes.pkg.apis.apps.v1beta1.ControllerRevision": { + "description": "ControllerRevision implements an immutable snapshot of state data. Clients are responsible for serializing and deserializing the objects that contain their internal state. Once a ControllerRevision has been successfully created, it can not be updated. The API Server will fail validation of all requests that attempt to mutate the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, it may be subject to name and representation changes in future releases, and clients should not depend on its stability. It is primarily for internal use by controllers.", + "required": [ + "revision" + ], + "properties": { + "apiVersion": { + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources", + "type": "string" + }, + "data": { + "description": "Data is the serialized representation of the state.", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.runtime.RawExtension" + }, + "kind": { + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "type": "string" + }, + "metadata": { + "description": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta" + }, + "revision": { + "description": "Revision indicates the revision of the state represented by Data.", + "type": "integer", + "format": "int64" + } + }, + "x-kubernetes-group-version-kind": [ + { + "group": "apps", + "version": "v1beta1", + "kind": "ControllerRevision" + } + ] + }, + "io.k8s.kubernetes.pkg.apis.apps.v1beta1.ControllerRevisionList": { + "description": "ControllerRevisionList is a resource containing a list of ControllerRevision objects.", + "required": [ + "items" + ], + "properties": { + "apiVersion": { + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources", + "type": "string" + }, + "items": { + "description": "Items is the list of ControllerRevisions", + "type": "array", + "items": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.apps.v1beta1.ControllerRevision" + } + }, + "kind": { + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "type": "string" + }, + "metadata": { + "description": "More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ListMeta" + } + }, + "x-kubernetes-group-version-kind": [ + { + "group": "apps", + "version": "v1beta1", + "kind": "ControllerRevisionList" + } + ] + }, "io.k8s.kubernetes.pkg.apis.apps.v1beta1.Deployment": { "description": "Deployment enables declarative updates for Pods and ReplicaSets.", "properties": { @@ -47091,9 +50449,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "apps", + "version": "v1beta1", + "kind": "Deployment" } ] }, @@ -47158,9 +50516,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "apps", - "Version": "v1beta1", - "Kind": "DeploymentList" + "group": "apps", + "version": "v1beta1", + "kind": "DeploymentList" } ] }, @@ -47197,9 +50555,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "apps", - "Version": "v1beta1", - "Kind": "DeploymentRollback" + "group": "apps", + "version": "v1beta1", + "kind": "DeploymentRollback" } ] }, @@ -47316,7 +50674,7 @@ "io.k8s.kubernetes.pkg.apis.apps.v1beta1.RollbackConfig": { "properties": { "revision": { - "description": "The revision to rollback to. If set to 0, rollbck to the last revision.", + "description": "The revision to rollback to. If set to 0, rollback to the last revision.", "type": "integer", "format": "int64" } @@ -47361,9 +50719,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "apps", - "Version": "v1beta1", - "Kind": "Scale" + "group": "apps", + "version": "v1beta1", + "kind": "Scale" } ] }, @@ -47426,9 +50784,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSet" + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSet" } ] }, @@ -47458,9 +50816,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "apps", - "Version": "v1beta1", - "Kind": "StatefulSetList" + "group": "apps", + "version": "v1beta1", + "kind": "StatefulSetList" } ] }, @@ -47547,9 +50905,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "authentication.k8s.io", - "Version": "v1", - "Kind": "TokenReview" + "group": "authentication.k8s.io", + "version": "v1", + "kind": "TokenReview" } ] }, @@ -47637,9 +50995,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "authentication.k8s.io", - "Version": "v1beta1", - "Kind": "TokenReview" + "group": "authentication.k8s.io", + "version": "v1beta1", + "kind": "TokenReview" } ] }, @@ -47727,9 +51085,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "authorization.k8s.io", - "Version": "v1", - "Kind": "LocalSubjectAccessReview" + "group": "authorization.k8s.io", + "version": "v1", + "kind": "LocalSubjectAccessReview" } ] }, @@ -47807,9 +51165,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "authorization.k8s.io", - "Version": "v1", - "Kind": "SelfSubjectAccessReview" + "group": "authorization.k8s.io", + "version": "v1", + "kind": "SelfSubjectAccessReview" } ] }, @@ -47854,9 +51212,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "authorization.k8s.io", - "Version": "v1", - "Kind": "SubjectAccessReview" + "group": "authorization.k8s.io", + "version": "v1", + "kind": "SubjectAccessReview" } ] }, @@ -47942,9 +51300,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "authorization.k8s.io", - "Version": "v1beta1", - "Kind": "LocalSubjectAccessReview" + "group": "authorization.k8s.io", + "version": "v1beta1", + "kind": "LocalSubjectAccessReview" } ] }, @@ -48022,9 +51380,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "authorization.k8s.io", - "Version": "v1beta1", - "Kind": "SelfSubjectAccessReview" + "group": "authorization.k8s.io", + "version": "v1beta1", + "kind": "SelfSubjectAccessReview" } ] }, @@ -48069,9 +51427,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "authorization.k8s.io", - "Version": "v1beta1", - "Kind": "SubjectAccessReview" + "group": "authorization.k8s.io", + "version": "v1beta1", + "kind": "SubjectAccessReview" } ] }, @@ -48176,9 +51534,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscaler" } ] }, @@ -48210,9 +51568,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "autoscaling", - "Version": "v1", - "Kind": "HorizontalPodAutoscalerList" + "group": "autoscaling", + "version": "v1", + "kind": "HorizontalPodAutoscalerList" } ] }, @@ -48303,9 +51661,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "autoscaling", - "Version": "v1", - "Kind": "Scale" + "group": "autoscaling", + "version": "v1", + "kind": "Scale" } ] }, @@ -48383,9 +51741,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscaler" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscaler" } ] }, @@ -48417,9 +51775,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "autoscaling", - "Version": "v2alpha1", - "Kind": "HorizontalPodAutoscalerList" + "group": "autoscaling", + "version": "v2alpha1", + "kind": "HorizontalPodAutoscalerList" } ] }, @@ -48684,9 +52042,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "batch", - "Version": "v1", - "Kind": "Job" + "group": "batch", + "version": "v1", + "kind": "Job" } ] }, @@ -48751,9 +52109,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "batch", - "Version": "v1", - "Kind": "JobList" + "group": "batch", + "version": "v1", + "kind": "JobList" } ] }, @@ -48855,14 +52213,14 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJob" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJob" }, { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJob" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJob" } ] }, @@ -48894,14 +52252,14 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "CronJobList" + "group": "batch", + "version": "v2alpha1", + "kind": "CronJobList" }, { - "Group": "batch", - "Version": "v2alpha1", - "Kind": "ScheduledJobList" + "group": "batch", + "version": "v2alpha1", + "kind": "ScheduledJobList" } ] }, @@ -48999,9 +52357,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "certificates.k8s.io", - "Version": "v1beta1", - "Kind": "CertificateSigningRequest" + "group": "certificates.k8s.io", + "version": "v1beta1", + "kind": "CertificateSigningRequest" } ] }, @@ -49053,9 +52411,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "certificates.k8s.io", - "Version": "v1beta1", - "Kind": "CertificateSigningRequestList" + "group": "certificates.k8s.io", + "version": "v1beta1", + "kind": "CertificateSigningRequestList" } ] }, @@ -49155,9 +52513,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } ] }, @@ -49189,9 +52547,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSetList" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSetList" } ] }, @@ -49314,9 +52672,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } ] }, @@ -49381,9 +52739,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DeploymentList" + "group": "extensions", + "version": "v1beta1", + "kind": "DeploymentList" } ] }, @@ -49420,9 +52778,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DeploymentRollback" + "group": "extensions", + "version": "v1beta1", + "kind": "DeploymentRollback" } ] }, @@ -49647,9 +53005,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } ] }, @@ -49698,9 +53056,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "IngressList" + "group": "extensions", + "version": "v1beta1", + "kind": "IngressList" } ] }, @@ -49765,6 +53123,7 @@ } }, "io.k8s.kubernetes.pkg.apis.extensions.v1beta1.NetworkPolicy": { + "description": "NetworkPolicy describes what network traffic is allowed for a set of Pods", "properties": { "apiVersion": { "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources", @@ -49785,9 +53144,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "NetworkPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "NetworkPolicy" } ] }, @@ -49838,9 +53197,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "NetworkPolicyList" + "group": "extensions", + "version": "v1beta1", + "kind": "NetworkPolicyList" } ] }, @@ -49874,7 +53233,7 @@ ], "properties": { "ingress": { - "description": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not affect ingress isolation. If this field is present and contains at least one rule, this policy allows any traffic which matches at least one of the ingress rules in this list.", + "description": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default).", "type": "array", "items": { "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.extensions.v1beta1.NetworkPolicyIngressRule" @@ -49908,9 +53267,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "PodSecurityPolicy" + "group": "extensions", + "version": "v1beta1", + "kind": "PodSecurityPolicy" } ] }, @@ -49942,9 +53301,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "PodSecurityPolicyList" + "group": "extensions", + "version": "v1beta1", + "kind": "PodSecurityPolicyList" } ] }, @@ -49964,6 +53323,13 @@ "type": "string" } }, + "allowedHostPaths": { + "description": "AllowedHostPaths is a white list of allowed host path prefixes. Empty indicates that all host paths may be used.", + "type": "array", + "items": { + "type": "string" + } + }, "defaultAddCapabilities": { "description": "DefaultAddCapabilities is the default set of capabilities that will be added to the container unless the pod spec specifically drops the capability. You may not list a capabiility in both DefaultAddCapabilities and RequiredDropCapabilities.", "type": "array", @@ -50056,9 +53422,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } ] }, @@ -50119,9 +53485,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSetList" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSetList" } ] }, @@ -50193,7 +53559,7 @@ "io.k8s.kubernetes.pkg.apis.extensions.v1beta1.RollbackConfig": { "properties": { "revision": { - "description": "The revision to rollback to. If set to 0, rollbck to the last revision.", + "description": "The revision to rollback to. If set to 0, rollback to the last revision.", "type": "integer", "format": "int64" } @@ -50282,9 +53648,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } ] }, @@ -50367,9 +53733,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ThirdPartyResource" + "group": "extensions", + "version": "v1beta1", + "kind": "ThirdPartyResource" } ] }, @@ -50401,12 +53767,138 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ThirdPartyResourceList" + "group": "extensions", + "version": "v1beta1", + "kind": "ThirdPartyResourceList" } ] }, + "io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicy": { + "description": "NetworkPolicy describes what network traffic is allowed for a set of Pods", + "properties": { + "apiVersion": { + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources", + "type": "string" + }, + "kind": { + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "type": "string" + }, + "metadata": { + "description": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta" + }, + "spec": { + "description": "Specification of the desired behavior for this NetworkPolicy.", + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicySpec" + } + }, + "x-kubernetes-group-version-kind": [ + { + "group": "networking.k8s.io", + "version": "v1", + "kind": "NetworkPolicy" + } + ] + }, + "io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicyIngressRule": { + "description": "NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from.", + "properties": { + "from": { + "description": "List of sources which should be able to access the pods selected for this rule. Items in this list are combined using a logical OR operation. If this field is empty or missing, this rule matches all sources (traffic not restricted by source). If this field is present and contains at least on item, this rule allows traffic only if the traffic matches at least one item in the from list.", + "type": "array", + "items": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicyPeer" + } + }, + "ports": { + "description": "List of ports which should be made accessible on the pods selected for this rule. Each item in this list is combined using a logical OR. If this field is empty or missing, this rule matches all ports (traffic not restricted by port). If this field is present and contains at least one item, then this rule allows traffic only if the traffic matches at least one port in the list.", + "type": "array", + "items": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicyPort" + } + } + } + }, + "io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicyList": { + "description": "NetworkPolicyList is a list of NetworkPolicy objects.", + "required": [ + "items" + ], + "properties": { + "apiVersion": { + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources", + "type": "string" + }, + "items": { + "description": "Items is a list of schema objects.", + "type": "array", + "items": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicy" + } + }, + "kind": { + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "type": "string" + }, + "metadata": { + "description": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ListMeta" + } + }, + "x-kubernetes-group-version-kind": [ + { + "group": "networking.k8s.io", + "version": "v1", + "kind": "NetworkPolicyList" + } + ] + }, + "io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicyPeer": { + "description": "NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields must be specified.", + "properties": { + "namespaceSelector": { + "description": "Selects Namespaces using cluster scoped-labels. This matches all pods in all namespaces selected by this label selector. This field follows standard label selector semantics. If present but empty, this selector selects all namespaces.", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.LabelSelector" + }, + "podSelector": { + "description": "This is a label selector which selects Pods in this namespace. This field follows standard label selector semantics. If present but empty, this selector selects all pods in this namespace.", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.LabelSelector" + } + } + }, + "io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicyPort": { + "description": "NetworkPolicyPort describes a port to allow traffic on", + "properties": { + "port": { + "description": "The port on the given protocol. This can either be a numerical or named port on a pod. If this field is not provided, this matches all port names and numbers.", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.util.intstr.IntOrString" + }, + "protocol": { + "description": "The protocol (TCP or UDP) which traffic must match. If not specified, this field defaults to TCP.", + "type": "string" + } + } + }, + "io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicySpec": { + "description": "NetworkPolicySpec provides the specification of a NetworkPolicy", + "required": [ + "podSelector" + ], + "properties": { + "ingress": { + "description": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod (and cluster policy otherwise allows the traffic), OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default)", + "type": "array", + "items": { + "$ref": "#/definitions/io.k8s.kubernetes.pkg.apis.networking.v1.NetworkPolicyIngressRule" + } + }, + "podSelector": { + "description": "Selects the pods to which this NetworkPolicy object applies. The array of ingress rules is applied to any pods selected by this field. Multiple network policies can select the same set of pods. In this case, the ingress rules for each are combined additively. This field is NOT optional and follows standard label selector semantics. An empty podSelector matches all pods in this namespace.", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.LabelSelector" + } + } + }, "io.k8s.kubernetes.pkg.apis.policy.v1beta1.Eviction": { "description": "Eviction evicts a pod from its node subject to certain policies and safety constraints. This is a subresource of Pod. A request to cause such an eviction is created by POSTing to .../pods/\u003cpod name\u003e/evictions.", "properties": { @@ -50429,9 +53921,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "policy", - "Version": "v1beta1", - "Kind": "Eviction" + "group": "policy", + "version": "v1beta1", + "kind": "Eviction" } ] }, @@ -50460,9 +53952,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudget" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudget" } ] }, @@ -50492,9 +53984,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "policy", - "Version": "v1beta1", - "Kind": "PodDisruptionBudgetList" + "group": "policy", + "version": "v1beta1", + "kind": "PodDisruptionBudgetList" } ] }, @@ -50587,9 +54079,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRole" } ] }, @@ -50626,9 +54118,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRoleBinding" } ] }, @@ -50660,9 +54152,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRoleBindingList" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRoleBindingList" } ] }, @@ -50694,9 +54186,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "ClusterRoleList" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "ClusterRoleList" } ] }, @@ -50771,9 +54263,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "Role" } ] }, @@ -50810,9 +54302,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleBinding" } ] }, @@ -50844,9 +54336,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleBindingList" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleBindingList" } ] }, @@ -50878,9 +54370,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1alpha1", - "Kind": "RoleList" + "group": "rbac.authorization.k8s.io", + "version": "v1alpha1", + "kind": "RoleList" } ] }, @@ -50959,9 +54451,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRole" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRole" } ] }, @@ -50998,9 +54490,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRoleBinding" } ] }, @@ -51032,9 +54524,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRoleBindingList" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRoleBindingList" } ] }, @@ -51066,9 +54558,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "ClusterRoleList" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "ClusterRoleList" } ] }, @@ -51143,9 +54635,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "Role" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "Role" } ] }, @@ -51182,9 +54674,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleBinding" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleBinding" } ] }, @@ -51216,9 +54708,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleBindingList" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleBindingList" } ] }, @@ -51250,9 +54742,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "rbac.authorization.k8s.io", - "Version": "v1beta1", - "Kind": "RoleList" + "group": "rbac.authorization.k8s.io", + "version": "v1beta1", + "kind": "RoleList" } ] }, @@ -51323,9 +54815,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "settings.k8s.io", - "Version": "v1alpha1", - "Kind": "PodPreset" + "group": "settings.k8s.io", + "version": "v1alpha1", + "kind": "PodPreset" } ] }, @@ -51357,9 +54849,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "settings.k8s.io", - "Version": "v1alpha1", - "Kind": "PodPresetList" + "group": "settings.k8s.io", + "version": "v1alpha1", + "kind": "PodPresetList" } ] }, @@ -51432,9 +54924,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "storage.k8s.io", - "Version": "v1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1", + "kind": "StorageClass" } ] }, @@ -51466,9 +54958,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "storage.k8s.io", - "Version": "v1", - "Kind": "StorageClassList" + "group": "storage.k8s.io", + "version": "v1", + "kind": "StorageClassList" } ] }, @@ -51504,9 +54996,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "storage.k8s.io", - "Version": "v1beta1", - "Kind": "StorageClass" + "group": "storage.k8s.io", + "version": "v1beta1", + "kind": "StorageClass" } ] }, @@ -51538,9 +55030,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "storage.k8s.io", - "Version": "v1beta1", - "Kind": "StorageClassList" + "group": "storage.k8s.io", + "version": "v1beta1", + "kind": "StorageClassList" } ] } diff --git a/api/swagger-spec/admissionregistration.k8s.io.json b/api/swagger-spec/admissionregistration.k8s.io.json new file mode 100644 index 0000000000000..f4cc3f04b8295 --- /dev/null +++ b/api/swagger-spec/admissionregistration.k8s.io.json @@ -0,0 +1,114 @@ +{ + "swaggerVersion": "1.2", + "apiVersion": "", + "basePath": "https://10.10.10.10:6443", + "resourcePath": "/apis/admissionregistration.k8s.io", + "info": { + "title": "", + "description": "" + }, + "apis": [ + { + "path": "/apis/admissionregistration.k8s.io", + "description": "get information of a group", + "operations": [ + { + "type": "v1.APIGroup", + "method": "GET", + "summary": "get information of a group", + "nickname": "getAPIGroup", + "parameters": [], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ] + } + ] + } + ], + "models": { + "v1.APIGroup": { + "id": "v1.APIGroup", + "description": "APIGroup contains the name, the supported versions, and the preferred version of a group.", + "required": [ + "name", + "versions", + "serverAddressByClientCIDRs" + ], + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "name": { + "type": "string", + "description": "name is the name of the group." + }, + "versions": { + "type": "array", + "items": { + "$ref": "v1.GroupVersionForDiscovery" + }, + "description": "versions are the versions supported in this group." + }, + "preferredVersion": { + "$ref": "v1.GroupVersionForDiscovery", + "description": "preferredVersion is the version preferred by the API server, which probably is the storage version." + }, + "serverAddressByClientCIDRs": { + "type": "array", + "items": { + "$ref": "v1.ServerAddressByClientCIDR" + }, + "description": "a map of client CIDR to server address that is serving this group. This is to help clients reach servers in the most network-efficient way possible. Clients can use the appropriate server address as per the CIDR that they match. In case of multiple matches, clients should use the longest matching CIDR. The server returns only those CIDRs that it thinks that the client can match. For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP." + } + } + }, + "v1.GroupVersionForDiscovery": { + "id": "v1.GroupVersionForDiscovery", + "description": "GroupVersion contains the \"group/version\" and \"version\" string of a version. It is made a struct to keep extensibility.", + "required": [ + "groupVersion", + "version" + ], + "properties": { + "groupVersion": { + "type": "string", + "description": "groupVersion specifies the API group and version in the form \"group/version\"" + }, + "version": { + "type": "string", + "description": "version specifies the version in the form of \"version\". This is to save the clients the trouble of splitting the GroupVersion." + } + } + }, + "v1.ServerAddressByClientCIDR": { + "id": "v1.ServerAddressByClientCIDR", + "description": "ServerAddressByClientCIDR helps the client to determine the server address that they should use, depending on the clientCIDR that they match.", + "required": [ + "clientCIDR", + "serverAddress" + ], + "properties": { + "clientCIDR": { + "type": "string", + "description": "The CIDR with which clients can match their IP to figure out the server address that they should use." + }, + "serverAddress": { + "type": "string", + "description": "Address of this server, suitable for a client that matches the above CIDR. This can be a hostname, hostname:port, IP or IP:port." + } + } + } + } + } diff --git a/api/swagger-spec/admissionregistration.k8s.io_v1alpha1.json b/api/swagger-spec/admissionregistration.k8s.io_v1alpha1.json new file mode 100644 index 0000000000000..a85b226b177f9 --- /dev/null +++ b/api/swagger-spec/admissionregistration.k8s.io_v1alpha1.json @@ -0,0 +1,1924 @@ +{ + "swaggerVersion": "1.2", + "apiVersion": "admissionregistration.k8s.io/v1alpha1", + "basePath": "https://10.10.10.10:6443", + "resourcePath": "/apis/admissionregistration.k8s.io/v1alpha1", + "info": { + "title": "", + "description": "" + }, + "apis": [ + { + "path": "/apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations", + "description": "API at /apis/admissionregistration.k8s.io/v1alpha1", + "operations": [ + { + "type": "v1alpha1.ExternalAdmissionHookConfigurationList", + "method": "GET", + "summary": "list or watch objects of kind ExternalAdmissionHookConfiguration", + "nickname": "listExternalAdmissionHookConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1alpha1.ExternalAdmissionHookConfigurationList" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1alpha1.ExternalAdmissionHookConfiguration", + "method": "POST", + "summary": "create an ExternalAdmissionHookConfiguration", + "nickname": "createExternalAdmissionHookConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1alpha1.ExternalAdmissionHookConfiguration", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1alpha1.ExternalAdmissionHookConfiguration" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1.Status", + "method": "DELETE", + "summary": "delete collection of ExternalAdmissionHookConfiguration", + "nickname": "deletecollectionExternalAdmissionHookConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.Status" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/admissionregistration.k8s.io/v1alpha1/watch/externaladmissionhookconfigurations", + "description": "API at /apis/admissionregistration.k8s.io/v1alpha1", + "operations": [ + { + "type": "v1.WatchEvent", + "method": "GET", + "summary": "watch individual changes to a list of ExternalAdmissionHookConfiguration", + "nickname": "watchExternalAdmissionHookConfigurationList", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.WatchEvent" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations/{name}", + "description": "API at /apis/admissionregistration.k8s.io/v1alpha1", + "operations": [ + { + "type": "v1alpha1.ExternalAdmissionHookConfiguration", + "method": "GET", + "summary": "read the specified ExternalAdmissionHookConfiguration", + "nickname": "readExternalAdmissionHookConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "export", + "description": "Should this value be exported. Export strips fields that a user can not specify.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "exact", + "description": "Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the ExternalAdmissionHookConfiguration", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1alpha1.ExternalAdmissionHookConfiguration" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1alpha1.ExternalAdmissionHookConfiguration", + "method": "PUT", + "summary": "replace the specified ExternalAdmissionHookConfiguration", + "nickname": "replaceExternalAdmissionHookConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1alpha1.ExternalAdmissionHookConfiguration", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the ExternalAdmissionHookConfiguration", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1alpha1.ExternalAdmissionHookConfiguration" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1alpha1.ExternalAdmissionHookConfiguration", + "method": "PATCH", + "summary": "partially update the specified ExternalAdmissionHookConfiguration", + "nickname": "patchExternalAdmissionHookConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1.Patch", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the ExternalAdmissionHookConfiguration", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1alpha1.ExternalAdmissionHookConfiguration" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "application/json-patch+json", + "application/merge-patch+json", + "application/strategic-merge-patch+json" + ] + }, + { + "type": "v1.Status", + "method": "DELETE", + "summary": "delete an ExternalAdmissionHookConfiguration", + "nickname": "deleteExternalAdmissionHookConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1.DeleteOptions", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "gracePeriodSeconds", + "description": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "orphanDependents", + "description": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "propagationPolicy", + "description": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the ExternalAdmissionHookConfiguration", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.Status" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/admissionregistration.k8s.io/v1alpha1/watch/externaladmissionhookconfigurations/{name}", + "description": "API at /apis/admissionregistration.k8s.io/v1alpha1", + "operations": [ + { + "type": "v1.WatchEvent", + "method": "GET", + "summary": "watch changes to an object of kind ExternalAdmissionHookConfiguration", + "nickname": "watchExternalAdmissionHookConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the ExternalAdmissionHookConfiguration", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.WatchEvent" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations", + "description": "API at /apis/admissionregistration.k8s.io/v1alpha1", + "operations": [ + { + "type": "v1alpha1.InitializerConfigurationList", + "method": "GET", + "summary": "list or watch objects of kind InitializerConfiguration", + "nickname": "listInitializerConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1alpha1.InitializerConfigurationList" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1alpha1.InitializerConfiguration", + "method": "POST", + "summary": "create an InitializerConfiguration", + "nickname": "createInitializerConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1alpha1.InitializerConfiguration", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1alpha1.InitializerConfiguration" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1.Status", + "method": "DELETE", + "summary": "delete collection of InitializerConfiguration", + "nickname": "deletecollectionInitializerConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.Status" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/admissionregistration.k8s.io/v1alpha1/watch/initializerconfigurations", + "description": "API at /apis/admissionregistration.k8s.io/v1alpha1", + "operations": [ + { + "type": "v1.WatchEvent", + "method": "GET", + "summary": "watch individual changes to a list of InitializerConfiguration", + "nickname": "watchInitializerConfigurationList", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.WatchEvent" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations/{name}", + "description": "API at /apis/admissionregistration.k8s.io/v1alpha1", + "operations": [ + { + "type": "v1alpha1.InitializerConfiguration", + "method": "GET", + "summary": "read the specified InitializerConfiguration", + "nickname": "readInitializerConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "export", + "description": "Should this value be exported. Export strips fields that a user can not specify.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "exact", + "description": "Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the InitializerConfiguration", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1alpha1.InitializerConfiguration" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1alpha1.InitializerConfiguration", + "method": "PUT", + "summary": "replace the specified InitializerConfiguration", + "nickname": "replaceInitializerConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1alpha1.InitializerConfiguration", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the InitializerConfiguration", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1alpha1.InitializerConfiguration" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1alpha1.InitializerConfiguration", + "method": "PATCH", + "summary": "partially update the specified InitializerConfiguration", + "nickname": "patchInitializerConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1.Patch", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the InitializerConfiguration", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1alpha1.InitializerConfiguration" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "application/json-patch+json", + "application/merge-patch+json", + "application/strategic-merge-patch+json" + ] + }, + { + "type": "v1.Status", + "method": "DELETE", + "summary": "delete an InitializerConfiguration", + "nickname": "deleteInitializerConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1.DeleteOptions", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "gracePeriodSeconds", + "description": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "orphanDependents", + "description": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "propagationPolicy", + "description": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the InitializerConfiguration", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.Status" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/admissionregistration.k8s.io/v1alpha1/watch/initializerconfigurations/{name}", + "description": "API at /apis/admissionregistration.k8s.io/v1alpha1", + "operations": [ + { + "type": "v1.WatchEvent", + "method": "GET", + "summary": "watch changes to an object of kind InitializerConfiguration", + "nickname": "watchInitializerConfiguration", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the InitializerConfiguration", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.WatchEvent" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/admissionregistration.k8s.io/v1alpha1", + "description": "API at /apis/admissionregistration.k8s.io/v1alpha1", + "operations": [ + { + "type": "v1.APIResourceList", + "method": "GET", + "summary": "get available resources", + "nickname": "getAPIResources", + "parameters": [], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ] + } + ] + } + ], + "models": { + "v1alpha1.ExternalAdmissionHookConfigurationList": { + "id": "v1alpha1.ExternalAdmissionHookConfigurationList", + "description": "ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration.", + "required": [ + "items" + ], + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "metadata": { + "$ref": "v1.ListMeta", + "description": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "items": { + "type": "array", + "items": { + "$ref": "v1alpha1.ExternalAdmissionHookConfiguration" + }, + "description": "List of ExternalAdmissionHookConfiguration." + } + } + }, + "v1.ListMeta": { + "id": "v1.ListMeta", + "description": "ListMeta describes metadata that synthetic resources must have, including lists and various status objects. A resource may have only one of {ObjectMeta, ListMeta}.", + "properties": { + "selfLink": { + "type": "string", + "description": "SelfLink is a URL representing this object. Populated by the system. Read-only." + }, + "resourceVersion": { + "type": "string", + "description": "String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency" + } + } + }, + "v1alpha1.ExternalAdmissionHookConfiguration": { + "id": "v1alpha1.ExternalAdmissionHookConfiguration", + "description": "ExternalAdmissionHookConfiguration describes the configuration of initializers.", + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "metadata": { + "$ref": "v1.ObjectMeta", + "description": "Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata." + }, + "externalAdmissionHooks": { + "type": "array", + "items": { + "$ref": "v1alpha1.ExternalAdmissionHook" + }, + "description": "ExternalAdmissionHooks is a list of external admission webhooks and the affected resources and operations." + } + } + }, + "v1.ObjectMeta": { + "id": "v1.ObjectMeta", + "description": "ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create.", + "properties": { + "name": { + "type": "string", + "description": "Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names" + }, + "generateName": { + "type": "string", + "description": "GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server.\n\nIf this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header).\n\nApplied only if Name is not specified. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#idempotency" + }, + "namespace": { + "type": "string", + "description": "Namespace defines the space within each name must be unique. An empty namespace is equivalent to the \"default\" namespace, but \"default\" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty.\n\nMust be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces" + }, + "selfLink": { + "type": "string", + "description": "SelfLink is a URL representing this object. Populated by the system. Read-only." + }, + "uid": { + "type": "string", + "description": "UID is the unique in time and space value for this object. It is typically generated by the server on successful creation of a resource and is not allowed to change on PUT operations.\n\nPopulated by the system. Read-only. More info: http://kubernetes.io/docs/user-guide/identifiers#uids" + }, + "resourceVersion": { + "type": "string", + "description": "An opaque value that represents the internal version of this object that can be used by clients to determine when objects have changed. May be used for optimistic concurrency, change detection, and the watch operation on a resource or set of resources. Clients must treat these values as opaque and passed unmodified back to the server. They may only be valid for a particular resource or set of resources.\n\nPopulated by the system. Read-only. Value must be treated as opaque by clients and . More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency" + }, + "generation": { + "type": "integer", + "format": "int64", + "description": "A sequence number representing a specific generation of the desired state. Populated by the system. Read-only." + }, + "creationTimestamp": { + "type": "string", + "description": "CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.\n\nPopulated by the system. Read-only. Null for lists. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata" + }, + "deletionTimestamp": { + "type": "string", + "description": "DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource is expected to be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field. Once set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, remove the pod from the API. In the presence of network partitions, this object may still exist after this timestamp, until an administrator or automated process can determine the resource is fully terminated. If not set, graceful deletion of the object has not been requested.\n\nPopulated by the system when a graceful deletion is requested. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata" + }, + "deletionGracePeriodSeconds": { + "type": "integer", + "format": "int64", + "description": "Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only." + }, + "labels": { + "type": "object", + "description": "Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels" + }, + "annotations": { + "type": "object", + "description": "Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations" + }, + "ownerReferences": { + "type": "array", + "items": { + "$ref": "v1.OwnerReference" + }, + "description": "List of objects depended by this object. If ALL objects in the list have been deleted, this object will be garbage collected. If this object is managed by a controller, then an entry in this list will point to this controller, with the controller field set to true. There cannot be more than one managing controller." + }, + "initializers": { + "$ref": "v1.Initializers", + "description": "An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects.\n\nWhen an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user." + }, + "finalizers": { + "type": "array", + "items": { + "type": "string" + }, + "description": "Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed." + }, + "clusterName": { + "type": "string", + "description": "The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request." + } + } + }, + "v1.OwnerReference": { + "id": "v1.OwnerReference", + "description": "OwnerReference contains enough information to let you identify an owning object. Currently, an owning object must be in the same namespace, so there is no namespace field.", + "required": [ + "apiVersion", + "kind", + "name", + "uid" + ], + "properties": { + "apiVersion": { + "type": "string", + "description": "API version of the referent." + }, + "kind": { + "type": "string", + "description": "Kind of the referent. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "name": { + "type": "string", + "description": "Name of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#names" + }, + "uid": { + "type": "string", + "description": "UID of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#uids" + }, + "controller": { + "type": "boolean", + "description": "If true, this reference points to the managing controller." + }, + "blockOwnerDeletion": { + "type": "boolean", + "description": "If true, AND if the owner has the \"foregroundDeletion\" finalizer, then the owner cannot be deleted from the key-value store until this reference is removed. Defaults to false. To set this field, a user needs \"delete\" permission of the owner, otherwise 422 (Unprocessable Entity) will be returned." + } + } + }, + "v1.Initializers": { + "id": "v1.Initializers", + "description": "Initializers tracks the progress of initialization.", + "required": [ + "pending" + ], + "properties": { + "pending": { + "type": "array", + "items": { + "$ref": "v1.Initializer" + }, + "description": "Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients." + }, + "result": { + "$ref": "v1.Status", + "description": "If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion." + } + } + }, + "v1.Initializer": { + "id": "v1.Initializer", + "description": "Initializer is information about an initializer that has not yet completed.", + "required": [ + "name" + ], + "properties": { + "name": { + "type": "string", + "description": "name of the process that is responsible for initializing this object." + } + } + }, + "v1.Status": { + "id": "v1.Status", + "description": "Status is a return value for calls that don't return other objects.", + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "metadata": { + "$ref": "v1.ListMeta", + "description": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "status": { + "type": "string", + "description": "Status of the operation. One of: \"Success\" or \"Failure\". More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status" + }, + "message": { + "type": "string", + "description": "A human-readable description of the status of this operation." + }, + "reason": { + "type": "string", + "description": "A machine-readable description of why this operation is in the \"Failure\" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it." + }, + "details": { + "$ref": "v1.StatusDetails", + "description": "Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type." + }, + "code": { + "type": "integer", + "format": "int32", + "description": "Suggested HTTP return code for this status, 0 if not set." + } + } + }, + "v1.StatusDetails": { + "id": "v1.StatusDetails", + "description": "StatusDetails is a set of additional properties that MAY be set by the server to provide additional information about a response. The Reason field of a Status object defines what attributes will be set. Clients must ignore fields that do not match the defined type of each attribute, and should assume that any attribute may be empty, invalid, or under defined.", + "properties": { + "name": { + "type": "string", + "description": "The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described)." + }, + "group": { + "type": "string", + "description": "The group attribute of the resource associated with the status StatusReason." + }, + "kind": { + "type": "string", + "description": "The kind attribute of the resource associated with the status StatusReason. On some operations may differ from the requested resource Kind. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "uid": { + "type": "string", + "description": "UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids" + }, + "causes": { + "type": "array", + "items": { + "$ref": "v1.StatusCause" + }, + "description": "The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes." + }, + "retryAfterSeconds": { + "type": "integer", + "format": "int32", + "description": "If specified, the time in seconds before the operation should be retried." + } + } + }, + "v1.StatusCause": { + "id": "v1.StatusCause", + "description": "StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered.", + "properties": { + "reason": { + "type": "string", + "description": "A machine-readable description of the cause of the error. If this value is empty there is no information available." + }, + "message": { + "type": "string", + "description": "A human-readable description of the cause of the error. This field may be presented as-is to a reader." + }, + "field": { + "type": "string", + "description": "The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional.\n\nExamples:\n \"name\" - the field \"name\" on the current resource\n \"items[0].name\" - the field \"name\" on the first array entry in \"items\"" + } + } + }, + "v1alpha1.ExternalAdmissionHook": { + "id": "v1alpha1.ExternalAdmissionHook", + "description": "ExternalAdmissionHook describes an external admission webhook and the resources and operations it applies to.", + "required": [ + "name", + "clientConfig" + ], + "properties": { + "name": { + "type": "string", + "description": "The name of the external admission webhook. Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where \"imagepolicy\" is the name of the webhook, and kubernetes.io is the name of the organization. Required." + }, + "clientConfig": { + "$ref": "v1alpha1.AdmissionHookClientConfig", + "description": "ClientConfig defines how to communicate with the hook. Required" + }, + "rules": { + "type": "array", + "items": { + "$ref": "v1alpha1.RuleWithOperations" + }, + "description": "Rules describes what operations on what resources/subresources the webhook cares about. The webhook cares about an operation if it matches _any_ Rule." + }, + "failurePolicy": { + "$ref": "v1alpha1.FailurePolicyType", + "description": "FailurePolicy defines how unrecognized errors from the admission endpoint are handled - allowed values are Ignore or Fail. Defaults to Ignore." + } + } + }, + "v1alpha1.AdmissionHookClientConfig": { + "id": "v1alpha1.AdmissionHookClientConfig", + "description": "AdmissionHookClientConfig contains the information to make a TLS connection with the webhook", + "required": [ + "service", + "caBundle" + ], + "properties": { + "service": { + "$ref": "v1alpha1.ServiceReference", + "description": "Service is a reference to the service for this webhook. If there is only one port open for the service, that port will be used. If there are multiple ports open, port 443 will be used if it is open, otherwise it is an error. Required" + }, + "caBundle": { + "type": "string", + "description": "CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. Required" + } + } + }, + "v1alpha1.ServiceReference": { + "id": "v1alpha1.ServiceReference", + "description": "ServiceReference holds a reference to Service.legacy.k8s.io", + "required": [ + "namespace", + "name" + ], + "properties": { + "namespace": { + "type": "string", + "description": "Namespace is the namespace of the service Required" + }, + "name": { + "type": "string", + "description": "Name is the name of the service Required" + } + } + }, + "v1alpha1.RuleWithOperations": { + "id": "v1alpha1.RuleWithOperations", + "description": "RuleWithOperations is a tuple of Operations and Resources. It is recommended to make sure that all the tuple expansions are valid.", + "properties": { + "operations": { + "type": "array", + "items": { + "$ref": "v1alpha1.OperationType" + }, + "description": "Operations is the operations the admission hook cares about - CREATE, UPDATE, or * for all operations. If '*' is present, the length of the slice must be one. Required." + }, + "apiGroups": { + "type": "array", + "items": { + "type": "string" + }, + "description": "APIGroups is the API groups the resources belong to. '*' is all groups. If '*' is present, the length of the slice must be one. Required." + }, + "apiVersions": { + "type": "array", + "items": { + "type": "string" + }, + "description": "APIVersions is the API versions the resources belong to. '*' is all versions. If '*' is present, the length of the slice must be one. Required." + }, + "resources": { + "type": "array", + "items": { + "type": "string" + }, + "description": "Resources is a list of resources this rule applies to.\n\nFor example: 'pods' means pods. 'pods/log' means the log subresource of pods. '*' means all resources, but not subresources. 'pods/*' means all subresources of pods. '*/scale' means all scale subresources. '*/*' means all resources and their subresources.\n\nIf '*' or '*/*' is present, the length of the slice must be one. Required." + } + } + }, + "v1alpha1.OperationType": { + "id": "v1alpha1.OperationType", + "properties": {} + }, + "v1alpha1.FailurePolicyType": { + "id": "v1alpha1.FailurePolicyType", + "properties": {} + }, + "v1.WatchEvent": { + "id": "v1.WatchEvent", + "required": [ + "type", + "object" + ], + "properties": { + "type": { + "type": "string" + }, + "object": { + "type": "string" + } + } + }, + "v1.Patch": { + "id": "v1.Patch", + "description": "Patch is provided to give a concrete name and type to the Kubernetes PATCH request body.", + "properties": {} + }, + "v1.DeleteOptions": { + "id": "v1.DeleteOptions", + "description": "DeleteOptions may be provided when deleting an API object.", + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "gracePeriodSeconds": { + "type": "integer", + "format": "int64", + "description": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately." + }, + "preconditions": { + "$ref": "v1.Preconditions", + "description": "Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned." + }, + "orphanDependents": { + "type": "boolean", + "description": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both." + }, + "propagationPolicy": { + "$ref": "v1.DeletionPropagation", + "description": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy." + } + } + }, + "v1.Preconditions": { + "id": "v1.Preconditions", + "description": "Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.", + "properties": { + "uid": { + "$ref": "types.UID", + "description": "Specifies the target UID." + } + } + }, + "types.UID": { + "id": "types.UID", + "properties": {} + }, + "v1.DeletionPropagation": { + "id": "v1.DeletionPropagation", + "properties": {} + }, + "v1alpha1.InitializerConfigurationList": { + "id": "v1alpha1.InitializerConfigurationList", + "description": "InitializerConfigurationList is a list of InitializerConfiguration.", + "required": [ + "items" + ], + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "metadata": { + "$ref": "v1.ListMeta", + "description": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "items": { + "type": "array", + "items": { + "$ref": "v1alpha1.InitializerConfiguration" + }, + "description": "List of InitializerConfiguration." + } + } + }, + "v1alpha1.InitializerConfiguration": { + "id": "v1alpha1.InitializerConfiguration", + "description": "InitializerConfiguration describes the configuration of initializers.", + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "metadata": { + "$ref": "v1.ObjectMeta", + "description": "Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata." + }, + "initializers": { + "type": "array", + "items": { + "$ref": "v1alpha1.Initializer" + }, + "description": "Initializers is a list of resources and their default initializers Order-sensitive. When merging multiple InitializerConfigurations, we sort the initializers from different InitializerConfigurations by the name of the InitializerConfigurations; the order of the initializers from the same InitializerConfiguration is preserved." + } + } + }, + "v1alpha1.Initializer": { + "id": "v1alpha1.Initializer", + "description": "Initializer describes the name and the failure policy of an initializer, and what resources it applies to.", + "required": [ + "name" + ], + "properties": { + "name": { + "type": "string", + "description": "Name is the identifier of the initializer. It will be added to the object that needs to be initialized. Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where \"alwayspullimages\" is the name of the webhook, and kubernetes.io is the name of the organization. Required" + }, + "rules": { + "type": "array", + "items": { + "$ref": "v1alpha1.Rule" + }, + "description": "Rules describes what resources/subresources the initializer cares about. The initializer cares about an operation if it matches _any_ Rule." + }, + "failurePolicy": { + "$ref": "v1alpha1.FailurePolicyType", + "description": "FailurePolicy defines what happens if the responsible initializer controller fails to takes action. Allowed values are Ignore, or Fail. If \"Ignore\" is set, initializer is removed from the initializers list of an object if the timeout is reached; If \"Fail\" is set, admissionregistration returns timeout error if the timeout is reached." + } + } + }, + "v1alpha1.Rule": { + "id": "v1alpha1.Rule", + "description": "Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended to make sure that all the tuple expansions are valid.", + "properties": { + "apiGroups": { + "type": "array", + "items": { + "type": "string" + }, + "description": "APIGroups is the API groups the resources belong to. '*' is all groups. If '*' is present, the length of the slice must be one. Required." + }, + "apiVersions": { + "type": "array", + "items": { + "type": "string" + }, + "description": "APIVersions is the API versions the resources belong to. '*' is all versions. If '*' is present, the length of the slice must be one. Required." + }, + "resources": { + "type": "array", + "items": { + "type": "string" + }, + "description": "Resources is a list of resources this rule applies to.\n\nFor example: 'pods' means pods. 'pods/log' means the log subresource of pods. '*' means all resources, but not subresources. 'pods/*' means all subresources of pods. '*/scale' means all scale subresources. '*/*' means all resources and their subresources.\n\nIf '*' or '*/*' is present, the length of the slice must be one. Required." + } + } + }, + "v1.APIResourceList": { + "id": "v1.APIResourceList", + "description": "APIResourceList is a list of APIResource, it is used to expose the name of the resources supported in a specific group and version, and if the resource is namespaced.", + "required": [ + "groupVersion", + "resources" + ], + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "groupVersion": { + "type": "string", + "description": "groupVersion is the group and version this APIResourceList is for." + }, + "resources": { + "type": "array", + "items": { + "$ref": "v1.APIResource" + }, + "description": "resources contains the name of the resources and if they are namespaced." + } + } + }, + "v1.APIResource": { + "id": "v1.APIResource", + "description": "APIResource specifies the name of a resource and whether it is namespaced.", + "required": [ + "name", + "singularName", + "namespaced", + "kind", + "verbs" + ], + "properties": { + "name": { + "type": "string", + "description": "name is the plural name of the resource." + }, + "singularName": { + "type": "string", + "description": "singularName is the singular name of the resource. This allows clients to handle plural and singular opaquely. The singularName is more correct for reporting status on a single item and both singular and plural are allowed from the kubectl CLI interface." + }, + "namespaced": { + "type": "boolean", + "description": "namespaced indicates if a resource is namespaced or not." + }, + "kind": { + "type": "string", + "description": "kind is the kind for the resource (e.g. 'Foo' is the kind for a resource 'foo')" + }, + "verbs": { + "type": "array", + "items": { + "type": "string" + }, + "description": "verbs is a list of supported kube verbs (this includes get, list, watch, create, update, patch, delete, deletecollection, and proxy)" + }, + "shortNames": { + "type": "array", + "items": { + "type": "string" + }, + "description": "shortNames is a list of suggested short names of the resource." + } + } + } + } + } diff --git a/api/swagger-spec/apps_v1beta1.json b/api/swagger-spec/apps_v1beta1.json index 3110d33c32a35..c3d5ec21bc78a 100644 --- a/api/swagger-spec/apps_v1beta1.json +++ b/api/swagger-spec/apps_v1beta1.json @@ -8,6 +8,867 @@ "description": "" }, "apis": [ + { + "path": "/apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions", + "description": "API at /apis/apps/v1beta1", + "operations": [ + { + "type": "v1beta1.ControllerRevisionList", + "method": "GET", + "summary": "list or watch objects of kind ControllerRevision", + "nickname": "listNamespacedControllerRevision", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1beta1.ControllerRevisionList" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1beta1.ControllerRevision", + "method": "POST", + "summary": "create a ControllerRevision", + "nickname": "createNamespacedControllerRevision", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1beta1.ControllerRevision", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1beta1.ControllerRevision" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1.Status", + "method": "DELETE", + "summary": "delete collection of ControllerRevision", + "nickname": "deletecollectionNamespacedControllerRevision", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.Status" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/apps/v1beta1/watch/namespaces/{namespace}/controllerrevisions", + "description": "API at /apis/apps/v1beta1", + "operations": [ + { + "type": "v1.WatchEvent", + "method": "GET", + "summary": "watch individual changes to a list of ControllerRevision", + "nickname": "watchNamespacedControllerRevisionList", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.WatchEvent" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions/{name}", + "description": "API at /apis/apps/v1beta1", + "operations": [ + { + "type": "v1beta1.ControllerRevision", + "method": "GET", + "summary": "read the specified ControllerRevision", + "nickname": "readNamespacedControllerRevision", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "export", + "description": "Should this value be exported. Export strips fields that a user can not specify.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "exact", + "description": "Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the ControllerRevision", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1beta1.ControllerRevision" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1beta1.ControllerRevision", + "method": "PUT", + "summary": "replace the specified ControllerRevision", + "nickname": "replaceNamespacedControllerRevision", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1beta1.ControllerRevision", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the ControllerRevision", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1beta1.ControllerRevision" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1beta1.ControllerRevision", + "method": "PATCH", + "summary": "partially update the specified ControllerRevision", + "nickname": "patchNamespacedControllerRevision", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1.Patch", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the ControllerRevision", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1beta1.ControllerRevision" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "application/json-patch+json", + "application/merge-patch+json", + "application/strategic-merge-patch+json" + ] + }, + { + "type": "v1.Status", + "method": "DELETE", + "summary": "delete a ControllerRevision", + "nickname": "deleteNamespacedControllerRevision", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1.DeleteOptions", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "gracePeriodSeconds", + "description": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "orphanDependents", + "description": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "propagationPolicy", + "description": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the ControllerRevision", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.Status" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/apps/v1beta1/watch/namespaces/{namespace}/controllerrevisions/{name}", + "description": "API at /apis/apps/v1beta1", + "operations": [ + { + "type": "v1.WatchEvent", + "method": "GET", + "summary": "watch changes to an object of kind ControllerRevision", + "nickname": "watchNamespacedControllerRevision", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the ControllerRevision", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.WatchEvent" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/apps/v1beta1/controllerrevisions", + "description": "API at /apis/apps/v1beta1", + "operations": [ + { + "type": "v1beta1.ControllerRevisionList", + "method": "GET", + "summary": "list or watch objects of kind ControllerRevision", + "nickname": "listControllerRevisionForAllNamespaces", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1beta1.ControllerRevisionList" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/apps/v1beta1/watch/controllerrevisions", + "description": "API at /apis/apps/v1beta1", + "operations": [ + { + "type": "v1.WatchEvent", + "method": "GET", + "summary": "watch individual changes to a list of ControllerRevision", + "nickname": "watchControllerRevisionListForAllNamespaces", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.WatchEvent" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + } + ] + }, { "path": "/apis/apps/v1beta1/namespaces/{namespace}/deployments", "description": "API at /apis/apps/v1beta1", @@ -2311,9 +3172,9 @@ } ], "models": { - "v1beta1.DeploymentList": { - "id": "v1beta1.DeploymentList", - "description": "DeploymentList is a list of Deployments.", + "v1beta1.ControllerRevisionList": { + "id": "v1beta1.ControllerRevisionList", + "description": "ControllerRevisionList is a resource containing a list of ControllerRevision objects.", "required": [ "items" ], @@ -2328,14 +3189,14 @@ }, "metadata": { "$ref": "v1.ListMeta", - "description": "Standard list metadata." + "description": "More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata" }, "items": { "type": "array", "items": { - "$ref": "v1beta1.Deployment" + "$ref": "v1beta1.ControllerRevision" }, - "description": "Items is the list of Deployments." + "description": "Items is the list of ControllerRevisions" } } }, @@ -2353,9 +3214,12 @@ } } }, - "v1beta1.Deployment": { - "id": "v1beta1.Deployment", - "description": "Deployment enables declarative updates for Pods and ReplicaSets.", + "v1beta1.ControllerRevision": { + "id": "v1beta1.ControllerRevision", + "description": "ControllerRevision implements an immutable snapshot of state data. Clients are responsible for serializing and deserializing the objects that contain their internal state. Once a ControllerRevision has been successfully created, it can not be updated. The API Server will fail validation of all requests that attempt to mutate the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, it may be subject to name and representation changes in future releases, and clients should not depend on its stability. It is primarily for internal use by controllers.", + "required": [ + "revision" + ], "properties": { "kind": { "type": "string", @@ -2367,15 +3231,16 @@ }, "metadata": { "$ref": "v1.ObjectMeta", - "description": "Standard object metadata." + "description": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata" }, - "spec": { - "$ref": "v1beta1.DeploymentSpec", - "description": "Specification of the desired behavior of the Deployment." + "data": { + "type": "string", + "description": "Data is the serialized representation of the state." }, - "status": { - "$ref": "v1beta1.DeploymentStatus", - "description": "Most recently observed status of the Deployment." + "revision": { + "type": "integer", + "format": "int64", + "description": "Revision indicates the revision of the state represented by Data." } } }, @@ -2617,6 +3482,129 @@ } } }, + "v1.WatchEvent": { + "id": "v1.WatchEvent", + "required": [ + "type", + "object" + ], + "properties": { + "type": { + "type": "string" + }, + "object": { + "type": "string" + } + } + }, + "v1.Patch": { + "id": "v1.Patch", + "description": "Patch is provided to give a concrete name and type to the Kubernetes PATCH request body.", + "properties": {} + }, + "v1.DeleteOptions": { + "id": "v1.DeleteOptions", + "description": "DeleteOptions may be provided when deleting an API object.", + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "gracePeriodSeconds": { + "type": "integer", + "format": "int64", + "description": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately." + }, + "preconditions": { + "$ref": "v1.Preconditions", + "description": "Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned." + }, + "orphanDependents": { + "type": "boolean", + "description": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both." + }, + "propagationPolicy": { + "$ref": "v1.DeletionPropagation", + "description": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy." + } + } + }, + "v1.Preconditions": { + "id": "v1.Preconditions", + "description": "Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.", + "properties": { + "uid": { + "$ref": "types.UID", + "description": "Specifies the target UID." + } + } + }, + "types.UID": { + "id": "types.UID", + "properties": {} + }, + "v1.DeletionPropagation": { + "id": "v1.DeletionPropagation", + "properties": {} + }, + "v1beta1.DeploymentList": { + "id": "v1beta1.DeploymentList", + "description": "DeploymentList is a list of Deployments.", + "required": [ + "items" + ], + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "metadata": { + "$ref": "v1.ListMeta", + "description": "Standard list metadata." + }, + "items": { + "type": "array", + "items": { + "$ref": "v1beta1.Deployment" + }, + "description": "Items is the list of Deployments." + } + } + }, + "v1beta1.Deployment": { + "id": "v1beta1.Deployment", + "description": "Deployment enables declarative updates for Pods and ReplicaSets.", + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "metadata": { + "$ref": "v1.ObjectMeta", + "description": "Standard object metadata." + }, + "spec": { + "$ref": "v1beta1.DeploymentSpec", + "description": "Specification of the desired behavior of the Deployment." + }, + "status": { + "$ref": "v1beta1.DeploymentStatus", + "description": "Most recently observed status of the Deployment." + } + } + }, "v1beta1.DeploymentSpec": { "id": "v1beta1.DeploymentSpec", "description": "DeploymentSpec is the specification of the desired behavior of the Deployment.", @@ -2980,6 +3968,10 @@ "medium": { "type": "string", "description": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir" + }, + "sizeLimit": { + "type": "string", + "description": "Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir" } } }, @@ -4662,7 +5654,7 @@ "revision": { "type": "integer", "format": "int64", - "description": "The revision to rollback to. If set to 0, rollbck to the last revision." + "description": "The revision to rollback to. If set to 0, rollback to the last revision." } } }, @@ -4748,75 +5740,6 @@ } } }, - "v1.WatchEvent": { - "id": "v1.WatchEvent", - "required": [ - "type", - "object" - ], - "properties": { - "type": { - "type": "string" - }, - "object": { - "type": "string" - } - } - }, - "v1.Patch": { - "id": "v1.Patch", - "description": "Patch is provided to give a concrete name and type to the Kubernetes PATCH request body.", - "properties": {} - }, - "v1.DeleteOptions": { - "id": "v1.DeleteOptions", - "description": "DeleteOptions may be provided when deleting an API object.", - "properties": { - "kind": { - "type": "string", - "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" - }, - "apiVersion": { - "type": "string", - "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" - }, - "gracePeriodSeconds": { - "type": "integer", - "format": "int64", - "description": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately." - }, - "preconditions": { - "$ref": "v1.Preconditions", - "description": "Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned." - }, - "orphanDependents": { - "type": "boolean", - "description": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both." - }, - "propagationPolicy": { - "$ref": "v1.DeletionPropagation", - "description": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy." - } - } - }, - "v1.Preconditions": { - "id": "v1.Preconditions", - "description": "Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.", - "properties": { - "uid": { - "$ref": "types.UID", - "description": "Specifies the target UID." - } - } - }, - "types.UID": { - "id": "types.UID", - "properties": {} - }, - "v1.DeletionPropagation": { - "id": "v1.DeletionPropagation", - "properties": {} - }, "v1beta1.DeploymentRollback": { "id": "v1beta1.DeploymentRollback", "description": "DeploymentRollback stores the information required to rollback a deployment.", diff --git a/api/swagger-spec/batch_v1.json b/api/swagger-spec/batch_v1.json index 3dd689dc4ed28..b77a10906e11e 100644 --- a/api/swagger-spec/batch_v1.json +++ b/api/swagger-spec/batch_v1.json @@ -1715,6 +1715,10 @@ "medium": { "type": "string", "description": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir" + }, + "sizeLimit": { + "type": "string", + "description": "Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir" } } }, diff --git a/api/swagger-spec/batch_v2alpha1.json b/api/swagger-spec/batch_v2alpha1.json index bc534fb9e82a4..c487740116078 100644 --- a/api/swagger-spec/batch_v2alpha1.json +++ b/api/swagger-spec/batch_v2alpha1.json @@ -2796,6 +2796,10 @@ "medium": { "type": "string", "description": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir" + }, + "sizeLimit": { + "type": "string", + "description": "Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir" } } }, diff --git a/api/swagger-spec/extensions_v1beta1.json b/api/swagger-spec/extensions_v1beta1.json index 22473d5265e67..9cf8f7cabe532 100644 --- a/api/swagger-spec/extensions_v1beta1.json +++ b/api/swagger-spec/extensions_v1beta1.json @@ -7435,6 +7435,10 @@ "medium": { "type": "string", "description": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir" + }, + "sizeLimit": { + "type": "string", + "description": "Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir" } } }, @@ -9364,7 +9368,7 @@ "revision": { "type": "integer", "format": "int64", - "description": "The revision to rollback to. If set to 0, rollbck to the last revision." + "description": "The revision to rollback to. If set to 0, rollback to the last revision." } } }, @@ -9765,6 +9769,7 @@ }, "v1beta1.NetworkPolicy": { "id": "v1beta1.NetworkPolicy", + "description": "NetworkPolicy describes what network traffic is allowed for a set of Pods", "properties": { "kind": { "type": "string", @@ -9799,7 +9804,7 @@ "items": { "$ref": "v1beta1.NetworkPolicyIngressRule" }, - "description": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not affect ingress isolation. If this field is present and contains at least one rule, this policy allows any traffic which matches at least one of the ingress rules in this list." + "description": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default)." } } }, @@ -9983,6 +9988,13 @@ "readOnlyRootFilesystem": { "type": "boolean", "description": "ReadOnlyRootFilesystem when set to true will force containers to run with a read only root file system. If the container specifically requests to run with a non-read only root file system the PSP should deny the pod. If set to false the container may run with a read only root file system if it wishes but it will not be forced to." + }, + "allowedHostPaths": { + "type": "array", + "items": { + "type": "string" + }, + "description": "AllowedHostPaths is a white list of allowed host path prefixes. Empty indicates that all host paths may be used." } } }, diff --git a/api/swagger-spec/networking.k8s.io.json b/api/swagger-spec/networking.k8s.io.json new file mode 100644 index 0000000000000..a1a0e3383aab9 --- /dev/null +++ b/api/swagger-spec/networking.k8s.io.json @@ -0,0 +1,114 @@ +{ + "swaggerVersion": "1.2", + "apiVersion": "", + "basePath": "https://10.10.10.10:6443", + "resourcePath": "/apis/networking.k8s.io", + "info": { + "title": "", + "description": "" + }, + "apis": [ + { + "path": "/apis/networking.k8s.io", + "description": "get information of a group", + "operations": [ + { + "type": "v1.APIGroup", + "method": "GET", + "summary": "get information of a group", + "nickname": "getAPIGroup", + "parameters": [], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ] + } + ] + } + ], + "models": { + "v1.APIGroup": { + "id": "v1.APIGroup", + "description": "APIGroup contains the name, the supported versions, and the preferred version of a group.", + "required": [ + "name", + "versions", + "serverAddressByClientCIDRs" + ], + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "name": { + "type": "string", + "description": "name is the name of the group." + }, + "versions": { + "type": "array", + "items": { + "$ref": "v1.GroupVersionForDiscovery" + }, + "description": "versions are the versions supported in this group." + }, + "preferredVersion": { + "$ref": "v1.GroupVersionForDiscovery", + "description": "preferredVersion is the version preferred by the API server, which probably is the storage version." + }, + "serverAddressByClientCIDRs": { + "type": "array", + "items": { + "$ref": "v1.ServerAddressByClientCIDR" + }, + "description": "a map of client CIDR to server address that is serving this group. This is to help clients reach servers in the most network-efficient way possible. Clients can use the appropriate server address as per the CIDR that they match. In case of multiple matches, clients should use the longest matching CIDR. The server returns only those CIDRs that it thinks that the client can match. For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP." + } + } + }, + "v1.GroupVersionForDiscovery": { + "id": "v1.GroupVersionForDiscovery", + "description": "GroupVersion contains the \"group/version\" and \"version\" string of a version. It is made a struct to keep extensibility.", + "required": [ + "groupVersion", + "version" + ], + "properties": { + "groupVersion": { + "type": "string", + "description": "groupVersion specifies the API group and version in the form \"group/version\"" + }, + "version": { + "type": "string", + "description": "version specifies the version in the form of \"version\". This is to save the clients the trouble of splitting the GroupVersion." + } + } + }, + "v1.ServerAddressByClientCIDR": { + "id": "v1.ServerAddressByClientCIDR", + "description": "ServerAddressByClientCIDR helps the client to determine the server address that they should use, depending on the clientCIDR that they match.", + "required": [ + "clientCIDR", + "serverAddress" + ], + "properties": { + "clientCIDR": { + "type": "string", + "description": "The CIDR with which clients can match their IP to figure out the server address that they should use." + }, + "serverAddress": { + "type": "string", + "description": "Address of this server, suitable for a client that matches the above CIDR. This can be a hostname, hostname:port, IP or IP:port." + } + } + } + } + } diff --git a/api/swagger-spec/networking.k8s.io_v1.json b/api/swagger-spec/networking.k8s.io_v1.json new file mode 100644 index 0000000000000..55ed0f3c84d5d --- /dev/null +++ b/api/swagger-spec/networking.k8s.io_v1.json @@ -0,0 +1,1455 @@ +{ + "swaggerVersion": "1.2", + "apiVersion": "networking.k8s.io/v1", + "basePath": "https://10.10.10.10:6443", + "resourcePath": "/apis/networking.k8s.io/v1", + "info": { + "title": "", + "description": "" + }, + "apis": [ + { + "path": "/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies", + "description": "API at /apis/networking.k8s.io/v1", + "operations": [ + { + "type": "v1.NetworkPolicyList", + "method": "GET", + "summary": "list or watch objects of kind NetworkPolicy", + "nickname": "listNamespacedNetworkPolicy", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.NetworkPolicyList" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1.NetworkPolicy", + "method": "POST", + "summary": "create a NetworkPolicy", + "nickname": "createNamespacedNetworkPolicy", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1.NetworkPolicy", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.NetworkPolicy" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1.Status", + "method": "DELETE", + "summary": "delete collection of NetworkPolicy", + "nickname": "deletecollectionNamespacedNetworkPolicy", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.Status" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/networking.k8s.io/v1/watch/namespaces/{namespace}/networkpolicies", + "description": "API at /apis/networking.k8s.io/v1", + "operations": [ + { + "type": "v1.WatchEvent", + "method": "GET", + "summary": "watch individual changes to a list of NetworkPolicy", + "nickname": "watchNamespacedNetworkPolicyList", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.WatchEvent" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}", + "description": "API at /apis/networking.k8s.io/v1", + "operations": [ + { + "type": "v1.NetworkPolicy", + "method": "GET", + "summary": "read the specified NetworkPolicy", + "nickname": "readNamespacedNetworkPolicy", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "export", + "description": "Should this value be exported. Export strips fields that a user can not specify.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "exact", + "description": "Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the NetworkPolicy", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.NetworkPolicy" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1.NetworkPolicy", + "method": "PUT", + "summary": "replace the specified NetworkPolicy", + "nickname": "replaceNamespacedNetworkPolicy", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1.NetworkPolicy", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the NetworkPolicy", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.NetworkPolicy" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + }, + { + "type": "v1.NetworkPolicy", + "method": "PATCH", + "summary": "partially update the specified NetworkPolicy", + "nickname": "patchNamespacedNetworkPolicy", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1.Patch", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the NetworkPolicy", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.NetworkPolicy" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "application/json-patch+json", + "application/merge-patch+json", + "application/strategic-merge-patch+json" + ] + }, + { + "type": "v1.Status", + "method": "DELETE", + "summary": "delete a NetworkPolicy", + "nickname": "deleteNamespacedNetworkPolicy", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "v1.DeleteOptions", + "paramType": "body", + "name": "body", + "description": "", + "required": true, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "gracePeriodSeconds", + "description": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "orphanDependents", + "description": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "propagationPolicy", + "description": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the NetworkPolicy", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.Status" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/networking.k8s.io/v1/watch/namespaces/{namespace}/networkpolicies/{name}", + "description": "API at /apis/networking.k8s.io/v1", + "operations": [ + { + "type": "v1.WatchEvent", + "method": "GET", + "summary": "watch changes to an object of kind NetworkPolicy", + "nickname": "watchNamespacedNetworkPolicy", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "namespace", + "description": "object name and auth scope, such as for teams and projects", + "required": true, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "path", + "name": "name", + "description": "name of the NetworkPolicy", + "required": true, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.WatchEvent" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/networking.k8s.io/v1/networkpolicies", + "description": "API at /apis/networking.k8s.io/v1", + "operations": [ + { + "type": "v1.NetworkPolicyList", + "method": "GET", + "summary": "list or watch objects of kind NetworkPolicy", + "nickname": "listNetworkPolicyForAllNamespaces", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.NetworkPolicyList" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/networking.k8s.io/v1/watch/networkpolicies", + "description": "API at /apis/networking.k8s.io/v1", + "operations": [ + { + "type": "v1.WatchEvent", + "method": "GET", + "summary": "watch individual changes to a list of NetworkPolicy", + "nickname": "watchNetworkPolicyListForAllNamespaces", + "parameters": [ + { + "type": "string", + "paramType": "query", + "name": "pretty", + "description": "If 'true', then the output is pretty printed.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "labelSelector", + "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "fieldSelector", + "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "includeUninitialized", + "description": "If true, partially initialized resources are included in the response.", + "required": false, + "allowMultiple": false + }, + { + "type": "boolean", + "paramType": "query", + "name": "watch", + "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "required": false, + "allowMultiple": false + }, + { + "type": "string", + "paramType": "query", + "name": "resourceVersion", + "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "required": false, + "allowMultiple": false + }, + { + "type": "integer", + "paramType": "query", + "name": "timeoutSeconds", + "description": "Timeout for the list/watch call.", + "required": false, + "allowMultiple": false + } + ], + "responseMessages": [ + { + "code": 200, + "message": "OK", + "responseModel": "v1.WatchEvent" + } + ], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf", + "application/json;stream=watch", + "application/vnd.kubernetes.protobuf;stream=watch" + ], + "consumes": [ + "*/*" + ] + } + ] + }, + { + "path": "/apis/networking.k8s.io/v1", + "description": "API at /apis/networking.k8s.io/v1", + "operations": [ + { + "type": "v1.APIResourceList", + "method": "GET", + "summary": "get available resources", + "nickname": "getAPIResources", + "parameters": [], + "produces": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ], + "consumes": [ + "application/json", + "application/yaml", + "application/vnd.kubernetes.protobuf" + ] + } + ] + } + ], + "models": { + "v1.NetworkPolicyList": { + "id": "v1.NetworkPolicyList", + "description": "NetworkPolicyList is a list of NetworkPolicy objects.", + "required": [ + "items" + ], + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "metadata": { + "$ref": "v1.ListMeta", + "description": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata" + }, + "items": { + "type": "array", + "items": { + "$ref": "v1.NetworkPolicy" + }, + "description": "Items is a list of schema objects." + } + } + }, + "v1.ListMeta": { + "id": "v1.ListMeta", + "description": "ListMeta describes metadata that synthetic resources must have, including lists and various status objects. A resource may have only one of {ObjectMeta, ListMeta}.", + "properties": { + "selfLink": { + "type": "string", + "description": "SelfLink is a URL representing this object. Populated by the system. Read-only." + }, + "resourceVersion": { + "type": "string", + "description": "String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency" + } + } + }, + "v1.NetworkPolicy": { + "id": "v1.NetworkPolicy", + "description": "NetworkPolicy describes what network traffic is allowed for a set of Pods", + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "metadata": { + "$ref": "v1.ObjectMeta", + "description": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata" + }, + "spec": { + "$ref": "v1.NetworkPolicySpec", + "description": "Specification of the desired behavior for this NetworkPolicy." + } + } + }, + "v1.ObjectMeta": { + "id": "v1.ObjectMeta", + "description": "ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create.", + "properties": { + "name": { + "type": "string", + "description": "Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names" + }, + "generateName": { + "type": "string", + "description": "GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server.\n\nIf this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header).\n\nApplied only if Name is not specified. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#idempotency" + }, + "namespace": { + "type": "string", + "description": "Namespace defines the space within each name must be unique. An empty namespace is equivalent to the \"default\" namespace, but \"default\" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty.\n\nMust be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces" + }, + "selfLink": { + "type": "string", + "description": "SelfLink is a URL representing this object. Populated by the system. Read-only." + }, + "uid": { + "type": "string", + "description": "UID is the unique in time and space value for this object. It is typically generated by the server on successful creation of a resource and is not allowed to change on PUT operations.\n\nPopulated by the system. Read-only. More info: http://kubernetes.io/docs/user-guide/identifiers#uids" + }, + "resourceVersion": { + "type": "string", + "description": "An opaque value that represents the internal version of this object that can be used by clients to determine when objects have changed. May be used for optimistic concurrency, change detection, and the watch operation on a resource or set of resources. Clients must treat these values as opaque and passed unmodified back to the server. They may only be valid for a particular resource or set of resources.\n\nPopulated by the system. Read-only. Value must be treated as opaque by clients and . More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency" + }, + "generation": { + "type": "integer", + "format": "int64", + "description": "A sequence number representing a specific generation of the desired state. Populated by the system. Read-only." + }, + "creationTimestamp": { + "type": "string", + "description": "CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.\n\nPopulated by the system. Read-only. Null for lists. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata" + }, + "deletionTimestamp": { + "type": "string", + "description": "DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource is expected to be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field. Once set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, remove the pod from the API. In the presence of network partitions, this object may still exist after this timestamp, until an administrator or automated process can determine the resource is fully terminated. If not set, graceful deletion of the object has not been requested.\n\nPopulated by the system when a graceful deletion is requested. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata" + }, + "deletionGracePeriodSeconds": { + "type": "integer", + "format": "int64", + "description": "Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only." + }, + "labels": { + "type": "object", + "description": "Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels" + }, + "annotations": { + "type": "object", + "description": "Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations" + }, + "ownerReferences": { + "type": "array", + "items": { + "$ref": "v1.OwnerReference" + }, + "description": "List of objects depended by this object. If ALL objects in the list have been deleted, this object will be garbage collected. If this object is managed by a controller, then an entry in this list will point to this controller, with the controller field set to true. There cannot be more than one managing controller." + }, + "initializers": { + "$ref": "v1.Initializers", + "description": "An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects.\n\nWhen an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user." + }, + "finalizers": { + "type": "array", + "items": { + "type": "string" + }, + "description": "Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed." + }, + "clusterName": { + "type": "string", + "description": "The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request." + } + } + }, + "v1.OwnerReference": { + "id": "v1.OwnerReference", + "description": "OwnerReference contains enough information to let you identify an owning object. Currently, an owning object must be in the same namespace, so there is no namespace field.", + "required": [ + "apiVersion", + "kind", + "name", + "uid" + ], + "properties": { + "apiVersion": { + "type": "string", + "description": "API version of the referent." + }, + "kind": { + "type": "string", + "description": "Kind of the referent. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "name": { + "type": "string", + "description": "Name of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#names" + }, + "uid": { + "type": "string", + "description": "UID of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#uids" + }, + "controller": { + "type": "boolean", + "description": "If true, this reference points to the managing controller." + }, + "blockOwnerDeletion": { + "type": "boolean", + "description": "If true, AND if the owner has the \"foregroundDeletion\" finalizer, then the owner cannot be deleted from the key-value store until this reference is removed. Defaults to false. To set this field, a user needs \"delete\" permission of the owner, otherwise 422 (Unprocessable Entity) will be returned." + } + } + }, + "v1.Initializers": { + "id": "v1.Initializers", + "description": "Initializers tracks the progress of initialization.", + "required": [ + "pending" + ], + "properties": { + "pending": { + "type": "array", + "items": { + "$ref": "v1.Initializer" + }, + "description": "Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients." + }, + "result": { + "$ref": "v1.Status", + "description": "If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion." + } + } + }, + "v1.Initializer": { + "id": "v1.Initializer", + "description": "Initializer is information about an initializer that has not yet completed.", + "required": [ + "name" + ], + "properties": { + "name": { + "type": "string", + "description": "name of the process that is responsible for initializing this object." + } + } + }, + "v1.Status": { + "id": "v1.Status", + "description": "Status is a return value for calls that don't return other objects.", + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "metadata": { + "$ref": "v1.ListMeta", + "description": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "status": { + "type": "string", + "description": "Status of the operation. One of: \"Success\" or \"Failure\". More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status" + }, + "message": { + "type": "string", + "description": "A human-readable description of the status of this operation." + }, + "reason": { + "type": "string", + "description": "A machine-readable description of why this operation is in the \"Failure\" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it." + }, + "details": { + "$ref": "v1.StatusDetails", + "description": "Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type." + }, + "code": { + "type": "integer", + "format": "int32", + "description": "Suggested HTTP return code for this status, 0 if not set." + } + } + }, + "v1.StatusDetails": { + "id": "v1.StatusDetails", + "description": "StatusDetails is a set of additional properties that MAY be set by the server to provide additional information about a response. The Reason field of a Status object defines what attributes will be set. Clients must ignore fields that do not match the defined type of each attribute, and should assume that any attribute may be empty, invalid, or under defined.", + "properties": { + "name": { + "type": "string", + "description": "The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described)." + }, + "group": { + "type": "string", + "description": "The group attribute of the resource associated with the status StatusReason." + }, + "kind": { + "type": "string", + "description": "The kind attribute of the resource associated with the status StatusReason. On some operations may differ from the requested resource Kind. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "uid": { + "type": "string", + "description": "UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids" + }, + "causes": { + "type": "array", + "items": { + "$ref": "v1.StatusCause" + }, + "description": "The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes." + }, + "retryAfterSeconds": { + "type": "integer", + "format": "int32", + "description": "If specified, the time in seconds before the operation should be retried." + } + } + }, + "v1.StatusCause": { + "id": "v1.StatusCause", + "description": "StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered.", + "properties": { + "reason": { + "type": "string", + "description": "A machine-readable description of the cause of the error. If this value is empty there is no information available." + }, + "message": { + "type": "string", + "description": "A human-readable description of the cause of the error. This field may be presented as-is to a reader." + }, + "field": { + "type": "string", + "description": "The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional.\n\nExamples:\n \"name\" - the field \"name\" on the current resource\n \"items[0].name\" - the field \"name\" on the first array entry in \"items\"" + } + } + }, + "v1.NetworkPolicySpec": { + "id": "v1.NetworkPolicySpec", + "description": "NetworkPolicySpec provides the specification of a NetworkPolicy", + "required": [ + "podSelector" + ], + "properties": { + "podSelector": { + "$ref": "v1.LabelSelector", + "description": "Selects the pods to which this NetworkPolicy object applies. The array of ingress rules is applied to any pods selected by this field. Multiple network policies can select the same set of pods. In this case, the ingress rules for each are combined additively. This field is NOT optional and follows standard label selector semantics. An empty podSelector matches all pods in this namespace." + }, + "ingress": { + "type": "array", + "items": { + "$ref": "v1.NetworkPolicyIngressRule" + }, + "description": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod (and cluster policy otherwise allows the traffic), OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default)" + } + } + }, + "v1.LabelSelector": { + "id": "v1.LabelSelector", + "description": "A label selector is a label query over a set of resources. The result of matchLabels and matchExpressions are ANDed. An empty label selector matches all objects. A null label selector matches no objects.", + "properties": { + "matchLabels": { + "type": "object", + "description": "matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is \"key\", the operator is \"In\", and the values array contains only \"value\". The requirements are ANDed." + }, + "matchExpressions": { + "type": "array", + "items": { + "$ref": "v1.LabelSelectorRequirement" + }, + "description": "matchExpressions is a list of label selector requirements. The requirements are ANDed." + } + } + }, + "v1.LabelSelectorRequirement": { + "id": "v1.LabelSelectorRequirement", + "description": "A label selector requirement is a selector that contains values, a key, and an operator that relates the key and values.", + "required": [ + "key", + "operator" + ], + "properties": { + "key": { + "type": "string", + "description": "key is the label key that the selector applies to." + }, + "operator": { + "type": "string", + "description": "operator represents a key's relationship to a set of values. Valid operators ard In, NotIn, Exists and DoesNotExist." + }, + "values": { + "type": "array", + "items": { + "type": "string" + }, + "description": "values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch." + } + } + }, + "v1.NetworkPolicyIngressRule": { + "id": "v1.NetworkPolicyIngressRule", + "description": "NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from.", + "properties": { + "ports": { + "type": "array", + "items": { + "$ref": "v1.NetworkPolicyPort" + }, + "description": "List of ports which should be made accessible on the pods selected for this rule. Each item in this list is combined using a logical OR. If this field is empty or missing, this rule matches all ports (traffic not restricted by port). If this field is present and contains at least one item, then this rule allows traffic only if the traffic matches at least one port in the list." + }, + "from": { + "type": "array", + "items": { + "$ref": "v1.NetworkPolicyPeer" + }, + "description": "List of sources which should be able to access the pods selected for this rule. Items in this list are combined using a logical OR operation. If this field is empty or missing, this rule matches all sources (traffic not restricted by source). If this field is present and contains at least on item, this rule allows traffic only if the traffic matches at least one item in the from list." + } + } + }, + "v1.NetworkPolicyPort": { + "id": "v1.NetworkPolicyPort", + "description": "NetworkPolicyPort describes a port to allow traffic on", + "properties": { + "protocol": { + "$ref": "v1.Protocol", + "description": "The protocol (TCP or UDP) which traffic must match. If not specified, this field defaults to TCP." + }, + "port": { + "type": "string", + "description": "The port on the given protocol. This can either be a numerical or named port on a pod. If this field is not provided, this matches all port names and numbers." + } + } + }, + "v1.Protocol": { + "id": "v1.Protocol", + "properties": {} + }, + "v1.NetworkPolicyPeer": { + "id": "v1.NetworkPolicyPeer", + "description": "NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields must be specified.", + "properties": { + "podSelector": { + "$ref": "v1.LabelSelector", + "description": "This is a label selector which selects Pods in this namespace. This field follows standard label selector semantics. If present but empty, this selector selects all pods in this namespace." + }, + "namespaceSelector": { + "$ref": "v1.LabelSelector", + "description": "Selects Namespaces using cluster scoped-labels. This matches all pods in all namespaces selected by this label selector. This field follows standard label selector semantics. If present but empty, this selector selects all namespaces." + } + } + }, + "v1.WatchEvent": { + "id": "v1.WatchEvent", + "required": [ + "type", + "object" + ], + "properties": { + "type": { + "type": "string" + }, + "object": { + "type": "string" + } + } + }, + "v1.Patch": { + "id": "v1.Patch", + "description": "Patch is provided to give a concrete name and type to the Kubernetes PATCH request body.", + "properties": {} + }, + "v1.DeleteOptions": { + "id": "v1.DeleteOptions", + "description": "DeleteOptions may be provided when deleting an API object.", + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "gracePeriodSeconds": { + "type": "integer", + "format": "int64", + "description": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately." + }, + "preconditions": { + "$ref": "v1.Preconditions", + "description": "Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned." + }, + "orphanDependents": { + "type": "boolean", + "description": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both." + }, + "propagationPolicy": { + "$ref": "v1.DeletionPropagation", + "description": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy." + } + } + }, + "v1.Preconditions": { + "id": "v1.Preconditions", + "description": "Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.", + "properties": { + "uid": { + "$ref": "types.UID", + "description": "Specifies the target UID." + } + } + }, + "types.UID": { + "id": "types.UID", + "properties": {} + }, + "v1.DeletionPropagation": { + "id": "v1.DeletionPropagation", + "properties": {} + }, + "v1.APIResourceList": { + "id": "v1.APIResourceList", + "description": "APIResourceList is a list of APIResource, it is used to expose the name of the resources supported in a specific group and version, and if the resource is namespaced.", + "required": [ + "groupVersion", + "resources" + ], + "properties": { + "kind": { + "type": "string", + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + }, + "apiVersion": { + "type": "string", + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources" + }, + "groupVersion": { + "type": "string", + "description": "groupVersion is the group and version this APIResourceList is for." + }, + "resources": { + "type": "array", + "items": { + "$ref": "v1.APIResource" + }, + "description": "resources contains the name of the resources and if they are namespaced." + } + } + }, + "v1.APIResource": { + "id": "v1.APIResource", + "description": "APIResource specifies the name of a resource and whether it is namespaced.", + "required": [ + "name", + "singularName", + "namespaced", + "kind", + "verbs" + ], + "properties": { + "name": { + "type": "string", + "description": "name is the plural name of the resource." + }, + "singularName": { + "type": "string", + "description": "singularName is the singular name of the resource. This allows clients to handle plural and singular opaquely. The singularName is more correct for reporting status on a single item and both singular and plural are allowed from the kubectl CLI interface." + }, + "namespaced": { + "type": "boolean", + "description": "namespaced indicates if a resource is namespaced or not." + }, + "kind": { + "type": "string", + "description": "kind is the kind for the resource (e.g. 'Foo' is the kind for a resource 'foo')" + }, + "verbs": { + "type": "array", + "items": { + "type": "string" + }, + "description": "verbs is a list of supported kube verbs (this includes get, list, watch, create, update, patch, delete, deletecollection, and proxy)" + }, + "shortNames": { + "type": "array", + "items": { + "type": "string" + }, + "description": "shortNames is a list of suggested short names of the resource." + } + } + } + } + } diff --git a/api/swagger-spec/resourceListing.json b/api/swagger-spec/resourceListing.json index ea421536924d7..6429c17b445da 100644 --- a/api/swagger-spec/resourceListing.json +++ b/api/swagger-spec/resourceListing.json @@ -85,6 +85,14 @@ "path": "/apis/extensions", "description": "get information of a group" }, + { + "path": "/apis/networking.k8s.io/v1", + "description": "API at /apis/networking.k8s.io/v1" + }, + { + "path": "/apis/networking.k8s.io", + "description": "get information of a group" + }, { "path": "/apis/policy/v1beta1", "description": "API at /apis/policy/v1beta1" @@ -132,6 +140,14 @@ { "path": "/apis/apps", "description": "get information of a group" + }, + { + "path": "/apis/admissionregistration.k8s.io/v1alpha1", + "description": "API at /apis/admissionregistration.k8s.io/v1alpha1" + }, + { + "path": "/apis/admissionregistration.k8s.io", + "description": "get information of a group" } ], "apiVersion": "", diff --git a/api/swagger-spec/settings.k8s.io_v1alpha1.json b/api/swagger-spec/settings.k8s.io_v1alpha1.json index 6783c338ca0d3..3c206dc2ecbdc 100644 --- a/api/swagger-spec/settings.k8s.io_v1alpha1.json +++ b/api/swagger-spec/settings.k8s.io_v1alpha1.json @@ -1580,6 +1580,10 @@ "medium": { "type": "string", "description": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir" + }, + "sizeLimit": { + "type": "string", + "description": "Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir" } } }, diff --git a/api/swagger-spec/v1.json b/api/swagger-spec/v1.json index d342edd5831d0..dbf74004c2e1a 100644 --- a/api/swagger-spec/v1.json +++ b/api/swagger-spec/v1.json @@ -3760,85 +3760,6 @@ "consumes": [ "*/*" ] - }, - { - "type": "v1.Status", - "method": "DELETE", - "summary": "delete collection of Namespace", - "nickname": "deletecollectionNamespace", - "parameters": [ - { - "type": "string", - "paramType": "query", - "name": "pretty", - "description": "If 'true', then the output is pretty printed.", - "required": false, - "allowMultiple": false - }, - { - "type": "string", - "paramType": "query", - "name": "labelSelector", - "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - "required": false, - "allowMultiple": false - }, - { - "type": "string", - "paramType": "query", - "name": "fieldSelector", - "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "required": false, - "allowMultiple": false - }, - { - "type": "boolean", - "paramType": "query", - "name": "includeUninitialized", - "description": "If true, partially initialized resources are included in the response.", - "required": false, - "allowMultiple": false - }, - { - "type": "boolean", - "paramType": "query", - "name": "watch", - "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - "required": false, - "allowMultiple": false - }, - { - "type": "string", - "paramType": "query", - "name": "resourceVersion", - "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", - "required": false, - "allowMultiple": false - }, - { - "type": "integer", - "paramType": "query", - "name": "timeoutSeconds", - "description": "Timeout for the list/watch call.", - "required": false, - "allowMultiple": false - } - ], - "responseMessages": [ - { - "code": 200, - "message": "OK", - "responseModel": "v1.Status" - } - ], - "produces": [ - "application/json", - "application/yaml", - "application/vnd.kubernetes.protobuf" - ], - "consumes": [ - "*/*" - ] } ] }, @@ -19878,6 +19799,10 @@ "medium": { "type": "string", "description": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir" + }, + "sizeLimit": { + "type": "string", + "description": "Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir" } } }, diff --git a/build/build-image/Dockerfile b/build/build-image/Dockerfile index 57b4300508cd7..e37a241de862f 100644 --- a/build/build-image/Dockerfile +++ b/build/build-image/Dockerfile @@ -19,7 +19,7 @@ FROM gcr.io/google_containers/kube-cross:KUBE_BUILD_IMAGE_CROSS_TAG RUN touch /kube-build-image # To run as non-root we sometimes need to rebuild go stdlib packages. -RUN chmod -R a+rwx /usr/local/go/pkg ${K8S_PATCHED_GOROOT}/pkg +RUN chmod -R a+rwx /usr/local/go/pkg # For running integration tests /var/run/kubernetes is required # and should be writable by user diff --git a/build/build-image/cross/Dockerfile b/build/build-image/cross/Dockerfile index d2887e9b555fc..d3ec13ebf7e4d 100644 --- a/build/build-image/cross/Dockerfile +++ b/build/build-image/cross/Dockerfile @@ -15,7 +15,7 @@ # This file creates a standard build environment for building cross # platform go binary for the architecture kubernetes cares about. -FROM golang:1.8.1 +FROM golang:1.8.3 ENV GOARM 7 ENV KUBE_DYNAMIC_CROSSPLATFORMS \ @@ -77,22 +77,3 @@ RUN export ETCD_VERSION=v3.0.17; \ && cd /usr/local/src/etcd \ && curl -fsSL https://github.com/coreos/etcd/releases/download/${ETCD_VERSION}/etcd-${ETCD_VERSION}-linux-amd64.tar.gz | tar -xz \ && ln -s ../src/etcd/etcd-${ETCD_VERSION}-linux-amd64/etcd /usr/local/bin/ - - -# There is a significant performance regression in Go 1.8 comparing to Go 1.7. -# Until this is solved in Go itself, we are patching 1.8.1 version of Go to -# reduce the impact of this regression - for more detailed discussion see: -# https://github.com/kubernetes/kubernetes/issues/45216 -# -# TODO: Once this issue is fixed in Go itself, we can get rid of the code below. -ENV K8S_PATCHED_GOLANG_VERSION=1.8.1 \ - K8S_PATCHED_GOROOT=/usr/local/go_k8s_patched -RUN mkdir -p ${K8S_PATCHED_GOROOT} \ - && curl -sSL https://github.com/golang/go/archive/go${K8S_PATCHED_GOLANG_VERSION}.tar.gz | tar -xz -C ${K8S_PATCHED_GOROOT} --strip-components=1 - -COPY go_181_performance_fix.patch ${K8S_PATCHED_GOROOT}/ -RUN cd ${K8S_PATCHED_GOROOT} \ - && patch -p1 < go_181_performance_fix.patch \ - && cd src \ - && GOROOT_FINAL=${K8S_PATCHED_GOROOT} GOROOT_BOOTSTRAP=/usr/local/go ./make.bash \ - && for platform in ${KUBE_CROSSPLATFORMS}; do GOOS=${platform%/*} GOARCH=${platform##*/} GOROOT=${K8S_PATCHED_GOROOT} go install std; done diff --git a/build/build-image/cross/VERSION b/build/build-image/cross/VERSION index de541432f1719..490e779dc9bf9 100644 --- a/build/build-image/cross/VERSION +++ b/build/build-image/cross/VERSION @@ -1 +1 @@ -v1.8.1-2 +v1.8.3-1 diff --git a/build/build-image/cross/go_181_performance_fix.patch b/build/build-image/cross/go_181_performance_fix.patch deleted file mode 100644 index 64f942937c6fb..0000000000000 --- a/build/build-image/cross/go_181_performance_fix.patch +++ /dev/null @@ -1,24 +0,0 @@ -diff --git a/src/net/http/h2_bundle.go b/src/net/http/h2_bundle.go -index 4536b2ff5d..84e78534a9 100644 ---- a/src/net/http/h2_bundle.go -+++ b/src/net/http/h2_bundle.go -@@ -3536,9 +3536,17 @@ func (sc *http2serverConn) serve() { - sc.idleTimerCh = sc.idleTimer.C - } - -- var gracefulShutdownCh <-chan struct{} -+ var gracefulShutdownCh chan struct{} - if sc.hs != nil { -- gracefulShutdownCh = http2h1ServerShutdownChan(sc.hs) -+ ch := http2h1ServerShutdownChan(sc.hs) -+ gracefulShutdownCh = make(chan struct{}) -+ go func() { -+ select { -+ case <-sc.doneServing: -+ case <-ch: -+ close(gracefulShutdownCh) -+ } -+ }() - } - - go sc.readFrames() diff --git a/build/cni/Makefile b/build/cni/Makefile index f5140ee989b20..73b2c06ccb27a 100644 --- a/build/cni/Makefile +++ b/build/cni/Makefile @@ -22,7 +22,7 @@ CNI_RELEASE?=0799f5732f2a11b329d9e3d51b9c8f2e3759f2ff CNI_TARBALL=cni-$(ARCH)-$(CNI_RELEASE).tar.gz CUR_DIR=$(shell pwd) OUTPUT_DIR=$(CUR_DIR)/output -GOLANG_VERSION=1.7.5 +GOLANG_VERSION=1.7.6 all: build diff --git a/build/common.sh b/build/common.sh index 8db8983abc43e..9ec643b1d98e8 100755 --- a/build/common.sh +++ b/build/common.sh @@ -558,6 +558,9 @@ function kube::build::run_build_command_ex() { --env "KUBE_FASTBUILD=${KUBE_FASTBUILD:-false}" --env "KUBE_BUILDER_OS=${OSTYPE:-notdetected}" --env "KUBE_VERBOSE=${KUBE_VERBOSE}" + --env "GOFLAGS=${GOFLAGS:-}" + --env "GOLDFLAGS=${GOLDFLAGS:-}" + --env "GOGCFLAGS=${GOGCFLAGS:-}" ) # If we have stdin we can run interactive. This allows things like 'shell.sh' diff --git a/build/root/.bazelrc b/build/root/.bazelrc index ab5db1d2dc3a0..8e989c90f103e 100644 --- a/build/root/.bazelrc +++ b/build/root/.bazelrc @@ -4,3 +4,6 @@ test --test_output=errors # Include git version info build --workspace_status_command hack/print-workspace-status.sh + +# Make /tmp hermetic +build --sandbox_tmpfs_path=/tmp diff --git a/build/root/Makefile b/build/root/Makefile index 80efef199cd8f..ea5eec81dd67f 100644 --- a/build/root/Makefile +++ b/build/root/Makefile @@ -153,7 +153,7 @@ define CHECK_TEST_HELP_INFO # Example: # make check # make test -# make check WHAT=pkg/kubelet GOFLAGS=-v +# make check WHAT=./pkg/kubelet GOFLAGS=-v endef .PHONY: check test ifeq ($(PRINT_HELP),y) @@ -333,7 +333,7 @@ define VET_HELP_INFO # # Example: # make vet -# make vet WHAT=pkg/kubelet +# make vet WHAT=./pkg/kubelet endef .PHONY: vet ifeq ($(PRINT_HELP),y) diff --git a/build/root/WORKSPACE b/build/root/WORKSPACE index fe0c36382ce3e..e01bbb336acb3 100644 --- a/build/root/WORKSPACE +++ b/build/root/WORKSPACE @@ -1,8 +1,8 @@ http_archive( name = "io_bazel_rules_go", - sha256 = "a1cae429e9d591017421150e3173478c46c693bc594322c7fa7e6cb5f672ef59", - strip_prefix = "rules_go-805fd1566500997379806373feb05e138a4dfe28", - urls = ["https://github.com/bazelbuild/rules_go/archive/805fd1566500997379806373feb05e138a4dfe28.tar.gz"], + sha256 = "64294fd0e74d2aafa03ec3a1f2f9c167e27d17c9a5cf393e8bf79e43258de73d", + strip_prefix = "rules_go-a9df110cf04e167b33f10473c7e904d780d921e6", + urls = ["https://github.com/bazelbuild/rules_go/archive/a9df110cf04e167b33f10473c7e904d780d921e6.tar.gz"], ) http_archive( @@ -33,7 +33,7 @@ load("@io_bazel_rules_go//go:def.bzl", "go_repositories") load("@io_bazel_rules_docker//docker:docker.bzl", "docker_repositories") go_repositories( - go_version = "1.8.1", + go_version = "1.8.3", ) docker_repositories() diff --git a/cluster/addons/fluentd-elasticsearch/es-image/Dockerfile b/cluster/addons/fluentd-elasticsearch/es-image/Dockerfile index 972cae297dcd1..553ccfdc6c1f0 100644 --- a/cluster/addons/fluentd-elasticsearch/es-image/Dockerfile +++ b/cluster/addons/fluentd-elasticsearch/es-image/Dockerfile @@ -19,7 +19,8 @@ FROM java:openjdk-8-jre-alpine -ENV ELASTICSEARCH_VERSION 2.4.1 +ENV DEBIAN_FRONTEND noninteractive +ENV ELASTICSEARCH_VERSION 5.4.0 RUN apk update && \ apk --no-cache add \ @@ -33,7 +34,7 @@ RUN apk update && \ RUN set -x \ && cd / \ && mkdir /elasticsearch \ - && curl -O https://download.elastic.co/elasticsearch/release/org/elasticsearch/distribution/tar/elasticsearch/$ELASTICSEARCH_VERSION/elasticsearch-$ELASTICSEARCH_VERSION.tar.gz \ + && curl -O https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-$ELASTICSEARCH_VERSION.tar.gz \ && tar xf elasticsearch-$ELASTICSEARCH_VERSION.tar.gz -C /elasticsearch --strip-components=1 \ && rm elasticsearch-$ELASTICSEARCH_VERSION.tar.gz diff --git a/cluster/addons/fluentd-elasticsearch/es-image/Makefile b/cluster/addons/fluentd-elasticsearch/es-image/Makefile index 0fcb496788ba5..024552bf503a3 100755 --- a/cluster/addons/fluentd-elasticsearch/es-image/Makefile +++ b/cluster/addons/fluentd-elasticsearch/es-image/Makefile @@ -16,7 +16,7 @@ # The current value of the tag to be used for building and # pushing an image to gcr.io -TAG = v2.4.1-3 +TAG = v5.4.0 build: elasticsearch_logging_discovery docker build --pull -t gcr.io/google_containers/elasticsearch:$(TAG) . diff --git a/cluster/addons/fluentd-elasticsearch/es-image/config/elasticsearch.yml b/cluster/addons/fluentd-elasticsearch/es-image/config/elasticsearch.yml index a2ea62e9b83c2..f4ffee74a7f31 100644 --- a/cluster/addons/fluentd-elasticsearch/es-image/config/elasticsearch.yml +++ b/cluster/addons/fluentd-elasticsearch/es-image/config/elasticsearch.yml @@ -12,4 +12,3 @@ path.data: /data network.host: 0.0.0.0 discovery.zen.minimum_master_nodes: ${MINIMUM_MASTER_NODES} -discovery.zen.ping.multicast.enabled: false diff --git a/cluster/addons/fluentd-elasticsearch/es-image/config/log4j2.properties b/cluster/addons/fluentd-elasticsearch/es-image/config/log4j2.properties new file mode 100644 index 0000000000000..23b0fa33c1633 --- /dev/null +++ b/cluster/addons/fluentd-elasticsearch/es-image/config/log4j2.properties @@ -0,0 +1,12 @@ +# you can override this using by setting a system property, for example -Des.logger.level=DEBUG +status = error + +appender.console.type = Console +appender.console.name = console +appender.console.layout.type = PatternLayout +appender.console.layout.pattern = [%d{ISO8601}][%-5p][%-25c{1.}] %marker%m%n + +rootLogger.level = info +rootLogger.appenderRef.console.ref = console +rootLogger.action = debug +rootLogger.com.amazonaws = warn diff --git a/cluster/addons/fluentd-elasticsearch/es-image/config/logging.yml b/cluster/addons/fluentd-elasticsearch/es-image/config/logging.yml deleted file mode 100644 index 89c1a60ce447a..0000000000000 --- a/cluster/addons/fluentd-elasticsearch/es-image/config/logging.yml +++ /dev/null @@ -1,15 +0,0 @@ -# you can override this using by setting a system property, for example -Des.logger.level=DEBUG -es.logger.level: INFO -rootLogger: ${es.logger.level}, console -logger: - # log action execution errors for easier debugging - action: DEBUG - # reduce the logging for aws, too much is logged under the default INFO - com.amazonaws: WARN - -appender: - console: - type: console - layout: - type: consolePattern - conversionPattern: "[%d{ISO8601}][%-5p][%-25c] %m%n" \ No newline at end of file diff --git a/cluster/addons/fluentd-elasticsearch/es-image/run.sh b/cluster/addons/fluentd-elasticsearch/es-image/run.sh index 148d4ed1f9ddd..f2e64129e0483 100755 --- a/cluster/addons/fluentd-elasticsearch/es-image/run.sh +++ b/cluster/addons/fluentd-elasticsearch/es-image/run.sh @@ -14,6 +14,8 @@ # See the License for the specific language governing permissions and # limitations under the License. +sysctl -w vm.max_map_count=262144 + export NODE_NAME=${NODE_NAME:-${HOSTNAME}} export NODE_MASTER=${NODE_MASTER:-true} export NODE_DATA=${NODE_DATA:-true} @@ -25,4 +27,4 @@ export MINIMUM_MASTER_NODES=${MINIMUM_MASTER_NODES:-2} chown -R elasticsearch:elasticsearch /data -exec gosu elasticsearch /elasticsearch/bin/elasticsearch +exec gosu elasticsearch sh /elasticsearch/bin/elasticsearch diff --git a/cluster/addons/fluentd-elasticsearch/fluentd-es-ds.yaml b/cluster/addons/fluentd-elasticsearch/fluentd-es-ds.yaml index 211291e38ad32..769d384286adf 100644 --- a/cluster/addons/fluentd-elasticsearch/fluentd-es-ds.yaml +++ b/cluster/addons/fluentd-elasticsearch/fluentd-es-ds.yaml @@ -23,7 +23,7 @@ spec: spec: containers: - name: fluentd-es - image: gcr.io/google_containers/fluentd-elasticsearch:1.22 + image: gcr.io/google_containers/fluentd-elasticsearch:1.23 command: - '/bin/sh' - '-c' diff --git a/cluster/addons/fluentd-elasticsearch/fluentd-es-image/Makefile b/cluster/addons/fluentd-elasticsearch/fluentd-es-image/Makefile index cc09d2bcc39e0..9747b5c504d9b 100644 --- a/cluster/addons/fluentd-elasticsearch/fluentd-es-image/Makefile +++ b/cluster/addons/fluentd-elasticsearch/fluentd-es-image/Makefile @@ -16,7 +16,7 @@ PREFIX = gcr.io/google_containers IMAGE = fluentd-elasticsearch -TAG = 1.22 +TAG = 1.23 build: docker build --pull -t $(PREFIX)/$(IMAGE):$(TAG) . diff --git a/cluster/addons/fluentd-elasticsearch/fluentd-es-image/build.sh b/cluster/addons/fluentd-elasticsearch/fluentd-es-image/build.sh index 004618e86c5a6..d0d9bbe6517a8 100755 --- a/cluster/addons/fluentd-elasticsearch/fluentd-es-image/build.sh +++ b/cluster/addons/fluentd-elasticsearch/fluentd-es-image/build.sh @@ -30,8 +30,8 @@ sed -i -e "s/USER=td-agent/USER=root/" -e "s/GROUP=td-agent/GROUP=root/" /etc/in # Install the Elasticsearch Fluentd plug-in. # http://docs.fluentd.org/articles/plugin-management -td-agent-gem install --no-document fluent-plugin-kubernetes_metadata_filter -v 0.24.0 -td-agent-gem install --no-document fluent-plugin-elasticsearch -v 1.5.0 +td-agent-gem install --no-document fluent-plugin-kubernetes_metadata_filter -v 0.27.0 +td-agent-gem install --no-document fluent-plugin-elasticsearch -v 1.9.5 # Remove docs and postgres references rm -rf /opt/td-agent/embedded/share/doc \ diff --git a/cluster/addons/fluentd-elasticsearch/kibana-image/Dockerfile b/cluster/addons/fluentd-elasticsearch/kibana-image/Dockerfile index 3a5ccd7fc0edc..9a82060ee5169 100644 --- a/cluster/addons/fluentd-elasticsearch/kibana-image/Dockerfile +++ b/cluster/addons/fluentd-elasticsearch/kibana-image/Dockerfile @@ -19,7 +19,7 @@ FROM gcr.io/google_containers/ubuntu-slim:0.6 ENV DEBIAN_FRONTEND noninteractive -ENV KIBANA_VERSION 4.6.1 +ENV KIBANA_VERSION 5.4.0 RUN apt-get update \ && apt-get install -y curl \ @@ -28,7 +28,7 @@ RUN apt-get update \ RUN set -x \ && cd / \ && mkdir /kibana \ - && curl -O https://download.elastic.co/kibana/kibana/kibana-$KIBANA_VERSION-linux-x86_64.tar.gz \ + && curl -O https://artifacts.elastic.co/downloads/kibana/kibana-$KIBANA_VERSION-linux-x86_64.tar.gz \ && tar xf kibana-$KIBANA_VERSION-linux-x86_64.tar.gz -C /kibana --strip-components=1 \ && rm kibana-$KIBANA_VERSION-linux-x86_64.tar.gz diff --git a/cluster/addons/fluentd-elasticsearch/kibana-image/Makefile b/cluster/addons/fluentd-elasticsearch/kibana-image/Makefile index fcdd99278c62b..cdd1fc85e2019 100755 --- a/cluster/addons/fluentd-elasticsearch/kibana-image/Makefile +++ b/cluster/addons/fluentd-elasticsearch/kibana-image/Makefile @@ -14,7 +14,7 @@ .PHONY: build push -TAG = v4.6.1-1 +TAG = v5.4.0 PREFIX = gcr.io/google_containers build: diff --git a/cluster/addons/fluentd-elasticsearch/kibana-image/run.sh b/cluster/addons/fluentd-elasticsearch/kibana-image/run.sh index d8b30ed309b35..2662ca92683e0 100755 --- a/cluster/addons/fluentd-elasticsearch/kibana-image/run.sh +++ b/cluster/addons/fluentd-elasticsearch/kibana-image/run.sh @@ -20,5 +20,7 @@ echo ELASTICSEARCH_URL=${ELASTICSEARCH_URL} export KIBANA_BASE_URL=${KIBANA_BASE_URL:-"''"} echo "server.basePath: ${KIBANA_BASE_URL}" echo "server.basePath: ${KIBANA_BASE_URL}" >> /kibana/config/kibana.yml +echo "server.host: ${KIBANA_HOST}" +echo "server.host: ${KIBANA_HOST}" >> /kibana/config/kibana.yml /kibana/bin/kibana -e ${ELASTICSEARCH_URL} diff --git a/cluster/addons/fluentd-gcp/fluentd-gcp-ds.yaml b/cluster/addons/fluentd-gcp/fluentd-gcp-ds.yaml index cccdad8fae4f6..737f74bc00980 100644 --- a/cluster/addons/fluentd-gcp/fluentd-gcp-ds.yaml +++ b/cluster/addons/fluentd-gcp/fluentd-gcp-ds.yaml @@ -26,7 +26,7 @@ spec: dnsPolicy: Default containers: - name: fluentd-gcp - image: gcr.io/google-containers/fluentd-gcp:2.0.2 + image: gcr.io/google-containers/fluentd-gcp:2.0.4 # If fluentd consumes its own logs, the following situation may happen: # fluentd fails to send a chunk to the server => writes it to the log => # tries to send this message to the server => fails to send a chunk and so on. diff --git a/cluster/addons/ip-masq-agent/ip-masq-agent.yaml b/cluster/addons/ip-masq-agent/ip-masq-agent.yaml index cc24c28d2d562..5fafe89be709b 100644 --- a/cluster/addons/ip-masq-agent/ip-masq-agent.yaml +++ b/cluster/addons/ip-masq-agent/ip-masq-agent.yaml @@ -20,7 +20,7 @@ spec: hostNetwork: true containers: - name: ip-masq-agent - image: gcr.io/google-containers/ip-masq-agent-amd64:v2.0.0 + image: gcr.io/google-containers/ip-masq-agent-amd64:v2.0.1 securityContext: privileged: true volumeMounts: diff --git a/cluster/addons/node-problem-detector/npd.yaml b/cluster/addons/node-problem-detector/npd.yaml index b84ed07a4e17b..5afef9d40b20c 100644 --- a/cluster/addons/node-problem-detector/npd.yaml +++ b/cluster/addons/node-problem-detector/npd.yaml @@ -77,3 +77,6 @@ spec: hostPath: path: /etc/localtime serviceAccountName: node-problem-detector + tolerations: + - operator: "Exists" + effect: "NoExecute" diff --git a/cluster/centos/build.sh b/cluster/centos/build.sh index 18bbe6f5aad9b..5d314371a8ef9 100755 --- a/cluster/centos/build.sh +++ b/cluster/centos/build.sh @@ -69,7 +69,7 @@ function unpack-releases() { cp ${RELEASES_DIR}/flanneld ${BINARY_DIR}/node/bin fi - # ectd + # etcd if [[ -f ${RELEASES_DIR}/etcd.tar.gz ]] ; then tar xzf ${RELEASES_DIR}/etcd.tar.gz -C ${RELEASES_DIR} ETCD="etcd-v${ETCD_VERSION}-linux-amd64" diff --git a/cluster/gce/config-default.sh b/cluster/gce/config-default.sh index 5d3f74de52061..f5470c647fad5 100755 --- a/cluster/gce/config-default.sh +++ b/cluster/gce/config-default.sh @@ -234,6 +234,9 @@ OPENCONTRAIL_PUBLIC_SUBNET="${OPENCONTRAIL_PUBLIC_SUBNET:-10.1.0.0/16}" # Network Policy plugin specific settings. NETWORK_POLICY_PROVIDER="${NETWORK_POLICY_PROVIDER:-none}" # calico +# Should the kubelet configure egress masquerade (old way) or let a daemonset do it? +NON_MASQUERADE_CIDR="0.0.0.0/0" + # How should the kubelet configure hairpin mode? HAIRPIN_MODE="${HAIRPIN_MODE:-promiscuous-bridge}" # promiscuous-bridge, hairpin-veth, none # Optional: if set to true, kube-up will configure the cluster to run e2e tests. diff --git a/cluster/gce/container-linux/configure-helper.sh b/cluster/gce/container-linux/configure-helper.sh index 7924fd3cff1f6..52c8a029a13a2 100755 --- a/cluster/gce/container-linux/configure-helper.sh +++ b/cluster/gce/container-linux/configure-helper.sh @@ -810,6 +810,7 @@ function start-kube-apiserver { params+=" --tls-cert-file=/etc/srv/kubernetes/server.cert" params+=" --tls-private-key-file=/etc/srv/kubernetes/server.key" params+=" --token-auth-file=/etc/srv/kubernetes/known_tokens.csv" + params+=" --enable-aggregator-routing=true" if [[ -n "${KUBE_PASSWORD:-}" && -n "${KUBE_USER:-}" ]]; then params+=" --basic-auth-file=/etc/srv/kubernetes/basic_auth.csv" fi diff --git a/cluster/gce/gci/configure-helper.sh b/cluster/gce/gci/configure-helper.sh index 24d1db1984eea..b4e5becf3bdf8 100644 --- a/cluster/gce/gci/configure-helper.sh +++ b/cluster/gce/gci/configure-helper.sh @@ -1015,6 +1015,7 @@ function start-kube-apiserver { params+=" --secure-port=443" params+=" --tls-cert-file=${APISERVER_SERVER_CERT_PATH}" params+=" --tls-private-key-file=${APISERVER_SERVER_KEY_PATH}" + params+=" --enable-aggregator-routing=true" if [[ -e "${APISERVER_CLIENT_CERT_PATH}" ]] && [[ -e "${APISERVER_CLIENT_KEY_PATH}" ]]; then params+=" --kubelet-client-certificate=${APISERVER_CLIENT_CERT_PATH}" params+=" --kubelet-client-key=${APISERVER_CLIENT_KEY_PATH}" diff --git a/cluster/gce/util.sh b/cluster/gce/util.sh index 88f333dd62b98..05bcd9a736368 100755 --- a/cluster/gce/util.sh +++ b/cluster/gce/util.sh @@ -778,7 +778,7 @@ function create-subnetworks() { --network ${NETWORK} \ --region ${REGION} \ --range ${NODE_IP_RANGE} \ - --secondary-range "name=pods-default,range=${CLUSTER_IP_RANGE}" + --secondary-range "pods-default=${CLUSTER_IP_RANGE}" echo "Created subnetwork ${IP_ALIAS_SUBNETWORK}" else if ! echo ${subnet} | grep --quiet secondaryIpRanges ${subnet}; then diff --git a/cluster/gke/util.sh b/cluster/gke/util.sh index 98fe2335f97ed..df140bb06157b 100755 --- a/cluster/gke/util.sh +++ b/cluster/gke/util.sh @@ -197,6 +197,14 @@ function kube-up() { create_args+=("--cluster-ipv4-cidr=${CLUSTER_IP_RANGE}") fi + if [[ ! -z "${ENABLE_LEGACY_ABAC:-}" ]]; then + if [[ "${ENABLE_LEGACY_ABAC:-}" == "true" ]]; then + create_args+=("--enable-legacy-authorization") + else + create_args+=("--no-enable-legacy-authorization") + fi + fi + create_args+=( ${GKE_CREATE_FLAGS:-} ) # Bring up the cluster. diff --git a/cluster/images/etcd-version-monitor/Makefile b/cluster/images/etcd-version-monitor/Makefile index 1149f4a0ae16c..09fb29607dcef 100644 --- a/cluster/images/etcd-version-monitor/Makefile +++ b/cluster/images/etcd-version-monitor/Makefile @@ -15,10 +15,10 @@ # Build the etcd-version-monitor image # # Usage: -# [GOLANG_VERSION=1.8.1] [REGISTRY=gcr.io/google-containers] [TAG=test] make (build|push) +# [GOLANG_VERSION=1.8.3] [REGISTRY=gcr.io/google-containers] [TAG=test] make (build|push) # TODO(shyamjvs): Support architectures other than amd64 if needed. ARCH:=amd64 -GOLANG_VERSION?=1.8.1 +GOLANG_VERSION?=1.8.3 REGISTRY?=gcr.io/google-containers TAG?=0.1.0 IMAGE:=$(REGISTRY)/etcd-version-monitor:$(TAG) diff --git a/cluster/images/etcd/Makefile b/cluster/images/etcd/Makefile index 4da9fa9b453f2..2e9c5e71de749 100644 --- a/cluster/images/etcd/Makefile +++ b/cluster/images/etcd/Makefile @@ -30,7 +30,7 @@ TAGS?=2.2.1 2.3.7 3.0.17 REGISTRY_TAG?=3.0.17 ARCH?=amd64 REGISTRY?=gcr.io/google_containers -GOLANG_VERSION?=1.7.5 +GOLANG_VERSION?=1.7.6 GOARM=7 TEMP_DIR:=$(shell mktemp -d) diff --git a/cluster/log-dump.sh b/cluster/log-dump.sh index 3c11c1aebd7e5..941df1eb5b1d0 100755 --- a/cluster/log-dump.sh +++ b/cluster/log-dump.sh @@ -105,7 +105,7 @@ function copy-logs-from-node() { gce|gke|kubemark) # get-serial-port-output lets you ask for ports 1-4, but currently (11/21/2016) only port 1 contains useful information gcloud compute instances get-serial-port-output --project "${PROJECT}" --zone "${ZONE}" --port 1 "${node}" > "${dir}/serial-1.log" || true - gcloud compute copy-files --project "${PROJECT}" --zone "${ZONE}" "${node}:${scp_files}" "${dir}" > /dev/null || true + gcloud compute scp --recurse --project "${PROJECT}" --zone "${ZONE}" "${node}:${scp_files}" "${dir}" > /dev/null || true ;; aws) local ip=$(get_ssh_hostname "${node}") diff --git a/cluster/saltbase/salt/README.md b/cluster/saltbase/salt/README.md index 4fb805773e6f8..f4c24c202fb06 100644 --- a/cluster/saltbase/salt/README.md +++ b/cluster/saltbase/salt/README.md @@ -22,9 +22,6 @@ Config | GCE | Vagrant | AWS | Az [kubelet](kubelet/) | M n | M n | M n | M n [logrotate](logrotate/) | M n | n | M n | M n [supervisord](supervisor/) | M n | M n | M n | M n -[nginx](nginx/) | | | | M -[openvpn-client](openvpn-client/) | | | | n -[openvpn](openvpn/) | | | | M [base](base.sls) | M n | M n | M n | M n [kube-client-tools](kube-client-tools.sls) | M | M | M | M diff --git a/cluster/saltbase/salt/kubelet/default b/cluster/saltbase/salt/kubelet/default index abf8e4c7b362f..1f258139d94b9 100644 --- a/cluster/saltbase/salt/kubelet/default +++ b/cluster/saltbase/salt/kubelet/default @@ -15,13 +15,6 @@ {% set api_servers = "--api-servers=https://" + ips[0][0] -%} {% endif -%} -# TODO: remove nginx for other cloud providers. -{% if grains['cloud'] is defined and grains.cloud in [ 'aws', 'gce', 'vagrant', 'photon-controller', 'openstack', 'azure-legacy'] %} - {% set api_servers_with_port = api_servers -%} -{% else -%} - {% set api_servers_with_port = api_servers + ":6443" -%} -{% endif -%} - {% set master_kubelet_args = "" %} {% set debugging_handlers = "--enable-debugging-handlers=true" -%} @@ -32,10 +25,10 @@ # Unless given a specific directive, disable registration for the kubelet # running on the master. {% if grains.kubelet_api_servers is defined -%} - {% set api_servers_with_port = "--api-servers=https://" + grains.kubelet_api_servers -%} + {% set api_servers = "--api-servers=https://" + grains.kubelet_api_servers -%} {% set master_kubelet_args = master_kubelet_args + "--register-schedulable=false" -%} {% else -%} - {% set api_servers_with_port = "" -%} + {% set api_servers = "" -%} {% endif -%} # Disable the debugging handlers (/run and /exec) to prevent arbitrary @@ -113,7 +106,7 @@ {% if grains['roles'][0] == 'kubernetes-master' %} {% if grains.get('cbr-cidr') %} {% set pod_cidr = "--pod-cidr=" + grains['cbr-cidr'] %} - {% elif api_servers_with_port == '' and pillar.get('network_provider', '').lower() == 'kubenet' %} + {% elif api_servers == '' and pillar.get('network_provider', '').lower() == 'kubenet' %} # Kubelet standalone mode needs a PodCIDR since there is no controller-manager {% set pod_cidr = "--pod-cidr=10.76.0.0/16" %} {% endif -%} @@ -186,4 +179,4 @@ {% set kubelet_auth = "--anonymous-auth=false --authorization-mode=Webhook --client-ca-file=" + pillar.get('ca_cert_bundle_path', '/var/lib/kubelet/ca.crt') %} # test_args has to be kept at the end, so they'll overwrite any prior configuration -DAEMON_ARGS="{{daemon_args}} {{api_servers_with_port}} {{debugging_handlers}} {{hostname_override}} {{cloud_provider}} {{cloud_config}} {{config}} {{manifest_url}} --allow-privileged={{pillar['allow_privileged']}} {{log_level}} {{cluster_dns}} {{cluster_domain}} {{docker_root}} {{kubelet_root}} {{non_masquerade_cidr}} {{cgroup_root}} {{system_container}} {{pod_cidr}} {{ master_kubelet_args }} {{cpu_cfs_quota}} {{network_plugin}} {{kubelet_port}} {{ hairpin_mode }} {{enable_custom_metrics}} {{runtime_container}} {{kubelet_container}} {{node_labels}} {{eviction_hard}} {{kubelet_auth}} {{feature_gates}} {{test_args}}" +DAEMON_ARGS="{{daemon_args}} {{api_servers}} {{debugging_handlers}} {{hostname_override}} {{cloud_provider}} {{cloud_config}} {{config}} {{manifest_url}} --allow-privileged={{pillar['allow_privileged']}} {{log_level}} {{cluster_dns}} {{cluster_domain}} {{docker_root}} {{kubelet_root}} {{non_masquerade_cidr}} {{cgroup_root}} {{system_container}} {{pod_cidr}} {{ master_kubelet_args }} {{cpu_cfs_quota}} {{network_plugin}} {{kubelet_port}} {{ hairpin_mode }} {{enable_custom_metrics}} {{runtime_container}} {{kubelet_container}} {{node_labels}} {{eviction_hard}} {{kubelet_auth}} {{feature_gates}} {{test_args}}" diff --git a/cluster/saltbase/salt/nginx/init.sls b/cluster/saltbase/salt/nginx/init.sls deleted file mode 100644 index 201371755dfe0..0000000000000 --- a/cluster/saltbase/salt/nginx/init.sls +++ /dev/null @@ -1,64 +0,0 @@ -nginx: - pkg: - - installed - -/etc/nginx/nginx.conf: - file: - - managed - - source: salt://nginx/nginx.conf - - template: jinja - - user: root - - group: root - - mode: 644 - -/etc/nginx/sites-enabled/default: - file: - - managed - - makedirs: true - - source: salt://nginx/kubernetes-site - - user: root - - group: root - - mode: 644 - -/usr/share/nginx/htpasswd: - file: - - managed - - source: salt://nginx/htpasswd - - user: root - - group: root - - mode: 644 - -{% if grains.cloud is defined and grains.cloud in ['gce'] %} -/etc/kubernetes/manifests/nginx.json: - file: - - managed - - source: salt://nginx/nginx.json - - user: root - - group: root - - mode: 644 - - require: - - file: /etc/nginx/nginx.conf - - file: /etc/nginx/sites-enabled/default - - file: /usr/share/nginx/htpasswd - - cmd: kubernetes-cert - - -#stop legacy nginx_service -stop_nginx-service: - service.dead: - - name: nginx - - enable: None - -{% else %} -nginx-service: - service: - - running - - name: nginx - - watch: - - pkg: nginx - - file: /etc/nginx/nginx.conf - - file: /etc/nginx/sites-enabled/default - - file: /usr/share/nginx/htpasswd - - cmd: kubernetes-cert -{% endif %} - diff --git a/cluster/saltbase/salt/nginx/kubernetes-site b/cluster/saltbase/salt/nginx/kubernetes-site deleted file mode 100644 index 818a487110564..0000000000000 --- a/cluster/saltbase/salt/nginx/kubernetes-site +++ /dev/null @@ -1,66 +0,0 @@ -#server { - #listen 80; ## listen for ipv4; this line is default and implied - #listen [::]:80 default_server ipv6only=on; ## listen for ipv6 - -# root /usr/share/nginx/www; -# index index.html index.htm; - - # Make site accessible from http://localhost/ -# server_name localhost; -# location / { -# auth_basic "Restricted"; -# auth_basic_user_file /usr/share/nginx/htpasswd; - - # Proxy settings. -# proxy_pass http://localhost:8080/; -# proxy_connect_timeout 159s; -# proxy_send_timeout 600s; -# proxy_read_timeout 600s; -# proxy_buffer_size 64k; -# proxy_buffers 16 32k; -# proxy_busy_buffers_size 64k; -# proxy_temp_file_write_size 64k; -# } -#} - -# HTTPS server -# -server { - listen 443; - server_name localhost; - - root html; - index index.html index.htm; - - ssl on; - ssl_certificate /srv/kubernetes/server.cert; - ssl_certificate_key /srv/kubernetes/server.key; - - ssl_session_timeout 5m; - - # don't use SSLv3 because of POODLE - ssl_protocols TLSv1 TLSv1.1 TLSv1.2; - ssl_ciphers ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+3DES:DH+3DES:RSA+AESGCM:RSA+AES:RSA+3DES:!aNULL:!MD5:!DSS; - ssl_prefer_server_ciphers on; - - location / { - auth_basic "Restricted"; - auth_basic_user_file /usr/share/nginx/htpasswd; - - # Proxy settings - # disable buffering so that watch works - proxy_buffering off; - proxy_pass http://127.0.0.1:8080/; - proxy_connect_timeout 159s; - proxy_send_timeout 600s; - proxy_read_timeout 600s; - - # Disable retry - proxy_next_upstream off; - - # Support web sockets - proxy_http_version 1.1; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection "upgrade"; - } -} diff --git a/cluster/saltbase/salt/nginx/nginx.conf b/cluster/saltbase/salt/nginx/nginx.conf deleted file mode 100644 index 00b1961ab617b..0000000000000 --- a/cluster/saltbase/salt/nginx/nginx.conf +++ /dev/null @@ -1,61 +0,0 @@ -{% if grains['os_family'] == 'RedHat' %} -user nginx; -{% else %} -user www-data; -{% endif %} - -worker_processes 4; -pid /var/run/nginx.pid; - -events { - worker_connections 768; - # multi_accept on; -} - -http { - - ## - # Basic Settings - ## - - sendfile on; - tcp_nopush on; - tcp_nodelay on; - keepalive_timeout 65; - types_hash_max_size 2048; - # server_tokens off; - - # server_names_hash_bucket_size 64; - # server_name_in_redirect off; - - include /etc/nginx/mime.types; - default_type application/octet-stream; - - ## - # Logging Settings - ## - - access_log /var/log/nginx/access.log; - error_log /var/log/nginx/error.log; - - ## - # Gzip Settings - ## - - gzip on; - gzip_disable "msie6"; - - # gzip_vary on; - # gzip_proxied any; - # gzip_comp_level 6; - # gzip_buffers 16 8k; - # gzip_http_version 1.1; - # gzip_types text/plain text/css application/json application/x-javascript text/xml application/xml application/xml+rss text/javascript; - - ## - # Virtual Host Configs - ## - - include /etc/nginx/conf.d/*.conf; - include /etc/nginx/sites-enabled/*; -} diff --git a/cluster/saltbase/salt/nginx/nginx.json b/cluster/saltbase/salt/nginx/nginx.json deleted file mode 100644 index 44c41c27d187e..0000000000000 --- a/cluster/saltbase/salt/nginx/nginx.json +++ /dev/null @@ -1,60 +0,0 @@ -{ -"apiVersion": "v1", -"kind": "Pod", -"metadata": {"name":"nginx"}, -"spec":{ -"hostNetwork": true, -"containers":[ - { - "name": "nginx", - "image": "gcr.io/google-containers/nginx:v1", - "resources": { - "limits": { - "cpu": "200m" - } - }, - "command": [ - "nginx", - "-g", - "daemon off;" - ], - "ports":[ - { "name": "https", - "containerPort": 443, - "hostPort": 443} - ], - "volumeMounts": [ - { "name": "nginx", - "mountPath": "/etc/nginx", - "readOnly": true}, - { "name": "k8s", - "mountPath": "/srv/kubernetes", - "readOnly": true}, - { "name": "logs", - "mountPath": "/var/log/nginx", - "readOnly": false}, - { "name": "passwd", - "mountPath": "/usr/share/nginx", - "readOnly": true} - ] - } -], -"volumes":[ - { "name": "nginx", - "hostPath": { - "path": "/etc/nginx"} - }, - { "name": "k8s", - "hostPath": { - "path": "/srv/kubernetes"} - }, - { "name": "passwd", - "hostPath": { - "path": "/usr/share/nginx"} - }, - { "name": "logs", - "hostPath": { - "path": "/var/logs/nginx"} - } -] -}} diff --git a/cluster/saltbase/salt/openvpn-client/client.conf b/cluster/saltbase/salt/openvpn-client/client.conf deleted file mode 100644 index a620762447424..0000000000000 --- a/cluster/saltbase/salt/openvpn-client/client.conf +++ /dev/null @@ -1,53 +0,0 @@ -# Specify that we are a client and that we -# will be pulling certain config file directives -# from the server. -client - -# Use the same setting as you are using on -# the server. -# On most systems, the VPN will not function -# unless you partially or fully disable -# the firewall for the TUN/TAP interface. -dev tun - -# Are we connecting to a TCP or -# UDP server? Use the same setting as -# on the server. -proto udp - -# The hostname/IP and port of the server. -# You can have multiple remote entries -# to load balance between the servers. -remote {{ salt['mine.get']('roles:kubernetes-master', 'network.ip_addrs', 'grain').keys()[0] }} 1194 - -# Keep trying indefinitely to resolve the -# host name of the OpenVPN server. Very useful -# on machines which are not permanently connected -# to the internet such as laptops. -resolv-retry infinite - -# Most clients don't need to bind to -# a specific local port number. -nobind - -# Try to preserve some state across restarts. -persist-key -persist-tun - -# SSL/TLS parms. -# See the server config file for more -# description. It's best to use -# a separate .crt/.key file pair -# for each client. A single ca -# file can be used for all clients. -ca /etc/openvpn/ca.crt -cert /etc/openvpn/client.crt -key /etc/openvpn/client.key - -# Enable compression on the VPN link. -# Don't enable this unless it is also -# enabled in the server config file. -comp-lzo - -# Set log file verbosity. -verb 3 diff --git a/cluster/saltbase/salt/openvpn-client/init.sls b/cluster/saltbase/salt/openvpn-client/init.sls deleted file mode 100644 index c0dbc04b06aa5..0000000000000 --- a/cluster/saltbase/salt/openvpn-client/init.sls +++ /dev/null @@ -1,16 +0,0 @@ -/etc/openvpn/client.conf: - file.managed: - - source: salt://openvpn-client/client.conf - - template: jinja - - user: root - - group: root - - mode: 644 - - makedirs: True - -openvpn: - pkg: - - latest - service.running: - - enable: True - - watch: - - file: /etc/openvpn/client.conf diff --git a/cluster/saltbase/salt/openvpn/init.sls b/cluster/saltbase/salt/openvpn/init.sls deleted file mode 100644 index ab6bed4198022..0000000000000 --- a/cluster/saltbase/salt/openvpn/init.sls +++ /dev/null @@ -1,31 +0,0 @@ -/etc/openvpn/server.conf: - file.managed: - - source: salt://openvpn/server.conf - - template: jinja - - user: root - - group: root - - mode: 644 - - makedirs: True - -{% for minion in salt['mine.get']('roles:kubernetes-pool', 'grains.items', expr_form='grain').values() %} -/etc/openvpn/ccd/{{ minion['hostnamef'] }}: - file.managed: - - contents: "iroute {{ minion['cbr-string'] }}\n" - - user: root - - group: root - - mode: 644 - - makedirs: True -{% endfor %} - -openssl dhparam -out /etc/openvpn/dh1024.pem 1024: - cmd.run: - - creates: /etc/openvpn/dh1024.pem - - unless: file /etc/openvpn/dh1024.pem - -openvpn: - pkg: - - latest - service.running: - - enable: True - - watch: - - file: /etc/openvpn/server.conf diff --git a/cluster/saltbase/salt/openvpn/server.conf b/cluster/saltbase/salt/openvpn/server.conf deleted file mode 100644 index 64ae567de8617..0000000000000 --- a/cluster/saltbase/salt/openvpn/server.conf +++ /dev/null @@ -1,123 +0,0 @@ -# Which TCP/UDP port should OpenVPN listen on? -# If you want to run multiple OpenVPN instances -# on the same machine, use a different port -# number for each one. You will need to -# open up this port on your firewall. -port 1194 - -# TCP or UDP server? -proto udp - -# "dev tun" will create a routed IP tunnel, -# "dev tap" will create an ethernet tunnel. -# Use "dev tap0" if you are ethernet bridging -# and have precreated a tap0 virtual interface -# and bridged it with your ethernet interface. -# If you want to control access policies -# over the VPN, you must create firewall -# rules for the the TUN/TAP interface. -# On non-Windows systems, you can give -# an explicit unit number, such as tun0. -# On Windows, use "dev-node" for this. -# On most systems, the VPN will not function -# unless you partially or fully disable -# the firewall for the TUN/TAP interface. -dev tun - -# SSL/TLS root certificate (ca), certificate -# (cert), and private key (key). Each client -# and the server must have their own cert and -# key file. The server and all clients will -# use the same ca file. -# -# See the "easy-rsa" directory for a series -# of scripts for generating RSA certificates -# and private keys. Remember to use -# a unique Common Name for the server -# and each of the client certificates. -# -# Any X509 key management system can be used. -# OpenVPN can also use a PKCS #12 formatted key file -# (see "pkcs12" directive in man page). -ca /etc/openvpn/ca.crt -cert /etc/openvpn/server.crt -key /etc/openvpn/server.key # This file should be kept secret - -# Diffie hellman parameters. -# Generate your own with: -# openssl dhparam -out dh1024.pem 1024 -# Substitute 2048 for 1024 if you are using -# 2048 bit keys. -dh /etc/openvpn/dh1024.pem - -# Configure server mode and supply a VPN subnet -# for OpenVPN to draw client addresses from. -# The server will take 10.8.0.1 for itself, -# the rest will be made available to clients. -# Each client will be able to reach the server -# on 10.8.0.1. Comment this line out if you are -# ethernet bridging. See the man page for more info. -server 10.8.0.0 255.255.255.0 - -# Maintain a record of client <-> virtual IP address -# associations in this file. If OpenVPN goes down or -# is restarted, reconnecting clients can be assigned -# the same virtual IP address from the pool that was -# previously assigned. -ifconfig-pool-persist ipp.txt - -# To assign specific IP addresses to specific -# clients or if a connecting client has a private -# subnet behind it that should also have VPN access, -# use the subdirectory "ccd" for client-specific -# configuration files (see man page for more info). - -client-config-dir /etc/openvpn/ccd - -{% for minion in salt['mine.get']('roles:kubernetes-pool', 'grains.items', expr_form='grain').values() %} -push "route {{ minion['cbr-string'] }}" -route {{ minion['cbr-string'] }} -{% endfor %} - -# Uncomment this directive to allow different -# clients to be able to "see" each other. -# By default, clients will only see the server. -# To force clients to only see the server, you -# will also need to appropriately firewall the -# server's TUN/TAP interface. -client-to-client - -# The keepalive directive causes ping-like -# messages to be sent back and forth over -# the link so that each side knows when -# the other side has gone down. -# Ping every 10 seconds, assume that remote -# peer is down if no ping received during -# a 120 second time period. -keepalive 10 120 - -# Enable compression on the VPN link. -# If you enable it here, you must also -# enable it in the client config file. -comp-lzo - -# The persist options will try to avoid -# accessing certain resources on restart -# that may no longer be accessible because -# of the privilege downgrade. -persist-key -persist-tun - -# Output a short status file showing -# current connections, truncated -# and rewritten every minute. -status openvpn-status.log - -# Set the appropriate level of log -# file verbosity. -# -# 0 is silent, except for fatal errors -# 4 is reasonable for general usage -# 5 and 6 can help to debug connection problems -# 9 is extremely verbose -verb 3 diff --git a/cluster/saltbase/salt/top.sls b/cluster/saltbase/salt/top.sls index 3cf3b78750295..e517778a77e6d 100644 --- a/cluster/saltbase/salt/top.sls +++ b/cluster/saltbase/salt/top.sls @@ -19,9 +19,6 @@ base: - cni {% elif pillar.get('network_provider', '').lower() == 'cni' %} - cni -{% endif %} -{% if grains['cloud'] is defined and grains['cloud'] == 'azure-legacy' %} - - openvpn-client {% endif %} - helpers - kube-client-tools @@ -67,10 +64,6 @@ base: - logrotate {% endif %} - kube-addons -{% if grains['cloud'] is defined and grains['cloud'] == 'azure-legacy' %} - - openvpn - - nginx -{% endif %} {% if grains['cloud'] is defined and grains['cloud'] in [ 'vagrant', 'gce', 'aws', 'photon-controller', 'openstack', 'azure-legacy'] %} - docker - kubelet diff --git a/cluster/update-storage-objects.sh b/cluster/update-storage-objects.sh index 7ad1d344bc556..d739c65eb18b9 100755 --- a/cluster/update-storage-objects.sh +++ b/cluster/update-storage-objects.sh @@ -48,6 +48,7 @@ declare -a resources=( "services" "jobs" "horizontalpodautoscalers" + "storageclasses" ) # Find all the namespaces. diff --git a/cluster/vagrant/config-default.sh b/cluster/vagrant/config-default.sh index d2ab2f7837f91..c307b8bd38365 100755 --- a/cluster/vagrant/config-default.sh +++ b/cluster/vagrant/config-default.sh @@ -121,5 +121,3 @@ E2E_STORAGE_TEST_ENVIRONMENT=${KUBE_E2E_STORAGE_TEST_ENVIRONMENT:-false} # Default fallback NETWORK_IF_NAME, will be used in case when no 'VAGRANT-BEGIN' comments were defined in network-script export DEFAULT_NETWORK_IF_NAME="eth0" -# Evict pods whenever compute resource availability on the nodes gets below a threshold. -EVICTION_HARD="${EVICTION_HARD:-memory.available<100Mi,nodefs.available<10%}" diff --git a/cluster/vagrant/config-test.sh b/cluster/vagrant/config-test.sh index f6dc030ce2e4d..d5458c2861bf8 100644 --- a/cluster/vagrant/config-test.sh +++ b/cluster/vagrant/config-test.sh @@ -27,5 +27,3 @@ REGISTER_MASTER_KUBELET=${REGISTER_MASTER:-false} # Optional: if set to true, kube-up will configure the cluster to run e2e tests. E2E_STORAGE_TEST_ENVIRONMENT=${KUBE_E2E_STORAGE_TEST_ENVIRONMENT:-false} -# Evict pods whenever compute resource availability on the nodes gets below a threshold. -EVICTION_HARD="${EVICTION_HARD:-memory.available<100Mi,nodefs.available<10%}" diff --git a/cmd/kube-apiserver/app/BUILD b/cmd/kube-apiserver/app/BUILD index 5154375b3670e..9d6abbca00511 100644 --- a/cmd/kube-apiserver/app/BUILD +++ b/cmd/kube-apiserver/app/BUILD @@ -23,6 +23,7 @@ go_library( "//pkg/apis/apps:go_default_library", "//pkg/apis/batch:go_default_library", "//pkg/apis/extensions:go_default_library", + "//pkg/apis/networking:go_default_library", "//pkg/capabilities:go_default_library", "//pkg/client/clientset_generated/internalclientset:go_default_library", "//pkg/client/informers/informers_generated/internalversion:go_default_library", @@ -55,7 +56,6 @@ go_library( "//plugin/pkg/admission/limitranger:go_default_library", "//plugin/pkg/admission/namespace/autoprovision:go_default_library", "//plugin/pkg/admission/namespace/exists:go_default_library", - "//plugin/pkg/admission/namespace/lifecycle:go_default_library", "//plugin/pkg/admission/noderestriction:go_default_library", "//plugin/pkg/admission/persistentvolume/label:go_default_library", "//plugin/pkg/admission/podnodeselector:go_default_library", @@ -82,10 +82,12 @@ go_library( "//vendor/k8s.io/apiserver/pkg/admission:go_default_library", "//vendor/k8s.io/apiserver/pkg/authentication/authenticator:go_default_library", "//vendor/k8s.io/apiserver/pkg/authorization/authorizer:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", "//vendor/k8s.io/apiserver/pkg/server:go_default_library", "//vendor/k8s.io/apiserver/pkg/server/filters:go_default_library", "//vendor/k8s.io/apiserver/pkg/server/healthz:go_default_library", "//vendor/k8s.io/apiserver/pkg/server/options:go_default_library", + "//vendor/k8s.io/apiserver/pkg/server/options/encryptionconfig:go_default_library", "//vendor/k8s.io/apiserver/pkg/server/storage:go_default_library", "//vendor/k8s.io/client-go/kubernetes:go_default_library", "//vendor/k8s.io/kube-aggregator/pkg/apis/apiregistration:go_default_library", diff --git a/cmd/kube-apiserver/app/aggregator.go b/cmd/kube-apiserver/app/aggregator.go index 2ced761f6443e..3aa6279b93df1 100644 --- a/cmd/kube-apiserver/app/aggregator.go +++ b/cmd/kube-apiserver/app/aggregator.go @@ -79,11 +79,13 @@ func createAggregatorConfig(kubeAPIServerConfig genericapiserver.Config, command return nil, err } } + aggregatorConfig := &aggregatorapiserver.Config{ - GenericConfig: &genericConfig, - CoreAPIServerClient: client, - ProxyClientCert: certBytes, - ProxyClientKey: keyBytes, + GenericConfig: &genericConfig, + CoreAPIServerClient: client, + ProxyClientCert: certBytes, + ProxyClientKey: keyBytes, + EnableAggregatorRouting: commandOptions.EnableAggregatorRouting, } return aggregatorConfig, nil diff --git a/cmd/kube-apiserver/app/apiextensions.go b/cmd/kube-apiserver/app/apiextensions.go index 211c2096629ee..75ef8a8cd892b 100644 --- a/cmd/kube-apiserver/app/apiextensions.go +++ b/cmd/kube-apiserver/app/apiextensions.go @@ -47,7 +47,7 @@ func createAPIExtensionsConfig(kubeAPIServerConfig genericapiserver.Config, comm // copy the etcd options so we don't mutate originals. etcdOptions := *commandOptions.Etcd - etcdOptions.StorageConfig.Codec = apiextensionsapiserver.Codecs.LegacyCodec(schema.GroupVersion{Group: "apiextensions.k8s.io", Version: "v1alpha1"}) + etcdOptions.StorageConfig.Codec = apiextensionsapiserver.Codecs.LegacyCodec(schema.GroupVersion{Group: "apiextensions.k8s.io", Version: "v1beta1"}) etcdOptions.StorageConfig.Copier = apiextensionsapiserver.Scheme genericConfig.RESTOptionsGetter = &genericoptions.SimpleRestOptionsFactory{Options: etcdOptions} diff --git a/cmd/kube-apiserver/app/options/options.go b/cmd/kube-apiserver/app/options/options.go index 8ecc905b436dd..99ca76f92e875 100644 --- a/cmd/kube-apiserver/app/options/options.go +++ b/cmd/kube-apiserver/app/options/options.go @@ -45,7 +45,7 @@ type ServerRunOptions struct { Etcd *genericoptions.EtcdOptions SecureServing *genericoptions.SecureServingOptions InsecureServing *kubeoptions.InsecureServingOptions - Audit *genericoptions.AuditLogOptions + Audit *genericoptions.AuditOptions Features *genericoptions.FeatureOptions Admission *genericoptions.AdmissionOptions Authentication *kubeoptions.BuiltInAuthenticationOptions @@ -68,6 +68,8 @@ type ServerRunOptions struct { ProxyClientCertFile string ProxyClientKeyFile string + + EnableAggregatorRouting bool } // NewServerRunOptions creates a new ServerRunOptions object with default parameters @@ -77,7 +79,7 @@ func NewServerRunOptions() *ServerRunOptions { Etcd: genericoptions.NewEtcdOptions(storagebackend.NewDefaultConfig(kubeoptions.DefaultEtcdPathPrefix, api.Scheme, nil)), SecureServing: kubeoptions.NewSecureServingOptions(), InsecureServing: kubeoptions.NewInsecureServingOptions(), - Audit: genericoptions.NewAuditLogOptions(), + Audit: genericoptions.NewAuditOptions(), Features: genericoptions.NewFeatureOptions(), Admission: genericoptions.NewAdmissionOptions(), Authentication: kubeoptions.NewBuiltInAuthenticationOptions().WithAll(), @@ -217,4 +219,7 @@ func (s *ServerRunOptions) AddFlags(fs *pflag.FlagSet) { fs.StringVar(&s.ProxyClientKeyFile, "proxy-client-key-file", s.ProxyClientKeyFile, "client certificate key used to prove the identity of the aggragator or kube-apiserver when it proxies requests to a user api-server") + fs.BoolVar(&s.EnableAggregatorRouting, "enable-aggregator-routing", s.EnableAggregatorRouting, + "Turns on aggregator routing requests to endoints IP rather than cluster IP.") + } diff --git a/cmd/kube-apiserver/app/plugins.go b/cmd/kube-apiserver/app/plugins.go index ba20aacfd1638..f287a9a47d0bf 100644 --- a/cmd/kube-apiserver/app/plugins.go +++ b/cmd/kube-apiserver/app/plugins.go @@ -37,7 +37,6 @@ import ( "k8s.io/kubernetes/plugin/pkg/admission/limitranger" "k8s.io/kubernetes/plugin/pkg/admission/namespace/autoprovision" "k8s.io/kubernetes/plugin/pkg/admission/namespace/exists" - "k8s.io/kubernetes/plugin/pkg/admission/namespace/lifecycle" noderestriction "k8s.io/kubernetes/plugin/pkg/admission/noderestriction" "k8s.io/kubernetes/plugin/pkg/admission/persistentvolume/label" "k8s.io/kubernetes/plugin/pkg/admission/podnodeselector" @@ -64,7 +63,6 @@ func registerAllAdmissionPlugins(plugins *admission.Plugins) { limitranger.Register(plugins) autoprovision.Register(plugins) exists.Register(plugins) - lifecycle.Register(plugins) noderestriction.Register(plugins) label.Register(plugins) podnodeselector.Register(plugins) diff --git a/cmd/kube-apiserver/app/preflight/checks.go b/cmd/kube-apiserver/app/preflight/checks.go index 1e55eca2430bd..c3bbd0577909f 100644 --- a/cmd/kube-apiserver/app/preflight/checks.go +++ b/cmd/kube-apiserver/app/preflight/checks.go @@ -31,6 +31,7 @@ type connection interface { CheckEtcdServers() (bool, error) } +// EtcdConnection holds the Etcd server list type EtcdConnection struct { ServerList []string } @@ -44,19 +45,19 @@ func (EtcdConnection) serverReachable(address string) bool { } func parseServerURI(serverURI string) (string, error) { - connUrl, err := url.Parse(serverURI) + connURL, err := url.Parse(serverURI) if err != nil { return "", fmt.Errorf("unable to parse etcd url: %v", err) } - return connUrl.Host, nil + return connURL.Host, nil } // CheckEtcdServers will attempt to reach all etcd servers once. If any // can be reached, return true. func (con EtcdConnection) CheckEtcdServers() (done bool, err error) { // Attempt to reach every Etcd server in order - for _, serverUri := range con.ServerList { - host, err := parseServerURI(serverUri) + for _, serverURI := range con.ServerList { + host, err := parseServerURI(serverURI) if err != nil { return false, err } diff --git a/cmd/kube-apiserver/app/preflight/checks_test.go b/cmd/kube-apiserver/app/preflight/checks_test.go index 71a59399cd1f3..da6ad0f3aca3e 100644 --- a/cmd/kube-apiserver/app/preflight/checks_test.go +++ b/cmd/kube-apiserver/app/preflight/checks_test.go @@ -31,7 +31,7 @@ func TestParseServerURIGood(t *testing.T) { reference := "127.0.0.1:2379" if host != reference { - t.Fatal("server uri was not parsed correctly") + t.Fatalf("server uri was not parsed correctly, host %s was invalid", host) } } diff --git a/cmd/kube-apiserver/app/server.go b/cmd/kube-apiserver/app/server.go index c8f3e5c326c8b..32bfa2eeddbb3 100644 --- a/cmd/kube-apiserver/app/server.go +++ b/cmd/kube-apiserver/app/server.go @@ -47,8 +47,10 @@ import ( "k8s.io/apiserver/pkg/admission" "k8s.io/apiserver/pkg/authentication/authenticator" "k8s.io/apiserver/pkg/authorization/authorizer" + genericregistry "k8s.io/apiserver/pkg/registry/generic" genericapiserver "k8s.io/apiserver/pkg/server" "k8s.io/apiserver/pkg/server/filters" + "k8s.io/apiserver/pkg/server/options/encryptionconfig" serverstorage "k8s.io/apiserver/pkg/server/storage" "k8s.io/kubernetes/cmd/kube-apiserver/app/options" @@ -57,6 +59,7 @@ import ( "k8s.io/kubernetes/pkg/apis/apps" "k8s.io/kubernetes/pkg/apis/batch" "k8s.io/kubernetes/pkg/apis/extensions" + "k8s.io/kubernetes/pkg/apis/networking" "k8s.io/kubernetes/pkg/capabilities" "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset" informers "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion" @@ -105,8 +108,18 @@ func Run(runOptions *options.ServerRunOptions, stopCh <-chan struct{}) error { return err } - // kubeAPIServer is at the base for now. This ensures that CustomResourceDefinitions trump TPRs - kubeAPIServer, err := CreateKubeAPIServer(kubeAPIServerConfig, genericapiserver.EmptyDelegate, sharedInformers) + // TPRs are enabled and not yet beta, since this these are the successor, they fall under the same enablement rule + // If additional API servers are added, they should be gated. + apiExtensionsConfig, err := createAPIExtensionsConfig(*kubeAPIServerConfig.GenericConfig, runOptions) + if err != nil { + return err + } + apiExtensionsServer, err := createAPIExtensionsServer(apiExtensionsConfig, genericapiserver.EmptyDelegate) + if err != nil { + return err + } + + kubeAPIServer, err := CreateKubeAPIServer(kubeAPIServerConfig, apiExtensionsServer.GenericAPIServer, sharedInformers, apiExtensionsConfig.CRDRESTOptionsGetter) if err != nil { return err } @@ -128,24 +141,12 @@ func Run(runOptions *options.ServerRunOptions, stopCh <-chan struct{}) error { // this wires up openapi kubeAPIServer.GenericAPIServer.PrepareRun() - // TPRs are enabled and not yet beta, since this these are the successor, they fall under the same enablement rule - // Subsequent API servers in between here and kube-apiserver will need to be gated. - // These come first so that if someone registers both a TPR and a CRD, the CRD is preferred. - apiExtensionsConfig, err := createAPIExtensionsConfig(*kubeAPIServerConfig.GenericConfig, runOptions) - if err != nil { - return err - } - apiExtensionsServer, err := createAPIExtensionsServer(apiExtensionsConfig, kubeAPIServer.GenericAPIServer) - if err != nil { - return err - } - // aggregator comes last in the chain aggregatorConfig, err := createAggregatorConfig(*kubeAPIServerConfig.GenericConfig, runOptions) if err != nil { return err } - aggregatorServer, err := createAggregatorServer(aggregatorConfig, apiExtensionsServer.GenericAPIServer, sharedInformers, apiExtensionsServer.Informers) + aggregatorServer, err := createAggregatorServer(aggregatorConfig, kubeAPIServer.GenericAPIServer, sharedInformers, apiExtensionsServer.Informers) if err != nil { // we don't need special handling for innerStopCh because the aggregator server doesn't create any go routines return err @@ -162,8 +163,8 @@ func Run(runOptions *options.ServerRunOptions, stopCh <-chan struct{}) error { } // CreateKubeAPIServer creates and wires a workable kube-apiserver -func CreateKubeAPIServer(kubeAPIServerConfig *master.Config, delegateAPIServer genericapiserver.DelegationTarget, sharedInformers informers.SharedInformerFactory) (*master.Master, error) { - kubeAPIServer, err := kubeAPIServerConfig.Complete().New(delegateAPIServer) +func CreateKubeAPIServer(kubeAPIServerConfig *master.Config, delegateAPIServer genericapiserver.DelegationTarget, sharedInformers informers.SharedInformerFactory, crdRESTOptionsGetter genericregistry.RESTOptionsGetter) (*master.Master, error) { + kubeAPIServer, err := kubeAPIServerConfig.Complete().New(delegateAPIServer, crdRESTOptionsGetter) if err != nil { return nil, err } @@ -473,8 +474,9 @@ func BuildStorageFactory(s *options.ServerRunOptions) (*serverstorage.DefaultSto return nil, fmt.Errorf("error in initializing storage factory: %s", err) } - // keep Deployments in extensions for backwards compatibility, we'll have to migrate at some point, eventually + // keep Deployments and NetworkPolicies in extensions for backwards compatibility, we'll have to migrate at some point, eventually storageFactory.AddCohabitatingResources(extensions.Resource("deployments"), apps.Resource("deployments")) + storageFactory.AddCohabitatingResources(extensions.Resource("networkpolicies"), networking.Resource("networkpolicies")) for _, override := range s.Etcd.EtcdServersOverrides { tokens := strings.Split(override, "#") if len(tokens) != 2 { @@ -495,6 +497,16 @@ func BuildStorageFactory(s *options.ServerRunOptions) (*serverstorage.DefaultSto storageFactory.SetEtcdLocation(groupResource, servers) } + if s.Etcd.EncryptionProviderConfigFilepath != "" { + transformerOverrides, err := encryptionconfig.GetTransformerOverrides(s.Etcd.EncryptionProviderConfigFilepath) + if err != nil { + return nil, err + } + for groupResource, transformer := range transformerOverrides { + storageFactory.SetTransformer(groupResource, transformer) + } + } + return storageFactory, nil } @@ -536,7 +548,7 @@ func defaultOptions(s *options.ServerRunOptions) error { // This is the heuristics that from memory capacity is trying to infer // the maximum number of nodes in the cluster and set cache sizes based // on that value. - // From our documentation, we officially recomment 120GB machines for + // From our documentation, we officially recommend 120GB machines for // 2000 nodes, and we scale from that point. Thus we assume ~60MB of // capacity per node. // TODO: We may consider deciding that some percentage of memory will diff --git a/cmd/kube-controller-manager/app/BUILD b/cmd/kube-controller-manager/app/BUILD index 9cb00956ac5e8..9b3692b68c354 100644 --- a/cmd/kube-controller-manager/app/BUILD +++ b/cmd/kube-controller-manager/app/BUILD @@ -84,6 +84,7 @@ go_library( "//pkg/volume/gce_pd:go_default_library", "//pkg/volume/glusterfs:go_default_library", "//pkg/volume/host_path:go_default_library", + "//pkg/volume/local:go_default_library", "//pkg/volume/nfs:go_default_library", "//pkg/volume/photon_pd:go_default_library", "//pkg/volume/portworx:go_default_library", diff --git a/cmd/kube-controller-manager/app/certificates.go b/cmd/kube-controller-manager/app/certificates.go index af669e04dd500..96819b4b44065 100644 --- a/cmd/kube-controller-manager/app/certificates.go +++ b/cmd/kube-controller-manager/app/certificates.go @@ -42,6 +42,7 @@ func startCSRSigningController(ctx ControllerContext) (bool, error) { ctx.InformerFactory.Certificates().V1beta1().CertificateSigningRequests(), ctx.Options.ClusterSigningCertFile, ctx.Options.ClusterSigningKeyFile, + ctx.Options.ClusterSigningDuration.Duration, ) if err != nil { glog.Errorf("Failed to start certificate controller: %v", err) @@ -56,15 +57,11 @@ func startCSRApprovingController(ctx ControllerContext) (bool, error) { if !ctx.AvailableResources[schema.GroupVersionResource{Group: "certificates.k8s.io", Version: "v1beta1", Resource: "certificatesigningrequests"}] { return false, nil } - if ctx.Options.ApproveAllKubeletCSRsForGroup == "" { - return false, nil - } c := ctx.ClientBuilder.ClientOrDie("certificate-controller") approver, err := approver.NewCSRApprovingController( c, ctx.InformerFactory.Certificates().V1beta1().CertificateSigningRequests(), - ctx.Options.ApproveAllKubeletCSRsForGroup, ) if err != nil { // TODO this is failing consistently in test-cmd and local-up-cluster.sh. Fix them and make it consistent with all others which diff --git a/cmd/kube-controller-manager/app/options/BUILD b/cmd/kube-controller-manager/app/options/BUILD index 24e610b7b7cd8..95a03df4fe9dc 100644 --- a/cmd/kube-controller-manager/app/options/BUILD +++ b/cmd/kube-controller-manager/app/options/BUILD @@ -17,6 +17,7 @@ go_library( "//pkg/controller/garbagecollector:go_default_library", "//pkg/features:go_default_library", "//pkg/master/ports:go_default_library", + "//vendor/github.com/cloudflare/cfssl/helpers:go_default_library", "//vendor/github.com/spf13/pflag:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/errors:go_default_library", diff --git a/cmd/kube-controller-manager/app/options/options.go b/cmd/kube-controller-manager/app/options/options.go index 03a41cbad86c6..7d81d8e276d54 100644 --- a/cmd/kube-controller-manager/app/options/options.go +++ b/cmd/kube-controller-manager/app/options/options.go @@ -35,6 +35,7 @@ import ( // add the kubernetes feature gates _ "k8s.io/kubernetes/pkg/features" + "github.com/cloudflare/cfssl/helpers" "github.com/spf13/pflag" ) @@ -66,7 +67,7 @@ func NewCMServer() *CMServer { ConcurrentJobSyncs: 5, ConcurrentResourceQuotaSyncs: 5, ConcurrentDeploymentSyncs: 5, - ConcurrentNamespaceSyncs: 2, + ConcurrentNamespaceSyncs: 5, ConcurrentSATokenSyncs: 5, LookupCacheSizeForRC: 4096, LookupCacheSizeForRS: 4096, @@ -112,6 +113,7 @@ func NewCMServer() *CMServer { GCIgnoredResources: gcIgnoredResources, ClusterSigningCertFile: "/etc/kubernetes/ca/ca.pem", ClusterSigningKeyFile: "/etc/kubernetes/ca/ca.key", + ClusterSigningDuration: metav1.Duration{Duration: helpers.OneYear}, ReconcilerSyncLoopPeriod: metav1.Duration{Duration: 60 * time.Second}, EnableTaintManager: true, HorizontalPodAutoscalerUseRESTClients: false, @@ -192,7 +194,10 @@ func (s *CMServer) AddFlags(fs *pflag.FlagSet, allControllers []string, disabled fs.StringVar(&s.ServiceAccountKeyFile, "service-account-private-key-file", s.ServiceAccountKeyFile, "Filename containing a PEM-encoded private RSA or ECDSA key used to sign service account tokens.") fs.StringVar(&s.ClusterSigningCertFile, "cluster-signing-cert-file", s.ClusterSigningCertFile, "Filename containing a PEM-encoded X509 CA certificate used to issue cluster-scoped certificates") fs.StringVar(&s.ClusterSigningKeyFile, "cluster-signing-key-file", s.ClusterSigningKeyFile, "Filename containing a PEM-encoded RSA or ECDSA private key used to sign cluster-scoped certificates") - fs.StringVar(&s.ApproveAllKubeletCSRsForGroup, "insecure-experimental-approve-all-kubelet-csrs-for-group", s.ApproveAllKubeletCSRsForGroup, "The group for which the controller-manager will auto approve all CSRs for kubelet client certificates.") + fs.DurationVar(&s.ClusterSigningDuration.Duration, "experimental-cluster-signing-duration", s.ClusterSigningDuration.Duration, "The length of duration signed certificates will be given.") + var dummy string + fs.MarkDeprecated("insecure-experimental-approve-all-kubelet-csrs-for-group", "This flag does nothing.") + fs.StringVar(&dummy, "insecure-experimental-approve-all-kubelet-csrs-for-group", "", "This flag does nothing.") fs.BoolVar(&s.EnableProfiling, "profiling", true, "Enable profiling via web interface host:port/debug/pprof/") fs.BoolVar(&s.EnableContentionProfiling, "contention-profiling", false, "Enable lock contention profiling, if profiling is enabled") fs.StringVar(&s.ClusterName, "cluster-name", s.ClusterName, "The instance prefix for the cluster") diff --git a/cmd/kube-controller-manager/app/plugins.go b/cmd/kube-controller-manager/app/plugins.go index 38f126f6b88e0..45dbec4f2a11a 100644 --- a/cmd/kube-controller-manager/app/plugins.go +++ b/cmd/kube-controller-manager/app/plugins.go @@ -47,6 +47,7 @@ import ( "k8s.io/kubernetes/pkg/volume/gce_pd" "k8s.io/kubernetes/pkg/volume/glusterfs" "k8s.io/kubernetes/pkg/volume/host_path" + "k8s.io/kubernetes/pkg/volume/local" "k8s.io/kubernetes/pkg/volume/nfs" "k8s.io/kubernetes/pkg/volume/photon_pd" "k8s.io/kubernetes/pkg/volume/portworx" @@ -121,6 +122,7 @@ func ProbeControllerVolumePlugins(cloud cloudprovider.Interface, config componen allPlugins = append(allPlugins, flocker.ProbeVolumePlugins()...) allPlugins = append(allPlugins, portworx.ProbeVolumePlugins()...) allPlugins = append(allPlugins, scaleio.ProbeVolumePlugins()...) + allPlugins = append(allPlugins, local.ProbeVolumePlugins()...) if cloud != nil { switch { diff --git a/cmd/kube-proxy/app/BUILD b/cmd/kube-proxy/app/BUILD index 745d22f0fb608..65ab9ca321048 100644 --- a/cmd/kube-proxy/app/BUILD +++ b/cmd/kube-proxy/app/BUILD @@ -53,6 +53,7 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/util/net:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", + "//vendor/k8s.io/apiserver/pkg/server/healthz:go_default_library", "//vendor/k8s.io/apiserver/pkg/util/feature:go_default_library", "//vendor/k8s.io/client-go/kubernetes:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/core/v1:go_default_library", diff --git a/cmd/kube-proxy/app/server.go b/cmd/kube-proxy/app/server.go index 993e6967f7654..7c50f18fb7b2a 100644 --- a/cmd/kube-proxy/app/server.go +++ b/cmd/kube-proxy/app/server.go @@ -38,6 +38,7 @@ import ( utilnet "k8s.io/apimachinery/pkg/util/net" utilruntime "k8s.io/apimachinery/pkg/util/runtime" "k8s.io/apimachinery/pkg/util/wait" + "k8s.io/apiserver/pkg/server/healthz" utilfeature "k8s.io/apiserver/pkg/util/feature" clientgoclientset "k8s.io/client-go/kubernetes" v1core "k8s.io/client-go/kubernetes/typed/core/v1" @@ -630,6 +631,7 @@ func (s *ProxyServer) Run() error { // Start up a metrics server if requested if len(s.MetricsBindAddress) > 0 { mux := http.NewServeMux() + healthz.InstallHandler(mux) mux.HandleFunc("/proxyMode", func(w http.ResponseWriter, r *http.Request) { fmt.Fprintf(w, "%s", s.ProxyMode) }) diff --git a/cmd/kubeadm/app/cmd/init.go b/cmd/kubeadm/app/cmd/init.go index 0c455e67d24c9..c7819668deaed 100644 --- a/cmd/kubeadm/app/cmd/init.go +++ b/cmd/kubeadm/app/cmd/init.go @@ -20,7 +20,7 @@ import ( "fmt" "io" "io/ioutil" - "path" + "path/filepath" "strconv" "text/template" @@ -217,7 +217,7 @@ func (i *Init) Run(out io.Writer) error { return err } - adminKubeConfigPath := path.Join(kubeadmapi.GlobalEnvParams.KubernetesDir, kubeadmconstants.AdminKubeConfigFileName) + adminKubeConfigPath := filepath.Join(kubeadmapi.GlobalEnvParams.KubernetesDir, kubeadmconstants.AdminKubeConfigFileName) client, err := kubemaster.CreateClientAndWaitForAPI(adminKubeConfigPath) if err != nil { return err @@ -269,7 +269,7 @@ func (i *Init) Run(out io.Writer) error { } ctx := map[string]string{ - "KubeConfigPath": path.Join(kubeadmapi.GlobalEnvParams.KubernetesDir, kubeadmconstants.AdminKubeConfigFileName), + "KubeConfigPath": filepath.Join(kubeadmapi.GlobalEnvParams.KubernetesDir, kubeadmconstants.AdminKubeConfigFileName), "KubeConfigName": kubeadmconstants.AdminKubeConfigFileName, "Token": i.cfg.Token, "MasterIP": i.cfg.API.AdvertiseAddress, diff --git a/cmd/kubeadm/app/cmd/phases/certs.go b/cmd/kubeadm/app/cmd/phases/certs.go index 56c269fb92e93..b8a90749c1420 100644 --- a/cmd/kubeadm/app/cmd/phases/certs.go +++ b/cmd/kubeadm/app/cmd/phases/certs.go @@ -65,7 +65,7 @@ func NewCmdSelfSign() *cobra.Command { }, } cmd.Flags().StringVar(&cfg.Networking.DNSDomain, "dns-domain", cfg.Networking.DNSDomain, "The DNS Domain for the Kubernetes cluster.") - cmd.Flags().StringVar(&cfg.CertificatesDir, "cert-dir", cfg.CertificatesDir, "The path where to save and store the certificates") + cmd.Flags().StringVar(&cfg.CertificatesDir, "cert-dir", cfg.CertificatesDir, "The path where to save and store the certificates.") cmd.Flags().StringVar(&cfg.Networking.ServiceSubnet, "service-cidr", cfg.Networking.ServiceSubnet, "The subnet for the Services in the cluster.") cmd.Flags().StringSliceVar(&cfg.APIServerCertSANs, "cert-altnames", []string{}, "Optional extra altnames to use for the API Server serving cert. Can be both IP addresses and dns names.") cmd.Flags().StringVar(&cfg.API.AdvertiseAddress, "apiserver-advertise-address", cfg.API.AdvertiseAddress, "The IP address the API Server will advertise it's listening on. 0.0.0.0 means the default network interface's address.") @@ -85,8 +85,7 @@ func RunSelfSign(config *kubeadmapi.MasterConfiguration) error { config.API.AdvertiseAddress = ip.String() } - err = certphase.CreatePKIAssets(config) - if err != nil { + if err = certphase.CreatePKIAssets(config); err != nil { return err } return nil diff --git a/cmd/kubeadm/app/cmd/reset.go b/cmd/kubeadm/app/cmd/reset.go index 64933ffb173c9..6e4a255248245 100644 --- a/cmd/kubeadm/app/cmd/reset.go +++ b/cmd/kubeadm/app/cmd/reset.go @@ -155,8 +155,7 @@ func cleanDir(filePath string) error { return err } for _, name := range names { - err = os.RemoveAll(filepath.Join(filePath, name)) - if err != nil { + if err = os.RemoveAll(filepath.Join(filePath, name)); err != nil { return err } } @@ -171,8 +170,7 @@ func resetConfigDir(configPathDir, pkiPathDir string) { } fmt.Printf("[reset] Deleting contents of config directories: %v\n", dirsToClean) for _, dir := range dirsToClean { - err := cleanDir(dir) - if err != nil { + if err := cleanDir(dir); err != nil { fmt.Printf("[reset] Failed to remove directory: %q [%v]\n", dir, err) } } @@ -185,8 +183,7 @@ func resetConfigDir(configPathDir, pkiPathDir string) { } fmt.Printf("[reset] Deleting files: %v\n", filesToClean) for _, path := range filesToClean { - err := os.RemoveAll(path) - if err != nil { + if err := os.RemoveAll(path); err != nil { fmt.Printf("[reset] Failed to remove file: %q [%v]\n", path, err) } } diff --git a/cmd/kubeadm/app/constants/constants.go b/cmd/kubeadm/app/constants/constants.go index 2cd64fbce036b..13eb5c18cbd5d 100644 --- a/cmd/kubeadm/app/constants/constants.go +++ b/cmd/kubeadm/app/constants/constants.go @@ -17,7 +17,7 @@ limitations under the License. package constants import ( - "path" + "path/filepath" "time" "k8s.io/client-go/pkg/api/v1" @@ -102,8 +102,8 @@ var ( Effect: v1.TaintEffectNoSchedule, } - AuthorizationPolicyPath = path.Join(KubernetesDir, "abac_policy.json") - AuthorizationWebhookConfigPath = path.Join(KubernetesDir, "webhook_authz.conf") + AuthorizationPolicyPath = filepath.Join(KubernetesDir, "abac_policy.json") + AuthorizationWebhookConfigPath = filepath.Join(KubernetesDir, "webhook_authz.conf") // DefaultTokenUsages specifies the default functions a token will get DefaultTokenUsages = []string{"signing", "authentication"} diff --git a/cmd/kubeadm/app/master/BUILD b/cmd/kubeadm/app/master/BUILD index 1ff50b59d7fbe..b8f889bc81c70 100644 --- a/cmd/kubeadm/app/master/BUILD +++ b/cmd/kubeadm/app/master/BUILD @@ -22,7 +22,6 @@ go_library( "//cmd/kubeadm/app/constants:go_default_library", "//cmd/kubeadm/app/images:go_default_library", "//cmd/kubeadm/app/util/kubeconfig:go_default_library", - "//pkg/bootstrap/api:go_default_library", "//pkg/kubeapiserver/authorizer/modes:go_default_library", "//pkg/kubectl/cmd/util:go_default_library", "//pkg/util/version:go_default_library", diff --git a/cmd/kubeadm/app/master/manifests.go b/cmd/kubeadm/app/master/manifests.go index cf4a42291ac10..dfcfb6dad24d9 100644 --- a/cmd/kubeadm/app/master/manifests.go +++ b/cmd/kubeadm/app/master/manifests.go @@ -20,7 +20,7 @@ import ( "bytes" "fmt" "os" - "path" + "path/filepath" "strings" "github.com/ghodss/yaml" @@ -33,7 +33,6 @@ import ( kubeadmapiext "k8s.io/kubernetes/cmd/kubeadm/app/apis/kubeadm/v1alpha1" kubeadmconstants "k8s.io/kubernetes/cmd/kubeadm/app/constants" "k8s.io/kubernetes/cmd/kubeadm/app/images" - bootstrapapi "k8s.io/kubernetes/pkg/bootstrap/api" authzmodes "k8s.io/kubernetes/pkg/kubeapiserver/authorizer/modes" cmdutil "k8s.io/kubernetes/pkg/kubectl/cmd/util" "k8s.io/kubernetes/pkg/util/version" @@ -135,12 +134,12 @@ func WriteStaticPodManifests(cfg *kubeadmapi.MasterConfiguration) error { staticPodSpecs[etcd] = etcdPod } - manifestsPath := path.Join(kubeadmapi.GlobalEnvParams.KubernetesDir, "manifests") + manifestsPath := filepath.Join(kubeadmapi.GlobalEnvParams.KubernetesDir, "manifests") if err := os.MkdirAll(manifestsPath, 0700); err != nil { return fmt.Errorf("failed to create directory %q [%v]", manifestsPath, err) } for name, spec := range staticPodSpecs { - filename := path.Join(manifestsPath, name+".yaml") + filename := filepath.Join(manifestsPath, name+".yaml") serialized, err := yaml.Marshal(spec) if err != nil { return fmt.Errorf("failed to marshal manifest for %q to YAML [%v]", name, err) @@ -332,12 +331,12 @@ func getAPIServerCommand(cfg *kubeadmapi.MasterConfiguration, selfHosted bool, k "insecure-port": "0", "admission-control": kubeadmconstants.DefaultAdmissionControl, "service-cluster-ip-range": cfg.Networking.ServiceSubnet, - "service-account-key-file": path.Join(cfg.CertificatesDir, kubeadmconstants.ServiceAccountPublicKeyName), - "client-ca-file": path.Join(cfg.CertificatesDir, kubeadmconstants.CACertName), - "tls-cert-file": path.Join(cfg.CertificatesDir, kubeadmconstants.APIServerCertName), - "tls-private-key-file": path.Join(cfg.CertificatesDir, kubeadmconstants.APIServerKeyName), - "kubelet-client-certificate": path.Join(cfg.CertificatesDir, kubeadmconstants.APIServerKubeletClientCertName), - "kubelet-client-key": path.Join(cfg.CertificatesDir, kubeadmconstants.APIServerKubeletClientKeyName), + "service-account-key-file": filepath.Join(cfg.CertificatesDir, kubeadmconstants.ServiceAccountPublicKeyName), + "client-ca-file": filepath.Join(cfg.CertificatesDir, kubeadmconstants.CACertName), + "tls-cert-file": filepath.Join(cfg.CertificatesDir, kubeadmconstants.APIServerCertName), + "tls-private-key-file": filepath.Join(cfg.CertificatesDir, kubeadmconstants.APIServerKeyName), + "kubelet-client-certificate": filepath.Join(cfg.CertificatesDir, kubeadmconstants.APIServerKubeletClientCertName), + "kubelet-client-key": filepath.Join(cfg.CertificatesDir, kubeadmconstants.APIServerKubeletClientKeyName), "secure-port": fmt.Sprintf("%d", cfg.API.BindPort), "allow-privileged": "true", "experimental-bootstrap-token-auth": "true", @@ -347,13 +346,13 @@ func getAPIServerCommand(cfg *kubeadmapi.MasterConfiguration, selfHosted bool, k "requestheader-username-headers": "X-Remote-User", "requestheader-group-headers": "X-Remote-Group", "requestheader-extra-headers-prefix": "X-Remote-Extra-", - "requestheader-client-ca-file": path.Join(cfg.CertificatesDir, kubeadmconstants.FrontProxyCACertName), + "requestheader-client-ca-file": filepath.Join(cfg.CertificatesDir, kubeadmconstants.FrontProxyCACertName), "requestheader-allowed-names": "front-proxy-client", } if k8sVersion.AtLeast(v170) { // add options which allow the kube-apiserver to act as a front-proxy to aggregated API servers - defaultArguments["proxy-client-cert-file"] = path.Join(cfg.CertificatesDir, kubeadmconstants.FrontProxyClientCertName) - defaultArguments["proxy-client-key-file"] = path.Join(cfg.CertificatesDir, kubeadmconstants.FrontProxyClientKeyName) + defaultArguments["proxy-client-cert-file"] = filepath.Join(cfg.CertificatesDir, kubeadmconstants.FrontProxyClientCertName) + defaultArguments["proxy-client-key-file"] = filepath.Join(cfg.CertificatesDir, kubeadmconstants.FrontProxyClientKeyName) } command = getComponentBaseCommand(apiServer) @@ -419,16 +418,15 @@ func getControllerManagerCommand(cfg *kubeadmapi.MasterConfiguration, selfHosted } defaultArguments := map[string]string{ - "address": "127.0.0.1", - "leader-elect": "true", - "kubeconfig": path.Join(kubeadmapi.GlobalEnvParams.KubernetesDir, kubeadmconstants.ControllerManagerKubeConfigFileName), - "root-ca-file": path.Join(cfg.CertificatesDir, kubeadmconstants.CACertName), - "service-account-private-key-file": path.Join(cfg.CertificatesDir, kubeadmconstants.ServiceAccountPrivateKeyName), - "cluster-signing-cert-file": path.Join(cfg.CertificatesDir, kubeadmconstants.CACertName), - "cluster-signing-key-file": path.Join(cfg.CertificatesDir, kubeadmconstants.CAKeyName), - "insecure-experimental-approve-all-kubelet-csrs-for-group": bootstrapapi.BootstrapGroup, - "use-service-account-credentials": "true", - "controllers": "*,bootstrapsigner,tokencleaner", + "address": "127.0.0.1", + "leader-elect": "true", + "kubeconfig": filepath.Join(kubeadmapi.GlobalEnvParams.KubernetesDir, kubeadmconstants.ControllerManagerKubeConfigFileName), + "root-ca-file": filepath.Join(cfg.CertificatesDir, kubeadmconstants.CACertName), + "service-account-private-key-file": filepath.Join(cfg.CertificatesDir, kubeadmconstants.ServiceAccountPrivateKeyName), + "cluster-signing-cert-file": filepath.Join(cfg.CertificatesDir, kubeadmconstants.CACertName), + "cluster-signing-key-file": filepath.Join(cfg.CertificatesDir, kubeadmconstants.CAKeyName), + "use-service-account-credentials": "true", + "controllers": "*,bootstrapsigner,tokencleaner", } command = getComponentBaseCommand(controllerManager) @@ -463,7 +461,7 @@ func getSchedulerCommand(cfg *kubeadmapi.MasterConfiguration, selfHosted bool) [ defaultArguments := map[string]string{ "address": "127.0.0.1", "leader-elect": "true", - "kubeconfig": path.Join(kubeadmapi.GlobalEnvParams.KubernetesDir, kubeadmconstants.SchedulerKubeConfigFileName), + "kubeconfig": filepath.Join(kubeadmapi.GlobalEnvParams.KubernetesDir, kubeadmconstants.SchedulerKubeConfigFileName), } command = getComponentBaseCommand(scheduler) diff --git a/cmd/kubeadm/app/master/manifests_test.go b/cmd/kubeadm/app/master/manifests_test.go index e392e5eab3525..7b34c3db0d8c1 100644 --- a/cmd/kubeadm/app/master/manifests_test.go +++ b/cmd/kubeadm/app/master/manifests_test.go @@ -89,6 +89,7 @@ func TestWriteStaticPodManifests(t *testing.T) { t.Errorf("WriteStaticPodManifests: %v", err) continue } + defer manifest.Close() var pod api.Pod d := yaml.NewYAMLOrJSONDecoder(manifest, 4096) @@ -675,7 +676,6 @@ func TestGetControllerManagerCommand(t *testing.T) { "--service-account-private-key-file=" + testCertsDir + "/sa.key", "--cluster-signing-cert-file=" + testCertsDir + "/ca.crt", "--cluster-signing-key-file=" + testCertsDir + "/ca.key", - "--insecure-experimental-approve-all-kubelet-csrs-for-group=system:bootstrappers", "--use-service-account-credentials=true", "--controllers=*,bootstrapsigner,tokencleaner", }, @@ -694,7 +694,6 @@ func TestGetControllerManagerCommand(t *testing.T) { "--service-account-private-key-file=" + testCertsDir + "/sa.key", "--cluster-signing-cert-file=" + testCertsDir + "/ca.crt", "--cluster-signing-key-file=" + testCertsDir + "/ca.key", - "--insecure-experimental-approve-all-kubelet-csrs-for-group=system:bootstrappers", "--use-service-account-credentials=true", "--controllers=*,bootstrapsigner,tokencleaner", "--cloud-provider=foo", @@ -714,7 +713,6 @@ func TestGetControllerManagerCommand(t *testing.T) { "--service-account-private-key-file=" + testCertsDir + "/sa.key", "--cluster-signing-cert-file=" + testCertsDir + "/ca.crt", "--cluster-signing-key-file=" + testCertsDir + "/ca.key", - "--insecure-experimental-approve-all-kubelet-csrs-for-group=system:bootstrappers", "--use-service-account-credentials=true", "--controllers=*,bootstrapsigner,tokencleaner", "--allocate-node-cidrs=true", diff --git a/cmd/kubeadm/app/master/selfhosted.go b/cmd/kubeadm/app/master/selfhosted.go index b42de843da9e8..9f8f83b6510a4 100644 --- a/cmd/kubeadm/app/master/selfhosted.go +++ b/cmd/kubeadm/app/master/selfhosted.go @@ -19,7 +19,7 @@ package master import ( "fmt" "os" - "path" + "path/filepath" "time" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -338,5 +338,5 @@ func getSchedulerDeployment(cfg *kubeadmapi.MasterConfiguration, volumes []v1.Vo } func buildStaticManifestFilepath(name string) string { - return path.Join(kubeadmapi.GlobalEnvParams.KubernetesDir, "manifests", name+".yaml") + return filepath.Join(kubeadmapi.GlobalEnvParams.KubernetesDir, "manifests", name+".yaml") } diff --git a/cmd/kubeadm/app/phases/apiconfig/clusterroles.go b/cmd/kubeadm/app/phases/apiconfig/clusterroles.go index 795c4d272e883..08e8910da473a 100644 --- a/cmd/kubeadm/app/phases/apiconfig/clusterroles.go +++ b/cmd/kubeadm/app/phases/apiconfig/clusterroles.go @@ -35,32 +35,16 @@ const ( // BootstrapSignerClusterRoleName sets the name for the ClusterRole that allows access to ConfigMaps in the kube-public ns BootstrapSignerClusterRoleName = "system:bootstrap-signer-clusterinfo" - // Constants - clusterRoleKind = "ClusterRole" - roleKind = "Role" - serviceAccountKind = "ServiceAccount" - rbacAPIGroup = "rbac.authorization.k8s.io" - anonymousUser = "system:anonymous" + clusterRoleKind = "ClusterRole" + roleKind = "Role" + serviceAccountKind = "ServiceAccount" + rbacAPIGroup = "rbac.authorization.k8s.io" + anonymousUser = "system:anonymous" + nodeAutoApproveBootstrap = "kubeadm:node-autoapprove-bootstrap" ) // TODO: Are there any unit tests that could be made for this file other than duplicating all values and logic in a separate file? -// CreateRBACRules creates the essential RBAC rules for a minimally set-up cluster -func CreateRBACRules(clientset *clientset.Clientset) error { - if err := CreateRoles(clientset); err != nil { - return err - } - if err := CreateRoleBindings(clientset); err != nil { - return err - } - if err := CreateClusterRoleBindings(clientset); err != nil { - return err - } - - fmt.Println("[apiconfig] Created RBAC rules") - return nil -} - // CreateServiceAccounts creates the necessary serviceaccounts that kubeadm uses/might use. func CreateServiceAccounts(clientset *clientset.Clientset) error { serviceAccounts := []v1.ServiceAccount{ @@ -86,8 +70,26 @@ func CreateServiceAccounts(clientset *clientset.Clientset) error { return nil } -// CreateRoles creates namespaces RBAC Roles -func CreateRoles(clientset *clientset.Clientset) error { +// CreateRBACRules creates the essential RBAC rules for a minimally set-up cluster +func CreateRBACRules(clientset *clientset.Clientset) error { + if err := createRoles(clientset); err != nil { + return err + } + if err := createRoleBindings(clientset); err != nil { + return err + } + if err := createClusterRoles(clientset); err != nil { + return err + } + if err := createClusterRoleBindings(clientset); err != nil { + return err + } + + fmt.Println("[apiconfig] Created RBAC rules") + return nil +} + +func createRoles(clientset *clientset.Clientset) error { roles := []rbac.Role{ { ObjectMeta: metav1.ObjectMeta{ @@ -107,8 +109,7 @@ func CreateRoles(clientset *clientset.Clientset) error { return nil } -// CreateRoleBindings creates all namespaced and necessary bindings between bootstrapped & kubeadm-created ClusterRoles and subjects kubeadm is using -func CreateRoleBindings(clientset *clientset.Clientset) error { +func createRoleBindings(clientset *clientset.Clientset) error { roleBindings := []rbac.RoleBinding{ { ObjectMeta: metav1.ObjectMeta{ @@ -137,8 +138,27 @@ func CreateRoleBindings(clientset *clientset.Clientset) error { return nil } -// CreateClusterRoleBindings creates all necessary bindings between bootstrapped & kubeadm-created ClusterRoles and subjects kubeadm is using -func CreateClusterRoleBindings(clientset *clientset.Clientset) error { +func createClusterRoles(clientset *clientset.Clientset) error { + clusterRoles := []rbac.ClusterRole{ + { + ObjectMeta: metav1.ObjectMeta{ + Name: nodeAutoApproveBootstrap, + }, + Rules: []rbac.PolicyRule{ + rbac.NewRule("create").Groups("certificates.k8s.io").Resources("certificatesigningrequests/nodeclient").RuleOrDie(), + }, + }, + } + + for _, roleBinding := range clusterRoles { + if _, err := clientset.RbacV1beta1().ClusterRoles().Create(&roleBinding); err != nil { + return err + } + } + return nil +} + +func createClusterRoleBindings(clientset *clientset.Clientset) error { clusterRoleBindings := []rbac.ClusterRoleBinding{ { ObjectMeta: metav1.ObjectMeta{ @@ -156,6 +176,22 @@ func CreateClusterRoleBindings(clientset *clientset.Clientset) error { }, }, }, + { + ObjectMeta: metav1.ObjectMeta{ + Name: nodeAutoApproveBootstrap, + }, + RoleRef: rbac.RoleRef{ + APIGroup: rbacAPIGroup, + Kind: clusterRoleKind, + Name: nodeAutoApproveBootstrap, + }, + Subjects: []rbac.Subject{ + { + Kind: "Group", + Name: bootstrapapi.BootstrapGroup, + }, + }, + }, { ObjectMeta: metav1.ObjectMeta{ Name: "kubeadm:node-proxier", diff --git a/cmd/kubeadm/app/phases/certs/pkiutil/pki_helpers.go b/cmd/kubeadm/app/phases/certs/pkiutil/pki_helpers.go index 94ddf73378881..d9587bf69246b 100644 --- a/cmd/kubeadm/app/phases/certs/pkiutil/pki_helpers.go +++ b/cmd/kubeadm/app/phases/certs/pkiutil/pki_helpers.go @@ -21,7 +21,7 @@ import ( "crypto/x509" "fmt" "os" - "path" + "path/filepath" "time" certutil "k8s.io/client-go/util/cert" @@ -198,13 +198,13 @@ func pathsForCertAndKey(pkiPath, name string) (string, string) { } func pathForCert(pkiPath, name string) string { - return path.Join(pkiPath, fmt.Sprintf("%s.crt", name)) + return filepath.Join(pkiPath, fmt.Sprintf("%s.crt", name)) } func pathForKey(pkiPath, name string) string { - return path.Join(pkiPath, fmt.Sprintf("%s.key", name)) + return filepath.Join(pkiPath, fmt.Sprintf("%s.key", name)) } func pathForPublicKey(pkiPath, name string) string { - return path.Join(pkiPath, fmt.Sprintf("%s.pub", name)) + return filepath.Join(pkiPath, fmt.Sprintf("%s.pub", name)) } diff --git a/cmd/kubelet/app/BUILD b/cmd/kubelet/app/BUILD index c29b3791ea52f..0202f3d5b0fe7 100644 --- a/cmd/kubelet/app/BUILD +++ b/cmd/kubelet/app/BUILD @@ -92,6 +92,7 @@ go_library( "//pkg/volume/glusterfs:go_default_library", "//pkg/volume/host_path:go_default_library", "//pkg/volume/iscsi:go_default_library", + "//pkg/volume/local:go_default_library", "//pkg/volume/nfs:go_default_library", "//pkg/volume/photon_pd:go_default_library", "//pkg/volume/portworx:go_default_library", diff --git a/cmd/kubelet/app/options/BUILD b/cmd/kubelet/app/options/BUILD index ff9f0bd3d02ec..7a94cb918ce57 100644 --- a/cmd/kubelet/app/options/BUILD +++ b/cmd/kubelet/app/options/BUILD @@ -9,7 +9,10 @@ load( go_library( name = "go_default_library", - srcs = ["options.go"], + srcs = [ + "container_runtime.go", + "options.go", + ], tags = ["automanaged"], deps = [ "//pkg/api:go_default_library", @@ -18,6 +21,7 @@ go_library( "//pkg/apis/componentconfig/v1alpha1:go_default_library", "//pkg/util/taints:go_default_library", "//vendor/github.com/spf13/pflag:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apiserver/pkg/util/feature:go_default_library", "//vendor/k8s.io/apiserver/pkg/util/flag:go_default_library", ], diff --git a/cmd/kubelet/app/options/container_runtime.go b/cmd/kubelet/app/options/container_runtime.go new file mode 100644 index 0000000000000..e2cb5477ec578 --- /dev/null +++ b/cmd/kubelet/app/options/container_runtime.go @@ -0,0 +1,145 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package options + +import ( + "runtime" + "time" + + "github.com/spf13/pflag" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +const ( + // When these values are updated, also update test/e2e/framework/util.go + defaultPodSandboxImageName = "gcr.io/google_containers/pause" + defaultPodSandboxImageVersion = "3.0" + // From pkg/kubelet/rkt/rkt.go to avoid circular import + defaultRktAPIServiceEndpoint = "localhost:15441" +) + +var ( + defaultPodSandboxImage = defaultPodSandboxImageName + + "-" + runtime.GOARCH + ":" + + defaultPodSandboxImageVersion +) + +type ContainerRuntimeOptions struct { + // Docker-specific options. + + // DockershimRootDirectory is the path to the dockershim root directory. Defaults to + // /var/lib/dockershim if unset. Exposed for integration testing (e.g. in OpenShift). + DockershimRootDirectory string + // Enable dockershim only mode. + ExperimentalDockershim bool + // This flag, if set, disables use of a shared PID namespace for pods running in the docker CRI runtime. + // A shared PID namespace is the only option in non-docker runtimes and is required by the CRI. The ability to + // disable it for docker will be removed unless a compelling use case is discovered with widespread use. + // TODO: Remove once we no longer support disabling shared PID namespace (https://issues.k8s.io/41938) + DockerDisableSharedPID bool + // PodSandboxImage is the image whose network/ipc namespaces + // containers in each pod will use. + PodSandboxImage string + // DockerEndpoint is the path to the docker endpoint to communicate with. + DockerEndpoint string + // DockerExecHandlerName is the handler to use when executing a command + // in a container. Valid values are 'native' and 'nsenter'. Defaults to + // 'native'. + DockerExecHandlerName string + // If no pulling progress is made before the deadline imagePullProgressDeadline, + // the image pulling will be cancelled. Defaults to 1m0s. + // +optional + ImagePullProgressDeadline metav1.Duration + + // Network plugin options. + + // networkPluginName is the name of the network plugin to be invoked for + // various events in kubelet/pod lifecycle + NetworkPluginName string + // NetworkPluginMTU is the MTU to be passed to the network plugin, + // and overrides the default MTU for cases where it cannot be automatically + // computed (such as IPSEC). + NetworkPluginMTU int32 + // NetworkPluginDir is the full path of the directory in which to search + // for network plugins (and, for backwards-compat, CNI config files) + NetworkPluginDir string + // CNIConfDir is the full path of the directory in which to search for + // CNI config files + CNIConfDir string + // CNIBinDir is the full path of the directory in which to search for + // CNI plugin binaries + CNIBinDir string + + // rkt-specific options. + + // rktPath is the path of rkt binary. Leave empty to use the first rkt in $PATH. + RktPath string + // rktApiEndpoint is the endpoint of the rkt API service to communicate with. + RktAPIEndpoint string + // rktStage1Image is the image to use as stage1. Local paths and + // http/https URLs are supported. + RktStage1Image string +} + +// NewContainerRuntimeOptions will create a new ContainerRuntimeOptions with +// default values. +func NewContainerRuntimeOptions() *ContainerRuntimeOptions { + dockerEndpoint := "" + if runtime.GOOS != "windows" { + dockerEndpoint = "unix:///var/run/docker.sock" + } + + return &ContainerRuntimeOptions{ + DockerEndpoint: dockerEndpoint, + DockershimRootDirectory: "/var/lib/dockershim", + DockerExecHandlerName: "native", + PodSandboxImage: defaultPodSandboxImage, + ImagePullProgressDeadline: metav1.Duration{Duration: 1 * time.Minute}, + RktAPIEndpoint: defaultRktAPIServiceEndpoint, + ExperimentalDockershim: false, + } +} + +func (s *ContainerRuntimeOptions) AddFlags(fs *pflag.FlagSet) { + // Docker-specific settings. + fs.BoolVar(&s.ExperimentalDockershim, "experimental-dockershim", s.ExperimentalDockershim, "Enable dockershim only mode. In this mode, kubelet will only start dockershim without any other functionalities. This flag only serves test purpose, please do not use it unless you are conscious of what you are doing. [default=false]") + fs.MarkHidden("experimental-dockershim") + fs.StringVar(&s.DockershimRootDirectory, "experimental-dockershim-root-directory", s.DockershimRootDirectory, "Path to the dockershim root directory.") + fs.MarkHidden("experimental-dockershim-root-directory") + fs.BoolVar(&s.DockerDisableSharedPID, "docker-disable-shared-pid", s.DockerDisableSharedPID, "The Container Runtime Interface (CRI) defaults to using a shared PID namespace for containers in a pod when running with Docker 1.13.1 or higher. Setting this flag reverts to the previous behavior of isolated PID namespaces. This ability will be removed in a future Kubernetes release.") + fs.StringVar(&s.PodSandboxImage, "pod-infra-container-image", s.PodSandboxImage, "The image whose network/ipc namespaces containers in each pod will use.") + fs.StringVar(&s.DockerEndpoint, "docker-endpoint", s.DockerEndpoint, "Use this for the docker endpoint to communicate with") + // TODO(#40229): Remove the docker-exec-handler flag. + fs.StringVar(&s.DockerExecHandlerName, "docker-exec-handler", s.DockerExecHandlerName, "Handler to use when executing a command in a container. Valid values are 'native' and 'nsenter'. Defaults to 'native'.") + fs.MarkDeprecated("docker-exec-handler", "this flag will be removed and only the 'native' handler will be supported in the future.") + fs.DurationVar(&s.ImagePullProgressDeadline.Duration, "image-pull-progress-deadline", s.ImagePullProgressDeadline.Duration, "If no pulling progress is made before this deadline, the image pulling will be cancelled.") + + // Network plugin settings. Shared by both docker and rkt. + fs.StringVar(&s.NetworkPluginName, "network-plugin", s.NetworkPluginName, " The name of the network plugin to be invoked for various events in kubelet/pod lifecycle") + fs.StringVar(&s.NetworkPluginDir, "network-plugin-dir", s.NetworkPluginDir, " The full path of the directory in which to search for network plugins or CNI config") + fs.StringVar(&s.CNIConfDir, "cni-conf-dir", s.CNIConfDir, " The full path of the directory in which to search for CNI config files. Default: /etc/cni/net.d") + fs.StringVar(&s.CNIBinDir, "cni-bin-dir", s.CNIBinDir, " The full path of the directory in which to search for CNI plugin binaries. Default: /opt/cni/bin") + fs.Int32Var(&s.NetworkPluginMTU, "network-plugin-mtu", s.NetworkPluginMTU, " The MTU to be passed to the network plugin, to override the default. Set to 0 to use the default 1460 MTU.") + + // Rkt-specific settings. + fs.StringVar(&s.RktPath, "rkt-path", s.RktPath, "Path of rkt binary. Leave empty to use the first rkt in $PATH. Only used if --container-runtime='rkt'.") + fs.StringVar(&s.RktAPIEndpoint, "rkt-api-endpoint", s.RktAPIEndpoint, "The endpoint of the rkt API service to communicate with. Only used if --container-runtime='rkt'.") + fs.StringVar(&s.RktStage1Image, "rkt-stage1-image", s.RktStage1Image, "image to use as stage1. Local paths and http/https URLs are supported. If empty, the 'stage1.aci' in the same directory as '--rkt-path' will be used.") + fs.MarkDeprecated("rkt-stage1-image", "Will be removed in a future version. The default stage1 image will be specified by the rkt configurations, see https://github.com/coreos/rkt/blob/master/Documentation/configuration.md for more details.") + +} diff --git a/cmd/kubelet/app/options/options.go b/cmd/kubelet/app/options/options.go index 5e22c58e7b4b6..b5dc81df4afed 100644 --- a/cmd/kubelet/app/options/options.go +++ b/cmd/kubelet/app/options/options.go @@ -74,13 +74,12 @@ type KubeletFlags struct { // If set, kubelet will use this IP address for the node. NodeIP string - // DockershimRootDirectory is the path to the dockershim root directory. Defaults to - // /var/lib/dockershim if unset. Exposed for integration testing (e.g. in OpenShift). - DockershimRootDirectory string - // This flag, if set, sets the unique id of the instance that an external provider (i.e. cloudprovider) // can use to identify a specific node ProviderID string + + // Container-runtime-specific options. + ContainerRuntimeOptions } // KubeletServer encapsulates all of the parameters necessary for starting up @@ -100,7 +99,7 @@ func NewKubeletServer() *KubeletServer { KubeletFlags: KubeletFlags{ KubeConfig: flag.NewStringFlag("/var/lib/kubelet/kubeconfig"), RequireKubeConfig: false, - DockershimRootDirectory: "/var/lib/dockershim", + ContainerRuntimeOptions: *NewContainerRuntimeOptions(), }, KubeletConfiguration: config, } @@ -111,13 +110,14 @@ type kubeletConfiguration componentconfig.KubeletConfiguration // AddFlags adds flags for a specific KubeletServer to the specified FlagSet func (s *KubeletServer) AddFlags(fs *pflag.FlagSet) { var kc *kubeletConfiguration = (*kubeletConfiguration)(&s.KubeletConfiguration) - s.KubeletFlags.AddFlags(fs) kc.addFlags(fs) } // AddFlags adds flags for a specific KubeletFlags to the specified FlagSet func (f *KubeletFlags) AddFlags(fs *pflag.FlagSet) { + f.ContainerRuntimeOptions.AddFlags(fs) + fs.Var(&f.KubeConfig, "kubeconfig", "Path to a kubeconfig file, specifying how to connect to the API server. --api-servers will be used for the location unless --require-kubeconfig is set.") fs.BoolVar(&f.RequireKubeConfig, "require-kubeconfig", f.RequireKubeConfig, "If true the Kubelet will exit if there are configuration errors, and will ignore the value of --api-servers in favor of the server defined in the kubeconfig file.") @@ -139,9 +139,7 @@ func (f *KubeletFlags) AddFlags(fs *pflag.FlagSet) { fs.StringVar(&f.NodeIP, "node-ip", f.NodeIP, "IP address of the node. If set, kubelet will use this IP address for the node") - fs.StringVar(&f.DockershimRootDirectory, "experimental-dockershim-root-directory", f.DockershimRootDirectory, "Path to the dockershim root directory.") fs.StringVar(&f.ProviderID, "provider-id", f.ProviderID, "Unique identifier for identifying the node in a machine database, i.e cloudprovider") - fs.MarkHidden("experimental-dockershim-root-directory") } // addFlags adds flags for a specific componentconfig.KubeletConfiguration to the specified FlagSet @@ -190,8 +188,6 @@ func (c *kubeletConfiguration) addFlags(fs *pflag.FlagSet) { fs.StringVar(&c.CertDirectory, "cert-dir", c.CertDirectory, "The directory where the TLS certs are located. "+ "If --tls-cert-file and --tls-private-key-file are provided, this flag will be ignored.") - fs.StringVar(&c.PodInfraContainerImage, "pod-infra-container-image", c.PodInfraContainerImage, "The image whose network/ipc namespaces containers in each pod will use.") - fs.StringVar(&c.DockerEndpoint, "docker-endpoint", c.DockerEndpoint, "Use this for the docker endpoint to communicate with") fs.StringVar(&c.RootDirectory, "root-dir", c.RootDirectory, "Directory path for managing kubelet files (volume mounts,etc).") fs.StringVar(&c.SeccompProfileRoot, "seccomp-profile-root", c.SeccompProfileRoot, "Directory path for seccomp profiles.") fs.BoolVar(&c.AllowPrivileged, "allow-privileged", c.AllowPrivileged, "If true, allow containers to request privileged mode.") @@ -231,11 +227,6 @@ func (c *kubeletConfiguration) addFlags(fs *pflag.FlagSet) { fs.Int32Var(&c.LowDiskSpaceThresholdMB, "low-diskspace-threshold-mb", c.LowDiskSpaceThresholdMB, "The absolute free disk space, in MB, to maintain. When disk space falls below this threshold, new pods would be rejected.") fs.MarkDeprecated("low-diskspace-threshold-mb", "Use --eviction-hard instead. Will be removed in a future version.") fs.DurationVar(&c.VolumeStatsAggPeriod.Duration, "volume-stats-agg-period", c.VolumeStatsAggPeriod.Duration, "Specifies interval for kubelet to calculate and cache the volume disk usage for all pods and volumes. To disable volume calculations, set to 0.") - fs.StringVar(&c.NetworkPluginName, "network-plugin", c.NetworkPluginName, " The name of the network plugin to be invoked for various events in kubelet/pod lifecycle") - fs.StringVar(&c.NetworkPluginDir, "network-plugin-dir", c.NetworkPluginDir, " The full path of the directory in which to search for network plugins or CNI config") - fs.StringVar(&c.CNIConfDir, "cni-conf-dir", c.CNIConfDir, " The full path of the directory in which to search for CNI config files. Default: /etc/cni/net.d") - fs.StringVar(&c.CNIBinDir, "cni-bin-dir", c.CNIBinDir, " The full path of the directory in which to search for CNI plugin binaries. Default: /opt/cni/bin") - fs.Int32Var(&c.NetworkPluginMTU, "network-plugin-mtu", c.NetworkPluginMTU, " The MTU to be passed to the network plugin, to override the default. Set to 0 to use the default 1460 MTU.") fs.StringVar(&c.VolumePluginDir, "volume-plugin-dir", c.VolumePluginDir, " The full path of the directory in which to search for additional third party volume plugins") fs.StringVar(&c.CloudProvider, "cloud-provider", c.CloudProvider, "The provider for cloud services. By default, kubelet will attempt to auto-detect the cloud provider. Specify empty string for running with no cloud provider.") fs.StringVar(&c.CloudConfigFile, "cloud-config", c.CloudConfigFile, "The path to the cloud provider configuration file. Empty string for no configuration file.") @@ -250,20 +241,13 @@ func (c *kubeletConfiguration) addFlags(fs *pflag.FlagSet) { fs.StringVar(&c.CgroupRoot, "cgroup-root", c.CgroupRoot, "Optional root cgroup to use for pods. This is handled by the container runtime on a best effort basis. Default: '', which means use the container runtime default.") fs.StringVar(&c.ContainerRuntime, "container-runtime", c.ContainerRuntime, "The container runtime to use. Possible values: 'docker', 'rkt'.") fs.DurationVar(&c.RuntimeRequestTimeout.Duration, "runtime-request-timeout", c.RuntimeRequestTimeout.Duration, "Timeout of all runtime requests except long running request - pull, logs, exec and attach. When timeout exceeded, kubelet will cancel the request, throw out an error and retry later.") - fs.DurationVar(&c.ImagePullProgressDeadline.Duration, "image-pull-progress-deadline", c.ImagePullProgressDeadline.Duration, "If no pulling progress is made before this deadline, the image pulling will be cancelled.") fs.StringVar(&c.LockFilePath, "lock-file", c.LockFilePath, " The path to file for kubelet to use as a lock file.") fs.BoolVar(&c.ExitOnLockContention, "exit-on-lock-contention", c.ExitOnLockContention, "Whether kubelet should exit upon lock-file contention.") - fs.StringVar(&c.RktPath, "rkt-path", c.RktPath, "Path of rkt binary. Leave empty to use the first rkt in $PATH. Only used if --container-runtime='rkt'.") fs.StringVar(&c.ExperimentalMounterPath, "experimental-mounter-path", c.ExperimentalMounterPath, "[Experimental] Path of mounter binary. Leave empty to use the default mount.") - fs.StringVar(&c.RktAPIEndpoint, "rkt-api-endpoint", c.RktAPIEndpoint, "The endpoint of the rkt API service to communicate with. Only used if --container-runtime='rkt'.") - fs.StringVar(&c.RktStage1Image, "rkt-stage1-image", c.RktStage1Image, "image to use as stage1. Local paths and http/https URLs are supported. If empty, the 'stage1.aci' in the same directory as '--rkt-path' will be used.") - fs.MarkDeprecated("rkt-stage1-image", "Will be removed in a future version. The default stage1 image will be specified by the rkt configurations, see https://github.com/coreos/rkt/blob/master/Documentation/configuration.md for more details.") fs.StringVar(&c.HairpinMode, "hairpin-mode", c.HairpinMode, "How should the kubelet setup hairpin NAT. This allows endpoints of a Service to loadbalance back to themselves if they should try to access their own Service. Valid values are \"promiscuous-bridge\", \"hairpin-veth\" and \"none\".") fs.Int32Var(&c.MaxPods, "max-pods", c.MaxPods, "Number of Pods that can run on this Kubelet.") - // TODO(#40229): Remove the docker-exec-handler flag. - fs.StringVar(&c.DockerExecHandlerName, "docker-exec-handler", c.DockerExecHandlerName, "Handler to use when executing a command in a container. Valid values are 'native' and 'nsenter'.") - fs.MarkDeprecated("docker-exec-handler", "this flag will be removed and only the 'native' handler will be supported in the future.") - fs.StringVar(&c.NonMasqueradeCIDR, "non-masquerade-cidr", c.NonMasqueradeCIDR, "Traffic to IPs outside this range will use IP masquerade.") + fs.StringVar(&c.NonMasqueradeCIDR, "non-masquerade-cidr", c.NonMasqueradeCIDR, "Traffic to IPs outside this range will use IP masquerade. Set to '0.0.0.0/0' to never masquerade.") + fs.MarkDeprecated("non-masquerade-cidr", "will be removed in a future version") fs.StringVar(&c.PodCIDR, "pod-cidr", "", "The CIDR to use for pod IP addresses, only used in standalone mode. In cluster mode, this is obtained from the master.") fs.StringVar(&c.ResolverConfig, "resolv-conf", c.ResolverConfig, "Resolver configuration file used as the basis for the container DNS resolution configuration.") fs.BoolVar(&c.CPUCFSQuota, "cpu-cfs-quota", c.CPUCFSQuota, "Enable CPU CFS quota enforcement for containers that specify CPU limits") @@ -278,7 +262,7 @@ func (c *kubeletConfiguration) addFlags(fs *pflag.FlagSet) { fs.Int64Var(&c.MaxOpenFiles, "max-open-files", c.MaxOpenFiles, "Number of files that can be opened by Kubelet process.") fs.BoolVar(&c.RegisterSchedulable, "register-schedulable", c.RegisterSchedulable, "Register the node as schedulable. Won't have any effect if register-node is false.") fs.MarkDeprecated("register-schedulable", "will be removed in a future version") - fs.Var(utiltaints.NewTaintsVar(&c.RegisterWithTaints), "register-with-taints", "Register the node with the given list of taints (comma seperated \"=:\"). No-op if register-node is false.") + fs.Var(utiltaints.NewTaintsVar(&c.RegisterWithTaints), "register-with-taints", "Register the node with the given list of taints (comma separated \"=:\"). No-op if register-node is false.") fs.StringVar(&c.ContentType, "kube-api-content-type", c.ContentType, "Content type of requests sent to apiserver.") fs.Int32Var(&c.KubeAPIQPS, "kube-api-qps", c.KubeAPIQPS, "QPS to use while talking with kubernetes apiserver") fs.Int32Var(&c.KubeAPIBurst, "kube-api-burst", c.KubeAPIBurst, "Burst to use while talking with kubernetes apiserver") @@ -300,11 +284,8 @@ func (c *kubeletConfiguration) addFlags(fs *pflag.FlagSet) { fs.BoolVar(&c.KeepTerminatedPodVolumes, "keep-terminated-pod-volumes", c.KeepTerminatedPodVolumes, "Keep terminated pod volumes mounted to the node after the pod terminates. Can be useful for debugging volume related issues.") // CRI flags. - fs.BoolVar(&c.ExperimentalDockershim, "experimental-dockershim", c.ExperimentalDockershim, "Enable dockershim only mode. In this mode, kubelet will only start dockershim without any other functionalities. This flag only serves test purpose, please do not use it unless you are conscious of what you are doing. [default=false]") - fs.MarkHidden("experimental-dockershim") - fs.StringVar(&c.RemoteRuntimeEndpoint, "container-runtime-endpoint", c.RemoteRuntimeEndpoint, "[Experimental] The unix socket endpoint of remote runtime service.") - fs.StringVar(&c.RemoteImageEndpoint, "image-service-endpoint", c.RemoteImageEndpoint, "[Experimental] The unix socket endpoint of remote image service. If not specified, it will be the same with container-runtime-endpoint by default.") - fs.BoolVar(&c.DockerDisableSharedPID, "docker-disable-shared-pid", c.DockerDisableSharedPID, "The Container Runtime Interface (CRI) defaults to using a shared PID namespace for containers in a pod when running with Docker 1.13.1 or higher. Setting this flag reverts to the previous behavior of isolated PID namespaces. This ability will be removed in a future Kubernetes release.") + fs.StringVar(&c.RemoteRuntimeEndpoint, "container-runtime-endpoint", c.RemoteRuntimeEndpoint, "[Experimental] The endpoint of remote runtime service. Currently unix socket is supported on Linux, and tcp is supported on windows. Examples:'unix:///var/run/dockershim.sock', 'tcp://localhost:3735'") + fs.StringVar(&c.RemoteImageEndpoint, "image-service-endpoint", c.RemoteImageEndpoint, "[Experimental] The endpoint of remote image service. If not specified, it will be the same with container-runtime-endpoint by default. Currently unix socket is supported on Linux, and tcp is supported on windows. Examples:'unix:///var/run/dockershim.sock', 'tcp://localhost:3735'") fs.BoolVar(&c.ExperimentalCheckNodeCapabilitiesBeforeMount, "experimental-check-node-capabilities-before-mount", c.ExperimentalCheckNodeCapabilitiesBeforeMount, "[Experimental] if set true, the kubelet will check the underlying node for required componenets (binaries, etc.) before performing the mount") diff --git a/cmd/kubelet/app/plugins.go b/cmd/kubelet/app/plugins.go index 10be1927d7edf..be45e063d49af 100644 --- a/cmd/kubelet/app/plugins.go +++ b/cmd/kubelet/app/plugins.go @@ -45,6 +45,7 @@ import ( "k8s.io/kubernetes/pkg/volume/glusterfs" "k8s.io/kubernetes/pkg/volume/host_path" "k8s.io/kubernetes/pkg/volume/iscsi" + "k8s.io/kubernetes/pkg/volume/local" "k8s.io/kubernetes/pkg/volume/nfs" "k8s.io/kubernetes/pkg/volume/photon_pd" "k8s.io/kubernetes/pkg/volume/portworx" @@ -95,6 +96,7 @@ func ProbeVolumePlugins(pluginDir string) []volume.VolumePlugin { allPlugins = append(allPlugins, projected.ProbeVolumePlugins()...) allPlugins = append(allPlugins, portworx.ProbeVolumePlugins()...) allPlugins = append(allPlugins, scaleio.ProbeVolumePlugins()...) + allPlugins = append(allPlugins, local.ProbeVolumePlugins()...) return allPlugins } diff --git a/cmd/kubelet/app/server.go b/cmd/kubelet/app/server.go index d2a6cf31b491a..6d23dc92568ec 100644 --- a/cmd/kubelet/app/server.go +++ b/cmd/kubelet/app/server.go @@ -288,7 +288,6 @@ func initKubeletConfigSync(s *options.KubeletServer) (*componentconfig.KubeletCo func Run(s *options.KubeletServer, kubeDeps *kubelet.KubeletDeps) error { if err := run(s, kubeDeps); err != nil { return fmt.Errorf("failed to run Kubelet: %v", err) - } return nil } @@ -623,7 +622,7 @@ func getNodeName(cloud cloudprovider.Interface, hostname string) (types.NodeName // InitializeTLS checks for a configured TLSCertFile and TLSPrivateKeyFile: if unspecified a new self-signed // certificate and key file are generated. Returns a configured server.TLSOptions object. func InitializeTLS(kf *options.KubeletFlags, kc *componentconfig.KubeletConfiguration) (*server.TLSOptions, error) { - if kc.TLSCertFile == "" && kc.TLSPrivateKeyFile == "" { + if !utilfeature.DefaultFeatureGate.Enabled(features.RotateKubeletServerCertificate) && kc.TLSCertFile == "" && kc.TLSPrivateKeyFile == "" { kc.TLSCertFile = path.Join(kc.CertDirectory, "kubelet.crt") kc.TLSPrivateKeyFile = path.Join(kc.CertDirectory, "kubelet.key") @@ -810,7 +809,7 @@ func RunKubelet(kubeFlags *options.KubeletFlags, kubeCfg *componentconfig.Kubele if kubeDeps.OSInterface == nil { kubeDeps.OSInterface = kubecontainer.RealOS{} } - k, err := builder(kubeCfg, kubeDeps, standaloneMode, kubeFlags.HostnameOverride, kubeFlags.NodeIP, kubeFlags.DockershimRootDirectory, kubeFlags.ProviderID) + k, err := builder(kubeCfg, kubeDeps, &kubeFlags.ContainerRuntimeOptions, standaloneMode, kubeFlags.HostnameOverride, kubeFlags.NodeIP, kubeFlags.ProviderID) if err != nil { return fmt.Errorf("failed to create kubelet: %v", err) } @@ -890,11 +889,11 @@ func startKubelet(k kubelet.KubeletBootstrap, podCfg *config.PodConfig, kubeCfg } } -func CreateAndInitKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *kubelet.KubeletDeps, standaloneMode bool, hostnameOverride, nodeIP, dockershimRootDir, providerID string) (k kubelet.KubeletBootstrap, err error) { +func CreateAndInitKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *kubelet.KubeletDeps, crOptions *options.ContainerRuntimeOptions, standaloneMode bool, hostnameOverride, nodeIP, providerID string) (k kubelet.KubeletBootstrap, err error) { // TODO: block until all sources have delivered at least one update to the channel, or break the sync loop // up into "per source" synchronizations - k, err = kubelet.NewMainKubelet(kubeCfg, kubeDeps, standaloneMode, hostnameOverride, nodeIP, dockershimRootDir, providerID) + k, err = kubelet.NewMainKubelet(kubeCfg, kubeDeps, crOptions, standaloneMode, hostnameOverride, nodeIP, providerID) if err != nil { return nil, err } @@ -934,24 +933,24 @@ func parseResourceList(m componentconfig.ConfigurationMap) (v1.ResourceList, err // RunDockershim only starts the dockershim in current process. This is only used for cri validate testing purpose // TODO(random-liu): Move this to a separate binary. -func RunDockershim(c *componentconfig.KubeletConfiguration, dockershimRootDir string) error { +func RunDockershim(c *componentconfig.KubeletConfiguration, r *options.ContainerRuntimeOptions) error { // Create docker client. - dockerClient := libdocker.ConnectToDockerOrDie(c.DockerEndpoint, c.RuntimeRequestTimeout.Duration, - c.ImagePullProgressDeadline.Duration) + dockerClient := libdocker.ConnectToDockerOrDie(r.DockerEndpoint, c.RuntimeRequestTimeout.Duration, + r.ImagePullProgressDeadline.Duration) // Initialize network plugin settings. - binDir := c.CNIBinDir + binDir := r.CNIBinDir if binDir == "" { - binDir = c.NetworkPluginDir + binDir = r.NetworkPluginDir } nh := &kubelet.NoOpLegacyHost{} pluginSettings := dockershim.NetworkPluginSettings{ HairpinMode: componentconfig.HairpinMode(c.HairpinMode), NonMasqueradeCIDR: c.NonMasqueradeCIDR, - PluginName: c.NetworkPluginName, - PluginConfDir: c.CNIConfDir, + PluginName: r.NetworkPluginName, + PluginConfDir: r.CNIConfDir, PluginBinDir: binDir, - MTU: int(c.NetworkPluginMTU), + MTU: int(r.NetworkPluginMTU), LegacyRuntimeHost: nh, } @@ -965,9 +964,9 @@ func RunDockershim(c *componentconfig.KubeletConfiguration, dockershimRootDir st SupportedPortForwardProtocols: streaming.DefaultConfig.SupportedPortForwardProtocols, } - ds, err := dockershim.NewDockerService(dockerClient, c.SeccompProfileRoot, c.PodInfraContainerImage, - streamingConfig, &pluginSettings, c.RuntimeCgroups, c.CgroupDriver, c.DockerExecHandlerName, dockershimRootDir, - c.DockerDisableSharedPID) + ds, err := dockershim.NewDockerService(dockerClient, c.SeccompProfileRoot, r.PodSandboxImage, + streamingConfig, &pluginSettings, c.RuntimeCgroups, c.CgroupDriver, r.DockerExecHandlerName, r.DockershimRootDirectory, + r.DockerDisableSharedPID) if err != nil { return err } @@ -975,14 +974,8 @@ func RunDockershim(c *componentconfig.KubeletConfiguration, dockershimRootDir st return err } - // The unix socket for kubelet <-> dockershim communication. - ep := c.RemoteRuntimeEndpoint - if len(ep) == 0 { - ep = "/var/run/dockershim.sock" - } - glog.V(2).Infof("Starting the GRPC server for the docker CRI shim.") - server := dockerremote.NewDockerServer(ep, ds) + server := dockerremote.NewDockerServer(c.RemoteRuntimeEndpoint, ds) if err := server.Start(); err != nil { return err } diff --git a/cmd/kubelet/kubelet.go b/cmd/kubelet/kubelet.go index c88a3f3ad3b52..b9f1b5fc1774a 100644 --- a/cmd/kubelet/kubelet.go +++ b/cmd/kubelet/kubelet.go @@ -46,7 +46,7 @@ func main() { verflag.PrintAndExitIfRequested() if s.ExperimentalDockershim { - if err := app.RunDockershim(&s.KubeletConfiguration, s.DockershimRootDirectory); err != nil { + if err := app.RunDockershim(&s.KubeletConfiguration, &s.ContainerRuntimeOptions); err != nil { fmt.Fprintf(os.Stderr, "error: %v\n", err) os.Exit(1) } diff --git a/cmd/libs/go2idl/client-gen/main.go b/cmd/libs/go2idl/client-gen/main.go index fa760bdcd622a..77ac1cf787266 100644 --- a/cmd/libs/go2idl/client-gen/main.go +++ b/cmd/libs/go2idl/client-gen/main.go @@ -36,6 +36,7 @@ var ( test = flag.BoolP("test", "t", false, "set this flag to generate the client code for the testdata") inputVersions = flag.StringSlice("input", []string{ "api/", + "admissionregistration/", "authentication/", "authorization/", "autoscaling/", @@ -47,6 +48,7 @@ var ( "apps/", "policy/", "settings/", + "networking/", }, "group/versions that client-gen will generate clients for. At most one version per group is allowed. Specified in the format \"group1/version1,group2/version2...\".") includedTypesOverrides = flag.StringSlice("included-types-overrides", []string{}, "list of group/version/type for which client should be generated. By default, client is generated for all types which have genclient=true in types.go. This overrides that. For each groupVersion in this list, only the types mentioned here will be included. The default check of genclient=true will be used for other group versions.") basePath = flag.String("input-base", "k8s.io/kubernetes/pkg/apis", "base path to look for the api group.") diff --git a/cmd/libs/go2idl/go-to-protobuf/protobuf/cmd.go b/cmd/libs/go2idl/go-to-protobuf/protobuf/cmd.go index e698803e01099..b33641bbb4542 100644 --- a/cmd/libs/go2idl/go-to-protobuf/protobuf/cmd.go +++ b/cmd/libs/go2idl/go-to-protobuf/protobuf/cmd.go @@ -91,6 +91,11 @@ func New() *Generator { `k8s.io/kubernetes/pkg/apis/storage/v1beta1`, `k8s.io/kubernetes/pkg/apis/storage/v1`, `k8s.io/kubernetes/pkg/apis/admission/v1alpha1`, + `k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1`, + `-k8s.io/client-go/pkg/api/v1`, + `k8s.io/metrics/pkg/apis/metrics/v1alpha1`, + `k8s.io/metrics/pkg/apis/custom_metrics/v1alpha1`, + `k8s.io/kubernetes/pkg/apis/networking/v1`, }, ","), DropEmbeddedFields: "k8s.io/apimachinery/pkg/apis/meta/v1.TypeMeta", } diff --git a/cmd/libs/go2idl/go-to-protobuf/protobuf/generator.go b/cmd/libs/go2idl/go-to-protobuf/protobuf/generator.go index 5e3ed2efe40ff..ed826b9c3be79 100644 --- a/cmd/libs/go2idl/go-to-protobuf/protobuf/generator.go +++ b/cmd/libs/go2idl/go-to-protobuf/protobuf/generator.go @@ -598,7 +598,7 @@ func protobufTagToField(tag string, field *protoField, m types.Member, t *types. protoExtra[parts[0]] = parts[1] case "casttype", "castkey", "castvalue": parts[0] = fmt.Sprintf("(gogoproto.%s)", parts[0]) - protoExtra[parts[0]] = parts[1] + protoExtra[parts[0]] = strconv.Quote(parts[1]) } } diff --git a/cmd/libs/go2idl/go-to-protobuf/protobuf/namer.go b/cmd/libs/go2idl/go-to-protobuf/protobuf/namer.go index 60060d4edf4fe..423577a12e99d 100644 --- a/cmd/libs/go2idl/go-to-protobuf/protobuf/namer.go +++ b/cmd/libs/go2idl/go-to-protobuf/protobuf/namer.go @@ -157,6 +157,21 @@ func assignGoTypeToProtoPackage(p *protobufPackage, t *types.Type, local, global } } +// isTypeApplicableToProtobuf checks to see if a type is relevant for protobuf processing. +// Currently, it filters out functions and private types. +func isTypeApplicableToProtobuf(t *types.Type) bool { + // skip functions -- we don't care about them for protobuf + if t.Kind == types.Func || (t.Kind == types.DeclarationOf && t.Underlying.Kind == types.Func) { + return false + } + // skip private types + if namer.IsPrivateGoName(t.Name.Name) { + return false + } + + return true +} + func (n *protobufNamer) AssignTypesToPackages(c *generator.Context) error { global := make(typeNameSet) for _, p := range n.packages { @@ -167,6 +182,10 @@ func (n *protobufNamer) AssignTypesToPackages(c *generator.Context) error { if t.Name.Package != p.PackagePath { continue } + if !isTypeApplicableToProtobuf(t) { + // skip types that we don't care about, like functions + continue + } assignGoTypeToProtoPackage(p, t, local, global, optional) } p.FilterTypes = make(map[types.Name]struct{}) diff --git a/docs/.generated_docs b/docs/.generated_docs index a288f3c408297..fd5cb22a43708 100644 --- a/docs/.generated_docs +++ b/docs/.generated_docs @@ -13,6 +13,7 @@ docs/man/man1/kube-scheduler.1 docs/man/man1/kubectl-annotate.1 docs/man/man1/kubectl-api-versions.1 docs/man/man1/kubectl-apiversions.1 +docs/man/man1/kubectl-apply-edit-last-applied.1 docs/man/man1/kubectl-apply-set-last-applied.1 docs/man/man1/kubectl-apply-view-last-applied.1 docs/man/man1/kubectl-apply.1 @@ -33,6 +34,7 @@ docs/man/man1/kubectl-config-delete-cluster.1 docs/man/man1/kubectl-config-delete-context.1 docs/man/man1/kubectl-config-get-clusters.1 docs/man/man1/kubectl-config-get-contexts.1 +docs/man/man1/kubectl-config-rename-context.1 docs/man/man1/kubectl-config-set-cluster.1 docs/man/man1/kubectl-config-set-context.1 docs/man/man1/kubectl-config-set-credentials.1 @@ -111,6 +113,7 @@ docs/user-guide/kubectl/kubectl.md docs/user-guide/kubectl/kubectl_annotate.md docs/user-guide/kubectl/kubectl_api-versions.md docs/user-guide/kubectl/kubectl_apply.md +docs/user-guide/kubectl/kubectl_apply_edit-last-applied.md docs/user-guide/kubectl/kubectl_apply_set-last-applied.md docs/user-guide/kubectl/kubectl_apply_view-last-applied.md docs/user-guide/kubectl/kubectl_attach.md @@ -129,6 +132,7 @@ docs/user-guide/kubectl/kubectl_config_delete-cluster.md docs/user-guide/kubectl/kubectl_config_delete-context.md docs/user-guide/kubectl/kubectl_config_get-clusters.md docs/user-guide/kubectl/kubectl_config_get-contexts.md +docs/user-guide/kubectl/kubectl_config_rename-context.md docs/user-guide/kubectl/kubectl_config_set-cluster.md docs/user-guide/kubectl/kubectl_config_set-context.md docs/user-guide/kubectl/kubectl_config_set-credentials.md diff --git a/docs/api-reference/admissionregistration.k8s.io/v1alpha1/definitions.html b/docs/api-reference/admissionregistration.k8s.io/v1alpha1/definitions.html new file mode 100755 index 0000000000000..ecd774eec4810 --- /dev/null +++ b/docs/api-reference/admissionregistration.k8s.io/v1alpha1/definitions.html @@ -0,0 +1,1753 @@ + + + + + + +Codestin Search App + + + + +
+ +
+

Definitions

+
+
+

v1.APIResourceList

+
+

APIResourceList is a list of APIResource, it is used to expose the name of the resources supported in a specific group and version, and if the resource is namespaced.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

kind

Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

false

string

apiVersion

APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

false

string

groupVersion

groupVersion is the group and version this APIResourceList is for.

true

string

resources

resources contains the name of the resources and if they are namespaced.

true

v1.APIResource array

+ +
+
+

v1alpha1.OperationType

+ +
+
+

v1alpha1.FailurePolicyType

+ +
+
+

v1alpha1.Rule

+
+

Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended to make sure that all the tuple expansions are valid.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

apiGroups

APIGroups is the API groups the resources belong to. is all groups. If is present, the length of the slice must be one. Required.

false

string array

apiVersions

APIVersions is the API versions the resources belong to. is all versions. If is present, the length of the slice must be one. Required.

false

string array

resources

Resources is a list of resources this rule applies to.
+
+For example: pods means pods. pods/log means the log subresource of pods. means all resources, but not subresources. pods/ means all subresources of pods. /scale means all scale subresources. / means all resources and their subresources.
+
+If
or / is present, the length of the slice must be one. Required.

false

string array

+ +
+
+

v1alpha1.RuleWithOperations

+
+

RuleWithOperations is a tuple of Operations and Resources. It is recommended to make sure that all the tuple expansions are valid.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

operations

Operations is the operations the admission hook cares about - CREATE, UPDATE, or * for all operations. If * is present, the length of the slice must be one. Required.

false

v1alpha1.OperationType array

apiGroups

APIGroups is the API groups the resources belong to. is all groups. If is present, the length of the slice must be one. Required.

false

string array

apiVersions

APIVersions is the API versions the resources belong to. is all versions. If is present, the length of the slice must be one. Required.

false

string array

resources

Resources is a list of resources this rule applies to.
+
+For example: pods means pods. pods/log means the log subresource of pods. means all resources, but not subresources. pods/ means all subresources of pods. /scale means all scale subresources. / means all resources and their subresources.
+
+If
or / is present, the length of the slice must be one. Required.

false

string array

+ +
+
+

v1.ListMeta

+
+

ListMeta describes metadata that synthetic resources must have, including lists and various status objects. A resource may have only one of {ObjectMeta, ListMeta}.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

selfLink

SelfLink is a URL representing this object. Populated by the system. Read-only.

false

string

resourceVersion

String that identifies the server’s internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency

false

string

+ +
+
+

v1.Initializers

+
+

Initializers tracks the progress of initialization.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

pending

Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients.

true

v1.Initializer array

result

If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion.

false

v1.Status

+ +
+
+

v1.Preconditions

+
+

Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.

+
+ +++++++ + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

uid

Specifies the target UID.

false

types.UID

+ +
+
+

v1alpha1.AdmissionHookClientConfig

+
+

AdmissionHookClientConfig contains the information to make a TLS connection with the webhook

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

service

Service is a reference to the service for this webhook. If there is only one port open for the service, that port will be used. If there are multiple ports open, port 443 will be used if it is open, otherwise it is an error. Required

true

v1alpha1.ServiceReference

caBundle

CABundle is a PEM encoded CA bundle which will be used to validate webhook’s server certificate. Required

true

string

+ +
+
+

v1.Status

+
+

Status is a return value for calls that don’t return other objects.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

kind

Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

false

string

apiVersion

APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

false

string

metadata

Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

false

v1.ListMeta

status

Status of the operation. One of: "Success" or "Failure". More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status

false

string

message

A human-readable description of the status of this operation.

false

string

reason

A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it.

false

string

details

Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type.

false

v1.StatusDetails

code

Suggested HTTP return code for this status, 0 if not set.

false

integer (int32)

+ +
+
+

v1.WatchEvent

+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

type

true

string

object

true

string

+ +
+
+

v1alpha1.ExternalAdmissionHook

+
+

ExternalAdmissionHook describes an external admission webhook and the resources and operations it applies to.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

name

The name of the external admission webhook. Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where "imagepolicy" is the name of the webhook, and kubernetes.io is the name of the organization. Required.

true

string

clientConfig

ClientConfig defines how to communicate with the hook. Required

true

v1alpha1.AdmissionHookClientConfig

rules

Rules describes what operations on what resources/subresources the webhook cares about. The webhook cares about an operation if it matches any Rule.

false

v1alpha1.RuleWithOperations array

failurePolicy

FailurePolicy defines how unrecognized errors from the admission endpoint are handled - allowed values are Ignore or Fail. Defaults to Ignore.

false

v1alpha1.FailurePolicyType

+ +
+
+

v1alpha1.ServiceReference

+
+

ServiceReference holds a reference to Service.legacy.k8s.io

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

namespace

Namespace is the namespace of the service Required

true

string

name

Name is the name of the service Required

true

string

+ +
+
+

v1alpha1.Initializer

+
+

Initializer describes the name and the failure policy of an initializer, and what resources it applies to.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

name

Name is the identifier of the initializer. It will be added to the object that needs to be initialized. Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where "alwayspullimages" is the name of the webhook, and kubernetes.io is the name of the organization. Required

true

string

rules

Rules describes what resources/subresources the initializer cares about. The initializer cares about an operation if it matches any Rule.

false

v1alpha1.Rule array

failurePolicy

FailurePolicy defines what happens if the responsible initializer controller fails to takes action. Allowed values are Ignore, or Fail. If "Ignore" is set, initializer is removed from the initializers list of an object if the timeout is reached; If "Fail" is set, admissionregistration returns timeout error if the timeout is reached.

false

v1alpha1.FailurePolicyType

+ +
+
+

v1alpha1.ExternalAdmissionHookConfiguration

+
+

ExternalAdmissionHookConfiguration describes the configuration of initializers.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

kind

Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

false

string

apiVersion

APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

false

string

metadata

Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.

false

v1.ObjectMeta

externalAdmissionHooks

ExternalAdmissionHooks is a list of external admission webhooks and the affected resources and operations.

false

v1alpha1.ExternalAdmissionHook array

+ +
+
+

v1.DeletionPropagation

+ +
+
+

v1.Patch

+
+

Patch is provided to give a concrete name and type to the Kubernetes PATCH request body.

+
+
+
+

v1.DeleteOptions

+
+

DeleteOptions may be provided when deleting an API object.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

kind

Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

false

string

apiVersion

APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

false

string

gracePeriodSeconds

The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.

false

integer (int64)

preconditions

Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned.

false

v1.Preconditions

orphanDependents

Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the "orphan" finalizer will be added to/removed from the object’s finalizers list. Either this field or PropagationPolicy may be set, but not both.

false

boolean

false

propagationPolicy

Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.

false

v1.DeletionPropagation

+ +
+
+

v1.StatusDetails

+
+

StatusDetails is a set of additional properties that MAY be set by the server to provide additional information about a response. The Reason field of a Status object defines what attributes will be set. Clients must ignore fields that do not match the defined type of each attribute, and should assume that any attribute may be empty, invalid, or under defined.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

name

The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described).

false

string

group

The group attribute of the resource associated with the status StatusReason.

false

string

kind

The kind attribute of the resource associated with the status StatusReason. On some operations may differ from the requested resource Kind. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

false

string

uid

UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids

false

string

causes

The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes.

false

v1.StatusCause array

retryAfterSeconds

If specified, the time in seconds before the operation should be retried.

false

integer (int32)

+ +
+
+

v1.Initializer

+
+

Initializer is information about an initializer that has not yet completed.

+
+ +++++++ + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

name

name of the process that is responsible for initializing this object.

true

string

+ +
+
+

v1.OwnerReference

+
+

OwnerReference contains enough information to let you identify an owning object. Currently, an owning object must be in the same namespace, so there is no namespace field.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

apiVersion

API version of the referent.

true

string

kind

Kind of the referent. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

true

string

name

Name of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#names

true

string

uid

UID of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#uids

true

string

controller

If true, this reference points to the managing controller.

false

boolean

false

blockOwnerDeletion

If true, AND if the owner has the "foregroundDeletion" finalizer, then the owner cannot be deleted from the key-value store until this reference is removed. Defaults to false. To set this field, a user needs "delete" permission of the owner, otherwise 422 (Unprocessable Entity) will be returned.

false

boolean

false

+ +
+
+

v1.ObjectMeta

+
+

ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

name

Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names

false

string

generateName

GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server.
+
+If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header).
+
+Applied only if Name is not specified. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#idempotency

false

string

namespace

Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty.
+
+Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces

false

string

selfLink

SelfLink is a URL representing this object. Populated by the system. Read-only.

false

string

uid

UID is the unique in time and space value for this object. It is typically generated by the server on successful creation of a resource and is not allowed to change on PUT operations.
+
+Populated by the system. Read-only. More info: http://kubernetes.io/docs/user-guide/identifiers#uids

false

string

resourceVersion

An opaque value that represents the internal version of this object that can be used by clients to determine when objects have changed. May be used for optimistic concurrency, change detection, and the watch operation on a resource or set of resources. Clients must treat these values as opaque and passed unmodified back to the server. They may only be valid for a particular resource or set of resources.
+
+Populated by the system. Read-only. Value must be treated as opaque by clients and . More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency

false

string

generation

A sequence number representing a specific generation of the desired state. Populated by the system. Read-only.

false

integer (int64)

creationTimestamp

CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.
+
+Populated by the system. Read-only. Null for lists. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata

false

string

deletionTimestamp

DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource is expected to be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field. Once set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, remove the pod from the API. In the presence of network partitions, this object may still exist after this timestamp, until an administrator or automated process can determine the resource is fully terminated. If not set, graceful deletion of the object has not been requested.
+
+Populated by the system when a graceful deletion is requested. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata

false

string

deletionGracePeriodSeconds

Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only.

false

integer (int64)

labels

Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels

false

object

annotations

Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations

false

object

ownerReferences

List of objects depended by this object. If ALL objects in the list have been deleted, this object will be garbage collected. If this object is managed by a controller, then an entry in this list will point to this controller, with the controller field set to true. There cannot be more than one managing controller.

false

v1.OwnerReference array

initializers

An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven’t explicitly asked to observe uninitialized objects.
+
+When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user.

false

v1.Initializers

finalizers

Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed.

false

string array

clusterName

The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request.

false

string

+ +
+
+

v1alpha1.InitializerConfiguration

+
+

InitializerConfiguration describes the configuration of initializers.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

kind

Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

false

string

apiVersion

APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

false

string

metadata

Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.

false

v1.ObjectMeta

initializers

Initializers is a list of resources and their default initializers Order-sensitive. When merging multiple InitializerConfigurations, we sort the initializers from different InitializerConfigurations by the name of the InitializerConfigurations; the order of the initializers from the same InitializerConfiguration is preserved.

false

v1alpha1.Initializer array

+ +
+
+

v1.APIResource

+
+

APIResource specifies the name of a resource and whether it is namespaced.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

name

name is the plural name of the resource.

true

string

singularName

singularName is the singular name of the resource. This allows clients to handle plural and singular opaquely. The singularName is more correct for reporting status on a single item and both singular and plural are allowed from the kubectl CLI interface.

true

string

namespaced

namespaced indicates if a resource is namespaced or not.

true

boolean

false

kind

kind is the kind for the resource (e.g. Foo is the kind for a resource foo)

true

string

verbs

verbs is a list of supported kube verbs (this includes get, list, watch, create, update, patch, delete, deletecollection, and proxy)

true

string array

shortNames

shortNames is a list of suggested short names of the resource.

false

string array

+ +
+
+

types.UID

+ +
+
+

v1.StatusCause

+
+

StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

reason

A machine-readable description of the cause of the error. If this value is empty there is no information available.

false

string

message

A human-readable description of the cause of the error. This field may be presented as-is to a reader.

false

string

field

The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional.
+
+Examples:
+ "name" - the field "name" on the current resource
+ "items[0].name" - the field "name" on the first array entry in "items"

false

string

+ +
+
+

v1alpha1.ExternalAdmissionHookConfigurationList

+
+

ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

kind

Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

false

string

apiVersion

APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

false

string

metadata

Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

false

v1.ListMeta

items

List of ExternalAdmissionHookConfiguration.

true

v1alpha1.ExternalAdmissionHookConfiguration array

+ +
+
+

v1alpha1.InitializerConfigurationList

+
+

InitializerConfigurationList is a list of InitializerConfiguration.

+
+ +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionRequiredSchemaDefault

kind

Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

false

string

apiVersion

APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

false

string

metadata

Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

false

v1.ListMeta

items

List of InitializerConfiguration.

true

v1alpha1.InitializerConfiguration array

+ +
+
+

any

+
+

Represents an untyped JSON map - see the description of the field for more info about the structure of this object.

+
+
+
+
+
+ + + \ No newline at end of file diff --git a/docs/api-reference/admissionregistration.k8s.io/v1alpha1/operations.html b/docs/api-reference/admissionregistration.k8s.io/v1alpha1/operations.html new file mode 100755 index 0000000000000..8c8bbbf32fe6c --- /dev/null +++ b/docs/api-reference/admissionregistration.k8s.io/v1alpha1/operations.html @@ -0,0 +1,2964 @@ + + + + + + +Codestin Search App + + + + +
+
+

Operations

+
+
+

get available resources

+
+
+
GET /apis/admissionregistration.k8s.io/v1alpha1
+
+
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

default

success

v1.APIResourceList

+ +
+
+

Consumes

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

list or watch objects of kind ExternalAdmissionHookConfiguration

+
+
+
GET /apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

QueryParameter

labelSelector

A selector to restrict the list of returned objects by their labels. Defaults to everything.

false

string

QueryParameter

fieldSelector

A selector to restrict the list of returned objects by their fields. Defaults to everything.

false

string

QueryParameter

includeUninitialized

If true, partially initialized resources are included in the response.

false

boolean

QueryParameter

watch

Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

false

boolean

QueryParameter

resourceVersion

When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

false

string

QueryParameter

timeoutSeconds

Timeout for the list/watch call.

false

integer (int32)

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1alpha1.ExternalAdmissionHookConfigurationList

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
  • +

    application/json;stream=watch

    +
  • +
  • +

    application/vnd.kubernetes.protobuf;stream=watch

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

delete collection of ExternalAdmissionHookConfiguration

+
+
+
DELETE /apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

QueryParameter

labelSelector

A selector to restrict the list of returned objects by their labels. Defaults to everything.

false

string

QueryParameter

fieldSelector

A selector to restrict the list of returned objects by their fields. Defaults to everything.

false

string

QueryParameter

includeUninitialized

If true, partially initialized resources are included in the response.

false

boolean

QueryParameter

watch

Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

false

boolean

QueryParameter

resourceVersion

When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

false

string

QueryParameter

timeoutSeconds

Timeout for the list/watch call.

false

integer (int32)

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1.Status

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

create an ExternalAdmissionHookConfiguration

+
+
+
POST /apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

BodyParameter

body

true

v1alpha1.ExternalAdmissionHookConfiguration

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1alpha1.ExternalAdmissionHookConfiguration

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

read the specified ExternalAdmissionHookConfiguration

+
+
+
GET /apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations/{name}
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

QueryParameter

export

Should this value be exported. Export strips fields that a user can not specify.

false

boolean

QueryParameter

exact

Should the export be exact. Exact export maintains cluster-specific fields like Namespace.

false

boolean

PathParameter

name

name of the ExternalAdmissionHookConfiguration

true

string

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1alpha1.ExternalAdmissionHookConfiguration

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

replace the specified ExternalAdmissionHookConfiguration

+
+
+
PUT /apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations/{name}
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

BodyParameter

body

true

v1alpha1.ExternalAdmissionHookConfiguration

PathParameter

name

name of the ExternalAdmissionHookConfiguration

true

string

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1alpha1.ExternalAdmissionHookConfiguration

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

delete an ExternalAdmissionHookConfiguration

+
+
+
DELETE /apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations/{name}
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

BodyParameter

body

true

v1.DeleteOptions

QueryParameter

gracePeriodSeconds

The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.

false

integer (int32)

QueryParameter

orphanDependents

Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the "orphan" finalizer will be added to/removed from the object’s finalizers list. Either this field or PropagationPolicy may be set, but not both.

false

boolean

QueryParameter

propagationPolicy

Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.

false

string

PathParameter

name

name of the ExternalAdmissionHookConfiguration

true

string

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1.Status

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

partially update the specified ExternalAdmissionHookConfiguration

+
+
+
PATCH /apis/admissionregistration.k8s.io/v1alpha1/externaladmissionhookconfigurations/{name}
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

BodyParameter

body

true

v1.Patch

PathParameter

name

name of the ExternalAdmissionHookConfiguration

true

string

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1alpha1.ExternalAdmissionHookConfiguration

+ +
+
+

Consumes

+
+
    +
  • +

    application/json-patch+json

    +
  • +
  • +

    application/merge-patch+json

    +
  • +
  • +

    application/strategic-merge-patch+json

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

list or watch objects of kind InitializerConfiguration

+
+
+
GET /apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

QueryParameter

labelSelector

A selector to restrict the list of returned objects by their labels. Defaults to everything.

false

string

QueryParameter

fieldSelector

A selector to restrict the list of returned objects by their fields. Defaults to everything.

false

string

QueryParameter

includeUninitialized

If true, partially initialized resources are included in the response.

false

boolean

QueryParameter

watch

Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

false

boolean

QueryParameter

resourceVersion

When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

false

string

QueryParameter

timeoutSeconds

Timeout for the list/watch call.

false

integer (int32)

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1alpha1.InitializerConfigurationList

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
  • +

    application/json;stream=watch

    +
  • +
  • +

    application/vnd.kubernetes.protobuf;stream=watch

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

delete collection of InitializerConfiguration

+
+
+
DELETE /apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

QueryParameter

labelSelector

A selector to restrict the list of returned objects by their labels. Defaults to everything.

false

string

QueryParameter

fieldSelector

A selector to restrict the list of returned objects by their fields. Defaults to everything.

false

string

QueryParameter

includeUninitialized

If true, partially initialized resources are included in the response.

false

boolean

QueryParameter

watch

Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

false

boolean

QueryParameter

resourceVersion

When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

false

string

QueryParameter

timeoutSeconds

Timeout for the list/watch call.

false

integer (int32)

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1.Status

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

create an InitializerConfiguration

+
+
+
POST /apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

BodyParameter

body

true

v1alpha1.InitializerConfiguration

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1alpha1.InitializerConfiguration

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

read the specified InitializerConfiguration

+
+
+
GET /apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations/{name}
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

QueryParameter

export

Should this value be exported. Export strips fields that a user can not specify.

false

boolean

QueryParameter

exact

Should the export be exact. Exact export maintains cluster-specific fields like Namespace.

false

boolean

PathParameter

name

name of the InitializerConfiguration

true

string

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1alpha1.InitializerConfiguration

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

replace the specified InitializerConfiguration

+
+
+
PUT /apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations/{name}
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

BodyParameter

body

true

v1alpha1.InitializerConfiguration

PathParameter

name

name of the InitializerConfiguration

true

string

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1alpha1.InitializerConfiguration

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

delete an InitializerConfiguration

+
+
+
DELETE /apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations/{name}
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

BodyParameter

body

true

v1.DeleteOptions

QueryParameter

gracePeriodSeconds

The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.

false

integer (int32)

QueryParameter

orphanDependents

Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the "orphan" finalizer will be added to/removed from the object’s finalizers list. Either this field or PropagationPolicy may be set, but not both.

false

boolean

QueryParameter

propagationPolicy

Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.

false

string

PathParameter

name

name of the InitializerConfiguration

true

string

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1.Status

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

partially update the specified InitializerConfiguration

+
+
+
PATCH /apis/admissionregistration.k8s.io/v1alpha1/initializerconfigurations/{name}
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

BodyParameter

body

true

v1.Patch

PathParameter

name

name of the InitializerConfiguration

true

string

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1alpha1.InitializerConfiguration

+ +
+
+

Consumes

+
+
    +
  • +

    application/json-patch+json

    +
  • +
  • +

    application/merge-patch+json

    +
  • +
  • +

    application/strategic-merge-patch+json

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

watch individual changes to a list of ExternalAdmissionHookConfiguration

+
+
+
GET /apis/admissionregistration.k8s.io/v1alpha1/watch/externaladmissionhookconfigurations
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

QueryParameter

labelSelector

A selector to restrict the list of returned objects by their labels. Defaults to everything.

false

string

QueryParameter

fieldSelector

A selector to restrict the list of returned objects by their fields. Defaults to everything.

false

string

QueryParameter

includeUninitialized

If true, partially initialized resources are included in the response.

false

boolean

QueryParameter

watch

Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

false

boolean

QueryParameter

resourceVersion

When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

false

string

QueryParameter

timeoutSeconds

Timeout for the list/watch call.

false

integer (int32)

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1.WatchEvent

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
  • +

    application/json;stream=watch

    +
  • +
  • +

    application/vnd.kubernetes.protobuf;stream=watch

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

watch changes to an object of kind ExternalAdmissionHookConfiguration

+
+
+
GET /apis/admissionregistration.k8s.io/v1alpha1/watch/externaladmissionhookconfigurations/{name}
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

QueryParameter

labelSelector

A selector to restrict the list of returned objects by their labels. Defaults to everything.

false

string

QueryParameter

fieldSelector

A selector to restrict the list of returned objects by their fields. Defaults to everything.

false

string

QueryParameter

includeUninitialized

If true, partially initialized resources are included in the response.

false

boolean

QueryParameter

watch

Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

false

boolean

QueryParameter

resourceVersion

When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

false

string

QueryParameter

timeoutSeconds

Timeout for the list/watch call.

false

integer (int32)

PathParameter

name

name of the ExternalAdmissionHookConfiguration

true

string

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1.WatchEvent

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
  • +

    application/json;stream=watch

    +
  • +
  • +

    application/vnd.kubernetes.protobuf;stream=watch

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

watch individual changes to a list of InitializerConfiguration

+
+
+
GET /apis/admissionregistration.k8s.io/v1alpha1/watch/initializerconfigurations
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

QueryParameter

labelSelector

A selector to restrict the list of returned objects by their labels. Defaults to everything.

false

string

QueryParameter

fieldSelector

A selector to restrict the list of returned objects by their fields. Defaults to everything.

false

string

QueryParameter

includeUninitialized

If true, partially initialized resources are included in the response.

false

boolean

QueryParameter

watch

Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

false

boolean

QueryParameter

resourceVersion

When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

false

string

QueryParameter

timeoutSeconds

Timeout for the list/watch call.

false

integer (int32)

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1.WatchEvent

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
  • +

    application/json;stream=watch

    +
  • +
  • +

    application/vnd.kubernetes.protobuf;stream=watch

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+

watch changes to an object of kind InitializerConfiguration

+
+
+
GET /apis/admissionregistration.k8s.io/v1alpha1/watch/initializerconfigurations/{name}
+
+
+
+

Parameters

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeNameDescriptionRequiredSchemaDefault

QueryParameter

pretty

If true, then the output is pretty printed.

false

string

QueryParameter

labelSelector

A selector to restrict the list of returned objects by their labels. Defaults to everything.

false

string

QueryParameter

fieldSelector

A selector to restrict the list of returned objects by their fields. Defaults to everything.

false

string

QueryParameter

includeUninitialized

If true, partially initialized resources are included in the response.

false

boolean

QueryParameter

watch

Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

false

boolean

QueryParameter

resourceVersion

When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

false

string

QueryParameter

timeoutSeconds

Timeout for the list/watch call.

false

integer (int32)

PathParameter

name

name of the InitializerConfiguration

true

string

+ +
+
+

Responses

+ +++++ + + + + + + + + + + + + + + +
HTTP CodeDescriptionSchema

200

success

v1.WatchEvent

+ +
+
+

Consumes

+
+
    +
  • +

    /

    +
  • +
+
+
+
+

Produces

+
+
    +
  • +

    application/json

    +
  • +
  • +

    application/yaml

    +
  • +
  • +

    application/vnd.kubernetes.protobuf

    +
  • +
  • +

    application/json;stream=watch

    +
  • +
  • +

    application/vnd.kubernetes.protobuf;stream=watch

    +
  • +
+
+
+
+

Tags

+
+
    +
  • +

    apisadmissionregistration.k8s.iov1alpha1

    +
  • +
+
+
+
+
+
+
+ + + \ No newline at end of file diff --git a/docs/api-reference/apps/v1beta1/definitions.html b/docs/api-reference/apps/v1beta1/definitions.html index eb12ea5f5d47b..3d065820b2abb 100755 --- a/docs/api-reference/apps/v1beta1/definitions.html +++ b/docs/api-reference/apps/v1beta1/definitions.html @@ -387,6 +387,12 @@

Top Level API Objects

  • v1beta1.StatefulSetList

  • +
  • +

    v1beta1.ControllerRevision

    +
  • +
  • +

    v1beta1.ControllerRevisionList

    +
  • @@ -1812,10 +1818,6 @@

    v1beta1.Deployment

    - -
    -

    types.UID

    -

    v1.AzureFileVolumeSource

    @@ -1864,6 +1866,10 @@

    v1.AzureFileVolumeSource

    +
    +
    +

    types.UID

    +

    v1.ISCSIVolumeSource

    @@ -1992,6 +1998,13 @@

    v1.EmptyDirVolumeSource

    string

    + +

    sizeLimit

    +

    Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir

    +

    false

    +

    string

    + + @@ -2422,7 +2435,7 @@

    v1beta1.RollbackConfig

    revision

    -

    The revision to rollback to. If set to 0, rollbck to the last revision.

    +

    The revision to rollback to. If set to 0, rollback to the last revision.

    false

    integer (int64)

    @@ -2607,9 +2620,9 @@

    v1.EnvVarSource

    -

    v1.AzureDiskVolumeSource

    +

    v1.KeyToPath

    -

    AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.

    +

    Maps a string key to a path within a volume.

    @@ -2630,45 +2643,24 @@

    v1.AzureDiskVolumeSource

    - - + + - - + + - - - - - - - - - - - - - - - - - - - - - - - + + - + @@ -2676,9 +2668,9 @@

    v1.AzureDiskVolumeSource

    -

    v1.KeyToPath

    +

    v1.AzureDiskVolumeSource

    -

    Maps a string key to a path within a volume.

    +

    AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.

    diskName

    The Name of the data disk in the blob storage

    key

    The key to project.

    true

    string

    diskURI

    The URI the data disk in the blob storage

    path

    The relative path of the file to map the key to. May not be an absolute path. May not contain the path element ... May not start with the string ...

    true

    string

    cachingMode

    Host Caching mode: None, Read Only, Read Write.

    false

    v1.AzureDataDiskCachingMode

    fsType

    Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.

    false

    string

    readOnly

    Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.

    false

    boolean

    false

    kind

    Expected values Shared: mulitple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared

    mode

    Optional: mode bits to use on this file, must be a value between 0 and 0777. If not specified, the volume defaultMode will be used. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.

    false

    v1.AzureDataDiskKind

    integer (int32)

    @@ -2699,24 +2691,45 @@

    v1.KeyToPath

    - - + + - - + + - - + + - + + + + + + + + + + + + + + + + + + + + + + @@ -4162,6 +4175,68 @@

    v1beta1.Scale

    key

    The key to project.

    diskName

    The Name of the data disk in the blob storage

    true

    string

    path

    The relative path of the file to map the key to. May not be an absolute path. May not contain the path element ... May not start with the string ...

    diskURI

    The URI the data disk in the blob storage

    true

    string

    mode

    Optional: mode bits to use on this file, must be a value between 0 and 0777. If not specified, the volume defaultMode will be used. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.

    cachingMode

    Host Caching mode: None, Read Only, Read Write.

    false

    integer (int32)

    v1.AzureDataDiskCachingMode

    fsType

    Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.

    false

    string

    readOnly

    Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.

    false

    boolean

    false

    kind

    Expected values Shared: mulitple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared

    false

    v1.AzureDataDiskKind

    +
    +
    +

    v1beta1.ControllerRevision

    +
    +

    ControllerRevision implements an immutable snapshot of state data. Clients are responsible for serializing and deserializing the objects that contain their internal state. Once a ControllerRevision has been successfully created, it can not be updated. The API Server will fail validation of all requests that attempt to mutate the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, it may be subject to name and representation changes in future releases, and clients should not depend on its stability. It is primarily for internal use by controllers.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    kind

    Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

    false

    string

    apiVersion

    APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

    false

    string

    metadata

    Standard object’s metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata

    false

    v1.ObjectMeta

    data

    Data is the serialized representation of the state.

    false

    string

    revision

    Revision indicates the revision of the state represented by Data.

    true

    integer (int64)

    +

    v1.RBDVolumeSource

    @@ -4963,9 +5038,9 @@

    v1.DeletionPropagation

    -

    v1.TCPSocketAction

    +

    v1beta1.DeploymentStrategy

    -

    TCPSocketAction describes an action based on opening a socket

    +

    DeploymentStrategy describes how to replace existing pods with new ones.

    @@ -4986,17 +5061,17 @@

    v1.TCPSocketAction

    - - - + + + - - + + - + @@ -5004,9 +5079,9 @@

    v1.TCPSocketAction

    -

    v1beta1.DeploymentStrategy

    +

    v1.TCPSocketAction

    -

    DeploymentStrategy describes how to replace existing pods with new ones.

    +

    TCPSocketAction describes an action based on opening a socket

    port

    Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.

    true

    type

    Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate.

    false

    string

    host

    Optional: Host name to connect to, defaults to the pod IP.

    rollingUpdate

    Rolling update config params. Present only if DeploymentStrategyType = RollingUpdate.

    false

    string

    v1beta1.RollingUpdateDeployment

    @@ -5027,17 +5102,17 @@

    v1beta1.DeploymentStrategy

    - - - + + + - - + + - + @@ -5474,6 +5549,61 @@

    v1.OwnerReference

    type

    Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate.

    false

    port

    Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.

    true

    string

    rollingUpdate

    Rolling update config params. Present only if DeploymentStrategyType = RollingUpdate.

    host

    Optional: Host name to connect to, defaults to the pod IP.

    false

    v1beta1.RollingUpdateDeployment

    string

    +
    +
    +

    v1beta1.ControllerRevisionList

    +
    +

    ControllerRevisionList is a resource containing a list of ControllerRevision objects.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    kind

    Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

    false

    string

    apiVersion

    APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

    false

    string

    metadata

    More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata

    false

    v1.ListMeta

    items

    Items is the list of ControllerRevisions

    true

    v1beta1.ControllerRevision array

    +

    v1.APIResource

    @@ -6477,7 +6607,7 @@

    any

    diff --git a/docs/api-reference/apps/v1beta1/operations.html b/docs/api-reference/apps/v1beta1/operations.html index c4517e6a75230..06e8b35e0f2ef 100755 --- a/docs/api-reference/apps/v1beta1/operations.html +++ b/docs/api-reference/apps/v1beta1/operations.html @@ -443,10 +443,10 @@

    Tags

    -

    list or watch objects of kind Deployment

    +

    list or watch objects of kind ControllerRevision

    -
    GET /apis/apps/v1beta1/deployments
    +
    GET /apis/apps/v1beta1/controllerrevisions
    @@ -550,7 +550,7 @@

    Responses

    200

    success

    -

    v1beta1.DeploymentList

    +

    v1beta1.ControllerRevisionList

    @@ -600,10 +600,10 @@

    Tags

    -

    list or watch objects of kind Deployment

    +

    list or watch objects of kind Deployment

    -
    GET /apis/apps/v1beta1/namespaces/{namespace}/deployments
    +
    GET /apis/apps/v1beta1/deployments
    @@ -684,14 +684,6 @@

    Parameters

    integer (int32)

    - -

    PathParameter

    -

    namespace

    -

    object name and auth scope, such as for teams and projects

    -

    true

    -

    string

    - - @@ -765,10 +757,10 @@

    Tags

    -

    delete collection of Deployment

    +

    list or watch objects of kind ControllerRevision

    -
    DELETE /apis/apps/v1beta1/namespaces/{namespace}/deployments
    +
    GET /apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions
    @@ -880,7 +872,7 @@

    Responses

    200

    success

    -

    v1.Status

    +

    v1beta1.ControllerRevisionList

    @@ -909,6 +901,12 @@

    Produces

  • application/vnd.kubernetes.protobuf

  • +
  • +

    application/json;stream=watch

    +
  • +
  • +

    application/vnd.kubernetes.protobuf;stream=watch

    +
  • @@ -924,10 +922,10 @@

    Tags

    -

    create a Deployment

    +

    delete collection of ControllerRevision

    -
    POST /apis/apps/v1beta1/namespaces/{namespace}/deployments
    +
    DELETE /apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions
    @@ -961,11 +959,51 @@

    Parameters

    -

    BodyParameter

    -

    body

    +

    QueryParameter

    +

    labelSelector

    +

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    +

    false

    +

    string

    -

    true

    -

    v1beta1.Deployment

    + + +

    QueryParameter

    +

    fieldSelector

    +

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    +

    false

    +

    string

    + + + +

    QueryParameter

    +

    includeUninitialized

    +

    If true, partially initialized resources are included in the response.

    +

    false

    +

    boolean

    + + + +

    QueryParameter

    +

    watch

    +

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    +

    false

    +

    boolean

    + + + +

    QueryParameter

    +

    resourceVersion

    +

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    +

    false

    +

    string

    + + + +

    QueryParameter

    +

    timeoutSeconds

    +

    Timeout for the list/watch call.

    +

    false

    +

    integer (int32)

    @@ -999,7 +1037,7 @@

    Responses

    200

    success

    -

    v1beta1.Deployment

    +

    v1.Status

    @@ -1043,10 +1081,10 @@

    Tags

    -

    read the specified Deployment

    +

    create a ControllerRevision

    -
    GET /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}
    +
    POST /apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions
    @@ -1080,19 +1118,11 @@

    Parameters

    -

    QueryParameter

    -

    export

    -

    Should this value be exported. Export strips fields that a user can not specify.

    -

    false

    -

    boolean

    +

    BodyParameter

    +

    body

    - - -

    QueryParameter

    -

    exact

    -

    Should the export be exact. Exact export maintains cluster-specific fields like Namespace.

    -

    false

    -

    boolean

    +

    true

    +

    v1beta1.ControllerRevision

    @@ -1103,14 +1133,6 @@

    Parameters

    string

    - -

    PathParameter

    -

    name

    -

    name of the Deployment

    -

    true

    -

    string

    - - @@ -1134,7 +1156,7 @@

    Responses

    200

    success

    -

    v1beta1.Deployment

    +

    v1beta1.ControllerRevision

    @@ -1178,10 +1200,10 @@

    Tags

    -

    replace the specified Deployment

    +

    read the specified ControllerRevision

    -
    PUT /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}
    +
    GET /apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions/{name}
    @@ -1215,11 +1237,19 @@

    Parameters

    -

    BodyParameter

    -

    body

    +

    QueryParameter

    +

    export

    +

    Should this value be exported. Export strips fields that a user can not specify.

    +

    false

    +

    boolean

    -

    true

    -

    v1beta1.Deployment

    + + +

    QueryParameter

    +

    exact

    +

    Should the export be exact. Exact export maintains cluster-specific fields like Namespace.

    +

    false

    +

    boolean

    @@ -1233,7 +1263,7 @@

    Parameters

    PathParameter

    name

    -

    name of the Deployment

    +

    name of the ControllerRevision

    true

    string

    @@ -1261,7 +1291,7 @@

    Responses

    200

    success

    -

    v1beta1.Deployment

    +

    v1beta1.ControllerRevision

    @@ -1305,10 +1335,10 @@

    Tags

    -

    delete a Deployment

    +

    replace the specified ControllerRevision

    -
    DELETE /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}
    +
    PUT /apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions/{name}
    @@ -1346,31 +1376,7 @@

    Parameters

    body

    true

    -

    v1.DeleteOptions

    - - - -

    QueryParameter

    -

    gracePeriodSeconds

    -

    The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.

    -

    false

    -

    integer (int32)

    - - - -

    QueryParameter

    -

    orphanDependents

    -

    Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the "orphan" finalizer will be added to/removed from the object’s finalizers list. Either this field or PropagationPolicy may be set, but not both.

    -

    false

    -

    boolean

    - - - -

    QueryParameter

    -

    propagationPolicy

    -

    Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.

    -

    false

    -

    string

    +

    v1beta1.ControllerRevision

    @@ -1384,7 +1390,7 @@

    Parameters

    PathParameter

    name

    -

    name of the Deployment

    +

    name of the ControllerRevision

    true

    string

    @@ -1412,7 +1418,7 @@

    Responses

    200

    success

    -

    v1.Status

    +

    v1beta1.ControllerRevision

    @@ -1456,10 +1462,10 @@

    Tags

    -

    partially update the specified Deployment

    +

    delete a ControllerRevision

    -
    PATCH /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}
    +
    DELETE /apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions/{name}
    @@ -1497,7 +1503,31 @@

    Parameters

    body

    true

    -

    v1.Patch

    +

    v1.DeleteOptions

    + + + +

    QueryParameter

    +

    gracePeriodSeconds

    +

    The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.

    +

    false

    +

    integer (int32)

    + + + +

    QueryParameter

    +

    orphanDependents

    +

    Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the "orphan" finalizer will be added to/removed from the object’s finalizers list. Either this field or PropagationPolicy may be set, but not both.

    +

    false

    +

    boolean

    + + + +

    QueryParameter

    +

    propagationPolicy

    +

    Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.

    +

    false

    +

    string

    @@ -1511,7 +1541,7 @@

    Parameters

    PathParameter

    name

    -

    name of the Deployment

    +

    name of the ControllerRevision

    true

    string

    @@ -1539,7 +1569,7 @@

    Responses

    200

    success

    -

    v1beta1.Deployment

    +

    v1.Status

    @@ -1550,13 +1580,7 @@

    Consumes

    • -

      application/json-patch+json

      -
    • -
    • -

      application/merge-patch+json

      -
    • -
    • -

      application/strategic-merge-patch+json

      +

      /

    @@ -1589,10 +1613,10 @@

    Tags

    -

    create rollback of a DeploymentRollback

    +

    partially update the specified ControllerRevision

    -
    POST /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/rollback
    +
    PATCH /apis/apps/v1beta1/namespaces/{namespace}/controllerrevisions/{name}
    @@ -1630,7 +1654,7 @@

    Parameters

    body

    true

    -

    v1beta1.DeploymentRollback

    +

    v1.Patch

    @@ -1644,7 +1668,7 @@

    Parameters

    PathParameter

    name

    -

    name of the DeploymentRollback

    +

    name of the ControllerRevision

    true

    string

    @@ -1672,7 +1696,7 @@

    Responses

    200

    success

    -

    v1beta1.DeploymentRollback

    +

    v1beta1.ControllerRevision

    @@ -1683,7 +1707,13 @@

    Consumes

    • -

      /

      +

      application/json-patch+json

      +
    • +
    • +

      application/merge-patch+json

      +
    • +
    • +

      application/strategic-merge-patch+json

    @@ -1716,10 +1746,10 @@

    Tags

    -

    read scale of the specified Scale

    +

    list or watch objects of kind Deployment

    -
    GET /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/scale
    +
    GET /apis/apps/v1beta1/namespaces/{namespace}/deployments
    @@ -1753,50 +1783,90 @@

    Parameters

    -

    PathParameter

    -

    namespace

    -

    object name and auth scope, such as for teams and projects

    -

    true

    +

    QueryParameter

    +

    labelSelector

    +

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    +

    false

    string

    -

    PathParameter

    -

    name

    -

    name of the Scale

    -

    true

    +

    QueryParameter

    +

    fieldSelector

    +

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    +

    false

    string

    - - - -
    -
    -

    Responses

    - ----- - - - - + + + + + + - - - - - - - -
    HTTP CodeDescriptionSchema

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    200

    success

    v1beta1.Scale

    - -
    +

    QueryParameter

    +

    watch

    +

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    +

    false

    +

    boolean

    + + + +

    QueryParameter

    +

    resourceVersion

    +

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    +

    false

    +

    string

    + + + +

    QueryParameter

    +

    timeoutSeconds

    +

    Timeout for the list/watch call.

    +

    false

    +

    integer (int32)

    + + + +

    PathParameter

    +

    namespace

    +

    object name and auth scope, such as for teams and projects

    +

    true

    +

    string

    + + + + + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1beta1.DeploymentList

    + +

    Consumes

    @@ -1820,6 +1890,12 @@

    Produces

  • application/vnd.kubernetes.protobuf

  • +
  • +

    application/json;stream=watch

    +
  • +
  • +

    application/vnd.kubernetes.protobuf;stream=watch

    +
  • @@ -1835,10 +1911,10 @@

    Tags

    -

    replace scale of the specified Scale

    +

    delete collection of Deployment

    -
    PUT /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/scale
    +
    DELETE /apis/apps/v1beta1/namespaces/{namespace}/deployments
    @@ -1872,25 +1948,57 @@

    Parameters

    -

    BodyParameter

    -

    body

    +

    QueryParameter

    +

    labelSelector

    +

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    +

    false

    +

    string

    -

    true

    -

    v1beta1.Scale

    + + +

    QueryParameter

    +

    fieldSelector

    +

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    +

    false

    +

    string

    -

    PathParameter

    -

    namespace

    -

    object name and auth scope, such as for teams and projects

    -

    true

    +

    QueryParameter

    +

    includeUninitialized

    +

    If true, partially initialized resources are included in the response.

    +

    false

    +

    boolean

    + + + +

    QueryParameter

    +

    watch

    +

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    +

    false

    +

    boolean

    + + + +

    QueryParameter

    +

    resourceVersion

    +

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    +

    false

    string

    +

    QueryParameter

    +

    timeoutSeconds

    +

    Timeout for the list/watch call.

    +

    false

    +

    integer (int32)

    + + +

    PathParameter

    -

    name

    -

    name of the Scale

    +

    namespace

    +

    object name and auth scope, such as for teams and projects

    true

    string

    @@ -1918,7 +2026,7 @@

    Responses

    200

    success

    -

    v1beta1.Scale

    +

    v1.Status

    @@ -1962,10 +2070,10 @@

    Tags

    -

    partially update scale of the specified Scale

    +

    create a Deployment

    -
    PATCH /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/scale
    +
    POST /apis/apps/v1beta1/namespaces/{namespace}/deployments
    @@ -2003,7 +2111,7 @@

    Parameters

    body

    true

    -

    v1.Patch

    +

    v1beta1.Deployment

    @@ -2014,14 +2122,6 @@

    Parameters

    string

    - -

    PathParameter

    -

    name

    -

    name of the Scale

    -

    true

    -

    string

    - - @@ -2045,7 +2145,7 @@

    Responses

    200

    success

    -

    v1beta1.Scale

    +

    v1beta1.Deployment

    @@ -2056,13 +2156,7 @@

    Consumes

    • -

      application/json-patch+json

      -
    • -
    • -

      application/merge-patch+json

      -
    • -
    • -

      application/strategic-merge-patch+json

      +

      /

    @@ -2095,10 +2189,10 @@

    Tags

    -

    read status of the specified Deployment

    +

    read the specified Deployment

    -
    GET /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/status
    +
    GET /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}
    @@ -2132,6 +2226,22 @@

    Parameters

    +

    QueryParameter

    +

    export

    +

    Should this value be exported. Export strips fields that a user can not specify.

    +

    false

    +

    boolean

    + + + +

    QueryParameter

    +

    exact

    +

    Should the export be exact. Exact export maintains cluster-specific fields like Namespace.

    +

    false

    +

    boolean

    + + +

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    @@ -2214,10 +2324,10 @@

    Tags

    -

    replace status of the specified Deployment

    +

    replace the specified Deployment

    -
    PUT /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/status
    +
    PUT /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}
    @@ -2341,10 +2451,10 @@

    Tags

    -

    partially update status of the specified Deployment

    +

    delete a Deployment

    -
    PATCH /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/status
    +
    DELETE /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}
    @@ -2382,7 +2492,31 @@

    Parameters

    body

    true

    -

    v1.Patch

    +

    v1.DeleteOptions

    + + + +

    QueryParameter

    +

    gracePeriodSeconds

    +

    The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.

    +

    false

    +

    integer (int32)

    + + + +

    QueryParameter

    +

    orphanDependents

    +

    Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the "orphan" finalizer will be added to/removed from the object’s finalizers list. Either this field or PropagationPolicy may be set, but not both.

    +

    false

    +

    boolean

    + + + +

    QueryParameter

    +

    propagationPolicy

    +

    Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.

    +

    false

    +

    string

    @@ -2424,7 +2558,7 @@

    Responses

    200

    success

    -

    v1beta1.Deployment

    +

    v1.Status

    @@ -2435,13 +2569,7 @@

    Consumes

    • -

      application/json-patch+json

      -
    • -
    • -

      application/merge-patch+json

      -
    • -
    • -

      application/strategic-merge-patch+json

      +

      /

    @@ -2474,10 +2602,10 @@

    Tags

    -

    list or watch objects of kind StatefulSet

    +

    partially update the specified Deployment

    -
    GET /apis/apps/v1beta1/namespaces/{namespace}/statefulsets
    +
    PATCH /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}
    @@ -2511,51 +2639,1353 @@

    Parameters

    -

    QueryParameter

    -

    labelSelector

    -

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    -

    false

    -

    string

    +

    BodyParameter

    +

    body

    - - -

    QueryParameter

    -

    fieldSelector

    -

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    -

    false

    -

    string

    +

    true

    +

    v1.Patch

    -

    QueryParameter

    -

    includeUninitialized

    -

    If true, partially initialized resources are included in the response.

    -

    false

    -

    boolean

    +

    PathParameter

    +

    namespace

    +

    object name and auth scope, such as for teams and projects

    +

    true

    +

    string

    -

    QueryParameter

    -

    watch

    -

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    -

    false

    -

    boolean

    +

    PathParameter

    +

    name

    +

    name of the Deployment

    +

    true

    +

    string

    - -

    QueryParameter

    -

    resourceVersion

    -

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    + + + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1beta1.Deployment

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      application/json-patch+json

      +
    • +
    • +

      application/merge-patch+json

      +
    • +
    • +

      application/strategic-merge-patch+json

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisappsv1beta1

      +
    • +
    +
    +
    +
    +
    +

    create rollback of a DeploymentRollback

    +
    +
    +
    POST /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/rollback
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    BodyParameter

    body

    true

    v1beta1.DeploymentRollback

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the DeploymentRollback

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1beta1.DeploymentRollback

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisappsv1beta1

      +
    • +
    +
    +
    +
    +
    +

    read scale of the specified Scale

    +
    +
    +
    GET /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/scale
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the Scale

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1beta1.Scale

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisappsv1beta1

      +
    • +
    +
    +
    +
    +
    +

    replace scale of the specified Scale

    +
    +
    +
    PUT /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/scale
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    BodyParameter

    body

    true

    v1beta1.Scale

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the Scale

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1beta1.Scale

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisappsv1beta1

      +
    • +
    +
    +
    +
    +
    +

    partially update scale of the specified Scale

    +
    +
    +
    PATCH /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/scale
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    BodyParameter

    body

    true

    v1.Patch

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the Scale

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1beta1.Scale

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      application/json-patch+json

      +
    • +
    • +

      application/merge-patch+json

      +
    • +
    • +

      application/strategic-merge-patch+json

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisappsv1beta1

      +
    • +
    +
    +
    +
    +
    +

    read status of the specified Deployment

    +
    +
    +
    GET /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/status
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the Deployment

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1beta1.Deployment

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisappsv1beta1

      +
    • +
    +
    +
    +
    +
    +

    replace status of the specified Deployment

    +
    +
    +
    PUT /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/status
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    BodyParameter

    body

    true

    v1beta1.Deployment

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the Deployment

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1beta1.Deployment

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisappsv1beta1

      +
    • +
    +
    +
    +
    +
    +

    partially update status of the specified Deployment

    +
    +
    +
    PATCH /apis/apps/v1beta1/namespaces/{namespace}/deployments/{name}/status
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    BodyParameter

    body

    true

    v1.Patch

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the Deployment

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1beta1.Deployment

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      application/json-patch+json

      +
    • +
    • +

      application/merge-patch+json

      +
    • +
    • +

      application/strategic-merge-patch+json

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisappsv1beta1

      +
    • +
    +
    +
    +
    +
    +

    list or watch objects of kind StatefulSet

    +
    +
    +
    GET /apis/apps/v1beta1/namespaces/{namespace}/statefulsets
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1beta1.StatefulSetList

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    • +

      application/json;stream=watch

      +
    • +
    • +

      application/vnd.kubernetes.protobuf;stream=watch

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisappsv1beta1

      +
    • +
    +
    +
    +
    +
    +

    delete collection of StatefulSet

    +
    +
    +
    DELETE /apis/apps/v1beta1/namespaces/{namespace}/statefulsets
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.Status

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisappsv1beta1

      +
    • +
    +
    +
    +
    +
    +

    create a StatefulSet

    +
    +
    +
    POST /apis/apps/v1beta1/namespaces/{namespace}/statefulsets
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + - - + + - + + + + + + + + + @@ -2571,7 +4001,7 @@

    Parameters

    -

    Responses

    +

    Responses

    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    pretty

    If true, then the output is pretty printed.

    false

    integer (int32)

    string

    BodyParameter

    body

    true

    v1beta1.StatefulSet

    @@ -2589,14 +4019,14 @@

    Responses

    - +

    200

    success

    v1beta1.StatefulSetList

    v1beta1.StatefulSet

    -

    Consumes

    +

    Consumes

    • @@ -2606,7 +4036,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2618,17 +4048,146 @@

      Produces

    • application/vnd.kubernetes.protobuf

    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisappsv1beta1

      +
    • +
    +
    +
    +
    +
    +

    read the specified StatefulSet

    +
    +
    +
    GET /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    export

    Should this value be exported. Export strips fields that a user can not specify.

    false

    boolean

    QueryParameter

    exact

    Should the export be exact. Exact export maintains cluster-specific fields like Namespace.

    false

    boolean

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the StatefulSet

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1beta1.StatefulSet

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • -

      application/json;stream=watch

      +

      application/yaml

    • -

      application/vnd.kubernetes.protobuf;stream=watch

      +

      application/vnd.kubernetes.protobuf

    -

    Tags

    +

    Tags

    • @@ -2639,14 +4198,14 @@

      Tags

    -

    delete collection of StatefulSet

    +

    replace the specified StatefulSet

    -
    DELETE /apis/apps/v1beta1/namespaces/{namespace}/statefulsets
    +
    PUT /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}
    -

    Parameters

    +

    Parameters

    @@ -2676,57 +4235,25 @@

    Parameters

    - - - - - - - - - - - - - - - - - - - - - + + - - - - - - - + + - - - - + + + + - - - - - - - - - - + + @@ -2736,7 +4263,7 @@

    Parameters

    -

    Responses

    +

    Responses

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    BodyParameter

    body

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    true

    v1beta1.StatefulSet

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    name

    name of the StatefulSet

    true

    string

    @@ -2754,14 +4281,14 @@

    Responses

    - +

    200

    success

    v1.Status

    v1beta1.StatefulSet

    -

    Consumes

    +

    Consumes

    • @@ -2771,7 +4298,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2787,7 +4314,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -2798,14 +4325,14 @@

      Tags

    -

    create a StatefulSet

    +

    delete a StatefulSet

    -
    POST /apis/apps/v1beta1/namespaces/{namespace}/statefulsets
    +
    DELETE /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}
    -

    Parameters

    +

    Parameters

    @@ -2839,7 +4366,31 @@

    Parameters

    - + + + + + + + + + + + + + + + + + + + + + + + + + @@ -2850,12 +4401,20 @@

    Parameters

    + + + + + + + +

    body

    true

    v1beta1.StatefulSet

    v1.DeleteOptions

    QueryParameter

    gracePeriodSeconds

    The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.

    false

    integer (int32)

    QueryParameter

    orphanDependents

    Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the "orphan" finalizer will be added to/removed from the object’s finalizers list. Either this field or PropagationPolicy may be set, but not both.

    false

    boolean

    QueryParameter

    propagationPolicy

    Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.

    false

    string

    string

    PathParameter

    name

    name of the StatefulSet

    true

    string

    -

    Responses

    +

    Responses

    @@ -2873,14 +4432,14 @@

    Responses

    - +

    200

    success

    v1beta1.StatefulSet

    v1.Status

    -

    Consumes

    +

    Consumes

    • @@ -2890,7 +4449,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2906,7 +4465,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -2917,14 +4476,14 @@

      Tags

    -

    read the specified StatefulSet

    +

    partially update the specified StatefulSet

    -
    GET /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}
    +
    PATCH /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}
    -

    Parameters

    +

    Parameters

    @@ -2954,19 +4513,11 @@

    Parameters

    - - - - - + + - - - - - - - + + @@ -2990,7 +4541,7 @@

    Parameters

    -

    Responses

    +

    Responses

    QueryParameter

    export

    Should this value be exported. Export strips fields that a user can not specify.

    false

    boolean

    BodyParameter

    body

    QueryParameter

    exact

    Should the export be exact. Exact export maintains cluster-specific fields like Namespace.

    false

    boolean

    true

    v1.Patch

    @@ -3015,17 +4566,23 @@

    Responses

    -

    Consumes

    +

    Consumes

    • -

      /

      +

      application/json-patch+json

      +
    • +
    • +

      application/merge-patch+json

      +
    • +
    • +

      application/strategic-merge-patch+json

    -

    Produces

    +

    Produces

    • @@ -3041,7 +4598,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3052,14 +4609,14 @@

      Tags

    -

    replace the specified StatefulSet

    +

    read status of the specified StatefulSet

    -
    PUT /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}
    +
    GET /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}/status
    -

    Parameters

    +

    Parameters

    @@ -3089,14 +4646,6 @@

    Parameters

    - - - - - - - - @@ -3117,7 +4666,7 @@

    Parameters

    -

    Responses

    +

    Responses

    BodyParameter

    body

    true

    v1beta1.StatefulSet

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    @@ -3142,7 +4691,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3152,7 +4701,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3168,7 +4717,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3179,14 +4728,14 @@

      Tags

    -

    delete a StatefulSet

    +

    replace status of the specified StatefulSet

    -
    DELETE /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}
    +
    PUT /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}/status
    -

    Parameters

    +

    Parameters

    @@ -3220,31 +4769,7 @@

    Parameters

    - - - - - - - - - - - - - - - - - - - - - - - - - + @@ -3268,7 +4793,7 @@

    Parameters

    -

    Responses

    +

    Responses

    body

    true

    v1.DeleteOptions

    QueryParameter

    gracePeriodSeconds

    The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.

    false

    integer (int32)

    QueryParameter

    orphanDependents

    Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the "orphan" finalizer will be added to/removed from the object’s finalizers list. Either this field or PropagationPolicy may be set, but not both.

    false

    boolean

    QueryParameter

    propagationPolicy

    Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.

    false

    string

    v1beta1.StatefulSet

    @@ -3286,14 +4811,14 @@

    Responses

    - +

    200

    success

    v1.Status

    v1beta1.StatefulSet

    -

    Consumes

    +

    Consumes

    • @@ -3303,7 +4828,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3319,7 +4844,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3330,14 +4855,14 @@

      Tags

    -

    partially update the specified StatefulSet

    +

    partially update status of the specified StatefulSet

    -
    PATCH /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}
    +
    PATCH /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}/status
    -

    Parameters

    +

    Parameters

    @@ -3395,7 +4920,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3420,7 +4945,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3436,7 +4961,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3452,7 +4977,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3463,14 +4988,14 @@

      Tags

    -

    read status of the specified StatefulSet

    +

    list or watch objects of kind StatefulSet

    -
    GET /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}/status
    +
    GET /apis/apps/v1beta1/statefulsets
    -

    Parameters

    +

    Parameters

    @@ -3489,38 +5014,70 @@

    Parameters

    - - + + + + + + + + + + + + + + + + + + - - + + - - - - - + + + + + - - - - + + + + + + + + + + + + + + + + + + + +
    Schema Default

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    PathParameter

    name

    name of the StatefulSet

    true

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    -

    Responses

    +

    Responses

    @@ -3538,14 +5095,14 @@

    Responses

    - +

    200

    success

    v1beta1.StatefulSet

    v1beta1.StatefulSetList

    -

    Consumes

    +

    Consumes

    • @@ -3555,7 +5112,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3567,11 +5124,17 @@

      Produces

    • application/vnd.kubernetes.protobuf

    • +
    • +

      application/json;stream=watch

      +
    • +
    • +

      application/vnd.kubernetes.protobuf;stream=watch

      +
    -

    Tags

    +

    Tags

    • @@ -3582,14 +5145,14 @@

      Tags

    -

    replace status of the specified StatefulSet

    +

    watch individual changes to a list of ControllerRevision

    -
    PUT /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}/status
    +
    GET /apis/apps/v1beta1/watch/controllerrevisions
    -

    Parameters

    +

    Parameters

    @@ -3619,35 +5182,59 @@

    Parameters

    - - - - - + + + + + - - - - + + + + - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    BodyParameter

    body

    true

    v1beta1.StatefulSet

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    PathParameter

    name

    name of the StatefulSet

    true

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    -

    Responses

    +

    Responses

    @@ -3665,14 +5252,14 @@

    Responses

    - +

    200

    success

    v1beta1.StatefulSet

    v1.WatchEvent

    -

    Consumes

    +

    Consumes

    • @@ -3682,7 +5269,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3694,11 +5281,17 @@

      Produces

    • application/vnd.kubernetes.protobuf

    • +
    • +

      application/json;stream=watch

      +
    • +
    • +

      application/vnd.kubernetes.protobuf;stream=watch

      +
    -

    Tags

    +

    Tags

    • @@ -3709,14 +5302,14 @@

      Tags

    -

    partially update status of the specified StatefulSet

    +

    watch individual changes to a list of Deployment

    -
    PATCH /apis/apps/v1beta1/namespaces/{namespace}/statefulsets/{name}/status
    +
    GET /apis/apps/v1beta1/watch/deployments
    -

    Parameters

    +

    Parameters

    @@ -3746,35 +5339,59 @@

    Parameters

    - - - - - + + + + + - - - - + + + + - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    BodyParameter

    body

    true

    v1.Patch

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    PathParameter

    name

    name of the StatefulSet

    true

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    -

    Responses

    +

    Responses

    @@ -3792,30 +5409,24 @@

    Responses

    - +

    200

    success

    v1beta1.StatefulSet

    v1.WatchEvent

    -

    Consumes

    +

    Consumes

    • -

      application/json-patch+json

      -
    • -
    • -

      application/merge-patch+json

      -
    • -
    • -

      application/strategic-merge-patch+json

      +

      /

    -

    Produces

    +

    Produces

    • @@ -3827,11 +5438,17 @@

      Produces

    • application/vnd.kubernetes.protobuf

    • +
    • +

      application/json;stream=watch

      +
    • +
    • +

      application/vnd.kubernetes.protobuf;stream=watch

      +
    -

    Tags

    +

    Tags

    • @@ -3842,14 +5459,14 @@

      Tags

    -

    list or watch objects of kind StatefulSet

    +

    watch individual changes to a list of ControllerRevision

    -
    GET /apis/apps/v1beta1/statefulsets
    +
    GET /apis/apps/v1beta1/watch/namespaces/{namespace}/controllerrevisions
    -

    Parameters

    +

    Parameters

    @@ -3926,12 +5543,20 @@

    Parameters

    + + + + + + + +

    integer (int32)

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    -

    Responses

    +

    Responses

    @@ -3949,14 +5574,14 @@

    Responses

    - +

    200

    success

    v1beta1.StatefulSetList

    v1.WatchEvent

    -

    Consumes

    +

    Consumes

    • @@ -3966,7 +5591,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3988,7 +5613,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3999,14 +5624,14 @@

      Tags

    -

    watch individual changes to a list of Deployment

    +

    watch changes to an object of kind ControllerRevision

    -
    GET /apis/apps/v1beta1/watch/deployments
    +
    GET /apis/apps/v1beta1/watch/namespaces/{namespace}/controllerrevisions/{name}
    -

    Parameters

    +

    Parameters

    @@ -4083,12 +5708,28 @@

    Parameters

    + + + + + + + + + + + + + + + +

    integer (int32)

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the ControllerRevision

    true

    string

    -

    Responses

    +

    Responses

    @@ -4113,7 +5754,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4123,7 +5764,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4145,7 +5786,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4163,7 +5804,7 @@

      watch individual ch

    -

    Parameters

    +

    Parameters

    @@ -4253,7 +5894,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4278,7 +5919,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4288,7 +5929,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4310,7 +5951,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4328,7 +5969,7 @@

      watch changes to an obje

    -

    Parameters

    +

    Parameters

    @@ -4426,7 +6067,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4451,7 +6092,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4461,7 +6102,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4483,7 +6124,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4501,7 +6142,7 @@

      watch individual cha

    -

    Parameters

    +

    Parameters

    @@ -4591,7 +6232,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4616,7 +6257,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4626,7 +6267,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4648,7 +6289,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4666,7 +6307,7 @@

      watch changes to an obj

    -

    Parameters

    +

    Parameters

    @@ -4764,7 +6405,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4789,7 +6430,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4799,7 +6440,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4821,7 +6462,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4839,7 +6480,7 @@

      watch individual c

    -

    Parameters

    +

    Parameters

    @@ -4921,7 +6562,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4946,7 +6587,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4956,7 +6597,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4978,7 +6619,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4993,7 +6634,7 @@

      Tags

    diff --git a/docs/api-reference/batch/v1/definitions.html b/docs/api-reference/batch/v1/definitions.html index 608b99f879aa8..ca691a16b982c 100755 --- a/docs/api-reference/batch/v1/definitions.html +++ b/docs/api-reference/batch/v1/definitions.html @@ -1663,6 +1663,13 @@

    v1.EmptyDirVolumeSource

    + + + + + + +

    string

    sizeLimit

    Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir

    false

    string

    @@ -5705,7 +5712,7 @@

    any

    diff --git a/docs/api-reference/batch/v2alpha1/definitions.html b/docs/api-reference/batch/v2alpha1/definitions.html index 135f7ad3fffcf..e9c5ac7b15e50 100755 --- a/docs/api-reference/batch/v2alpha1/definitions.html +++ b/docs/api-reference/batch/v2alpha1/definitions.html @@ -1663,6 +1663,13 @@

    v1.EmptyDirVolumeSource

    string

    + +

    sizeLimit

    +

    Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir

    +

    false

    +

    string

    + + @@ -5801,7 +5808,7 @@

    any

    diff --git a/docs/api-reference/extensions/v1beta1/definitions.html b/docs/api-reference/extensions/v1beta1/definitions.html index 36d660a86b1a8..986de03ebce6e 100755 --- a/docs/api-reference/extensions/v1beta1/definitions.html +++ b/docs/api-reference/extensions/v1beta1/definitions.html @@ -2605,6 +2605,13 @@

    v1.EmptyDirVolumeSource

    string

    + +

    sizeLimit

    +

    Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir

    +

    false

    +

    string

    + + @@ -3007,7 +3014,7 @@

    v1beta1.RollbackConfig

    revision

    -

    The revision to rollback to. If set to 0, rollbck to the last revision.

    +

    The revision to rollback to. If set to 0, rollback to the last revision.

    false

    integer (int64)

    @@ -5211,6 +5218,9 @@

    v1.ScaleIOVolumeSource

    v1beta1.NetworkPolicy

    +
    +

    NetworkPolicy describes what network traffic is allowed for a set of Pods

    +
    @@ -5466,7 +5476,7 @@

    v1beta1.NetworkPolicySpec

    - + @@ -7652,6 +7662,13 @@

    v1beta1.PodSecurityPolicySpec

    + + + + + + +

    ingress

    List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, OR if the traffic source is the pod’s local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not affect ingress isolation. If this field is present and contains at least one rule, this policy allows any traffic which matches at least one of the ingress rules in this list.

    List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod OR if the traffic source is the pod’s local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default).

    false

    v1beta1.NetworkPolicyIngressRule array

    boolean

    false

    allowedHostPaths

    AllowedHostPaths is a white list of allowed host path prefixes. Empty indicates that all host paths may be used.

    false

    string array

    @@ -8117,7 +8134,7 @@

    any

    diff --git a/docs/api-reference/networking.k8s.io/v1/definitions.html b/docs/api-reference/networking.k8s.io/v1/definitions.html new file mode 100755 index 0000000000000..05f5efa0f1327 --- /dev/null +++ b/docs/api-reference/networking.k8s.io/v1/definitions.html @@ -0,0 +1,1590 @@ + + + + + + +Codestin Search App + + + + +
    +
    +

    Top Level API Objects

    + +
    +
    +

    Definitions

    +
    +
    +

    v1.APIResourceList

    +
    +

    APIResourceList is a list of APIResource, it is used to expose the name of the resources supported in a specific group and version, and if the resource is namespaced.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    kind

    Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

    false

    string

    apiVersion

    APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

    false

    string

    groupVersion

    groupVersion is the group and version this APIResourceList is for.

    true

    string

    resources

    resources contains the name of the resources and if they are namespaced.

    true

    v1.APIResource array

    + +
    +
    +

    v1.Patch

    +
    +

    Patch is provided to give a concrete name and type to the Kubernetes PATCH request body.

    +
    +
    +
    +

    v1.NetworkPolicyIngressRule

    +
    +

    NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods matched by a NetworkPolicySpec’s podSelector. The traffic must match both ports and from.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    ports

    List of ports which should be made accessible on the pods selected for this rule. Each item in this list is combined using a logical OR. If this field is empty or missing, this rule matches all ports (traffic not restricted by port). If this field is present and contains at least one item, then this rule allows traffic only if the traffic matches at least one port in the list.

    false

    v1.NetworkPolicyPort array

    from

    List of sources which should be able to access the pods selected for this rule. Items in this list are combined using a logical OR operation. If this field is empty or missing, this rule matches all sources (traffic not restricted by source). If this field is present and contains at least on item, this rule allows traffic only if the traffic matches at least one item in the from list.

    false

    v1.NetworkPolicyPeer array

    + +
    +
    +

    v1.DeleteOptions

    +
    +

    DeleteOptions may be provided when deleting an API object.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    kind

    Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

    false

    string

    apiVersion

    APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

    false

    string

    gracePeriodSeconds

    The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.

    false

    integer (int64)

    preconditions

    Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned.

    false

    v1.Preconditions

    orphanDependents

    Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the "orphan" finalizer will be added to/removed from the object’s finalizers list. Either this field or PropagationPolicy may be set, but not both.

    false

    boolean

    false

    propagationPolicy

    Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.

    false

    v1.DeletionPropagation

    + +
    +
    +

    v1.Protocol

    + +
    +
    +

    v1.ListMeta

    +
    +

    ListMeta describes metadata that synthetic resources must have, including lists and various status objects. A resource may have only one of {ObjectMeta, ListMeta}.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    selfLink

    SelfLink is a URL representing this object. Populated by the system. Read-only.

    false

    string

    resourceVersion

    String that identifies the server’s internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency

    false

    string

    + +
    +
    +

    v1.StatusDetails

    +
    +

    StatusDetails is a set of additional properties that MAY be set by the server to provide additional information about a response. The Reason field of a Status object defines what attributes will be set. Clients must ignore fields that do not match the defined type of each attribute, and should assume that any attribute may be empty, invalid, or under defined.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    name

    The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described).

    false

    string

    group

    The group attribute of the resource associated with the status StatusReason.

    false

    string

    kind

    The kind attribute of the resource associated with the status StatusReason. On some operations may differ from the requested resource Kind. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

    false

    string

    uid

    UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids

    false

    string

    causes

    The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes.

    false

    v1.StatusCause array

    retryAfterSeconds

    If specified, the time in seconds before the operation should be retried.

    false

    integer (int32)

    + +
    +
    +

    v1.Preconditions

    +
    +

    Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    uid

    Specifies the target UID.

    false

    types.UID

    + +
    +
    +

    v1.Initializers

    +
    +

    Initializers tracks the progress of initialization.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    pending

    Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients.

    true

    v1.Initializer array

    result

    If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion.

    false

    v1.Status

    + +
    +
    +

    v1.Initializer

    +
    +

    Initializer is information about an initializer that has not yet completed.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    name

    name of the process that is responsible for initializing this object.

    true

    string

    + +
    +
    +

    v1.Status

    +
    +

    Status is a return value for calls that don’t return other objects.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    kind

    Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

    false

    string

    apiVersion

    APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

    false

    string

    metadata

    Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

    false

    v1.ListMeta

    status

    Status of the operation. One of: "Success" or "Failure". More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status

    false

    string

    message

    A human-readable description of the status of this operation.

    false

    string

    reason

    A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it.

    false

    string

    details

    Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type.

    false

    v1.StatusDetails

    code

    Suggested HTTP return code for this status, 0 if not set.

    false

    integer (int32)

    + +
    +
    +

    v1.WatchEvent

    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    type

    true

    string

    object

    true

    string

    + +
    +
    +

    v1.NetworkPolicyPort

    +
    +

    NetworkPolicyPort describes a port to allow traffic on

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    protocol

    The protocol (TCP or UDP) which traffic must match. If not specified, this field defaults to TCP.

    false

    v1.Protocol

    port

    The port on the given protocol. This can either be a numerical or named port on a pod. If this field is not provided, this matches all port names and numbers.

    false

    string

    + +
    +
    +

    v1.LabelSelector

    +
    +

    A label selector is a label query over a set of resources. The result of matchLabels and matchExpressions are ANDed. An empty label selector matches all objects. A null label selector matches no objects.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    matchLabels

    matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed.

    false

    object

    matchExpressions

    matchExpressions is a list of label selector requirements. The requirements are ANDed.

    false

    v1.LabelSelectorRequirement array

    + +
    +
    +

    v1.ObjectMeta

    +
    +

    ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    name

    Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names

    false

    string

    generateName

    GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server.
    +
    +If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header).
    +
    +Applied only if Name is not specified. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#idempotency

    false

    string

    namespace

    Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty.
    +
    +Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces

    false

    string

    selfLink

    SelfLink is a URL representing this object. Populated by the system. Read-only.

    false

    string

    uid

    UID is the unique in time and space value for this object. It is typically generated by the server on successful creation of a resource and is not allowed to change on PUT operations.
    +
    +Populated by the system. Read-only. More info: http://kubernetes.io/docs/user-guide/identifiers#uids

    false

    string

    resourceVersion

    An opaque value that represents the internal version of this object that can be used by clients to determine when objects have changed. May be used for optimistic concurrency, change detection, and the watch operation on a resource or set of resources. Clients must treat these values as opaque and passed unmodified back to the server. They may only be valid for a particular resource or set of resources.
    +
    +Populated by the system. Read-only. Value must be treated as opaque by clients and . More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency

    false

    string

    generation

    A sequence number representing a specific generation of the desired state. Populated by the system. Read-only.

    false

    integer (int64)

    creationTimestamp

    CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.
    +
    +Populated by the system. Read-only. Null for lists. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata

    false

    string

    deletionTimestamp

    DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource is expected to be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field. Once set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, remove the pod from the API. In the presence of network partitions, this object may still exist after this timestamp, until an administrator or automated process can determine the resource is fully terminated. If not set, graceful deletion of the object has not been requested.
    +
    +Populated by the system when a graceful deletion is requested. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata

    false

    string

    deletionGracePeriodSeconds

    Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only.

    false

    integer (int64)

    labels

    Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels

    false

    object

    annotations

    Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations

    false

    object

    ownerReferences

    List of objects depended by this object. If ALL objects in the list have been deleted, this object will be garbage collected. If this object is managed by a controller, then an entry in this list will point to this controller, with the controller field set to true. There cannot be more than one managing controller.

    false

    v1.OwnerReference array

    initializers

    An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven’t explicitly asked to observe uninitialized objects.
    +
    +When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user.

    false

    v1.Initializers

    finalizers

    Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed.

    false

    string array

    clusterName

    The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request.

    false

    string

    + +
    +
    +

    v1.OwnerReference

    +
    +

    OwnerReference contains enough information to let you identify an owning object. Currently, an owning object must be in the same namespace, so there is no namespace field.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    apiVersion

    API version of the referent.

    true

    string

    kind

    Kind of the referent. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

    true

    string

    name

    Name of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#names

    true

    string

    uid

    UID of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#uids

    true

    string

    controller

    If true, this reference points to the managing controller.

    false

    boolean

    false

    blockOwnerDeletion

    If true, AND if the owner has the "foregroundDeletion" finalizer, then the owner cannot be deleted from the key-value store until this reference is removed. Defaults to false. To set this field, a user needs "delete" permission of the owner, otherwise 422 (Unprocessable Entity) will be returned.

    false

    boolean

    false

    + +
    +
    +

    v1.NetworkPolicySpec

    +
    +

    NetworkPolicySpec provides the specification of a NetworkPolicy

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    podSelector

    Selects the pods to which this NetworkPolicy object applies. The array of ingress rules is applied to any pods selected by this field. Multiple network policies can select the same set of pods. In this case, the ingress rules for each are combined additively. This field is NOT optional and follows standard label selector semantics. An empty podSelector matches all pods in this namespace.

    true

    v1.LabelSelector

    ingress

    List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod (and cluster policy otherwise allows the traffic), OR if the traffic source is the pod’s local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default)

    false

    v1.NetworkPolicyIngressRule array

    + +
    +
    +

    v1.LabelSelectorRequirement

    +
    +

    A label selector requirement is a selector that contains values, a key, and an operator that relates the key and values.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    key

    key is the label key that the selector applies to.

    true

    string

    operator

    operator represents a key’s relationship to a set of values. Valid operators ard In, NotIn, Exists and DoesNotExist.

    true

    string

    values

    values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.

    false

    string array

    + +
    +
    +

    v1.NetworkPolicy

    +
    +

    NetworkPolicy describes what network traffic is allowed for a set of Pods

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    kind

    Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

    false

    string

    apiVersion

    APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

    false

    string

    metadata

    Standard object’s metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata

    false

    v1.ObjectMeta

    spec

    Specification of the desired behavior for this NetworkPolicy.

    false

    v1.NetworkPolicySpec

    + +
    +
    +

    v1.APIResource

    +
    +

    APIResource specifies the name of a resource and whether it is namespaced.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    name

    name is the plural name of the resource.

    true

    string

    singularName

    singularName is the singular name of the resource. This allows clients to handle plural and singular opaquely. The singularName is more correct for reporting status on a single item and both singular and plural are allowed from the kubectl CLI interface.

    true

    string

    namespaced

    namespaced indicates if a resource is namespaced or not.

    true

    boolean

    false

    kind

    kind is the kind for the resource (e.g. Foo is the kind for a resource foo)

    true

    string

    verbs

    verbs is a list of supported kube verbs (this includes get, list, watch, create, update, patch, delete, deletecollection, and proxy)

    true

    string array

    shortNames

    shortNames is a list of suggested short names of the resource.

    false

    string array

    + +
    +
    +

    v1.NetworkPolicyPeer

    +
    +

    NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields must be specified.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    podSelector

    This is a label selector which selects Pods in this namespace. This field follows standard label selector semantics. If present but empty, this selector selects all pods in this namespace.

    false

    v1.LabelSelector

    namespaceSelector

    Selects Namespaces using cluster scoped-labels. This matches all pods in all namespaces selected by this label selector. This field follows standard label selector semantics. If present but empty, this selector selects all namespaces.

    false

    v1.LabelSelector

    + +
    +
    +

    types.UID

    + +
    +
    +

    v1.StatusCause

    +
    +

    StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    reason

    A machine-readable description of the cause of the error. If this value is empty there is no information available.

    false

    string

    message

    A human-readable description of the cause of the error. This field may be presented as-is to a reader.

    false

    string

    field

    The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional.
    +
    +Examples:
    + "name" - the field "name" on the current resource
    + "items[0].name" - the field "name" on the first array entry in "items"

    false

    string

    + +
    +
    +

    v1.DeletionPropagation

    + +
    +
    +

    v1.NetworkPolicyList

    +
    +

    NetworkPolicyList is a list of NetworkPolicy objects.

    +
    + +++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameDescriptionRequiredSchemaDefault

    kind

    Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds

    false

    string

    apiVersion

    APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources

    false

    string

    metadata

    Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata

    false

    v1.ListMeta

    items

    Items is a list of schema objects.

    true

    v1.NetworkPolicy array

    + +
    +
    +

    any

    +
    +

    Represents an untyped JSON map - see the description of the field for more info about the structure of this object.

    +
    +
    +
    +
    +
    + + + \ No newline at end of file diff --git a/docs/api-reference/networking.k8s.io/v1/operations.html b/docs/api-reference/networking.k8s.io/v1/operations.html new file mode 100755 index 0000000000000..83f67df932fb7 --- /dev/null +++ b/docs/api-reference/networking.k8s.io/v1/operations.html @@ -0,0 +1,2095 @@ + + + + + + +Codestin Search App + + + + +
    +
    +

    Operations

    +
    +
    +

    get available resources

    +
    +
    +
    GET /apis/networking.k8s.io/v1
    +
    +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    default

    success

    v1.APIResourceList

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisnetworking.k8s.iov1

      +
    • +
    +
    +
    +
    +
    +

    list or watch objects of kind NetworkPolicy

    +
    +
    +
    GET /apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.NetworkPolicyList

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    • +

      application/json;stream=watch

      +
    • +
    • +

      application/vnd.kubernetes.protobuf;stream=watch

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisnetworking.k8s.iov1

      +
    • +
    +
    +
    +
    +
    +

    delete collection of NetworkPolicy

    +
    +
    +
    DELETE /apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.Status

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisnetworking.k8s.iov1

      +
    • +
    +
    +
    +
    +
    +

    create a NetworkPolicy

    +
    +
    +
    POST /apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    BodyParameter

    body

    true

    v1.NetworkPolicy

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.NetworkPolicy

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisnetworking.k8s.iov1

      +
    • +
    +
    +
    +
    +
    +

    read the specified NetworkPolicy

    +
    +
    +
    GET /apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    export

    Should this value be exported. Export strips fields that a user can not specify.

    false

    boolean

    QueryParameter

    exact

    Should the export be exact. Exact export maintains cluster-specific fields like Namespace.

    false

    boolean

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the NetworkPolicy

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.NetworkPolicy

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisnetworking.k8s.iov1

      +
    • +
    +
    +
    +
    +
    +

    replace the specified NetworkPolicy

    +
    +
    +
    PUT /apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    BodyParameter

    body

    true

    v1.NetworkPolicy

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the NetworkPolicy

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.NetworkPolicy

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisnetworking.k8s.iov1

      +
    • +
    +
    +
    +
    +
    +

    delete a NetworkPolicy

    +
    +
    +
    DELETE /apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    BodyParameter

    body

    true

    v1.DeleteOptions

    QueryParameter

    gracePeriodSeconds

    The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.

    false

    integer (int32)

    QueryParameter

    orphanDependents

    Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the "orphan" finalizer will be added to/removed from the object’s finalizers list. Either this field or PropagationPolicy may be set, but not both.

    false

    boolean

    QueryParameter

    propagationPolicy

    Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.

    false

    string

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the NetworkPolicy

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.Status

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisnetworking.k8s.iov1

      +
    • +
    +
    +
    +
    +
    +

    partially update the specified NetworkPolicy

    +
    +
    +
    PATCH /apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    BodyParameter

    body

    true

    v1.Patch

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the NetworkPolicy

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.NetworkPolicy

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      application/json-patch+json

      +
    • +
    • +

      application/merge-patch+json

      +
    • +
    • +

      application/strategic-merge-patch+json

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisnetworking.k8s.iov1

      +
    • +
    +
    +
    +
    +
    +

    list or watch objects of kind NetworkPolicy

    +
    +
    +
    GET /apis/networking.k8s.io/v1/networkpolicies
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.NetworkPolicyList

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    • +

      application/json;stream=watch

      +
    • +
    • +

      application/vnd.kubernetes.protobuf;stream=watch

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisnetworking.k8s.iov1

      +
    • +
    +
    +
    +
    +
    +

    watch individual changes to a list of NetworkPolicy

    +
    +
    +
    GET /apis/networking.k8s.io/v1/watch/namespaces/{namespace}/networkpolicies
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.WatchEvent

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    • +

      application/json;stream=watch

      +
    • +
    • +

      application/vnd.kubernetes.protobuf;stream=watch

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisnetworking.k8s.iov1

      +
    • +
    +
    +
    +
    +
    +

    watch changes to an object of kind NetworkPolicy

    +
    +
    +
    GET /apis/networking.k8s.io/v1/watch/namespaces/{namespace}/networkpolicies/{name}
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the NetworkPolicy

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.WatchEvent

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    • +

      application/json;stream=watch

      +
    • +
    • +

      application/vnd.kubernetes.protobuf;stream=watch

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisnetworking.k8s.iov1

      +
    • +
    +
    +
    +
    +
    +

    watch individual changes to a list of NetworkPolicy

    +
    +
    +
    GET /apis/networking.k8s.io/v1/watch/networkpolicies
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.WatchEvent

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    • +

      application/json;stream=watch

      +
    • +
    • +

      application/vnd.kubernetes.protobuf;stream=watch

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apisnetworking.k8s.iov1

      +
    • +
    +
    +
    +
    +
    +
    +
    + + + \ No newline at end of file diff --git a/docs/api-reference/settings.k8s.io/v1alpha1/definitions.html b/docs/api-reference/settings.k8s.io/v1alpha1/definitions.html index 71354c8801fb0..10a1675bdf8a0 100755 --- a/docs/api-reference/settings.k8s.io/v1alpha1/definitions.html +++ b/docs/api-reference/settings.k8s.io/v1alpha1/definitions.html @@ -2218,6 +2218,13 @@

    v1.EmptyDirVolumeSource

    string

    + +

    sizeLimit

    +

    Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir

    +

    false

    +

    string

    + + @@ -3943,7 +3950,7 @@

    any

    diff --git a/docs/api-reference/v1/definitions.html b/docs/api-reference/v1/definitions.html index 40acd217f2108..e81bd174e46f3 100755 --- a/docs/api-reference/v1/definitions.html +++ b/docs/api-reference/v1/definitions.html @@ -2744,6 +2744,13 @@

    v1.EmptyDirVolumeSource

    string

    + +

    sizeLimit

    +

    Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir

    +

    false

    +

    string

    + + @@ -10098,7 +10105,7 @@

    any

    diff --git a/docs/api-reference/v1/operations.html b/docs/api-reference/v1/operations.html index 7e985a21ec33d..c0bb2debda008 100755 --- a/docs/api-reference/v1/operations.html +++ b/docs/api-reference/v1/operations.html @@ -1496,10 +1496,10 @@

    Tags

    -

    delete collection of Namespace

    +

    create a Namespace

    -
    DELETE /api/v1/namespaces
    +
    POST /api/v1/namespaces
    @@ -1533,51 +1533,11 @@

    Parameters

    -

    QueryParameter

    -

    labelSelector

    -

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    -

    false

    -

    string

    - - - -

    QueryParameter

    -

    fieldSelector

    -

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    -

    false

    -

    string

    - - - -

    QueryParameter

    -

    includeUninitialized

    -

    If true, partially initialized resources are included in the response.

    -

    false

    -

    boolean

    - - - -

    QueryParameter

    -

    watch

    -

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    -

    false

    -

    boolean

    - - - -

    QueryParameter

    -

    resourceVersion

    -

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    -

    false

    -

    string

    +

    BodyParameter

    +

    body

    - - -

    QueryParameter

    -

    timeoutSeconds

    -

    Timeout for the list/watch call.

    -

    false

    -

    integer (int32)

    +

    true

    +

    v1.Namespace

    @@ -1603,7 +1563,7 @@

    Responses

    200

    success

    -

    v1.Status

    +

    v1.Namespace

    @@ -1647,10 +1607,10 @@

    Tags

    -

    create a Namespace

    +

    create a Binding

    -
    POST /api/v1/namespaces
    +
    POST /api/v1/namespaces/{namespace}/bindings
    @@ -1688,7 +1648,15 @@

    Parameters

    body

    true

    -

    v1.Namespace

    +

    v1.Binding

    + + + +

    PathParameter

    +

    namespace

    +

    object name and auth scope, such as for teams and projects

    +

    true

    +

    string

    @@ -1714,7 +1682,7 @@

    Responses

    200

    success

    -

    v1.Namespace

    +

    v1.Binding

    @@ -1758,10 +1726,10 @@

    Tags

    -

    create a Binding

    +

    list or watch objects of kind ConfigMap

    -
    POST /api/v1/namespaces/{namespace}/bindings
    +
    GET /api/v1/namespaces/{namespace}/configmaps
    @@ -1795,11 +1763,51 @@

    Parameters

    -

    BodyParameter

    -

    body

    +

    QueryParameter

    +

    labelSelector

    +

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    +

    false

    +

    string

    -

    true

    -

    v1.Binding

    + + +

    QueryParameter

    +

    fieldSelector

    +

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    +

    false

    +

    string

    + + + +

    QueryParameter

    +

    includeUninitialized

    +

    If true, partially initialized resources are included in the response.

    +

    false

    +

    boolean

    + + + +

    QueryParameter

    +

    watch

    +

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    +

    false

    +

    boolean

    + + + +

    QueryParameter

    +

    resourceVersion

    +

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    +

    false

    +

    string

    + + + +

    QueryParameter

    +

    timeoutSeconds

    +

    Timeout for the list/watch call.

    +

    false

    +

    integer (int32)

    @@ -1833,7 +1841,7 @@

    Responses

    200

    success

    -

    v1.Binding

    +

    v1.ConfigMapList

    @@ -1862,6 +1870,12 @@

    Produces

  • application/vnd.kubernetes.protobuf

  • +
  • +

    application/json;stream=watch

    +
  • +
  • +

    application/vnd.kubernetes.protobuf;stream=watch

    +
  • @@ -1877,10 +1891,10 @@

    Tags

    -

    list or watch objects of kind ConfigMap

    +

    delete collection of ConfigMap

    -
    GET /api/v1/namespaces/{namespace}/configmaps
    +
    DELETE /api/v1/namespaces/{namespace}/configmaps
    @@ -1992,7 +2006,7 @@

    Responses

    200

    success

    -

    v1.ConfigMapList

    +

    v1.Status

    @@ -2021,17 +2035,130 @@

    Produces

  • application/vnd.kubernetes.protobuf

  • + +
    +
    +
    +

    Tags

    +
    +
    • -

      application/json;stream=watch

      +

      apiv1

    • +
    +
    +
    +
    +
    +

    create a ConfigMap

    +
    +
    +
    POST /api/v1/namespaces/{namespace}/configmaps
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    BodyParameter

    body

    true

    v1.ConfigMap

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.ConfigMap

    + +
    +
    +

    Consumes

    +
    +
    • -

      application/vnd.kubernetes.protobuf;stream=watch

      +

      /

    -

    Tags

    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    • @@ -2042,292 +2169,14 @@

      Tags

    -

    delete collection of ConfigMap

    +

    read the specified ConfigMap

    -
    DELETE /api/v1/namespaces/{namespace}/configmaps
    +
    GET /api/v1/namespaces/{namespace}/configmaps/{name}
    -

    Parameters

    - -------- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    - -
    -
    -

    Responses

    - ----- - - - - - - - - - - - - - - -
    HTTP CodeDescriptionSchema

    200

    success

    v1.Status

    - -
    -
    -

    Consumes

    -
    -
      -
    • -

      /

      -
    • -
    -
    -
    -
    -

    Produces

    -
    -
      -
    • -

      application/json

      -
    • -
    • -

      application/yaml

      -
    • -
    • -

      application/vnd.kubernetes.protobuf

      -
    • -
    -
    -
    -
    -

    Tags

    -
    -
      -
    • -

      apiv1

      -
    • -
    -
    -
    -
    -
    -

    create a ConfigMap

    -
    -
    -
    POST /api/v1/namespaces/{namespace}/configmaps
    -
    -
    -
    -

    Parameters

    - -------- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    BodyParameter

    body

    true

    v1.ConfigMap

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    - -
    -
    -

    Responses

    - ----- - - - - - - - - - - - - - - -
    HTTP CodeDescriptionSchema

    200

    success

    v1.ConfigMap

    - -
    -
    -

    Consumes

    -
    -
      -
    • -

      /

      -
    • -
    -
    -
    -
    -

    Produces

    -
    -
      -
    • -

      application/json

      -
    • -
    • -

      application/yaml

      -
    • -
    • -

      application/vnd.kubernetes.protobuf

      -
    • -
    -
    -
    -
    -

    Tags

    -
    -
      -
    • -

      apiv1

      -
    • -
    -
    -
    -
    -
    -

    read the specified ConfigMap

    -
    -
    -
    GET /api/v1/namespaces/{namespace}/configmaps/{name}
    -
    -
    -
    -

    Parameters

    +

    Parameters

    @@ -2393,7 +2242,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -2418,7 +2267,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -2428,7 +2277,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2444,7 +2293,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -2462,7 +2311,7 @@

      replace the specified ConfigMap

    -

    Parameters

    +

    Parameters

    @@ -2520,7 +2369,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -2545,7 +2394,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -2555,7 +2404,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2571,7 +2420,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -2589,7 +2438,7 @@

      delete a ConfigMap

    -

    Parameters

    +

    Parameters

    @@ -2671,7 +2520,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -2696,7 +2545,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -2706,7 +2555,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2722,7 +2571,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -2740,7 +2589,7 @@

      partially update the specifie

    -

    Parameters

    +

    Parameters

    @@ -2798,7 +2647,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -2823,7 +2672,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -2839,7 +2688,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2855,7 +2704,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -2873,7 +2722,7 @@

      list or watch objects of kin

    -

    Parameters

    +

    Parameters

    @@ -2963,7 +2812,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -2988,7 +2837,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -2998,7 +2847,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3020,7 +2869,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3038,7 +2887,7 @@

      delete collection of Endpoints

    -

    Parameters

    +

    Parameters

    @@ -3128,7 +2977,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3153,7 +3002,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3163,7 +3012,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3179,7 +3028,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3197,7 +3046,7 @@

      create Endpoints

    -

    Parameters

    +

    Parameters

    @@ -3247,7 +3096,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3272,7 +3121,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3282,7 +3131,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3298,7 +3147,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3316,7 +3165,7 @@

      read the specified Endpoints

    -

    Parameters

    +

    Parameters

    @@ -3382,7 +3231,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3407,7 +3256,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3417,7 +3266,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3433,7 +3282,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3451,7 +3300,7 @@

      replace the specified Endpoints

    -

    Parameters

    +

    Parameters

    @@ -3509,7 +3358,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3534,7 +3383,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3544,7 +3393,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3560,7 +3409,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3578,7 +3427,7 @@

      delete Endpoints

    -

    Parameters

    +

    Parameters

    @@ -3660,7 +3509,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3685,7 +3534,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3695,7 +3544,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3711,7 +3560,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3729,7 +3578,7 @@

      partially update the specifie

    -

    Parameters

    +

    Parameters

    @@ -3787,7 +3636,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3812,7 +3661,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3828,7 +3677,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3844,7 +3693,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3862,7 +3711,7 @@

      list or watch objects of kind Ev

    -

    Parameters

    +

    Parameters

    @@ -3952,7 +3801,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3977,7 +3826,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3987,7 +3836,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4009,7 +3858,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4027,7 +3876,7 @@

      delete collection of Event

    -

    Parameters

    +

    Parameters

    @@ -4117,7 +3966,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4142,7 +3991,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4152,7 +4001,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4168,7 +4017,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4186,7 +4035,7 @@

      create an Event

    -

    Parameters

    +

    Parameters

    @@ -4236,7 +4085,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4261,7 +4110,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4271,7 +4120,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4287,7 +4136,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4305,7 +4154,7 @@

      read the specified Event

    -

    Parameters

    +

    Parameters

    @@ -4371,7 +4220,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4396,7 +4245,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4406,7 +4255,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4422,7 +4271,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4440,7 +4289,7 @@

      replace the specified Event

    -

    Parameters

    +

    Parameters

    @@ -4498,7 +4347,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4523,7 +4372,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4533,7 +4382,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4549,7 +4398,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4567,7 +4416,7 @@

      delete an Event

    -

    Parameters

    +

    Parameters

    @@ -4649,7 +4498,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4674,7 +4523,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4684,7 +4533,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4700,7 +4549,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4718,7 +4567,7 @@

      partially update the specified Ev

    -

    Parameters

    +

    Parameters

    @@ -4776,7 +4625,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4801,7 +4650,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4817,7 +4666,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4833,7 +4682,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4851,7 +4700,7 @@

      list or watch objects of ki

    -

    Parameters

    +

    Parameters

    @@ -4941,7 +4790,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4966,7 +4815,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4976,7 +4825,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4998,7 +4847,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5016,7 +4865,7 @@

      delete collection of LimitRange

    -

    Parameters

    +

    Parameters

    @@ -5106,7 +4955,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5131,7 +4980,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5141,7 +4990,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5157,7 +5006,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5175,7 +5024,7 @@

      create a LimitRange

    -

    Parameters

    +

    Parameters

    @@ -5225,7 +5074,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5250,7 +5099,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5260,7 +5109,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5276,7 +5125,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5294,7 +5143,7 @@

      read the specified LimitRange

    -

    Parameters

    +

    Parameters

    @@ -5360,7 +5209,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5385,7 +5234,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5395,7 +5244,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5411,7 +5260,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5429,7 +5278,7 @@

      replace the specified LimitRange

    -

    Parameters

    +

    Parameters

    @@ -5487,7 +5336,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5512,7 +5361,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5522,7 +5371,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5538,7 +5387,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5556,7 +5405,7 @@

      delete a LimitRange

    -

    Parameters

    +

    Parameters

    @@ -5638,7 +5487,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5663,7 +5512,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5673,7 +5522,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5689,7 +5538,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5707,7 +5556,7 @@

      partially update the specifi

    -

    Parameters

    +

    Parameters

    @@ -5765,7 +5614,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5790,7 +5639,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5806,7 +5655,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5822,7 +5671,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5840,7 +5689,7 @@

      list or watch obje

    -

    Parameters

    +

    Parameters

    @@ -5930,7 +5779,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5955,7 +5804,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5965,7 +5814,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5987,7 +5836,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6005,7 +5854,7 @@

      delete collection of Persis

    -

    Parameters

    +

    Parameters

    @@ -6095,7 +5944,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6120,7 +5969,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6130,7 +5979,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6146,7 +5995,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6164,7 +6013,7 @@

      create a PersistentVolumeClaim

    -

    Parameters

    +

    Parameters

    @@ -6214,7 +6063,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6239,7 +6088,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6249,7 +6098,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6265,7 +6114,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6283,7 +6132,7 @@

      read the specified Persistent

    -

    Parameters

    +

    Parameters

    @@ -6349,7 +6198,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6374,7 +6223,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6384,7 +6233,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6400,7 +6249,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6418,7 +6267,7 @@

      replace the specified Pers

    -

    Parameters

    +

    Parameters

    @@ -6476,7 +6325,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6501,7 +6350,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6511,7 +6360,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6527,7 +6376,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6545,7 +6394,7 @@

      delete a PersistentVolumeClaim

    -

    Parameters

    +

    Parameters

    @@ -6627,7 +6476,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6652,7 +6501,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6662,7 +6511,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6678,7 +6527,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6696,7 +6545,7 @@

      partially update

    -

    Parameters

    +

    Parameters

    @@ -6754,7 +6603,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6779,7 +6628,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6795,7 +6644,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6811,7 +6660,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6829,7 +6678,7 @@

      read status of the

    -

    Parameters

    +

    Parameters

    @@ -6879,7 +6728,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6904,7 +6753,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6914,7 +6763,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6930,7 +6779,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6948,7 +6797,7 @@

      replace status o

    -

    Parameters

    +

    Parameters

    @@ -7006,7 +6855,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -7031,7 +6880,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -7041,7 +6890,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -7057,7 +6906,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -7075,7 +6924,7 @@

      partial

    -

    Parameters

    +

    Parameters

    @@ -7133,7 +6982,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -7158,7 +7007,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -7174,7 +7023,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -7190,7 +7039,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -7208,7 +7057,7 @@

      list or watch objects of kind Pod

    -

    Parameters

    +

    Parameters

    @@ -7298,7 +7147,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -7323,7 +7172,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -7333,7 +7182,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -7355,7 +7204,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -7373,7 +7222,7 @@

      delete collection of Pod

    -

    Parameters

    +

    Parameters

    @@ -7463,7 +7312,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -7488,7 +7337,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -7498,7 +7347,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -7514,7 +7363,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -7532,7 +7381,7 @@

      create a Pod

    -

    Parameters

    +

    Parameters

    @@ -7582,7 +7431,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -7607,7 +7456,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -7617,7 +7466,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -7633,7 +7482,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -7651,7 +7500,7 @@

      read the specified Pod

    -

    Parameters

    +

    Parameters

    @@ -7717,7 +7566,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -7742,7 +7591,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -7752,7 +7601,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -7768,7 +7617,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -7786,7 +7635,7 @@

      replace the specified Pod

    -

    Parameters

    +

    Parameters

    @@ -7844,7 +7693,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -7869,7 +7718,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -7879,7 +7728,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -7895,7 +7744,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -7913,7 +7762,7 @@

      delete a Pod

    -

    Parameters

    +

    Parameters

    @@ -7995,7 +7844,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -8020,7 +7869,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -8030,7 +7879,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -8046,7 +7895,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -8064,7 +7913,7 @@

      partially update the specified Pod<

    -

    Parameters

    +

    Parameters

    @@ -8122,7 +7971,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -8147,7 +7996,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -8163,7 +8012,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -8179,7 +8028,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -8197,7 +8046,7 @@

      connect GET requests to attach o

    -

    Parameters

    +

    Parameters

    @@ -8279,7 +8128,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -8304,7 +8153,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -8314,7 +8163,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -8324,7 +8173,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -8342,7 +8191,7 @@

      connect POST requests to attach

    -

    Parameters

    +

    Parameters

    @@ -8424,7 +8273,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -8449,7 +8298,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -8459,7 +8308,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -8469,7 +8318,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -8487,7 +8336,7 @@

      create binding of a Binding

    -

    Parameters

    +

    Parameters

    @@ -8545,7 +8394,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -8570,7 +8419,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -8580,7 +8429,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -8596,7 +8445,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -8614,7 +8463,7 @@

      create eviction of an Eviction

    -

    Parameters

    +

    Parameters

    @@ -8672,7 +8521,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -8697,7 +8546,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -8707,7 +8556,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -8723,7 +8572,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -8741,7 +8590,7 @@

      connect GET requests to exec of Po

    -

    Parameters

    +

    Parameters

    @@ -8831,7 +8680,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -8856,7 +8705,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -8866,7 +8715,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -8876,7 +8725,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -8894,7 +8743,7 @@

      connect POST requests to exec of

    -

    Parameters

    +

    Parameters

    @@ -8984,7 +8833,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -9009,7 +8858,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -9019,7 +8868,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -9029,7 +8878,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -9047,7 +8896,7 @@

      read log of the specified Pod

    -

    Parameters

    +

    Parameters

    @@ -9153,7 +9002,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -9178,7 +9027,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -9188,7 +9037,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -9207,7 +9056,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -9225,7 +9074,7 @@

      connect GET requests to por

    -

    Parameters

    +

    Parameters

    @@ -9275,7 +9124,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -9300,7 +9149,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -9310,7 +9159,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -9320,7 +9169,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -9338,7 +9187,7 @@

      connect POST requests to p

    -

    Parameters

    +

    Parameters

    @@ -9388,7 +9237,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -9413,7 +9262,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -9423,7 +9272,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -9433,7 +9282,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -9451,7 +9300,7 @@

      connect GET requests to proxy of

    -

    Parameters

    +

    Parameters

    @@ -9501,7 +9350,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -9526,7 +9375,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -9536,7 +9385,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -9546,7 +9395,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -9564,7 +9413,7 @@

      connect PUT requests to proxy of

    -

    Parameters

    +

    Parameters

    @@ -9614,7 +9463,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -9639,7 +9488,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -9649,7 +9498,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -9659,7 +9508,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -9677,7 +9526,7 @@

      connect DELETE requests to pro

    -

    Parameters

    +

    Parameters

    @@ -9727,7 +9576,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -9752,7 +9601,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -9762,7 +9611,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -9772,7 +9621,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -9790,7 +9639,7 @@

      connect POST requests to proxy o

    -

    Parameters

    +

    Parameters

    @@ -9840,7 +9689,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -9865,7 +9714,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -9875,7 +9724,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -9885,7 +9734,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -9903,7 +9752,7 @@

      connect PATCH requests to proxy

    -

    Parameters

    +

    Parameters

    @@ -9953,7 +9802,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -9978,7 +9827,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -9988,7 +9837,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -9998,7 +9847,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -10016,7 +9865,7 @@

      connect GET requests to proxy o

    -

    Parameters

    +

    Parameters

    @@ -10074,7 +9923,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -10099,7 +9948,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -10109,7 +9958,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -10119,7 +9968,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -10137,7 +9986,7 @@

      connect PUT requests to proxy o

    -

    Parameters

    +

    Parameters

    @@ -10195,7 +10044,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -10220,7 +10069,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -10230,7 +10079,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -10240,7 +10089,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -10258,7 +10107,7 @@

      connect DELETE requests to p

    -

    Parameters

    +

    Parameters

    @@ -10316,7 +10165,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -10341,7 +10190,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -10351,7 +10200,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -10361,7 +10210,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -10379,7 +10228,7 @@

      connect POST requests to proxy

    -

    Parameters

    +

    Parameters

    @@ -10437,7 +10286,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -10462,7 +10311,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -10472,7 +10321,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -10482,7 +10331,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -10500,7 +10349,7 @@

      connect PATCH requests to pro

    -

    Parameters

    +

    Parameters

    @@ -10558,7 +10407,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -10583,7 +10432,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -10593,7 +10442,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -10603,7 +10452,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -10621,7 +10470,7 @@

      read status of the specified Pod

    -

    Parameters

    +

    Parameters

    @@ -10671,7 +10520,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -10696,7 +10545,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -10706,7 +10555,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -10722,7 +10571,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -10740,7 +10589,7 @@

      replace status of the specified Po

    -

    Parameters

    +

    Parameters

    @@ -10798,7 +10647,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -10823,7 +10672,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -10833,7 +10682,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -10849,7 +10698,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -10867,7 +10716,7 @@

      partially update status o

    -

    Parameters

    +

    Parameters

    @@ -10925,7 +10774,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -10950,7 +10799,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -10966,7 +10815,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -10982,7 +10831,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -11000,7 +10849,7 @@

      list or watch objects of kin

    -

    Parameters

    +

    Parameters

    @@ -11090,7 +10939,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -11115,7 +10964,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -11125,7 +10974,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -11147,7 +10996,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -11165,7 +11014,7 @@

      delete collection of PodTemplate

    -

    Parameters

    +

    Parameters

    @@ -11255,7 +11104,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -11280,7 +11129,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -11290,7 +11139,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -11306,7 +11155,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -11324,7 +11173,7 @@

      create a PodTemplate

    -

    Parameters

    +

    Parameters

    @@ -11374,7 +11223,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -11399,7 +11248,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -11409,7 +11258,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -11425,7 +11274,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -11443,7 +11292,7 @@

      read the specified PodTemplate

    -

    Parameters

    +

    Parameters

    @@ -11509,7 +11358,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -11534,7 +11383,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -11544,7 +11393,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -11560,7 +11409,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -11578,7 +11427,7 @@

      replace the specified PodTemplate

    -

    Parameters

    +

    Parameters

    @@ -11636,7 +11485,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -11661,7 +11510,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -11671,7 +11520,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -11687,7 +11536,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -11705,7 +11554,7 @@

      delete a PodTemplate

    -

    Parameters

    +

    Parameters

    @@ -11787,7 +11636,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -11812,7 +11661,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -11822,7 +11671,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -11838,7 +11687,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -11856,7 +11705,7 @@

      partially update the specif

    -

    Parameters

    +

    Parameters

    @@ -11914,7 +11763,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -11939,7 +11788,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -11955,7 +11804,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -11971,7 +11820,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -11989,7 +11838,7 @@

      list or watch obje

    -

    Parameters

    +

    Parameters

    @@ -12079,7 +11928,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -12104,7 +11953,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -12114,7 +11963,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -12136,7 +11985,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -12154,7 +12003,7 @@

      delete collection of Replic

    -

    Parameters

    +

    Parameters

    @@ -12244,7 +12093,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -12269,7 +12118,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -12279,7 +12128,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -12295,7 +12144,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -12313,7 +12162,7 @@

      create a ReplicationController

    -

    Parameters

    +

    Parameters

    @@ -12363,7 +12212,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -12388,7 +12237,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -12398,7 +12247,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -12414,7 +12263,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -12432,7 +12281,7 @@

      read the specified Replicatio

    -

    Parameters

    +

    Parameters

    @@ -12498,7 +12347,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -12523,7 +12372,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -12533,7 +12382,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -12549,7 +12398,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -12567,7 +12416,7 @@

      replace the specified Repl

    -

    Parameters

    +

    Parameters

    @@ -12625,7 +12474,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -12650,7 +12499,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -12660,7 +12509,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -12676,7 +12525,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -12694,7 +12543,7 @@

      delete a ReplicationController

    -

    Parameters

    +

    Parameters

    @@ -12776,7 +12625,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -12801,7 +12650,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -12811,7 +12660,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -12827,7 +12676,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -12845,7 +12694,7 @@

      partially update

    -

    Parameters

    +

    Parameters

    @@ -12903,7 +12752,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -12928,7 +12777,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -12944,7 +12793,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -12960,7 +12809,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -12978,7 +12827,7 @@

      read scale of the specified Scale

    -

    Parameters

    +

    Parameters

    @@ -13028,7 +12877,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -13053,7 +12902,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -13063,7 +12912,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -13079,7 +12928,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -13097,7 +12946,7 @@

      replace scale of the specified Sc

    -

    Parameters

    +

    Parameters

    @@ -13155,7 +13004,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -13180,7 +13029,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -13190,7 +13039,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -13206,7 +13055,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -13224,7 +13073,7 @@

      partially update scale o

    -

    Parameters

    +

    Parameters

    @@ -13282,7 +13131,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -13307,7 +13156,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -13323,7 +13172,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -13339,7 +13188,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -13357,7 +13206,7 @@

      read status of the

    -

    Parameters

    +

    Parameters

    @@ -13407,7 +13256,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -13432,7 +13281,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -13442,7 +13291,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -13458,7 +13307,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -13476,7 +13325,7 @@

      replace status o

    -

    Parameters

    +

    Parameters

    @@ -13534,7 +13383,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -13559,7 +13408,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -13569,7 +13418,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -13585,7 +13434,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -13603,7 +13452,7 @@

      partial

    -

    Parameters

    +

    Parameters

    @@ -13661,7 +13510,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -13686,7 +13535,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -13702,7 +13551,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -13718,7 +13567,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -13736,7 +13585,7 @@

      list or watch objects of k

    -

    Parameters

    +

    Parameters

    @@ -13826,7 +13675,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -13851,7 +13700,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -13861,7 +13710,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -13883,7 +13732,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -13901,7 +13750,7 @@

      delete collection of ResourceQuota<

    -

    Parameters

    +

    Parameters

    @@ -13991,7 +13840,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -14016,7 +13865,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -14026,7 +13875,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -14042,7 +13891,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -14060,7 +13909,7 @@

      create a ResourceQuota

    -

    Parameters

    +

    Parameters

    @@ -14110,7 +13959,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -14135,7 +13984,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -14145,7 +13994,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -14161,7 +14010,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -14179,7 +14028,7 @@

      read the specified ResourceQuota

    -

    Parameters

    +

    Parameters

    @@ -14245,7 +14094,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -14270,7 +14119,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -14280,7 +14129,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -14296,7 +14145,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -14314,7 +14163,7 @@

      replace the specified ResourceQuot

    -

    Parameters

    +

    Parameters

    @@ -14372,7 +14221,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -14397,7 +14246,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -14407,7 +14256,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -14423,7 +14272,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -14441,7 +14290,7 @@

      delete a ResourceQuota

    -

    Parameters

    +

    Parameters

    @@ -14521,6 +14370,133 @@

    Parameters

    +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    200

    success

    v1.Status

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apiv1

      +
    • +
    +
    +
    +
    +
    +

    partially update the specified ResourceQuota

    +
    +
    +
    PATCH /api/v1/namespaces/{namespace}/resourcequotas/{name}
    +
    +
    +
    +

    Parameters

    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    BodyParameter

    body

    true

    v1.Patch

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the ResourceQuota

    true

    string

    +

    Responses

    @@ -14541,133 +14517,6 @@

    Responses

    200

    success

    -

    v1.Status

    - - - - -
    -
    -

    Consumes

    -
    -
      -
    • -

      /

      -
    • -
    -
    -
    -
    -

    Produces

    -
    -
      -
    • -

      application/json

      -
    • -
    • -

      application/yaml

      -
    • -
    • -

      application/vnd.kubernetes.protobuf

      -
    • -
    -
    -
    -
    -

    Tags

    -
    -
      -
    • -

      apiv1

      -
    • -
    -
    -
    -
    -
    -

    partially update the specified ResourceQuota

    -
    -
    -
    PATCH /api/v1/namespaces/{namespace}/resourcequotas/{name}
    -
    -
    -
    -

    Parameters

    - -------- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    BodyParameter

    body

    true

    v1.Patch

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the ResourceQuota

    true

    string

    - -
    -
    -

    Responses

    - ----- - - - - - - - - - - - @@ -14675,7 +14524,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -14691,7 +14540,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -14707,7 +14556,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -14725,7 +14574,7 @@

      read status of the specifie

    -

    Parameters

    +

    Parameters

    HTTP CodeDescriptionSchema

    200

    success

    v1.ResourceQuota

    @@ -14775,7 +14624,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -14800,7 +14649,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -14810,7 +14659,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -14826,7 +14675,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -14844,7 +14693,7 @@

      replace status of the sp

    -

    Parameters

    +

    Parameters

    @@ -14902,7 +14751,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -14927,7 +14776,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -14937,7 +14786,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -14953,7 +14802,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -14971,7 +14820,7 @@

      partially updat

    -

    Parameters

    +

    Parameters

    @@ -15029,7 +14878,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -15054,7 +14903,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -15070,7 +14919,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -15086,7 +14935,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -15104,7 +14953,7 @@

      list or watch objects of kind Sec

    -

    Parameters

    +

    Parameters

    @@ -15194,7 +15043,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -15219,7 +15068,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -15229,7 +15078,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -15251,7 +15100,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -15269,7 +15118,7 @@

      delete collection of Secret

    -

    Parameters

    +

    Parameters

    @@ -15359,7 +15208,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -15384,7 +15233,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -15394,7 +15243,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -15410,7 +15259,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -15428,7 +15277,7 @@

      create a Secret

    -

    Parameters

    +

    Parameters

    @@ -15478,7 +15327,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -15503,7 +15352,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -15513,7 +15362,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -15529,7 +15378,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -15547,7 +15396,7 @@

      read the specified Secret

    -

    Parameters

    +

    Parameters

    @@ -15613,7 +15462,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -15638,7 +15487,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -15648,7 +15497,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -15664,7 +15513,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -15682,7 +15531,7 @@

      replace the specified Secret

    -

    Parameters

    +

    Parameters

    @@ -15740,7 +15589,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -15765,7 +15614,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -15775,7 +15624,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -15791,7 +15640,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -15809,7 +15658,7 @@

      delete a Secret

    -

    Parameters

    +

    Parameters

    @@ -15891,7 +15740,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -15916,7 +15765,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -15926,7 +15775,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -15942,7 +15791,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -15960,7 +15809,7 @@

      partially update the specified S

    -

    Parameters

    +

    Parameters

    @@ -16018,7 +15867,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -16043,7 +15892,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -16059,7 +15908,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -16075,7 +15924,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -16093,7 +15942,7 @@

      list or watch objects of

    -

    Parameters

    +

    Parameters

    @@ -16183,7 +16032,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -16208,7 +16057,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -16218,7 +16067,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -16240,7 +16089,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -16258,7 +16107,7 @@

      delete collection of ServiceAccoun

    -

    Parameters

    +

    Parameters

    @@ -16348,7 +16197,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -16373,7 +16222,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -16383,7 +16232,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -16399,7 +16248,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -16417,7 +16266,7 @@

      create a ServiceAccount

    -

    Parameters

    +

    Parameters

    @@ -16467,7 +16316,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -16492,7 +16341,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -16502,7 +16351,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -16518,7 +16367,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -16536,7 +16385,7 @@

      read the specified ServiceAccount

    -

    Parameters

    +

    Parameters

    @@ -16602,7 +16451,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -16627,7 +16476,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -16637,7 +16486,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -16653,7 +16502,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -16671,7 +16520,7 @@

      replace the specified ServiceAcco

    -

    Parameters

    +

    Parameters

    @@ -16729,7 +16578,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -16754,7 +16603,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -16764,7 +16613,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -16780,7 +16629,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -16798,7 +16647,7 @@

      delete a ServiceAccount

    -

    Parameters

    +

    Parameters

    @@ -16880,7 +16729,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -16905,7 +16754,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -16915,7 +16764,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -16931,7 +16780,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -16949,7 +16798,7 @@

      partially update the spe

    -

    Parameters

    +

    Parameters

    @@ -17007,7 +16856,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -17032,7 +16881,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -17048,7 +16897,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -17064,7 +16913,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -17082,7 +16931,7 @@

      list or watch objects of kind Se

    -

    Parameters

    +

    Parameters

    @@ -17172,7 +17021,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -17197,7 +17046,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -17207,7 +17056,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -17229,7 +17078,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -17247,7 +17096,7 @@

      create a Service

    -

    Parameters

    +

    Parameters

    @@ -17297,7 +17146,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -17322,7 +17171,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -17332,7 +17181,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -17348,7 +17197,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -17366,7 +17215,7 @@

      read the specified Service

    -

    Parameters

    +

    Parameters

    @@ -17432,7 +17281,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -17457,7 +17306,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -17467,7 +17316,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -17483,7 +17332,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -17501,7 +17350,7 @@

      replace the specified Service

    -

    Parameters

    +

    Parameters

    @@ -17559,7 +17408,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -17584,7 +17433,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -17594,7 +17443,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -17610,7 +17459,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -17628,7 +17477,7 @@

      delete a Service

    -

    Parameters

    +

    Parameters

    @@ -17678,7 +17527,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -17703,7 +17552,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -17713,7 +17562,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -17729,7 +17578,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -17747,7 +17596,7 @@

      partially update the specified

    -

    Parameters

    +

    Parameters

    @@ -17805,7 +17654,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -17830,7 +17679,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -17846,7 +17695,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -17862,7 +17711,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -17880,7 +17729,7 @@

      connect GET requests to proxy

    -

    Parameters

    +

    Parameters

    @@ -17930,7 +17779,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -17955,7 +17804,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -17965,7 +17814,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -17975,7 +17824,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -17993,7 +17842,7 @@

      connect PUT requests to proxy

    -

    Parameters

    +

    Parameters

    @@ -18043,7 +17892,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -18068,7 +17917,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -18078,7 +17927,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -18088,7 +17937,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -18106,7 +17955,7 @@

      connect DELETE requests to

    -

    Parameters

    +

    Parameters

    @@ -18156,7 +18005,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -18181,7 +18030,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -18191,7 +18040,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -18201,7 +18050,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -18219,7 +18068,7 @@

      connect POST requests to pro

    -

    Parameters

    +

    Parameters

    @@ -18269,7 +18118,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -18294,7 +18143,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -18304,7 +18153,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -18314,7 +18163,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -18332,7 +18181,7 @@

      connect PATCH requests to p

    -

    Parameters

    +

    Parameters

    @@ -18382,7 +18231,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -18407,7 +18256,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -18417,7 +18266,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -18427,7 +18276,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -18445,7 +18294,7 @@

      connect GET requests to pro

    -

    Parameters

    +

    Parameters

    @@ -18503,7 +18352,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -18528,7 +18377,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -18538,7 +18387,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -18548,7 +18397,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -18566,7 +18415,7 @@

      connect PUT requests to pro

    -

    Parameters

    +

    Parameters

    @@ -18624,7 +18473,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -18649,7 +18498,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -18659,7 +18508,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -18669,7 +18518,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -18687,7 +18536,7 @@

      connect DELETE requests

    -

    Parameters

    +

    Parameters

    @@ -18745,7 +18594,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -18770,7 +18619,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -18780,7 +18629,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -18790,7 +18639,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -18808,7 +18657,7 @@

      connect POST requests to p

    -

    Parameters

    +

    Parameters

    @@ -18866,7 +18715,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -18891,7 +18740,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -18901,7 +18750,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -18911,7 +18760,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -18929,7 +18778,7 @@

      connect PATCH requests to

    -

    Parameters

    +

    Parameters

    @@ -18987,7 +18836,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -19012,7 +18861,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -19022,7 +18871,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -19032,7 +18881,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -19050,7 +18899,7 @@

      read status of the specified Serv

    -

    Parameters

    +

    Parameters

    @@ -19100,7 +18949,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -19125,7 +18974,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -19135,7 +18984,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -19151,7 +19000,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -19169,7 +19018,7 @@

      replace status of the specifie

    -

    Parameters

    +

    Parameters

    @@ -19227,7 +19076,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -19252,7 +19101,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -19262,7 +19111,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -19278,7 +19127,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -19296,7 +19145,7 @@

      partially update stat

    -

    Parameters

    +

    Parameters

    @@ -19354,7 +19203,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -19379,7 +19228,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -19395,7 +19244,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -19411,7 +19260,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -19429,7 +19278,7 @@

      read the specified Namespace

    -

    Parameters

    +

    Parameters

    @@ -19487,7 +19336,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -19512,7 +19361,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -19522,7 +19371,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -19538,7 +19387,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -19556,7 +19405,7 @@

      replace the specified Namespace

    -

    Parameters

    +

    Parameters

    @@ -19606,7 +19455,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -19631,7 +19480,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -19641,7 +19490,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -19657,7 +19506,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -19675,7 +19524,7 @@

      delete a Namespace

    -

    Parameters

    +

    Parameters

    @@ -19749,7 +19598,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -19774,7 +19623,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -19784,7 +19633,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -19800,7 +19649,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -19818,7 +19667,7 @@

      partially update the specifie

    -

    Parameters

    +

    Parameters

    @@ -19868,7 +19717,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -19893,7 +19742,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -19909,7 +19758,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -19925,7 +19774,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -19943,7 +19792,7 @@

      replace finalize of the sp

    -

    Parameters

    +

    Parameters

    @@ -19993,7 +19842,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -20018,7 +19867,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -20028,7 +19877,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -20044,7 +19893,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -20062,7 +19911,7 @@

      read status of the specified Na

    -

    Parameters

    +

    Parameters

    @@ -20104,7 +19953,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -20129,7 +19978,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -20139,7 +19988,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -20155,7 +20004,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -20173,7 +20022,7 @@

      replace status of the specif

    -

    Parameters

    +

    Parameters

    @@ -20223,7 +20072,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -20248,7 +20097,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -20258,7 +20107,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -20274,7 +20123,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -20292,7 +20141,7 @@

      partially update st

    -

    Parameters

    +

    Parameters

    @@ -20342,7 +20191,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -20367,7 +20216,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -20383,7 +20232,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -20399,7 +20248,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -20417,7 +20266,7 @@

      list or watch objects of kind Node<

    -

    Parameters

    +

    Parameters

    @@ -20499,7 +20348,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -20524,7 +20373,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -20534,7 +20383,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -20556,7 +20405,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -20574,7 +20423,7 @@

      delete collection of Node

    -

    Parameters

    +

    Parameters

    @@ -20656,7 +20505,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -20681,7 +20530,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -20691,7 +20540,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -20707,7 +20556,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -20725,7 +20574,7 @@

      create a Node

    -

    Parameters

    +

    Parameters

    @@ -20767,7 +20616,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -20792,7 +20641,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -20802,7 +20651,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -20818,7 +20667,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -20836,7 +20685,7 @@

      read the specified Node

    -

    Parameters

    +

    Parameters

    @@ -20894,7 +20743,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -20919,7 +20768,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -20929,7 +20778,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -20945,7 +20794,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -20963,7 +20812,7 @@

      replace the specified Node

    -

    Parameters

    +

    Parameters

    @@ -21013,7 +20862,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -21038,7 +20887,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -21048,7 +20897,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -21064,7 +20913,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -21082,7 +20931,7 @@

      delete a Node

    -

    Parameters

    +

    Parameters

    @@ -21156,7 +21005,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -21181,7 +21030,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -21191,7 +21040,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -21207,7 +21056,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -21225,7 +21074,7 @@

      partially update the specified Nod

    -

    Parameters

    +

    Parameters

    @@ -21275,7 +21124,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -21300,7 +21149,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -21316,7 +21165,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -21332,7 +21181,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -21350,7 +21199,7 @@

      connect GET requests to proxy of

    -

    Parameters

    +

    Parameters

    @@ -21392,7 +21241,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -21417,7 +21266,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -21427,7 +21276,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -21437,7 +21286,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -21455,7 +21304,7 @@

      connect PUT requests to proxy of

    -

    Parameters

    +

    Parameters

    @@ -21497,7 +21346,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -21522,7 +21371,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -21532,7 +21381,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -21542,7 +21391,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -21560,7 +21409,7 @@

      connect DELETE requests to pr

    -

    Parameters

    +

    Parameters

    @@ -21602,7 +21451,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -21627,7 +21476,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -21637,7 +21486,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -21647,7 +21496,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -21665,7 +21514,7 @@

      connect POST requests to proxy

    -

    Parameters

    +

    Parameters

    @@ -21707,7 +21556,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -21732,7 +21581,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -21742,7 +21591,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -21752,7 +21601,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -21770,7 +21619,7 @@

      connect PATCH requests to prox

    -

    Parameters

    +

    Parameters

    @@ -21812,7 +21661,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -21837,7 +21686,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -21847,7 +21696,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -21857,7 +21706,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -21875,7 +21724,7 @@

      connect GET requests to proxy

    -

    Parameters

    +

    Parameters

    @@ -21925,7 +21774,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -21950,7 +21799,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -21960,7 +21809,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -21970,7 +21819,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -21988,7 +21837,7 @@

      connect PUT requests to proxy

    -

    Parameters

    +

    Parameters

    @@ -22038,7 +21887,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -22063,7 +21912,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -22073,7 +21922,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -22083,7 +21932,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -22101,7 +21950,7 @@

      connect DELETE requests to

    -

    Parameters

    +

    Parameters

    @@ -22151,7 +22000,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -22176,7 +22025,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -22186,7 +22035,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -22196,7 +22045,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -22214,7 +22063,7 @@

      connect POST requests to prox

    -

    Parameters

    +

    Parameters

    @@ -22264,7 +22113,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -22289,7 +22138,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -22299,7 +22148,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -22309,7 +22158,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -22327,7 +22176,7 @@

      connect PATCH requests to pr

    -

    Parameters

    +

    Parameters

    @@ -22377,7 +22226,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -22402,7 +22251,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -22412,7 +22261,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -22422,7 +22271,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -22440,7 +22289,7 @@

      read status of the specified Node

    -

    Parameters

    +

    Parameters

    @@ -22482,7 +22331,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -22507,7 +22356,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -22517,7 +22366,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -22533,7 +22382,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -22551,7 +22400,7 @@

      replace status of the specified N

    -

    Parameters

    +

    Parameters

    @@ -22601,7 +22450,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -22626,7 +22475,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -22636,7 +22485,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -22652,7 +22501,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -22670,7 +22519,7 @@

      partially update status

    -

    Parameters

    +

    Parameters

    @@ -22720,7 +22569,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -22745,7 +22594,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -22761,7 +22610,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -22777,7 +22626,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -22795,7 +22644,7 @@

      list or watch ob

    -

    Parameters

    +

    Parameters

    @@ -22877,7 +22726,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -22902,7 +22751,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -22912,7 +22761,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -22934,7 +22783,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -22952,7 +22801,7 @@

      list or watch objects o

    -

    Parameters

    +

    Parameters

    @@ -23034,7 +22883,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -23059,7 +22908,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -23069,7 +22918,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -23091,7 +22940,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -23109,7 +22958,7 @@

      delete collection of PersistentV

    -

    Parameters

    +

    Parameters

    @@ -23191,7 +23040,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -23216,7 +23065,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -23226,7 +23075,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -23242,7 +23091,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -23260,7 +23109,7 @@

      create a PersistentVolume

    -

    Parameters

    +

    Parameters

    @@ -23302,7 +23151,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -23327,7 +23176,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -23337,7 +23186,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -23353,7 +23202,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -23371,7 +23220,7 @@

      read the specified PersistentVolum

    -

    Parameters

    +

    Parameters

    @@ -23429,7 +23278,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -23454,7 +23303,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -23464,7 +23313,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -23480,7 +23329,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -23498,7 +23347,7 @@

      replace the specified Persisten

    -

    Parameters

    +

    Parameters

    @@ -23548,7 +23397,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -23573,7 +23422,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -23583,7 +23432,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -23599,7 +23448,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -23617,7 +23466,7 @@

      delete a PersistentVolume

    -

    Parameters

    +

    Parameters

    @@ -23691,7 +23540,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -23716,7 +23565,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -23726,7 +23575,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -23742,7 +23591,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -23760,7 +23609,7 @@

      partially update the s

    -

    Parameters

    +

    Parameters

    @@ -23810,7 +23659,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -23835,7 +23684,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -23851,7 +23700,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -23867,7 +23716,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -23885,7 +23734,7 @@

      read status of the speci

    -

    Parameters

    +

    Parameters

    @@ -23927,7 +23776,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -23952,7 +23801,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -23962,7 +23811,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -23978,7 +23827,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -23996,7 +23845,7 @@

      replace status of the

    -

    Parameters

    +

    Parameters

    @@ -24046,7 +23895,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -24071,7 +23920,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -24081,7 +23930,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -24097,7 +23946,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -24115,7 +23964,7 @@

      partially up

    -

    Parameters

    +

    Parameters

    @@ -24165,7 +24014,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -24190,7 +24039,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -24206,7 +24055,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -24222,7 +24071,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -24240,7 +24089,7 @@

      list or watch objects of kind Pod<

    -

    Parameters

    +

    Parameters

    @@ -24322,7 +24171,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -24347,7 +24196,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -24357,7 +24206,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -24379,7 +24228,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -24397,7 +24246,7 @@

      list or watch objects of k

    -

    Parameters

    +

    Parameters

    @@ -24479,7 +24328,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -24504,7 +24353,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -24514,7 +24363,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -24536,7 +24385,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -24554,6 +24403,111 @@

      proxy GET requests to Pod

    +

    Parameters

    +
    ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypeNameDescriptionRequiredSchemaDefault

    PathParameter

    namespace

    object name and auth scope, such as for teams and projects

    true

    string

    PathParameter

    name

    name of the Pod

    true

    string

    + +
    +
    +

    Responses

    + +++++ + + + + + + + + + + + + + + +
    HTTP CodeDescriptionSchema

    default

    success

    string

    + +
    +
    +

    Consumes

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Produces

    +
    +
      +
    • +

      /

      +
    • +
    +
    +
    +
    +

    Tags

    +
    +
      +
    • +

      apiv1

      +
    • +
    +
    +
    +
    +
    +

    proxy PUT requests to Pod

    +
    +
    +
    PUT /api/v1/proxy/namespaces/{namespace}/pods/{name}
    +
    +
    +

    Parameters

    @@ -24652,10 +24606,10 @@

    Tags

    -

    proxy PUT requests to Pod

    +

    proxy DELETE requests to Pod

    -
    PUT /api/v1/proxy/namespaces/{namespace}/pods/{name}
    +
    DELETE /api/v1/proxy/namespaces/{namespace}/pods/{name}
    @@ -24757,10 +24711,10 @@

    Tags

    -

    proxy DELETE requests to Pod

    +

    proxy POST requests to Pod

    -
    DELETE /api/v1/proxy/namespaces/{namespace}/pods/{name}
    +
    POST /api/v1/proxy/namespaces/{namespace}/pods/{name}
    @@ -24862,10 +24816,10 @@

    Tags

    -

    proxy POST requests to Pod

    +

    proxy PATCH requests to Pod

    -
    POST /api/v1/proxy/namespaces/{namespace}/pods/{name}
    +
    PATCH /api/v1/proxy/namespaces/{namespace}/pods/{name}
    @@ -24967,10 +24921,10 @@

    Tags

    -

    proxy PATCH requests to Pod

    +

    proxy GET requests to Pod

    -
    PATCH /api/v1/proxy/namespaces/{namespace}/pods/{name}
    +
    GET /api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}
    @@ -25011,6 +24965,14 @@

    Parameters

    + + + + + + + +

    string

    PathParameter

    path

    path to the resource

    true

    string

    @@ -25072,10 +25034,10 @@

    Tags

    -

    proxy GET requests to Pod

    +

    proxy PUT requests to Pod

    -
    GET /api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}
    +
    PUT /api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}
    @@ -25185,10 +25147,10 @@

    Tags

    -

    proxy PUT requests to Pod

    +

    proxy DELETE requests to Pod

    -
    PUT /api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}
    +
    DELETE /api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}
    @@ -25298,10 +25260,10 @@

    Tags

    -

    proxy DELETE requests to Pod

    +

    proxy POST requests to Pod

    -
    DELETE /api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}
    +
    POST /api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}
    @@ -25411,10 +25373,10 @@

    Tags

    -

    proxy POST requests to Pod

    +

    proxy PATCH requests to Pod

    -
    POST /api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}
    +
    PATCH /api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}
    @@ -25524,10 +25486,10 @@

    Tags

    -

    proxy PATCH requests to Pod

    +

    proxy GET requests to Service

    -
    PATCH /api/v1/proxy/namespaces/{namespace}/pods/{name}/{path}
    +
    GET /api/v1/proxy/namespaces/{namespace}/services/{name}
    @@ -25563,15 +25525,7 @@

    Parameters

    PathParameter

    name

    -

    name of the Pod

    -

    true

    -

    string

    - - - -

    PathParameter

    -

    path

    -

    path to the resource

    +

    name of the Service

    true

    string

    @@ -25637,10 +25591,10 @@

    Tags

    -

    proxy GET requests to Service

    +

    proxy PUT requests to Service

    -
    GET /api/v1/proxy/namespaces/{namespace}/services/{name}
    +
    PUT /api/v1/proxy/namespaces/{namespace}/services/{name}
    @@ -25742,10 +25696,10 @@

    Tags

    -

    proxy PUT requests to Service

    +

    proxy DELETE requests to Service

    -
    PUT /api/v1/proxy/namespaces/{namespace}/services/{name}
    +
    DELETE /api/v1/proxy/namespaces/{namespace}/services/{name}
    @@ -25847,10 +25801,10 @@

    Tags

    -

    proxy DELETE requests to Service

    +

    proxy POST requests to Service

    -
    DELETE /api/v1/proxy/namespaces/{namespace}/services/{name}
    +
    POST /api/v1/proxy/namespaces/{namespace}/services/{name}
    @@ -25952,10 +25906,10 @@

    Tags

    -

    proxy POST requests to Service

    +

    proxy PATCH requests to Service

    -
    POST /api/v1/proxy/namespaces/{namespace}/services/{name}
    +
    PATCH /api/v1/proxy/namespaces/{namespace}/services/{name}
    @@ -26057,10 +26011,10 @@

    Tags

    -

    proxy PATCH requests to Service

    +

    proxy GET requests to Service

    -
    PATCH /api/v1/proxy/namespaces/{namespace}/services/{name}
    +
    GET /api/v1/proxy/namespaces/{namespace}/services/{name}/{path}
    @@ -26101,6 +26055,14 @@

    Parameters

    string

    + +

    PathParameter

    +

    path

    +

    path to the resource

    +

    true

    +

    string

    + + @@ -26162,10 +26124,10 @@

    Tags

    -

    proxy GET requests to Service

    +

    proxy PUT requests to Service

    -
    GET /api/v1/proxy/namespaces/{namespace}/services/{name}/{path}
    +
    PUT /api/v1/proxy/namespaces/{namespace}/services/{name}/{path}
    @@ -26275,10 +26237,10 @@

    Tags

    -

    proxy PUT requests to Service

    +

    proxy DELETE requests to Service

    -
    PUT /api/v1/proxy/namespaces/{namespace}/services/{name}/{path}
    +
    DELETE /api/v1/proxy/namespaces/{namespace}/services/{name}/{path}
    @@ -26388,10 +26350,10 @@

    Tags

    -

    proxy DELETE requests to Service

    +

    proxy POST requests to Service

    -
    DELETE /api/v1/proxy/namespaces/{namespace}/services/{name}/{path}
    +
    POST /api/v1/proxy/namespaces/{namespace}/services/{name}/{path}
    @@ -26501,10 +26463,10 @@

    Tags

    -

    proxy POST requests to Service

    +

    proxy PATCH requests to Service

    -
    POST /api/v1/proxy/namespaces/{namespace}/services/{name}/{path}
    +
    PATCH /api/v1/proxy/namespaces/{namespace}/services/{name}/{path}
    @@ -26614,10 +26576,10 @@

    Tags

    -

    proxy PATCH requests to Service

    +

    proxy GET requests to Node

    -
    PATCH /api/v1/proxy/namespaces/{namespace}/services/{name}/{path}
    +
    GET /api/v1/proxy/nodes/{name}
    @@ -26644,24 +26606,8 @@

    Parameters

    PathParameter

    -

    namespace

    -

    object name and auth scope, such as for teams and projects

    -

    true

    -

    string

    - - - -

    PathParameter

    name

    -

    name of the Service

    -

    true

    -

    string

    - - - -

    PathParameter

    -

    path

    -

    path to the resource

    +

    name of the Node

    true

    string

    @@ -26727,10 +26673,10 @@

    Tags

    -

    proxy GET requests to Node

    +

    proxy PUT requests to Node

    -
    GET /api/v1/proxy/nodes/{name}
    +
    PUT /api/v1/proxy/nodes/{name}
    @@ -26824,10 +26770,10 @@

    Tags

    -

    proxy PUT requests to Node

    +

    proxy DELETE requests to Node

    -
    PUT /api/v1/proxy/nodes/{name}
    +
    DELETE /api/v1/proxy/nodes/{name}
    @@ -26921,10 +26867,10 @@

    Tags

    -

    proxy DELETE requests to Node

    +

    proxy POST requests to Node

    -
    DELETE /api/v1/proxy/nodes/{name}
    +
    POST /api/v1/proxy/nodes/{name}
    @@ -27018,10 +26964,10 @@

    Tags

    -

    proxy POST requests to Node

    +

    proxy PATCH requests to Node

    -
    POST /api/v1/proxy/nodes/{name}
    +
    PATCH /api/v1/proxy/nodes/{name}
    @@ -27115,10 +27061,10 @@

    Tags

    -

    proxy PATCH requests to Node

    +

    proxy GET requests to Node

    -
    PATCH /api/v1/proxy/nodes/{name}
    +
    GET /api/v1/proxy/nodes/{name}/{path}
    @@ -27151,6 +27097,14 @@

    Parameters

    string

    + +

    PathParameter

    +

    path

    +

    path to the resource

    +

    true

    +

    string

    + + @@ -27212,10 +27166,10 @@

    Tags

    -

    proxy GET requests to Node

    +

    proxy PUT requests to Node

    -
    GET /api/v1/proxy/nodes/{name}/{path}
    +
    PUT /api/v1/proxy/nodes/{name}/{path}
    @@ -27317,10 +27271,10 @@

    Tags

    -

    proxy PUT requests to Node

    +

    proxy DELETE requests to Node

    -
    PUT /api/v1/proxy/nodes/{name}/{path}
    +
    DELETE /api/v1/proxy/nodes/{name}/{path}
    @@ -27422,10 +27376,10 @@

    Tags

    -

    proxy DELETE requests to Node

    +

    proxy POST requests to Node

    -
    DELETE /api/v1/proxy/nodes/{name}/{path}
    +
    POST /api/v1/proxy/nodes/{name}/{path}
    @@ -27527,10 +27481,10 @@

    Tags

    -

    proxy POST requests to Node

    +

    proxy PATCH requests to Node

    -
    POST /api/v1/proxy/nodes/{name}/{path}
    +
    PATCH /api/v1/proxy/nodes/{name}/{path}
    @@ -27632,10 +27586,10 @@

    Tags

    -

    proxy PATCH requests to Node

    +

    list or watch objects of kind ReplicationController

    -
    PATCH /api/v1/proxy/nodes/{name}/{path}
    +
    GET /api/v1/replicationcontrollers
    @@ -27661,21 +27615,61 @@

    Parameters

    -

    PathParameter

    -

    name

    -

    name of the Node

    -

    true

    +

    QueryParameter

    +

    pretty

    +

    If true, then the output is pretty printed.

    +

    false

    string

    -

    PathParameter

    -

    path

    -

    path to the resource

    -

    true

    +

    QueryParameter

    +

    labelSelector

    +

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    +

    false

    +

    string

    + + + +

    QueryParameter

    +

    fieldSelector

    +

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    +

    false

    string

    + +

    QueryParameter

    +

    includeUninitialized

    +

    If true, partially initialized resources are included in the response.

    +

    false

    +

    boolean

    + + + +

    QueryParameter

    +

    watch

    +

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    +

    false

    +

    boolean

    + + + +

    QueryParameter

    +

    resourceVersion

    +

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    +

    false

    +

    string

    + + + +

    QueryParameter

    +

    timeoutSeconds

    +

    Timeout for the list/watch call.

    +

    false

    +

    integer (int32)

    + + @@ -27697,9 +27691,9 @@

    Responses

    -

    default

    +

    200

    success

    -

    string

    +

    v1.ReplicationControllerList

    @@ -27720,7 +27714,19 @@

    Produces

    • -

      /

      +

      application/json

      +
    • +
    • +

      application/yaml

      +
    • +
    • +

      application/vnd.kubernetes.protobuf

      +
    • +
    • +

      application/json;stream=watch

      +
    • +
    • +

      application/vnd.kubernetes.protobuf;stream=watch

    @@ -27737,10 +27743,10 @@

    Tags

    -

    list or watch objects of kind ReplicationController

    +

    list or watch objects of kind ResourceQuota

    -
    GET /api/v1/replicationcontrollers
    +
    GET /api/v1/resourcequotas
    @@ -27844,7 +27850,7 @@

    Responses

    200

    success

    -

    v1.ReplicationControllerList

    +

    v1.ResourceQuotaList

    @@ -27894,10 +27900,10 @@

    Tags

    -

    list or watch objects of kind ResourceQuota

    +

    list or watch objects of kind Secret

    -
    GET /api/v1/resourcequotas
    +
    GET /api/v1/secrets
    @@ -28001,7 +28007,7 @@

    Responses

    200

    success

    -

    v1.ResourceQuotaList

    +

    v1.SecretList

    @@ -28051,10 +28057,10 @@

    Tags

    -

    list or watch objects of kind Secret

    +

    list or watch objects of kind ServiceAccount

    -
    GET /api/v1/secrets
    +
    GET /api/v1/serviceaccounts
    @@ -28158,7 +28164,7 @@

    Responses

    200

    success

    -

    v1.SecretList

    +

    v1.ServiceAccountList

    @@ -28208,10 +28214,10 @@

    Tags

    -

    list or watch objects of kind ServiceAccount

    +

    list or watch objects of kind Service

    -
    GET /api/v1/serviceaccounts
    +
    GET /api/v1/services
    @@ -28315,7 +28321,7 @@

    Responses

    200

    success

    -

    v1.ServiceAccountList

    +

    v1.ServiceList

    @@ -28365,10 +28371,10 @@

    Tags

    -

    list or watch objects of kind Service

    +

    watch individual changes to a list of ConfigMap

    -
    GET /api/v1/services
    +
    GET /api/v1/watch/configmaps
    @@ -28472,7 +28478,7 @@

    Responses

    200

    success

    -

    v1.ServiceList

    +

    v1.WatchEvent

    @@ -28522,10 +28528,10 @@

    Tags

    -

    watch individual changes to a list of ConfigMap

    +

    watch individual changes to a list of Endpoints

    -
    GET /api/v1/watch/configmaps
    +
    GET /api/v1/watch/endpoints
    @@ -28679,10 +28685,10 @@

    Tags

    -

    watch individual changes to a list of Endpoints

    +

    watch individual changes to a list of Event

    -
    GET /api/v1/watch/endpoints
    +
    GET /api/v1/watch/events
    @@ -28836,10 +28842,10 @@

    Tags

    -

    watch individual changes to a list of Event

    +

    watch individual changes to a list of LimitRange

    -
    GET /api/v1/watch/events
    +
    GET /api/v1/watch/limitranges
    @@ -28993,10 +28999,10 @@

    Tags

    -

    watch individual changes to a list of LimitRange

    +

    watch individual changes to a list of Namespace

    -
    GET /api/v1/watch/limitranges
    +
    GET /api/v1/watch/namespaces
    @@ -29150,10 +29156,10 @@

    Tags

    -

    watch individual changes to a list of Namespace

    +

    watch individual changes to a list of ConfigMap

    -
    GET /api/v1/watch/namespaces
    +
    GET /api/v1/watch/namespaces/{namespace}/configmaps
    @@ -29234,163 +29240,6 @@

    Parameters

    integer (int32)

    - - - -
    -
    -

    Responses

    - ----- - - - - - - - - - - - - - - -
    HTTP CodeDescriptionSchema

    200

    success

    v1.WatchEvent

    - -
    -
    -

    Consumes

    -
    -
      -
    • -

      /

      -
    • -
    -
    -
    -
    -

    Produces

    -
    -
      -
    • -

      application/json

      -
    • -
    • -

      application/yaml

      -
    • -
    • -

      application/vnd.kubernetes.protobuf

      -
    • -
    • -

      application/json;stream=watch

      -
    • -
    • -

      application/vnd.kubernetes.protobuf;stream=watch

      -
    • -
    -
    -
    -
    -

    Tags

    -
    -
      -
    • -

      apiv1

      -
    • -
    -
    -
    -
    -
    -

    watch individual changes to a list of ConfigMap

    -
    -
    -
    GET /api/v1/watch/namespaces/{namespace}/configmaps
    -
    -
    -
    -

    Parameters

    - -------- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -29404,7 +29253,7 @@

    Parameters

    -

    Responses

    +

    Responses

    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    PathParameter

    namespace

    @@ -29429,7 +29278,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -29439,7 +29288,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -29461,7 +29310,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -29479,7 +29328,7 @@

      watch changes to an objec

    -

    Parameters

    +

    Parameters

    @@ -29577,7 +29426,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -29602,7 +29451,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -29612,7 +29461,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -29634,7 +29483,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -29652,7 +29501,7 @@

      watch individual cha

    -

    Parameters

    +

    Parameters

    @@ -29742,7 +29591,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -29767,7 +29616,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -29777,7 +29626,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -29799,7 +29648,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -29817,7 +29666,7 @@

      watch changes to an objec

    -

    Parameters

    +

    Parameters

    @@ -29915,7 +29764,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -29940,7 +29789,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -29950,7 +29799,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -29972,7 +29821,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -29990,7 +29839,7 @@

      watch individual changes

    -

    Parameters

    +

    Parameters

    @@ -30080,7 +29929,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -30105,7 +29954,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -30115,7 +29964,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -30137,7 +29986,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -30155,7 +30004,7 @@

      watch changes to an object of

    -

    Parameters

    +

    Parameters

    @@ -30253,7 +30102,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -30278,7 +30127,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -30288,7 +30137,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -30310,7 +30159,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -30328,7 +30177,7 @@

      watch individual ch

    -

    Parameters

    +

    Parameters

    @@ -30418,7 +30267,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -30443,7 +30292,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -30453,7 +30302,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -30475,7 +30324,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -30493,7 +30342,7 @@

      watch changes to an obje

    -

    Parameters

    +

    Parameters

    @@ -30591,7 +30440,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -30616,7 +30465,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -30626,7 +30475,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -30648,7 +30497,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -30666,7 +30515,7 @@

      watch indi

    -

    Parameters

    +

    Parameters

    @@ -30756,7 +30605,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -30781,7 +30630,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -30791,7 +30640,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -30813,7 +30662,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -30831,7 +30680,7 @@

      watch changes

    -

    Parameters

    +

    Parameters

    @@ -30929,7 +30778,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -30954,7 +30803,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -30964,7 +30813,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -30986,7 +30835,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -31004,7 +30853,7 @@

      watch individual changes to

    -

    Parameters

    +

    Parameters

    @@ -31094,7 +30943,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -31119,7 +30968,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -31129,7 +30978,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -31151,7 +31000,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -31169,7 +31018,7 @@

      watch changes to an object of k

    -

    Parameters

    +

    Parameters

    @@ -31267,7 +31116,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -31292,7 +31141,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -31302,7 +31151,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -31324,7 +31173,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -31342,7 +31191,7 @@

      watch individual cha

    -

    Parameters

    +

    Parameters

    @@ -31432,7 +31281,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -31457,7 +31306,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -31467,7 +31316,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -31489,7 +31338,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -31507,7 +31356,7 @@

      watch changes to an obj

    -

    Parameters

    +

    Parameters

    @@ -31605,7 +31454,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -31630,7 +31479,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -31640,7 +31489,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -31662,7 +31511,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -31680,7 +31529,7 @@

      watch indi

    -

    Parameters

    +

    Parameters

    @@ -31770,7 +31619,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -31795,7 +31644,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -31805,7 +31654,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -31827,7 +31676,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -31845,7 +31694,7 @@

      watch changes

    -

    Parameters

    +

    Parameters

    @@ -31943,7 +31792,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -31968,7 +31817,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -31978,7 +31827,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -32000,7 +31849,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -32018,7 +31867,7 @@

      watch individual c

    -

    Parameters

    +

    Parameters

    @@ -32108,7 +31957,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -32133,7 +31982,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -32143,7 +31992,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -32165,7 +32014,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -32183,7 +32032,7 @@

      watch changes to an o

    -

    Parameters

    +

    Parameters

    @@ -32281,7 +32130,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -32306,7 +32155,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -32316,7 +32165,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -32338,7 +32187,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -32356,7 +32205,7 @@

      watch individual changes

    -

    Parameters

    +

    Parameters

    @@ -32446,7 +32295,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -32471,7 +32320,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -32481,7 +32330,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -32503,7 +32352,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -32521,7 +32370,7 @@

      watch changes to an object o

    -

    Parameters

    +

    Parameters

    @@ -32619,7 +32468,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -32644,7 +32493,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -32654,7 +32503,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -32676,7 +32525,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -32694,7 +32543,7 @@

      watch individual

    -

    Parameters

    +

    Parameters

    @@ -32784,7 +32633,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -32809,7 +32658,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -32819,7 +32668,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -32841,7 +32690,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -32859,7 +32708,7 @@

      watch changes to an

    -

    Parameters

    +

    Parameters

    @@ -32957,7 +32806,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -32982,7 +32831,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -32992,7 +32841,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -33014,7 +32863,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -33032,7 +32881,7 @@

      watch individual changes

    -

    Parameters

    +

    Parameters

    @@ -33122,7 +32971,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -33147,7 +32996,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -33157,7 +33006,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -33179,7 +33028,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -33197,7 +33046,7 @@

      watch changes to an object

    -

    Parameters

    +

    Parameters

    @@ -33295,7 +33144,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -33320,7 +33169,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -33330,7 +33179,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -33352,7 +33201,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -33370,7 +33219,7 @@

      watch changes to an objec

    -

    Parameters

    +

    Parameters

    @@ -33460,7 +33309,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -33485,7 +33334,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -33495,7 +33344,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -33517,7 +33366,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -33535,7 +33384,7 @@

      watch individual changes to

    -

    Parameters

    +

    Parameters

    @@ -33617,7 +33466,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -33642,7 +33491,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -33652,7 +33501,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -33674,7 +33523,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -33692,7 +33541,7 @@

      watch changes to an object of

    -

    Parameters

    +

    Parameters

    @@ -33782,7 +33631,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -33807,7 +33656,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -33817,7 +33666,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -33839,7 +33688,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -33857,7 +33706,7 @@

      watch in

    -

    Parameters

    +

    Parameters

    @@ -33939,7 +33788,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -33964,7 +33813,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -33974,7 +33823,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -33996,7 +33845,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -34014,7 +33863,7 @@

      watch individua

    -

    Parameters

    +

    Parameters

    @@ -34096,7 +33945,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -34121,7 +33970,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -34131,7 +33980,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -34153,7 +34002,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -34171,7 +34020,7 @@

      watch changes to a

    -

    Parameters

    +

    Parameters

    @@ -34261,7 +34110,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -34286,7 +34135,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -34296,7 +34145,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -34318,7 +34167,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -34336,7 +34185,7 @@

      watch individual changes t

    -

    Parameters

    +

    Parameters

    @@ -34418,7 +34267,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -34443,7 +34292,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -34453,7 +34302,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -34475,7 +34324,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -34493,7 +34342,7 @@

      watch individual c

    -

    Parameters

    +

    Parameters

    @@ -34575,7 +34424,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -34600,7 +34449,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -34610,7 +34459,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -34632,7 +34481,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -34650,7 +34499,7 @@

      watch in

    -

    Parameters

    +

    Parameters

    @@ -34732,7 +34581,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -34757,7 +34606,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -34767,7 +34616,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -34789,7 +34638,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -34807,7 +34656,7 @@

      watch individual

    -

    Parameters

    +

    Parameters

    @@ -34889,7 +34738,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -34914,7 +34763,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -34924,7 +34773,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -34946,7 +34795,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -34964,7 +34813,7 @@

      watch individual change

    -

    Parameters

    +

    Parameters

    @@ -35046,7 +34895,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -35071,7 +34920,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -35081,7 +34930,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -35103,7 +34952,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -35121,7 +34970,7 @@

      watch individua

    -

    Parameters

    +

    Parameters

    @@ -35203,7 +35052,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -35228,7 +35077,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -35238,7 +35087,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -35260,7 +35109,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -35278,7 +35127,7 @@

      watch individual chang

    -

    Parameters

    +

    Parameters

    @@ -35360,7 +35209,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -35385,7 +35234,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -35395,7 +35244,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -35417,7 +35266,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -35432,7 +35281,7 @@

      Tags

    diff --git a/docs/man/man1/kubectl-apply-edit-last-applied.1 b/docs/man/man1/kubectl-apply-edit-last-applied.1 new file mode 100644 index 0000000000000..b6fd7a0f9896b --- /dev/null +++ b/docs/man/man1/kubectl-apply-edit-last-applied.1 @@ -0,0 +1,3 @@ +This file is autogenerated, but we've stopped checking such files into the +repository to reduce the need for rebases. Please run hack/generate-docs.sh to +populate this file. diff --git a/docs/man/man1/kubectl-config-rename-context.1 b/docs/man/man1/kubectl-config-rename-context.1 new file mode 100644 index 0000000000000..b6fd7a0f9896b --- /dev/null +++ b/docs/man/man1/kubectl-config-rename-context.1 @@ -0,0 +1,3 @@ +This file is autogenerated, but we've stopped checking such files into the +repository to reduce the need for rebases. Please run hack/generate-docs.sh to +populate this file. diff --git a/docs/user-guide/kubectl/kubectl_apply_edit-last-applied.md b/docs/user-guide/kubectl/kubectl_apply_edit-last-applied.md new file mode 100644 index 0000000000000..b6fd7a0f9896b --- /dev/null +++ b/docs/user-guide/kubectl/kubectl_apply_edit-last-applied.md @@ -0,0 +1,3 @@ +This file is autogenerated, but we've stopped checking such files into the +repository to reduce the need for rebases. Please run hack/generate-docs.sh to +populate this file. diff --git a/docs/user-guide/kubectl/kubectl_config_rename-context.md b/docs/user-guide/kubectl/kubectl_config_rename-context.md new file mode 100644 index 0000000000000..b6fd7a0f9896b --- /dev/null +++ b/docs/user-guide/kubectl/kubectl_config_rename-context.md @@ -0,0 +1,3 @@ +This file is autogenerated, but we've stopped checking such files into the +repository to reduce the need for rebases. Please run hack/generate-docs.sh to +populate this file. diff --git a/examples/elasticsearch/README.md b/examples/elasticsearch/README.md index b4377b0bba743..661c0a447a23d 100644 --- a/examples/elasticsearch/README.md +++ b/examples/elasticsearch/README.md @@ -97,7 +97,7 @@ So we have a 3-node Elasticsearch cluster ready to handle more work. ## Access the service -*Don't forget* that services in Kubernetes are only acessible from containers in the cluster. For different behavior you should [configure the creation of an external load-balancer](http://kubernetes.io/v1.0/docs/user-guide/services.html#type-loadbalancer). While it's supported within this example service descriptor, its usage is out of scope of this document, for now. +*Don't forget* that services in Kubernetes are only accessible from containers in the cluster. For different behavior you should [configure the creation of an external load-balancer](http://kubernetes.io/v1.0/docs/user-guide/services.html#type-loadbalancer). While it's supported within this example service descriptor, its usage is out of scope of this document, for now. ``` $ kubectl get service elasticsearch diff --git a/examples/scheduler-policy-config-with-extender.json b/examples/scheduler-policy-config-with-extender.json index eea38f5c40386..071b08d2bf0c6 100644 --- a/examples/scheduler-policy-config-with-extender.json +++ b/examples/scheduler-policy-config-with-extender.json @@ -14,7 +14,7 @@ {"name" : "ServiceSpreadingPriority", "weight" : 1}, {"name" : "EqualPriority", "weight" : 1} ], -"extenders":[ +"extenders" : [ { "urlPrefix": "http://127.0.0.1:12346/scheduler", "apiVersion": "v1beta1", @@ -24,5 +24,6 @@ "enableHttps": false, "nodeCacheCapable": false } - ] + ], +"hardPodAffinitySymmetricWeight" : 10 } diff --git a/examples/scheduler-policy-config.json b/examples/scheduler-policy-config.json index f93c39d133a65..b0fecffab2343 100644 --- a/examples/scheduler-policy-config.json +++ b/examples/scheduler-policy-config.json @@ -14,5 +14,6 @@ {"name" : "BalancedResourceAllocation", "weight" : 1}, {"name" : "ServiceSpreadingPriority", "weight" : 1}, {"name" : "EqualPriority", "weight" : 1} - ] + ], +"hardPodAffinitySymmetricWeight" : 10 } diff --git a/examples/volumes/glusterfs/README.md b/examples/volumes/glusterfs/README.md index d67bd865068f6..027fcd8af784c 100644 --- a/examples/volumes/glusterfs/README.md +++ b/examples/volumes/glusterfs/README.md @@ -2,15 +2,25 @@ [GlusterFS](http://www.gluster.org) is an open source scale-out filesystem. These examples provide information about how to allow containers use GlusterFS volumes. +There are couple of ways to use GlusterFS as a persistent data store in application pods. + +*) Static Provisioning of GlusterFS Volumes. +*) Dynamic Provisioning of GlusterFS Volumes. + +### Static Provisioning + +Static Provisioning of GlusterFS Volumes is analogues to creation of a PV ( Persistent Volume) resource by specifying the parameters in it. This +also need a working GlusterFS cluster/trusted pool available to carve out GlusterFS volumes. + The example assumes that you have already set up a GlusterFS server cluster and have a working GlusterFS volume ready to use in the containers. -### Prerequisites +#### Prerequisites * Set up a GlusterFS server cluster * Create a GlusterFS volume * If you are not using hyperkube, you may need to install the GlusterFS client package on the Kubernetes nodes ([Guide](http://gluster.readthedocs.io/en/latest/Administrator%20Guide/)) -### Create endpoints +#### Create endpoints The first step is to create the GlusterFS endpoints definition in Kubernetes. Here is a snippet of [glusterfs-endpoints.json](glusterfs-endpoints.json): @@ -52,7 +62,7 @@ $ kubectl create -f examples/volumes/glusterfs/glusterfs-service.json ``` -### Create a Pod +#### Create a Pod The following *volume* spec in [glusterfs-pod.json](glusterfs-pod.json) illustrates a sample configuration: @@ -93,11 +103,15 @@ You may execute the command `mount` inside the container to see if the GlusterFS ```sh $ kubectl exec glusterfs -- mount | grep gluster -10.240.106.152:kube_vol on /mnt/glusterfs type fuse.glusterfs (rw,relatime,user_id=0,group_id=0,default_permissions,allow_other,max_read=131072)``` +10.240.106.152:kube_vol on /mnt/glusterfs type fuse.glusterfs (rw,relatime,user_id=0,group_id=0,default_permissions,allow_other,max_read=131072) +``` You may also run `docker ps` on the host to see the actual container. +### Dynamic Provisioning of GlusterFS Volumes: +Dynamic Provisioning means provisioning of GlusterFS volumes based on a Storage class. Please refer [this guide](./../../persistent-volume-provisioning/README.md) +. [![Analytics](https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/examples/volumes/glusterfs/README.md?pixel)]() diff --git a/examples/volumes/quobyte/Readme.md b/examples/volumes/quobyte/Readme.md index b2689f11e9401..4199a232a8532 100644 --- a/examples/volumes/quobyte/Readme.md +++ b/examples/volumes/quobyte/Readme.md @@ -60,7 +60,7 @@ spec: Parameters: -* **registry** Quobyte registry to use to mount the volume. You can specifiy the registry as : pair or if you want to specify multiple registries you just have to put a comma between them e.q. :,:,:. The host can be an IP address or if you have a working DNS you can also provide the DNS names. +* **registry** Quobyte registry to use to mount the volume. You can specify the registry as : pair or if you want to specify multiple registries you just have to put a comma between them e.q. :,:,:. The host can be an IP address or if you have a working DNS you can also provide the DNS names. * **volume** volume represents a Quobyte volume which must be created before usage. * **readOnly** is the boolean that sets the mountpoint readOnly or readWrite. * **user** maps all access to this user. Default is `root`. diff --git a/examples/volumes/scaleio/README.md b/examples/volumes/scaleio/README.md index 849be22d73b07..65bec664117b9 100644 --- a/examples/volumes/scaleio/README.md +++ b/examples/volumes/scaleio/README.md @@ -93,7 +93,7 @@ The Kubernetes ScaleIO volume spec supports the following attributes: | storagePool| the name of the volume storage pool (default `default`)| | storageMode| the storage provision mode: `ThinProvisionned` (default) or `ThickProvisionned`| | volumeName| the name of an existing volume in ScaleIO (required)| -| secretRef:name| reference to a configuered Secret object (required, see Secret earlier)| +| secretRef:name| reference to a configured Secret object (required, see Secret earlier)| | readOnly| specifies the access mode to the mounted volume (default `false`)| | fsType| the file system to use for the volume (default `ext4`)| @@ -170,7 +170,7 @@ The ScaleIO volume plugin is a dynamic provisioner identified as `kubernetes.io/ | protectionDomain| the name of the ScaleIO protection domain (default `default`)| | storagePool| the name of the volume storage pool (default `default`)| | storageMode| the storage provision mode: `ThinProvisionned` (default) or `ThickProvisionned`| -| secretRef| reference to the name of a configuered Secret object (required)| +| secretRef| reference to the name of a configured Secret object (required)| | readOnly| specifies the access mode to the mounted volume (default `false`)| | fsType| the file system to use for the volume (default `ext4`)| diff --git a/federation/apis/federation/v1beta1/generated.pb.go b/federation/apis/federation/v1beta1/generated.pb.go index 052eadcebfb6a..50386d80e4147 100644 --- a/federation/apis/federation/v1beta1/generated.pb.go +++ b/federation/apis/federation/v1beta1/generated.pb.go @@ -1707,60 +1707,59 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 879 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x54, 0xcf, 0x6e, 0xe3, 0x44, - 0x18, 0x8f, 0x9b, 0x26, 0x6d, 0xa6, 0x04, 0x56, 0x23, 0x90, 0x42, 0x24, 0x1c, 0x64, 0x21, 0xd4, - 0x45, 0x8b, 0x4d, 0x0b, 0x42, 0x2b, 0x21, 0x90, 0xd6, 0x59, 0x21, 0xad, 0xe8, 0xaa, 0x68, 0x5a, - 0xed, 0x61, 0x85, 0x04, 0x13, 0xe7, 0xab, 0x6b, 0x62, 0x7b, 0xcc, 0xcc, 0x38, 0x22, 0x7b, 0xe2, - 0x01, 0x40, 0xe2, 0x21, 0x78, 0x03, 0xce, 0xdc, 0x7b, 0x63, 0x0f, 0x1c, 0xf6, 0x14, 0xd1, 0xf0, - 0x16, 0x7b, 0x42, 0x33, 0x9e, 0x38, 0x36, 0x69, 0x96, 0xdd, 0xf6, 0xe6, 0xf9, 0xf9, 0xfb, 0x7e, - 0xbf, 0xef, 0x3f, 0xba, 0x3f, 0xb9, 0x2b, 0xdc, 0x88, 0x79, 0x93, 0x7c, 0x04, 0x3c, 0x05, 0x09, - 0xc2, 0x3b, 0x83, 0x31, 0x70, 0x2a, 0x23, 0x96, 0x7a, 0x34, 0x8b, 0x6a, 0xef, 0xe9, 0xc1, 0x08, - 0x24, 0x3d, 0xf0, 0x42, 0x48, 0x15, 0x04, 0x63, 0x37, 0xe3, 0x4c, 0x32, 0xfc, 0x49, 0xc1, 0xe2, - 0xae, 0x58, 0xdc, 0x95, 0x97, 0xab, 0x58, 0xaa, 0x6f, 0xc3, 0xd2, 0xff, 0x30, 0x8c, 0xe4, 0x79, - 0x3e, 0x72, 0x03, 0x96, 0x78, 0x21, 0x0b, 0x99, 0xa7, 0xc9, 0x46, 0xf9, 0x99, 0x7e, 0xe9, 0x87, - 0xfe, 0x2a, 0x44, 0xfa, 0x46, 0x44, 0x05, 0x95, 0xd0, 0xe0, 0x3c, 0x4a, 0x81, 0xcf, 0xbc, 0x6c, - 0x12, 0x16, 0x51, 0x26, 0x20, 0xa9, 0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c, 0x46, 0x43, 0xeb, 0x77, 0x8d, 0x52, 0xeb, 0x81, 0xe2, 0x24, 0x05, 0xb5, 0xf3, 0x8b, 0x85, - 0xfa, 0xcb, 0xb1, 0x86, 0x18, 0x02, 0xc9, 0x38, 0x81, 0x1f, 0xf2, 0x88, 0x43, 0x02, 0xa9, 0xc4, - 0xef, 0xa0, 0xe6, 0x04, 0x66, 0x66, 0x6a, 0xf7, 0x0c, 0x43, 0xf3, 0x2b, 0x98, 0x11, 0x85, 0xe3, - 0x3b, 0x68, 0x97, 0x65, 0x4a, 0x90, 0x71, 0x33, 0x9d, 0x65, 0x3e, 0xc7, 0x06, 0x27, 0xa5, 0x05, - 0x76, 0x50, 0x7b, 0x4a, 0xe3, 0x1c, 0xd4, 0x16, 0x36, 0xf7, 0x3b, 0x3e, 0x52, 0xcd, 0x78, 0xa4, - 0x11, 0x62, 0xfe, 0x38, 0xbf, 0x6d, 0x95, 0x15, 0x56, 0xfb, 0x8b, 0x7f, 0xb7, 0x50, 0xbf, 0xb8, - 0x74, 0xf7, 0xc6, 0x63, 0x0e, 0x42, 0xf8, 0xb3, 0x61, 0x1c, 0x41, 0x2a, 0x87, 0x0f, 0xee, 0x13, - 0xd1, 0xb3, 0x74, 0x65, 0x8e, 0xaf, 0x57, 0x99, 0x93, 0x4d, 0xbc, 0xbe, 0x63, 0xb2, 0xe8, 0x6f, - 0x34, 0x11, 0xe4, 0x05, 0x61, 0xe1, 0x6f, 0x51, 0x47, 0x40, 0xc0, 0x41, 0x12, 0x38, 0x33, 0x97, - 0xed, 0xf0, 0x8a, 0x18, 0xcd, 0x58, 0xe8, 0x81, 0x60, 0x01, 0x8d, 0x8b, 0x03, 0x49, 0xe0, 0x0c, - 0x38, 0xa4, 0x01, 0xf8, 0xdd, 0xc5, 0x7c, 0xd0, 0x39, 0x59, 0x12, 0x91, 0x15, 0xa7, 0xf3, 0x97, - 0x85, 0xba, 0xb5, 0x6b, 0x84, 0x9f, 0x20, 0x14, 0x2c, 0x37, 0x7d, 0x59, 0x97, 0x2f, 0x6f, 0x34, - 0x31, 0xe5, 0xe1, 0x58, 0x5d, 0xf0, 0x12, 0x12, 0xa4, 0xa2, 0x86, 0x07, 0xa8, 0xf5, 0x84, 0xa5, - 0x20, 0x7a, 0x2d, 0xdd, 0xd7, 0x8e, 0x9a, 0xb2, 0xc7, 0x0a, 0x20, 0x05, 0x5e, 0xac, 0x62, 0x18, - 0xb1, 0xd4, 0x6c, 0x58, 0x65, 0x15, 0x15, 0x4a, 0xcc, 0x5f, 0xe7, 0x67, 0x0b, 0xbd, 0xbd, 0xb1, - 0xe4, 0xf8, 0x10, 0xa1, 0xa0, 0x7c, 0x99, 0x99, 0x5c, 0x85, 0x56, 0xfe, 0x21, 0x15, 0x2b, 0xfc, - 0x19, 0xea, 0xd6, 0xfa, 0x64, 0xc6, 0xb4, 0xbc, 0x5c, 0x35, 0x35, 0x52, 0xb7, 0xf5, 0x6f, 0x5f, - 0x5c, 0xda, 0x8d, 0xa7, 0x97, 0x76, 0xe3, 0xd9, 0xa5, 0xdd, 0xf8, 0x69, 0x61, 0x5b, 0x17, 0x0b, - 0xdb, 0x7a, 0xba, 0xb0, 0xad, 0xbf, 0x17, 0xb6, 0xf5, 0xeb, 0x3f, 0x76, 0xe3, 0xf1, 0x8e, 0xa9, - 0xd9, 0xbf, 0x01, 0x00, 0x00, 0xff, 0xff, 0xfc, 0x8a, 0x4c, 0xa8, 0x18, 0x09, 0x00, 0x00, + // 864 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x54, 0x4f, 0x8f, 0xdb, 0x44, + 0x14, 0x8f, 0x37, 0xff, 0x36, 0x13, 0x02, 0xd5, 0x08, 0xa4, 0x10, 0x09, 0x07, 0x59, 0x08, 0x6d, + 0x51, 0xb1, 0xd9, 0x80, 0x50, 0x25, 0x04, 0x52, 0x9d, 0x0a, 0xa9, 0x62, 0xab, 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 0x50, 0x62, 0xfe, 0x3a, 0x3f, 0x59, 0xe8, 0xed, + 0xbd, 0x2d, 0xc7, 0x03, 0x84, 0x82, 0xc2, 0x32, 0x3b, 0xb9, 0x49, 0xad, 0xf8, 0x43, 0xb6, 0xbc, + 0xf0, 0x67, 0xa8, 0x53, 0x9a, 0x93, 0x59, 0xd3, 0xe2, 0xe5, 0x2a, 0xa9, 0x91, 0xb2, 0xaf, 0x7f, + 0xfb, 0xf2, 0xca, 0xae, 0x3c, 0xbd, 0xb2, 0x2b, 0xcf, 0xae, 0xec, 0xca, 0x8f, 0x2b, 0xdb, 0xba, + 0x5c, 0xd9, 0xd6, 0xd3, 0x95, 0x6d, 0xfd, 0xb5, 0xb2, 0xad, 0x5f, 0xfe, 0xb6, 0x2b, 0x8f, 0x9b, + 0xa6, 0x67, 0xff, 0x04, 0x00, 0x00, 0xff, 0xff, 0x27, 0xd7, 0x7b, 0x6e, 0xe2, 0x08, 0x00, 0x00, } diff --git a/federation/apis/federation/v1beta1/generated.proto b/federation/apis/federation/v1beta1/generated.proto index fc9badaf4c1c6..63d5dd0fe1c08 100644 --- a/federation/apis/federation/v1beta1/generated.proto +++ b/federation/apis/federation/v1beta1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; // Package-wide variables from generator "generated". diff --git a/federation/apis/openapi-spec/swagger.json b/federation/apis/openapi-spec/swagger.json index 4d7bf450db171..5deda45be2851 100644 --- a/federation/apis/openapi-spec/swagger.json +++ b/federation/apis/openapi-spec/swagger.json @@ -102,11 +102,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "parameters": [ @@ -192,11 +192,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "parameters": [ @@ -326,11 +326,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "post": { @@ -371,90 +371,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" - } - }, - "delete": { - "description": "delete collection of Namespace", - "consumes": [ - "*/*" - ], - "produces": [ - "application/json", - "application/yaml", - "application/vnd.kubernetes.protobuf" - ], - "schemes": [ - "https" - ], - "tags": [ - "core_v1" - ], - "operationId": "deleteCoreV1CollectionNamespace", - "parameters": [ - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "name": "fieldSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "If true, partially initialized resources are included in the response.", - "name": "includeUninitialized", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - "name": "labelSelector", - "in": "query" - }, - { - "uniqueItems": true, - "type": "string", - "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", - "name": "resourceVersion", - "in": "query" - }, - { - "uniqueItems": true, - "type": "integer", - "description": "Timeout for the list/watch call.", - "name": "timeoutSeconds", - "in": "query" - }, - { - "uniqueItems": true, - "type": "boolean", - "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - "name": "watch", - "in": "query" - } - ], - "responses": { - "200": { - "description": "OK", - "schema": { - "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Status" - } - }, - "401": { - "description": "Unauthorized" - } - }, - "x-kubernetes-action": "DELETECOLLECTION", - "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "parameters": [ @@ -542,11 +463,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "post": { @@ -587,11 +508,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "delete": { @@ -666,11 +587,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "parameters": [ @@ -736,11 +657,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "put": { @@ -781,11 +702,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "delete": { @@ -847,11 +768,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "patch": { @@ -894,11 +815,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "parameters": [ @@ -1002,11 +923,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "post": { @@ -1047,11 +968,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "delete": { @@ -1126,11 +1047,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "parameters": [ @@ -1196,11 +1117,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "put": { @@ -1241,11 +1162,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "delete": { @@ -1307,11 +1228,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "patch": { @@ -1354,11 +1275,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "parameters": [ @@ -1462,11 +1383,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "post": { @@ -1507,11 +1428,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "delete": { @@ -1586,11 +1507,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "parameters": [ @@ -1656,11 +1577,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "put": { @@ -1701,11 +1622,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "delete": { @@ -1767,11 +1688,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "patch": { @@ -1814,11 +1735,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "parameters": [ @@ -1922,11 +1843,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "post": { @@ -1967,11 +1888,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "delete": { @@ -2046,11 +1967,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -2116,11 +2037,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "put": { @@ -2161,11 +2082,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "delete": { @@ -2227,11 +2148,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "patch": { @@ -2274,11 +2195,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -2336,11 +2257,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "put": { @@ -2381,11 +2302,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "patch": { @@ -2428,11 +2349,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -2506,11 +2427,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "put": { @@ -2551,11 +2472,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "delete": { @@ -2617,11 +2538,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "patch": { @@ -2664,11 +2585,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "parameters": [ @@ -2728,11 +2649,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "parameters": [ @@ -2782,11 +2703,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "put": { @@ -2827,11 +2748,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "patch": { @@ -2874,11 +2795,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "parameters": [ @@ -2930,11 +2851,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "parameters": [ @@ -3020,11 +2941,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -3110,11 +3031,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "parameters": [ @@ -3200,11 +3121,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "parameters": [ @@ -3290,11 +3211,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "parameters": [ @@ -3380,11 +3301,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "parameters": [ @@ -3478,11 +3399,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } }, "parameters": [ @@ -3584,11 +3505,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "parameters": [ @@ -3682,11 +3603,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } }, "parameters": [ @@ -3788,11 +3709,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "parameters": [ @@ -3886,11 +3807,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "parameters": [ @@ -3992,11 +3913,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -4090,11 +4011,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -4196,11 +4117,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } }, "parameters": [ @@ -4294,11 +4215,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } }, "parameters": [ @@ -4384,11 +4305,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } }, "parameters": [ @@ -4573,11 +4494,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "parameters": [ @@ -4663,11 +4584,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ @@ -4753,11 +4674,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "parameters": [ @@ -4887,11 +4808,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "post": { @@ -4932,11 +4853,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "delete": { @@ -5011,11 +4932,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "parameters": [ @@ -5081,11 +5002,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "put": { @@ -5126,11 +5047,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "delete": { @@ -5192,11 +5113,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "patch": { @@ -5239,11 +5160,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "parameters": [ @@ -5301,11 +5222,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "put": { @@ -5346,11 +5267,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "patch": { @@ -5393,11 +5314,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "parameters": [ @@ -5501,11 +5422,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "post": { @@ -5546,11 +5467,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "delete": { @@ -5625,11 +5546,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ @@ -5695,11 +5616,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "put": { @@ -5740,11 +5661,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "delete": { @@ -5806,11 +5727,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "patch": { @@ -5853,11 +5774,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ @@ -5925,11 +5846,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DeploymentRollback" + "group": "extensions", + "version": "v1beta1", + "kind": "DeploymentRollback" } }, "parameters": [ @@ -5987,11 +5908,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "put": { @@ -6032,11 +5953,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "patch": { @@ -6079,11 +6000,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "parameters": [ @@ -6141,11 +6062,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "put": { @@ -6186,11 +6107,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "patch": { @@ -6233,11 +6154,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ @@ -6341,11 +6262,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "post": { @@ -6386,11 +6307,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "delete": { @@ -6465,11 +6386,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "parameters": [ @@ -6535,11 +6456,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "put": { @@ -6580,11 +6501,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "delete": { @@ -6646,11 +6567,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "patch": { @@ -6693,11 +6614,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "parameters": [ @@ -6755,11 +6676,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "put": { @@ -6800,11 +6721,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "patch": { @@ -6847,11 +6768,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "parameters": [ @@ -6955,11 +6876,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "post": { @@ -7000,11 +6921,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "delete": { @@ -7079,11 +7000,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "parameters": [ @@ -7149,11 +7070,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "put": { @@ -7194,11 +7115,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "delete": { @@ -7260,11 +7181,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "patch": { @@ -7307,11 +7228,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "parameters": [ @@ -7369,11 +7290,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "put": { @@ -7414,11 +7335,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "patch": { @@ -7461,11 +7382,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } }, "parameters": [ @@ -7523,11 +7444,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "put": { @@ -7568,11 +7489,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "patch": { @@ -7615,11 +7536,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "parameters": [ @@ -7679,11 +7600,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "parameters": [ @@ -7769,11 +7690,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "parameters": [ @@ -7859,11 +7780,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ @@ -7949,11 +7870,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "parameters": [ @@ -8039,11 +7960,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "parameters": [ @@ -8137,11 +8058,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } }, "parameters": [ @@ -8243,11 +8164,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ @@ -8341,11 +8262,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } }, "parameters": [ @@ -8447,11 +8368,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "parameters": [ @@ -8545,11 +8466,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } }, "parameters": [ @@ -8651,11 +8572,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "parameters": [ @@ -8749,11 +8670,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "parameters": [ @@ -8855,11 +8776,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } }, "parameters": [ @@ -9055,11 +8976,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "LIST", + "x-kubernetes-action": "list", "x-kubernetes-group-version-kind": { - "Group": "federation", - "Version": "v1beta1", - "Kind": "Cluster" + "group": "federation", + "version": "v1beta1", + "kind": "Cluster" } }, "post": { @@ -9100,11 +9021,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "POST", + "x-kubernetes-action": "post", "x-kubernetes-group-version-kind": { - "Group": "federation", - "Version": "v1beta1", - "Kind": "Cluster" + "group": "federation", + "version": "v1beta1", + "kind": "Cluster" } }, "delete": { @@ -9179,11 +9100,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETECOLLECTION", + "x-kubernetes-action": "deletecollection", "x-kubernetes-group-version-kind": { - "Group": "federation", - "Version": "v1beta1", - "Kind": "Cluster" + "group": "federation", + "version": "v1beta1", + "kind": "Cluster" } }, "parameters": [ @@ -9241,11 +9162,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "GET", + "x-kubernetes-action": "get", "x-kubernetes-group-version-kind": { - "Group": "federation", - "Version": "v1beta1", - "Kind": "Cluster" + "group": "federation", + "version": "v1beta1", + "kind": "Cluster" } }, "put": { @@ -9286,11 +9207,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "federation", - "Version": "v1beta1", - "Kind": "Cluster" + "group": "federation", + "version": "v1beta1", + "kind": "Cluster" } }, "delete": { @@ -9352,11 +9273,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "DELETE", + "x-kubernetes-action": "delete", "x-kubernetes-group-version-kind": { - "Group": "federation", - "Version": "v1beta1", - "Kind": "Cluster" + "group": "federation", + "version": "v1beta1", + "kind": "Cluster" } }, "patch": { @@ -9399,11 +9320,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PATCH", + "x-kubernetes-action": "patch", "x-kubernetes-group-version-kind": { - "Group": "federation", - "Version": "v1beta1", - "Kind": "Cluster" + "group": "federation", + "version": "v1beta1", + "kind": "Cluster" } }, "parameters": [ @@ -9463,11 +9384,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "PUT", + "x-kubernetes-action": "put", "x-kubernetes-group-version-kind": { - "Group": "federation", - "Version": "v1beta1", - "Kind": "Cluster" + "group": "federation", + "version": "v1beta1", + "kind": "Cluster" } }, "parameters": [ @@ -9519,11 +9440,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCHLIST", + "x-kubernetes-action": "watchlist", "x-kubernetes-group-version-kind": { - "Group": "federation", - "Version": "v1beta1", - "Kind": "Cluster" + "group": "federation", + "version": "v1beta1", + "kind": "Cluster" } }, "parameters": [ @@ -9609,11 +9530,11 @@ "description": "Unauthorized" } }, - "x-kubernetes-action": "WATCH", + "x-kubernetes-action": "watch", "x-kubernetes-group-version-kind": { - "Group": "federation", - "Version": "v1beta1", - "Kind": "Cluster" + "group": "federation", + "version": "v1beta1", + "kind": "Cluster" } }, "parameters": [ @@ -10400,9 +10321,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "federation", - "Version": "v1beta1", - "Kind": "Cluster" + "group": "federation", + "version": "v1beta1", + "kind": "Cluster" } ] }, @@ -10467,9 +10388,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "federation", - "Version": "v1beta1", - "Kind": "ClusterList" + "group": "federation", + "version": "v1beta1", + "kind": "ClusterList" } ] }, @@ -10729,9 +10650,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ConfigMap" + "group": "", + "version": "v1", + "kind": "ConfigMap" } ] }, @@ -10796,9 +10717,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ConfigMapList" + "group": "", + "version": "v1", + "kind": "ConfigMapList" } ] }, @@ -11049,6 +10970,10 @@ "medium": { "description": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", "type": "string" + }, + "sizeLimit": { + "description": "Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir", + "$ref": "#/definitions/io.k8s.apimachinery.pkg.api.resource.Quantity" } } }, @@ -11165,9 +11090,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "Event" + "group": "", + "version": "v1", + "kind": "Event" } ] }, @@ -11199,9 +11124,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "EventList" + "group": "", + "version": "v1", + "kind": "EventList" } ] }, @@ -11632,9 +11557,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "Namespace" + "group": "", + "version": "v1", + "kind": "Namespace" } ] }, @@ -11666,9 +11591,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "NamespaceList" + "group": "", + "version": "v1", + "kind": "NamespaceList" } ] }, @@ -12401,9 +12326,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "Secret" + "group": "", + "version": "v1", + "kind": "Secret" } ] }, @@ -12468,9 +12393,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "SecretList" + "group": "", + "version": "v1", + "kind": "SecretList" } ] }, @@ -12575,9 +12500,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "Service" + "group": "", + "version": "v1", + "kind": "Service" } ] }, @@ -12609,9 +12534,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "", - "Version": "v1", - "Kind": "ServiceList" + "group": "", + "version": "v1", + "kind": "ServiceList" } ] }, @@ -12988,9 +12913,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSet" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSet" } ] }, @@ -13022,9 +12947,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DaemonSetList" + "group": "extensions", + "version": "v1beta1", + "kind": "DaemonSetList" } ] }, @@ -13147,9 +13072,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Deployment" + "group": "extensions", + "version": "v1beta1", + "kind": "Deployment" } ] }, @@ -13214,9 +13139,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DeploymentList" + "group": "extensions", + "version": "v1beta1", + "kind": "DeploymentList" } ] }, @@ -13253,9 +13178,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "DeploymentRollback" + "group": "extensions", + "version": "v1beta1", + "kind": "DeploymentRollback" } ] }, @@ -13426,9 +13351,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Ingress" + "group": "extensions", + "version": "v1beta1", + "kind": "Ingress" } ] }, @@ -13477,9 +13402,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "IngressList" + "group": "extensions", + "version": "v1beta1", + "kind": "IngressList" } ] }, @@ -13569,9 +13494,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSet" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSet" } ] }, @@ -13632,9 +13557,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "ReplicaSetList" + "group": "extensions", + "version": "v1beta1", + "kind": "ReplicaSetList" } ] }, @@ -13706,7 +13631,7 @@ "io.k8s.kubernetes.pkg.apis.extensions.v1beta1.RollbackConfig": { "properties": { "revision": { - "description": "The revision to rollback to. If set to 0, rollbck to the last revision.", + "description": "The revision to rollback to. If set to 0, rollback to the last revision.", "type": "integer", "format": "int64" } @@ -13760,9 +13685,9 @@ }, "x-kubernetes-group-version-kind": [ { - "Group": "extensions", - "Version": "v1beta1", - "Kind": "Scale" + "group": "extensions", + "version": "v1beta1", + "kind": "Scale" } ] }, diff --git a/federation/apis/swagger-spec/extensions_v1beta1.json b/federation/apis/swagger-spec/extensions_v1beta1.json index d7ea4a687d1f7..98582acdc0ca8 100644 --- a/federation/apis/swagger-spec/extensions_v1beta1.json +++ b/federation/apis/swagger-spec/extensions_v1beta1.json @@ -5179,6 +5179,10 @@ "medium": { "type": "string", "description": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir" + }, + "sizeLimit": { + "type": "string", + "description": "Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir" } } }, @@ -7108,7 +7112,7 @@ "revision": { "type": "integer", "format": "int64", - "description": "The revision to rollback to. If set to 0, rollbck to the last revision." + "description": "The revision to rollback to. If set to 0, rollback to the last revision." } } }, diff --git a/federation/apis/swagger-spec/v1.json b/federation/apis/swagger-spec/v1.json index 6783fd7284b59..d441bfc94d7f2 100644 --- a/federation/apis/swagger-spec/v1.json +++ b/federation/apis/swagger-spec/v1.json @@ -1853,85 +1853,6 @@ "consumes": [ "*/*" ] - }, - { - "type": "v1.Status", - "method": "DELETE", - "summary": "delete collection of Namespace", - "nickname": "deletecollectionNamespace", - "parameters": [ - { - "type": "string", - "paramType": "query", - "name": "pretty", - "description": "If 'true', then the output is pretty printed.", - "required": false, - "allowMultiple": false - }, - { - "type": "string", - "paramType": "query", - "name": "labelSelector", - "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - "required": false, - "allowMultiple": false - }, - { - "type": "string", - "paramType": "query", - "name": "fieldSelector", - "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "required": false, - "allowMultiple": false - }, - { - "type": "boolean", - "paramType": "query", - "name": "includeUninitialized", - "description": "If true, partially initialized resources are included in the response.", - "required": false, - "allowMultiple": false - }, - { - "type": "boolean", - "paramType": "query", - "name": "watch", - "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - "required": false, - "allowMultiple": false - }, - { - "type": "string", - "paramType": "query", - "name": "resourceVersion", - "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", - "required": false, - "allowMultiple": false - }, - { - "type": "integer", - "paramType": "query", - "name": "timeoutSeconds", - "description": "Timeout for the list/watch call.", - "required": false, - "allowMultiple": false - } - ], - "responseMessages": [ - { - "code": 200, - "message": "OK", - "responseModel": "v1.Status" - } - ], - "produces": [ - "application/json", - "application/yaml", - "application/vnd.kubernetes.protobuf" - ], - "consumes": [ - "*/*" - ] } ] }, diff --git a/federation/cmd/federation-apiserver/app/BUILD b/federation/cmd/federation-apiserver/app/BUILD index 84177527d91a0..0966608dce01b 100644 --- a/federation/cmd/federation-apiserver/app/BUILD +++ b/federation/cmd/federation-apiserver/app/BUILD @@ -67,7 +67,6 @@ go_library( "//plugin/pkg/admission/admit:go_default_library", "//plugin/pkg/admission/deny:go_default_library", "//plugin/pkg/admission/gc:go_default_library", - "//plugin/pkg/admission/namespace/lifecycle:go_default_library", "//vendor/github.com/go-openapi/spec:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/github.com/spf13/cobra:go_default_library", diff --git a/federation/cmd/federation-apiserver/app/options/options.go b/federation/cmd/federation-apiserver/app/options/options.go index 36fabdebe4edc..bda3c6c9707d6 100644 --- a/federation/cmd/federation-apiserver/app/options/options.go +++ b/federation/cmd/federation-apiserver/app/options/options.go @@ -37,7 +37,7 @@ type ServerRunOptions struct { Etcd *genericoptions.EtcdOptions SecureServing *genericoptions.SecureServingOptions InsecureServing *kubeoptions.InsecureServingOptions - Audit *genericoptions.AuditLogOptions + Audit *genericoptions.AuditOptions Features *genericoptions.FeatureOptions Admission *genericoptions.AdmissionOptions Authentication *kubeoptions.BuiltInAuthenticationOptions @@ -56,7 +56,7 @@ func NewServerRunOptions() *ServerRunOptions { Etcd: genericoptions.NewEtcdOptions(storagebackend.NewDefaultConfig(kubeoptions.DefaultEtcdPathPrefix, api.Scheme, nil)), SecureServing: kubeoptions.NewSecureServingOptions(), InsecureServing: kubeoptions.NewInsecureServingOptions(), - Audit: genericoptions.NewAuditLogOptions(), + Audit: genericoptions.NewAuditOptions(), Features: genericoptions.NewFeatureOptions(), Admission: genericoptions.NewAdmissionOptions(), Authentication: kubeoptions.NewBuiltInAuthenticationOptions().WithAll(), diff --git a/federation/cmd/federation-apiserver/app/plugins.go b/federation/cmd/federation-apiserver/app/plugins.go index fbad2402da51c..61c5902eb125b 100644 --- a/federation/cmd/federation-apiserver/app/plugins.go +++ b/federation/cmd/federation-apiserver/app/plugins.go @@ -21,14 +21,13 @@ package app // given binary target. import ( // Cloud providers - "k8s.io/apiserver/pkg/admission" _ "k8s.io/kubernetes/pkg/cloudprovider/providers" // Admission policies + "k8s.io/apiserver/pkg/admission" "k8s.io/kubernetes/plugin/pkg/admission/admit" "k8s.io/kubernetes/plugin/pkg/admission/deny" "k8s.io/kubernetes/plugin/pkg/admission/gc" - "k8s.io/kubernetes/plugin/pkg/admission/namespace/lifecycle" ) // registerAllAdmissionPlugins registers all admission plugins @@ -36,5 +35,4 @@ func registerAllAdmissionPlugins(plugins *admission.Plugins) { admit.Register(plugins) deny.Register(plugins) gc.Register(plugins) - lifecycle.Register(plugins) } diff --git a/federation/cmd/federation-apiserver/app/server.go b/federation/cmd/federation-apiserver/app/server.go index dbc7456b93d36..edc2a10c37eec 100644 --- a/federation/cmd/federation-apiserver/app/server.go +++ b/federation/cmd/federation-apiserver/app/server.go @@ -87,6 +87,7 @@ func Run(s *options.ServerRunOptions, stopCh <-chan struct{}) error { func NonBlockingRun(s *options.ServerRunOptions, stopCh <-chan struct{}) error { // register all admission plugins registerAllAdmissionPlugins(s.Admission.Plugins) + // set defaults if err := s.GenericServerRunOptions.DefaultAdvertiseAddress(s.SecureServing); err != nil { return err @@ -227,12 +228,12 @@ func NonBlockingRun(s *options.ServerRunOptions, stopCh <-chan struct{}) error { cachesize.SetWatchCacheSizes(s.GenericServerRunOptions.WatchCacheSizes) } - m, err := genericConfig.Complete().New(genericapiserver.EmptyDelegate) + m, err := genericConfig.Complete().New("federation", genericapiserver.EmptyDelegate) if err != nil { return err } - routes.UIRedirect{}.Install(m.Handler.PostGoRestfulMux) + routes.UIRedirect{}.Install(m.Handler.NonGoRestfulMux) routes.Logs{}.Install(m.Handler.GoRestfulContainer) apiResourceConfigSource := storageFactory.APIResourceConfigSource diff --git a/federation/cmd/federation-controller-manager/app/BUILD b/federation/cmd/federation-controller-manager/app/BUILD index 2ce89231c7085..4f10afb2d7e11 100644 --- a/federation/cmd/federation-controller-manager/app/BUILD +++ b/federation/cmd/federation-controller-manager/app/BUILD @@ -28,6 +28,7 @@ go_library( "//federation/pkg/federation-controller/namespace:go_default_library", "//federation/pkg/federation-controller/replicaset:go_default_library", "//federation/pkg/federation-controller/service:go_default_library", + "//federation/pkg/federation-controller/service/dns:go_default_library", "//federation/pkg/federation-controller/sync:go_default_library", "//pkg/util/configz:go_default_library", "//pkg/version:go_default_library", diff --git a/federation/cmd/federation-controller-manager/app/controllermanager.go b/federation/cmd/federation-controller-manager/app/controllermanager.go index 99035359981df..08a7934fd49a8 100644 --- a/federation/cmd/federation-controller-manager/app/controllermanager.go +++ b/federation/cmd/federation-controller-manager/app/controllermanager.go @@ -42,6 +42,7 @@ import ( namespacecontroller "k8s.io/kubernetes/federation/pkg/federation-controller/namespace" replicasetcontroller "k8s.io/kubernetes/federation/pkg/federation-controller/replicaset" servicecontroller "k8s.io/kubernetes/federation/pkg/federation-controller/service" + servicednscontroller "k8s.io/kubernetes/federation/pkg/federation-controller/service/dns" synccontroller "k8s.io/kubernetes/federation/pkg/federation-controller/sync" "k8s.io/kubernetes/pkg/util/configz" "k8s.io/kubernetes/pkg/version" @@ -136,9 +137,9 @@ func StartControllers(s *options.CMServer, restClientCfg *restclient.Config) err clustercontroller.StartClusterController(restClientCfg, stopChan, s.ClusterMonitorPeriod.Duration) if controllerEnabled(s.Controllers, serverResources, servicecontroller.ControllerName, servicecontroller.RequiredResources, true) { - if controllerEnabled(s.Controllers, serverResources, servicecontroller.DNSControllerName, servicecontroller.RequiredResources, true) { - serviceDNScontrollerClientset := federationclientset.NewForConfigOrDie(restclient.AddUserAgent(restClientCfg, servicecontroller.DNSUserAgentName)) - serviceDNSController, err := servicecontroller.NewServiceDNSController(serviceDNScontrollerClientset, s.DnsProvider, s.DnsConfigFile, s.FederationName, s.ServiceDnsSuffix, s.ZoneName, s.ZoneID) + if controllerEnabled(s.Controllers, serverResources, servicednscontroller.ControllerName, servicecontroller.RequiredResources, true) { + serviceDNScontrollerClientset := federationclientset.NewForConfigOrDie(restclient.AddUserAgent(restClientCfg, servicednscontroller.UserAgentName)) + serviceDNSController, err := servicednscontroller.NewServiceDNSController(serviceDNScontrollerClientset, s.DnsProvider, s.DnsConfigFile, s.FederationName, s.ServiceDnsSuffix, s.ZoneName, s.ZoneID) if err != nil { glog.Fatalf("Failed to start service dns controller: %v", err) } else { diff --git a/federation/docs/api-reference/extensions/v1beta1/definitions.html b/federation/docs/api-reference/extensions/v1beta1/definitions.html index 4201aa6580c95..b15e8bd661ce5 100755 --- a/federation/docs/api-reference/extensions/v1beta1/definitions.html +++ b/federation/docs/api-reference/extensions/v1beta1/definitions.html @@ -2436,6 +2436,13 @@

    v1.EmptyDirVolumeSource

    + + + + + + +

    string

    sizeLimit

    Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir

    false

    string

    @@ -2756,7 +2763,7 @@

    v1beta1.RollbackConfig

    revision

    -

    The revision to rollback to. If set to 0, rollbck to the last revision.

    +

    The revision to rollback to. If set to 0, rollback to the last revision.

    false

    integer (int64)

    @@ -7197,7 +7204,7 @@

    any

    diff --git a/federation/docs/api-reference/v1/operations.html b/federation/docs/api-reference/v1/operations.html index c7d8f683d9498..766c3fdbf1b03 100755 --- a/federation/docs/api-reference/v1/operations.html +++ b/federation/docs/api-reference/v1/operations.html @@ -914,157 +914,6 @@

    Tags

    -

    delete collection of Namespace

    -
    -
    -
    DELETE /api/v1/namespaces
    -
    -
    -
    -

    Parameters

    - -------- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    TypeNameDescriptionRequiredSchemaDefault

    QueryParameter

    pretty

    If true, then the output is pretty printed.

    false

    string

    QueryParameter

    labelSelector

    A selector to restrict the list of returned objects by their labels. Defaults to everything.

    false

    string

    QueryParameter

    fieldSelector

    A selector to restrict the list of returned objects by their fields. Defaults to everything.

    false

    string

    QueryParameter

    includeUninitialized

    If true, partially initialized resources are included in the response.

    false

    boolean

    QueryParameter

    watch

    Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.

    false

    boolean

    QueryParameter

    resourceVersion

    When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it’s 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.

    false

    string

    QueryParameter

    timeoutSeconds

    Timeout for the list/watch call.

    false

    integer (int32)

    - -
    -
    -

    Responses

    - ----- - - - - - - - - - - - - - - -
    HTTP CodeDescriptionSchema

    200

    success

    v1.Status

    - -
    -
    -

    Consumes

    -
    -
      -
    • -

      /

      -
    • -
    -
    -
    -
    -

    Produces

    -
    -
      -
    • -

      application/json

      -
    • -
    • -

      application/yaml

      -
    • -
    • -

      application/vnd.kubernetes.protobuf

      -
    • -
    -
    -
    -
    -

    Tags

    -
    -
      -
    • -

      apiv1

      -
    • -
    -
    -
    -
    -

    create a Namespace

    @@ -1072,7 +921,7 @@

    create a Namespace

    -

    Parameters

    +

    Parameters

    @@ -1114,7 +963,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -1139,7 +988,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -1149,7 +998,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -1165,7 +1014,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -1183,7 +1032,7 @@

      list or watch objects of kin

    -

    Parameters

    +

    Parameters

    @@ -1273,7 +1122,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -1298,7 +1147,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -1308,7 +1157,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -1330,7 +1179,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -1348,7 +1197,7 @@

      delete collection of ConfigMap

    -

    Parameters

    +

    Parameters

    @@ -1438,7 +1287,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -1463,7 +1312,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -1473,7 +1322,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -1489,7 +1338,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -1507,7 +1356,7 @@

      create a ConfigMap

    -

    Parameters

    +

    Parameters

    @@ -1557,7 +1406,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -1582,7 +1431,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -1592,7 +1441,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -1608,7 +1457,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -1626,7 +1475,7 @@

      read the specified ConfigMap

    -

    Parameters

    +

    Parameters

    @@ -1692,7 +1541,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -1717,7 +1566,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -1727,7 +1576,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -1743,7 +1592,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -1761,7 +1610,7 @@

      replace the specified ConfigMap

    -

    Parameters

    +

    Parameters

    @@ -1819,7 +1668,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -1844,7 +1693,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -1854,7 +1703,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -1870,7 +1719,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -1888,7 +1737,7 @@

      delete a ConfigMap

    -

    Parameters

    +

    Parameters

    @@ -1970,7 +1819,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -1995,7 +1844,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -2005,7 +1854,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2021,7 +1870,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -2039,7 +1888,7 @@

      partially update the specifie

    -

    Parameters

    +

    Parameters

    @@ -2097,7 +1946,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -2122,7 +1971,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -2138,7 +1987,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2154,7 +2003,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -2172,7 +2021,7 @@

      list or watch objects of kind Ev

    -

    Parameters

    +

    Parameters

    @@ -2262,7 +2111,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -2287,7 +2136,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -2297,7 +2146,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2319,7 +2168,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -2337,7 +2186,7 @@

      delete collection of Event

    -

    Parameters

    +

    Parameters

    @@ -2427,7 +2276,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -2452,7 +2301,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -2462,7 +2311,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2478,7 +2327,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -2496,7 +2345,7 @@

      create an Event

    -

    Parameters

    +

    Parameters

    @@ -2546,7 +2395,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -2571,7 +2420,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -2581,7 +2430,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2597,7 +2446,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -2615,7 +2464,7 @@

      read the specified Event

    -

    Parameters

    +

    Parameters

    @@ -2681,7 +2530,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -2706,7 +2555,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -2716,7 +2565,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2732,7 +2581,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -2750,7 +2599,7 @@

      replace the specified Event

    -

    Parameters

    +

    Parameters

    @@ -2808,7 +2657,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -2833,7 +2682,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -2843,7 +2692,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -2859,7 +2708,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -2877,7 +2726,7 @@

      delete an Event

    -

    Parameters

    +

    Parameters

    @@ -2959,7 +2808,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -2984,7 +2833,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -2994,7 +2843,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3010,7 +2859,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3028,7 +2877,7 @@

      partially update the specified Ev

    -

    Parameters

    +

    Parameters

    @@ -3086,7 +2935,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3111,7 +2960,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3127,7 +2976,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3143,7 +2992,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3161,7 +3010,7 @@

      list or watch objects of kind Sec

    -

    Parameters

    +

    Parameters

    @@ -3251,7 +3100,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3276,7 +3125,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3286,7 +3135,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3308,7 +3157,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3326,7 +3175,7 @@

      delete collection of Secret

    -

    Parameters

    +

    Parameters

    @@ -3416,7 +3265,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3441,7 +3290,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3451,7 +3300,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3467,7 +3316,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3485,7 +3334,7 @@

      create a Secret

    -

    Parameters

    +

    Parameters

    @@ -3535,7 +3384,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3560,7 +3409,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3570,7 +3419,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3586,7 +3435,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3604,7 +3453,7 @@

      read the specified Secret

    -

    Parameters

    +

    Parameters

    @@ -3670,7 +3519,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3695,7 +3544,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3705,7 +3554,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3721,7 +3570,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3739,7 +3588,7 @@

      replace the specified Secret

    -

    Parameters

    +

    Parameters

    @@ -3797,7 +3646,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3822,7 +3671,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3832,7 +3681,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3848,7 +3697,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -3866,7 +3715,7 @@

      delete a Secret

    -

    Parameters

    +

    Parameters

    @@ -3948,7 +3797,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -3973,7 +3822,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -3983,7 +3832,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -3999,7 +3848,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4017,7 +3866,7 @@

      partially update the specified S

    -

    Parameters

    +

    Parameters

    @@ -4075,7 +3924,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4100,7 +3949,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4116,7 +3965,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4132,7 +3981,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4150,7 +3999,7 @@

      list or watch objects of kind Se

    -

    Parameters

    +

    Parameters

    @@ -4240,7 +4089,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4265,7 +4114,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4275,7 +4124,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4297,7 +4146,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4315,7 +4164,7 @@

      delete collection of Service

    -

    Parameters

    +

    Parameters

    @@ -4405,7 +4254,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4430,7 +4279,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4440,7 +4289,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4456,7 +4305,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4474,7 +4323,7 @@

      create a Service

    -

    Parameters

    +

    Parameters

    @@ -4524,7 +4373,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4549,7 +4398,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4559,7 +4408,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4575,7 +4424,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4593,7 +4442,7 @@

      read the specified Service

    -

    Parameters

    +

    Parameters

    @@ -4659,7 +4508,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4684,7 +4533,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4694,7 +4543,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4710,7 +4559,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4728,7 +4577,7 @@

      replace the specified Service

    -

    Parameters

    +

    Parameters

    @@ -4786,7 +4635,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4811,7 +4660,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4821,7 +4670,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4837,7 +4686,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -4855,7 +4704,7 @@

      delete a Service

    -

    Parameters

    +

    Parameters

    @@ -4937,7 +4786,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -4962,7 +4811,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -4972,7 +4821,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -4988,7 +4837,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5006,7 +4855,7 @@

      partially update the specified

    -

    Parameters

    +

    Parameters

    @@ -5064,7 +4913,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5089,7 +4938,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5105,7 +4954,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5121,7 +4970,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5139,7 +4988,7 @@

      read status of the specified Serv

    -

    Parameters

    +

    Parameters

    @@ -5189,7 +5038,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5214,7 +5063,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5224,7 +5073,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5240,7 +5089,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5258,7 +5107,7 @@

      replace status of the specifie

    -

    Parameters

    +

    Parameters

    @@ -5316,7 +5165,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5341,7 +5190,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5351,7 +5200,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5367,7 +5216,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5385,7 +5234,7 @@

      partially update stat

    -

    Parameters

    +

    Parameters

    @@ -5443,7 +5292,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5468,7 +5317,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5484,7 +5333,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5500,7 +5349,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5518,7 +5367,7 @@

      read the specified Namespace

    -

    Parameters

    +

    Parameters

    @@ -5576,7 +5425,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5601,7 +5450,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5611,7 +5460,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5627,7 +5476,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5645,7 +5494,7 @@

      replace the specified Namespace

    -

    Parameters

    +

    Parameters

    @@ -5695,7 +5544,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5720,7 +5569,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5730,7 +5579,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5746,7 +5595,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5764,7 +5613,7 @@

      delete a Namespace

    -

    Parameters

    +

    Parameters

    @@ -5838,7 +5687,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5863,7 +5712,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5873,7 +5722,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -5889,7 +5738,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -5907,7 +5756,7 @@

      partially update the specifie

    -

    Parameters

    +

    Parameters

    @@ -5957,7 +5806,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -5982,7 +5831,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -5998,7 +5847,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6014,7 +5863,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6032,7 +5881,7 @@

      replace finalize of the sp

    -

    Parameters

    +

    Parameters

    @@ -6082,7 +5931,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6107,7 +5956,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6117,7 +5966,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6133,7 +5982,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6151,7 +6000,7 @@

      read status of the specified Na

    -

    Parameters

    +

    Parameters

    @@ -6193,7 +6042,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6218,7 +6067,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6228,7 +6077,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6244,7 +6093,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6262,7 +6111,7 @@

      replace status of the specif

    -

    Parameters

    +

    Parameters

    @@ -6312,7 +6161,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6337,7 +6186,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6347,7 +6196,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6363,7 +6212,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6381,7 +6230,7 @@

      partially update st

    -

    Parameters

    +

    Parameters

    @@ -6431,7 +6280,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6456,7 +6305,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6472,7 +6321,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6488,7 +6337,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6506,7 +6355,7 @@

      list or watch objects of kind S

    -

    Parameters

    +

    Parameters

    @@ -6588,7 +6437,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6613,7 +6462,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6623,7 +6472,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6645,7 +6494,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6663,7 +6512,7 @@

      list or watch objects of kind

    -

    Parameters

    +

    Parameters

    @@ -6745,7 +6594,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6770,7 +6619,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6780,7 +6629,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6802,7 +6651,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6820,7 +6669,7 @@

      watch individual chang

    -

    Parameters

    +

    Parameters

    @@ -6902,7 +6751,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -6927,7 +6776,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -6937,7 +6786,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -6959,7 +6808,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -6977,7 +6826,7 @@

      watch individual changes t

    -

    Parameters

    +

    Parameters

    @@ -7059,7 +6908,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -7084,7 +6933,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -7094,7 +6943,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -7116,7 +6965,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -7134,7 +6983,7 @@

      watch individual chang

    -

    Parameters

    +

    Parameters

    @@ -7216,7 +7065,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -7241,7 +7090,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -7251,7 +7100,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -7273,7 +7122,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -7291,7 +7140,7 @@

      watch individual cha

    -

    Parameters

    +

    Parameters

    @@ -7381,7 +7230,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -7406,7 +7255,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -7416,7 +7265,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -7438,7 +7287,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -7456,7 +7305,7 @@

      watch changes to an objec

    -

    Parameters

    +

    Parameters

    @@ -7554,7 +7403,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -7579,7 +7428,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -7589,7 +7438,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -7611,7 +7460,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -7629,7 +7478,7 @@

      watch individual changes

    -

    Parameters

    +

    Parameters

    @@ -7719,7 +7568,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -7744,7 +7593,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -7754,7 +7603,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -7776,7 +7625,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -7794,7 +7643,7 @@

      watch changes to an object of

    -

    Parameters

    +

    Parameters

    @@ -7892,7 +7741,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -7917,7 +7766,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -7927,7 +7776,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -7949,7 +7798,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -7967,7 +7816,7 @@

      watch individual changes

    -

    Parameters

    +

    Parameters

    @@ -8057,7 +7906,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -8082,7 +7931,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -8092,7 +7941,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -8114,7 +7963,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -8132,7 +7981,7 @@

      watch changes to an object o

    -

    Parameters

    +

    Parameters

    @@ -8230,7 +8079,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -8255,7 +8104,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -8265,7 +8114,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -8287,7 +8136,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -8305,7 +8154,7 @@

      watch individual changes

    -

    Parameters

    +

    Parameters

    @@ -8395,7 +8244,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -8420,7 +8269,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -8430,7 +8279,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -8452,7 +8301,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -8470,7 +8319,7 @@

      watch changes to an object

    -

    Parameters

    +

    Parameters

    @@ -8568,7 +8417,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -8593,7 +8442,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -8603,7 +8452,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -8625,7 +8474,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -8643,7 +8492,7 @@

      watch changes to an objec

    -

    Parameters

    +

    Parameters

    @@ -8733,7 +8582,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -8758,7 +8607,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -8768,7 +8617,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -8790,7 +8639,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -8808,7 +8657,7 @@

      watch individual change

    -

    Parameters

    +

    Parameters

    @@ -8890,7 +8739,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -8915,7 +8764,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -8925,7 +8774,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -8947,7 +8796,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -8965,7 +8814,7 @@

      watch individual chang

    -

    Parameters

    +

    Parameters

    @@ -9047,7 +8896,7 @@

    Parameters

    -

    Responses

    +

    Responses

    @@ -9072,7 +8921,7 @@

    Responses

    -

    Consumes

    +

    Consumes

    • @@ -9082,7 +8931,7 @@

      Consumes

    -

    Produces

    +

    Produces

    • @@ -9104,7 +8953,7 @@

      Produces

    -

    Tags

    +

    Tags

    • @@ -9119,7 +8968,7 @@

      Tags

    diff --git a/federation/pkg/federation-controller/deployment/deploymentcontroller.go b/federation/pkg/federation-controller/deployment/deploymentcontroller.go index 4ba9b2a4b1abf..91335b4014f78 100644 --- a/federation/pkg/federation-controller/deployment/deploymentcontroller.go +++ b/federation/pkg/federation-controller/deployment/deploymentcontroller.go @@ -472,6 +472,9 @@ func (fdc *DeploymentController) reconcileDeployment(key string) (reconciliation return statusError, err } podStatus, err := podanalyzer.AnalysePods(fd.Spec.Selector, allPods, time.Now()) + if err != nil { + return statusError, err + } current := make(map[string]int64) estimatedCapacity := make(map[string]int64) for _, cluster := range clusters { diff --git a/federation/pkg/federation-controller/ingress/BUILD b/federation/pkg/federation-controller/ingress/BUILD index ade9b9717ce21..16c8226049c70 100644 --- a/federation/pkg/federation-controller/ingress/BUILD +++ b/federation/pkg/federation-controller/ingress/BUILD @@ -16,6 +16,7 @@ go_library( "//federation/apis/federation/v1beta1:go_default_library", "//federation/client/clientset_generated/federation_clientset:go_default_library", "//federation/pkg/federation-controller/util:go_default_library", + "//federation/pkg/federation-controller/util/clusterselector:go_default_library", "//federation/pkg/federation-controller/util/deletionhelper:go_default_library", "//federation/pkg/federation-controller/util/eventsink:go_default_library", "//pkg/api:go_default_library", diff --git a/federation/pkg/federation-controller/ingress/ingress_controller.go b/federation/pkg/federation-controller/ingress/ingress_controller.go index 6cccbae0808f1..931418133644f 100644 --- a/federation/pkg/federation-controller/ingress/ingress_controller.go +++ b/federation/pkg/federation-controller/ingress/ingress_controller.go @@ -35,6 +35,7 @@ import ( federationapi "k8s.io/kubernetes/federation/apis/federation/v1beta1" federationclientset "k8s.io/kubernetes/federation/client/clientset_generated/federation_clientset" "k8s.io/kubernetes/federation/pkg/federation-controller/util" + "k8s.io/kubernetes/federation/pkg/federation-controller/util/clusterselector" "k8s.io/kubernetes/federation/pkg/federation-controller/util/deletionhelper" "k8s.io/kubernetes/federation/pkg/federation-controller/util/eventsink" "k8s.io/kubernetes/pkg/api" @@ -765,7 +766,14 @@ func (ic *IngressController) reconcileIngress(ingress types.NamespacedName) { desiredIngress.Spec = *objSpecCopy glog.V(4).Infof("Desired Ingress: %v", desiredIngress) - if !clusterIngressFound { + send, err := clusterselector.SendToCluster(cluster.Labels, desiredIngress.ObjectMeta.Annotations) + if err != nil { + glog.Errorf("Error processing ClusterSelector cluster: %s for Ingress map: %s error: %s", cluster.Name, key, err.Error()) + return + } + + switch { + case !clusterIngressFound && send: glog.V(4).Infof("No existing Ingress %s in cluster %s - checking if appropriate to queue a create operation", ingress, cluster.Name) // We can't supply server-created fields when creating a new object. desiredIngress.ObjectMeta = util.DeepCopyRelevantObjectMeta(baseIngress.ObjectMeta) @@ -799,7 +807,15 @@ func (ic *IngressController) reconcileIngress(ingress types.NamespacedName) { } else { glog.V(4).Infof("No annotation %q exists on ingress %q in federation and waiting for ingress in cluster %s. Not queueing create operation for ingress until annotation exists", staticIPNameKeyWritable, ingress, firstClusterName) } - } else { + case clusterIngressFound && !send: + glog.V(5).Infof("Removing Ingress: %s from cluster: %s reason: cluster selectors do not match: %-v %-v", key, cluster.Name, cluster.ObjectMeta.Labels, desiredIngress.ObjectMeta.Annotations[federationapi.FederationClusterSelectorAnnotation]) + operations = append(operations, util.FederatedOperation{ + Type: util.OperationTypeDelete, + Obj: desiredIngress, + ClusterName: cluster.Name, + Key: key, + }) + case clusterIngressFound && send: clusterIngress := clusterIngressObj.(*extensionsv1beta1.Ingress) glog.V(4).Infof("Found existing Ingress %s in cluster %s - checking if update is required (in either direction)", ingress, cluster.Name) clusterIPName, clusterIPNameExists := clusterIngress.ObjectMeta.Annotations[staticIPNameKeyReadonly] diff --git a/federation/pkg/federation-controller/ingress/ingress_controller_test.go b/federation/pkg/federation-controller/ingress/ingress_controller_test.go index c1067b00fe417..b3cb5dfcdb3a0 100644 --- a/federation/pkg/federation-controller/ingress/ingress_controller_test.go +++ b/federation/pkg/federation-controller/ingress/ingress_controller_test.go @@ -233,6 +233,7 @@ func TestIngressController(t *testing.T) { fedIngress.ObjectMeta.Annotations = make(map[string]string) } fedIngress.ObjectMeta.Annotations["A"] = "B" + fedIngress.ObjectMeta.Annotations[federationapi.FederationClusterSelectorAnnotation] = `[{"key": "cluster", "operator": "in", "values": ["cluster1","cluster2"]}]` t.Log("Modifying Federated Ingress") fedIngressWatch.Modify(&fedIngress) t.Log("Checking that Ingress was correctly updated in cluster 1") diff --git a/federation/pkg/federation-controller/replicaset/replicasetcontroller.go b/federation/pkg/federation-controller/replicaset/replicasetcontroller.go index b11417dc2aa17..c8946c573c089 100644 --- a/federation/pkg/federation-controller/replicaset/replicasetcontroller.go +++ b/federation/pkg/federation-controller/replicaset/replicasetcontroller.go @@ -452,6 +452,9 @@ func (frsc *ReplicaSetController) reconcileReplicaSet(key string) (reconciliatio return statusError, err } podStatus, err := podanalyzer.AnalysePods(frs.Spec.Selector, allPods, time.Now()) + if err != nil { + return statusError, err + } current := make(map[string]int64) estimatedCapacity := make(map[string]int64) for _, cluster := range clusters { diff --git a/federation/pkg/federation-controller/service/BUILD b/federation/pkg/federation-controller/service/BUILD index 0d8472bd3db66..e378f428cf7cb 100644 --- a/federation/pkg/federation-controller/service/BUILD +++ b/federation/pkg/federation-controller/service/BUILD @@ -10,18 +10,13 @@ load( go_library( name = "go_default_library", - srcs = [ - "dns.go", - "ingress.go", - "servicecontroller.go", - ], + srcs = ["servicecontroller.go"], tags = ["automanaged"], deps = [ "//federation/apis/federation:go_default_library", "//federation/apis/federation/v1beta1:go_default_library", "//federation/client/clientset_generated/federation_clientset:go_default_library", - "//federation/pkg/dnsprovider:go_default_library", - "//federation/pkg/dnsprovider/rrstype:go_default_library", + "//federation/pkg/federation-controller/service/ingress:go_default_library", "//federation/pkg/federation-controller/util:go_default_library", "//federation/pkg/federation-controller/util/clusterselector:go_default_library", "//federation/pkg/federation-controller/util/deletionhelper:go_default_library", @@ -50,16 +45,13 @@ go_library( go_test( name = "go_default_test", - srcs = [ - "dns_test.go", - "servicecontroller_test.go", - ], + srcs = ["servicecontroller_test.go"], library = ":go_default_library", tags = ["automanaged"], deps = [ "//federation/apis/federation/v1beta1:go_default_library", "//federation/client/clientset_generated/federation_clientset/fake:go_default_library", - "//federation/pkg/dnsprovider/providers/google/clouddns:go_default_library", + "//federation/pkg/federation-controller/service/ingress:go_default_library", "//federation/pkg/federation-controller/util:go_default_library", "//federation/pkg/federation-controller/util/test:go_default_library", "//pkg/api/v1:go_default_library", @@ -85,6 +77,10 @@ filegroup( filegroup( name = "all-srcs", - srcs = [":package-srcs"], + srcs = [ + ":package-srcs", + "//federation/pkg/federation-controller/service/dns:all-srcs", + "//federation/pkg/federation-controller/service/ingress:all-srcs", + ], tags = ["automanaged"], ) diff --git a/federation/pkg/federation-controller/service/dns/BUILD b/federation/pkg/federation-controller/service/dns/BUILD new file mode 100644 index 0000000000000..2254642887cdd --- /dev/null +++ b/federation/pkg/federation-controller/service/dns/BUILD @@ -0,0 +1,62 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["dns_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//federation/apis/federation/v1beta1:go_default_library", + "//federation/client/clientset_generated/federation_clientset/fake:go_default_library", + "//federation/pkg/dnsprovider/providers/google/clouddns:go_default_library", + "//federation/pkg/federation-controller/service/ingress:go_default_library", + "//federation/pkg/federation-controller/util/test:go_default_library", + "//pkg/api/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = ["dns.go"], + tags = ["automanaged"], + deps = [ + "//federation/client/clientset_generated/federation_clientset:go_default_library", + "//federation/pkg/dnsprovider:go_default_library", + "//federation/pkg/dnsprovider/rrstype:go_default_library", + "//federation/pkg/federation-controller/service/ingress:go_default_library", + "//federation/pkg/federation-controller/util:go_default_library", + "//pkg/api/v1:go_default_library", + "//pkg/client/listers/core/v1:go_default_library", + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + "//vendor/k8s.io/client-go/util/workqueue:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/federation/pkg/federation-controller/service/dns.go b/federation/pkg/federation-controller/service/dns/dns.go similarity index 96% rename from federation/pkg/federation-controller/service/dns.go rename to federation/pkg/federation-controller/service/dns/dns.go index 8c733e5122371..5d92989b3c263 100644 --- a/federation/pkg/federation-controller/service/dns.go +++ b/federation/pkg/federation-controller/service/dns/dns.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package service +package dns import ( "fmt" @@ -27,6 +27,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" pkgruntime "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/util/runtime" + "k8s.io/apimachinery/pkg/util/sets" "k8s.io/apimachinery/pkg/util/wait" "k8s.io/apimachinery/pkg/watch" "k8s.io/client-go/tools/cache" @@ -34,18 +35,21 @@ import ( fedclientset "k8s.io/kubernetes/federation/client/clientset_generated/federation_clientset" "k8s.io/kubernetes/federation/pkg/dnsprovider" "k8s.io/kubernetes/federation/pkg/dnsprovider/rrstype" + "k8s.io/kubernetes/federation/pkg/federation-controller/service/ingress" "k8s.io/kubernetes/federation/pkg/federation-controller/util" "k8s.io/kubernetes/pkg/api/v1" corelisters "k8s.io/kubernetes/pkg/client/listers/core/v1" ) const ( - DNSControllerName = "service-dns" + ControllerName = "service-dns" - DNSUserAgentName = "federation-service-dns-controller" + UserAgentName = "federation-service-dns-controller" // minDNSTTL is the minimum safe DNS TTL value to use (in seconds). We use this as the TTL for all DNS records. minDNSTTL = 180 + + serviceSyncPeriod = 30 * time.Second ) type ServiceDNSController struct { @@ -148,7 +152,7 @@ func (s *ServiceDNSController) workerFunction() bool { return false } - ingress, err := ParseFederatedServiceIngress(service) + ingress, err := ingress.ParseFederatedServiceIngress(service) if err != nil { runtime.HandleError(fmt.Errorf("Error in parsing lb ingress for service %s/%s: %v", service.Namespace, service.Name, err)) return false @@ -236,7 +240,7 @@ func (s *ServiceDNSController) getHealthyEndpoints(clusterName string, service * return zoneEndpoints, regionEndpoints, globalEndpoints, nil } - serviceIngress, err := ParseFederatedServiceIngress(service) + serviceIngress, err := ingress.ParseFederatedServiceIngress(service) if err != nil { return nil, nil, nil, err } @@ -332,22 +336,23 @@ func findRrset(list []dnsprovider.ResourceRecordSet, rrset dnsprovider.ResourceR non-nil error is also returned (possibly along with a partially complete list of resolved endpoints. */ func getResolvedEndpoints(endpoints []string) ([]string, error) { - resolvedEndpoints := make([]string, 0, len(endpoints)) + resolvedEndpoints := sets.String{} for _, endpoint := range endpoints { if net.ParseIP(endpoint) == nil { // It's not a valid IP address, so assume it's a DNS name, and try to resolve it, // replacing its DNS name with its IP addresses in expandedEndpoints ipAddrs, err := net.LookupHost(endpoint) if err != nil { - return resolvedEndpoints, err + return resolvedEndpoints.List(), err + } + for _, ip := range ipAddrs { + resolvedEndpoints = resolvedEndpoints.Union(sets.NewString(ip)) } - resolvedEndpoints = append(resolvedEndpoints, ipAddrs...) - } else { - resolvedEndpoints = append(resolvedEndpoints, endpoint) + resolvedEndpoints = resolvedEndpoints.Union(sets.NewString(endpoint)) } } - return resolvedEndpoints, nil + return resolvedEndpoints.List(), nil } /* ensureDNSRrsets ensures (idempotently, and with minimum mutations) that all of the DNS resource record sets for dnsName are consistent with endpoints. diff --git a/federation/pkg/federation-controller/service/dns_test.go b/federation/pkg/federation-controller/service/dns/dns_test.go similarity index 89% rename from federation/pkg/federation-controller/service/dns_test.go rename to federation/pkg/federation-controller/service/dns/dns_test.go index 6b9e40890aa7f..d79678822d49d 100644 --- a/federation/pkg/federation-controller/service/dns_test.go +++ b/federation/pkg/federation-controller/service/dns/dns_test.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package service +package dns import ( "fmt" @@ -27,10 +27,19 @@ import ( "k8s.io/kubernetes/federation/apis/federation/v1beta1" fakefedclientset "k8s.io/kubernetes/federation/client/clientset_generated/federation_clientset/fake" "k8s.io/kubernetes/federation/pkg/dnsprovider/providers/google/clouddns" // Only for unit testing purposes. + "k8s.io/kubernetes/federation/pkg/federation-controller/service/ingress" . "k8s.io/kubernetes/federation/pkg/federation-controller/util/test" "k8s.io/kubernetes/pkg/api/v1" ) +// NewClusterWithRegionZone builds a new cluster object with given region and zone attributes. +func NewClusterWithRegionZone(name string, readyStatus v1.ConditionStatus, region, zone string) *v1beta1.Cluster { + cluster := NewCluster(name, readyStatus) + cluster.Status.Zones = []string{zone} + cluster.Status.Region = region + return cluster +} + func TestServiceController_ensureDnsRecords(t *testing.T) { cluster1Name := "c1" cluster2Name := "c2" @@ -51,7 +60,7 @@ func TestServiceController_ensureDnsRecords(t *testing.T) { name: "ServiceWithSingleLBIngress", service: v1.Service{ ObjectMeta: metav1.ObjectMeta{Annotations: map[string]string{ - FederatedServiceIngressAnnotation: NewFederatedServiceIngress(). + ingress.FederatedServiceIngressAnnotation: ingress.NewFederatedServiceIngress(). AddEndpoints(cluster1Name, []string{"198.51.100.1"}). AddEndpoints(cluster2Name, []string{}). String()}, @@ -84,7 +93,7 @@ func TestServiceController_ensureDnsRecords(t *testing.T) { name: "ServiceWithNoLBIngress", service: v1.Service{ ObjectMeta: metav1.ObjectMeta{Annotations: map[string]string{ - FederatedServiceIngressAnnotation: NewFederatedServiceIngress(). + ingress.FederatedServiceIngressAnnotation: ingress.NewFederatedServiceIngress(). AddEndpoints(cluster1Name, []string{}). AddEndpoints(cluster2Name, []string{}). String()}, @@ -101,7 +110,7 @@ func TestServiceController_ensureDnsRecords(t *testing.T) { name: "ServiceWithMultipleLBIngress", service: v1.Service{ ObjectMeta: metav1.ObjectMeta{Annotations: map[string]string{ - FederatedServiceIngressAnnotation: NewFederatedServiceIngress(). + ingress.FederatedServiceIngressAnnotation: ingress.NewFederatedServiceIngress(). AddEndpoints(cluster1Name, []string{"198.51.100.1"}). AddEndpoints(cluster2Name, []string{"198.51.200.1"}). String()}, @@ -119,7 +128,7 @@ func TestServiceController_ensureDnsRecords(t *testing.T) { name: "ServiceWithLBIngressAndServiceDeleted", service: v1.Service{ ObjectMeta: metav1.ObjectMeta{Annotations: map[string]string{ - FederatedServiceIngressAnnotation: NewFederatedServiceIngress(). + ingress.FederatedServiceIngressAnnotation: ingress.NewFederatedServiceIngress(). AddEndpoints(cluster1Name, []string{"198.51.100.1"}). AddEndpoints(cluster2Name, []string{"198.51.200.1"}). String()}, @@ -138,7 +147,7 @@ func TestServiceController_ensureDnsRecords(t *testing.T) { name: "ServiceWithMultipleLBIngressAndOneLBIngressGettingRemoved", service: v1.Service{ ObjectMeta: metav1.ObjectMeta{Annotations: map[string]string{ - FederatedServiceIngressAnnotation: NewFederatedServiceIngress(). + ingress.FederatedServiceIngressAnnotation: ingress.NewFederatedServiceIngress(). AddEndpoints(cluster1Name, []string{"198.51.100.1"}). AddEndpoints(cluster2Name, []string{"198.51.200.1"}). RemoveEndpoint(cluster2Name, "198.51.200.1"). @@ -157,7 +166,7 @@ func TestServiceController_ensureDnsRecords(t *testing.T) { name: "ServiceWithMultipleLBIngressAndAllLBIngressGettingRemoved", service: v1.Service{ ObjectMeta: metav1.ObjectMeta{Annotations: map[string]string{ - FederatedServiceIngressAnnotation: NewFederatedServiceIngress(). + ingress.FederatedServiceIngressAnnotation: ingress.NewFederatedServiceIngress(). AddEndpoints(cluster1Name, []string{"198.51.100.1"}). AddEndpoints(cluster2Name, []string{"198.51.200.1"}). RemoveEndpoint(cluster1Name, "198.51.100.1"). @@ -198,7 +207,7 @@ func TestServiceController_ensureDnsRecords(t *testing.T) { test.service.Name = "servicename" test.service.Namespace = "servicenamespace" - ingress, err := ParseFederatedServiceIngress(&test.service) + ingress, err := ingress.ParseFederatedServiceIngress(&test.service) if err != nil { t.Errorf("Error in parsing lb ingress for service %s/%s: %v", test.service.Namespace, test.service.Name, err) return diff --git a/federation/pkg/federation-controller/service/ingress/BUILD b/federation/pkg/federation-controller/service/ingress/BUILD new file mode 100644 index 0000000000000..61694447560f4 --- /dev/null +++ b/federation/pkg/federation-controller/service/ingress/BUILD @@ -0,0 +1,31 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["ingress.go"], + tags = ["automanaged"], + deps = [ + "//federation/apis/federation:go_default_library", + "//pkg/api/v1:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/federation/pkg/federation-controller/service/ingress.go b/federation/pkg/federation-controller/service/ingress/ingress.go similarity index 99% rename from federation/pkg/federation-controller/service/ingress.go rename to federation/pkg/federation-controller/service/ingress/ingress.go index 0fdf9103407e3..d78f7d4835792 100644 --- a/federation/pkg/federation-controller/service/ingress.go +++ b/federation/pkg/federation-controller/service/ingress/ingress.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package service +package ingress import ( "encoding/json" diff --git a/federation/pkg/federation-controller/service/servicecontroller.go b/federation/pkg/federation-controller/service/servicecontroller.go index 10b6c2a2b8541..2e89f15095159 100644 --- a/federation/pkg/federation-controller/service/servicecontroller.go +++ b/federation/pkg/federation-controller/service/servicecontroller.go @@ -41,6 +41,7 @@ import ( fedapi "k8s.io/kubernetes/federation/apis/federation" v1beta1 "k8s.io/kubernetes/federation/apis/federation/v1beta1" fedclientset "k8s.io/kubernetes/federation/client/clientset_generated/federation_clientset" + "k8s.io/kubernetes/federation/pkg/federation-controller/service/ingress" fedutil "k8s.io/kubernetes/federation/pkg/federation-controller/util" "k8s.io/kubernetes/federation/pkg/federation-controller/util/clusterselector" "k8s.io/kubernetes/federation/pkg/federation-controller/util/deletionhelper" @@ -52,7 +53,7 @@ import ( ) const ( - serviceSyncPeriod = 10 * time.Minute + serviceSyncPeriod = 30 * time.Second UserAgentName = "federation-service-controller" @@ -472,7 +473,7 @@ func (s *ServiceController) reconcileService(key string) reconciliationStatus { } newLBStatus := newLoadbalancerStatus() - newServiceIngress := NewFederatedServiceIngress() + newServiceIngress := ingress.NewFederatedServiceIngress() operations := make([]fedutil.FederatedOperation, 0) for _, cluster := range clusters { // Aggregate all operations to perform on all federated clusters @@ -660,7 +661,7 @@ func (s *ServiceController) getServiceEndpointsInCluster(cluster *v1beta1.Cluste // updateFederatedService updates the federated service with aggregated lbStatus and serviceIngresses // and also updates the dns records as needed -func (s *ServiceController) updateFederatedService(fedService *v1.Service, newLBStatus *loadbalancerStatus, newServiceIngress *FederatedServiceIngress) error { +func (s *ServiceController) updateFederatedService(fedService *v1.Service, newLBStatus *loadbalancerStatus, newServiceIngress *ingress.FederatedServiceIngress) error { key := types.NamespacedName{Namespace: fedService.Namespace, Name: fedService.Name}.String() needUpdate := false @@ -672,7 +673,7 @@ func (s *ServiceController) updateFederatedService(fedService *v1.Service, newLB needUpdate = true } - existingServiceIngress, err := ParseFederatedServiceIngress(fedService) + existingServiceIngress, err := ingress.ParseFederatedServiceIngress(fedService) if err != nil { runtime.HandleError(fmt.Errorf("Failed to parse endpoint annotations for service %s: %v", key, err)) return err @@ -695,7 +696,7 @@ func (s *ServiceController) updateFederatedService(fedService *v1.Service, newLB // Update federated service status and/or ingress annotations if changed sort.Sort(newServiceIngress) if !reflect.DeepEqual(existingServiceIngress.Items, newServiceIngress.Items) { - fedService = UpdateIngressAnnotation(fedService, newServiceIngress) + fedService = ingress.UpdateIngressAnnotation(fedService, newServiceIngress) glog.V(3).Infof("Federated service loadbalancer ingress updated for %s: existing: %#v, desired: %#v", key, existingServiceIngress, newServiceIngress) needUpdate = true } diff --git a/federation/pkg/federation-controller/service/servicecontroller_test.go b/federation/pkg/federation-controller/service/servicecontroller_test.go index a98ae0936c4f8..8e6b196719065 100644 --- a/federation/pkg/federation-controller/service/servicecontroller_test.go +++ b/federation/pkg/federation-controller/service/servicecontroller_test.go @@ -32,6 +32,7 @@ import ( "k8s.io/client-go/tools/cache" "k8s.io/kubernetes/federation/apis/federation/v1beta1" fakefedclientset "k8s.io/kubernetes/federation/client/clientset_generated/federation_clientset/fake" + "k8s.io/kubernetes/federation/pkg/federation-controller/service/ingress" fedutil "k8s.io/kubernetes/federation/pkg/federation-controller/util" . "k8s.io/kubernetes/federation/pkg/federation-controller/util/test" "k8s.io/kubernetes/pkg/api/v1" @@ -58,8 +59,8 @@ var awfulError error = errors.NewGone("Something bad happened") func TestServiceController(t *testing.T) { glog.Infof("Creating fake infrastructure") fedClient := &fakefedclientset.Clientset{} - cluster1 := NewClusterWithRegionZone("cluster1", v1.ConditionTrue, "region1", "zone1") - cluster2 := NewClusterWithRegionZone("cluster2", v1.ConditionTrue, "region2", "zone2") + cluster1 := NewCluster("cluster1", v1.ConditionTrue) + cluster2 := NewCluster("cluster2", v1.ConditionTrue) RegisterFakeClusterGet(&fedClient.Fake, &v1beta1.ClusterList{Items: []v1beta1.Cluster{*cluster1, *cluster2}}) RegisterFakeList(clusters, &fedClient.Fake, &v1beta1.ClusterList{Items: []v1beta1.Cluster{*cluster1, *cluster2}}) @@ -151,10 +152,10 @@ func TestServiceController(t *testing.T) { key, desiredService, serviceStatusCompare, wait.ForeverTestTimeout)) glog.Infof("Test federation service is updated when cluster1 endpoint for the service is created") - desiredIngressAnnotation := NewFederatedServiceIngress(). + desiredIngressAnnotation := ingress.NewFederatedServiceIngress(). AddEndpoints("cluster1", []string{lbIngress1}). String() - desiredService = &v1.Service{ObjectMeta: metav1.ObjectMeta{Annotations: map[string]string{FederatedServiceIngressAnnotation: desiredIngressAnnotation}}} + desiredService = &v1.Service{ObjectMeta: metav1.ObjectMeta{Annotations: map[string]string{ingress.FederatedServiceIngressAnnotation: desiredIngressAnnotation}}} c1EndpointWatch.Add(NewEndpoint("test-service-1", serviceEndpoint1)) require.NoError(t, WaitForFederatedServiceUpdate(t, sc.serviceStore, key, desiredService, serviceIngressCompare, wait.ForeverTestTimeout)) @@ -175,20 +176,20 @@ func TestServiceController(t *testing.T) { key, desiredService, serviceStatusCompare, wait.ForeverTestTimeout)) glog.Infof("Test federation service is updated when cluster2 endpoint for the service is created") - desiredIngressAnnotation = NewFederatedServiceIngress(). + desiredIngressAnnotation = ingress.NewFederatedServiceIngress(). AddEndpoints("cluster1", []string{lbIngress1}). AddEndpoints("cluster2", []string{lbIngress2}). String() - desiredService = &v1.Service{ObjectMeta: metav1.ObjectMeta{Annotations: map[string]string{FederatedServiceIngressAnnotation: desiredIngressAnnotation}}} + desiredService = &v1.Service{ObjectMeta: metav1.ObjectMeta{Annotations: map[string]string{ingress.FederatedServiceIngressAnnotation: desiredIngressAnnotation}}} c2EndpointWatch.Add(NewEndpoint("test-service-1", serviceEndpoint2)) require.NoError(t, WaitForFederatedServiceUpdate(t, sc.serviceStore, key, desiredService, serviceIngressCompare, wait.ForeverTestTimeout)) glog.Infof("Test federation service is updated when cluster1 endpoint for the service is deleted") - desiredIngressAnnotation = NewFederatedServiceIngress(). + desiredIngressAnnotation = ingress.NewFederatedServiceIngress(). AddEndpoints("cluster2", []string{lbIngress2}). String() - desiredService = &v1.Service{ObjectMeta: metav1.ObjectMeta{Annotations: map[string]string{FederatedServiceIngressAnnotation: desiredIngressAnnotation}}} + desiredService = &v1.Service{ObjectMeta: metav1.ObjectMeta{Annotations: map[string]string{ingress.FederatedServiceIngressAnnotation: desiredIngressAnnotation}}} c1EndpointWatch.Delete(NewEndpoint("test-service-1", serviceEndpoint1)) require.NoError(t, WaitForFederatedServiceUpdate(t, sc.serviceStore, key, desiredService, serviceIngressCompare, wait.ForeverTestTimeout)) @@ -211,7 +212,7 @@ func TestServiceController(t *testing.T) { func TestGetOperationsToPerformOnCluster(t *testing.T) { obj := NewService("test-service-1", 80) - cluster1 := NewClusterWithRegionZone("cluster1", v1.ConditionTrue, "region1", "zone1") + cluster1 := NewCluster("cluster1", v1.ConditionTrue) fedClient := &fakefedclientset.Clientset{} sc := New(fedClient) @@ -287,14 +288,6 @@ func NewEndpoint(name, ip string) *v1.Endpoints { } } -// NewClusterWithRegionZone builds a new cluster object with given region and zone attributes. -func NewClusterWithRegionZone(name string, readyStatus v1.ConditionStatus, region, zone string) *v1beta1.Cluster { - cluster := NewCluster(name, readyStatus) - cluster.Status.Zones = []string{zone} - cluster.Status.Region = region - return cluster -} - // WaitForClusterService waits for the cluster service to be created matching the desiredService. func WaitForClusterService(t *testing.T, store fedutil.FederatedReadOnlyStore, clusterName, key string, desiredService *v1.Service, timeout time.Duration) error { err := wait.PollImmediate(retryInterval, timeout, func() (bool, error) { @@ -325,11 +318,11 @@ func serviceStatusCompare(current, desired *v1.Service) bool { } func serviceIngressCompare(current, desired *v1.Service) bool { - if strings.Compare(current.Annotations[FederatedServiceIngressAnnotation], desired.Annotations[FederatedServiceIngressAnnotation]) != 0 { - glog.V(5).Infof("Waiting for loadbalancer ingress, Current: %v, Desired: %v", current.Annotations[FederatedServiceIngressAnnotation], desired.Annotations[FederatedServiceIngressAnnotation]) + if strings.Compare(current.Annotations[ingress.FederatedServiceIngressAnnotation], desired.Annotations[ingress.FederatedServiceIngressAnnotation]) != 0 { + glog.V(5).Infof("Waiting for loadbalancer ingress, Current: %v, Desired: %v", current.Annotations[ingress.FederatedServiceIngressAnnotation], desired.Annotations[ingress.FederatedServiceIngressAnnotation]) return false } - glog.V(5).Infof("Loadbalancer ingress match: %v", current.Annotations[FederatedServiceIngressAnnotation]) + glog.V(5).Infof("Loadbalancer ingress match: %v", current.Annotations[ingress.FederatedServiceIngressAnnotation]) return true } diff --git a/federation/pkg/federation-controller/sync/BUILD b/federation/pkg/federation-controller/sync/BUILD index 020a836644c58..9e6dee6d657a2 100644 --- a/federation/pkg/federation-controller/sync/BUILD +++ b/federation/pkg/federation-controller/sync/BUILD @@ -52,6 +52,7 @@ go_test( "//federation/pkg/federation-controller/util/test:go_default_library", "//pkg/api/v1:go_default_library", "//vendor/github.com/stretchr/testify/require:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", ], ) diff --git a/federation/pkg/federation-controller/sync/controller.go b/federation/pkg/federation-controller/sync/controller.go index 7b5e3bef848a9..77221449eeb60 100644 --- a/federation/pkg/federation-controller/sync/controller.go +++ b/federation/pkg/federation-controller/sync/controller.go @@ -356,10 +356,10 @@ func (s *FederationSyncController) reconcile(namespacedName types.NamespacedName return statusError } - operationsAccessor := func(adapter federatedtypes.FederatedTypeAdapter, clusters []*federationapi.Cluster, obj pkgruntime.Object) ([]util.FederatedOperation, error) { - operations, err := clusterOperations(adapter, clusters, obj, key, func(clusterName string) (interface{}, bool, error) { + operationsAccessor := func(adapter federatedtypes.FederatedTypeAdapter, selectedClusters []*federationapi.Cluster, unselectedClusters []*federationapi.Cluster, obj pkgruntime.Object) ([]util.FederatedOperation, error) { + operations, err := clusterOperations(adapter, selectedClusters, unselectedClusters, obj, key, func(clusterName string) (interface{}, bool, error) { return s.informer.GetTargetStore().GetByKey(clusterName, key) - }, clusterselector.SendToCluster) + }) if err != nil { s.eventRecorder.Eventf(obj, api.EventTypeWarning, "FedClusterOperationsError", "Error obtaining sync operations for %s: %s error: %s", kind, key, err.Error()) } @@ -369,6 +369,7 @@ func (s *FederationSyncController) reconcile(namespacedName types.NamespacedName return syncToClusters( s.informer.GetReadyClusters, operationsAccessor, + selectedClusters, s.updater.Update, s.adapter, obj, @@ -422,11 +423,12 @@ func (s *FederationSyncController) delete(obj pkgruntime.Object, kind string, na } type clustersAccessorFunc func() ([]*federationapi.Cluster, error) -type operationsFunc func(federatedtypes.FederatedTypeAdapter, []*federationapi.Cluster, pkgruntime.Object) ([]util.FederatedOperation, error) +type operationsFunc func(federatedtypes.FederatedTypeAdapter, []*federationapi.Cluster, []*federationapi.Cluster, pkgruntime.Object) ([]util.FederatedOperation, error) +type clusterSelectorFunc func(*metav1.ObjectMeta, func(map[string]string, map[string]string) (bool, error), []*federationapi.Cluster) ([]*federationapi.Cluster, []*federationapi.Cluster, error) type executionFunc func([]util.FederatedOperation) error // syncToClusters ensures that the state of the given object is synchronized to member clusters. -func syncToClusters(clustersAccessor clustersAccessorFunc, operationsAccessor operationsFunc, execute executionFunc, adapter federatedtypes.FederatedTypeAdapter, obj pkgruntime.Object) reconciliationStatus { +func syncToClusters(clustersAccessor clustersAccessorFunc, operationsAccessor operationsFunc, selector clusterSelectorFunc, execute executionFunc, adapter federatedtypes.FederatedTypeAdapter, obj pkgruntime.Object) reconciliationStatus { kind := adapter.Kind() key := federatedtypes.ObjectKey(adapter, obj) @@ -438,7 +440,12 @@ func syncToClusters(clustersAccessor clustersAccessorFunc, operationsAccessor op return statusNotSynced } - operations, err := operationsAccessor(adapter, clusters, obj) + selectedClusters, unselectedClusters, err := selector(adapter.ObjectMeta(obj), clusterselector.SendToCluster, clusters) + if err != nil { + return statusError + } + + operations, err := operationsAccessor(adapter, selectedClusters, unselectedClusters, obj) if err != nil { return statusError } @@ -456,18 +463,33 @@ func syncToClusters(clustersAccessor clustersAccessorFunc, operationsAccessor op return statusNeedsRecheck } +// selectedClusters filters the provided clusters into two slices, one containing the clusters selected by selector and the other containing the rest of the provided clusters. +func selectedClusters(objMeta *metav1.ObjectMeta, selector func(map[string]string, map[string]string) (bool, error), clusters []*federationapi.Cluster) ([]*federationapi.Cluster, []*federationapi.Cluster, error) { + selectedClusters := []*federationapi.Cluster{} + unselectedClusters := []*federationapi.Cluster{} + + for _, cluster := range clusters { + send, err := selector(cluster.Labels, objMeta.Annotations) + if err != nil { + return nil, nil, err + } else if !send { + unselectedClusters = append(unselectedClusters, cluster) + } else { + selectedClusters = append(selectedClusters, cluster) + } + } + return selectedClusters, unselectedClusters, nil +} + type clusterObjectAccessorFunc func(clusterName string) (interface{}, bool, error) -type clusterSelectorFunc func(map[string]string, map[string]string) (bool, error) // clusterOperations returns the list of operations needed to synchronize the state of the given object to the provided clusters -func clusterOperations(adapter federatedtypes.FederatedTypeAdapter, clusters []*federationapi.Cluster, obj pkgruntime.Object, key string, accessor clusterObjectAccessorFunc, selector clusterSelectorFunc) ([]util.FederatedOperation, error) { +func clusterOperations(adapter federatedtypes.FederatedTypeAdapter, selectedClusters []*federationapi.Cluster, unselectedClusters []*federationapi.Cluster, obj pkgruntime.Object, key string, accessor clusterObjectAccessorFunc) ([]util.FederatedOperation, error) { // The data should not be modified. desiredObj := adapter.Copy(obj) - objMeta := adapter.ObjectMeta(desiredObj) - kind := adapter.Kind() operations := make([]util.FederatedOperation, 0) - for _, cluster := range clusters { + for _, cluster := range selectedClusters { clusterObj, found, err := accessor(cluster.Name) if err != nil { wrappedErr := fmt.Errorf("Failed to get %s %q from cluster %q: %v", adapter.Kind(), key, cluster.Name, err) @@ -475,24 +497,13 @@ func clusterOperations(adapter federatedtypes.FederatedTypeAdapter, clusters []* return nil, wrappedErr } - send, err := selector(cluster.Labels, objMeta.Annotations) - if err != nil { - glog.Errorf("Error processing ClusterSelector cluster: %s for %s map: %s error: %s", cluster.Name, kind, key, err.Error()) - return nil, err - } else if !send { - glog.V(5).Infof("Skipping cluster: %s for %s: %s reason: cluster selectors do not match: %-v %-v", cluster.Name, kind, key, cluster.ObjectMeta.Labels, objMeta.Annotations[federationapi.FederationClusterSelectorAnnotation]) - } - var operationType util.FederatedOperationType = "" - switch { - case found && send: + if found { clusterObj := clusterObj.(pkgruntime.Object) if !adapter.Equivalent(desiredObj, clusterObj) { operationType = util.OperationTypeUpdate } - case found && !send: - operationType = util.OperationTypeDelete - case !found && send: + } else { operationType = util.OperationTypeAdd } @@ -505,5 +516,23 @@ func clusterOperations(adapter federatedtypes.FederatedTypeAdapter, clusters []* }) } } + + for _, cluster := range unselectedClusters { + _, found, err := accessor(cluster.Name) + if err != nil { + wrappedErr := fmt.Errorf("Failed to get %s %q from cluster %q: %v", adapter.Kind(), key, cluster.Name, err) + runtime.HandleError(wrappedErr) + return nil, wrappedErr + } + if found { + operations = append(operations, util.FederatedOperation{ + Type: util.OperationTypeDelete, + Obj: desiredObj, + ClusterName: cluster.Name, + Key: key, + }) + } + } + return operations, nil } diff --git a/federation/pkg/federation-controller/sync/controller_test.go b/federation/pkg/federation-controller/sync/controller_test.go index 10023a4eb3895..667e84710953b 100644 --- a/federation/pkg/federation-controller/sync/controller_test.go +++ b/federation/pkg/federation-controller/sync/controller_test.go @@ -20,6 +20,7 @@ import ( "errors" "testing" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" pkgruntime "k8s.io/apimachinery/pkg/runtime" federationapi "k8s.io/kubernetes/federation/apis/federation/v1beta1" "k8s.io/kubernetes/federation/pkg/federatedtypes" @@ -74,12 +75,15 @@ func TestSyncToClusters(t *testing.T) { } return nil, nil }, - func(federatedtypes.FederatedTypeAdapter, []*federationapi.Cluster, pkgruntime.Object) ([]util.FederatedOperation, error) { + func(federatedtypes.FederatedTypeAdapter, []*federationapi.Cluster, []*federationapi.Cluster, pkgruntime.Object) ([]util.FederatedOperation, error) { if testCase.operationsError { return nil, awfulError } return testCase.operations, nil }, + func(objMeta *metav1.ObjectMeta, selector func(map[string]string, map[string]string) (bool, error), clusters []*federationapi.Cluster) ([]*federationapi.Cluster, []*federationapi.Cluster, error) { + return clusters, []*federationapi.Cluster{}, nil + }, func([]util.FederatedOperation) error { if testCase.executionError { return awfulError @@ -94,6 +98,67 @@ func TestSyncToClusters(t *testing.T) { } } +func TestSelectedClusters(t *testing.T) { + clusterOne := fedtest.NewCluster("cluster1", apiv1.ConditionTrue) + clusterOne.Labels = map[string]string{"name": "cluster1"} + clusterTwo := fedtest.NewCluster("cluster2", apiv1.ConditionTrue) + clusterTwo.Labels = map[string]string{"name": "cluster2"} + + clusters := []*federationapi.Cluster{clusterOne, clusterTwo} + testCases := map[string]struct { + expectedSelectorError bool + clusterOneSelected bool + clusterTwoSelected bool + expectedSelectedClusters []*federationapi.Cluster + expectedUnselectedClusters []*federationapi.Cluster + }{ + "Selector returned error": { + expectedSelectorError: true, + }, + "All clusters selected": { + clusterOneSelected: true, + clusterTwoSelected: true, + expectedSelectedClusters: clusters, + expectedUnselectedClusters: []*federationapi.Cluster{}, + }, + "One cluster selected": { + clusterOneSelected: true, + expectedSelectedClusters: []*federationapi.Cluster{clusterOne}, + expectedUnselectedClusters: []*federationapi.Cluster{clusterTwo}, + }, + "No clusters selected": { + expectedSelectedClusters: []*federationapi.Cluster{}, + expectedUnselectedClusters: clusters, + }, + } + + for testName, testCase := range testCases { + t.Run(testName, func(t *testing.T) { + selectedClusters, unselectedClusters, err := selectedClusters(&metav1.ObjectMeta{}, func(labels map[string]string, annotations map[string]string) (bool, error) { + if testCase.expectedSelectorError { + return false, awfulError + } + if labels["name"] == "cluster1" { + return testCase.clusterOneSelected, nil + } + if labels["name"] == "cluster2" { + return testCase.clusterTwoSelected, nil + } + t.Errorf("Unexpected cluster") + return false, nil + }, clusters) + + if testCase.expectedSelectorError { + require.Error(t, err, "An error was expected") + } else { + require.NoError(t, err, "An error was not expected") + } + require.Equal(t, testCase.expectedSelectedClusters, selectedClusters, "Expected the correct clusters to be selected.") + require.Equal(t, testCase.expectedUnselectedClusters, unselectedClusters, "Expected the correct clusters to be unselected.") + }) + } +} + func TestClusterOperations(t *testing.T) { adapter := &federatedtypes.SecretAdapter{} obj := adapter.NewTestObject("foo") @@ -101,19 +166,15 @@ func TestClusterOperations(t *testing.T) { federatedtypes.SetAnnotation(adapter, differingObj, "foo", "bar") testCases := map[string]struct { - clusterObject pkgruntime.Object - expectedErr bool - expectedSendErr bool - sendToCluster bool + clusterObject pkgruntime.Object + expectedErr bool + sendToCluster bool operationType util.FederatedOperationType }{ "Accessor error returned": { expectedErr: true, }, - "sendToCluster error returned": { - expectedSendErr: true, - }, "Missing cluster object should result in add operation": { operationType: util.OperationTypeAdd, sendToCluster: true, @@ -138,18 +199,21 @@ func TestClusterOperations(t *testing.T) { clusters := []*federationapi.Cluster{fedtest.NewCluster("cluster1", apiv1.ConditionTrue)} key := federatedtypes.ObjectKey(adapter, obj) - operations, err := clusterOperations(adapter, clusters, obj, key, func(string) (interface{}, bool, error) { + var selectedClusters, unselectedClusters []*federationapi.Cluster + if testCase.sendToCluster { + selectedClusters = clusters + unselectedClusters = []*federationapi.Cluster{} + } else { + selectedClusters = []*federationapi.Cluster{} + unselectedClusters = clusters + } + operations, err := clusterOperations(adapter, selectedClusters, unselectedClusters, obj, key, func(string) (interface{}, bool, error) { if testCase.expectedErr { return nil, false, awfulError } return testCase.clusterObject, (testCase.clusterObject != nil), nil - }, func(map[string]string, map[string]string) (bool, error) { - if testCase.expectedSendErr { - return false, awfulError - } - return testCase.sendToCluster, nil }) - if testCase.expectedErr || testCase.expectedSendErr { + if testCase.expectedErr { require.Error(t, err, "An error was expected") } else { require.NoError(t, err, "An error was not expected") diff --git a/federation/pkg/federation-controller/util/test/test_helper.go b/federation/pkg/federation-controller/util/test/test_helper.go index 9647cf9d20922..c75b9ca047756 100644 --- a/federation/pkg/federation-controller/util/test/test_helper.go +++ b/federation/pkg/federation-controller/util/test/test_helper.go @@ -344,7 +344,7 @@ func CompareObjectMeta(a, b metav1.ObjectMeta) error { return fmt.Errorf("Different namespace expected:%s observed:%s", a.Namespace, b.Namespace) } if a.Name != b.Name { - return fmt.Errorf("Different name expected:%s observed:%s", a.Namespace, b.Namespace) + return fmt.Errorf("Different name expected:%s observed:%s", a.Name, b.Name) } if !reflect.DeepEqual(a.Labels, b.Labels) && (len(a.Labels) != 0 || len(b.Labels) != 0) { return fmt.Errorf("Labels are different expected:%v observed:%v", a.Labels, b.Labels) @@ -366,6 +366,7 @@ func NewCluster(name string, readyStatus apiv1.ConditionStatus) *federationapi.C ObjectMeta: metav1.ObjectMeta{ Name: name, Annotations: map[string]string{}, + Labels: map[string]string{"cluster": name}, }, Status: federationapi.ClusterStatus{ Conditions: []federationapi.ClusterCondition{ diff --git a/federation/pkg/kubefed/init/init.go b/federation/pkg/kubefed/init/init.go index 6171b6735beaf..13388216ef403 100644 --- a/federation/pkg/kubefed/init/init.go +++ b/federation/pkg/kubefed/init/init.go @@ -139,6 +139,7 @@ type initFederationOptions struct { dnsProviderConfig string etcdImage string etcdPVCapacity string + etcdPVStorageClass string etcdPersistentStorage bool dryRun bool apiServerOverridesString string @@ -159,6 +160,7 @@ func (o *initFederationOptions) Bind(flags *pflag.FlagSet, defaultServerImage, d flags.StringVar(&o.dnsProviderConfig, "dns-provider-config", "", "Config file path on local file system for configuring DNS provider.") flags.StringVar(&o.etcdImage, "etcd-image", defaultEtcdImage, "Image to use for etcd server.") flags.StringVar(&o.etcdPVCapacity, "etcd-pv-capacity", "10Gi", "Size of persistent volume claim to be used for etcd.") + flags.StringVar(&o.etcdPVStorageClass, "etcd-pv-storage-class", "", "The storage class of the persistent volume claim used for etcd. Must be provided if a default storage class is not enabled for the host cluster.") flags.BoolVar(&o.etcdPersistentStorage, "etcd-persistent-storage", true, "Use persistent volume for etcd. Defaults to 'true'.") flags.BoolVar(&o.dryRun, "dry-run", false, "dry run without sending commands to server.") flags.StringVar(&o.apiServerOverridesString, "apiserver-arg-overrides", "", "comma separated list of federation-apiserver arguments to override: Example \"--arg1=value1,--arg2=value2...\"") @@ -325,7 +327,7 @@ func (i *initFederation) Run(cmdOut io.Writer, config util.AdminConfig) error { glog.V(4).Info("Creating a persistent volume and a claim to store the federation API server's state, including etcd data") var pvc *api.PersistentVolumeClaim if i.options.etcdPersistentStorage { - pvc, err = createPVC(hostClientset, i.commonOptions.FederationSystemNamespace, svc.Name, i.commonOptions.Name, i.options.etcdPVCapacity, i.options.dryRun) + pvc, err = createPVC(hostClientset, i.commonOptions.FederationSystemNamespace, svc.Name, i.commonOptions.Name, i.options.etcdPVCapacity, i.options.etcdPVStorageClass, i.options.dryRun) if err != nil { return err } @@ -638,20 +640,25 @@ func createControllerManagerKubeconfigSecret(clientset client.Interface, namespa return util.CreateKubeconfigSecret(clientset, config, namespace, kubeconfigName, name, "", dryRun) } -func createPVC(clientset client.Interface, namespace, svcName, federationName, etcdPVCapacity string, dryRun bool) (*api.PersistentVolumeClaim, error) { +func createPVC(clientset client.Interface, namespace, svcName, federationName, etcdPVCapacity, etcdPVStorageClass string, dryRun bool) (*api.PersistentVolumeClaim, error) { capacity, err := resource.ParseQuantity(etcdPVCapacity) if err != nil { return nil, err } + var storageClassName *string + if len(etcdPVStorageClass) > 0 { + storageClassName = &etcdPVStorageClass + } + pvc := &api.PersistentVolumeClaim{ ObjectMeta: metav1.ObjectMeta{ Name: fmt.Sprintf("%s-etcd-claim", svcName), Namespace: namespace, Labels: componentLabel, Annotations: map[string]string{ - "volume.alpha.kubernetes.io/storage-class": "yes", - federation.FederationNameAnnotation: federationName}, + federation.FederationNameAnnotation: federationName, + }, }, Spec: api.PersistentVolumeClaimSpec{ AccessModes: []api.PersistentVolumeAccessMode{ @@ -662,6 +669,7 @@ func createPVC(clientset client.Interface, namespace, svcName, federationName, e api.ResourceStorage: capacity, }, }, + StorageClassName: storageClassName, }, } diff --git a/federation/pkg/kubefed/init/init_test.go b/federation/pkg/kubefed/init/init_test.go index 4598a6256fef9..765bbad5ffb91 100644 --- a/federation/pkg/kubefed/init/init_test.go +++ b/federation/pkg/kubefed/init/init_test.go @@ -98,6 +98,7 @@ func TestInitFederation(t *testing.T) { serverImage string etcdImage string etcdPVCapacity string + etcdPVStorageClass string etcdPersistence string expectedErr string dnsProvider string @@ -200,6 +201,7 @@ func TestInitFederation(t *testing.T) { serverImage: "example.test/foo:bar", etcdImage: "gcr.io/google_containers/etcd:latest", etcdPVCapacity: "5Gi", + etcdPVStorageClass: "fast", etcdPersistence: "true", expectedErr: "", dryRun: "", @@ -244,7 +246,7 @@ func TestInitFederation(t *testing.T) { tc.etcdImage = defaultEtcdImage } - hostFactory, err := fakeInitHostFactory(tc.apiserverServiceType, tc.federation, util.DefaultFederationSystemNamespace, tc.advertiseAddress, tc.lbIP, tc.dnsZoneName, tc.serverImage, tc.etcdImage, tc.dnsProvider, tc.dnsProviderConfig, tc.etcdPersistence, tc.etcdPVCapacity, tc.apiserverArgOverrides, tc.cmArgOverrides, tmpDirPath, tc.apiserverEnableHTTPBasicAuth, tc.apiserverEnableTokenAuth, tc.isRBACAPIAvailable) + hostFactory, err := fakeInitHostFactory(tc.apiserverServiceType, tc.federation, util.DefaultFederationSystemNamespace, tc.advertiseAddress, tc.lbIP, tc.dnsZoneName, tc.serverImage, tc.etcdImage, tc.dnsProvider, tc.dnsProviderConfig, tc.etcdPersistence, tc.etcdPVCapacity, tc.etcdPVStorageClass, tc.apiserverArgOverrides, tc.cmArgOverrides, tmpDirPath, tc.apiserverEnableHTTPBasicAuth, tc.apiserverEnableTokenAuth, tc.isRBACAPIAvailable) if err != nil { t.Fatalf("[%d] unexpected error: %v", i, err) } @@ -271,6 +273,9 @@ func TestInitFederation(t *testing.T) { if tc.etcdPVCapacity != "" { cmd.Flags().Set("etcd-pv-capacity", tc.etcdPVCapacity) } + if tc.etcdPVStorageClass != "" { + cmd.Flags().Set("etcd-pv-storage-class", tc.etcdPVStorageClass) + } if tc.etcdPersistence != "true" { cmd.Flags().Set("etcd-persistent-storage", tc.etcdPersistence) } @@ -616,7 +621,7 @@ func TestCertsHTTPS(t *testing.T) { } } -func fakeInitHostFactory(apiserverServiceType v1.ServiceType, federationName, namespaceName, advertiseAddress, lbIp, dnsZoneName, serverImage, etcdImage, dnsProvider, dnsProviderConfig, etcdPersistence, etcdPVCapacity, apiserverOverrideArg, cmOverrideArg, tmpDirPath string, apiserverEnableHTTPBasicAuth, apiserverEnableTokenAuth, isRBACAPIAvailable bool) (cmdutil.Factory, error) { +func fakeInitHostFactory(apiserverServiceType v1.ServiceType, federationName, namespaceName, advertiseAddress, lbIp, dnsZoneName, serverImage, etcdImage, dnsProvider, dnsProviderConfig, etcdPersistence, etcdPVCapacity, etcdPVStorageClass, apiserverOverrideArg, cmOverrideArg, tmpDirPath string, apiserverEnableHTTPBasicAuth, apiserverEnableTokenAuth, isRBACAPIAvailable bool) (cmdutil.Factory, error) { svcName := federationName + "-apiserver" svcUrlPrefix := "/api/v1/namespaces/federation-system/services" credSecretName := svcName + "-credentials" @@ -729,6 +734,11 @@ func fakeInitHostFactory(apiserverServiceType v1.ServiceType, federationName, na Data: nil, } + var storageClassName *string + if len(etcdPVStorageClass) > 0 { + storageClassName = &etcdPVStorageClass + } + pvc := v1.PersistentVolumeClaim{ TypeMeta: metav1.TypeMeta{ Kind: "PersistentVolumeClaim", @@ -739,8 +749,7 @@ func fakeInitHostFactory(apiserverServiceType v1.ServiceType, federationName, na Namespace: namespaceName, Labels: componentLabel, Annotations: map[string]string{ - "volume.alpha.kubernetes.io/storage-class": "yes", - federation.FederationNameAnnotation: federationName, + federation.FederationNameAnnotation: federationName, }, }, Spec: v1.PersistentVolumeClaimSpec{ @@ -752,6 +761,7 @@ func fakeInitHostFactory(apiserverServiceType v1.ServiceType, federationName, na v1.ResourceStorage: capacity, }, }, + StorageClassName: storageClassName, }, } diff --git a/federation/pkg/kubefed/kubefed.go b/federation/pkg/kubefed/kubefed.go index 6a35d6daf5021..8676e2ae642bc 100644 --- a/federation/pkg/kubefed/kubefed.go +++ b/federation/pkg/kubefed/kubefed.go @@ -67,7 +67,7 @@ func NewKubeFedCommand(f cmdutil.Factory, in io.Reader, out, err io.Writer, defa templates.ActsAsRootCommand(cmds, filters, groups...) cmds.AddCommand(kubectl.NewCmdVersion(f, out)) - cmds.AddCommand(kubectl.NewCmdOptions()) + cmds.AddCommand(kubectl.NewCmdOptions(out)) return cmds } diff --git a/hack/.linted_packages b/hack/.linted_packages index cf5d004aa3a0e..42e84968ff007 100644 --- a/hack/.linted_packages +++ b/hack/.linted_packages @@ -13,6 +13,7 @@ cmd/gke-certificates-controller cmd/kube-apiserver cmd/kube-apiserver/app cmd/kube-apiserver/app/options +cmd/kube-apiserver/app/preflight cmd/kube-controller-manager cmd/kube-controller-manager/app/options cmd/kube-proxy @@ -58,6 +59,7 @@ pkg/api/errors pkg/api/events pkg/api/install pkg/api/meta +pkg/api/persistentvolume pkg/api/pod pkg/api/resource pkg/api/service @@ -66,6 +68,7 @@ pkg/api/v1/node pkg/api/v1/service pkg/apis/abac/v0 pkg/apis/abac/v1beta1 +pkg/apis/admissionregistration/install pkg/apis/apps/install pkg/apis/apps/v1beta1 pkg/apis/authentication/install @@ -80,6 +83,8 @@ pkg/apis/componentconfig/install pkg/apis/extensions/install pkg/apis/extensions/v1beta1 pkg/apis/imagepolicy/install +pkg/apis/networking/install +pkg/apis/networking/validation pkg/apis/policy/install pkg/apis/rbac/install pkg/apis/rbac/v1alpha1 @@ -91,6 +96,8 @@ pkg/auth/nodeidentifier pkg/bootstrap/api pkg/client/conditions pkg/client/informers/informers_generated/externalversions +pkg/client/informers/informers_generated/externalversions/admissionregistration +pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1 pkg/client/informers/informers_generated/externalversions/apps pkg/client/informers/informers_generated/externalversions/apps/v1beta1 pkg/client/informers/informers_generated/externalversions/autoscaling @@ -105,6 +112,8 @@ pkg/client/informers/informers_generated/externalversions/core pkg/client/informers/informers_generated/externalversions/core/v1 pkg/client/informers/informers_generated/externalversions/extensions pkg/client/informers/informers_generated/externalversions/extensions/v1beta1 +pkg/client/informers/informers_generated/externalversions/networking +pkg/client/informers/informers_generated/externalversions/networking/v1 pkg/client/informers/informers_generated/externalversions/policy pkg/client/informers/informers_generated/externalversions/policy/v1beta1 pkg/client/informers/informers_generated/externalversions/rbac @@ -116,6 +125,8 @@ pkg/client/informers/informers_generated/externalversions/storage pkg/client/informers/informers_generated/externalversions/storage/v1 pkg/client/informers/informers_generated/externalversions/storage/v1beta1 pkg/client/informers/informers_generated/internalversion +pkg/client/informers/informers_generated/internalversion/admissionregistration +pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion pkg/client/informers/informers_generated/internalversion/apps pkg/client/informers/informers_generated/internalversion/apps/internalversion pkg/client/informers/informers_generated/internalversion/autoscaling @@ -128,6 +139,8 @@ pkg/client/informers/informers_generated/internalversion/core pkg/client/informers/informers_generated/internalversion/core/internalversion pkg/client/informers/informers_generated/internalversion/extensions pkg/client/informers/informers_generated/internalversion/extensions/internalversion +pkg/client/informers/informers_generated/internalversion/networking +pkg/client/informers/informers_generated/internalversion/networking/internalversion pkg/client/informers/informers_generated/internalversion/policy pkg/client/informers/informers_generated/internalversion/policy/internalversion pkg/client/informers/informers_generated/internalversion/rbac @@ -136,6 +149,8 @@ pkg/client/informers/informers_generated/internalversion/settings pkg/client/informers/informers_generated/internalversion/settings/internalversion pkg/client/informers/informers_generated/internalversion/storage pkg/client/informers/informers_generated/internalversion/storage/internalversion +pkg/client/listers/admissionregistration/internalversion +pkg/client/listers/admissionregistration/v1alpha1 pkg/client/listers/apps/internalversion pkg/client/listers/apps/v1beta1 pkg/client/listers/authentication/internalversion @@ -158,6 +173,8 @@ pkg/client/listers/extensions/internalversion pkg/client/listers/extensions/v1beta1 pkg/client/listers/imagepolicy/internalversion pkg/client/listers/imagepolicy/v1alpha1 +pkg/client/listers/networking/internalversion +pkg/client/listers/networking/v1 pkg/client/listers/policy/internalversion pkg/client/listers/policy/v1alpha1 pkg/client/listers/policy/v1beta1 @@ -208,6 +225,7 @@ pkg/proxy/healthcheck pkg/quota pkg/quota/install pkg/registry +pkg/registry/apps/controllerrevision/storage pkg/registry/authorization/util pkg/registry/core/configmap/storage pkg/registry/core/endpoint @@ -307,6 +325,8 @@ staging/src/k8s.io/apimachinery/pkg/api/errors staging/src/k8s.io/apimachinery/pkg/api/resource staging/src/k8s.io/apimachinery/pkg/apimachinery staging/src/k8s.io/apimachinery/pkg/conversion/queryparams +staging/src/k8s.io/apimachinery/pkg/fields +staging/src/k8s.io/apimachinery/pkg/labels staging/src/k8s.io/apimachinery/pkg/runtime staging/src/k8s.io/apimachinery/pkg/runtime/serializer/json staging/src/k8s.io/apimachinery/pkg/runtime/serializer/recognizer/testing @@ -337,17 +357,22 @@ staging/src/k8s.io/apiserver/pkg/storage/names staging/src/k8s.io/apiserver/pkg/storage/storagebackend/factory staging/src/k8s.io/apiserver/pkg/storage/storagebackend/factory staging/src/k8s.io/apiserver/pkg/storage/value/encrypt/aes +staging/src/k8s.io/apiserver/pkg/storage/value/encrypt/identity staging/src/k8s.io/apiserver/pkg/util/flushwriter staging/src/k8s.io/apiserver/pkg/util/logs +staging/src/k8s.io/apiserver/plugin/pkg/audit/webhook staging/src/k8s.io/apiserver/plugin/pkg/authenticator staging/src/k8s.io/apiserver/plugin/pkg/authenticator/password staging/src/k8s.io/apiserver/plugin/pkg/authenticator/password/allow staging/src/k8s.io/apiserver/plugin/pkg/authenticator/request/basicauth staging/src/k8s.io/client-go/discovery +staging/src/k8s.io/client-go/examples/create-update-delete-deployment staging/src/k8s.io/client-go/examples/in-cluster staging/src/k8s.io/client-go/examples/out-of-cluster staging/src/k8s.io/client-go/examples/third-party-resources staging/src/k8s.io/client-go/informers +staging/src/k8s.io/client-go/informers/admissionregistration +staging/src/k8s.io/client-go/informers/admissionregistration/v1alpha1 staging/src/k8s.io/client-go/informers/apps staging/src/k8s.io/client-go/informers/apps/v1beta1 staging/src/k8s.io/client-go/informers/autoscaling @@ -362,6 +387,8 @@ staging/src/k8s.io/client-go/informers/core staging/src/k8s.io/client-go/informers/core/v1 staging/src/k8s.io/client-go/informers/extensions staging/src/k8s.io/client-go/informers/extensions/v1beta1 +staging/src/k8s.io/client-go/informers/networking +staging/src/k8s.io/client-go/informers/networking/v1 staging/src/k8s.io/client-go/informers/policy staging/src/k8s.io/client-go/informers/policy/v1beta1 staging/src/k8s.io/client-go/informers/rbac @@ -372,6 +399,7 @@ staging/src/k8s.io/client-go/informers/settings/v1alpha1 staging/src/k8s.io/client-go/informers/storage staging/src/k8s.io/client-go/informers/storage/v1 staging/src/k8s.io/client-go/informers/storage/v1beta1 +staging/src/k8s.io/client-go/listers/admissionregistration/v1alpha1 staging/src/k8s.io/client-go/listers/apps/v1beta1 staging/src/k8s.io/client-go/listers/autoscaling/v1 staging/src/k8s.io/client-go/listers/autoscaling/v2alpha1 @@ -380,6 +408,7 @@ staging/src/k8s.io/client-go/listers/batch/v2alpha1 staging/src/k8s.io/client-go/listers/certificates/v1beta1 staging/src/k8s.io/client-go/listers/core/v1 staging/src/k8s.io/client-go/listers/extensions/v1beta1 +staging/src/k8s.io/client-go/listers/networking/v1 staging/src/k8s.io/client-go/listers/policy/v1beta1 staging/src/k8s.io/client-go/listers/rbac/v1alpha1 staging/src/k8s.io/client-go/listers/rbac/v1beta1 @@ -411,12 +440,12 @@ staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/install staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/validation staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions -staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1alpha1 +staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1beta1 staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/internalversion staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/internalversion/apiextensions staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/internalversion/apiextensions/internalversion staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/internalversion -staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1alpha1 +staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1beta1 staging/src/k8s.io/kube-apiextensions-server/test/integration staging/src/k8s.io/metrics/pkg/apis/custom_metrics/install staging/src/k8s.io/metrics/pkg/apis/metrics/install diff --git a/hack/e2e.go b/hack/e2e.go index 3ba2d77d7fe21..889754a668197 100644 --- a/hack/e2e.go +++ b/hack/e2e.go @@ -112,7 +112,7 @@ func (t tester) lookKubetest() (string, error) { p := filepath.Join(t.goPath, "bin", "kubetest") _, err := t.stat(p) if err == nil { - return p, err + return p, nil } } diff --git a/hack/gen-swagger-doc/Dockerfile b/hack/gen-swagger-doc/Dockerfile index 38ece9db7e83b..7eb2fdaa59740 100644 --- a/hack/gen-swagger-doc/Dockerfile +++ b/hack/gen-swagger-doc/Dockerfile @@ -35,7 +35,7 @@ COPY gen-swagger-docs.sh build/ # Run the script once to download the dependent java libraries into the image RUN mkdir -p /output /swagger-source \ && wget https://raw.githubusercontent.com/kubernetes/kubernetes/master/api/swagger-spec/v1.json -O /swagger-source/v1.json \ - && wget https://raw.githubusercontent.com/GoogleCloudPlatform/kubernetes/master/pkg/api/v1/register.go -O /register.go \ + && wget https://raw.githubusercontent.com/kubernetes/kubernetes/master/pkg/api/v1/register.go -O /register.go \ && build/gen-swagger-docs.sh v1 \ && rm -rf /output/* /swagger-source/* /register.go diff --git a/hack/lib/golang.sh b/hack/lib/golang.sh index 1156f9c516bd8..ce3bea0fa22db 100755 --- a/hack/lib/golang.sh +++ b/hack/lib/golang.sh @@ -267,11 +267,6 @@ kube::golang::set_platform_envs() { # Do not set CC when building natively on a platform, only if cross-compiling from linux/amd64 if [[ $(kube::golang::host_platform) == "linux/amd64" ]]; then - # We are currently using go 1.8.1, which has significant performance - # regression. Until this is fixed in Golang head, we are using patched - # version of Go that eliminates this problem. - export GOROOT=${K8S_PATCHED_GOROOT:-${GOROOT}} - # Dynamic CGO linking for other server architectures than linux/amd64 goes here # If you want to include support for more server platforms than these, add arch-specific gcc names here case "${platform}" in diff --git a/hack/lib/init.sh b/hack/lib/init.sh old mode 100644 new mode 100755 index c3fc455581d5f..41967e1c8eace --- a/hack/lib/init.sh +++ b/hack/lib/init.sh @@ -52,6 +52,7 @@ KUBE_OUTPUT_HOSTBIN="${KUBE_OUTPUT_BINPATH}/$(kube::util::host_platform)" # most preferred version for a group should appear first KUBE_AVAILABLE_GROUP_VERSIONS="${KUBE_AVAILABLE_GROUP_VERSIONS:-\ v1 \ +admissionregistration.k8s.io/v1alpha1 \ apps/v1beta1 \ authentication.k8s.io/v1 \ authentication.k8s.io/v1beta1 \ @@ -64,6 +65,7 @@ batch/v2alpha1 \ certificates.k8s.io/v1beta1 \ extensions/v1beta1 \ imagepolicy.k8s.io/v1alpha1 \ +networking.k8s.io/v1 \ policy/v1beta1 \ rbac.authorization.k8s.io/v1beta1 \ rbac.authorization.k8s.io/v1alpha1 \ diff --git a/hack/local-up-cluster.sh b/hack/local-up-cluster.sh index 1188fee113fa9..f5f5554bba6c1 100755 --- a/hack/local-up-cluster.sh +++ b/hack/local-up-cluster.sh @@ -45,7 +45,7 @@ CGROUP_DRIVER=${CGROUP_DRIVER:-""} USER=${USER:-$(whoami)} # enables testing eviction scenarios locally. -EVICTION_HARD=${EVICTION_HARD:-"memory.available<100Mi"} +EVICTION_HARD=${EVICTION_HARD:-"memory.available<100Mi,nodefs.available<10%,nodefs.inodesFree<5%"} EVICTION_SOFT=${EVICTION_SOFT:-""} EVICTION_PRESSURE_TRANSITION_PERIOD=${EVICTION_PRESSURE_TRANSITION_PERIOD:-"1m"} @@ -62,7 +62,7 @@ ENABLE_DAEMON=${ENABLE_DAEMON:-false} HOSTNAME_OVERRIDE=${HOSTNAME_OVERRIDE:-"127.0.0.1"} CLOUD_PROVIDER=${CLOUD_PROVIDER:-""} CLOUD_CONFIG=${CLOUD_CONFIG:-""} -FEATURE_GATES=${FEATURE_GATES:-"AllAlpha=true"} +FEATURE_GATES=${FEATURE_GATES:-"AllAlpha=false"} STORAGE_BACKEND=${STORAGE_BACKEND:-"etcd3"} # enable swagger ui ENABLE_SWAGGER_UI=${ENABLE_SWAGGER_UI:-false} @@ -76,6 +76,7 @@ ENABLE_APISERVER_BASIC_AUDIT=${ENABLE_APISERVER_BASIC_AUDIT:-false} # RBAC Mode options ALLOW_ANY_TOKEN=${ALLOW_ANY_TOKEN:-false} ENABLE_RBAC=${ENABLE_RBAC:-false} +AUTHORIZATION_MODE=${AUTHORIZATION_MODE:-""} KUBECONFIG_TOKEN=${KUBECONFIG_TOKEN:-""} AUTH_ARGS=${AUTH_ARGS:-""} @@ -86,6 +87,10 @@ DEFAULT_STORAGE_CLASS=${KUBE_DEFAULT_STORAGE_CLASS:-true} KUBE_CACHE_MUTATION_DETECTOR="${KUBE_CACHE_MUTATION_DETECTOR:-true}" export KUBE_CACHE_MUTATION_DETECTOR +# panic the server on watch decode errors since they are considered coder mistakes +KUBE_PANIC_WATCH_DECODE_ERROR="${KUBE_PANIC_WATCH_DECODE_ERROR:-true}" +export KUBE_PANIC_WATCH_DECODE_ERROR + ADMISSION_CONTROL_CONFIG_FILE=${ADMISSION_CONTROL_CONFIG_FILE:-""} # START_MODE can be 'all', 'kubeletonly', or 'nokubelet' @@ -197,6 +202,8 @@ KUBELET_HOST=${KUBELET_HOST:-"127.0.0.1"} API_CORS_ALLOWED_ORIGINS=${API_CORS_ALLOWED_ORIGINS:-/127.0.0.1(:[0-9]+)?$,/localhost(:[0-9]+)?$} KUBELET_PORT=${KUBELET_PORT:-10250} LOG_LEVEL=${LOG_LEVEL:-3} +# Use to increase verbosity on particular files, e.g. LOG_SPEC=token_controller*=5,other_controller*=4 +LOG_SPEC=${LOG_SPEC:-""} LOG_DIR=${LOG_DIR:-"/tmp"} CONTAINER_RUNTIME=${CONTAINER_RUNTIME:-"docker"} CONTAINER_RUNTIME_ENDPOINT=${CONTAINER_RUNTIME_ENDPOINT:-""} @@ -431,6 +438,12 @@ function start_apiserver { if [[ "${ENABLE_RBAC}" = true ]]; then authorizer_arg="--authorization-mode=RBAC " fi + if [[ -n "${AUTHORIZATION_MODE}" ]]; then + if [[ "${ENABLE_RBAC}" = true ]]; then + warning "AUTHORIZATION_MODE=$AUTHORIZATION_MODE overrode ENABLE_RBAC=true" + fi + authorizer_arg="--authorization-mode=${AUTHORIZATION_MODE} " + fi priv_arg="" if [[ -n "${ALLOW_PRIVILEGED}" ]]; then priv_arg="--allow-privileged " @@ -483,6 +496,7 @@ function start_apiserver { ${CONTROLPLANE_SUDO} "${GO_OUT}/hyperkube" apiserver ${swagger_arg} ${audit_arg} ${anytoken_arg} ${authorizer_arg} ${priv_arg} ${runtime_config}\ ${advertise_address} \ --v=${LOG_LEVEL} \ + --vmodule="${LOG_SPEC}" \ --cert-dir="${CERT_DIR}" \ --client-ca-file="${CERT_DIR}/client-ca.crt" \ --service-account-key-file="${SERVICE_ACCOUNT_KEY}" \ @@ -658,11 +672,11 @@ function start_kubelet { ${KUBELET_FLAGS} >"${KUBELET_LOG}" 2>&1 & KUBELET_PID=$! # Quick check that kubelet is running. - if ps -p $KUBELET_PID > /dev/null ; then + if ps -p $KUBELET_PID > /dev/null ; then echo "kubelet ( $KUBELET_PID ) is running." else cat ${KUBELET_LOG} ; exit 1 - fi + fi else # Docker won't run a container with a cidfile (container id file) # unless that file does not already exist; clean up an existing @@ -733,7 +747,7 @@ function start_kubedns { echo "Creating kube-system namespace" sed -e "s/{{ pillar\['dns_domain'\] }}/${DNS_DOMAIN}/g" "${KUBE_ROOT}/cluster/addons/dns/kubedns-controller.yaml.in" >| kubedns-deployment.yaml sed -e "s/{{ pillar\['dns_server'\] }}/${DNS_SERVER_IP}/g" "${KUBE_ROOT}/cluster/addons/dns/kubedns-svc.yaml.in" >| kubedns-svc.yaml - + # TODO update to dns role once we have one. ${KUBECTL} --kubeconfig="${CERT_DIR}/admin.kubeconfig" create clusterrolebinding system:kube-dns --clusterrole=cluster-admin --serviceaccount=kube-system:default # use kubectl to create kubedns deployment and service @@ -748,7 +762,7 @@ function start_kubedns { function start_kubedashboard { if [[ "${ENABLE_CLUSTER_DASHBOARD}" = true ]]; then - echo "Creating kubernetes-dashboard" + echo "Creating kubernetes-dashboard" # use kubectl to create the dashboard ${KUBECTL} --kubeconfig="${CERT_DIR}/admin.kubeconfig" create -f ${KUBE_ROOT}/cluster/addons/dashboard/dashboard-controller.yaml ${KUBECTL} --kubeconfig="${CERT_DIR}/admin.kubeconfig" create -f ${KUBE_ROOT}/cluster/addons/dashboard/dashboard-service.yaml @@ -890,7 +904,7 @@ if [[ "${START_MODE}" != "nokubelet" ]]; then esac fi -if [[ -n "${PSP_ADMISSION}" && "${ENABLE_RBAC}" = true ]]; then +if [[ -n "${PSP_ADMISSION}" && ("${ENABLE_RBAC}" = true || "${AUTHORIZATION_MODE}" = *RBAC* ) ]]; then create_psp_policy fi diff --git a/hack/lookup_pull.py b/hack/lookup_pull.py index 3bbbac1cccb51..e290981d5bb62 100755 --- a/hack/lookup_pull.py +++ b/hack/lookup_pull.py @@ -21,7 +21,7 @@ import urllib2 PULLQUERY=("https://api.github.com/repos/" - "GoogleCloudPlatform/kubernetes/pulls/{pull}") + "kubernetes/kubernetes/pulls/{pull}") LOGIN="login" TITLE="title" USER="user" diff --git a/hack/make-rules/test-cmd-util.sh b/hack/make-rules/test-cmd-util.sh index 5fe2ee218d5e8..76c1c1fd5779b 100644 --- a/hack/make-rules/test-cmd-util.sh +++ b/hack/make-rules/test-cmd-util.sh @@ -20,6 +20,9 @@ set -o errexit set -o nounset set -o pipefail +# Set locale to ensure english responses from kubectl commands +export LANG=C + KUBE_ROOT=$(dirname "${BASH_SOURCE}")/../.. # Expects the following has already been done by whatever sources this script # source "${KUBE_ROOT}/hack/lib/init.sh" @@ -30,7 +33,6 @@ ETCD_PORT=${ETCD_PORT:-2379} API_PORT=${API_PORT:-8080} SECURE_API_PORT=${SECURE_API_PORT:-6443} API_HOST=${API_HOST:-127.0.0.1} -KUBELET_PORT=${KUBELET_PORT:-10250} KUBELET_HEALTHZ_PORT=${KUBELET_HEALTHZ_PORT:-10248} CTLRMGR_PORT=${CTLRMGR_PORT:-10252} PROXY_HOST=127.0.0.1 # kubectl only serves on localhost. @@ -179,6 +181,7 @@ function kubectl-with-retry() # wait-for-pods-with-label "app=foo" "nginx-0nginx-1" function wait-for-pods-with-label() { + local i for i in $(seq 1 10); do kubeout=`kubectl get po -l $1 --template '{{range.items}}{{.metadata.name}}{{end}}' --sort-by metadata.name "${kube_flags[@]}"` if [[ $kubeout = $2 ]]; then @@ -1322,7 +1325,7 @@ run_crd_tests() { kubectl "${kube_flags_with_token[@]}" create -f - << __EOF__ { "kind": "CustomResourceDefinition", - "apiVersion": "apiextensions.k8s.io/v1alpha1", + "apiVersion": "apiextensions.k8s.io/v1beta1", "metadata": { "name": "foos.company.com" }, @@ -1343,7 +1346,7 @@ __EOF__ kubectl "${kube_flags_with_token[@]}" create -f - << __EOF__ { "kind": "CustomResourceDefinition", - "apiVersion": "apiextensions.k8s.io/v1alpha1", + "apiVersion": "apiextensions.k8s.io/v1beta1", "metadata": { "name": "bars.company.com" }, @@ -1413,6 +1416,101 @@ __EOF__ kubectl delete thirdpartyresources/bar.company.com "${kube_flags[@]}" } +run_tpr_migration_tests() { + local i tries + create_and_use_new_namespace + + # Create CRD first. This is sort of backwards so we can create a marker below. + kubectl "${kube_flags_with_token[@]}" create -f - << __EOF__ +{ + "kind": "CustomResourceDefinition", + "apiVersion": "apiextensions.k8s.io/v1beta1", + "metadata": { + "name": "foos.company.crd" + }, + "spec": { + "group": "company.crd", + "version": "v1", + "names": { + "plural": "foos", + "kind": "Foo" + } + } +} +__EOF__ + # Wait for API to become available. + tries=0 + until kubectl "${kube_flags[@]}" get foos.company.crd || [ $tries -gt 10 ]; do + tries=$((tries+1)) + sleep ${tries} + done + kube::test::get_object_assert foos.company.crd '{{len .items}}' '0' + + # Create a marker that only exists in CRD so we know when CRD is active vs. TPR. + kubectl "${kube_flags[@]}" create -f - << __EOF__ +{ + "kind": "Foo", + "apiVersion": "company.crd/v1", + "metadata": { + "name": "crd-marker" + }, + "testValue": "only exists in CRD" +} +__EOF__ + kube::test::get_object_assert foos.company.crd '{{len .items}}' '1' + + # Now create a TPR that sits in front of the CRD and hides it. + kubectl "${kube_flags[@]}" create -f - << __EOF__ +{ + "kind": "ThirdPartyResource", + "apiVersion": "extensions/v1beta1", + "metadata": { + "name": "foo.company.crd" + }, + "versions": [ + { + "name": "v1" + } + ] +} +__EOF__ + # The marker should disappear. + kube::test::wait_object_assert foos.company.crd '{{len .items}}' '0' + + # Add some items to the TPR. + for i in {1..10}; do + kubectl "${kube_flags[@]}" create -f - << __EOF__ +{ + "kind": "Foo", + "apiVersion": "company.crd/v1", + "metadata": { + "name": "tpr-${i}" + }, + "testValue": "migrate-${i}" +} +__EOF__ + done + kube::test::get_object_assert foos.company.crd '{{len .items}}' '10' + + # Delete the TPR and wait for the CRD to take over. + kubectl "${kube_flags[@]}" delete thirdpartyresource/foo.company.crd + tries=0 + until kubectl "${kube_flags[@]}" get foos.company.crd/crd-marker || [ $tries -gt 10 ]; do + tries=$((tries+1)) + sleep ${tries} + done + kube::test::get_object_assert foos.company.crd/crd-marker '{{.testValue}}' 'only exists in CRD' + + # Check if the TPR items were migrated to CRD. + kube::test::get_object_assert foos.company.crd '{{len .items}}' '11' + for i in {1..10}; do + kube::test::get_object_assert foos.company.crd/tpr-${i} '{{.testValue}}' "migrate-${i}" + done + + # teardown + kubectl delete customresourcedefinitions/foos.company.crd "${kube_flags_with_token[@]}" +} + kube::util::non_native_resources() { local times @@ -2951,12 +3049,12 @@ runTests() { kube::log::status "Checking kubectl version" kubectl version - i=0 + ns_num=0 create_and_use_new_namespace() { - i=$(($i+1)) - kube::log::status "Creating namespace namespace${i}" - kubectl create namespace "namespace${i}" - kubectl config set-context "${CONTEXT}" --namespace="namespace${i}" + ns_num=$(($ns_num+1)) + kube::log::status "Creating namespace namespace${ns_num}" + kubectl create namespace "namespace${ns_num}" + kubectl config set-context "${CONTEXT}" --namespace="namespace${ns_num}" } kube_flags=( @@ -3125,6 +3223,9 @@ runTests() { kube::test::get_object_assert clusterrole/resourcename-reader "{{range.rules}}{{range.resources}}{{.}}:{{end}}{{end}}" 'pods:' kube::test::get_object_assert clusterrole/resourcename-reader "{{range.rules}}{{range.apiGroups}}{{.}}:{{end}}{{end}}" ':' kube::test::get_object_assert clusterrole/resourcename-reader "{{range.rules}}{{range.resourceNames}}{{.}}:{{end}}{{end}}" 'foo:' + kubectl create "${kube_flags[@]}" clusterrole url-reader --verb=get --non-resource-url=/logs/* --non-resource-url=/healthz/* + kube::test::get_object_assert clusterrole/url-reader "{{range.rules}}{{range.verbs}}{{.}}:{{end}}{{end}}" 'get:' + kube::test::get_object_assert clusterrole/url-reader "{{range.rules}}{{range.nonResourceURLs}}{{.}}:{{end}}{{end}}" '/logs/\*:/healthz/\*:' # test `kubectl create rolebinding/clusterrolebinding` # test `kubectl set subject rolebinding/clusterrolebinding` @@ -3287,6 +3388,9 @@ runTests() { if kube::test::if_supports_resource "${thirdpartyresources}" ; then run_tpr_tests + if kube::test::if_supports_resource "${customresourcedefinitions}" ; then + run_tpr_migration_tests + fi fi ################# diff --git a/hack/make-rules/test-cmd.sh b/hack/make-rules/test-cmd.sh index 09f8a3abc346b..9728367e00ec4 100755 --- a/hack/make-rules/test-cmd.sh +++ b/hack/make-rules/test-cmd.sh @@ -40,15 +40,13 @@ function run_kube_apiserver() { AUTHORIZATION_MODE="RBAC,AlwaysAllow" "${KUBE_OUTPUT_HOSTBIN}/kube-apiserver" \ - --address="127.0.0.1" \ - --public-address-override="127.0.0.1" \ - --port="${API_PORT}" \ + --insecure-bind-address="127.0.0.1" \ + --bind-address="127.0.0.1" \ + --insecure-port="${API_PORT}" \ --authorization-mode="${AUTHORIZATION_MODE}" \ --secure-port="${SECURE_API_PORT}" \ --admission-control="${ADMISSION_CONTROL}" \ --etcd-servers="http://${ETCD_HOST}:${ETCD_PORT}" \ - --public-address-override="127.0.0.1" \ - --kubelet-port=${KUBELET_PORT} \ --runtime-config=api/v1 \ --storage-media-type="${KUBE_TEST_API_STORAGE_TYPE-}" \ --cert-dir="${TMPDIR:-/tmp/}" \ diff --git a/hack/make-rules/test.sh b/hack/make-rules/test.sh index d577645fd0b24..fddcc3ec56ae9 100755 --- a/hack/make-rules/test.sh +++ b/hack/make-rules/test.sh @@ -27,6 +27,10 @@ kube::golang::setup_env KUBE_CACHE_MUTATION_DETECTOR="${KUBE_CACHE_MUTATION_DETECTOR:-true}" export KUBE_CACHE_MUTATION_DETECTOR +# panic the server on watch decode errors since they are considered coder mistakes +KUBE_PANIC_WATCH_DECODE_ERROR="${KUBE_PANIC_WATCH_DECODE_ERROR:-true}" +export KUBE_PANIC_WATCH_DECODE_ERROR + # Handle case where OS has sha#sum commands, instead of shasum. if which shasum >/dev/null 2>&1; then SHA1SUM="shasum -a1" diff --git a/hack/test-update-storage-objects.sh b/hack/test-update-storage-objects.sh index 3429e8da6a85c..147ab13957445 100755 --- a/hack/test-update-storage-objects.sh +++ b/hack/test-update-storage-objects.sh @@ -29,8 +29,8 @@ KUBE_OLD_API_VERSION=${KUBE_OLD_API_VERSION:-"v1"} # The new api version KUBE_NEW_API_VERSION=${KUBE_NEW_API_VERSION:-"v1"} -KUBE_OLD_STORAGE_VERSIONS=${KUBE_OLD_STORAGE_VERSIONs:-""} -KUBE_NEW_STORAGE_VERSIONS=${KUBE_NEW_STORAGE_VERSIONs:-""} +KUBE_OLD_STORAGE_VERSIONS=${KUBE_OLD_STORAGE_VERSIONS:-""} +KUBE_NEW_STORAGE_VERSIONS=${KUBE_NEW_STORAGE_VERSIONS:-""} STORAGE_BACKEND_ETCD2="etcd2" STORAGE_BACKEND_ETCD3="etcd3" @@ -107,17 +107,15 @@ echo "${ETCD_VERSION}/${STORAGE_BACKEND_ETCD2}" > "${ETCD_DIR}/version.txt" ### BEGIN TEST DEFINITION CUSTOMIZATION ### -# After removing HPA in v1beta1 there is basically no resource which has -# two versions. In the future we may want to extend it. # source_file,resource,namespace,name,old_version,new_version tests=( -test/fixtures/doc-yaml/user-guide/pod.yaml,pods,default,nginx,v1,v1 +examples/persistent-volume-provisioning/rbd/rbd-storage-class.yaml,storageclasses,,slow,v1beta1,v1 ) -KUBE_OLD_API_VERSION="v1,extensions/v1beta1" -KUBE_NEW_API_VERSION="v1,extensions/v1beta1" -KUBE_OLD_STORAGE_VERSIONS="v1" -KUBE_NEW_STORAGE_VERSIONS="v1" +KUBE_OLD_API_VERSION="storage.k8s.io/v1beta1,extensions/v1beta1" +KUBE_NEW_API_VERSION="storage.k8s.io/v1,extensions/v1beta1" +KUBE_OLD_STORAGE_VERSIONS="storage.k8s.io/v1beta1" +KUBE_NEW_STORAGE_VERSIONS="storage.k8s.io/v1" ### END TEST DEFINITION CUSTOMIZATION ### @@ -126,8 +124,8 @@ KUBE_NEW_STORAGE_VERSIONS="v1" # but KUBE_OLD_API_VERSION is the latest (storage) version. # Additionally use KUBE_STORAGE_MEDIA_TYPE_JSON for storage encoding. ####################################################### -KUBE_API_VERSIONS="${KUBE_OLD_API_VERSION},${KUBE_NEW_API_VERSION}" -RUNTIME_CONFIG="api/all=false,api/${KUBE_OLD_API_VERSION}=true,api/${KUBE_NEW_API_VERSION}=true" +KUBE_API_VERSIONS="v1,${KUBE_OLD_API_VERSION},${KUBE_NEW_API_VERSION}" +RUNTIME_CONFIG="api/all=false,api/v1=true,${KUBE_OLD_API_VERSION}=true,${KUBE_NEW_API_VERSION}=true" startApiServer ${STORAGE_BACKEND_ETCD2} ${KUBE_OLD_STORAGE_VERSIONS} ${KUBE_STORAGE_MEDIA_TYPE_JSON} @@ -145,15 +143,18 @@ for test in ${tests[@]}; do name=${test_data[3]} old_storage_version=${test_data[4]} - kube::log::status "Verifying ${resource}/${namespace}/${name} has storage version ${old_storage_version} in etcd" - curl -s http://${ETCD_HOST}:${ETCD_PORT}/v2/keys/${ETCD_PREFIX}/${resource}/${namespace}/${name} | grep ${old_storage_version} + if [ -n "${namespace}" ]; then + namespace="${namespace}/" + fi + kube::log::status "Verifying ${resource}/${namespace}${name} has storage version ${old_storage_version} in etcd" + curl -s http://${ETCD_HOST}:${ETCD_PORT}/v2/keys/${ETCD_PREFIX}/${resource}/${namespace}${name} | grep ${old_storage_version} done killApiServer ####################################################### -# Step 2: Perform etcd2 -> etcd migration. +# Step 2: Perform etcd2 -> etcd3 migration. # We always perform offline migration, so we need to stop etcd. ####################################################### @@ -175,8 +176,8 @@ kube::etcd::start # Still use KUBE_STORAGE_MEDIA_TYPE_JSON for storage encoding. ####################################################### -KUBE_API_VERSIONS="${KUBE_NEW_API_VERSION},${KUBE_OLD_API_VERSION}" -RUNTIME_CONFIG="api/all=false,api/${KUBE_OLD_API_VERSION}=true,api/${KUBE_NEW_API_VERSION}=true" +KUBE_API_VERSIONS="v1,${KUBE_NEW_API_VERSION},${KUBE_OLD_API_VERSION}" +RUNTIME_CONFIG="api/all=false,api/v1=true,${KUBE_OLD_API_VERSION}=true,${KUBE_NEW_API_VERSION}=true" startApiServer ${STORAGE_BACKEND_ETCD3} ${KUBE_NEW_STORAGE_VERSIONS} ${KUBE_STORAGE_MEDIA_TYPE_JSON} # Update etcd objects, so that will now be stored in the new api version. @@ -191,8 +192,11 @@ for test in ${tests[@]}; do name=${test_data[3]} new_storage_version=${test_data[5]} - kube::log::status "Verifying ${resource}/${namespace}/${name} has updated storage version ${new_storage_version} in etcd" - ETCDCTL_API=3 ${ETCDCTL} --endpoints="${ETCD_HOST}:${ETCD_PORT}" get "/${ETCD_PREFIX}/${resource}/${namespace}/${name}" | grep ${new_storage_version} + if [ -n "${namespace}" ]; then + namespace="${namespace}/" + fi + kube::log::status "Verifying ${resource}/${namespace}${name} has updated storage version ${new_storage_version} in etcd" + ETCDCTL_API=3 ${ETCDCTL} --endpoints="${ETCD_HOST}:${ETCD_PORT}" get "/${ETCD_PREFIX}/${resource}/${namespace}${name}" | grep ${new_storage_version} done killApiServer @@ -203,8 +207,8 @@ killApiServer # However, change storage encoding to KUBE_STORAGE_MEDIA_TYPE_PROTOBUF. ####################################################### -KUBE_API_VERSIONS="${KUBE_NEW_API_VERSION}" -RUNTIME_CONFIG="api/all=false,api/${KUBE_NEW_API_VERSION}=true" +KUBE_API_VERSIONS="v1,${KUBE_NEW_API_VERSION}" +RUNTIME_CONFIG="api/all=false,api/v1=true,${KUBE_NEW_API_VERSION}=true" # This seems to reduce flakiness. sleep 1 @@ -215,10 +219,18 @@ for test in ${tests[@]}; do resource=${test_data[1]} namespace=${test_data[2]} name=${test_data[3]} + namespace_flag="" # Verify that the server is able to read the object. - kube::log::status "Verifying we can retrieve ${resource}/${namespace}/${name} via kubectl" - ${KUBECTL} get --namespace=${namespace} ${resource}/${name} + if [ -n "${namespace}" ]; then + namespace_flag="--namespace=${namespace}" + namespace="${namespace}/" + fi + kube::log::status "Verifying we can retrieve ${resource}/${namespace}${name} via kubectl" + # We have to remove the cached discovery information about the old version; otherwise, + # the 'kubectl get' will use that and fail to find the resource. + rm -rf ${HOME}/.kube/cache/discovery/localhost_8080/${KUBE_OLD_STORAGE_VERSIONS} + ${KUBECTL} get ${namespace_flag} ${resource}/${name} done killApiServer diff --git a/hack/update-swagger-spec.sh b/hack/update-swagger-spec.sh index 213e138828d74..ed45f2c15549e 100755 --- a/hack/update-swagger-spec.sh +++ b/hack/update-swagger-spec.sh @@ -58,7 +58,9 @@ API_HOST=${API_HOST:-127.0.0.1} kube::etcd::start + # Start kube-apiserver, with alpha api versions on so we can harvest their swagger docs +# Set --runtime-config to all versions in KUBE_AVAILABLE_GROUP_VERSIONS to enable alpha features. kube::log::status "Starting kube-apiserver" "${KUBE_OUTPUT_HOSTBIN}/kube-apiserver" \ --insecure-bind-address="${API_HOST}" \ @@ -67,8 +69,7 @@ kube::log::status "Starting kube-apiserver" --etcd-servers="http://${ETCD_HOST}:${ETCD_PORT}" \ --advertise-address="10.10.10.10" \ --cert-dir="${TMP_DIR}/certs" \ - --runtime-config="batch/v2alpha1" \ - --runtime-config="autoscaling/v2alpha1" \ + --runtime-config=$(echo "${KUBE_AVAILABLE_GROUP_VERSIONS}" | sed -E 's|[[:blank:]]+|,|g') \ --service-cluster-ip-range="10.0.0.0/24" >/tmp/swagger-api-server.log 2>&1 & APISERVER_PID=$! diff --git a/hack/verify-flags/exceptions.txt b/hack/verify-flags/exceptions.txt index 6f6d6d241a6a8..214007fdeb728 100644 --- a/hack/verify-flags/exceptions.txt +++ b/hack/verify-flags/exceptions.txt @@ -163,6 +163,7 @@ test/e2e/common/projected.go: Command: []string{"/mt", "--break_on_expected_co test/e2e/common/secrets.go: Command: []string{"/mt", "--break_on_expected_content=false", "--retry_time=120", "--file_content_in_loop=/etc/secret-volumes/create/data-1"}, test/e2e/common/secrets.go: Command: []string{"/mt", "--break_on_expected_content=false", "--retry_time=120", "--file_content_in_loop=/etc/secret-volumes/delete/data-1"}, test/e2e/common/secrets.go: Command: []string{"/mt", "--break_on_expected_content=false", "--retry_time=120", "--file_content_in_loop=/etc/secret-volumes/update/data-3"}, +test/e2e/no-snat.go: node_ip := v1.EnvVar{ test/e2e_node/container_manager_test.go: return fmt.Errorf("expected pid %d's oom_score_adj to be %d; found %d", pid, expectedOOMScoreAdj, oomScore) test/e2e_node/container_manager_test.go: return fmt.Errorf("expected pid %d's oom_score_adj to be < %d; found %d", pid, expectedMaxOOMScoreAdj, oomScore) test/e2e_node/container_manager_test.go: return fmt.Errorf("expected pid %d's oom_score_adj to be >= %d; found %d", pid, expectedMinOOMScoreAdj, oomScore) diff --git a/hack/verify-flags/known-flags.txt b/hack/verify-flags/known-flags.txt index cf0b1e31268f8..4ed806724389b 100644 --- a/hack/verify-flags/known-flags.txt +++ b/hack/verify-flags/known-flags.txt @@ -46,6 +46,8 @@ audit-log-maxage audit-log-maxbackup audit-log-maxsize audit-log-path +audit-webhook-config-file +audit-webhook-mode authentication-kubeconfig authentication-token-webhook authentication-token-webhook-cache-ttl @@ -190,6 +192,7 @@ dump-logs-on-failure duration-sec e2e-output-dir e2e-verify-service-account +enable-aggregator-routing enable-controller-attach-detach enable-custom-metrics enable-debugging-handlers @@ -215,6 +218,7 @@ etcd-mutation-timeout etcd-persistent-storage etcd-prefix etcd-pv-capacity +etcd-pv-storage-class etcd-quorum-read etcd-server etcd-servers @@ -242,6 +246,7 @@ experimental-allowed-unsafe-sysctls experimental-bootstrap-kubeconfig experimental-bootstrap-token-auth experimental-check-node-capabilities-before-mount +experimental-cluster-signing-duration experimental-cri experimental-dockershim experimental-dockershim-root-directory @@ -290,6 +295,7 @@ garbage-collector-enabled gather-logs-sizes gather-metrics-at-teardown gather-resource-usage +gather-suite-metrics-at-teardown gce-multizone gce-project gce-service-account @@ -508,6 +514,7 @@ node-sync-period no-headers no-headers non-masquerade-cidr +non-resource-url no-suggestions no-suggestions num-nodes diff --git a/hack/verify-generated-protobuf.sh b/hack/verify-generated-protobuf.sh index 1e607a4d88345..dd849f5a9b40d 100755 --- a/hack/verify-generated-protobuf.sh +++ b/hack/verify-generated-protobuf.sh @@ -23,7 +23,7 @@ source "${KUBE_ROOT}/hack/lib/init.sh" kube::golang::setup_env -APIROOTS=${APIROOTS:-pkg/api pkg/apis pkg/runtime pkg/util/intstr pkg/watch staging/src/k8s.io/apimachinery/pkg/api staging/src/k8s.io/apimachinery/pkg/apis staging/src/k8s.io/apiserver/pkg staging/src/k8s.io/client-go/pkg/api staging/src/k8s.io/client-go/pkg/apis} +APIROOTS=${APIROOTS:-pkg/api pkg/apis pkg/runtime pkg/util/intstr pkg/watch staging/src/k8s.io/apimachinery/pkg/api staging/src/k8s.io/apimachinery/pkg/apis staging/src/k8s.io/apiserver/pkg staging/src/k8s.io/client-go/pkg/api staging/src/k8s.io/client-go/pkg/apis staging/src/k8s.io/metrics/pkg/apis} _tmp="${KUBE_ROOT}/_tmp" cleanup() { diff --git a/hack/verify-staging-imports.sh b/hack/verify-staging-imports.sh index 036ba821f0ab3..abff35db45a30 100755 --- a/hack/verify-staging-imports.sh +++ b/hack/verify-staging-imports.sh @@ -37,7 +37,8 @@ function print_forbidden_imports () { go list -f $'{{with $package := .ImportPath}}{{range $.Imports}}{{$package}} imports {{.}}\n{{end}}{{end}}' ./vendor/k8s.io/${PACKAGE}/... | sed 's|^k8s.io/kubernetes/vendor/||;s| k8s.io/kubernetes/vendor/| |' | grep -v " k8s.io/${PACKAGE}" | - grep -e "imports \(${RE}\)" + grep " k8s.io/" | + grep -v -e "imports \(${RE}\)" ) if [ -n "${FORBIDDEN}" ]; then echo "${PACKAGE} has a forbidden dependency:" @@ -50,7 +51,8 @@ function print_forbidden_imports () { go list -f $'{{with $package := .ImportPath}}{{range $.TestImports}}{{$package}} imports {{.}}\n{{end}}{{end}}' ./vendor/k8s.io/${PACKAGE}/... | sed 's|^k8s.io/kubernetes/vendor/||;s| k8s.io/kubernetes/vendor/| |' | grep -v " k8s.io/${PACKAGE}" | - grep -e "imports \(${RE}\)" + grep " k8s.io/" | + grep -v -e "imports \(${RE}\)" ) if [ -n "${TEST_FORBIDDEN}" ]; then echo "${PACKAGE} has a forbidden dependency in test code:" @@ -63,11 +65,11 @@ function print_forbidden_imports () { } RC=0 -print_forbidden_imports apimachinery k8s.io/ || RC=1 -print_forbidden_imports apiserver k8s.io/kubernetes k8s.io/sample-apiserver k8s.io/kube-aggregator || RC=1 -print_forbidden_imports client-go k8s.io/kubernetes k8s.io/apiserver k8s.io/sample-apiserver k8s.io/kube-aggregator || RC=1 -print_forbidden_imports kube-aggregator k8s.io/kubernetes k8s.io/sample-apiserver || RC=1 -print_forbidden_imports sample-apiserver k8s.io/kubernetes k8s.io/kube-aggregator || RC=1 +print_forbidden_imports apimachinery || RC=1 +print_forbidden_imports client-go k8s.io/apimachinery || RC=1 +print_forbidden_imports apiserver k8s.io/apimachinery k8s.io/client-go || RC=1 +print_forbidden_imports kube-aggregator k8s.io/apimachinery k8s.io/client-go k8s.io/apiserver || RC=1 +print_forbidden_imports sample-apiserver k8s.io/apimachinery k8s.io/client-go k8s.io/apiserver || RC=1 if [ ${RC} != 0 ]; then exit ${RC} fi @@ -85,4 +87,4 @@ for EXAMPLE in vendor/k8s.io/client-go/examples/{in-cluster,out-of-cluster,third fi done -exit 0 \ No newline at end of file +exit 0 diff --git a/pkg/BUILD b/pkg/BUILD index 33fcac5034d78..1d03162813319 100644 --- a/pkg/BUILD +++ b/pkg/BUILD @@ -17,6 +17,7 @@ filegroup( "//pkg/apimachinery/tests:all-srcs", "//pkg/apis/abac:all-srcs", "//pkg/apis/admission:all-srcs", + "//pkg/apis/admissionregistration:all-srcs", "//pkg/apis/apps:all-srcs", "//pkg/apis/authentication:all-srcs", "//pkg/apis/authorization:all-srcs", @@ -27,6 +28,7 @@ filegroup( "//pkg/apis/extensions:all-srcs", "//pkg/apis/imagepolicy:all-srcs", "//pkg/apis/meta/v1:all-srcs", + "//pkg/apis/networking:all-srcs", "//pkg/apis/policy:all-srcs", "//pkg/apis/rbac:all-srcs", "//pkg/apis/settings:all-srcs", @@ -43,6 +45,8 @@ filegroup( "//pkg/client/informers/informers_generated/externalversions:all-srcs", "//pkg/client/informers/informers_generated/internalversion:all-srcs", "//pkg/client/leaderelection:all-srcs", + "//pkg/client/listers/admissionregistration/internalversion:all-srcs", + "//pkg/client/listers/admissionregistration/v1alpha1:all-srcs", "//pkg/client/listers/apps/internalversion:all-srcs", "//pkg/client/listers/apps/v1beta1:all-srcs", "//pkg/client/listers/authentication/internalversion:all-srcs", @@ -65,6 +69,8 @@ filegroup( "//pkg/client/listers/extensions/v1beta1:all-srcs", "//pkg/client/listers/imagepolicy/internalversion:all-srcs", "//pkg/client/listers/imagepolicy/v1alpha1:all-srcs", + "//pkg/client/listers/networking/internalversion:all-srcs", + "//pkg/client/listers/networking/v1:all-srcs", "//pkg/client/listers/policy/internalversion:all-srcs", "//pkg/client/listers/policy/v1alpha1:all-srcs", "//pkg/client/listers/policy/v1beta1:all-srcs", diff --git a/pkg/api/BUILD b/pkg/api/BUILD index c4ca2b6339868..ee99308203123 100644 --- a/pkg/api/BUILD +++ b/pkg/api/BUILD @@ -107,6 +107,7 @@ filegroup( "//pkg/api/helper:all-srcs", "//pkg/api/install:all-srcs", "//pkg/api/meta:all-srcs", + "//pkg/api/persistentvolume:all-srcs", "//pkg/api/pod:all-srcs", "//pkg/api/ref:all-srcs", "//pkg/api/resource:all-srcs", diff --git a/pkg/api/defaulting_test.go b/pkg/api/defaulting_test.go index 8572e8dda57f1..6a11771d2c33d 100644 --- a/pkg/api/defaulting_test.go +++ b/pkg/api/defaulting_test.go @@ -103,24 +103,30 @@ func TestDefaulting(t *testing.T) { // This object contains only int fields which currently breaks the defaulting test because // it's pretty stupid. Once we add non integer fields, we should uncomment this. // {Group: "kubeadm.k8s.io", Version: "v1alpha1", Kind: "NodeConfiguration"}: {}, - {Group: "extensions", Version: "v1beta1", Kind: "DaemonSet"}: {}, - {Group: "extensions", Version: "v1beta1", Kind: "DaemonSetList"}: {}, - {Group: "extensions", Version: "v1beta1", Kind: "Deployment"}: {}, - {Group: "extensions", Version: "v1beta1", Kind: "DeploymentList"}: {}, - {Group: "apps", Version: "v1beta1", Kind: "Deployment"}: {}, - {Group: "apps", Version: "v1beta1", Kind: "DeploymentList"}: {}, - {Group: "extensions", Version: "v1beta1", Kind: "ReplicaSet"}: {}, - {Group: "extensions", Version: "v1beta1", Kind: "ReplicaSetList"}: {}, - {Group: "rbac.authorization.k8s.io", Version: "v1alpha1", Kind: "ClusterRoleBinding"}: {}, - {Group: "rbac.authorization.k8s.io", Version: "v1alpha1", Kind: "ClusterRoleBindingList"}: {}, - {Group: "rbac.authorization.k8s.io", Version: "v1alpha1", Kind: "RoleBinding"}: {}, - {Group: "rbac.authorization.k8s.io", Version: "v1alpha1", Kind: "RoleBindingList"}: {}, - {Group: "rbac.authorization.k8s.io", Version: "v1beta1", Kind: "ClusterRoleBinding"}: {}, - {Group: "rbac.authorization.k8s.io", Version: "v1beta1", Kind: "ClusterRoleBindingList"}: {}, - {Group: "rbac.authorization.k8s.io", Version: "v1beta1", Kind: "RoleBinding"}: {}, - {Group: "rbac.authorization.k8s.io", Version: "v1beta1", Kind: "RoleBindingList"}: {}, - {Group: "settings.k8s.io", Version: "v1alpha1", Kind: "PodPreset"}: {}, - {Group: "settings.k8s.io", Version: "v1alpha1", Kind: "PodPresetList"}: {}, + {Group: "extensions", Version: "v1beta1", Kind: "DaemonSet"}: {}, + {Group: "extensions", Version: "v1beta1", Kind: "DaemonSetList"}: {}, + {Group: "extensions", Version: "v1beta1", Kind: "Deployment"}: {}, + {Group: "extensions", Version: "v1beta1", Kind: "DeploymentList"}: {}, + {Group: "apps", Version: "v1beta1", Kind: "Deployment"}: {}, + {Group: "apps", Version: "v1beta1", Kind: "DeploymentList"}: {}, + {Group: "extensions", Version: "v1beta1", Kind: "ReplicaSet"}: {}, + {Group: "extensions", Version: "v1beta1", Kind: "ReplicaSetList"}: {}, + {Group: "rbac.authorization.k8s.io", Version: "v1alpha1", Kind: "ClusterRoleBinding"}: {}, + {Group: "rbac.authorization.k8s.io", Version: "v1alpha1", Kind: "ClusterRoleBindingList"}: {}, + {Group: "rbac.authorization.k8s.io", Version: "v1alpha1", Kind: "RoleBinding"}: {}, + {Group: "rbac.authorization.k8s.io", Version: "v1alpha1", Kind: "RoleBindingList"}: {}, + {Group: "rbac.authorization.k8s.io", Version: "v1beta1", Kind: "ClusterRoleBinding"}: {}, + {Group: "rbac.authorization.k8s.io", Version: "v1beta1", Kind: "ClusterRoleBindingList"}: {}, + {Group: "rbac.authorization.k8s.io", Version: "v1beta1", Kind: "RoleBinding"}: {}, + {Group: "rbac.authorization.k8s.io", Version: "v1beta1", Kind: "RoleBindingList"}: {}, + {Group: "settings.k8s.io", Version: "v1alpha1", Kind: "PodPreset"}: {}, + {Group: "settings.k8s.io", Version: "v1alpha1", Kind: "PodPresetList"}: {}, + {Group: "admissionregistration.k8s.io", Version: "v1alpha1", Kind: "InitializerConfiguration"}: {}, + {Group: "admissionregistration.k8s.io", Version: "v1alpha1", Kind: "InitializerConfigurationList"}: {}, + {Group: "admissionregistration.k8s.io", Version: "v1alpha1", Kind: "ExternalAdmissionHookConfiguration"}: {}, + {Group: "admissionregistration.k8s.io", Version: "v1alpha1", Kind: "ExternalAdmissionHookConfigurationList"}: {}, + {Group: "networking.k8s.io", Version: "v1", Kind: "NetworkPolicy"}: {}, + {Group: "networking.k8s.io", Version: "v1", Kind: "NetworkPolicyList"}: {}, } f := fuzz.New().NilChance(.5).NumElements(1, 1).RandSource(rand.NewSource(1)) diff --git a/pkg/api/helper/helpers.go b/pkg/api/helper/helpers.go index 891c012d9948a..95b8f8aa5ae2f 100644 --- a/pkg/api/helper/helpers.go +++ b/pkg/api/helper/helpers.go @@ -590,6 +590,10 @@ func GetStorageNodeAffinityFromAnnotation(annotations map[string]string) (*api.N // Converts NodeAffinity type to Alpha annotation for use in PersistentVolumes // TODO: update when storage node affinity graduates to beta func StorageNodeAffinityToAlphaAnnotation(annotations map[string]string, affinity *api.NodeAffinity) error { + if affinity == nil { + return nil + } + json, err := json.Marshal(*affinity) if err != nil { return err diff --git a/pkg/api/persistentvolume/BUILD b/pkg/api/persistentvolume/BUILD new file mode 100644 index 0000000000000..1699f870c30dd --- /dev/null +++ b/pkg/api/persistentvolume/BUILD @@ -0,0 +1,41 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_library( + name = "go_default_library", + srcs = ["util.go"], + tags = ["automanaged"], + deps = ["//pkg/api:go_default_library"], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) + +go_test( + name = "go_default_test", + srcs = ["util_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation/field:go_default_library", + ], +) diff --git a/pkg/api/persistentvolume/OWNERS b/pkg/api/persistentvolume/OWNERS new file mode 100755 index 0000000000000..b74bd2bf49a9a --- /dev/null +++ b/pkg/api/persistentvolume/OWNERS @@ -0,0 +1,4 @@ +reviewers: +- smarterclayton +- kargakis +- david-mcmahon diff --git a/pkg/api/persistentvolume/util.go b/pkg/api/persistentvolume/util.go new file mode 100644 index 0000000000000..b33077d68da8d --- /dev/null +++ b/pkg/api/persistentvolume/util.go @@ -0,0 +1,55 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package persistentvolume + +import ( + "k8s.io/kubernetes/pkg/api" +) + +// VisitPVSecretNames invokes the visitor function with the name of every secret +// referenced by the PV spec. If visitor returns false, visiting is short-circuited. +// Returns true if visiting completed, false if visiting was short-circuited. +func VisitPVSecretNames(pv *api.PersistentVolume, visitor func(string) bool) bool { + source := &pv.Spec.PersistentVolumeSource + switch { + case source.AzureFile != nil: + if len(source.AzureFile.SecretName) > 0 && !visitor(source.AzureFile.SecretName) { + return false + } + case source.CephFS != nil: + if source.CephFS.SecretRef != nil && !visitor(source.CephFS.SecretRef.Name) { + return false + } + case source.FlexVolume != nil: + if source.FlexVolume.SecretRef != nil && !visitor(source.FlexVolume.SecretRef.Name) { + return false + } + case source.RBD != nil: + if source.RBD.SecretRef != nil && !visitor(source.RBD.SecretRef.Name) { + return false + } + case source.ScaleIO != nil: + if source.ScaleIO.SecretRef != nil && !visitor(source.ScaleIO.SecretRef.Name) { + return false + } + case source.ISCSI != nil: + if source.ISCSI.SecretRef != nil && !visitor(source.ISCSI.SecretRef.Name) { + return false + } + } + return true +} diff --git a/pkg/api/persistentvolume/util_test.go b/pkg/api/persistentvolume/util_test.go new file mode 100644 index 0000000000000..f8353050de559 --- /dev/null +++ b/pkg/api/persistentvolume/util_test.go @@ -0,0 +1,133 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package persistentvolume + +import ( + "reflect" + "testing" + + "strings" + + "k8s.io/apimachinery/pkg/util/sets" + "k8s.io/apimachinery/pkg/util/validation/field" + "k8s.io/kubernetes/pkg/api" +) + +func TestPVSecrets(t *testing.T) { + // Stub containing all possible secret references in a PV. + // The names of the referenced secrets match struct paths detected by reflection. + pvs := []*api.PersistentVolume{ + {Spec: api.PersistentVolumeSpec{PersistentVolumeSource: api.PersistentVolumeSource{ + AzureFile: &api.AzureFileVolumeSource{ + SecretName: "Spec.PersistentVolumeSource.AzureFile.SecretName"}}}}, + {Spec: api.PersistentVolumeSpec{PersistentVolumeSource: api.PersistentVolumeSource{ + CephFS: &api.CephFSVolumeSource{ + SecretRef: &api.LocalObjectReference{ + Name: "Spec.PersistentVolumeSource.CephFS.SecretRef"}}}}}, + {Spec: api.PersistentVolumeSpec{PersistentVolumeSource: api.PersistentVolumeSource{ + FlexVolume: &api.FlexVolumeSource{ + SecretRef: &api.LocalObjectReference{ + Name: "Spec.PersistentVolumeSource.FlexVolume.SecretRef"}}}}}, + {Spec: api.PersistentVolumeSpec{PersistentVolumeSource: api.PersistentVolumeSource{ + RBD: &api.RBDVolumeSource{ + SecretRef: &api.LocalObjectReference{ + Name: "Spec.PersistentVolumeSource.RBD.SecretRef"}}}}}, + {Spec: api.PersistentVolumeSpec{PersistentVolumeSource: api.PersistentVolumeSource{ + ScaleIO: &api.ScaleIOVolumeSource{ + SecretRef: &api.LocalObjectReference{ + Name: "Spec.PersistentVolumeSource.ScaleIO.SecretRef"}}}}}, + {Spec: api.PersistentVolumeSpec{PersistentVolumeSource: api.PersistentVolumeSource{ + ISCSI: &api.ISCSIVolumeSource{ + SecretRef: &api.LocalObjectReference{ + Name: "Spec.PersistentVolumeSource.ISCSI.SecretRef"}}}}}, + } + extractedNames := sets.NewString() + for _, pv := range pvs { + VisitPVSecretNames(pv, func(name string) bool { + extractedNames.Insert(name) + return true + }) + } + + // excludedSecretPaths holds struct paths to fields with "secret" in the name that are not actually references to secret API objects + excludedSecretPaths := sets.NewString( + "Spec.PersistentVolumeSource.CephFS.SecretFile", + ) + // expectedSecretPaths holds struct paths to fields with "secret" in the name that are references to secret API objects. + // every path here should be represented as an example in the PV stub above, with the secret name set to the path. + expectedSecretPaths := sets.NewString( + "Spec.PersistentVolumeSource.AzureFile.SecretName", + "Spec.PersistentVolumeSource.CephFS.SecretRef", + "Spec.PersistentVolumeSource.FlexVolume.SecretRef", + "Spec.PersistentVolumeSource.RBD.SecretRef", + "Spec.PersistentVolumeSource.ScaleIO.SecretRef", + "Spec.PersistentVolumeSource.ISCSI.SecretRef", + ) + secretPaths := collectSecretPaths(t, nil, "", reflect.TypeOf(&api.PersistentVolume{})) + secretPaths = secretPaths.Difference(excludedSecretPaths) + if missingPaths := expectedSecretPaths.Difference(secretPaths); len(missingPaths) > 0 { + t.Logf("Missing expected secret paths:\n%s", strings.Join(missingPaths.List(), "\n")) + t.Error("Missing expected secret paths. Verify VisitPVSecretNames() is correctly finding the missing paths, then correct expectedSecretPaths") + } + if extraPaths := secretPaths.Difference(expectedSecretPaths); len(extraPaths) > 0 { + t.Logf("Extra secret paths:\n%s", strings.Join(extraPaths.List(), "\n")) + t.Error("Extra fields with 'secret' in the name found. Verify VisitPVSecretNames() is including these fields if appropriate, then correct expectedSecretPaths") + } + + if missingNames := expectedSecretPaths.Difference(extractedNames); len(missingNames) > 0 { + t.Logf("Missing expected secret names:\n%s", strings.Join(missingNames.List(), "\n")) + t.Error("Missing expected secret names. Verify the PV stub above includes these references, then verify VisitPVSecretNames() is correctly finding the missing names") + } + if extraNames := extractedNames.Difference(expectedSecretPaths); len(extraNames) > 0 { + t.Logf("Extra secret names:\n%s", strings.Join(extraNames.List(), "\n")) + t.Error("Extra secret names extracted. Verify VisitPVSecretNames() is correctly extracting secret names") + } +} + +// collectSecretPaths traverses the object, computing all the struct paths that lead to fields with "secret" in the name. +func collectSecretPaths(t *testing.T, path *field.Path, name string, tp reflect.Type) sets.String { + secretPaths := sets.NewString() + + if tp.Kind() == reflect.Ptr { + secretPaths.Insert(collectSecretPaths(t, path, name, tp.Elem()).List()...) + return secretPaths + } + + if strings.Contains(strings.ToLower(name), "secret") { + secretPaths.Insert(path.String()) + } + + switch tp.Kind() { + case reflect.Ptr: + secretPaths.Insert(collectSecretPaths(t, path, name, tp.Elem()).List()...) + case reflect.Struct: + for i := 0; i < tp.NumField(); i++ { + field := tp.Field(i) + secretPaths.Insert(collectSecretPaths(t, path.Child(field.Name), field.Name, field.Type).List()...) + } + case reflect.Interface: + t.Errorf("cannot find secret fields in interface{} field %s", path.String()) + case reflect.Map: + secretPaths.Insert(collectSecretPaths(t, path.Key("*"), "", tp.Elem()).List()...) + case reflect.Slice: + secretPaths.Insert(collectSecretPaths(t, path.Key("*"), "", tp.Elem()).List()...) + default: + // all primitive types + } + + return secretPaths +} diff --git a/pkg/api/testapi/BUILD b/pkg/api/testapi/BUILD index bb4ebdeda0419..48167f98db2da 100644 --- a/pkg/api/testapi/BUILD +++ b/pkg/api/testapi/BUILD @@ -17,6 +17,8 @@ go_library( "//federation/apis/federation/install:go_default_library", "//pkg/api:go_default_library", "//pkg/api/install:go_default_library", + "//pkg/apis/admissionregistration:go_default_library", + "//pkg/apis/admissionregistration/install:go_default_library", "//pkg/apis/apps:go_default_library", "//pkg/apis/apps/install:go_default_library", "//pkg/apis/authentication/install:go_default_library", @@ -33,6 +35,8 @@ go_library( "//pkg/apis/extensions/install:go_default_library", "//pkg/apis/imagepolicy:go_default_library", "//pkg/apis/imagepolicy/install:go_default_library", + "//pkg/apis/networking:go_default_library", + "//pkg/apis/networking/install:go_default_library", "//pkg/apis/policy:go_default_library", "//pkg/apis/policy/install:go_default_library", "//pkg/apis/rbac:go_default_library", diff --git a/pkg/api/testapi/testapi.go b/pkg/api/testapi/testapi.go index 65a429ab3036e..d36efa956707d 100644 --- a/pkg/api/testapi/testapi.go +++ b/pkg/api/testapi/testapi.go @@ -36,6 +36,7 @@ import ( "k8s.io/apimachinery/pkg/runtime/serializer/recognizer" "k8s.io/kubernetes/federation/apis/federation" "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/admissionregistration" "k8s.io/kubernetes/pkg/apis/apps" "k8s.io/kubernetes/pkg/apis/authorization" "k8s.io/kubernetes/pkg/apis/autoscaling" @@ -43,6 +44,7 @@ import ( "k8s.io/kubernetes/pkg/apis/certificates" "k8s.io/kubernetes/pkg/apis/extensions" "k8s.io/kubernetes/pkg/apis/imagepolicy" + "k8s.io/kubernetes/pkg/apis/networking" "k8s.io/kubernetes/pkg/apis/policy" "k8s.io/kubernetes/pkg/apis/rbac" "k8s.io/kubernetes/pkg/apis/settings" @@ -50,6 +52,7 @@ import ( _ "k8s.io/kubernetes/federation/apis/federation/install" _ "k8s.io/kubernetes/pkg/api/install" + _ "k8s.io/kubernetes/pkg/apis/admissionregistration/install" _ "k8s.io/kubernetes/pkg/apis/apps/install" _ "k8s.io/kubernetes/pkg/apis/authentication/install" _ "k8s.io/kubernetes/pkg/apis/authorization/install" @@ -59,6 +62,7 @@ import ( _ "k8s.io/kubernetes/pkg/apis/componentconfig/install" _ "k8s.io/kubernetes/pkg/apis/extensions/install" _ "k8s.io/kubernetes/pkg/apis/imagepolicy/install" + _ "k8s.io/kubernetes/pkg/apis/networking/install" _ "k8s.io/kubernetes/pkg/apis/policy/install" _ "k8s.io/kubernetes/pkg/apis/rbac/install" _ "k8s.io/kubernetes/pkg/apis/settings/install" @@ -80,6 +84,7 @@ var ( Settings TestGroup Storage TestGroup ImagePolicy TestGroup + Networking TestGroup serializer runtime.SerializerInfo storageSerializer runtime.SerializerInfo @@ -278,6 +283,24 @@ func init() { externalTypes: api.Scheme.KnownTypes(externalGroupVersion), } } + if _, ok := Groups[admissionregistration.GroupName]; !ok { + externalGroupVersion := schema.GroupVersion{Group: admissionregistration.GroupName, Version: api.Registry.GroupOrDie(admissionregistration.GroupName).GroupVersion.Version} + Groups[admissionregistration.GroupName] = TestGroup{ + externalGroupVersion: externalGroupVersion, + internalGroupVersion: admissionregistration.SchemeGroupVersion, + internalTypes: api.Scheme.KnownTypes(admissionregistration.SchemeGroupVersion), + externalTypes: api.Scheme.KnownTypes(externalGroupVersion), + } + } + if _, ok := Groups[networking.GroupName]; !ok { + externalGroupVersion := schema.GroupVersion{Group: networking.GroupName, Version: api.Registry.GroupOrDie(networking.GroupName).GroupVersion.Version} + Groups[networking.GroupName] = TestGroup{ + externalGroupVersion: externalGroupVersion, + internalGroupVersion: networking.SchemeGroupVersion, + internalTypes: api.Scheme.KnownTypes(networking.SchemeGroupVersion), + externalTypes: api.Scheme.KnownTypes(externalGroupVersion), + } + } Default = Groups[api.GroupName] Autoscaling = Groups[autoscaling.GroupName] @@ -292,6 +315,7 @@ func init() { Storage = Groups[storage.GroupName] ImagePolicy = Groups[imagepolicy.GroupName] Authorization = Groups[authorization.GroupName] + Networking = Groups[networking.GroupName] } func (g TestGroup) ContentConfig() (string, *schema.GroupVersion, runtime.Codec) { diff --git a/pkg/api/testing/BUILD b/pkg/api/testing/BUILD index 8bb555412a745..97e3cfb0a8e4a 100644 --- a/pkg/api/testing/BUILD +++ b/pkg/api/testing/BUILD @@ -20,6 +20,7 @@ go_library( "//pkg/api:go_default_library", "//pkg/api/testapi:go_default_library", "//pkg/api/v1:go_default_library", + "//pkg/apis/admissionregistration:go_default_library", "//pkg/apis/apps:go_default_library", "//pkg/apis/autoscaling:go_default_library", "//pkg/apis/batch:go_default_library", diff --git a/pkg/api/testing/fuzzer.go b/pkg/api/testing/fuzzer.go index ee9ca68723e8a..e3884e42e850e 100644 --- a/pkg/api/testing/fuzzer.go +++ b/pkg/api/testing/fuzzer.go @@ -36,6 +36,7 @@ import ( "k8s.io/kubernetes/pkg/api" "k8s.io/kubernetes/pkg/api/testapi" "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/pkg/apis/admissionregistration" "k8s.io/kubernetes/pkg/apis/apps" "k8s.io/kubernetes/pkg/apis/autoscaling" "k8s.io/kubernetes/pkg/apis/batch" @@ -738,6 +739,21 @@ func certificateFuncs(t apitesting.TestingCommon) []interface{} { } } +func admissionregistrationFuncs(t apitesting.TestingCommon) []interface{} { + return []interface{}{ + func(obj *admissionregistration.ExternalAdmissionHook, c fuzz.Continue) { + c.FuzzNoCustom(obj) // fuzz self without calling this function again + p := admissionregistration.FailurePolicyType("Fail") + obj.FailurePolicy = &p + }, + func(obj *admissionregistration.Initializer, c fuzz.Continue) { + c.FuzzNoCustom(obj) // fuzz self without calling this function again + p := admissionregistration.FailurePolicyType("Fail") + obj.FailurePolicy = &p + }, + } +} + func FuzzerFuncs(t apitesting.TestingCommon, codecs runtimeserializer.CodecFactory) []interface{} { return apitesting.MergeFuzzerFuncs(t, apitesting.GenericFuzzerFuncs(t, codecs), @@ -751,6 +767,7 @@ func FuzzerFuncs(t apitesting.TestingCommon, codecs runtimeserializer.CodecFacto kubeadmfuzzer.KubeadmFuzzerFuncs(t), policyFuncs(t), certificateFuncs(t), + admissionregistrationFuncs(t), ) } diff --git a/pkg/api/types.go b/pkg/api/types.go index b8897e17ef003..6d8943c36a0e4 100644 --- a/pkg/api/types.go +++ b/pkg/api/types.go @@ -601,6 +601,14 @@ type EmptyDirVolumeSource struct { // The default is "" which means to use the node's default medium. // +optional Medium StorageMedium + // Total amount of local storage required for this EmptyDir volume. + // The size limit is also applicable for memory medium. + // The maximum usage on memory medium EmptyDir would be the minimum value between + // the SizeLimit specified here and the sum of memory limits of all containers in a pod. + // The default is nil which means that the limit is undefined. + // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir + // +optional + SizeLimit resource.Quantity } // StorageMedium defines ways that storage can be allocated to a volume. @@ -3017,6 +3025,12 @@ const ( ResourceMemory ResourceName = "memory" // Volume size, in bytes (e,g. 5Gi = 5GiB = 5 * 1024 * 1024 * 1024) ResourceStorage ResourceName = "storage" + // Local Storage for overlay filesystem, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024) + // The resource name for ResourceStorageOverlay is alpha and it can change across releases. + ResourceStorageOverlay ResourceName = "storage.kubernetes.io/overlay" + // Local Storage for scratch space, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024) + // The resource name for ResourceStorageScratch is alpha and it can change across releases. + ResourceStorageScratch ResourceName = "storage.kubernetes.io/scratch" // NVIDIA GPU, in devices. Alpha, might change: although fractional and allowing values >1, only one whole device per node is assigned. ResourceNvidiaGPU ResourceName = "alpha.kubernetes.io/nvidia-gpu" // Number of Pods that may be running on this Node: see ResourcePods diff --git a/pkg/api/v1/generated.pb.go b/pkg/api/v1/generated.pb.go index a636ed2a8d834..8b5e36ad3b5d5 100644 --- a/pkg/api/v1/generated.pb.go +++ b/pkg/api/v1/generated.pb.go @@ -2571,6 +2571,14 @@ func (m *EmptyDirVolumeSource) MarshalTo(dAtA []byte) (int, error) { i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Medium))) i += copy(dAtA[i:], m.Medium) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.SizeLimit.Size())) + n31, err := m.SizeLimit.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n31 return i, nil } @@ -2597,11 +2605,11 @@ func (m *EndpointAddress) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.TargetRef.Size())) - n31, err := m.TargetRef.MarshalTo(dAtA[i:]) + n32, err := m.TargetRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n31 + i += n32 } dAtA[i] = 0x1a i++ @@ -2717,11 +2725,11 @@ func (m *Endpoints) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n32, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n33, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n32 + i += n33 if len(m.Subsets) > 0 { for _, msg := range m.Subsets { dAtA[i] = 0x12 @@ -2755,11 +2763,11 @@ func (m *EndpointsList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n33, err := m.ListMeta.MarshalTo(dAtA[i:]) + n34, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n33 + i += n34 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -2798,21 +2806,21 @@ func (m *EnvFromSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ConfigMapRef.Size())) - n34, err := m.ConfigMapRef.MarshalTo(dAtA[i:]) + n35, err := m.ConfigMapRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n34 + i += n35 } if m.SecretRef != nil { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) - n35, err := m.SecretRef.MarshalTo(dAtA[i:]) + n36, err := m.SecretRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n35 + i += n36 } return i, nil } @@ -2844,11 +2852,11 @@ func (m *EnvVar) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ValueFrom.Size())) - n36, err := m.ValueFrom.MarshalTo(dAtA[i:]) + n37, err := m.ValueFrom.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n36 + i += n37 } return i, nil } @@ -2872,41 +2880,41 @@ func (m *EnvVarSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.FieldRef.Size())) - n37, err := m.FieldRef.MarshalTo(dAtA[i:]) + n38, err := m.FieldRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n37 + i += n38 } if m.ResourceFieldRef != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ResourceFieldRef.Size())) - n38, err := m.ResourceFieldRef.MarshalTo(dAtA[i:]) + n39, err := m.ResourceFieldRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n38 + i += n39 } if m.ConfigMapKeyRef != nil { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ConfigMapKeyRef.Size())) - n39, err := m.ConfigMapKeyRef.MarshalTo(dAtA[i:]) + n40, err := m.ConfigMapKeyRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n39 + i += n40 } if m.SecretKeyRef != nil { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecretKeyRef.Size())) - n40, err := m.SecretKeyRef.MarshalTo(dAtA[i:]) + n41, err := m.SecretKeyRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n40 + i += n41 } return i, nil } @@ -2929,19 +2937,19 @@ func (m *Event) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n41, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n42, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n41 + i += n42 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.InvolvedObject.Size())) - n42, err := m.InvolvedObject.MarshalTo(dAtA[i:]) + n43, err := m.InvolvedObject.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n42 + i += n43 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) @@ -2953,27 +2961,27 @@ func (m *Event) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x2a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Source.Size())) - n43, err := m.Source.MarshalTo(dAtA[i:]) + n44, err := m.Source.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n43 + i += n44 dAtA[i] = 0x32 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.FirstTimestamp.Size())) - n44, err := m.FirstTimestamp.MarshalTo(dAtA[i:]) + n45, err := m.FirstTimestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n44 + i += n45 dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastTimestamp.Size())) - n45, err := m.LastTimestamp.MarshalTo(dAtA[i:]) + n46, err := m.LastTimestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n45 + i += n46 dAtA[i] = 0x40 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Count)) @@ -3002,11 +3010,11 @@ func (m *EventList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n46, err := m.ListMeta.MarshalTo(dAtA[i:]) + n47, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n46 + i += n47 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -3158,11 +3166,11 @@ func (m *FlexVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) - n47, err := m.SecretRef.MarshalTo(dAtA[i:]) + n48, err := m.SecretRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n47 + i += n48 } dAtA[i] = 0x20 i++ @@ -3341,11 +3349,11 @@ func (m *HTTPGetAction) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Port.Size())) - n48, err := m.Port.MarshalTo(dAtA[i:]) + n49, err := m.Port.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n48 + i += n49 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Host))) @@ -3414,31 +3422,31 @@ func (m *Handler) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Exec.Size())) - n49, err := m.Exec.MarshalTo(dAtA[i:]) + n50, err := m.Exec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n49 + i += n50 } if m.HTTPGet != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.HTTPGet.Size())) - n50, err := m.HTTPGet.MarshalTo(dAtA[i:]) + n51, err := m.HTTPGet.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n50 + i += n51 } if m.TCPSocket != nil { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.TCPSocket.Size())) - n51, err := m.TCPSocket.MarshalTo(dAtA[i:]) + n52, err := m.TCPSocket.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n51 + i += n52 } return i, nil } @@ -3571,11 +3579,11 @@ func (m *ISCSIVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x52 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) - n52, err := m.SecretRef.MarshalTo(dAtA[i:]) + n53, err := m.SecretRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n52 + i += n53 } dAtA[i] = 0x58 i++ @@ -3638,21 +3646,21 @@ func (m *Lifecycle) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PostStart.Size())) - n53, err := m.PostStart.MarshalTo(dAtA[i:]) + n54, err := m.PostStart.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n53 + i += n54 } if m.PreStop != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PreStop.Size())) - n54, err := m.PreStop.MarshalTo(dAtA[i:]) + n55, err := m.PreStop.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n54 + i += n55 } return i, nil } @@ -3675,19 +3683,19 @@ func (m *LimitRange) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n55, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n56, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n55 + i += n56 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n56, err := m.Spec.MarshalTo(dAtA[i:]) + n57, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n56 + i += n57 return i, nil } @@ -3729,11 +3737,11 @@ func (m *LimitRangeItem) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n57, err := (&v).MarshalTo(dAtA[i:]) + n58, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n57 + i += n58 } } if len(m.Min) > 0 { @@ -3755,11 +3763,11 @@ func (m *LimitRangeItem) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n58, err := (&v).MarshalTo(dAtA[i:]) + n59, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n58 + i += n59 } } if len(m.Default) > 0 { @@ -3781,11 +3789,11 @@ func (m *LimitRangeItem) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n59, err := (&v).MarshalTo(dAtA[i:]) + n60, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n59 + i += n60 } } if len(m.DefaultRequest) > 0 { @@ -3807,11 +3815,11 @@ func (m *LimitRangeItem) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n60, err := (&v).MarshalTo(dAtA[i:]) + n61, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n60 + i += n61 } } if len(m.MaxLimitRequestRatio) > 0 { @@ -3833,11 +3841,11 @@ func (m *LimitRangeItem) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n61, err := (&v).MarshalTo(dAtA[i:]) + n62, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n61 + i += n62 } } return i, nil @@ -3861,11 +3869,11 @@ func (m *LimitRangeList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n62, err := m.ListMeta.MarshalTo(dAtA[i:]) + n63, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n62 + i += n63 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -3929,11 +3937,11 @@ func (m *List) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n63, err := m.ListMeta.MarshalTo(dAtA[i:]) + n64, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n63 + i += n64 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -4152,27 +4160,27 @@ func (m *Namespace) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n64, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n65, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n64 + i += n65 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n65, err := m.Spec.MarshalTo(dAtA[i:]) + n66, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n65 + i += n66 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n66, err := m.Status.MarshalTo(dAtA[i:]) + n67, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n66 + i += n67 return i, nil } @@ -4194,11 +4202,11 @@ func (m *NamespaceList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n67, err := m.ListMeta.MarshalTo(dAtA[i:]) + n68, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n67 + i += n68 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -4287,27 +4295,27 @@ func (m *Node) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n68, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n69, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n68 + i += n69 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n69, err := m.Spec.MarshalTo(dAtA[i:]) + n70, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n69 + i += n70 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n70, err := m.Status.MarshalTo(dAtA[i:]) + n71, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n70 + i += n71 return i, nil } @@ -4356,11 +4364,11 @@ func (m *NodeAffinity) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.RequiredDuringSchedulingIgnoredDuringExecution.Size())) - n71, err := m.RequiredDuringSchedulingIgnoredDuringExecution.MarshalTo(dAtA[i:]) + n72, err := m.RequiredDuringSchedulingIgnoredDuringExecution.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n71 + i += n72 } if len(m.PreferredDuringSchedulingIgnoredDuringExecution) > 0 { for _, msg := range m.PreferredDuringSchedulingIgnoredDuringExecution { @@ -4403,19 +4411,19 @@ func (m *NodeCondition) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastHeartbeatTime.Size())) - n72, err := m.LastHeartbeatTime.MarshalTo(dAtA[i:]) + n73, err := m.LastHeartbeatTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n72 + i += n73 dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) - n73, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) + n74, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n73 + i += n74 dAtA[i] = 0x2a i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) @@ -4445,11 +4453,11 @@ func (m *NodeDaemonEndpoints) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.KubeletEndpoint.Size())) - n74, err := m.KubeletEndpoint.MarshalTo(dAtA[i:]) + n75, err := m.KubeletEndpoint.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n74 + i += n75 return i, nil } @@ -4471,11 +4479,11 @@ func (m *NodeList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n75, err := m.ListMeta.MarshalTo(dAtA[i:]) + n76, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n75 + i += n76 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -4547,11 +4555,11 @@ func (m *NodeResources) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n76, err := (&v).MarshalTo(dAtA[i:]) + n77, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n76 + i += n77 } } return i, nil @@ -4742,11 +4750,11 @@ func (m *NodeStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n77, err := (&v).MarshalTo(dAtA[i:]) + n78, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n77 + i += n78 } } if len(m.Allocatable) > 0 { @@ -4768,11 +4776,11 @@ func (m *NodeStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n78, err := (&v).MarshalTo(dAtA[i:]) + n79, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n78 + i += n79 } } dAtA[i] = 0x1a @@ -4806,19 +4814,19 @@ func (m *NodeStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x32 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.DaemonEndpoints.Size())) - n79, err := m.DaemonEndpoints.MarshalTo(dAtA[i:]) + n80, err := m.DaemonEndpoints.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n79 + i += n80 dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.NodeInfo.Size())) - n80, err := m.NodeInfo.MarshalTo(dAtA[i:]) + n81, err := m.NodeInfo.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n80 + i += n81 if len(m.Images) > 0 { for _, msg := range m.Images { dAtA[i] = 0x42 @@ -4990,20 +4998,20 @@ func (m *ObjectMeta) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x42 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.CreationTimestamp.Size())) - n81, err := m.CreationTimestamp.MarshalTo(dAtA[i:]) + n82, err := m.CreationTimestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n81 + i += n82 if m.DeletionTimestamp != nil { dAtA[i] = 0x4a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.DeletionTimestamp.Size())) - n82, err := m.DeletionTimestamp.MarshalTo(dAtA[i:]) + n83, err := m.DeletionTimestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n82 + i += n83 } if m.DeletionGracePeriodSeconds != nil { dAtA[i] = 0x50 @@ -5081,11 +5089,11 @@ func (m *ObjectMeta) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Initializers.Size())) - n83, err := m.Initializers.MarshalTo(dAtA[i:]) + n84, err := m.Initializers.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n83 + i += n84 } return i, nil } @@ -5154,27 +5162,27 @@ func (m *PersistentVolume) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n84, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n85, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n84 + i += n85 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n85, err := m.Spec.MarshalTo(dAtA[i:]) + n86, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n85 + i += n86 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n86, err := m.Status.MarshalTo(dAtA[i:]) + n87, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n86 + i += n87 return i, nil } @@ -5196,27 +5204,27 @@ func (m *PersistentVolumeClaim) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n87, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n88, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n87 + i += n88 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n88, err := m.Spec.MarshalTo(dAtA[i:]) + n89, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n88 + i += n89 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n89, err := m.Status.MarshalTo(dAtA[i:]) + n90, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n89 + i += n90 return i, nil } @@ -5238,11 +5246,11 @@ func (m *PersistentVolumeClaimList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n90, err := m.ListMeta.MarshalTo(dAtA[i:]) + n91, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n90 + i += n91 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -5291,11 +5299,11 @@ func (m *PersistentVolumeClaimSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Resources.Size())) - n91, err := m.Resources.MarshalTo(dAtA[i:]) + n92, err := m.Resources.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n91 + i += n92 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.VolumeName))) @@ -5304,11 +5312,11 @@ func (m *PersistentVolumeClaimSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) - n92, err := m.Selector.MarshalTo(dAtA[i:]) + n93, err := m.Selector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n92 + i += n93 } if m.StorageClassName != nil { dAtA[i] = 0x2a @@ -5372,11 +5380,11 @@ func (m *PersistentVolumeClaimStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n93, err := (&v).MarshalTo(dAtA[i:]) + n94, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n93 + i += n94 } } return i, nil @@ -5430,11 +5438,11 @@ func (m *PersistentVolumeList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n94, err := m.ListMeta.MarshalTo(dAtA[i:]) + n95, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n94 + i += n95 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -5469,151 +5477,151 @@ func (m *PersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.GCEPersistentDisk.Size())) - n95, err := m.GCEPersistentDisk.MarshalTo(dAtA[i:]) + n96, err := m.GCEPersistentDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n95 + i += n96 } if m.AWSElasticBlockStore != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.AWSElasticBlockStore.Size())) - n96, err := m.AWSElasticBlockStore.MarshalTo(dAtA[i:]) + n97, err := m.AWSElasticBlockStore.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n96 + i += n97 } if m.HostPath != nil { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.HostPath.Size())) - n97, err := m.HostPath.MarshalTo(dAtA[i:]) + n98, err := m.HostPath.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n97 + i += n98 } if m.Glusterfs != nil { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Glusterfs.Size())) - n98, err := m.Glusterfs.MarshalTo(dAtA[i:]) + n99, err := m.Glusterfs.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n98 + i += n99 } if m.NFS != nil { dAtA[i] = 0x2a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.NFS.Size())) - n99, err := m.NFS.MarshalTo(dAtA[i:]) + n100, err := m.NFS.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n99 + i += n100 } if m.RBD != nil { dAtA[i] = 0x32 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.RBD.Size())) - n100, err := m.RBD.MarshalTo(dAtA[i:]) + n101, err := m.RBD.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n100 + i += n101 } if m.ISCSI != nil { dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ISCSI.Size())) - n101, err := m.ISCSI.MarshalTo(dAtA[i:]) + n102, err := m.ISCSI.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n101 + i += n102 } if m.Cinder != nil { dAtA[i] = 0x42 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Cinder.Size())) - n102, err := m.Cinder.MarshalTo(dAtA[i:]) + n103, err := m.Cinder.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n102 + i += n103 } if m.CephFS != nil { dAtA[i] = 0x4a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.CephFS.Size())) - n103, err := m.CephFS.MarshalTo(dAtA[i:]) + n104, err := m.CephFS.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n103 + i += n104 } if m.FC != nil { dAtA[i] = 0x52 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.FC.Size())) - n104, err := m.FC.MarshalTo(dAtA[i:]) + n105, err := m.FC.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n104 + i += n105 } if m.Flocker != nil { dAtA[i] = 0x5a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Flocker.Size())) - n105, err := m.Flocker.MarshalTo(dAtA[i:]) + n106, err := m.Flocker.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n105 + i += n106 } if m.FlexVolume != nil { dAtA[i] = 0x62 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.FlexVolume.Size())) - n106, err := m.FlexVolume.MarshalTo(dAtA[i:]) + n107, err := m.FlexVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n106 + i += n107 } if m.AzureFile != nil { dAtA[i] = 0x6a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.AzureFile.Size())) - n107, err := m.AzureFile.MarshalTo(dAtA[i:]) + n108, err := m.AzureFile.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n107 + i += n108 } if m.VsphereVolume != nil { dAtA[i] = 0x72 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.VsphereVolume.Size())) - n108, err := m.VsphereVolume.MarshalTo(dAtA[i:]) + n109, err := m.VsphereVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n108 + i += n109 } if m.Quobyte != nil { dAtA[i] = 0x7a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Quobyte.Size())) - n109, err := m.Quobyte.MarshalTo(dAtA[i:]) + n110, err := m.Quobyte.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n109 + i += n110 } if m.AzureDisk != nil { dAtA[i] = 0x82 @@ -5621,11 +5629,11 @@ func (m *PersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.AzureDisk.Size())) - n110, err := m.AzureDisk.MarshalTo(dAtA[i:]) + n111, err := m.AzureDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n110 + i += n111 } if m.PhotonPersistentDisk != nil { dAtA[i] = 0x8a @@ -5633,11 +5641,11 @@ func (m *PersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PhotonPersistentDisk.Size())) - n111, err := m.PhotonPersistentDisk.MarshalTo(dAtA[i:]) + n112, err := m.PhotonPersistentDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n111 + i += n112 } if m.PortworxVolume != nil { dAtA[i] = 0x92 @@ -5645,11 +5653,11 @@ func (m *PersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PortworxVolume.Size())) - n112, err := m.PortworxVolume.MarshalTo(dAtA[i:]) + n113, err := m.PortworxVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n112 + i += n113 } if m.ScaleIO != nil { dAtA[i] = 0x9a @@ -5657,11 +5665,11 @@ func (m *PersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ScaleIO.Size())) - n113, err := m.ScaleIO.MarshalTo(dAtA[i:]) + n114, err := m.ScaleIO.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n113 + i += n114 } if m.Local != nil { dAtA[i] = 0xa2 @@ -5669,11 +5677,11 @@ func (m *PersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Local.Size())) - n114, err := m.Local.MarshalTo(dAtA[i:]) + n115, err := m.Local.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n114 + i += n115 } return i, nil } @@ -5712,21 +5720,21 @@ func (m *PersistentVolumeSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n115, err := (&v).MarshalTo(dAtA[i:]) + n116, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n115 + i += n116 } } dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PersistentVolumeSource.Size())) - n116, err := m.PersistentVolumeSource.MarshalTo(dAtA[i:]) + n117, err := m.PersistentVolumeSource.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n116 + i += n117 if len(m.AccessModes) > 0 { for _, s := range m.AccessModes { dAtA[i] = 0x1a @@ -5746,11 +5754,11 @@ func (m *PersistentVolumeSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ClaimRef.Size())) - n117, err := m.ClaimRef.MarshalTo(dAtA[i:]) + n118, err := m.ClaimRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n117 + i += n118 } dAtA[i] = 0x2a i++ @@ -5837,27 +5845,27 @@ func (m *Pod) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n118, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n119, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n118 + i += n119 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n119, err := m.Spec.MarshalTo(dAtA[i:]) + n120, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n119 + i += n120 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n120, err := m.Status.MarshalTo(dAtA[i:]) + n121, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n120 + i += n121 return i, nil } @@ -5922,11 +5930,11 @@ func (m *PodAffinityTerm) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LabelSelector.Size())) - n121, err := m.LabelSelector.MarshalTo(dAtA[i:]) + n122, err := m.LabelSelector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n121 + i += n122 } if len(m.Namespaces) > 0 { for _, s := range m.Namespaces { @@ -6072,19 +6080,19 @@ func (m *PodCondition) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastProbeTime.Size())) - n122, err := m.LastProbeTime.MarshalTo(dAtA[i:]) + n123, err := m.LastProbeTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n122 + i += n123 dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) - n123, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) + n124, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n123 + i += n124 dAtA[i] = 0x2a i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) @@ -6183,11 +6191,11 @@ func (m *PodList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n124, err := m.ListMeta.MarshalTo(dAtA[i:]) + n125, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n124 + i += n125 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -6247,11 +6255,11 @@ func (m *PodLogOptions) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x2a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SinceTime.Size())) - n125, err := m.SinceTime.MarshalTo(dAtA[i:]) + n126, err := m.SinceTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n125 + i += n126 } dAtA[i] = 0x30 i++ @@ -6340,11 +6348,11 @@ func (m *PodSecurityContext) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SELinuxOptions.Size())) - n126, err := m.SELinuxOptions.MarshalTo(dAtA[i:]) + n127, err := m.SELinuxOptions.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n126 + i += n127 } if m.RunAsUser != nil { dAtA[i] = 0x10 @@ -6395,11 +6403,11 @@ func (m *PodSignature) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PodController.Size())) - n127, err := m.PodController.MarshalTo(dAtA[i:]) + n128, err := m.PodController.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n127 + i += n128 } return i, nil } @@ -6518,11 +6526,11 @@ func (m *PodSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x72 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecurityContext.Size())) - n128, err := m.SecurityContext.MarshalTo(dAtA[i:]) + n129, err := m.SecurityContext.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n128 + i += n129 } if len(m.ImagePullSecrets) > 0 { for _, msg := range m.ImagePullSecrets { @@ -6554,11 +6562,11 @@ func (m *PodSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Affinity.Size())) - n129, err := m.Affinity.MarshalTo(dAtA[i:]) + n130, err := m.Affinity.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n129 + i += n130 } dAtA[i] = 0x9a i++ @@ -6674,11 +6682,11 @@ func (m *PodStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.StartTime.Size())) - n130, err := m.StartTime.MarshalTo(dAtA[i:]) + n131, err := m.StartTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n130 + i += n131 } if len(m.ContainerStatuses) > 0 { for _, msg := range m.ContainerStatuses { @@ -6729,19 +6737,19 @@ func (m *PodStatusResult) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n131, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n132, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n131 + i += n132 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n132, err := m.Status.MarshalTo(dAtA[i:]) + n133, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n132 + i += n133 return i, nil } @@ -6763,19 +6771,19 @@ func (m *PodTemplate) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n133, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n134, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n133 + i += n134 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) - n134, err := m.Template.MarshalTo(dAtA[i:]) + n135, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n134 + i += n135 return i, nil } @@ -6797,11 +6805,11 @@ func (m *PodTemplateList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n135, err := m.ListMeta.MarshalTo(dAtA[i:]) + n136, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n135 + i += n136 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -6835,19 +6843,19 @@ func (m *PodTemplateSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n136, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n137, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n136 + i += n137 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n137, err := m.Spec.MarshalTo(dAtA[i:]) + n138, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n137 + i += n138 return i, nil } @@ -6927,19 +6935,19 @@ func (m *PreferAvoidPodsEntry) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PodSignature.Size())) - n138, err := m.PodSignature.MarshalTo(dAtA[i:]) + n139, err := m.PodSignature.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n138 + i += n139 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.EvictionTime.Size())) - n139, err := m.EvictionTime.MarshalTo(dAtA[i:]) + n140, err := m.EvictionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n139 + i += n140 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) @@ -6972,11 +6980,11 @@ func (m *PreferredSchedulingTerm) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Preference.Size())) - n140, err := m.Preference.MarshalTo(dAtA[i:]) + n141, err := m.Preference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n140 + i += n141 return i, nil } @@ -6998,11 +7006,11 @@ func (m *Probe) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Handler.Size())) - n141, err := m.Handler.MarshalTo(dAtA[i:]) + n142, err := m.Handler.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n141 + i += n142 dAtA[i] = 0x10 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.InitialDelaySeconds)) @@ -7152,11 +7160,11 @@ func (m *RBDVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) - n142, err := m.SecretRef.MarshalTo(dAtA[i:]) + n143, err := m.SecretRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n142 + i += n143 } dAtA[i] = 0x40 i++ @@ -7187,11 +7195,11 @@ func (m *RangeAllocation) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n143, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n144, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n143 + i += n144 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Range))) @@ -7223,27 +7231,27 @@ func (m *ReplicationController) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n144, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n145, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n144 + i += n145 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n145, err := m.Spec.MarshalTo(dAtA[i:]) + n146, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n145 + i += n146 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n146, err := m.Status.MarshalTo(dAtA[i:]) + n147, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n146 + i += n147 return i, nil } @@ -7273,11 +7281,11 @@ func (m *ReplicationControllerCondition) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) - n147, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) + n148, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n147 + i += n148 dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) @@ -7307,11 +7315,11 @@ func (m *ReplicationControllerList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n148, err := m.ListMeta.MarshalTo(dAtA[i:]) + n149, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n148 + i += n149 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -7368,11 +7376,11 @@ func (m *ReplicationControllerSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) - n149, err := m.Template.MarshalTo(dAtA[i:]) + n150, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n149 + i += n150 } dAtA[i] = 0x20 i++ @@ -7451,11 +7459,11 @@ func (m *ResourceFieldSelector) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Divisor.Size())) - n150, err := m.Divisor.MarshalTo(dAtA[i:]) + n151, err := m.Divisor.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n150 + i += n151 return i, nil } @@ -7477,27 +7485,27 @@ func (m *ResourceQuota) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n151, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n152, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n151 + i += n152 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n152, err := m.Spec.MarshalTo(dAtA[i:]) + n153, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n152 + i += n153 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n153, err := m.Status.MarshalTo(dAtA[i:]) + n154, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n153 + i += n154 return i, nil } @@ -7519,11 +7527,11 @@ func (m *ResourceQuotaList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n154, err := m.ListMeta.MarshalTo(dAtA[i:]) + n155, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n154 + i += n155 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -7573,11 +7581,11 @@ func (m *ResourceQuotaSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n155, err := (&v).MarshalTo(dAtA[i:]) + n156, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n155 + i += n156 } } if len(m.Scopes) > 0 { @@ -7632,11 +7640,11 @@ func (m *ResourceQuotaStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n156, err := (&v).MarshalTo(dAtA[i:]) + n157, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n156 + i += n157 } } if len(m.Used) > 0 { @@ -7658,11 +7666,11 @@ func (m *ResourceQuotaStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n157, err := (&v).MarshalTo(dAtA[i:]) + n158, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n157 + i += n158 } } return i, nil @@ -7702,11 +7710,11 @@ func (m *ResourceRequirements) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n158, err := (&v).MarshalTo(dAtA[i:]) + n159, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n158 + i += n159 } } if len(m.Requests) > 0 { @@ -7728,11 +7736,11 @@ func (m *ResourceRequirements) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n159, err := (&v).MarshalTo(dAtA[i:]) + n160, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n159 + i += n160 } } return i, nil @@ -7799,11 +7807,11 @@ func (m *ScaleIOVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) - n160, err := m.SecretRef.MarshalTo(dAtA[i:]) + n161, err := m.SecretRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n160 + i += n161 } dAtA[i] = 0x20 i++ @@ -7862,11 +7870,11 @@ func (m *Secret) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n161, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n162, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n161 + i += n162 if len(m.Data) > 0 { for k := range m.Data { dAtA[i] = 0x12 @@ -7932,11 +7940,11 @@ func (m *SecretEnvSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LocalObjectReference.Size())) - n162, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) + n163, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n162 + i += n163 if m.Optional != nil { dAtA[i] = 0x10 i++ @@ -7968,11 +7976,11 @@ func (m *SecretKeySelector) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LocalObjectReference.Size())) - n163, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) + n164, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n163 + i += n164 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Key))) @@ -8008,11 +8016,11 @@ func (m *SecretList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n164, err := m.ListMeta.MarshalTo(dAtA[i:]) + n165, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n164 + i += n165 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -8046,11 +8054,11 @@ func (m *SecretProjection) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LocalObjectReference.Size())) - n165, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) + n166, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n165 + i += n166 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -8144,11 +8152,11 @@ func (m *SecurityContext) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Capabilities.Size())) - n166, err := m.Capabilities.MarshalTo(dAtA[i:]) + n167, err := m.Capabilities.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n166 + i += n167 } if m.Privileged != nil { dAtA[i] = 0x10 @@ -8164,11 +8172,11 @@ func (m *SecurityContext) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SELinuxOptions.Size())) - n167, err := m.SELinuxOptions.MarshalTo(dAtA[i:]) + n168, err := m.SELinuxOptions.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n167 + i += n168 } if m.RunAsUser != nil { dAtA[i] = 0x20 @@ -8216,11 +8224,11 @@ func (m *SerializedReference) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Reference.Size())) - n168, err := m.Reference.MarshalTo(dAtA[i:]) + n169, err := m.Reference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n168 + i += n169 return i, nil } @@ -8242,27 +8250,27 @@ func (m *Service) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n169, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n170, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n169 + i += n170 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n170, err := m.Spec.MarshalTo(dAtA[i:]) + n171, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n170 + i += n171 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n171, err := m.Status.MarshalTo(dAtA[i:]) + n172, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n171 + i += n172 return i, nil } @@ -8284,11 +8292,11 @@ func (m *ServiceAccount) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n172, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n173, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n172 + i += n173 if len(m.Secrets) > 0 { for _, msg := range m.Secrets { dAtA[i] = 0x12 @@ -8344,11 +8352,11 @@ func (m *ServiceAccountList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n173, err := m.ListMeta.MarshalTo(dAtA[i:]) + n174, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n173 + i += n174 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -8382,11 +8390,11 @@ func (m *ServiceList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n174, err := m.ListMeta.MarshalTo(dAtA[i:]) + n175, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n174 + i += n175 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -8431,11 +8439,11 @@ func (m *ServicePort) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.TargetPort.Size())) - n175, err := m.TargetPort.MarshalTo(dAtA[i:]) + n176, err := m.TargetPort.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n175 + i += n176 dAtA[i] = 0x28 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.NodePort)) @@ -8586,11 +8594,11 @@ func (m *ServiceStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LoadBalancer.Size())) - n176, err := m.LoadBalancer.MarshalTo(dAtA[i:]) + n177, err := m.LoadBalancer.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n176 + i += n177 return i, nil } @@ -8638,11 +8646,11 @@ func (m *TCPSocketAction) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Port.Size())) - n177, err := m.Port.MarshalTo(dAtA[i:]) + n178, err := m.Port.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n177 + i += n178 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Host))) @@ -8680,11 +8688,11 @@ func (m *Taint) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.TimeAdded.Size())) - n178, err := m.TimeAdded.MarshalTo(dAtA[i:]) + n179, err := m.TimeAdded.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n178 + i += n179 return i, nil } @@ -8749,11 +8757,11 @@ func (m *Volume) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.VolumeSource.Size())) - n179, err := m.VolumeSource.MarshalTo(dAtA[i:]) + n180, err := m.VolumeSource.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n179 + i += n180 return i, nil } @@ -8814,31 +8822,31 @@ func (m *VolumeProjection) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Secret.Size())) - n180, err := m.Secret.MarshalTo(dAtA[i:]) + n181, err := m.Secret.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n180 + i += n181 } if m.DownwardAPI != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.DownwardAPI.Size())) - n181, err := m.DownwardAPI.MarshalTo(dAtA[i:]) + n182, err := m.DownwardAPI.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n181 + i += n182 } if m.ConfigMap != nil { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ConfigMap.Size())) - n182, err := m.ConfigMap.MarshalTo(dAtA[i:]) + n183, err := m.ConfigMap.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n182 + i += n183 } return i, nil } @@ -8862,151 +8870,151 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.HostPath.Size())) - n183, err := m.HostPath.MarshalTo(dAtA[i:]) + n184, err := m.HostPath.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n183 + i += n184 } if m.EmptyDir != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.EmptyDir.Size())) - n184, err := m.EmptyDir.MarshalTo(dAtA[i:]) + n185, err := m.EmptyDir.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n184 + i += n185 } if m.GCEPersistentDisk != nil { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.GCEPersistentDisk.Size())) - n185, err := m.GCEPersistentDisk.MarshalTo(dAtA[i:]) + n186, err := m.GCEPersistentDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n185 + i += n186 } if m.AWSElasticBlockStore != nil { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.AWSElasticBlockStore.Size())) - n186, err := m.AWSElasticBlockStore.MarshalTo(dAtA[i:]) + n187, err := m.AWSElasticBlockStore.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n186 + i += n187 } if m.GitRepo != nil { dAtA[i] = 0x2a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.GitRepo.Size())) - n187, err := m.GitRepo.MarshalTo(dAtA[i:]) + n188, err := m.GitRepo.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n187 + i += n188 } if m.Secret != nil { dAtA[i] = 0x32 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Secret.Size())) - n188, err := m.Secret.MarshalTo(dAtA[i:]) + n189, err := m.Secret.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n188 + i += n189 } if m.NFS != nil { dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.NFS.Size())) - n189, err := m.NFS.MarshalTo(dAtA[i:]) + n190, err := m.NFS.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n189 + i += n190 } if m.ISCSI != nil { dAtA[i] = 0x42 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ISCSI.Size())) - n190, err := m.ISCSI.MarshalTo(dAtA[i:]) + n191, err := m.ISCSI.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n190 + i += n191 } if m.Glusterfs != nil { dAtA[i] = 0x4a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Glusterfs.Size())) - n191, err := m.Glusterfs.MarshalTo(dAtA[i:]) + n192, err := m.Glusterfs.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n191 + i += n192 } if m.PersistentVolumeClaim != nil { dAtA[i] = 0x52 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PersistentVolumeClaim.Size())) - n192, err := m.PersistentVolumeClaim.MarshalTo(dAtA[i:]) + n193, err := m.PersistentVolumeClaim.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n192 + i += n193 } if m.RBD != nil { dAtA[i] = 0x5a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.RBD.Size())) - n193, err := m.RBD.MarshalTo(dAtA[i:]) + n194, err := m.RBD.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n193 + i += n194 } if m.FlexVolume != nil { dAtA[i] = 0x62 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.FlexVolume.Size())) - n194, err := m.FlexVolume.MarshalTo(dAtA[i:]) + n195, err := m.FlexVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n194 + i += n195 } if m.Cinder != nil { dAtA[i] = 0x6a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Cinder.Size())) - n195, err := m.Cinder.MarshalTo(dAtA[i:]) + n196, err := m.Cinder.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n195 + i += n196 } if m.CephFS != nil { dAtA[i] = 0x72 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.CephFS.Size())) - n196, err := m.CephFS.MarshalTo(dAtA[i:]) + n197, err := m.CephFS.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n196 + i += n197 } if m.Flocker != nil { dAtA[i] = 0x7a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Flocker.Size())) - n197, err := m.Flocker.MarshalTo(dAtA[i:]) + n198, err := m.Flocker.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n197 + i += n198 } if m.DownwardAPI != nil { dAtA[i] = 0x82 @@ -9014,11 +9022,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.DownwardAPI.Size())) - n198, err := m.DownwardAPI.MarshalTo(dAtA[i:]) + n199, err := m.DownwardAPI.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n198 + i += n199 } if m.FC != nil { dAtA[i] = 0x8a @@ -9026,11 +9034,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.FC.Size())) - n199, err := m.FC.MarshalTo(dAtA[i:]) + n200, err := m.FC.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n199 + i += n200 } if m.AzureFile != nil { dAtA[i] = 0x92 @@ -9038,11 +9046,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.AzureFile.Size())) - n200, err := m.AzureFile.MarshalTo(dAtA[i:]) + n201, err := m.AzureFile.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n200 + i += n201 } if m.ConfigMap != nil { dAtA[i] = 0x9a @@ -9050,11 +9058,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ConfigMap.Size())) - n201, err := m.ConfigMap.MarshalTo(dAtA[i:]) + n202, err := m.ConfigMap.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n201 + i += n202 } if m.VsphereVolume != nil { dAtA[i] = 0xa2 @@ -9062,11 +9070,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.VsphereVolume.Size())) - n202, err := m.VsphereVolume.MarshalTo(dAtA[i:]) + n203, err := m.VsphereVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n202 + i += n203 } if m.Quobyte != nil { dAtA[i] = 0xaa @@ -9074,11 +9082,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Quobyte.Size())) - n203, err := m.Quobyte.MarshalTo(dAtA[i:]) + n204, err := m.Quobyte.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n203 + i += n204 } if m.AzureDisk != nil { dAtA[i] = 0xb2 @@ -9086,11 +9094,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.AzureDisk.Size())) - n204, err := m.AzureDisk.MarshalTo(dAtA[i:]) + n205, err := m.AzureDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n204 + i += n205 } if m.PhotonPersistentDisk != nil { dAtA[i] = 0xba @@ -9098,11 +9106,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PhotonPersistentDisk.Size())) - n205, err := m.PhotonPersistentDisk.MarshalTo(dAtA[i:]) + n206, err := m.PhotonPersistentDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n205 + i += n206 } if m.PortworxVolume != nil { dAtA[i] = 0xc2 @@ -9110,11 +9118,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PortworxVolume.Size())) - n206, err := m.PortworxVolume.MarshalTo(dAtA[i:]) + n207, err := m.PortworxVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n206 + i += n207 } if m.ScaleIO != nil { dAtA[i] = 0xca @@ -9122,11 +9130,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ScaleIO.Size())) - n207, err := m.ScaleIO.MarshalTo(dAtA[i:]) + n208, err := m.ScaleIO.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n207 + i += n208 } if m.Projected != nil { dAtA[i] = 0xd2 @@ -9134,11 +9142,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Projected.Size())) - n208, err := m.Projected.MarshalTo(dAtA[i:]) + n209, err := m.Projected.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n208 + i += n209 } return i, nil } @@ -9198,11 +9206,11 @@ func (m *WeightedPodAffinityTerm) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PodAffinityTerm.Size())) - n209, err := m.PodAffinityTerm.MarshalTo(dAtA[i:]) + n210, err := m.PodAffinityTerm.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n209 + i += n210 return i, nil } @@ -9770,6 +9778,8 @@ func (m *EmptyDirVolumeSource) Size() (n int) { _ = l l = len(m.Medium) n += 1 + l + sovGenerated(uint64(l)) + l = m.SizeLimit.Size() + n += 1 + l + sovGenerated(uint64(l)) return n } @@ -12642,6 +12652,7 @@ func (this *EmptyDirVolumeSource) String() string { } s := strings.Join([]string{`&EmptyDirVolumeSource{`, `Medium:` + fmt.Sprintf("%v", this.Medium) + `,`, + `SizeLimit:` + strings.Replace(strings.Replace(this.SizeLimit.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -19602,6 +19613,36 @@ func (m *EmptyDirVolumeSource) Unmarshal(dAtA []byte) error { } m.Medium = StorageMedium(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SizeLimit", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.SizeLimit.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -43577,715 +43618,715 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 11348 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00,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 0x84, 0x06, 0xc3, 0x7a, 0x7d, 0x64, - 0xab, 0x8d, 0x38, 0xc0, 0x28, 0x41, 0xc6, 0x26, 0x3c, 0xab, 0xed, 0xa9, 0x41, 0xb6, 0xa7, 0xc6, - 0xb2, 0xf7, 0x13, 0xba, 0x00, 0x03, 0xf7, 0x5c, 0xbf, 0x39, 0x3b, 0xc4, 0x68, 0x3d, 0x4e, 0x3f, - 0xff, 0x55, 0xd7, 0x6f, 0xee, 0xef, 0xce, 0x4f, 0x1b, 0xdd, 0xa1, 0x85, 0x98, 0xa1, 0xda, 0xff, - 0xc8, 0x12, 0xd3, 0xb8, 0xea, 0x7a, 0x26, 0x47, 0xb9, 0x08, 0x10, 0x91, 0x46, 0x48, 0x62, 0x6d, - 0x22, 0xd5, 0xca, 0xa8, 0x2b, 0x08, 0xd6, 0xb0, 0x28, 0xbf, 0x88, 0x36, 0x9d, 0x90, 0x2d, 0x30, - 0x31, 0x9d, 0x8a, 0x5f, 0xd4, 0x25, 0x00, 0x27, 0x38, 0x06, 0xbf, 0x28, 0xe7, 0xf2, 0x8b, 0xdf, - 0xb2, 0x60, 0x78, 0xc9, 0xf5, 0x9b, 0xae, 0xdf, 0x42, 0x6f, 0xc3, 0x08, 0x3d, 0x04, 0x9a, 0x4e, - 0xec, 0x08, 0x56, 0xf1, 0x61, 0xb9, 0xde, 0x74, 0x9e, 0x2c, 0x57, 0x5c, 0xb4, 0x40, 0xb1, 0xe9, - 0xba, 0xbb, 0x79, 0xf7, 0x1d, 0xd2, 0x88, 0xaf, 0x93, 0xd8, 0x49, 0x86, 0x93, 0x94, 0x61, 0x45, - 0x15, 0xdd, 0x82, 0xa1, 0xd8, 0x09, 0x5b, 0x24, 0x16, 0x9c, 0x22, 0x67, 0x1f, 0x73, 0x1a, 0x98, - 0xae, 0x52, 0xe2, 0x37, 0x48, 0xc2, 0x53, 0xd7, 0x19, 0x11, 0x2c, 0x88, 0xd9, 0x0d, 0x18, 0x5b, - 0x76, 0xda, 0x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0xb5, 0x9e, 0x89, 0x85, 0x7b, 0xd4, 0x46, 0x37, 0x61, 0x92, 0xed, 0xa7, 0x5a, 0xc7, 0xf3, 0x6a, - 0x81, 0xe7, 0x36, 0x76, 0x66, 0x27, 0x18, 0xc1, 0xa7, 0xa4, 0xcd, 0x64, 0xcd, 0x04, 0x53, 0xc5, - 0x30, 0xf9, 0x87, 0xd3, 0xb5, 0x91, 0x07, 0x93, 0x11, 0x69, 0x74, 0x42, 0x37, 0xde, 0xa1, 0x6b, - 0x9f, 0x3c, 0x88, 0x67, 0x27, 0x8b, 0x28, 0xba, 0x75, 0xb3, 0x12, 0x37, 0x58, 0xa5, 0x0a, 0x71, - 0x9a, 0x34, 0x65, 0x15, 0x51, 0xdc, 0x74, 0xfd, 0xd9, 0x29, 0xc6, 0x81, 0xd4, 0xfe, 0xaa, 0xd3, - 0x42, 0xcc, 0x61, 0xcc, 0x7e, 0x40, 0x7f, 0xdc, 0xa4, 0x5c, 0x7a, 0x9a, 0x21, 0x26, 0xf6, 0x03, - 0x09, 0xc0, 0x09, 0x0e, 0x15, 0x0d, 0xe2, 0x78, 0x67, 0x16, 0x31, 0x54, 0xb5, 0xd5, 0xd6, 0xd7, - 0x3f, 0x85, 0x69, 0x39, 0xba, 0x0d, 0xc3, 0xc4, 0xdf, 0x5e, 0x0d, 0x83, 0xad, 0xd9, 0x13, 0x45, - 0x78, 0xc0, 0x0a, 0x47, 0xe6, 0xe7, 0x47, 0xa2, 0xc2, 0x88, 0x62, 0x2c, 0x89, 0xa1, 0x07, 0x30, - 0x9b, 0xf1, 0x95, 0xf8, 0x47, 0x99, 0x61, 0x1f, 0xe5, 0xe3, 0xa2, 0xee, 0xec, 0x7a, 0x0f, 0xbc, - 0xfd, 0x03, 0x60, 0xb8, 0x27, 0x75, 0xfb, 0x2e, 0x4c, 0x28, 0x46, 0xc5, 0xbe, 0x37, 0x9a, 0x87, - 0x41, 0xca, 0x8b, 0xa5, 0x42, 0x5f, 0xa1, 0x93, 0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, - 0x84, 0xb0, 0xee, 0x6e, 0xa1, 0x4f, 0xd3, 0x2d, 0xed, 0x84, 0x31, 0x69, 0x2e, 0xc6, 0x69, 0x9b, - 0xfe, 0xc1, 0x22, 0xf6, 0xba, 0xbb, 0x45, 0xf4, 0xed, 0x2f, 0x88, 0xe0, 0x84, 0x9e, 0xfd, 0xbd, - 0x32, 0xcc, 0xf6, 0xea, 0x2e, 0x5d, 0x92, 0xe4, 0x81, 0x1b, 0x2f, 0x53, 0x31, 0xc9, 0x32, 0x97, - 0xe4, 0x8a, 0x28, 0xc7, 0x0a, 0x83, 0xae, 0x8d, 0xc8, 0x6d, 0x49, 0x65, 0x69, 0x30, 0x59, 0x1b, + // 11352 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x7d, 0x6d, 0x8c, 0x24, 0xc7, + 0x75, 0x98, 0x7a, 0x66, 0xbf, 0xe6, 0xed, 0x77, 0xdd, 0xde, 0x71, 0xb9, 0x22, 0x6f, 0x8f, 0x4d, + 0x91, 0x3e, 0x92, 0xc7, 0x3d, 0xdd, 0x91, 0x14, 0x4f, 0xa2, 0x42, 0x69, 0x77, 0x67, 0xf7, 0x6e, + 0x75, 0xb7, 0x77, 0xc3, 0x9a, 0xbd, 0x3b, 0x8a, 0x62, 0x44, 0xf6, 0x4d, 0xd7, 0xee, 0x36, 0x6f, + 0xb6, 0x7b, 0xd8, 0xdd, 0xb3, 0x77, 0x4b, 0x41, 0x80, 0xad, 0x08, 0x92, 0x02, 0x28, 0x89, 0x02, + 0x47, 0x40, 0xe0, 0x04, 0x50, 0x60, 0x20, 0x8e, 0xf2, 0x69, 0x2b, 0x82, 0x3e, 0x0c, 0xcb, 0x09, + 0xe2, 0x58, 0x8e, 0x0c, 0x24, 0x8e, 0x01, 0x23, 0xb6, 0x03, 0xc3, 0x6b, 0x6b, 0x85, 0xf8, 0x5f, + 0x82, 0x20, 0xf9, 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 0x57, 0x5c, 0x34, 0x47, 0xb1, 0xe9, 0xba, + 0xbb, 0x71, 0xe7, 0x1d, 0xd2, 0x88, 0x57, 0x49, 0xec, 0x24, 0x9f, 0x93, 0x94, 0x61, 0x45, 0x15, + 0xdd, 0x84, 0x81, 0xd8, 0x09, 0x37, 0x48, 0x2c, 0x38, 0x45, 0xce, 0x3e, 0xe6, 0x34, 0x30, 0x5d, + 0xa5, 0xc4, 0x6f, 0x90, 0x84, 0xa7, 0xae, 0x31, 0x22, 0x58, 0x10, 0xb3, 0x1b, 0x30, 0xb2, 0xe8, + 0xb4, 0x9c, 0x3b, 0x5e, 0xd3, 0x8b, 0x3d, 0x12, 0xa1, 0x9f, 0x83, 0xb2, 0xe3, 0xba, 0x6c, 0xcf, + 0x54, 0x16, 0x4e, 0xee, 0xed, 0xce, 0x96, 0xe7, 0x5d, 0x3a, 0x65, 0xa0, 0xb0, 0x76, 0x30, 0xc5, + 0x40, 0xcf, 0x42, 0x9f, 0x1b, 0x06, 0xad, 0xe9, 0x12, 0xc3, 0x3c, 0x45, 0x67, 0xb7, 0x1a, 0x06, + 0xad, 0x14, 0x2a, 0xc3, 0xb1, 0x7f, 0x58, 0x02, 0xb4, 0x48, 0x5a, 0x9b, 0xcb, 0x75, 0x63, 0x4e, + 0xcf, 0xc2, 0xd0, 0x56, 0xe0, 0x7b, 0x71, 0x10, 0x46, 0xa2, 0x41, 0xb6, 0x94, 0x56, 0x45, 0x19, + 0x56, 0x50, 0x74, 0x06, 0xfa, 0x5a, 0x09, 0x47, 0x18, 0x91, 0xdc, 0x84, 0xf1, 0x02, 0x06, 0xa1, + 0x18, 0xed, 0x88, 0x84, 0x62, 0x0b, 0x28, 0x8c, 0x9b, 0x11, 0x09, 0x31, 0x83, 0x24, 0x2b, 0x88, + 0xae, 0x2d, 0xb1, 0xc0, 0x53, 0x2b, 0x88, 0x42, 0xb0, 0x86, 0x85, 0xde, 0x82, 0x0a, 0xff, 0x87, + 0xc9, 0x3a, 0x5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xa2, + 0x08, 0x0f, 0x58, 0xe2, 0xc8, 0xfc, 0xfc, 0x48, 0x54, 0x18, 0x51, 0x8c, 0x25, 0x31, 0x74, 0x1f, + 0xa6, 0x33, 0x66, 0x89, 0x4f, 0xca, 0x14, 0x9b, 0x94, 0x8f, 0x8b, 0xba, 0xd3, 0x6b, 0x5d, 0xf0, + 0xf6, 0x0f, 0x80, 0xe1, 0xae, 0xd4, 0xed, 0x3b, 0x30, 0xa6, 0x18, 0x15, 0x9b, 0x6f, 0x34, 0x0b, + 0xfd, 0x94, 0x17, 0x4b, 0x85, 0xbe, 0x42, 0x07, 0x95, 0xb2, 0xe8, 0x08, 0xf3, 0x72, 0x36, 0xa8, + 0xde, 0x7b, 0x64, 0x61, 0x27, 0x26, 0x5c, 0xb1, 0x2b, 0x6b, 0x83, 0x2a, 0x01, 0x38, 0xc1, 0xb1, + 0xff, 0x2f, 0x17, 0x93, 0x12, 0x6e, 0x58, 0xe0, 0x24, 0x38, 0x07, 0x43, 0x9b, 0x41, 0x14, 0x53, + 0x6c, 0xd6, 0x46, 0x7f, 0x22, 0x18, 0x5d, 0x11, 0xe5, 0x58, 0x61, 0xa0, 0x57, 0x60, 0xb4, 0xa1, + 0x37, 0x20, 0x8e, 0xb1, 0x93, 0xa2, 0x8a, 0xd9, 0x3a, 0x36, 0x71, 0xd1, 0x25, 0x18, 0x62, 0x86, + 0xf1, 0x46, 0xd0, 0x14, 0x2a, 0xa4, 0x3c, 0x95, 0x87, 0x6a, 0xa2, 0x7c, 0x5f, 0xfb, 0x8d, 0x15, + 0x36, 0x55, 0xc4, 0x69, 0x17, 0x56, 0x6a, 0xe2, 0x00, 0x51, 0x8a, 0xf8, 0x15, 0x56, 0x8a, 0x05, + 0xd4, 0xfe, 0xb5, 0x92, 0x36, 0xca, 0x54, 0x01, 0x22, 0xe8, 0x0d, 0x18, 0xbc, 0xe7, 0x78, 0xb1, + 0xe7, 0x6f, 0x08, 0xe9, 0xe1, 0x85, 0x82, 0xa7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44, 0xaf, 0x0a, 0x32, 0x58, - 0x11, 0x44, 0x1d, 0x98, 0x92, 0x7a, 0x98, 0x84, 0x8a, 0xcd, 0xfe, 0x42, 0x31, 0x35, 0xcf, 0x6c, - 0x86, 0x7d, 0x5e, 0x9c, 0x22, 0x88, 0xbb, 0x9a, 0xa0, 0xfa, 0xf3, 0x16, 0x3d, 0xea, 0x06, 0xd8, - 0xd2, 0x67, 0xfa, 0x33, 0x33, 0x05, 0xb0, 0x52, 0xfb, 0x57, 0x2d, 0x78, 0xa4, 0x6b, 0xb6, 0x84, - 0x9d, 0xe4, 0xc8, 0xbe, 0x51, 0xda, 0x58, 0x51, 0xca, 0x37, 0x56, 0xd8, 0x37, 0x61, 0x66, 0x65, - 0xab, 0x1d, 0xef, 0x54, 0x5d, 0xf3, 0xca, 0xe5, 0x65, 0x18, 0xda, 0x22, 0x4d, 0xb7, 0xb3, 0x25, - 0x3e, 0xeb, 0xbc, 0x3c, 0x17, 0xae, 0xb3, 0xd2, 0xfd, 0xdd, 0xf9, 0xf1, 0x7a, 0x1c, 0x84, 0x4e, - 0x8b, 0xf0, 0x02, 0x2c, 0xd0, 0xed, 0x1f, 0x5b, 0x30, 0x29, 0xf9, 0xc3, 0x62, 0xb3, 0x19, 0x92, - 0x28, 0x42, 0x73, 0x50, 0x72, 0xdb, 0x82, 0x10, 0x08, 0x42, 0xa5, 0xb5, 0x1a, 0x2e, 0xb9, 0x6d, - 0xf4, 0x06, 0x54, 0xf8, 0x4d, 0x5d, 0xb2, 0x38, 0xfa, 0xbc, 0xf9, 0x63, 0xba, 0xe1, 0xba, 0xa4, - 0x81, 0x13, 0x72, 0x52, 0x4a, 0x66, 0x27, 0x4f, 0xd9, 0xbc, 0x37, 0xba, 0x22, 0xca, 0xb1, 0xc2, - 0x40, 0x67, 0x61, 0xc4, 0x0f, 0x9a, 0xfc, 0x32, 0x95, 0xef, 0x53, 0xb6, 0xe4, 0x6e, 0x88, 0x32, - 0xac, 0xa0, 0xf6, 0x57, 0x2d, 0x18, 0x93, 0x63, 0x2c, 0x28, 0xb0, 0xd3, 0x4d, 0x92, 0x08, 0xeb, - 0xc9, 0x26, 0xa1, 0x02, 0x37, 0x83, 0x18, 0x72, 0x76, 0xb9, 0x1f, 0x39, 0xdb, 0xfe, 0xf5, 0x12, - 0x4c, 0xc8, 0xee, 0xd4, 0x3b, 0x77, 0x23, 0x42, 0xc5, 0x90, 0x8a, 0xc3, 0x27, 0x9f, 0xc8, 0x75, - 0xf6, 0x7c, 0x9e, 0x2e, 0x66, 0x7c, 0xb3, 0x44, 0xcc, 0x59, 0x94, 0x74, 0x70, 0x42, 0x12, 0x6d, - 0xc3, 0xb4, 0x1f, 0xc4, 0xec, 0x78, 0x53, 0xf0, 0x62, 0x37, 0x1d, 0xe9, 0x76, 0x1e, 0x15, 0xed, - 0x4c, 0xdf, 0x48, 0xd3, 0xc3, 0xdd, 0x4d, 0xa0, 0x9b, 0xd2, 0xc6, 0x54, 0x66, 0x6d, 0x3d, 0x5b, - 0xac, 0xad, 0xde, 0x26, 0x26, 0xfb, 0x77, 0x2c, 0xa8, 0x48, 0xb4, 0xe3, 0xb8, 0xf2, 0xba, 0x03, - 0xc3, 0x11, 0xfb, 0x44, 0x72, 0xba, 0xce, 0x15, 0x1b, 0x02, 0xff, 0xae, 0xc9, 0x99, 0xce, 0xff, - 0x47, 0x58, 0x52, 0x63, 0xc6, 0x76, 0x35, 0x90, 0xf7, 0x9d, 0xb1, 0x5d, 0xf5, 0xac, 0xf7, 0xcd, - 0xd6, 0xb8, 0x61, 0x0d, 0xa0, 0x82, 0x69, 0x3b, 0x24, 0x1b, 0xee, 0x83, 0xb4, 0x60, 0x5a, 0x63, - 0xa5, 0x58, 0x40, 0xd1, 0x06, 0x8c, 0x35, 0xa4, 0x39, 0x3a, 0x61, 0x21, 0x1f, 0x2e, 0x68, 0xfb, - 0x57, 0xd7, 0x48, 0xdc, 0x9b, 0x69, 0x59, 0xa3, 0x84, 0x0d, 0xba, 0x94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22, 0x11, 0xf9, 0x69, 0x57, 0x15, - 0x14, 0xa7, 0xb0, 0x35, 0x3e, 0x3e, 0x58, 0x58, 0x0a, 0xc9, 0x75, 0x42, 0xa7, 0x02, 0x56, 0x9b, - 0x8d, 0x2e, 0x62, 0x9e, 0x47, 0x42, 0xc0, 0xe2, 0x03, 0x8e, 0xb0, 0x84, 0xa1, 0xcb, 0x30, 0xdd, - 0xd8, 0x74, 0xda, 0x8b, 0x9d, 0x78, 0xb3, 0xea, 0x46, 0x8d, 0x60, 0x9b, 0x84, 0x3b, 0x4c, 0x00, - 0x1e, 0x49, 0x6c, 0x5a, 0x0a, 0xb0, 0x7c, 0x65, 0xb1, 0x46, 0x31, 0x71, 0x77, 0x1d, 0x53, 0x20, - 0x81, 0x23, 0x10, 0x48, 0x16, 0x61, 0x52, 0xb6, 0x5a, 0x27, 0x11, 0x3b, 0x22, 0x46, 0x59, 0x3f, - 0x55, 0xf8, 0x8f, 0x28, 0x56, 0xbd, 0x4c, 0xe3, 0xdb, 0xef, 0x40, 0x45, 0x79, 0xca, 0x49, 0x07, - 0x51, 0xab, 0x87, 0x83, 0x68, 0x3e, 0x73, 0x97, 0xb6, 0xf3, 0x72, 0xa6, 0xed, 0xfc, 0x9f, 0x5a, - 0x90, 0xb8, 0xfa, 0x20, 0x0c, 0x95, 0x76, 0xc0, 0xee, 0xd9, 0x42, 0x79, 0xa1, 0xfd, 0x54, 0xce, - 0x9e, 0xe7, 0x3c, 0x87, 0x4f, 0x48, 0x4d, 0xd6, 0xc5, 0x09, 0x19, 0x74, 0x0d, 0x86, 0xdb, 0x21, - 0xa9, 0xc7, 0x2c, 0xba, 0xa3, 0x0f, 0x8a, 0x7c, 0x21, 0xf0, 0x9a, 0x58, 0x92, 0xb0, 0xff, 0xa5, - 0x05, 0x70, 0xcd, 0xdd, 0x72, 0x63, 0xec, 0xf8, 0x2d, 0x72, 0x0c, 0x8a, 0xf5, 0x0d, 0x18, 0x88, - 0xda, 0xa4, 0x51, 0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0x1f, 0xeb, 0x91, 0x3a, 0xe7, 0xc3, 0x54, 0x7a, 0x53, 0x1e, 0xe9, 0x11, 0xfe, 0x93, 0x01, - 0x98, 0x30, 0x17, 0x07, 0x3a, 0x0f, 0x15, 0x41, 0x44, 0x25, 0x60, 0x53, 0x7b, 0xe0, 0xba, 0x04, - 0xe0, 0x04, 0x87, 0xa5, 0xa2, 0x63, 0xd5, 0x35, 0x07, 0xaf, 0x24, 0x15, 0x9d, 0x82, 0x60, 0x0d, - 0x8b, 0x4a, 0xc2, 0x77, 0x83, 0x20, 0x56, 0x27, 0x81, 0x5a, 0x37, 0x4b, 0xac, 0x14, 0x0b, 0x28, - 0x3d, 0x01, 0xee, 0xd1, 0x8f, 0xe9, 0x99, 0xe6, 0x4d, 0x75, 0x02, 0x5c, 0xd5, 0x81, 0xd8, 0xc4, - 0xa5, 0x27, 0x5a, 0x10, 0xb1, 0x85, 0x28, 0xe4, 0xed, 0xc4, 0x61, 0xae, 0xce, 0xa3, 0x29, 0x25, - 0x1c, 0x7d, 0x0a, 0x1e, 0x51, 0xc1, 0x8f, 0x98, 0x9b, 0x8b, 0x65, 0x8b, 0x43, 0x86, 0xca, 0xfc, - 0xc8, 0x72, 0x36, 0x1a, 0xee, 0x55, 0x1f, 0xbd, 0x0a, 0x13, 0x42, 0x56, 0x96, 0x14, 0x87, 0x4d, - 0xbf, 0x87, 0xab, 0x06, 0x14, 0xa7, 0xb0, 0x51, 0x15, 0xa6, 0x68, 0x09, 0x13, 0x52, 0x25, 0x05, - 0x1e, 0xc4, 0xa9, 0x8e, 0xfa, 0xab, 0x29, 0x38, 0xee, 0xaa, 0x81, 0x16, 0x61, 0x92, 0x0b, 0x2b, - 0x54, 0x31, 0x64, 0xdf, 0x41, 0xf8, 0xe6, 0xaa, 0x8d, 0x70, 0xd3, 0x04, 0xe3, 0x34, 0x3e, 0xba, - 0x04, 0x63, 0x4e, 0xd8, 0xd8, 0x74, 0x63, 0xd2, 0x88, 0x3b, 0x21, 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xb4, 0x30, 0x39, 0x31, 0xae, 0x9c, 0xd8, 0xc2, 0x03, 0xa3, 0xeb, 0xb8, 0xd6, - 0xd3, 0x85, 0x82, 0xbb, 0x1b, 0x43, 0x5f, 0xb5, 0x60, 0xc6, 0xb9, 0x1f, 0x75, 0x3d, 0xa1, 0x23, - 0x16, 0xd2, 0xab, 0x39, 0x66, 0xb9, 0x9c, 0xc7, 0x77, 0x96, 0x66, 0xf7, 0x76, 0xe7, 0x67, 0xb2, - 0xb0, 0x70, 0x66, 0xab, 0xf4, 0xfb, 0x6e, 0x8a, 0x70, 0x99, 0x62, 0x01, 0x9f, 0x59, 0xc1, 0x35, - 0x9c, 0xad, 0x49, 0x08, 0x56, 0x14, 0xd1, 0xdb, 0x50, 0x69, 0xc9, 0xc8, 0xb8, 0x34, 0xdb, 0xec, - 0x31, 0xcd, 0x59, 0x81, 0x74, 0x3c, 0x5c, 0x41, 0x81, 0x70, 0x42, 0x14, 0x5d, 0x81, 0xb2, 0xbf, - 0x11, 0x89, 0x18, 0xf4, 0x3c, 0x6f, 0x23, 0xd3, 0xc7, 0x8b, 0x87, 0xed, 0xde, 0x58, 0xad, 0x63, - 0x4a, 0x82, 0x52, 0x0a, 0xef, 0x36, 0x85, 0x3d, 0x3a, 0x87, 0x12, 0x5e, 0xaa, 0x76, 0x53, 0xc2, - 0x4b, 0x55, 0x4c, 0x49, 0xa0, 0x1a, 0x0c, 0xb2, 0x60, 0x1c, 0x61, 0x6c, 0xce, 0x49, 0x54, 0xd0, - 0x15, 0x72, 0xc4, 0xf3, 0x66, 0xb2, 0x62, 0xcc, 0x09, 0xa1, 0x75, 0x18, 0x6a, 0xb0, 0xa7, 0x1f, - 0x84, 0x15, 0x20, 0x2f, 0x85, 0x47, 0xd7, 0x33, 0x11, 0xfc, 0x86, 0x8d, 0x97, 0x63, 0x41, 0x8b, - 0x51, 0x25, 0xed, 0xcd, 0x8d, 0x48, 0xa8, 0xf9, 0x79, 0x54, 0xbb, 0x1e, 0x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 0x5e, 0x70, 0x3f, 0xfd, 0xed, 0x56, 0x59, 0x29, - 0x16, 0x50, 0x74, 0x0e, 0x46, 0xda, 0x21, 0xd9, 0x76, 0x83, 0x4e, 0x94, 0x8e, 0xc0, 0xac, 0x89, - 0x72, 0xac, 0x30, 0xd0, 0x8b, 0x30, 0x16, 0xb9, 0x7e, 0x83, 0x48, 0x47, 0x94, 0x01, 0xe6, 0x88, - 0xc2, 0x93, 0x87, 0x6a, 0xe5, 0xd8, 0xc0, 0x42, 0x77, 0xa0, 0xc2, 0xfe, 0xb3, 0x1d, 0xd4, 0xff, - 0xc3, 0x19, 0x3c, 0x41, 0x8d, 0x24, 0x80, 0x13, 0x5a, 0xe8, 0x22, 0x40, 0x2c, 0x5d, 0x66, 0x22, - 0x11, 0x2a, 0xac, 0xe4, 0x52, 0xe5, 0x4c, 0x13, 0x61, 0x0d, 0x0b, 0x3d, 0x07, 0x95, 0xd8, 0x71, - 0xbd, 0x6b, 0xae, 0x4f, 0x22, 0xe1, 0x72, 0x24, 0x12, 0x81, 0x8b, 0x42, 0x9c, 0xc0, 0xe9, 0x79, - 0xcf, 0x02, 0xd1, 0xf9, 0xa3, 0x3c, 0x23, 0x0c, 0x9b, 0x9d, 0xf7, 0xd7, 0x54, 0x29, 0xd6, 0x30, - 0xec, 0x4b, 0x70, 0xb2, 0x16, 0x34, 0x6b, 0x41, 0x18, 0xaf, 0x06, 0xe1, 0x7d, 0x27, 0x6c, 0xca, - 0xef, 0x37, 0x2f, 0xf3, 0x4f, 0xd3, 0x33, 0x79, 0x90, 0x6b, 0xf6, 0x46, 0x3e, 0xe9, 0x17, 0xd8, - 0x89, 0xdf, 0x67, 0xf8, 0xc8, 0x1f, 0x96, 0x01, 0xd5, 0x98, 0x53, 0x8f, 0xf1, 0x86, 0xd3, 0x26, - 0x4c, 0x44, 0xe4, 0x9a, 0xeb, 0x77, 0x1e, 0x08, 0x52, 0xc5, 0xe2, 0x75, 0xea, 0x2b, 0x7a, 0x1d, -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0x73, 0x36, 0x55, 0xfc, 0xc9, 0x4d, 0x8e, 0x6f, 0x38, 0xe8, - 0x0b, 0x12, 0x58, 0x23, 0x87, 0xae, 0xc1, 0xb8, 0x78, 0x01, 0x45, 0x18, 0x4b, 0xca, 0x86, 0xa2, - 0x3f, 0x8e, 0x75, 0xe0, 0x7e, 0xba, 0x00, 0x9b, 0x95, 0x51, 0x0b, 0x1e, 0xd7, 0x5e, 0xf8, 0xca, - 0x70, 0xc4, 0xe3, 0xfc, 0xef, 0x89, 0xbd, 0xdd, 0xf9, 0xc7, 0xd7, 0x0f, 0x42, 0xc4, 0x07, 0xd3, - 0x41, 0x37, 0xe1, 0xa4, 0xd3, 0x88, 0xdd, 0x6d, 0x52, 0x25, 0x4e, 0xd3, 0x73, 0x7d, 0x62, 0x26, - 0x50, 0x78, 0x74, 0x6f, 0x77, 0xfe, 0xe4, 0x62, 0x16, 0x02, 0xce, 0xae, 0x87, 0x3e, 0x0e, 0x95, - 0xa6, 0x1f, 0x89, 0x39, 0x18, 0x32, 0x1e, 0xb4, 0xab, 0x54, 0x6f, 0xd4, 0xd5, 0xf8, 0x93, 0x3f, - 0x38, 0xa9, 0x80, 0xde, 0x85, 0x31, 0x3d, 0x30, 0x4a, 0x3c, 0xa4, 0xf8, 0x72, 0x21, 0x2d, 0xde, - 0x88, 0x26, 0xe2, 0x76, 0x44, 0xe5, 0xf0, 0x6a, 0x04, 0x1a, 0x19, 0x4d, 0xa0, 0x4f, 0x02, 0x8a, - 0x48, 0xb8, 0xed, 0x36, 0xc8, 0x62, 0x83, 0xe5, 0xfd, 0x65, 0x96, 0xa6, 0x11, 0x23, 0xf2, 0x03, - 0xd5, 0xbb, 0x30, 0x70, 0x46, 0x2d, 0x74, 0x85, 0xf2, 0x3f, 0xbd, 0x54, 0xf8, 0x27, 0x4b, 0xf1, - 0x74, 0xb6, 0x4a, 0xda, 0x21, 0x69, 0x38, 0x31, 0x69, 0x9a, 0x14, 0x71, 0xaa, 0x1e, 0x3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0xc8, 0x36, 0x91, 0x46, 0x12, 0xc5, 0xc6, - 0xaf, 0xd1, 0x42, 0xcc, 0x61, 0xf6, 0x6f, 0x0c, 0xc0, 0x89, 0x8c, 0x38, 0x41, 0xaa, 0x21, 0xb5, - 0x9c, 0x98, 0xdc, 0x77, 0x76, 0xd2, 0x89, 0x71, 0x2f, 0xf3, 0x62, 0x2c, 0xe1, 0xcc, 0xa9, 0x96, - 0x27, 0xd7, 0x4b, 0x99, 0xae, 0x44, 0x4e, 0x3d, 0x01, 0x3d, 0xfa, 0x67, 0x89, 0x2f, 0x02, 0x44, - 0x91, 0xb7, 0xe2, 0x53, 0x09, 0xaf, 0x29, 0x9c, 0x77, 0x93, 0x9c, 0x8c, 0xf5, 0x6b, 0x02, 0x82, - 0x35, 0x2c, 0x54, 0x85, 0xa9, 0x76, 0x18, 0xc4, 0xdc, 0x30, 0x58, 0xe5, 0xae, 0x16, 0x83, 0x66, - 0xd4, 0x58, 0x2d, 0x05, 0xc7, 0x5d, 0x35, 0xd0, 0x4b, 0x30, 0x2a, 0x22, 0xc9, 0x6a, 0x41, 0xe0, - 0x09, 0x33, 0x92, 0xba, 0x8f, 0xaf, 0x27, 0x20, 0xac, 0xe3, 0x69, 0xd5, 0x98, 0xb5, 0x71, 0x38, - 0xb3, 0x1a, 0xb7, 0x38, 0x6a, 0x78, 0xa9, 0xcc, 0x27, 0x23, 0x85, 0x32, 0x9f, 0x24, 0x86, 0xb5, - 0x4a, 0xe1, 0x8b, 0x18, 0xc8, 0x35, 0x40, 0xfd, 0x5e, 0x19, 0x86, 0xf8, 0xa7, 0x38, 0x06, 0x29, - 0xaf, 0x26, 0x4c, 0x4a, 0x85, 0xb2, 0x4c, 0xf0, 0x5e, 0x2d, 0x54, 0x9d, 0xd8, 0xe1, 0xac, 0x49, - 0xed, 0x90, 0xc4, 0x0c, 0x85, 0x16, 0x8c, 0x3d, 0x34, 0x97, 0xb2, 0x94, 0x00, 0xa7, 0xa1, 0xed, - 0xa8, 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 0x1c, - 0xed, 0xcf, 0x15, 0x47, 0x31, 0xb3, 0x75, 0x49, 0x04, 0x27, 0xf4, 0xec, 0xaf, 0x95, 0x00, 0x92, - 0xb8, 0xa6, 0xbc, 0x61, 0x2e, 0x75, 0x3d, 0x3f, 0xf7, 0x74, 0xc6, 0xf3, 0x73, 0x28, 0x21, 0x98, - 0xf1, 0xf8, 0x9c, 0x9a, 0xaa, 0x72, 0xa1, 0xa9, 0x1a, 0xe8, 0x67, 0xaa, 0x96, 0x61, 0x3a, 0x89, - 0xcb, 0x32, 0x03, 0x5c, 0x59, 0x8a, 0xd8, 0xf5, 0x34, 0x10, 0x77, 0xe3, 0xdb, 0x5f, 0xb3, 0x40, - 0x38, 0x6f, 0x16, 0x58, 0xd0, 0x4d, 0xf9, 0x54, 0x94, 0x91, 0x79, 0xee, 0xd9, 0x22, 0x7e, 0xad, - 0x22, 0xdf, 0x9c, 0xda, 0x62, 0x46, 0x96, 0x39, 0x83, 0xaa, 0xfd, 0xeb, 0x16, 0x8c, 0x72, 0xf0, - 0x75, 0x26, 0xf3, 0xe7, 0xf7, 0xab, 0xaf, 0xfc, 0xc3, 0xec, 0x15, 0x25, 0x4a, 0x58, 0xe5, 0xa1, - 0xd5, 0x5f, 0x51, 0x92, 0x00, 0x9c, 0xe0, 0xa0, 0x67, 0x60, 0x38, 0xea, 0xdc, 0x65, 0xe8, 0x29, - 0x4f, 0xce, 0x3a, 0x2f, 0xc6, 0x12, 0x6e, 0xff, 0xb3, 0x12, 0x4c, 0xa5, 0x1d, 0x79, 0x11, 0x86, - 0x21, 0xae, 0x03, 0xa4, 0xc5, 0xc7, 0x83, 0xec, 0x52, 0x9a, 0x23, 0x30, 0xf0, 0xb7, 0xc0, 0xd9, - 0x05, 0x82, 0xa0, 0x84, 0x36, 0x60, 0xb4, 0x19, 0xdc, 0xf7, 0xef, 0x3b, 0x61, 0x73, 0xb1, 0xb6, - 0x26, 0xbe, 0x44, 0x8e, 0xeb, 0x55, 0x35, 0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d, 0xef, 0x72, 0xc4, 0x5e, 0x2a, 0x3e, 0x62, 0xda, 0xe7, 0x2e, 0x4c, + 0x8b, 0xde, 0x4f, 0xac, 0xa6, 0xc8, 0xe2, 0x8e, 0x86, 0xec, 0x7f, 0x54, 0xe2, 0x7b, 0x96, 0xc9, + 0x70, 0xcf, 0xc0, 0x60, 0x2b, 0x70, 0x17, 0x57, 0xaa, 0x58, 0x8c, 0x95, 0x62, 0x3a, 0x35, 0x5e, + 0x8c, 0x25, 0x1c, 0x5d, 0x04, 0x20, 0xf7, 0x63, 0x12, 0xfa, 0x4e, 0x53, 0x5d, 0xe9, 0x2b, 0x51, + 0x69, 0x49, 0x41, 0xb0, 0x86, 0x45, 0xeb, 0xb4, 0xc2, 0x60, 0xdb, 0x73, 0x59, 0x9c, 0x4b, 0xd9, + 0xac, 0x53, 0x53, 0x10, 0xac, 0x61, 0x51, 0x05, 0xba, 0xed, 0x47, 0xfc, 0x18, 0x73, 0xee, 0x88, + 0x4c, 0x4a, 0x43, 0x89, 0x02, 0x7d, 0x53, 0x07, 0x62, 0x13, 0x17, 0x5d, 0x85, 0x81, 0xd8, 0x61, + 0x17, 0xd5, 0xfd, 0x45, 0xbc, 0x7e, 0xd6, 0x28, 0xae, 0x9e, 0xba, 0x8a, 0x56, 0xc5, 0x82, 0x84, + 0xfd, 0x9f, 0x2a, 0x00, 0x89, 0xd4, 0x85, 0xbe, 0xd8, 0xb9, 0xe1, 0x3f, 0x52, 0x54, 0x64, 0x7b, + 0x70, 0xbb, 0x1d, 0x7d, 0xcd, 0x82, 0x61, 0xa7, 0xd9, 0x0c, 0x1a, 0x4e, 0xcc, 0x86, 0xa7, 0x54, + 0x94, 0xf5, 0x88, 0x9e, 0xcc, 0x27, 0x75, 0x79, 0x67, 0x5e, 0x90, 0x97, 0xc7, 0x1a, 0x24, 0xb7, + 0x3f, 0x7a, 0x17, 0xd0, 0x87, 0xa5, 0xd4, 0xce, 0x67, 0x78, 0x26, 0x2d, 0xb5, 0x57, 0x18, 0xc3, + 0xd5, 0x04, 0x76, 0xf4, 0x96, 0x91, 0x79, 0xa8, 0xaf, 0x48, 0xb0, 0xb2, 0x21, 0x87, 0xe4, 0x25, + 0x1d, 0x42, 0x6f, 0xe8, 0xee, 0xf1, 0xfd, 0x45, 0xb2, 0x01, 0x68, 0xe2, 0x70, 0x8e, 0x6b, 0x7c, + 0x0c, 0xe3, 0xae, 0x79, 0xf2, 0x0a, 0x17, 0xbf, 0x0b, 0xf9, 0x2d, 0xa4, 0x8e, 0xec, 0xe4, 0xac, + 0x4d, 0x01, 0x70, 0xba, 0x09, 0xf4, 0x06, 0x0f, 0x5e, 0x58, 0xf1, 0xd7, 0x03, 0xe1, 0xe6, 0x77, + 0xae, 0xc0, 0x9c, 0xef, 0x44, 0x31, 0xd9, 0xa2, 0x75, 0x92, 0xc3, 0xf5, 0xba, 0xa0, 0x82, 0x15, + 0x3d, 0xb4, 0x06, 0x03, 0x2c, 0x36, 0x2d, 0x9a, 0x1e, 0x2a, 0x62, 0x12, 0x34, 0x43, 0xb2, 0x93, + 0xfd, 0xc3, 0xfe, 0x46, 0x58, 0xd0, 0x42, 0x57, 0x64, 0x52, 0x86, 0x68, 0xc5, 0xbf, 0x19, 0x11, + 0x96, 0x94, 0xa1, 0xb2, 0xf0, 0xa1, 0x24, 0xcb, 0x02, 0x2f, 0xcf, 0x4c, 0xd7, 0x68, 0xd4, 0xa4, + 0x82, 0x8d, 0xf8, 0x2f, 0xb3, 0x40, 0x4e, 0x43, 0x91, 0x8e, 0x9a, 0x39, 0x23, 0x93, 0xc1, 0xbe, + 0x65, 0x12, 0xc3, 0x69, 0xea, 0xc7, 0x7a, 0xa4, 0xce, 0xf8, 0x30, 0x91, 0xde, 0x94, 0x47, 0x7a, + 0x84, 0xff, 0xa4, 0x0f, 0xc6, 0xcc, 0xc5, 0x81, 0xce, 0x43, 0x45, 0x10, 0x51, 0x29, 0xde, 0xd4, + 0x1e, 0x58, 0x95, 0x00, 0x9c, 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xac, 0x5a, + 0x38, 0x4e, 0xde, 0x48, 0x07, 0xaa, 0x7a, 0x9d, 0x02, 0xe0, 0x34, 0xf9, 0x85, 0x0f, 0xfd, 0xe8, + 0xc7, 0xa7, 0x3f, 0xf0, 0xfb, 0x3f, 0x3e, 0xfd, 0x81, 0x3f, 0xfe, 0xf1, 0xe9, 0x0f, 0xfc, 0xfc, + 0xde, 0x69, 0xeb, 0x47, 0x7b, 0xa7, 0xad, 0xdf, 0xdf, 0x3b, 0x6d, 0xfd, 0xf9, 0xde, 0x69, 0xeb, + 0x6b, 0x3f, 0x39, 0xfd, 0x81, 0x37, 0x4a, 0xdb, 0x17, 0xfe, 0x5f, 0x00, 0x00, 0x00, 0xff, 0xff, + 0x8d, 0xa0, 0x5a, 0x64, 0xe6, 0xcd, 0x00, 0x00, } diff --git a/pkg/api/v1/generated.proto b/pkg/api/v1/generated.proto index a1e069f916733..e76c7c4b63c4e 100644 --- a/pkg/api/v1/generated.proto +++ b/pkg/api/v1/generated.proto @@ -26,7 +26,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1"; @@ -762,6 +761,15 @@ message EmptyDirVolumeSource { // More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir // +optional optional string medium = 1; + + // Total amount of local storage required for this EmptyDir volume. + // The size limit is also applicable for memory medium. + // The maximum usage on memory medium EmptyDir would be the minimum value between + // the SizeLimit specified here and the sum of memory limits of all containers in a pod. + // The default is nil which means that the limit is undefined. + // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir + // +optional + optional k8s.io.apimachinery.pkg.api.resource.Quantity sizeLimit = 2; } // EndpointAddress is a tuple that describes single IP address. diff --git a/pkg/api/v1/helper/helpers.go b/pkg/api/v1/helper/helpers.go index 9a8caad82f2d7..6b51c5c8364b7 100644 --- a/pkg/api/v1/helper/helpers.go +++ b/pkg/api/v1/helper/helpers.go @@ -517,6 +517,10 @@ func GetStorageNodeAffinityFromAnnotation(annotations map[string]string) (*v1.No // Converts NodeAffinity type to Alpha annotation for use in PersistentVolumes // TODO: update when storage node affinity graduates to beta func StorageNodeAffinityToAlphaAnnotation(annotations map[string]string, affinity *v1.NodeAffinity) error { + if affinity == nil { + return nil + } + json, err := json.Marshal(*affinity) if err != nil { return err diff --git a/pkg/api/v1/pod/util.go b/pkg/api/v1/pod/util.go index 3aadefdb54651..9734ad98f7d74 100644 --- a/pkg/api/v1/pod/util.go +++ b/pkg/api/v1/pod/util.go @@ -197,6 +197,60 @@ func visitContainerSecretNames(container *v1.Container, visitor Visitor) bool { return true } +// VisitPodConfigmapNames invokes the visitor function with the name of every configmap +// referenced by the pod spec. If visitor returns false, visiting is short-circuited. +// Transitive references (e.g. pod -> pvc -> pv -> secret) are not visited. +// Returns true if visiting completed, false if visiting was short-circuited. +func VisitPodConfigmapNames(pod *v1.Pod, visitor Visitor) bool { + for i := range pod.Spec.InitContainers { + if !visitContainerConfigmapNames(&pod.Spec.InitContainers[i], visitor) { + return false + } + } + for i := range pod.Spec.Containers { + if !visitContainerConfigmapNames(&pod.Spec.Containers[i], visitor) { + return false + } + } + var source *v1.VolumeSource + for i := range pod.Spec.Volumes { + source = &pod.Spec.Volumes[i].VolumeSource + switch { + case source.Projected != nil: + for j := range source.Projected.Sources { + if source.Projected.Sources[j].ConfigMap != nil { + if !visitor(source.Projected.Sources[j].ConfigMap.Name) { + return false + } + } + } + case source.ConfigMap != nil: + if !visitor(source.ConfigMap.Name) { + return false + } + } + } + return true +} + +func visitContainerConfigmapNames(container *v1.Container, visitor Visitor) bool { + for _, env := range container.EnvFrom { + if env.ConfigMapRef != nil { + if !visitor(env.ConfigMapRef.Name) { + return false + } + } + } + for _, envVar := range container.Env { + if envVar.ValueFrom != nil && envVar.ValueFrom.ConfigMapKeyRef != nil { + if !visitor(envVar.ValueFrom.ConfigMapKeyRef.Name) { + return false + } + } + } + return true +} + // GetContainerStatus extracts the status of container "name" from "statuses". // It also returns if "name" exists. func GetContainerStatus(statuses []v1.ContainerStatus, name string) (v1.ContainerStatus, bool) { diff --git a/pkg/api/v1/types.generated.go b/pkg/api/v1/types.generated.go index a0fa0cf225dc6..333b12aceced0 100644 --- a/pkg/api/v1/types.generated.go +++ b/pkg/api/v1/types.generated.go @@ -11220,13 +11220,14 @@ func (x *EmptyDirVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } else { yysep2 := !z.EncBinary() yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [1]bool + var yyq2 [2]bool _, _, _ = yysep2, yyq2, yy2arr2 const yyr2 bool = false yyq2[0] = x.Medium != "" + yyq2[1] = true var yynn2 int if yyr2 || yy2arr2 { - r.EncodeArrayStart(1) + r.EncodeArrayStart(2) } else { yynn2 = 0 for _, b := range yyq2 { @@ -11252,6 +11253,39 @@ func (x *EmptyDirVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { x.Medium.CodecEncodeSelf(e) } } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yy7 := &x.SizeLimit + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(yy7) { + } else if !yym8 && z.IsJSONHandle() { + z.EncJSONMarshal(yy7) + } else { + z.EncFallback(yy7) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("sizeLimit")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy9 := &x.SizeLimit + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(yy9) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(yy9) + } else { + z.EncFallback(yy9) + } + } + } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { @@ -11320,6 +11354,21 @@ func (x *EmptyDirVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decode yyv4 := &x.Medium yyv4.CodecDecodeSelf(d) } + case "sizeLimit": + if r.TryDecodeAsNil() { + x.SizeLimit = pkg3_resource.Quantity{} + } else { + yyv5 := &x.SizeLimit + yym6 := z.DecBinary() + _ = yym6 + if false { + } else if z.HasExtensions() && z.DecExt(yyv5) { + } else if !yym6 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv5) + } else { + z.DecFallback(yyv5, false) + } + } default: z.DecStructFieldNotFound(-1, yys3) } // end switch yys3 @@ -11331,16 +11380,16 @@ func (x *EmptyDirVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj5 int - var yyb5 bool - var yyhl5 bool = l >= 0 - yyj5++ - if yyhl5 { - yyb5 = yyj5 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb5 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb5 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11348,21 +11397,46 @@ func (x *EmptyDirVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Medium = "" } else { - yyv6 := &x.Medium - yyv6.CodecDecodeSelf(d) + yyv8 := &x.Medium + yyv8.CodecDecodeSelf(d) + } + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.SizeLimit = pkg3_resource.Quantity{} + } else { + yyv9 := &x.SizeLimit + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(yyv9) { + } else if !yym10 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv9) + } else { + z.DecFallback(yyv9, false) + } } for { - yyj5++ - if yyhl5 { - yyb5 = yyj5 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb5 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb5 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj5-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } diff --git a/pkg/api/v1/types.go b/pkg/api/v1/types.go index b8e787091e120..93caed774e422 100644 --- a/pkg/api/v1/types.go +++ b/pkg/api/v1/types.go @@ -686,6 +686,14 @@ type EmptyDirVolumeSource struct { // More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir // +optional Medium StorageMedium `json:"medium,omitempty" protobuf:"bytes,1,opt,name=medium,casttype=StorageMedium"` + // Total amount of local storage required for this EmptyDir volume. + // The size limit is also applicable for memory medium. + // The maximum usage on memory medium EmptyDir would be the minimum value between + // the SizeLimit specified here and the sum of memory limits of all containers in a pod. + // The default is nil which means that the limit is undefined. + // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir + // +optional + SizeLimit resource.Quantity `json:"sizeLimit,omitempty" protobuf:"bytes,2,opt,name=sizeLimit"` } // Represents a Glusterfs mount that lasts the lifetime of a pod. @@ -3455,6 +3463,12 @@ const ( ResourceMemory ResourceName = "memory" // Volume size, in bytes (e,g. 5Gi = 5GiB = 5 * 1024 * 1024 * 1024) ResourceStorage ResourceName = "storage" + // Local Storage for container overlay filesystem, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024) + // The resource name for ResourceStorageOverlay is alpha and it can change across releases. + ResourceStorageOverlay ResourceName = "storage.kubernetes.io/overlay" + // Local Storage for scratch space, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024) + // The resource name for ResourceStorageScratch is alpha and it can change across releases. + ResourceStorageScratch ResourceName = "storage.kubernetes.io/scratch" // NVIDIA GPU, in devices. Alpha, might change: although fractional and allowing values >1, only one whole device per node is assigned. ResourceNvidiaGPU ResourceName = "alpha.kubernetes.io/nvidia-gpu" // Number of Pods that may be running on this Node: see ResourcePods diff --git a/pkg/api/v1/types_swagger_doc_generated.go b/pkg/api/v1/types_swagger_doc_generated.go index 3ffc43306702d..7b2a450245783 100644 --- a/pkg/api/v1/types_swagger_doc_generated.go +++ b/pkg/api/v1/types_swagger_doc_generated.go @@ -396,8 +396,9 @@ func (DownwardAPIVolumeSource) SwaggerDoc() map[string]string { } var map_EmptyDirVolumeSource = map[string]string{ - "": "Represents an empty directory for a pod. Empty directory volumes support ownership management and SELinux relabeling.", - "medium": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", + "": "Represents an empty directory for a pod. Empty directory volumes support ownership management and SELinux relabeling.", + "medium": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", + "sizeLimit": "Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir", } func (EmptyDirVolumeSource) SwaggerDoc() map[string]string { diff --git a/pkg/api/v1/zz_generated.conversion.go b/pkg/api/v1/zz_generated.conversion.go index 7546d39f4f488..80f398293c90a 100644 --- a/pkg/api/v1/zz_generated.conversion.go +++ b/pkg/api/v1/zz_generated.conversion.go @@ -1236,6 +1236,7 @@ func Convert_api_DownwardAPIVolumeSource_To_v1_DownwardAPIVolumeSource(in *api.D func autoConvert_v1_EmptyDirVolumeSource_To_api_EmptyDirVolumeSource(in *EmptyDirVolumeSource, out *api.EmptyDirVolumeSource, s conversion.Scope) error { out.Medium = api.StorageMedium(in.Medium) + out.SizeLimit = in.SizeLimit return nil } @@ -1246,6 +1247,7 @@ func Convert_v1_EmptyDirVolumeSource_To_api_EmptyDirVolumeSource(in *EmptyDirVol func autoConvert_api_EmptyDirVolumeSource_To_v1_EmptyDirVolumeSource(in *api.EmptyDirVolumeSource, out *EmptyDirVolumeSource, s conversion.Scope) error { out.Medium = StorageMedium(in.Medium) + out.SizeLimit = in.SizeLimit return nil } diff --git a/pkg/api/v1/zz_generated.deepcopy.go b/pkg/api/v1/zz_generated.deepcopy.go index f6d5d9b4acd27..4f69f1f510809 100644 --- a/pkg/api/v1/zz_generated.deepcopy.go +++ b/pkg/api/v1/zz_generated.deepcopy.go @@ -856,6 +856,7 @@ func DeepCopy_v1_EmptyDirVolumeSource(in interface{}, out interface{}, c *conver in := in.(*EmptyDirVolumeSource) out := out.(*EmptyDirVolumeSource) *out = *in + out.SizeLimit = in.SizeLimit.DeepCopy() return nil } } @@ -3549,7 +3550,9 @@ func DeepCopy_v1_VolumeSource(in interface{}, out interface{}, c *conversion.Clo if in.EmptyDir != nil { in, out := &in.EmptyDir, &out.EmptyDir *out = new(EmptyDirVolumeSource) - **out = **in + if err := DeepCopy_v1_EmptyDirVolumeSource(*in, *out, c); err != nil { + return err + } } if in.GCEPersistentDisk != nil { in, out := &in.GCEPersistentDisk, &out.GCEPersistentDisk diff --git a/pkg/api/validation/validation.go b/pkg/api/validation/validation.go index 9f4b585018fdd..f35516b29e49c 100644 --- a/pkg/api/validation/validation.go +++ b/pkg/api/validation/validation.go @@ -29,6 +29,8 @@ import ( "github.com/golang/glog" + "math" + apiequality "k8s.io/apimachinery/pkg/api/equality" "k8s.io/apimachinery/pkg/api/resource" apimachineryvalidation "k8s.io/apimachinery/pkg/api/validation" @@ -396,7 +398,12 @@ func validateVolumeSource(source *api.VolumeSource, fldPath *field.Path) field.E allErrs := field.ErrorList{} if source.EmptyDir != nil { numVolumes++ - // EmptyDirs have nothing to validate + if !utilfeature.DefaultFeatureGate.Enabled(features.LocalStorageCapacityIsolation) { + unsetSizeLimit := resource.Quantity{} + if unsetSizeLimit.Cmp(source.EmptyDir.SizeLimit) != 0 { + allErrs = append(allErrs, field.Forbidden(fldPath.Child("emptyDir").Child("sizeLimit"), "SizeLimit field disabled by feature-gate for EmptyDir volumes")) + } + } } if source.HostPath != nil { if numVolumes > 0 { @@ -1393,7 +1400,7 @@ func ValidatePersistentVolumeClaimSpec(spec *api.PersistentVolumeClaimSpec, fldP return allErrs } -// ValidatePersistentVolumeClaimUpdate validates an update to a PeristentVolumeClaim +// ValidatePersistentVolumeClaimUpdate validates an update to a PersistentVolumeClaim func ValidatePersistentVolumeClaimUpdate(newPvc, oldPvc *api.PersistentVolumeClaim) field.ErrorList { allErrs := ValidateObjectMetaUpdate(&newPvc.ObjectMeta, &oldPvc.ObjectMeta, field.NewPath("metadata")) allErrs = append(allErrs, ValidatePersistentVolumeClaim(newPvc)...) @@ -1419,7 +1426,7 @@ func ValidatePersistentVolumeClaimUpdate(newPvc, oldPvc *api.PersistentVolumeCla return allErrs } -// ValidatePersistentVolumeClaimStatusUpdate validates an update to status of a PeristentVolumeClaim +// ValidatePersistentVolumeClaimStatusUpdate validates an update to status of a PersistentVolumeClaim func ValidatePersistentVolumeClaimStatusUpdate(newPvc, oldPvc *api.PersistentVolumeClaim) field.ErrorList { allErrs := ValidateObjectMetaUpdate(&newPvc.ObjectMeta, &oldPvc.ObjectMeta, field.NewPath("metadata")) if len(newPvc.ResourceVersion) == 0 { @@ -2188,8 +2195,11 @@ func ValidatePodSpec(spec *api.PodSpec, fldPath *field.Path) field.ErrorList { } if spec.ActiveDeadlineSeconds != nil { - if *spec.ActiveDeadlineSeconds <= 0 { - allErrs = append(allErrs, field.Invalid(fldPath.Child("activeDeadlineSeconds"), spec.ActiveDeadlineSeconds, "must be greater than 0")) + if spec.ActiveDeadlineSeconds != nil { + value := *spec.ActiveDeadlineSeconds + if value < 1 || value > math.MaxUint32 { + allErrs = append(allErrs, field.Invalid(fldPath.Child("activeDeadlineSeconds"), value, validation.InclusiveRangeError(1, math.MaxUint32))) + } } } @@ -2575,8 +2585,8 @@ func ValidatePodUpdate(newPod, oldPod *api.Pod) field.ErrorList { // 2. from a positive value to a lesser, non-negative value if newPod.Spec.ActiveDeadlineSeconds != nil { newActiveDeadlineSeconds := *newPod.Spec.ActiveDeadlineSeconds - if newActiveDeadlineSeconds < 0 { - allErrs = append(allErrs, field.Invalid(specPath.Child("activeDeadlineSeconds"), newActiveDeadlineSeconds, isNegativeErrorMsg)) + if newActiveDeadlineSeconds < 0 || newActiveDeadlineSeconds > math.MaxUint32 { + allErrs = append(allErrs, field.Invalid(specPath.Child("activeDeadlineSeconds"), newActiveDeadlineSeconds, validation.InclusiveRangeError(0, math.MaxUint32))) return allErrs } if oldPod.Spec.ActiveDeadlineSeconds != nil { @@ -3633,6 +3643,9 @@ func ValidateResourceRequirements(requirements *api.ResourceRequirements, fldPat allErrs = append(allErrs, field.Invalid(limPath, quantity.String(), fmt.Sprintf("must be greater than or equal to %s request", resourceName))) } } + if resourceName == api.ResourceStorageOverlay && !utilfeature.DefaultFeatureGate.Enabled(features.LocalStorageCapacityIsolation) { + allErrs = append(allErrs, field.Forbidden(limPath, "ResourceStorageOverlay field disabled by feature-gate for ResourceRequirements")) + } } for resourceName, quantity := range requirements.Requests { fldPath := reqPath.Key(string(resourceName)) diff --git a/pkg/api/validation/validation_test.go b/pkg/api/validation/validation_test.go index 315ef4886be1e..9b03fd1534727 100644 --- a/pkg/api/validation/validation_test.go +++ b/pkg/api/validation/validation_test.go @@ -17,6 +17,7 @@ limitations under the License. package validation import ( + "math" "reflect" "strings" "testing" @@ -897,6 +898,98 @@ func TestValidateKeyToPath(t *testing.T) { } } +func TestValidateNFSVolumeSource(t *testing.T) { + testCases := []struct { + name string + nfs *api.NFSVolumeSource + errtype field.ErrorType + errfield string + errdetail string + }{ + { + name: "missing server", + nfs: &api.NFSVolumeSource{Server: "", Path: "/tmp"}, + errtype: field.ErrorTypeRequired, + errfield: "server", + }, + { + name: "missing path", + nfs: &api.NFSVolumeSource{Server: "my-server", Path: ""}, + errtype: field.ErrorTypeRequired, + errfield: "path", + }, + { + name: "abs path", + nfs: &api.NFSVolumeSource{Server: "my-server", Path: "tmp"}, + errtype: field.ErrorTypeInvalid, + errfield: "path", + errdetail: "must be an absolute path", + }, + } + + for i, tc := range testCases { + errs := validateNFSVolumeSource(tc.nfs, field.NewPath("field")) + + if len(errs) > 0 && tc.errtype == "" { + t.Errorf("[%d: %q] unexpected error(s): %v", i, tc.name, errs) + } else if len(errs) == 0 && tc.errtype != "" { + t.Errorf("[%d: %q] expected error type %v", i, tc.name, tc.errtype) + } else if len(errs) >= 1 { + if errs[0].Type != tc.errtype { + t.Errorf("[%d: %q] expected error type %v, got %v", i, tc.name, tc.errtype, errs[0].Type) + } else if !strings.HasSuffix(errs[0].Field, "."+tc.errfield) { + t.Errorf("[%d: %q] expected error on field %q, got %q", i, tc.name, tc.errfield, errs[0].Field) + } else if !strings.Contains(errs[0].Detail, tc.errdetail) { + t.Errorf("[%d: %q] expected error detail %q, got %q", i, tc.name, tc.errdetail, errs[0].Detail) + } + } + } +} + +func TestValidateGlusterfs(t *testing.T) { + testCases := []struct { + name string + gfs *api.GlusterfsVolumeSource + errtype field.ErrorType + errfield string + }{ + { + name: "missing endpointname", + gfs: &api.GlusterfsVolumeSource{EndpointsName: "", Path: "/tmp"}, + errtype: field.ErrorTypeRequired, + errfield: "endpoints", + }, + { + name: "missing path", + gfs: &api.GlusterfsVolumeSource{EndpointsName: "my-endpoint", Path: ""}, + errtype: field.ErrorTypeRequired, + errfield: "path", + }, + { + name: "missing endpintname and path", + gfs: &api.GlusterfsVolumeSource{EndpointsName: "", Path: ""}, + errtype: field.ErrorTypeRequired, + errfield: "endpoints", + }, + } + + for i, tc := range testCases { + errs := validateGlusterfs(tc.gfs, field.NewPath("field")) + + if len(errs) > 0 && tc.errtype == "" { + t.Errorf("[%d: %q] unexpected error(s): %v", i, tc.name, errs) + } else if len(errs) == 0 && tc.errtype != "" { + t.Errorf("[%d: %q] expected error type %v", i, tc.name, tc.errtype) + } else if len(errs) >= 1 { + if errs[0].Type != tc.errtype { + t.Errorf("[%d: %q] expected error type %v, got %v", i, tc.name, tc.errtype, errs[0].Type) + } else if !strings.HasSuffix(errs[0].Field, "."+tc.errfield) { + t.Errorf("[%d: %q] expected error on field %q, got %q", i, tc.name, tc.errfield, errs[0].Field) + } + } + } +} + // helper func newInt32(val int) *int32 { p := new(int32) @@ -2281,6 +2374,62 @@ func TestValidateVolumes(t *testing.T) { } } +func TestAlphaLocalStorageCapacityIsolation(t *testing.T) { + + testCases := []api.VolumeSource{ + {EmptyDir: &api.EmptyDirVolumeSource{SizeLimit: *resource.NewQuantity(int64(5), resource.BinarySI)}}, + } + // Enable alpha feature LocalStorageCapacityIsolation + err := utilfeature.DefaultFeatureGate.Set("LocalStorageCapacityIsolation=true") + if err != nil { + t.Errorf("Failed to enable feature gate for LocalStorageCapacityIsolation: %v", err) + return + } + for _, tc := range testCases { + if errs := validateVolumeSource(&tc, field.NewPath("spec")); len(errs) != 0 { + t.Errorf("expected success: %v", errs) + } + } + // Disable alpha feature LocalStorageCapacityIsolation + err = utilfeature.DefaultFeatureGate.Set("LocalStorageCapacityIsolation=false") + if err != nil { + t.Errorf("Failed to disable feature gate for LocalStorageCapacityIsolation: %v", err) + return + } + for _, tc := range testCases { + if errs := validateVolumeSource(&tc, field.NewPath("spec")); len(errs) == 0 { + t.Errorf("expected failure: %v", errs) + } + } + + containerLimitCase := api.ResourceRequirements{ + Limits: api.ResourceList{ + api.ResourceStorageOverlay: *resource.NewMilliQuantity( + int64(40000), + resource.BinarySI), + }, + } + // Enable alpha feature LocalStorageCapacityIsolation + err = utilfeature.DefaultFeatureGate.Set("LocalStorageCapacityIsolation=true") + if err != nil { + t.Errorf("Failed to enable feature gate for LocalStorageCapacityIsolation: %v", err) + return + } + if errs := ValidateResourceRequirements(&containerLimitCase, field.NewPath("resources")); len(errs) != 0 { + t.Errorf("expected success: %v", errs) + } + // Disable alpha feature LocalStorageCapacityIsolation + err = utilfeature.DefaultFeatureGate.Set("LocalStorageCapacityIsolation=false") + if err != nil { + t.Errorf("Failed to disable feature gate for LocalStorageCapacityIsolation: %v", err) + return + } + if errs := ValidateResourceRequirements(&containerLimitCase, field.NewPath("resources")); len(errs) == 0 { + t.Errorf("expected failure: %v", errs) + } + +} + func TestValidatePorts(t *testing.T) { successCase := []api.ContainerPort{ {Name: "abc", ContainerPort: 80, HostPort: 80, Protocol: "TCP"}, @@ -3350,6 +3499,7 @@ func TestValidateDNSPolicy(t *testing.T) { func TestValidatePodSpec(t *testing.T) { activeDeadlineSeconds := int64(30) + activeDeadlineSecondsMax := int64(math.MaxUint32) minUserID := types.UnixUserID(0) maxUserID := types.UnixUserID(2147483647) @@ -3378,6 +3528,21 @@ func TestValidatePodSpec(t *testing.T) { ActiveDeadlineSeconds: &activeDeadlineSeconds, ServiceAccountName: "acct", }, + { // Populate all fields with larger active deadline. + Volumes: []api.Volume{ + {Name: "vol", VolumeSource: api.VolumeSource{EmptyDir: &api.EmptyDirVolumeSource{}}}, + }, + Containers: []api.Container{{Name: "ctr", Image: "image", ImagePullPolicy: "IfNotPresent", TerminationMessagePolicy: "File"}}, + InitContainers: []api.Container{{Name: "ictr", Image: "iimage", ImagePullPolicy: "IfNotPresent", TerminationMessagePolicy: "File"}}, + RestartPolicy: api.RestartPolicyAlways, + NodeSelector: map[string]string{ + "key": "value", + }, + NodeName: "foobar", + DNSPolicy: api.DNSClusterFirst, + ActiveDeadlineSeconds: &activeDeadlineSecondsMax, + ServiceAccountName: "acct", + }, { // Populate HostNetwork. Containers: []api.Container{ {Name: "ctr", Image: "image", ImagePullPolicy: "IfNotPresent", TerminationMessagePolicy: "File", @@ -3450,6 +3615,7 @@ func TestValidatePodSpec(t *testing.T) { } activeDeadlineSeconds = int64(0) + activeDeadlineSecondsTooLarge := int64(math.MaxUint32 + 1) minUserID = types.UnixUserID(-1) maxUserID = types.UnixUserID(2147483648) @@ -3591,6 +3757,19 @@ func TestValidatePodSpec(t *testing.T) { DNSPolicy: api.DNSClusterFirst, ActiveDeadlineSeconds: &activeDeadlineSeconds, }, + "active-deadline-seconds-too-large": { + Volumes: []api.Volume{ + {Name: "vol", VolumeSource: api.VolumeSource{EmptyDir: &api.EmptyDirVolumeSource{}}}, + }, + Containers: []api.Container{{Name: "ctr", Image: "image", ImagePullPolicy: "IfNotPresent", TerminationMessagePolicy: "File"}}, + RestartPolicy: api.RestartPolicyAlways, + NodeSelector: map[string]string{ + "key": "value", + }, + NodeName: "foobar", + DNSPolicy: api.DNSClusterFirst, + ActiveDeadlineSeconds: &activeDeadlineSecondsTooLarge, + }, "bad nodeName": { NodeName: "node name", Volumes: []api.Volume{{Name: "vol", VolumeSource: api.VolumeSource{EmptyDir: &api.EmptyDirVolumeSource{}}}}, @@ -9217,7 +9396,7 @@ func TestValidateEndpoints(t *testing.T) { func TestValidateTLSSecret(t *testing.T) { successCases := map[string]api.Secret{ - "emtpy certificate chain": { + "empty certificate chain": { ObjectMeta: metav1.ObjectMeta{Name: "tls-cert", Namespace: "namespace"}, Data: map[string][]byte{ api.TLSCertKey: []byte("public key"), diff --git a/pkg/api/zz_generated.deepcopy.go b/pkg/api/zz_generated.deepcopy.go index ab50cbb194c3f..7f8adc35d3d8e 100644 --- a/pkg/api/zz_generated.deepcopy.go +++ b/pkg/api/zz_generated.deepcopy.go @@ -858,6 +858,7 @@ func DeepCopy_api_EmptyDirVolumeSource(in interface{}, out interface{}, c *conve in := in.(*EmptyDirVolumeSource) out := out.(*EmptyDirVolumeSource) *out = *in + out.SizeLimit = in.SizeLimit.DeepCopy() return nil } } @@ -3555,7 +3556,9 @@ func DeepCopy_api_VolumeSource(in interface{}, out interface{}, c *conversion.Cl if in.EmptyDir != nil { in, out := &in.EmptyDir, &out.EmptyDir *out = new(EmptyDirVolumeSource) - **out = **in + if err := DeepCopy_api_EmptyDirVolumeSource(*in, *out, c); err != nil { + return err + } } if in.GCEPersistentDisk != nil { in, out := &in.GCEPersistentDisk, &out.GCEPersistentDisk diff --git a/pkg/apis/admission/v1alpha1/generated.pb.go b/pkg/apis/admission/v1alpha1/generated.pb.go index 292eb1d7ee98f..83fbe8e0e8a33 100644 --- a/pkg/apis/admission/v1alpha1/generated.pb.go +++ b/pkg/apis/admission/v1alpha1/generated.pb.go @@ -988,47 +988,46 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 663 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x93, 0x4f, 0x6f, 0xd3, 0x4c, - 0x10, 0xc6, 0xe3, 0xf7, 0x4d, 0xd3, 0x64, 0x8b, 0x28, 0x6c, 0x85, 0x64, 0xf5, 0xe0, 0x56, 0x3d, - 0x15, 0x44, 0x6d, 0x95, 0x3f, 0x15, 0x42, 0xf4, 0x50, 0x0b, 0x84, 0x10, 0x52, 0x8b, 0xb6, 0x2a, - 0x42, 0x20, 0x21, 0x6d, 0xec, 0x69, 0xb2, 0xc4, 0xf6, 0x5a, 0xbb, 0xeb, 0xb4, 0xdc, 0xf8, 0x08, - 0x1c, 0xf8, 0x50, 0x3d, 0xf6, 0xc8, 0x85, 0x8a, 0x06, 0xf1, 0x25, 0x38, 0x21, 0xaf, 0xd7, 0x76, - 0xdb, 0x24, 0x40, 0xe1, 0x94, 0xec, 0xce, 0x3e, 0xbf, 0x79, 0xc6, 0x33, 0x83, 0x36, 0x07, 0x0f, - 0xa4, 0xcb, 0xb8, 0x37, 0xc8, 0xba, 0x20, 0x12, 0x50, 0x20, 0xbd, 0x74, 0xd0, 0xf3, 0x68, 0xca, - 0xa4, 0x47, 0xc3, 0x98, 0x49, 0xc9, 0x78, 0xe2, 0x0d, 0xd7, 0x69, 0x94, 0xf6, 0xe9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, 0xfa, 0x0d, 0xee, 0xa3, 0xb6, - 0x00, 0xc9, 0x33, 0x11, 0x80, 0x3d, 0xab, 0x3f, 0xc7, 0xc3, 0xcb, 0x37, 0x91, 0x18, 0x82, 0x7f, - 0xcd, 0xe4, 0x6a, 0x97, 0x37, 0xa4, 0xa2, 0xe3, 0xfb, 0x68, 0x4e, 0x66, 0xdd, 0x32, 0x60, 0xb7, - 0xb5, 0xb9, 0x05, 0x23, 0x98, 0xdb, 0xad, 0x43, 0xe4, 0xec, 0x3b, 0x1c, 0xa2, 0x76, 0x26, 0x41, - 0x3c, 0x4b, 0xf6, 0xb9, 0xdd, 0x39, 0x3f, 0x65, 0x13, 0x27, 0xfd, 0xdc, 0xca, 0xe6, 0x46, 0xf7, - 0x8c, 0xba, 0x36, 0x57, 0xde, 0x90, 0x8a, 0xbc, 0xf2, 0xc9, 0x42, 0x37, 0x26, 0x6e, 0x04, 0xbe, - 0x89, 0x66, 0x69, 0x14, 0xf1, 0x03, 0x28, 0x86, 0xbc, 0xed, 0xcf, 0x1b, 0xcc, 0xec, 0x56, 0x71, - 0x4d, 0xca, 0x38, 0x7e, 0x71, 0x61, 0x25, 0x6f, 0xff, 0xd9, 0x97, 0x34, 0xab, 0x87, 0xf2, 0x69, - 0x25, 0x20, 0xb3, 0x48, 0x95, 0x6b, 0xe7, 0xdf, 0x3a, 0x3a, 0x75, 0x1a, 0xc7, 0xa7, 0x4e, 0xe3, - 0xf3, 0xa9, 0xd3, 0xf8, 0x30, 0x72, 0xac, 0xa3, 0x91, 0x63, 0x1d, 0x8f, 0x1c, 0xeb, 0xeb, 0xc8, - 0xb1, 0x3e, 0x7e, 0x73, 0x1a, 0xaf, 0xdb, 0xe5, 0x42, 0xff, 0x0c, 0x00, 0x00, 0xff, 0xff, 0x7e, - 0x0b, 0x34, 0xea, 0x70, 0x06, 0x00, 0x00, + // 652 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00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x2a, 0xf2, 0xd2, 0x67, 0x07, 0xdd, + 0x38, 0x73, 0x22, 0xf0, 0x4d, 0x34, 0x4d, 0xe3, 0x58, 0xec, 0x41, 0xd1, 0xe4, 0xed, 0xee, 0xac, + 0xc5, 0x4c, 0x6f, 0x14, 0xdb, 0xa4, 0x8c, 0xe3, 0x17, 0xa7, 0x46, 0xf2, 0xf6, 0xdf, 0x55, 0xd2, + 0x8e, 0x1e, 0xca, 0xbb, 0x95, 0x80, 0xca, 0x62, 0x5d, 0x8e, 0x5d, 0xf7, 0xd6, 0xfe, 0x91, 0xd7, + 0x38, 0x38, 0xf2, 0x1a, 0x5f, 0x8e, 0xbc, 0xc6, 0xc7, 0xb1, 0xe7, 0xec, 0x8f, 0x3d, 0xe7, 0x60, + 0xec, 0x39, 0xdf, 0xc6, 0x9e, 0xf3, 0xe9, 0xbb, 0xd7, 0x78, 0xdd, 0x2e, 0x07, 0xfa, 0x57, 0x00, + 0x00, 0x00, 0xff, 0xff, 0xfd, 0x67, 0xf4, 0x3f, 0x3a, 0x06, 0x00, 0x00, } diff --git a/pkg/apis/admission/v1alpha1/generated.proto b/pkg/apis/admission/v1alpha1/generated.proto index a2425a144d5c2..4578a2b7aaf7d 100644 --- a/pkg/apis/admission/v1alpha1/generated.proto +++ b/pkg/apis/admission/v1alpha1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/apis/authentication/v1/generated.proto"; // Package-wide variables from generator "generated". diff --git a/pkg/apis/admissionregistration/BUILD b/pkg/apis/admissionregistration/BUILD new file mode 100644 index 0000000000000..72f4fd29b838e --- /dev/null +++ b/pkg/apis/admissionregistration/BUILD @@ -0,0 +1,43 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/apis/admissionregistration/install:all-srcs", + "//pkg/apis/admissionregistration/v1alpha1:all-srcs", + "//pkg/apis/admissionregistration/validation:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/apis/admissionregistration/doc.go b/pkg/apis/admissionregistration/doc.go new file mode 100644 index 0000000000000..5dfc4e74e37aa --- /dev/null +++ b/pkg/apis/admissionregistration/doc.go @@ -0,0 +1,24 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// +k8s:deepcopy-gen=package,register + +// Package admissionregistration is the internal version of the API. +// AdmissionConfiguration and AdmissionPluginConfiguration are legacy static admission plugin configuration +// InitializerConfiguration and ExternalAdmissionHookConfiguration is for the +// new dynamic admission controller configuration. +// +groupName=admissionregistration.k8s.io +package admissionregistration // import "k8s.io/kubernetes/pkg/apis/admissionregistration" diff --git a/pkg/apis/admissionregistration/install/BUILD b/pkg/apis/admissionregistration/install/BUILD new file mode 100644 index 0000000000000..49cc0c90e0ba3 --- /dev/null +++ b/pkg/apis/admissionregistration/install/BUILD @@ -0,0 +1,36 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["install.go"], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/admissionregistration:go_default_library", + "//pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/apis/admissionregistration/install/install.go b/pkg/apis/admissionregistration/install/install.go new file mode 100644 index 0000000000000..28bc44c28a222 --- /dev/null +++ b/pkg/apis/admissionregistration/install/install.go @@ -0,0 +1,49 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package install + +import ( + "k8s.io/apimachinery/pkg/apimachinery/announced" + "k8s.io/apimachinery/pkg/apimachinery/registered" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/sets" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/admissionregistration" + "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" +) + +func init() { + Install(api.GroupFactoryRegistry, api.Registry, api.Scheme) +} + +// Install registers the API group and adds types to a scheme +func Install(groupFactoryRegistry announced.APIGroupFactoryRegistry, registry *registered.APIRegistrationManager, scheme *runtime.Scheme) { + if err := announced.NewGroupMetaFactory( + &announced.GroupMetaFactoryArgs{ + GroupName: admissionregistration.GroupName, + RootScopedKinds: sets.NewString("InitializerConfiguration", "ExternalAdmissionHookConfiguration"), + VersionPreferenceOrder: []string{v1alpha1.SchemeGroupVersion.Version}, + ImportPrefix: "k8s.io/kubernetes/pkg/apis/admissionregistration", + AddInternalObjectsToScheme: admissionregistration.AddToScheme, + }, + announced.VersionToSchemeFunc{ + v1alpha1.SchemeGroupVersion.Version: v1alpha1.AddToScheme, + }, + ).Announce(groupFactoryRegistry).RegisterAndEnable(registry, scheme); err != nil { + panic(err) + } +} diff --git a/pkg/apis/admissionregistration/register.go b/pkg/apis/admissionregistration/register.go new file mode 100644 index 0000000000000..1fe291a8f23f0 --- /dev/null +++ b/pkg/apis/admissionregistration/register.go @@ -0,0 +1,53 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package admissionregistration + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +const GroupName = "admissionregistration.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} + +// Kind takes an unqualified kind and returns back a Group qualified GroupKind +func Kind(kind string) schema.GroupKind { + return SchemeGroupVersion.WithKind(kind).GroupKind() +} + +// Resource takes an unqualified resource and returns back a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) + AddToScheme = SchemeBuilder.AddToScheme +) + +// Adds the list of known types to scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &InitializerConfiguration{}, + &InitializerConfigurationList{}, + &ExternalAdmissionHookConfiguration{}, + &ExternalAdmissionHookConfigurationList{}, + ) + return nil +} diff --git a/pkg/apis/admissionregistration/types.go b/pkg/apis/admissionregistration/types.go new file mode 100644 index 0000000000000..037c075770928 --- /dev/null +++ b/pkg/apis/admissionregistration/types.go @@ -0,0 +1,210 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package admissionregistration + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// +genclient=true + +// InitializerConfiguration describes the configuration of initializers. +type InitializerConfiguration struct { + metav1.TypeMeta + // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // +optional + metav1.ObjectMeta + + // Initializers is a list of resources and their default initializers + // Order-sensitive. + // When merging multiple InitializerConfigurations, we sort the initializers + // from different InitializerConfigurations by the name of the + // InitializerConfigurations; the order of the initializers from the same + // InitializerConfiguration is preserved. + // +optional + Initializers []Initializer +} + +// InitializerConfigurationList is a list of InitializerConfiguration. +type InitializerConfigurationList struct { + metav1.TypeMeta + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // +optional + metav1.ListMeta + + // List of InitializerConfiguration. + Items []InitializerConfiguration +} + +// Initializer describes the name and the failure policy of an initializer, and +// what resources it applies to. +type Initializer struct { + // Name is the identifier of the initializer. It will be added to the + // object that needs to be initialized. + // Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where + // "alwayspullimages" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required + Name string + + // Rules describes what resources/subresources the initializer cares about. + // The initializer cares about an operation if it matches _any_ Rule. + Rules []Rule + + // FailurePolicy defines what happens if the responsible initializer controller + // fails to takes action. Allowed values are Ignore, or Fail. If "Ignore" is + // set, initializer is removed from the initializers list of an object if + // the timeout is reached; If "Fail" is set, admissionregistration returns timeout error + // if the timeout is reached. + FailurePolicy *FailurePolicyType +} + +// Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended +// to make sure that all the tuple expansions are valid. +type Rule struct { + // APIGroups is the API groups the resources belong to. '*' is all groups. + // If '*' is present, the length of the slice must be one. + // Required. + APIGroups []string + + // APIVersions is the API versions the resources belong to. '*' is all versions. + // If '*' is present, the length of the slice must be one. + // Required. + APIVersions []string + + // Resources is a list of resources this rule applies to. + // + // For example: + // 'pods' means pods. + // 'pods/log' means the log subresource of pods. + // '*' means all resources, but not subresources. + // 'pods/*' means all subresources of pods. + // '*/scale' means all scale subresources. + // '*/*' means all resources and their subresources. + // + // If '*' or '*/*' is present, the length of the slice must be one. + // Required. + Resources []string +} + +type FailurePolicyType string + +const ( + // Ignore means the initilizer is removed from the initializers list of an + // object if the initializer is timed out. + Ignore FailurePolicyType = "Ignore" + // For 1.7, only "Ignore" is allowed. "Fail" will be allowed when the + // extensible admission feature is beta. + Fail FailurePolicyType = "Fail" +) + +// +genclient=true + +// ExternalAdmissionHookConfiguration describes the configuration of initializers. +type ExternalAdmissionHookConfiguration struct { + metav1.TypeMeta + // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // +optional + metav1.ObjectMeta + // ExternalAdmissionHooks is a list of external admission webhooks and the + // affected resources and operations. + // +optional + ExternalAdmissionHooks []ExternalAdmissionHook +} + +// ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration. +type ExternalAdmissionHookConfigurationList struct { + metav1.TypeMeta + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // +optional + metav1.ListMeta + // List of ExternalAdmissionHookConfiguration. + Items []ExternalAdmissionHookConfiguration +} + +// ExternalAdmissionHook describes an external admission webhook and the +// resources and operations it applies to. +type ExternalAdmissionHook struct { + // The name of the external admission webhook. + // Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where + // "imagepolicy" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required. + Name string + + // ClientConfig defines how to communicate with the hook. + // Required + ClientConfig AdmissionHookClientConfig + + // Rules describes what operations on what resources/subresources the webhook cares about. + // The webhook cares about an operation if it matches _any_ Rule. + Rules []RuleWithOperations + + // FailurePolicy defines how unrecognized errors from the admission endpoint are handled - + // allowed values are Ignore or Fail. Defaults to Ignore. + // +optional + FailurePolicy *FailurePolicyType +} + +// RuleWithOperations is a tuple of Operations and Resources. It is recommended to make +// sure that all the tuple expansions are valid. +type RuleWithOperations struct { + // Operations is the operations the admission hook cares about - CREATE, UPDATE, or * + // for all operations. + // If '*' is present, the length of the slice must be one. + // Required. + Operations []OperationType + // Rule is embedded, it describes other criteria of the rule, like + // APIGroups, APIVersions, Resources, etc. + Rule +} + +type OperationType string + +// The constants should be kept in sync with those defined in k8s.io/kubernetes/pkg/admission/interface.go. +const ( + OperationAll OperationType = "*" + Create OperationType = "CREATE" + Update OperationType = "UPDATE" + Delete OperationType = "DELETE" + Connect OperationType = "CONNECT" +) + +// AdmissionHookClientConfig contains the information to make a TLS +// connection with the webhook +type AdmissionHookClientConfig struct { + // Service is a reference to the service for this webhook. If there is only + // one port open for the service, that port will be used. If there are multiple + // ports open, port 443 will be used if it is open, otherwise it is an error. + // Required + Service ServiceReference + // CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. + // Required + CABundle []byte +} + +// ServiceReference holds a reference to Service.legacy.k8s.io +type ServiceReference struct { + // Namespace is the namespace of the service + // Required + Namespace string + // Name is the name of the service + // Required + Name string +} diff --git a/pkg/apis/admissionregistration/v1alpha1/BUILD b/pkg/apis/admissionregistration/v1alpha1/BUILD new file mode 100644 index 0000000000000..9692de3c191d7 --- /dev/null +++ b/pkg/apis/admissionregistration/v1alpha1/BUILD @@ -0,0 +1,48 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/admissionregistration:go_default_library", + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/apis/admissionregistration/v1alpha1/defaults.go b/pkg/apis/admissionregistration/v1alpha1/defaults.go new file mode 100644 index 0000000000000..5aed8f1d78716 --- /dev/null +++ b/pkg/apis/admissionregistration/v1alpha1/defaults.go @@ -0,0 +1,39 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +import ( + "k8s.io/apimachinery/pkg/runtime" +) + +func addDefaultingFuncs(scheme *runtime.Scheme) error { + return RegisterDefaults(scheme) +} + +func SetDefaults_Initializer(obj *Initializer) { + if obj.FailurePolicy == nil { + policy := Ignore + obj.FailurePolicy = &policy + } +} + +func SetDefaults_ExternalAdmissionHook(obj *ExternalAdmissionHook) { + if obj.FailurePolicy == nil { + policy := Ignore + obj.FailurePolicy = &policy + } +} diff --git a/pkg/apis/admissionregistration/v1alpha1/doc.go b/pkg/apis/admissionregistration/v1alpha1/doc.go new file mode 100644 index 0000000000000..9f75528f9aab4 --- /dev/null +++ b/pkg/apis/admissionregistration/v1alpha1/doc.go @@ -0,0 +1,27 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// +k8s:deepcopy-gen=package,register +// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/admissionregistration +// +k8s:openapi-gen=true +// +k8s:defaulter-gen=TypeMeta + +// Package v1alpha1 is the v1alpha1 version of the API. +// AdmissionConfiguration and AdmissionPluginConfiguration are legacy static admission plugin configuration +// InitializerConfiguration and ExternalAdmissionHookConfiguration is for the +// new dynamic admission controller configuration. +// +groupName=admissionregistration.k8s.io +package v1alpha1 // import "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" diff --git a/pkg/apis/admissionregistration/v1alpha1/generated.pb.go b/pkg/apis/admissionregistration/v1alpha1/generated.pb.go new file mode 100644 index 0000000000000..59a896d76092a --- /dev/null +++ b/pkg/apis/admissionregistration/v1alpha1/generated.pb.go @@ -0,0 +1,2228 @@ +/* +Copyright 2017 The Kubernetes 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 protoc-gen-gogo. +// source: k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1/generated.proto +// DO NOT EDIT! + +/* + Package v1alpha1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1/generated.proto + + It has these top-level messages: + AdmissionHookClientConfig + ExternalAdmissionHook + ExternalAdmissionHookConfiguration + ExternalAdmissionHookConfigurationList + Initializer + InitializerConfiguration + InitializerConfigurationList + Rule + RuleWithOperations + ServiceReference +*/ +package v1alpha1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *AdmissionHookClientConfig) Reset() { *m = AdmissionHookClientConfig{} } +func (*AdmissionHookClientConfig) ProtoMessage() {} +func (*AdmissionHookClientConfig) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{0} +} + +func (m *ExternalAdmissionHook) Reset() { *m = ExternalAdmissionHook{} } +func (*ExternalAdmissionHook) ProtoMessage() {} +func (*ExternalAdmissionHook) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } + +func (m *ExternalAdmissionHookConfiguration) Reset() { *m = ExternalAdmissionHookConfiguration{} } +func (*ExternalAdmissionHookConfiguration) ProtoMessage() {} +func (*ExternalAdmissionHookConfiguration) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{2} +} + +func (m *ExternalAdmissionHookConfigurationList) Reset() { + *m = ExternalAdmissionHookConfigurationList{} +} +func (*ExternalAdmissionHookConfigurationList) ProtoMessage() {} +func (*ExternalAdmissionHookConfigurationList) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{3} +} + +func (m *Initializer) Reset() { *m = Initializer{} } +func (*Initializer) ProtoMessage() {} +func (*Initializer) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } + +func (m *InitializerConfiguration) Reset() { *m = InitializerConfiguration{} } +func (*InitializerConfiguration) ProtoMessage() {} +func (*InitializerConfiguration) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{5} +} + +func (m *InitializerConfigurationList) Reset() { *m = InitializerConfigurationList{} } +func (*InitializerConfigurationList) ProtoMessage() {} +func (*InitializerConfigurationList) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{6} +} + +func (m *Rule) Reset() { *m = Rule{} } +func (*Rule) ProtoMessage() {} +func (*Rule) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } + +func (m *RuleWithOperations) Reset() { *m = RuleWithOperations{} } +func (*RuleWithOperations) ProtoMessage() {} +func (*RuleWithOperations) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } + +func (m *ServiceReference) Reset() { *m = ServiceReference{} } +func (*ServiceReference) ProtoMessage() {} +func (*ServiceReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } + +func init() { + proto.RegisterType((*AdmissionHookClientConfig)(nil), "k8s.io.kubernetes.pkg.apis.admissionregistration.v1alpha1.AdmissionHookClientConfig") + proto.RegisterType((*ExternalAdmissionHook)(nil), "k8s.io.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHook") + proto.RegisterType((*ExternalAdmissionHookConfiguration)(nil), "k8s.io.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfiguration") + proto.RegisterType((*ExternalAdmissionHookConfigurationList)(nil), "k8s.io.kubernetes.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfigurationList") + proto.RegisterType((*Initializer)(nil), "k8s.io.kubernetes.pkg.apis.admissionregistration.v1alpha1.Initializer") + proto.RegisterType((*InitializerConfiguration)(nil), "k8s.io.kubernetes.pkg.apis.admissionregistration.v1alpha1.InitializerConfiguration") + proto.RegisterType((*InitializerConfigurationList)(nil), "k8s.io.kubernetes.pkg.apis.admissionregistration.v1alpha1.InitializerConfigurationList") + proto.RegisterType((*Rule)(nil), "k8s.io.kubernetes.pkg.apis.admissionregistration.v1alpha1.Rule") + proto.RegisterType((*RuleWithOperations)(nil), "k8s.io.kubernetes.pkg.apis.admissionregistration.v1alpha1.RuleWithOperations") + proto.RegisterType((*ServiceReference)(nil), "k8s.io.kubernetes.pkg.apis.admissionregistration.v1alpha1.ServiceReference") +} +func (m *AdmissionHookClientConfig) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *AdmissionHookClientConfig) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Service.Size())) + n1, err := m.Service.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + if m.CABundle != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.CABundle))) + i += copy(dAtA[i:], m.CABundle) + } + return i, nil +} + +func (m *ExternalAdmissionHook) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ExternalAdmissionHook) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ClientConfig.Size())) + n2, err := m.ClientConfig.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n2 + if len(m.Rules) > 0 { + for _, msg := range m.Rules { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if m.FailurePolicy != nil { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.FailurePolicy))) + i += copy(dAtA[i:], *m.FailurePolicy) + } + return i, nil +} + +func (m *ExternalAdmissionHookConfiguration) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ExternalAdmissionHookConfiguration) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n3, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + if len(m.ExternalAdmissionHooks) > 0 { + for _, msg := range m.ExternalAdmissionHooks { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *ExternalAdmissionHookConfigurationList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ExternalAdmissionHookConfigurationList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n4, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *Initializer) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Initializer) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + if len(m.Rules) > 0 { + for _, msg := range m.Rules { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if m.FailurePolicy != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.FailurePolicy))) + i += copy(dAtA[i:], *m.FailurePolicy) + } + return i, nil +} + +func (m *InitializerConfiguration) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *InitializerConfiguration) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n5, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 + if len(m.Initializers) > 0 { + for _, msg := range m.Initializers { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *InitializerConfigurationList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *InitializerConfigurationList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n6, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n6 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *Rule) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Rule) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.APIGroups) > 0 { + for _, s := range m.APIGroups { + dAtA[i] = 0xa + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.APIVersions) > 0 { + for _, s := range m.APIVersions { + dAtA[i] = 0x12 + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.Resources) > 0 { + for _, s := range m.Resources { + dAtA[i] = 0x1a + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + return i, nil +} + +func (m *RuleWithOperations) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *RuleWithOperations) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Operations) > 0 { + for _, s := range m.Operations { + dAtA[i] = 0xa + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Rule.Size())) + n7, err := m.Rule.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n7 + return i, nil +} + +func (m *ServiceReference) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ServiceReference) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Namespace))) + i += copy(dAtA[i:], m.Namespace) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *AdmissionHookClientConfig) Size() (n int) { + var l int + _ = l + l = m.Service.Size() + n += 1 + l + sovGenerated(uint64(l)) + if m.CABundle != nil { + l = len(m.CABundle) + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *ExternalAdmissionHook) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + l = m.ClientConfig.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Rules) > 0 { + for _, e := range m.Rules { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if m.FailurePolicy != nil { + l = len(*m.FailurePolicy) + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *ExternalAdmissionHookConfiguration) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.ExternalAdmissionHooks) > 0 { + for _, e := range m.ExternalAdmissionHooks { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *ExternalAdmissionHookConfigurationList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *Initializer) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Rules) > 0 { + for _, e := range m.Rules { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if m.FailurePolicy != nil { + l = len(*m.FailurePolicy) + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *InitializerConfiguration) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Initializers) > 0 { + for _, e := range m.Initializers { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *InitializerConfigurationList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *Rule) Size() (n int) { + var l int + _ = l + if len(m.APIGroups) > 0 { + for _, s := range m.APIGroups { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.APIVersions) > 0 { + for _, s := range m.APIVersions { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.Resources) > 0 { + for _, s := range m.Resources { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *RuleWithOperations) Size() (n int) { + var l int + _ = l + if len(m.Operations) > 0 { + for _, s := range m.Operations { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + l = m.Rule.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *ServiceReference) Size() (n int) { + var l int + _ = l + l = len(m.Namespace) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *AdmissionHookClientConfig) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&AdmissionHookClientConfig{`, + `Service:` + strings.Replace(strings.Replace(this.Service.String(), "ServiceReference", "ServiceReference", 1), `&`, ``, 1) + `,`, + `CABundle:` + valueToStringGenerated(this.CABundle) + `,`, + `}`, + }, "") + return s +} +func (this *ExternalAdmissionHook) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ExternalAdmissionHook{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `ClientConfig:` + strings.Replace(strings.Replace(this.ClientConfig.String(), "AdmissionHookClientConfig", "AdmissionHookClientConfig", 1), `&`, ``, 1) + `,`, + `Rules:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Rules), "RuleWithOperations", "RuleWithOperations", 1), `&`, ``, 1) + `,`, + `FailurePolicy:` + valueToStringGenerated(this.FailurePolicy) + `,`, + `}`, + }, "") + return s +} +func (this *ExternalAdmissionHookConfiguration) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ExternalAdmissionHookConfiguration{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ExternalAdmissionHooks:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ExternalAdmissionHooks), "ExternalAdmissionHook", "ExternalAdmissionHook", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ExternalAdmissionHookConfigurationList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ExternalAdmissionHookConfigurationList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ExternalAdmissionHookConfiguration", "ExternalAdmissionHookConfiguration", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *Initializer) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Initializer{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `Rules:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Rules), "Rule", "Rule", 1), `&`, ``, 1) + `,`, + `FailurePolicy:` + valueToStringGenerated(this.FailurePolicy) + `,`, + `}`, + }, "") + return s +} +func (this *InitializerConfiguration) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&InitializerConfiguration{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Initializers:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Initializers), "Initializer", "Initializer", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *InitializerConfigurationList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&InitializerConfigurationList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "InitializerConfiguration", "InitializerConfiguration", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *Rule) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Rule{`, + `APIGroups:` + fmt.Sprintf("%v", this.APIGroups) + `,`, + `APIVersions:` + fmt.Sprintf("%v", this.APIVersions) + `,`, + `Resources:` + fmt.Sprintf("%v", this.Resources) + `,`, + `}`, + }, "") + return s +} +func (this *RuleWithOperations) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RuleWithOperations{`, + `Operations:` + fmt.Sprintf("%v", this.Operations) + `,`, + `Rule:` + strings.Replace(strings.Replace(this.Rule.String(), "Rule", "Rule", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ServiceReference) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ServiceReference{`, + `Namespace:` + fmt.Sprintf("%v", this.Namespace) + `,`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *AdmissionHookClientConfig) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: AdmissionHookClientConfig: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: AdmissionHookClientConfig: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Service", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Service.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field CABundle", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + byteLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.CABundle = append(m.CABundle[:0], dAtA[iNdEx:postIndex]...) + if m.CABundle == nil { + m.CABundle = []byte{} + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ExternalAdmissionHook) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExternalAdmissionHook: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExternalAdmissionHook: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClientConfig", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ClientConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Rules", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Rules = append(m.Rules, RuleWithOperations{}) + if err := m.Rules[len(m.Rules)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FailurePolicy", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := FailurePolicyType(dAtA[iNdEx:postIndex]) + m.FailurePolicy = &s + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ExternalAdmissionHookConfiguration) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExternalAdmissionHookConfiguration: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExternalAdmissionHookConfiguration: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ExternalAdmissionHooks", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ExternalAdmissionHooks = append(m.ExternalAdmissionHooks, ExternalAdmissionHook{}) + if err := m.ExternalAdmissionHooks[len(m.ExternalAdmissionHooks)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ExternalAdmissionHookConfigurationList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExternalAdmissionHookConfigurationList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExternalAdmissionHookConfigurationList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, ExternalAdmissionHookConfiguration{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Initializer) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Initializer: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Initializer: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Rules", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Rules = append(m.Rules, Rule{}) + if err := m.Rules[len(m.Rules)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FailurePolicy", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := FailurePolicyType(dAtA[iNdEx:postIndex]) + m.FailurePolicy = &s + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *InitializerConfiguration) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: InitializerConfiguration: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: InitializerConfiguration: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Initializers", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Initializers = append(m.Initializers, Initializer{}) + if err := m.Initializers[len(m.Initializers)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *InitializerConfigurationList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: InitializerConfigurationList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: InitializerConfigurationList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, InitializerConfiguration{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Rule) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Rule: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Rule: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIGroups", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIGroups = append(m.APIGroups, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIVersions", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIVersions = append(m.APIVersions, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Resources", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Resources = append(m.Resources, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RuleWithOperations) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RuleWithOperations: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RuleWithOperations: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Operations", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Operations = append(m.Operations, OperationType(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Rule", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Rule.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ServiceReference) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ServiceReference: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ServiceReference: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Namespace", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Namespace = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 874 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x56, 0xcf, 0x6f, 0x1b, 0x45, + 0x14, 0xce, 0xd8, 0x8e, 0x6a, 0x8f, 0x6d, 0xb5, 0x1d, 0x41, 0x65, 0x22, 0xb4, 0x6b, 0xed, 0xa1, + 0xb2, 0x40, 0xec, 0x92, 0x80, 0x10, 0x9c, 0xaa, 0x6c, 0x44, 0xc1, 0xa2, 0x3f, 0xa2, 0x69, 0x05, + 0x12, 0x02, 0x89, 0xc9, 0xfa, 0xc5, 0x1e, 0xbc, 0xbf, 0x34, 0x33, 0x6b, 0x35, 0x9c, 0x2a, 0xae, + 0x20, 0x84, 0xc4, 0x3f, 0xc1, 0x95, 0x1b, 0x17, 0xee, 0x39, 0xf6, 0xc8, 0xc9, 0x22, 0xdb, 0xff, + 0x81, 0x43, 0x2f, 0xa0, 0xfd, 0xe5, 0x5d, 0xd7, 0xb6, 0x1a, 0xd5, 0x55, 0x6f, 0x99, 0xf7, 0xf6, + 0x7d, 0xef, 0xfb, 0xbe, 0xbc, 0x37, 0x63, 0x3c, 0x9c, 0x7e, 0x2c, 0x4d, 0x1e, 0x58, 0xd3, 0xe8, + 0x04, 0x84, 0x0f, 0x0a, 0xa4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c7, 0x1a, 0x3a, 0x8f, 0x35, 0xf4, 0x24, 0xd6, + 0xd0, 0x3f, 0xb1, 0x86, 0x7e, 0x7d, 0xaa, 0xed, 0x7c, 0xdd, 0x2c, 0xb8, 0xfe, 0x1f, 0x00, 0x00, + 0xff, 0xff, 0xde, 0x51, 0xae, 0xb2, 0xdf, 0x0a, 0x00, 0x00, +} diff --git a/pkg/apis/admissionregistration/v1alpha1/generated.proto b/pkg/apis/admissionregistration/v1alpha1/generated.proto new file mode 100644 index 0000000000000..75ecc3515d376 --- /dev/null +++ b/pkg/apis/admissionregistration/v1alpha1/generated.proto @@ -0,0 +1,199 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.kubernetes.pkg.apis.admissionregistration.v1alpha1; + +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v1alpha1"; + +// AdmissionHookClientConfig contains the information to make a TLS +// connection with the webhook +message AdmissionHookClientConfig { + // Service is a reference to the service for this webhook. If there is only + // one port open for the service, that port will be used. If there are multiple + // ports open, port 443 will be used if it is open, otherwise it is an error. + // Required + optional ServiceReference service = 1; + + // CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. + // Required + optional bytes caBundle = 2; +} + +// ExternalAdmissionHook describes an external admission webhook and the +// resources and operations it applies to. +message ExternalAdmissionHook { + // The name of the external admission webhook. + // Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where + // "imagepolicy" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required. + optional string name = 1; + + // ClientConfig defines how to communicate with the hook. + // Required + optional AdmissionHookClientConfig clientConfig = 2; + + // Rules describes what operations on what resources/subresources the webhook cares about. + // The webhook cares about an operation if it matches _any_ Rule. + repeated RuleWithOperations rules = 3; + + // FailurePolicy defines how unrecognized errors from the admission endpoint are handled - + // allowed values are Ignore or Fail. Defaults to Ignore. + // +optional + optional string failurePolicy = 4; +} + +// ExternalAdmissionHookConfiguration describes the configuration of initializers. +message ExternalAdmissionHookConfiguration { + // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // ExternalAdmissionHooks is a list of external admission webhooks and the + // affected resources and operations. + // +optional + // +patchMergeKey=name + // +patchStrategy=merge + repeated ExternalAdmissionHook externalAdmissionHooks = 2; +} + +// ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration. +message ExternalAdmissionHookConfigurationList { + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // List of ExternalAdmissionHookConfiguration. + repeated ExternalAdmissionHookConfiguration items = 2; +} + +// Initializer describes the name and the failure policy of an initializer, and +// what resources it applies to. +message Initializer { + // Name is the identifier of the initializer. It will be added to the + // object that needs to be initialized. + // Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where + // "alwayspullimages" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required + optional string name = 1; + + // Rules describes what resources/subresources the initializer cares about. + // The initializer cares about an operation if it matches _any_ Rule. + repeated Rule rules = 2; + + // FailurePolicy defines what happens if the responsible initializer controller + // fails to takes action. Allowed values are Ignore, or Fail. If "Ignore" is + // set, initializer is removed from the initializers list of an object if + // the timeout is reached; If "Fail" is set, admissionregistration returns timeout error + // if the timeout is reached. + optional string failurePolicy = 3; +} + +// InitializerConfiguration describes the configuration of initializers. +message InitializerConfiguration { + // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Initializers is a list of resources and their default initializers + // Order-sensitive. + // When merging multiple InitializerConfigurations, we sort the initializers + // from different InitializerConfigurations by the name of the + // InitializerConfigurations; the order of the initializers from the same + // InitializerConfiguration is preserved. + // +patchMergeKey=name + // +patchStrategy=merge + // +optional + repeated Initializer initializers = 2; +} + +// InitializerConfigurationList is a list of InitializerConfiguration. +message InitializerConfigurationList { + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // List of InitializerConfiguration. + repeated InitializerConfiguration items = 2; +} + +// Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended +// to make sure that all the tuple expansions are valid. +message Rule { + // APIGroups is the API groups the resources belong to. '*' is all groups. + // If '*' is present, the length of the slice must be one. + // Required. + repeated string apiGroups = 1; + + // APIVersions is the API versions the resources belong to. '*' is all versions. + // If '*' is present, the length of the slice must be one. + // Required. + repeated string apiVersions = 2; + + // Resources is a list of resources this rule applies to. + // + // For example: + // 'pods' means pods. + // 'pods/log' means the log subresource of pods. + // '*' means all resources, but not subresources. + // 'pods/*' means all subresources of pods. + // '*/scale' means all scale subresources. + // '*/*' means all resources and their subresources. + // + // If '*' or '*/*' is present, the length of the slice must be one. + // Required. + repeated string resources = 3; +} + +// RuleWithOperations is a tuple of Operations and Resources. It is recommended to make +// sure that all the tuple expansions are valid. +message RuleWithOperations { + // Operations is the operations the admission hook cares about - CREATE, UPDATE, or * + // for all operations. + // If '*' is present, the length of the slice must be one. + // Required. + repeated string operations = 1; + + // Rule is embedded, it describes other criteria of the rule, like + // APIGroups, APIVersions, Resources, etc. + optional Rule rule = 2; +} + +// ServiceReference holds a reference to Service.legacy.k8s.io +message ServiceReference { + // Namespace is the namespace of the service + // Required + optional string namespace = 1; + + // Name is the name of the service + // Required + optional string name = 2; +} + diff --git a/pkg/apis/admissionregistration/v1alpha1/register.go b/pkg/apis/admissionregistration/v1alpha1/register.go new file mode 100644 index 0000000000000..10fa4a161b5bb --- /dev/null +++ b/pkg/apis/admissionregistration/v1alpha1/register.go @@ -0,0 +1,60 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +const GroupName = "admissionregistration.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme +) + +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs) +} + +// Adds the list of known types to scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &InitializerConfiguration{}, + &InitializerConfigurationList{}, + &ExternalAdmissionHookConfiguration{}, + &ExternalAdmissionHookConfigurationList{}, + ) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) + return nil +} diff --git a/pkg/apis/admissionregistration/v1alpha1/types.generated.go b/pkg/apis/admissionregistration/v1alpha1/types.generated.go new file mode 100644 index 0000000000000..8a6563730bc40 --- /dev/null +++ b/pkg/apis/admissionregistration/v1alpha1/types.generated.go @@ -0,0 +1,4232 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +// ************************************************************ +// DO NOT EDIT. +// THIS FILE IS AUTO-GENERATED BY codecgen. +// ************************************************************ + +package v1alpha1 + +import ( + "errors" + "fmt" + codec1978 "github.com/ugorji/go/codec" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" + "reflect" + "runtime" + time "time" +) + +const ( + // ----- content types ---- + codecSelferC_UTF81234 = 1 + codecSelferC_RAW1234 = 0 + // ----- value types used ---- + codecSelferValueTypeArray1234 = 10 + codecSelferValueTypeMap1234 = 9 + // ----- containerStateValues ---- + codecSelfer_containerMapKey1234 = 2 + codecSelfer_containerMapValue1234 = 3 + codecSelfer_containerMapEnd1234 = 4 + codecSelfer_containerArrayElem1234 = 6 + codecSelfer_containerArrayEnd1234 = 7 +) + +var ( + codecSelferBitsize1234 = uint8(reflect.TypeOf(uint(0)).Bits()) + codecSelferOnlyMapOrArrayEncodeToStructErr1234 = errors.New(`only encoded map or array can be decoded into a struct`) +) + +type codecSelfer1234 struct{} + +func init() { + if codec1978.GenVersion != 5 { + _, file, _, _ := runtime.Caller(0) + err := fmt.Errorf("codecgen version mismatch: current: %v, need %v. Re-generate file: %v", + 5, codec1978.GenVersion, file) + panic(err) + } + if false { // reference the types, but skip this branch at build/run time + var v0 pkg1_v1.TypeMeta + var v1 pkg2_types.UID + var v2 time.Time + _, _, _ = v0, v1, v2 + } +} + +func (x *InitializerConfiguration) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = len(x.Initializers) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Initializers == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceInitializer(([]Initializer)(x.Initializers), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("initializers")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Initializers == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceInitializer(([]Initializer)(x.Initializers), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *InitializerConfiguration) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *InitializerConfiguration) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "initializers": + if r.TryDecodeAsNil() { + x.Initializers = nil + } else { + yyv10 := &x.Initializers + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceInitializer((*[]Initializer)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *InitializerConfiguration) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Initializers = nil + } else { + yyv19 := &x.Initializers + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceInitializer((*[]Initializer)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *InitializerConfigurationList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceInitializerConfiguration(([]InitializerConfiguration)(x.Items), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceInitializerConfiguration(([]InitializerConfiguration)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *InitializerConfigurationList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *InitializerConfigurationList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceInitializerConfiguration((*[]InitializerConfiguration)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *InitializerConfigurationList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceInitializerConfiguration((*[]InitializerConfiguration)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *Initializer) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = len(x.Rules) != 0 + yyq2[2] = x.FailurePolicy != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Rules == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encSliceRule(([]Rule)(x.Rules), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rules")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Rules == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encSliceRule(([]Rule)(x.Rules), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.FailurePolicy == nil { + r.EncodeNil() + } else { + yy10 := *x.FailurePolicy + yy10.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("failurePolicy")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.FailurePolicy == nil { + r.EncodeNil() + } else { + yy12 := *x.FailurePolicy + yy12.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *Initializer) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *Initializer) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "rules": + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv6 := &x.Rules + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSliceRule((*[]Rule)(yyv6), d) + } + } + case "failurePolicy": + if r.TryDecodeAsNil() { + if x.FailurePolicy != nil { + x.FailurePolicy = nil + } + } else { + if x.FailurePolicy == nil { + x.FailurePolicy = new(FailurePolicyType) + } + x.FailurePolicy.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *Initializer) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv10 := &x.Name + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv12 := &x.Rules + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + h.decSliceRule((*[]Rule)(yyv12), d) + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.FailurePolicy != nil { + x.FailurePolicy = nil + } + } else { + if x.FailurePolicy == nil { + x.FailurePolicy = new(FailurePolicyType) + } + x.FailurePolicy.CodecDecodeSelf(d) + } + for { + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj9-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *Rule) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.APIGroups) != 0 + yyq2[1] = len(x.APIVersions) != 0 + yyq2[2] = len(x.Resources) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiGroups")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.APIVersions == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.APIVersions, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersions")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.APIVersions == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.APIVersions, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Resources == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resources")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Resources == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *Rule) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *Rule) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "apiGroups": + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv4 := &x.APIGroups + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "apiVersions": + if r.TryDecodeAsNil() { + x.APIVersions = nil + } else { + yyv6 := &x.APIVersions + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + case "resources": + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv8 := &x.Resources + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *Rule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv11 := &x.APIGroups + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + z.F.DecSliceStringX(yyv11, false, d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersions = nil + } else { + yyv13 := &x.APIVersions + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + z.F.DecSliceStringX(yyv13, false, d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv15 := &x.Resources + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + z.F.DecSliceStringX(yyv15, false, d) + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x FailurePolicyType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *FailurePolicyType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *ExternalAdmissionHookConfiguration) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = len(x.ExternalAdmissionHooks) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.ExternalAdmissionHooks == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceExternalAdmissionHook(([]ExternalAdmissionHook)(x.ExternalAdmissionHooks), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("externalAdmissionHooks")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ExternalAdmissionHooks == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceExternalAdmissionHook(([]ExternalAdmissionHook)(x.ExternalAdmissionHooks), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ExternalAdmissionHookConfiguration) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ExternalAdmissionHookConfiguration) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "externalAdmissionHooks": + if r.TryDecodeAsNil() { + x.ExternalAdmissionHooks = nil + } else { + yyv10 := &x.ExternalAdmissionHooks + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceExternalAdmissionHook((*[]ExternalAdmissionHook)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ExternalAdmissionHookConfiguration) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ExternalAdmissionHooks = nil + } else { + yyv19 := &x.ExternalAdmissionHooks + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceExternalAdmissionHook((*[]ExternalAdmissionHook)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ExternalAdmissionHookConfigurationList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceExternalAdmissionHookConfiguration(([]ExternalAdmissionHookConfiguration)(x.Items), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceExternalAdmissionHookConfiguration(([]ExternalAdmissionHookConfiguration)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ExternalAdmissionHookConfigurationList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ExternalAdmissionHookConfigurationList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceExternalAdmissionHookConfiguration((*[]ExternalAdmissionHookConfiguration)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ExternalAdmissionHookConfigurationList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceExternalAdmissionHookConfiguration((*[]ExternalAdmissionHookConfiguration)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ExternalAdmissionHook) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = len(x.Rules) != 0 + yyq2[3] = x.FailurePolicy != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy7 := &x.ClientConfig + yy7.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("clientConfig")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy9 := &x.ClientConfig + yy9.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Rules == nil { + r.EncodeNil() + } else { + yym12 := z.EncBinary() + _ = yym12 + if false { + } else { + h.encSliceRuleWithOperations(([]RuleWithOperations)(x.Rules), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rules")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Rules == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + h.encSliceRuleWithOperations(([]RuleWithOperations)(x.Rules), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.FailurePolicy == nil { + r.EncodeNil() + } else { + yy15 := *x.FailurePolicy + yy15.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("failurePolicy")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.FailurePolicy == nil { + r.EncodeNil() + } else { + yy17 := *x.FailurePolicy + yy17.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ExternalAdmissionHook) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ExternalAdmissionHook) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "clientConfig": + if r.TryDecodeAsNil() { + x.ClientConfig = AdmissionHookClientConfig{} + } else { + yyv6 := &x.ClientConfig + yyv6.CodecDecodeSelf(d) + } + case "rules": + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv7 := &x.Rules + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + h.decSliceRuleWithOperations((*[]RuleWithOperations)(yyv7), d) + } + } + case "failurePolicy": + if r.TryDecodeAsNil() { + if x.FailurePolicy != nil { + x.FailurePolicy = nil + } + } else { + if x.FailurePolicy == nil { + x.FailurePolicy = new(FailurePolicyType) + } + x.FailurePolicy.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ExternalAdmissionHook) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv11 := &x.Name + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ClientConfig = AdmissionHookClientConfig{} + } else { + yyv13 := &x.ClientConfig + yyv13.CodecDecodeSelf(d) + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv14 := &x.Rules + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + h.decSliceRuleWithOperations((*[]RuleWithOperations)(yyv14), d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.FailurePolicy != nil { + x.FailurePolicy = nil + } + } else { + if x.FailurePolicy == nil { + x.FailurePolicy = new(FailurePolicyType) + } + x.FailurePolicy.CodecDecodeSelf(d) + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *RuleWithOperations) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Operations) != 0 + yyq2[1] = len(x.APIGroups) != 0 + yyq2[2] = len(x.APIVersions) != 0 + yyq2[3] = len(x.Resources) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Operations == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSliceOperationType(([]OperationType)(x.Operations), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("operations")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Operations == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSliceOperationType(([]OperationType)(x.Operations), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiGroups")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.APIVersions == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceStringV(x.APIVersions, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersions")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.APIVersions == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceStringV(x.APIVersions, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Resources == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resources")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Resources == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *RuleWithOperations) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *RuleWithOperations) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "operations": + if r.TryDecodeAsNil() { + x.Operations = nil + } else { + yyv4 := &x.Operations + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSliceOperationType((*[]OperationType)(yyv4), d) + } + } + case "apiGroups": + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv6 := &x.APIGroups + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + case "apiVersions": + if r.TryDecodeAsNil() { + x.APIVersions = nil + } else { + yyv8 := &x.APIVersions + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + case "resources": + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv10 := &x.Resources + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + z.F.DecSliceStringX(yyv10, false, d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *RuleWithOperations) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Operations = nil + } else { + yyv13 := &x.Operations + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSliceOperationType((*[]OperationType)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv15 := &x.APIGroups + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + z.F.DecSliceStringX(yyv15, false, d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersions = nil + } else { + yyv17 := &x.APIVersions + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + z.F.DecSliceStringX(yyv17, false, d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv19 := &x.Resources + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + z.F.DecSliceStringX(yyv19, false, d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x OperationType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *OperationType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *AdmissionHookClientConfig) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy4 := &x.Service + yy4.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("service")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy6 := &x.Service + yy6.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.CABundle == nil { + r.EncodeNil() + } else { + yym9 := z.EncBinary() + _ = yym9 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.CABundle)) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("caBundle")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.CABundle == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.CABundle)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *AdmissionHookClientConfig) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *AdmissionHookClientConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "service": + if r.TryDecodeAsNil() { + x.Service = ServiceReference{} + } else { + yyv4 := &x.Service + yyv4.CodecDecodeSelf(d) + } + case "caBundle": + if r.TryDecodeAsNil() { + x.CABundle = nil + } else { + yyv5 := &x.CABundle + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *yyv5 = r.DecodeBytes(*(*[]byte)(yyv5), false, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *AdmissionHookClientConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Service = ServiceReference{} + } else { + yyv8 := &x.Service + yyv8.CodecDecodeSelf(d) + } + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CABundle = nil + } else { + yyv9 := &x.CABundle + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *yyv9 = r.DecodeBytes(*(*[]byte)(yyv9), false, false) + } + } + for { + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj7-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ServiceReference) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ServiceReference) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ServiceReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv4 := &x.Namespace + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv6 := &x.Name + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ServiceReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv9 := &x.Namespace + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv11 := &x.Name + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) encSliceInitializer(v []Initializer, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceInitializer(v *[]Initializer, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Initializer{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 48) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]Initializer, yyrl1) + } + } else { + yyv1 = make([]Initializer, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Initializer{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Initializer{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Initializer{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Initializer{}) // var yyz1 Initializer + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = Initializer{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Initializer{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceInitializerConfiguration(v []InitializerConfiguration, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceInitializerConfiguration(v *[]InitializerConfiguration, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []InitializerConfiguration{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]InitializerConfiguration, yyrl1) + } + } else { + yyv1 = make([]InitializerConfiguration, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = InitializerConfiguration{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, InitializerConfiguration{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = InitializerConfiguration{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, InitializerConfiguration{}) // var yyz1 InitializerConfiguration + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = InitializerConfiguration{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []InitializerConfiguration{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceRule(v []Rule, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceRule(v *[]Rule, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Rule{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 72) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]Rule, yyrl1) + } + } else { + yyv1 = make([]Rule, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Rule{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Rule{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Rule{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Rule{}) // var yyz1 Rule + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = Rule{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Rule{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceExternalAdmissionHook(v []ExternalAdmissionHook, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceExternalAdmissionHook(v *[]ExternalAdmissionHook, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ExternalAdmissionHook{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 104) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]ExternalAdmissionHook, yyrl1) + } + } else { + yyv1 = make([]ExternalAdmissionHook, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHook{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ExternalAdmissionHook{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHook{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ExternalAdmissionHook{}) // var yyz1 ExternalAdmissionHook + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHook{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ExternalAdmissionHook{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceExternalAdmissionHookConfiguration(v []ExternalAdmissionHookConfiguration, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceExternalAdmissionHookConfiguration(v *[]ExternalAdmissionHookConfiguration, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ExternalAdmissionHookConfiguration{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]ExternalAdmissionHookConfiguration, yyrl1) + } + } else { + yyv1 = make([]ExternalAdmissionHookConfiguration, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHookConfiguration{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ExternalAdmissionHookConfiguration{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHookConfiguration{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ExternalAdmissionHookConfiguration{}) // var yyz1 ExternalAdmissionHookConfiguration + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHookConfiguration{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ExternalAdmissionHookConfiguration{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceRuleWithOperations(v []RuleWithOperations, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceRuleWithOperations(v *[]RuleWithOperations, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []RuleWithOperations{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 96) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]RuleWithOperations, yyrl1) + } + } else { + yyv1 = make([]RuleWithOperations, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = RuleWithOperations{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, RuleWithOperations{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = RuleWithOperations{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, RuleWithOperations{}) // var yyz1 RuleWithOperations + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = RuleWithOperations{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []RuleWithOperations{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceOperationType(v []OperationType, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yyv1.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceOperationType(v *[]OperationType, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []OperationType{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]OperationType, yyrl1) + } + } else { + yyv1 = make([]OperationType, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 OperationType + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []OperationType{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} diff --git a/pkg/apis/admissionregistration/v1alpha1/types.go b/pkg/apis/admissionregistration/v1alpha1/types.go new file mode 100644 index 0000000000000..67a76dff98144 --- /dev/null +++ b/pkg/apis/admissionregistration/v1alpha1/types.go @@ -0,0 +1,214 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// +genclient=true + +// InitializerConfiguration describes the configuration of initializers. +type InitializerConfiguration struct { + metav1.TypeMeta `json:",inline"` + // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Initializers is a list of resources and their default initializers + // Order-sensitive. + // When merging multiple InitializerConfigurations, we sort the initializers + // from different InitializerConfigurations by the name of the + // InitializerConfigurations; the order of the initializers from the same + // InitializerConfiguration is preserved. + // +patchMergeKey=name + // +patchStrategy=merge + // +optional + Initializers []Initializer `json:"initializers,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,2,rep,name=initializers"` +} + +// InitializerConfigurationList is a list of InitializerConfiguration. +type InitializerConfigurationList struct { + metav1.TypeMeta `json:",inline"` + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // List of InitializerConfiguration. + Items []InitializerConfiguration `json:"items" protobuf:"bytes,2,rep,name=items"` +} + +// Initializer describes the name and the failure policy of an initializer, and +// what resources it applies to. +type Initializer struct { + // Name is the identifier of the initializer. It will be added to the + // object that needs to be initialized. + // Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where + // "alwayspullimages" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required + Name string `json:"name" protobuf:"bytes,1,opt,name=name"` + + // Rules describes what resources/subresources the initializer cares about. + // The initializer cares about an operation if it matches _any_ Rule. + Rules []Rule `json:"rules,omitempty" protobuf:"bytes,2,rep,name=rules"` + + // FailurePolicy defines what happens if the responsible initializer controller + // fails to takes action. Allowed values are Ignore, or Fail. If "Ignore" is + // set, initializer is removed from the initializers list of an object if + // the timeout is reached; If "Fail" is set, admissionregistration returns timeout error + // if the timeout is reached. + FailurePolicy *FailurePolicyType `json:"failurePolicy,omitempty" protobuf:"bytes,3,opt,name=failurePolicy,casttype=FailurePolicyType"` +} + +// Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended +// to make sure that all the tuple expansions are valid. +type Rule struct { + // APIGroups is the API groups the resources belong to. '*' is all groups. + // If '*' is present, the length of the slice must be one. + // Required. + APIGroups []string `json:"apiGroups,omitempty" protobuf:"bytes,1,rep,name=apiGroups"` + + // APIVersions is the API versions the resources belong to. '*' is all versions. + // If '*' is present, the length of the slice must be one. + // Required. + APIVersions []string `json:"apiVersions,omitempty" protobuf:"bytes,2,rep,name=apiVersions"` + + // Resources is a list of resources this rule applies to. + // + // For example: + // 'pods' means pods. + // 'pods/log' means the log subresource of pods. + // '*' means all resources, but not subresources. + // 'pods/*' means all subresources of pods. + // '*/scale' means all scale subresources. + // '*/*' means all resources and their subresources. + // + // If '*' or '*/*' is present, the length of the slice must be one. + // Required. + Resources []string `json:"resources,omitempty" protobuf:"bytes,3,rep,name=resources"` +} + +type FailurePolicyType string + +const ( + // Ignore means the initilizer is removed from the initializers list of an + // object if the initializer is timed out. + Ignore FailurePolicyType = "Ignore" + // For 1.7, only "Ignore" is allowed. "Fail" will be allowed when the + // extensible admission feature is beta. + Fail FailurePolicyType = "Fail" +) + +// +genclient=true + +// ExternalAdmissionHookConfiguration describes the configuration of initializers. +type ExternalAdmissionHookConfiguration struct { + metav1.TypeMeta `json:",inline"` + // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + // ExternalAdmissionHooks is a list of external admission webhooks and the + // affected resources and operations. + // +optional + // +patchMergeKey=name + // +patchStrategy=merge + ExternalAdmissionHooks []ExternalAdmissionHook `json:"externalAdmissionHooks,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,2,rep,name=externalAdmissionHooks"` +} + +// ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration. +type ExternalAdmissionHookConfigurationList struct { + metav1.TypeMeta `json:",inline"` + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + // List of ExternalAdmissionHookConfiguration. + Items []ExternalAdmissionHookConfiguration `json:"items" protobuf:"bytes,2,rep,name=items"` +} + +// ExternalAdmissionHook describes an external admission webhook and the +// resources and operations it applies to. +type ExternalAdmissionHook struct { + // The name of the external admission webhook. + // Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where + // "imagepolicy" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required. + Name string `json:"name" protobuf:"bytes,1,opt,name=name"` + + // ClientConfig defines how to communicate with the hook. + // Required + ClientConfig AdmissionHookClientConfig `json:"clientConfig" protobuf:"bytes,2,opt,name=clientConfig"` + + // Rules describes what operations on what resources/subresources the webhook cares about. + // The webhook cares about an operation if it matches _any_ Rule. + Rules []RuleWithOperations `json:"rules,omitempty" protobuf:"bytes,3,rep,name=rules"` + + // FailurePolicy defines how unrecognized errors from the admission endpoint are handled - + // allowed values are Ignore or Fail. Defaults to Ignore. + // +optional + FailurePolicy *FailurePolicyType `json:"failurePolicy,omitempty" protobuf:"bytes,4,opt,name=failurePolicy,casttype=FailurePolicyType"` +} + +// RuleWithOperations is a tuple of Operations and Resources. It is recommended to make +// sure that all the tuple expansions are valid. +type RuleWithOperations struct { + // Operations is the operations the admission hook cares about - CREATE, UPDATE, or * + // for all operations. + // If '*' is present, the length of the slice must be one. + // Required. + Operations []OperationType `json:"operations,omitempty" protobuf:"bytes,1,rep,name=operations,casttype=OperationType"` + // Rule is embedded, it describes other criteria of the rule, like + // APIGroups, APIVersions, Resources, etc. + Rule `json:",inline" protobuf:"bytes,2,opt,name=rule"` +} + +type OperationType string + +// The constants should be kept in sync with those defined in k8s.io/kubernetes/pkg/admission/interface.go. +const ( + OperationAll OperationType = "*" + Create OperationType = "CREATE" + Update OperationType = "UPDATE" + Delete OperationType = "DELETE" + Connect OperationType = "CONNECT" +) + +// AdmissionHookClientConfig contains the information to make a TLS +// connection with the webhook +type AdmissionHookClientConfig struct { + // Service is a reference to the service for this webhook. If there is only + // one port open for the service, that port will be used. If there are multiple + // ports open, port 443 will be used if it is open, otherwise it is an error. + // Required + Service ServiceReference `json:"service" protobuf:"bytes,1,opt,name=service"` + // CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. + // Required + CABundle []byte `json:"caBundle" protobuf:"bytes,2,opt,name=caBundle"` +} + +// ServiceReference holds a reference to Service.legacy.k8s.io +type ServiceReference struct { + // Namespace is the namespace of the service + // Required + Namespace string `json:"namespace" protobuf:"bytes,1,opt,name=namespace"` + // Name is the name of the service + // Required + Name string `json:"name" protobuf:"bytes,2,opt,name=name"` +} diff --git a/pkg/apis/admissionregistration/v1alpha1/types_swagger_doc_generated.go b/pkg/apis/admissionregistration/v1alpha1/types_swagger_doc_generated.go new file mode 100644 index 0000000000000..80f9120b37b20 --- /dev/null +++ b/pkg/apis/admissionregistration/v1alpha1/types_swagger_doc_generated.go @@ -0,0 +1,133 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +package v1alpha1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_AdmissionHookClientConfig = map[string]string{ + "": "AdmissionHookClientConfig contains the information to make a TLS connection with the webhook", + "service": "Service is a reference to the service for this webhook. If there is only one port open for the service, that port will be used. If there are multiple ports open, port 443 will be used if it is open, otherwise it is an error. Required", + "caBundle": "CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. Required", +} + +func (AdmissionHookClientConfig) SwaggerDoc() map[string]string { + return map_AdmissionHookClientConfig +} + +var map_ExternalAdmissionHook = map[string]string{ + "": "ExternalAdmissionHook describes an external admission webhook and the resources and operations it applies to.", + "name": "The name of the external admission webhook. Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where \"imagepolicy\" is the name of the webhook, and kubernetes.io is the name of the organization. Required.", + "clientConfig": "ClientConfig defines how to communicate with the hook. Required", + "rules": "Rules describes what operations on what resources/subresources the webhook cares about. The webhook cares about an operation if it matches _any_ Rule.", + "failurePolicy": "FailurePolicy defines how unrecognized errors from the admission endpoint are handled - allowed values are Ignore or Fail. Defaults to Ignore.", +} + +func (ExternalAdmissionHook) SwaggerDoc() map[string]string { + return map_ExternalAdmissionHook +} + +var map_ExternalAdmissionHookConfiguration = map[string]string{ + "": "ExternalAdmissionHookConfiguration describes the configuration of initializers.", + "metadata": "Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.", + "externalAdmissionHooks": "ExternalAdmissionHooks is a list of external admission webhooks and the affected resources and operations.", +} + +func (ExternalAdmissionHookConfiguration) SwaggerDoc() map[string]string { + return map_ExternalAdmissionHookConfiguration +} + +var map_ExternalAdmissionHookConfigurationList = map[string]string{ + "": "ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration.", + "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "items": "List of ExternalAdmissionHookConfiguration.", +} + +func (ExternalAdmissionHookConfigurationList) SwaggerDoc() map[string]string { + return map_ExternalAdmissionHookConfigurationList +} + +var map_Initializer = map[string]string{ + "": "Initializer describes the name and the failure policy of an initializer, and what resources it applies to.", + "name": "Name is the identifier of the initializer. It will be added to the object that needs to be initialized. Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where \"alwayspullimages\" is the name of the webhook, and kubernetes.io is the name of the organization. Required", + "rules": "Rules describes what resources/subresources the initializer cares about. The initializer cares about an operation if it matches _any_ Rule.", + "failurePolicy": "FailurePolicy defines what happens if the responsible initializer controller fails to takes action. Allowed values are Ignore, or Fail. If \"Ignore\" is set, initializer is removed from the initializers list of an object if the timeout is reached; If \"Fail\" is set, admissionregistration returns timeout error if the timeout is reached.", +} + +func (Initializer) SwaggerDoc() map[string]string { + return map_Initializer +} + +var map_InitializerConfiguration = map[string]string{ + "": "InitializerConfiguration describes the configuration of initializers.", + "metadata": "Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.", + "initializers": "Initializers is a list of resources and their default initializers Order-sensitive. When merging multiple InitializerConfigurations, we sort the initializers from different InitializerConfigurations by the name of the InitializerConfigurations; the order of the initializers from the same InitializerConfiguration is preserved.", +} + +func (InitializerConfiguration) SwaggerDoc() map[string]string { + return map_InitializerConfiguration +} + +var map_InitializerConfigurationList = map[string]string{ + "": "InitializerConfigurationList is a list of InitializerConfiguration.", + "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "items": "List of InitializerConfiguration.", +} + +func (InitializerConfigurationList) SwaggerDoc() map[string]string { + return map_InitializerConfigurationList +} + +var map_Rule = map[string]string{ + "": "Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended to make sure that all the tuple expansions are valid.", + "apiGroups": "APIGroups is the API groups the resources belong to. '*' is all groups. If '*' is present, the length of the slice must be one. Required.", + "apiVersions": "APIVersions is the API versions the resources belong to. '*' is all versions. If '*' is present, the length of the slice must be one. Required.", + "resources": "Resources is a list of resources this rule applies to.\n\nFor example: 'pods' means pods. 'pods/log' means the log subresource of pods. '*' means all resources, but not subresources. 'pods/*' means all subresources of pods. '*/scale' means all scale subresources. '*/*' means all resources and their subresources.\n\nIf '*' or '*/*' is present, the length of the slice must be one. Required.", +} + +func (Rule) SwaggerDoc() map[string]string { + return map_Rule +} + +var map_RuleWithOperations = map[string]string{ + "": "RuleWithOperations is a tuple of Operations and Resources. It is recommended to make sure that all the tuple expansions are valid.", + "operations": "Operations is the operations the admission hook cares about - CREATE, UPDATE, or * for all operations. If '*' is present, the length of the slice must be one. Required.", +} + +func (RuleWithOperations) SwaggerDoc() map[string]string { + return map_RuleWithOperations +} + +var map_ServiceReference = map[string]string{ + "": "ServiceReference holds a reference to Service.legacy.k8s.io", + "namespace": "Namespace is the namespace of the service Required", + "name": "Name is the name of the service Required", +} + +func (ServiceReference) SwaggerDoc() map[string]string { + return map_ServiceReference +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/pkg/apis/admissionregistration/v1alpha1/zz_generated.conversion.go b/pkg/apis/admissionregistration/v1alpha1/zz_generated.conversion.go new file mode 100644 index 0000000000000..02c17b09138b2 --- /dev/null +++ b/pkg/apis/admissionregistration/v1alpha1/zz_generated.conversion.go @@ -0,0 +1,311 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v1alpha1 + +import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + admissionregistration "k8s.io/kubernetes/pkg/apis/admissionregistration" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig, + Convert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig, + Convert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook, + Convert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook, + Convert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration, + Convert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration, + Convert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList, + Convert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList, + Convert_v1alpha1_Initializer_To_admissionregistration_Initializer, + Convert_admissionregistration_Initializer_To_v1alpha1_Initializer, + Convert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration, + Convert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration, + Convert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList, + Convert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList, + Convert_v1alpha1_Rule_To_admissionregistration_Rule, + Convert_admissionregistration_Rule_To_v1alpha1_Rule, + Convert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations, + Convert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations, + Convert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference, + Convert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference, + ) +} + +func autoConvert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig(in *AdmissionHookClientConfig, out *admissionregistration.AdmissionHookClientConfig, s conversion.Scope) error { + if err := Convert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference(&in.Service, &out.Service, s); err != nil { + return err + } + out.CABundle = *(*[]byte)(unsafe.Pointer(&in.CABundle)) + return nil +} + +// Convert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig is an autogenerated conversion function. +func Convert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig(in *AdmissionHookClientConfig, out *admissionregistration.AdmissionHookClientConfig, s conversion.Scope) error { + return autoConvert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig(in, out, s) +} + +func autoConvert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig(in *admissionregistration.AdmissionHookClientConfig, out *AdmissionHookClientConfig, s conversion.Scope) error { + if err := Convert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference(&in.Service, &out.Service, s); err != nil { + return err + } + if in.CABundle == nil { + out.CABundle = make([]byte, 0) + } else { + out.CABundle = *(*[]byte)(unsafe.Pointer(&in.CABundle)) + } + return nil +} + +// Convert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig is an autogenerated conversion function. +func Convert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig(in *admissionregistration.AdmissionHookClientConfig, out *AdmissionHookClientConfig, s conversion.Scope) error { + return autoConvert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig(in, out, s) +} + +func autoConvert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook(in *ExternalAdmissionHook, out *admissionregistration.ExternalAdmissionHook, s conversion.Scope) error { + out.Name = in.Name + if err := Convert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig(&in.ClientConfig, &out.ClientConfig, s); err != nil { + return err + } + out.Rules = *(*[]admissionregistration.RuleWithOperations)(unsafe.Pointer(&in.Rules)) + out.FailurePolicy = (*admissionregistration.FailurePolicyType)(unsafe.Pointer(in.FailurePolicy)) + return nil +} + +// Convert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook is an autogenerated conversion function. +func Convert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook(in *ExternalAdmissionHook, out *admissionregistration.ExternalAdmissionHook, s conversion.Scope) error { + return autoConvert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook(in, out, s) +} + +func autoConvert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook(in *admissionregistration.ExternalAdmissionHook, out *ExternalAdmissionHook, s conversion.Scope) error { + out.Name = in.Name + if err := Convert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig(&in.ClientConfig, &out.ClientConfig, s); err != nil { + return err + } + out.Rules = *(*[]RuleWithOperations)(unsafe.Pointer(&in.Rules)) + out.FailurePolicy = (*FailurePolicyType)(unsafe.Pointer(in.FailurePolicy)) + return nil +} + +// Convert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook is an autogenerated conversion function. +func Convert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook(in *admissionregistration.ExternalAdmissionHook, out *ExternalAdmissionHook, s conversion.Scope) error { + return autoConvert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook(in, out, s) +} + +func autoConvert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration(in *ExternalAdmissionHookConfiguration, out *admissionregistration.ExternalAdmissionHookConfiguration, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.ExternalAdmissionHooks = *(*[]admissionregistration.ExternalAdmissionHook)(unsafe.Pointer(&in.ExternalAdmissionHooks)) + return nil +} + +// Convert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration is an autogenerated conversion function. +func Convert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration(in *ExternalAdmissionHookConfiguration, out *admissionregistration.ExternalAdmissionHookConfiguration, s conversion.Scope) error { + return autoConvert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration(in, out, s) +} + +func autoConvert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration(in *admissionregistration.ExternalAdmissionHookConfiguration, out *ExternalAdmissionHookConfiguration, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.ExternalAdmissionHooks = *(*[]ExternalAdmissionHook)(unsafe.Pointer(&in.ExternalAdmissionHooks)) + return nil +} + +// Convert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration is an autogenerated conversion function. +func Convert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration(in *admissionregistration.ExternalAdmissionHookConfiguration, out *ExternalAdmissionHookConfiguration, s conversion.Scope) error { + return autoConvert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration(in, out, s) +} + +func autoConvert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList(in *ExternalAdmissionHookConfigurationList, out *admissionregistration.ExternalAdmissionHookConfigurationList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]admissionregistration.ExternalAdmissionHookConfiguration)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList is an autogenerated conversion function. +func Convert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList(in *ExternalAdmissionHookConfigurationList, out *admissionregistration.ExternalAdmissionHookConfigurationList, s conversion.Scope) error { + return autoConvert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList(in, out, s) +} + +func autoConvert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList(in *admissionregistration.ExternalAdmissionHookConfigurationList, out *ExternalAdmissionHookConfigurationList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]ExternalAdmissionHookConfiguration, 0) + } else { + out.Items = *(*[]ExternalAdmissionHookConfiguration)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList is an autogenerated conversion function. +func Convert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList(in *admissionregistration.ExternalAdmissionHookConfigurationList, out *ExternalAdmissionHookConfigurationList, s conversion.Scope) error { + return autoConvert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList(in, out, s) +} + +func autoConvert_v1alpha1_Initializer_To_admissionregistration_Initializer(in *Initializer, out *admissionregistration.Initializer, s conversion.Scope) error { + out.Name = in.Name + out.Rules = *(*[]admissionregistration.Rule)(unsafe.Pointer(&in.Rules)) + out.FailurePolicy = (*admissionregistration.FailurePolicyType)(unsafe.Pointer(in.FailurePolicy)) + return nil +} + +// Convert_v1alpha1_Initializer_To_admissionregistration_Initializer is an autogenerated conversion function. +func Convert_v1alpha1_Initializer_To_admissionregistration_Initializer(in *Initializer, out *admissionregistration.Initializer, s conversion.Scope) error { + return autoConvert_v1alpha1_Initializer_To_admissionregistration_Initializer(in, out, s) +} + +func autoConvert_admissionregistration_Initializer_To_v1alpha1_Initializer(in *admissionregistration.Initializer, out *Initializer, s conversion.Scope) error { + out.Name = in.Name + out.Rules = *(*[]Rule)(unsafe.Pointer(&in.Rules)) + out.FailurePolicy = (*FailurePolicyType)(unsafe.Pointer(in.FailurePolicy)) + return nil +} + +// Convert_admissionregistration_Initializer_To_v1alpha1_Initializer is an autogenerated conversion function. +func Convert_admissionregistration_Initializer_To_v1alpha1_Initializer(in *admissionregistration.Initializer, out *Initializer, s conversion.Scope) error { + return autoConvert_admissionregistration_Initializer_To_v1alpha1_Initializer(in, out, s) +} + +func autoConvert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration(in *InitializerConfiguration, out *admissionregistration.InitializerConfiguration, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Initializers = *(*[]admissionregistration.Initializer)(unsafe.Pointer(&in.Initializers)) + return nil +} + +// Convert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration is an autogenerated conversion function. +func Convert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration(in *InitializerConfiguration, out *admissionregistration.InitializerConfiguration, s conversion.Scope) error { + return autoConvert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration(in, out, s) +} + +func autoConvert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration(in *admissionregistration.InitializerConfiguration, out *InitializerConfiguration, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Initializers = *(*[]Initializer)(unsafe.Pointer(&in.Initializers)) + return nil +} + +// Convert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration is an autogenerated conversion function. +func Convert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration(in *admissionregistration.InitializerConfiguration, out *InitializerConfiguration, s conversion.Scope) error { + return autoConvert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration(in, out, s) +} + +func autoConvert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList(in *InitializerConfigurationList, out *admissionregistration.InitializerConfigurationList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]admissionregistration.InitializerConfiguration)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList is an autogenerated conversion function. +func Convert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList(in *InitializerConfigurationList, out *admissionregistration.InitializerConfigurationList, s conversion.Scope) error { + return autoConvert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList(in, out, s) +} + +func autoConvert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList(in *admissionregistration.InitializerConfigurationList, out *InitializerConfigurationList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]InitializerConfiguration, 0) + } else { + out.Items = *(*[]InitializerConfiguration)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList is an autogenerated conversion function. +func Convert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList(in *admissionregistration.InitializerConfigurationList, out *InitializerConfigurationList, s conversion.Scope) error { + return autoConvert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList(in, out, s) +} + +func autoConvert_v1alpha1_Rule_To_admissionregistration_Rule(in *Rule, out *admissionregistration.Rule, s conversion.Scope) error { + out.APIGroups = *(*[]string)(unsafe.Pointer(&in.APIGroups)) + out.APIVersions = *(*[]string)(unsafe.Pointer(&in.APIVersions)) + out.Resources = *(*[]string)(unsafe.Pointer(&in.Resources)) + return nil +} + +// Convert_v1alpha1_Rule_To_admissionregistration_Rule is an autogenerated conversion function. +func Convert_v1alpha1_Rule_To_admissionregistration_Rule(in *Rule, out *admissionregistration.Rule, s conversion.Scope) error { + return autoConvert_v1alpha1_Rule_To_admissionregistration_Rule(in, out, s) +} + +func autoConvert_admissionregistration_Rule_To_v1alpha1_Rule(in *admissionregistration.Rule, out *Rule, s conversion.Scope) error { + out.APIGroups = *(*[]string)(unsafe.Pointer(&in.APIGroups)) + out.APIVersions = *(*[]string)(unsafe.Pointer(&in.APIVersions)) + out.Resources = *(*[]string)(unsafe.Pointer(&in.Resources)) + return nil +} + +// Convert_admissionregistration_Rule_To_v1alpha1_Rule is an autogenerated conversion function. +func Convert_admissionregistration_Rule_To_v1alpha1_Rule(in *admissionregistration.Rule, out *Rule, s conversion.Scope) error { + return autoConvert_admissionregistration_Rule_To_v1alpha1_Rule(in, out, s) +} + +func autoConvert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations(in *RuleWithOperations, out *admissionregistration.RuleWithOperations, s conversion.Scope) error { + out.Operations = *(*[]admissionregistration.OperationType)(unsafe.Pointer(&in.Operations)) + if err := Convert_v1alpha1_Rule_To_admissionregistration_Rule(&in.Rule, &out.Rule, s); err != nil { + return err + } + return nil +} + +// Convert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations is an autogenerated conversion function. +func Convert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations(in *RuleWithOperations, out *admissionregistration.RuleWithOperations, s conversion.Scope) error { + return autoConvert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations(in, out, s) +} + +func autoConvert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations(in *admissionregistration.RuleWithOperations, out *RuleWithOperations, s conversion.Scope) error { + out.Operations = *(*[]OperationType)(unsafe.Pointer(&in.Operations)) + if err := Convert_admissionregistration_Rule_To_v1alpha1_Rule(&in.Rule, &out.Rule, s); err != nil { + return err + } + return nil +} + +// Convert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations is an autogenerated conversion function. +func Convert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations(in *admissionregistration.RuleWithOperations, out *RuleWithOperations, s conversion.Scope) error { + return autoConvert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations(in, out, s) +} + +func autoConvert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference(in *ServiceReference, out *admissionregistration.ServiceReference, s conversion.Scope) error { + out.Namespace = in.Namespace + out.Name = in.Name + return nil +} + +// Convert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference is an autogenerated conversion function. +func Convert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference(in *ServiceReference, out *admissionregistration.ServiceReference, s conversion.Scope) error { + return autoConvert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference(in, out, s) +} + +func autoConvert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference(in *admissionregistration.ServiceReference, out *ServiceReference, s conversion.Scope) error { + out.Namespace = in.Namespace + out.Name = in.Name + return nil +} + +// Convert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference is an autogenerated conversion function. +func Convert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference(in *admissionregistration.ServiceReference, out *ServiceReference, s conversion.Scope) error { + return autoConvert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference(in, out, s) +} diff --git a/pkg/apis/admissionregistration/v1alpha1/zz_generated.deepcopy.go b/pkg/apis/admissionregistration/v1alpha1/zz_generated.deepcopy.go new file mode 100644 index 0000000000000..526dbe3a2202e --- /dev/null +++ b/pkg/apis/admissionregistration/v1alpha1/zz_generated.deepcopy.go @@ -0,0 +1,254 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_AdmissionHookClientConfig, InType: reflect.TypeOf(&AdmissionHookClientConfig{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_ExternalAdmissionHook, InType: reflect.TypeOf(&ExternalAdmissionHook{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_ExternalAdmissionHookConfiguration, InType: reflect.TypeOf(&ExternalAdmissionHookConfiguration{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_ExternalAdmissionHookConfigurationList, InType: reflect.TypeOf(&ExternalAdmissionHookConfigurationList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_Initializer, InType: reflect.TypeOf(&Initializer{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_InitializerConfiguration, InType: reflect.TypeOf(&InitializerConfiguration{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_InitializerConfigurationList, InType: reflect.TypeOf(&InitializerConfigurationList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_Rule, InType: reflect.TypeOf(&Rule{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_RuleWithOperations, InType: reflect.TypeOf(&RuleWithOperations{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_ServiceReference, InType: reflect.TypeOf(&ServiceReference{})}, + ) +} + +// DeepCopy_v1alpha1_AdmissionHookClientConfig is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_AdmissionHookClientConfig(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*AdmissionHookClientConfig) + out := out.(*AdmissionHookClientConfig) + *out = *in + if in.CABundle != nil { + in, out := &in.CABundle, &out.CABundle + *out = make([]byte, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1alpha1_ExternalAdmissionHook is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_ExternalAdmissionHook(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHook) + out := out.(*ExternalAdmissionHook) + *out = *in + if err := DeepCopy_v1alpha1_AdmissionHookClientConfig(&in.ClientConfig, &out.ClientConfig, c); err != nil { + return err + } + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]RuleWithOperations, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_RuleWithOperations(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.FailurePolicy != nil { + in, out := &in.FailurePolicy, &out.FailurePolicy + *out = new(FailurePolicyType) + **out = **in + } + return nil + } +} + +// DeepCopy_v1alpha1_ExternalAdmissionHookConfiguration is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_ExternalAdmissionHookConfiguration(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHookConfiguration) + out := out.(*ExternalAdmissionHookConfiguration) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.ExternalAdmissionHooks != nil { + in, out := &in.ExternalAdmissionHooks, &out.ExternalAdmissionHooks + *out = make([]ExternalAdmissionHook, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_ExternalAdmissionHook(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_ExternalAdmissionHookConfigurationList is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_ExternalAdmissionHookConfigurationList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHookConfigurationList) + out := out.(*ExternalAdmissionHookConfigurationList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ExternalAdmissionHookConfiguration, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_ExternalAdmissionHookConfiguration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_Initializer is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_Initializer(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Initializer) + out := out.(*Initializer) + *out = *in + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]Rule, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_Rule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.FailurePolicy != nil { + in, out := &in.FailurePolicy, &out.FailurePolicy + *out = new(FailurePolicyType) + **out = **in + } + return nil + } +} + +// DeepCopy_v1alpha1_InitializerConfiguration is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_InitializerConfiguration(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*InitializerConfiguration) + out := out.(*InitializerConfiguration) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.Initializers != nil { + in, out := &in.Initializers, &out.Initializers + *out = make([]Initializer, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_Initializer(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_InitializerConfigurationList is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_InitializerConfigurationList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*InitializerConfigurationList) + out := out.(*InitializerConfigurationList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]InitializerConfiguration, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_InitializerConfiguration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_Rule is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_Rule(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Rule) + out := out.(*Rule) + *out = *in + if in.APIGroups != nil { + in, out := &in.APIGroups, &out.APIGroups + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.APIVersions != nil { + in, out := &in.APIVersions, &out.APIVersions + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Resources != nil { + in, out := &in.Resources, &out.Resources + *out = make([]string, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1alpha1_RuleWithOperations is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_RuleWithOperations(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RuleWithOperations) + out := out.(*RuleWithOperations) + *out = *in + if in.Operations != nil { + in, out := &in.Operations, &out.Operations + *out = make([]OperationType, len(*in)) + copy(*out, *in) + } + if err := DeepCopy_v1alpha1_Rule(&in.Rule, &out.Rule, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1alpha1_ServiceReference is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_ServiceReference(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ServiceReference) + out := out.(*ServiceReference) + *out = *in + return nil + } +} diff --git a/pkg/apis/admissionregistration/v1alpha1/zz_generated.defaults.go b/pkg/apis/admissionregistration/v1alpha1/zz_generated.defaults.go new file mode 100644 index 0000000000000..74fea7f418913 --- /dev/null +++ b/pkg/apis/admissionregistration/v1alpha1/zz_generated.defaults.go @@ -0,0 +1,70 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1alpha1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + scheme.AddTypeDefaultingFunc(&ExternalAdmissionHookConfiguration{}, func(obj interface{}) { + SetObjectDefaults_ExternalAdmissionHookConfiguration(obj.(*ExternalAdmissionHookConfiguration)) + }) + scheme.AddTypeDefaultingFunc(&ExternalAdmissionHookConfigurationList{}, func(obj interface{}) { + SetObjectDefaults_ExternalAdmissionHookConfigurationList(obj.(*ExternalAdmissionHookConfigurationList)) + }) + scheme.AddTypeDefaultingFunc(&InitializerConfiguration{}, func(obj interface{}) { SetObjectDefaults_InitializerConfiguration(obj.(*InitializerConfiguration)) }) + scheme.AddTypeDefaultingFunc(&InitializerConfigurationList{}, func(obj interface{}) { + SetObjectDefaults_InitializerConfigurationList(obj.(*InitializerConfigurationList)) + }) + return nil +} + +func SetObjectDefaults_ExternalAdmissionHookConfiguration(in *ExternalAdmissionHookConfiguration) { + for i := range in.ExternalAdmissionHooks { + a := &in.ExternalAdmissionHooks[i] + SetDefaults_ExternalAdmissionHook(a) + } +} + +func SetObjectDefaults_ExternalAdmissionHookConfigurationList(in *ExternalAdmissionHookConfigurationList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_ExternalAdmissionHookConfiguration(a) + } +} + +func SetObjectDefaults_InitializerConfiguration(in *InitializerConfiguration) { + for i := range in.Initializers { + a := &in.Initializers[i] + SetDefaults_Initializer(a) + } +} + +func SetObjectDefaults_InitializerConfigurationList(in *InitializerConfigurationList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_InitializerConfiguration(a) + } +} diff --git a/pkg/apis/admissionregistration/validation/BUILD b/pkg/apis/admissionregistration/validation/BUILD new file mode 100644 index 0000000000000..fe15831602613 --- /dev/null +++ b/pkg/apis/admissionregistration/validation/BUILD @@ -0,0 +1,46 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["validation_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//pkg/apis/admissionregistration:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = ["validation.go"], + tags = ["automanaged"], + deps = [ + "//pkg/apis/admissionregistration:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/validation:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation/field:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/apis/admissionregistration/validation/validation.go b/pkg/apis/admissionregistration/validation/validation.go new file mode 100644 index 0000000000000..5425b16bebbce --- /dev/null +++ b/pkg/apis/admissionregistration/validation/validation.go @@ -0,0 +1,174 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package validation + +import ( + "strings" + + genericvalidation "k8s.io/apimachinery/pkg/api/validation" + "k8s.io/apimachinery/pkg/util/sets" + validationutil "k8s.io/apimachinery/pkg/util/validation" + "k8s.io/apimachinery/pkg/util/validation/field" + "k8s.io/kubernetes/pkg/apis/admissionregistration" +) + +func ValidateInitializerConfiguration(ic *admissionregistration.InitializerConfiguration) field.ErrorList { + allErrors := genericvalidation.ValidateObjectMeta(&ic.ObjectMeta, false, genericvalidation.NameIsDNSSubdomain, field.NewPath("metadata")) + for i, initializer := range ic.Initializers { + allErrors = append(allErrors, validateInitializer(&initializer, field.NewPath("initializers").Index(i))...) + } + return allErrors +} + +func validateInitializer(initializer *admissionregistration.Initializer, fldPath *field.Path) field.ErrorList { + var allErrors field.ErrorList + // initlializer.Name must be fully qualified + if len(initializer.Name) == 0 { + allErrors = append(allErrors, field.Required(fldPath.Child("name"), "")) + } + if errs := validationutil.IsDNS1123Subdomain(initializer.Name); len(errs) > 0 { + allErrors = append(allErrors, field.Invalid(fldPath.Child("name"), initializer.Name, strings.Join(errs, ","))) + } + if len(strings.Split(initializer.Name, ".")) < 3 { + allErrors = append(allErrors, field.Invalid(fldPath.Child("name"), initializer.Name, "should be a domain with at least two dots")) + } + + for i, rule := range initializer.Rules { + allErrors = append(allErrors, validateRule(&rule, fldPath.Child("rules").Index(i))...) + } + // TODO: relax the validation rule when admissionregistration is beta. + if initializer.FailurePolicy != nil && *initializer.FailurePolicy != admissionregistration.Ignore { + allErrors = append(allErrors, field.NotSupported(fldPath.Child("failurePolicy"), *initializer.FailurePolicy, []string{string(admissionregistration.Ignore)})) + } + return allErrors +} + +func hasWildcard(slice []string) bool { + for _, s := range slice { + if s == "*" { + return true + } + } + return false +} + +func validateRule(rule *admissionregistration.Rule, fldPath *field.Path) field.ErrorList { + var allErrors field.ErrorList + if len(rule.APIGroups) == 0 { + allErrors = append(allErrors, field.Required(fldPath.Child("apiGroups"), "")) + } + if len(rule.APIGroups) > 1 && hasWildcard(rule.APIGroups) { + allErrors = append(allErrors, field.Invalid(fldPath.Child("apiGroups"), rule.APIGroups, "if '*' is present, must not specify other API groups")) + } + // Note: group could be empty, e.g., the legacy "v1" API + if len(rule.APIVersions) == 0 { + allErrors = append(allErrors, field.Required(fldPath.Child("apiVersions"), "")) + } + if len(rule.APIVersions) > 1 && hasWildcard(rule.APIVersions) { + allErrors = append(allErrors, field.Invalid(fldPath.Child("apiVersions"), rule.APIVersions, "if '*' is present, must not specify other API versions")) + } + for i, version := range rule.APIVersions { + if version == "" { + allErrors = append(allErrors, field.Required(fldPath.Child("apiVersions").Index(i), "")) + } + } + if len(rule.Resources) == 0 { + allErrors = append(allErrors, field.Required(fldPath.Child("resources"), "")) + } + if len(rule.Resources) > 1 && hasWildcard(rule.Resources) { + allErrors = append(allErrors, field.Invalid(fldPath.Child("Resources"), rule.Resources, "if '*' is present, must not specify other resources")) + } + for i, resource := range rule.Resources { + if resource == "" { + allErrors = append(allErrors, field.Required(fldPath.Child("resources").Index(i), "")) + } + } + return allErrors +} + +func ValidateInitializerConfigurationUpdate(newIC, oldIC *admissionregistration.InitializerConfiguration) field.ErrorList { + return ValidateInitializerConfiguration(newIC) +} + +func ValidateExternalAdmissionHookConfiguration(e *admissionregistration.ExternalAdmissionHookConfiguration) field.ErrorList { + allErrors := genericvalidation.ValidateObjectMeta(&e.ObjectMeta, false, genericvalidation.NameIsDNSSubdomain, field.NewPath("metadata")) + for i, hook := range e.ExternalAdmissionHooks { + allErrors = append(allErrors, validateExternalAdmissionHook(&hook, field.NewPath("externalAdmissionHook").Index(i))...) + } + return allErrors +} + +func validateExternalAdmissionHook(hook *admissionregistration.ExternalAdmissionHook, fldPath *field.Path) field.ErrorList { + var allErrors field.ErrorList + // hook.Name must be fully qualified + if len(hook.Name) == 0 { + allErrors = append(allErrors, field.Required(fldPath.Child("name"), "")) + } + if errs := validationutil.IsDNS1123Subdomain(hook.Name); len(errs) > 0 { + allErrors = append(allErrors, field.Invalid(fldPath.Child("name"), hook.Name, strings.Join(errs, ","))) + } + if len(strings.Split(hook.Name, ".")) < 3 { + allErrors = append(allErrors, field.Invalid(fldPath.Child("name"), hook.Name, "should be a domain with at least two dots")) + } + + for i, rule := range hook.Rules { + allErrors = append(allErrors, validateRuleWithOperations(&rule, fldPath.Child("rules").Index(i))...) + } + // TODO: relax the validation rule when admissionregistration is beta. + if hook.FailurePolicy != nil && *hook.FailurePolicy != admissionregistration.Ignore { + allErrors = append(allErrors, field.NotSupported(fldPath.Child("failurePolicy"), *hook.FailurePolicy, []string{string(admissionregistration.Ignore)})) + } + return allErrors +} + +var supportedOperations = sets.NewString( + string(admissionregistration.OperationAll), + string(admissionregistration.Create), + string(admissionregistration.Update), + string(admissionregistration.Delete), + string(admissionregistration.Connect), +) + +func hasWildcardOperation(operations []admissionregistration.OperationType) bool { + for _, o := range operations { + if o == admissionregistration.OperationAll { + return true + } + } + return false +} + +func validateRuleWithOperations(ruleWithOperations *admissionregistration.RuleWithOperations, fldPath *field.Path) field.ErrorList { + var allErrors field.ErrorList + if len(ruleWithOperations.Operations) == 0 { + allErrors = append(allErrors, field.Required(fldPath.Child("operations"), "")) + } + if len(ruleWithOperations.Operations) > 1 && hasWildcardOperation(ruleWithOperations.Operations) { + allErrors = append(allErrors, field.Invalid(fldPath.Child("operations"), ruleWithOperations.Operations, "if '*' is present, must not specify other operations")) + } + for i, operation := range ruleWithOperations.Operations { + if !supportedOperations.Has(string(operation)) { + allErrors = append(allErrors, field.NotSupported(fldPath.Child("operations").Index(i), operation, supportedOperations.List())) + } + } + allErrors = append(allErrors, validateRule(&ruleWithOperations.Rule, fldPath)...) + return allErrors +} + +func ValidateExternalAdmissionHookConfigurationUpdate(newC, oldC *admissionregistration.ExternalAdmissionHookConfiguration) field.ErrorList { + return ValidateExternalAdmissionHookConfiguration(newC) +} diff --git a/pkg/apis/admissionregistration/validation/validation_test.go b/pkg/apis/admissionregistration/validation/validation_test.go new file mode 100644 index 0000000000000..e700d6a380701 --- /dev/null +++ b/pkg/apis/admissionregistration/validation/validation_test.go @@ -0,0 +1,378 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package validation + +import ( + "strings" + "testing" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/kubernetes/pkg/apis/admissionregistration" +) + +func getInitializerConfiguration(initializers []admissionregistration.Initializer) *admissionregistration.InitializerConfiguration { + return &admissionregistration.InitializerConfiguration{ + ObjectMeta: metav1.ObjectMeta{ + Name: "config", + }, + Initializers: initializers, + } +} + +func TestValidateInitializerConfiguration(t *testing.T) { + tests := []struct { + name string + config *admissionregistration.InitializerConfiguration + expectedError string + }{ + { + name: "0 rule is valid", + config: getInitializerConfiguration( + []admissionregistration.Initializer{ + { + Name: "initializer.k8s.io", + }, + }), + }, + { + name: "all initializers must have a fully qualified name", + config: getInitializerConfiguration( + []admissionregistration.Initializer{ + { + Name: "initializer.k8s.io", + }, + { + Name: "k8s.io", + }, + { + Name: "", + }, + }), + expectedError: `initializers[1].name: Invalid value: "k8s.io": should be a domain with at least two dots, initializers[2].name: Required value`, + }, + { + name: "APIGroups must not be empty or nil", + config: getInitializerConfiguration( + []admissionregistration.Initializer{ + { + Name: "initializer.k8s.io", + Rules: []admissionregistration.Rule{ + { + APIGroups: []string{}, + APIVersions: []string{"a"}, + Resources: []string{"a"}, + }, + { + APIGroups: nil, + APIVersions: []string{"a"}, + Resources: []string{"a"}, + }, + }, + }, + }), + expectedError: `initializers[0].rules[0].apiGroups: Required value, initializers[0].rules[1].apiGroups: Required value`, + }, + { + name: "APIVersions must not be empty or nil", + config: getInitializerConfiguration( + []admissionregistration.Initializer{ + { + Name: "initializer.k8s.io", + Rules: []admissionregistration.Rule{ + { + APIGroups: []string{"a"}, + APIVersions: []string{}, + Resources: []string{"a"}, + }, + { + APIGroups: []string{"a"}, + APIVersions: nil, + Resources: []string{"a"}, + }, + }, + }, + }), + expectedError: `initializers[0].rules[0].apiVersions: Required value, initializers[0].rules[1].apiVersions: Required value`, + }, + { + name: "Resources must not be empty or nil", + config: getInitializerConfiguration( + []admissionregistration.Initializer{ + { + Name: "initializer.k8s.io", + Rules: []admissionregistration.Rule{ + { + APIGroups: []string{"a"}, + APIVersions: []string{"a"}, + Resources: []string{}, + }, + { + APIGroups: []string{"a"}, + APIVersions: []string{"a"}, + Resources: nil, + }, + }, + }, + }), + expectedError: `initializers[0].rules[0].resources: Required value, initializers[0].rules[1].resources: Required value`, + }, + { + name: "\"\" is a valid APIGroup", + config: getInitializerConfiguration( + []admissionregistration.Initializer{ + { + Name: "initializer.k8s.io", + Rules: []admissionregistration.Rule{ + { + APIGroups: []string{"a", ""}, + APIVersions: []string{"a"}, + Resources: []string{"a"}, + }, + }, + }, + }), + }, + { + name: "\"\" is NOT a valid APIVersion", + config: getInitializerConfiguration( + []admissionregistration.Initializer{ + { + Name: "initializer.k8s.io", + Rules: []admissionregistration.Rule{ + { + APIGroups: []string{"a"}, + APIVersions: []string{"a", ""}, + Resources: []string{"a"}, + }, + }, + }, + }), + expectedError: "apiVersions[1]: Required value", + }, + { + name: "\"\" is NOT a valid Resource", + config: getInitializerConfiguration( + []admissionregistration.Initializer{ + { + Name: "initializer.k8s.io", + Rules: []admissionregistration.Rule{ + { + APIGroups: []string{"a"}, + APIVersions: []string{"a"}, + Resources: []string{"a", ""}, + }, + }, + }, + }), + expectedError: "resources[1]: Required value", + }, + { + name: "wildcard cannot be mixed with other strings", + config: getInitializerConfiguration( + []admissionregistration.Initializer{ + { + Name: "initializer.k8s.io", + Rules: []admissionregistration.Rule{ + { + APIGroups: []string{"a", "*"}, + APIVersions: []string{"a", "*"}, + Resources: []string{"a", "*"}, + }, + }, + }, + }), + expectedError: `initializers[0].rules[0].apiGroups: Invalid value: []string{"a", "*"}: if '*' is present, must not specify other API groups, initializers[0].rules[0].apiVersions: Invalid value: []string{"a", "*"}: if '*' is present, must not specify other API versions, initializers[0].rules[0].Resources: Invalid value: []string{"a", "*"}: if '*' is present, must not specify other resources`, + }, + { + name: "FailurePolicy can only be \"Ignore\"", + config: getInitializerConfiguration( + []admissionregistration.Initializer{ + { + Name: "initializer.k8s.io", + FailurePolicy: func() *admissionregistration.FailurePolicyType { + r := admissionregistration.Fail + return &r + }(), + }, + }), + expectedError: `failurePolicy: Unsupported value: "Fail": supported values: Ignore`, + }, + } + + for _, test := range tests { + errs := ValidateInitializerConfiguration(test.config) + err := errs.ToAggregate() + if err != nil { + if e, a := test.expectedError, err.Error(); !strings.Contains(a, e) || e == "" { + t.Errorf("test case %s, expected to contain %s, got %s", test.name, e, a) + } + } else { + if test.expectedError != "" { + t.Errorf("test case %s, unexpected no error, expected to contain %s", test.name, test.expectedError) + } + } + } +} + +func getExternalAdmissionHookConfiguration(hooks []admissionregistration.ExternalAdmissionHook) *admissionregistration.ExternalAdmissionHookConfiguration { + return &admissionregistration.ExternalAdmissionHookConfiguration{ + ObjectMeta: metav1.ObjectMeta{ + Name: "config", + }, + ExternalAdmissionHooks: hooks, + } +} + +func TestValidateExternalAdmissionHookConfiguration(t *testing.T) { + tests := []struct { + name string + config *admissionregistration.ExternalAdmissionHookConfiguration + expectedError string + }{ + { + name: "all ExternalAdmissionHook must have a fully qualified name", + config: getExternalAdmissionHookConfiguration( + []admissionregistration.ExternalAdmissionHook{ + { + Name: "webhook.k8s.io", + }, + { + Name: "k8s.io", + }, + { + Name: "", + }, + }), + expectedError: `externalAdmissionHook[1].name: Invalid value: "k8s.io": should be a domain with at least two dots, externalAdmissionHook[2].name: Required value`, + }, + { + name: "Operations must not be empty or nil", + config: getExternalAdmissionHookConfiguration( + []admissionregistration.ExternalAdmissionHook{ + { + Name: "webhook.k8s.io", + Rules: []admissionregistration.RuleWithOperations{ + { + Operations: []admissionregistration.OperationType{}, + Rule: admissionregistration.Rule{ + APIGroups: []string{"a"}, + APIVersions: []string{"a"}, + Resources: []string{"a"}, + }, + }, + { + Operations: nil, + Rule: admissionregistration.Rule{ + APIGroups: []string{"a"}, + APIVersions: []string{"a"}, + Resources: []string{"a"}, + }, + }, + }, + }, + }), + expectedError: `externalAdmissionHook[0].rules[0].operations: Required value, externalAdmissionHook[0].rules[1].operations: Required value`, + }, + { + name: "\"\" is NOT a valid operation", + config: getExternalAdmissionHookConfiguration( + []admissionregistration.ExternalAdmissionHook{ + { + Name: "webhook.k8s.io", + Rules: []admissionregistration.RuleWithOperations{ + { + Operations: []admissionregistration.OperationType{"CREATE", ""}, + Rule: admissionregistration.Rule{ + APIGroups: []string{"a"}, + APIVersions: []string{"a"}, + Resources: []string{"a"}, + }, + }, + }, + }, + }), + expectedError: `Unsupported value: ""`, + }, + { + name: "operation must be either create/update/delete/connect", + config: getExternalAdmissionHookConfiguration( + []admissionregistration.ExternalAdmissionHook{ + { + Name: "webhook.k8s.io", + Rules: []admissionregistration.RuleWithOperations{ + { + Operations: []admissionregistration.OperationType{"PATCH"}, + Rule: admissionregistration.Rule{ + APIGroups: []string{"a"}, + APIVersions: []string{"a"}, + Resources: []string{"a"}, + }, + }, + }, + }, + }), + expectedError: `Unsupported value: "PATCH"`, + }, + { + name: "wildcard cannot be mixed with other strings", + config: getExternalAdmissionHookConfiguration( + []admissionregistration.ExternalAdmissionHook{ + { + Name: "webhook.k8s.io", + Rules: []admissionregistration.RuleWithOperations{ + { + Operations: []admissionregistration.OperationType{"CREATE", "*"}, + Rule: admissionregistration.Rule{ + APIGroups: []string{"a"}, + APIVersions: []string{"a"}, + Resources: []string{"a"}, + }, + }, + }, + }, + }), + expectedError: `if '*' is present, must not specify other operations`, + }, + { + name: "FailurePolicy can only be \"Ignore\"", + config: getExternalAdmissionHookConfiguration( + []admissionregistration.ExternalAdmissionHook{ + { + Name: "initializer.k8s.io", + FailurePolicy: func() *admissionregistration.FailurePolicyType { + r := admissionregistration.Fail + return &r + }(), + }, + }), + expectedError: `failurePolicy: Unsupported value: "Fail": supported values: Ignore`, + }, + } + for _, test := range tests { + errs := ValidateExternalAdmissionHookConfiguration(test.config) + err := errs.ToAggregate() + if err != nil { + if e, a := test.expectedError, err.Error(); !strings.Contains(a, e) || e == "" { + t.Errorf("test case %s, expected to contain %s, got %s", test.name, e, a) + } + } else { + if test.expectedError != "" { + t.Errorf("test case %s, unexpected no error, expected to contain %s", test.name, test.expectedError) + } + } + } +} diff --git a/pkg/apis/admissionregistration/zz_generated.deepcopy.go b/pkg/apis/admissionregistration/zz_generated.deepcopy.go new file mode 100644 index 0000000000000..e41f28efa1eb2 --- /dev/null +++ b/pkg/apis/admissionregistration/zz_generated.deepcopy.go @@ -0,0 +1,254 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package admissionregistration + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_AdmissionHookClientConfig, InType: reflect.TypeOf(&AdmissionHookClientConfig{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_ExternalAdmissionHook, InType: reflect.TypeOf(&ExternalAdmissionHook{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_ExternalAdmissionHookConfiguration, InType: reflect.TypeOf(&ExternalAdmissionHookConfiguration{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_ExternalAdmissionHookConfigurationList, InType: reflect.TypeOf(&ExternalAdmissionHookConfigurationList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_Initializer, InType: reflect.TypeOf(&Initializer{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_InitializerConfiguration, InType: reflect.TypeOf(&InitializerConfiguration{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_InitializerConfigurationList, InType: reflect.TypeOf(&InitializerConfigurationList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_Rule, InType: reflect.TypeOf(&Rule{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_RuleWithOperations, InType: reflect.TypeOf(&RuleWithOperations{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_ServiceReference, InType: reflect.TypeOf(&ServiceReference{})}, + ) +} + +// DeepCopy_admissionregistration_AdmissionHookClientConfig is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_AdmissionHookClientConfig(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*AdmissionHookClientConfig) + out := out.(*AdmissionHookClientConfig) + *out = *in + if in.CABundle != nil { + in, out := &in.CABundle, &out.CABundle + *out = make([]byte, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_admissionregistration_ExternalAdmissionHook is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_ExternalAdmissionHook(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHook) + out := out.(*ExternalAdmissionHook) + *out = *in + if err := DeepCopy_admissionregistration_AdmissionHookClientConfig(&in.ClientConfig, &out.ClientConfig, c); err != nil { + return err + } + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]RuleWithOperations, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_RuleWithOperations(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.FailurePolicy != nil { + in, out := &in.FailurePolicy, &out.FailurePolicy + *out = new(FailurePolicyType) + **out = **in + } + return nil + } +} + +// DeepCopy_admissionregistration_ExternalAdmissionHookConfiguration is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_ExternalAdmissionHookConfiguration(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHookConfiguration) + out := out.(*ExternalAdmissionHookConfiguration) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.ExternalAdmissionHooks != nil { + in, out := &in.ExternalAdmissionHooks, &out.ExternalAdmissionHooks + *out = make([]ExternalAdmissionHook, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_ExternalAdmissionHook(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_admissionregistration_ExternalAdmissionHookConfigurationList is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_ExternalAdmissionHookConfigurationList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHookConfigurationList) + out := out.(*ExternalAdmissionHookConfigurationList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ExternalAdmissionHookConfiguration, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_ExternalAdmissionHookConfiguration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_admissionregistration_Initializer is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_Initializer(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Initializer) + out := out.(*Initializer) + *out = *in + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]Rule, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_Rule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.FailurePolicy != nil { + in, out := &in.FailurePolicy, &out.FailurePolicy + *out = new(FailurePolicyType) + **out = **in + } + return nil + } +} + +// DeepCopy_admissionregistration_InitializerConfiguration is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_InitializerConfiguration(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*InitializerConfiguration) + out := out.(*InitializerConfiguration) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.Initializers != nil { + in, out := &in.Initializers, &out.Initializers + *out = make([]Initializer, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_Initializer(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_admissionregistration_InitializerConfigurationList is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_InitializerConfigurationList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*InitializerConfigurationList) + out := out.(*InitializerConfigurationList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]InitializerConfiguration, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_InitializerConfiguration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_admissionregistration_Rule is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_Rule(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Rule) + out := out.(*Rule) + *out = *in + if in.APIGroups != nil { + in, out := &in.APIGroups, &out.APIGroups + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.APIVersions != nil { + in, out := &in.APIVersions, &out.APIVersions + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Resources != nil { + in, out := &in.Resources, &out.Resources + *out = make([]string, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_admissionregistration_RuleWithOperations is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_RuleWithOperations(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RuleWithOperations) + out := out.(*RuleWithOperations) + *out = *in + if in.Operations != nil { + in, out := &in.Operations, &out.Operations + *out = make([]OperationType, len(*in)) + copy(*out, *in) + } + if err := DeepCopy_admissionregistration_Rule(&in.Rule, &out.Rule, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_admissionregistration_ServiceReference is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_ServiceReference(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ServiceReference) + out := out.(*ServiceReference) + *out = *in + return nil + } +} diff --git a/pkg/apis/apps/register.go b/pkg/apis/apps/register.go index dae876f37bfb8..f3b126fa43d3a 100644 --- a/pkg/apis/apps/register.go +++ b/pkg/apis/apps/register.go @@ -53,6 +53,8 @@ func addKnownTypes(scheme *runtime.Scheme) error { &extensions.Scale{}, &StatefulSet{}, &StatefulSetList{}, + &ControllerRevision{}, + &ControllerRevisionList{}, ) return nil } diff --git a/pkg/apis/apps/types.go b/pkg/apis/apps/types.go index 18f3d2f620461..b5233b3423527 100644 --- a/pkg/apis/apps/types.go +++ b/pkg/apis/apps/types.go @@ -18,6 +18,7 @@ package apps import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/kubernetes/pkg/api" ) @@ -127,3 +128,35 @@ type StatefulSetList struct { metav1.ListMeta Items []StatefulSet } + +// +genclient=true + +// ControllerRevision implements an immutable snapshot of state data. Clients +// are responsible for serializing and deserializing the objects that contain +// their internal state. +// Once a ControllerRevision has been successfully created, it can not be updated. +// The API Server will fail validation of all requests that attempt to mutate +// the Data field. ControllerRevisions may, however, be deleted. +type ControllerRevision struct { + metav1.TypeMeta + // Standard object's metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta + + // Data is the Object representing the state. + Data runtime.Object + + // Revision indicates the revision of the state represented by Data. + Revision int64 +} + +// ControllerRevisionList is a resource containing a list of ControllerRevision objects. +type ControllerRevisionList struct { + metav1.TypeMeta + // +optional + metav1.ListMeta + + // Items is the list of ControllerRevision objects. + Items []ControllerRevision +} diff --git a/pkg/apis/apps/v1beta1/generated.pb.go b/pkg/apis/apps/v1beta1/generated.pb.go index cc4cde6a858fe..690fa6522cd41 100644 --- a/pkg/apis/apps/v1beta1/generated.pb.go +++ b/pkg/apis/apps/v1beta1/generated.pb.go @@ -25,6 +25,8 @@ limitations under the License. k8s.io/kubernetes/pkg/apis/apps/v1beta1/generated.proto It has these top-level messages: + ControllerRevision + ControllerRevisionList Deployment DeploymentCondition DeploymentList @@ -51,7 +53,6 @@ import math "math" import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" import k8s_io_apimachinery_pkg_util_intstr "k8s.io/apimachinery/pkg/util/intstr" - import k8s_io_kubernetes_pkg_api_v1 "k8s.io/kubernetes/pkg/api/v1" import strings "strings" @@ -71,71 +72,83 @@ var _ = math.Inf // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package +func (m *ControllerRevision) Reset() { *m = ControllerRevision{} } +func (*ControllerRevision) ProtoMessage() {} +func (*ControllerRevision) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func (m *ControllerRevisionList) Reset() { *m = ControllerRevisionList{} } +func (*ControllerRevisionList) ProtoMessage() {} +func (*ControllerRevisionList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } + func (m *Deployment) Reset() { *m = Deployment{} } func (*Deployment) ProtoMessage() {} -func (*Deployment) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } +func (*Deployment) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } func (m *DeploymentCondition) Reset() { *m = DeploymentCondition{} } func (*DeploymentCondition) ProtoMessage() {} -func (*DeploymentCondition) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } +func (*DeploymentCondition) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } func (m *DeploymentList) Reset() { *m = DeploymentList{} } func (*DeploymentList) ProtoMessage() {} -func (*DeploymentList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } +func (*DeploymentList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } func (m *DeploymentRollback) Reset() { *m = DeploymentRollback{} } func (*DeploymentRollback) ProtoMessage() {} -func (*DeploymentRollback) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } +func (*DeploymentRollback) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } func (m *DeploymentSpec) Reset() { *m = DeploymentSpec{} } func (*DeploymentSpec) ProtoMessage() {} -func (*DeploymentSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } +func (*DeploymentSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } func (m *DeploymentStatus) Reset() { *m = DeploymentStatus{} } func (*DeploymentStatus) ProtoMessage() {} -func (*DeploymentStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } +func (*DeploymentStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } func (m *DeploymentStrategy) Reset() { *m = DeploymentStrategy{} } func (*DeploymentStrategy) ProtoMessage() {} -func (*DeploymentStrategy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } +func (*DeploymentStrategy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } func (m *RollbackConfig) Reset() { *m = RollbackConfig{} } func (*RollbackConfig) ProtoMessage() {} -func (*RollbackConfig) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } +func (*RollbackConfig) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } -func (m *RollingUpdateDeployment) Reset() { *m = RollingUpdateDeployment{} } -func (*RollingUpdateDeployment) ProtoMessage() {} -func (*RollingUpdateDeployment) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } +func (m *RollingUpdateDeployment) Reset() { *m = RollingUpdateDeployment{} } +func (*RollingUpdateDeployment) ProtoMessage() {} +func (*RollingUpdateDeployment) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{10} +} func (m *Scale) Reset() { *m = Scale{} } func (*Scale) ProtoMessage() {} -func (*Scale) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } +func (*Scale) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{11} } func (m *ScaleSpec) Reset() { *m = ScaleSpec{} } func (*ScaleSpec) ProtoMessage() {} -func (*ScaleSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{10} } +func (*ScaleSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{12} } func (m *ScaleStatus) Reset() { *m = ScaleStatus{} } func (*ScaleStatus) ProtoMessage() {} -func (*ScaleStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{11} } +func (*ScaleStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{13} } func (m *StatefulSet) Reset() { *m = StatefulSet{} } func (*StatefulSet) ProtoMessage() {} -func (*StatefulSet) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{12} } +func (*StatefulSet) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{14} } func (m *StatefulSetList) Reset() { *m = StatefulSetList{} } func (*StatefulSetList) ProtoMessage() {} -func (*StatefulSetList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{13} } +func (*StatefulSetList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{15} } func (m *StatefulSetSpec) Reset() { *m = StatefulSetSpec{} } func (*StatefulSetSpec) ProtoMessage() {} -func (*StatefulSetSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{14} } +func (*StatefulSetSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{16} } func (m *StatefulSetStatus) Reset() { *m = StatefulSetStatus{} } func (*StatefulSetStatus) ProtoMessage() {} -func (*StatefulSetStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{15} } +func (*StatefulSetStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{17} } func init() { + proto.RegisterType((*ControllerRevision)(nil), "k8s.io.kubernetes.pkg.apis.apps.v1beta1.ControllerRevision") + proto.RegisterType((*ControllerRevisionList)(nil), "k8s.io.kubernetes.pkg.apis.apps.v1beta1.ControllerRevisionList") proto.RegisterType((*Deployment)(nil), "k8s.io.kubernetes.pkg.apis.apps.v1beta1.Deployment") proto.RegisterType((*DeploymentCondition)(nil), "k8s.io.kubernetes.pkg.apis.apps.v1beta1.DeploymentCondition") proto.RegisterType((*DeploymentList)(nil), "k8s.io.kubernetes.pkg.apis.apps.v1beta1.DeploymentList") @@ -153,7 +166,7 @@ func init() { proto.RegisterType((*StatefulSetSpec)(nil), "k8s.io.kubernetes.pkg.apis.apps.v1beta1.StatefulSetSpec") proto.RegisterType((*StatefulSetStatus)(nil), "k8s.io.kubernetes.pkg.apis.apps.v1beta1.StatefulSetStatus") } -func (m *Deployment) Marshal() (dAtA []byte, err error) { +func (m *ControllerRevision) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalTo(dAtA) @@ -163,7 +176,7 @@ func (m *Deployment) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *Deployment) MarshalTo(dAtA []byte) (int, error) { +func (m *ControllerRevision) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int @@ -178,20 +191,95 @@ func (m *Deployment) MarshalTo(dAtA []byte) (int, error) { i += n1 dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n2, err := m.Spec.MarshalTo(dAtA[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Data.Size())) + n2, err := m.Data.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 + dAtA[i] = 0x18 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Revision)) + return i, nil +} + +func (m *ControllerRevisionList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ControllerRevisionList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n3, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *Deployment) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Deployment) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n4, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n5, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n3, err := m.Status.MarshalTo(dAtA[i:]) + n6, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n3 + i += n6 return i, nil } @@ -229,19 +317,19 @@ func (m *DeploymentCondition) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x32 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastUpdateTime.Size())) - n4, err := m.LastUpdateTime.MarshalTo(dAtA[i:]) + n7, err := m.LastUpdateTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n4 + i += n7 dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) - n5, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) + n8, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n5 + i += n8 return i, nil } @@ -263,11 +351,11 @@ func (m *DeploymentList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n6, err := m.ListMeta.MarshalTo(dAtA[i:]) + n9, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n6 + i += n9 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -322,11 +410,11 @@ func (m *DeploymentRollback) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.RollbackTo.Size())) - n7, err := m.RollbackTo.MarshalTo(dAtA[i:]) + n10, err := m.RollbackTo.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n7 + i += n10 return i, nil } @@ -354,28 +442,28 @@ func (m *DeploymentSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) - n8, err := m.Selector.MarshalTo(dAtA[i:]) + n11, err := m.Selector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n8 + i += n11 } dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) - n9, err := m.Template.MarshalTo(dAtA[i:]) + n12, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n9 + i += n12 dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Strategy.Size())) - n10, err := m.Strategy.MarshalTo(dAtA[i:]) + n13, err := m.Strategy.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n10 + i += n13 dAtA[i] = 0x28 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.MinReadySeconds)) @@ -396,11 +484,11 @@ func (m *DeploymentSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x42 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.RollbackTo.Size())) - n11, err := m.RollbackTo.MarshalTo(dAtA[i:]) + n14, err := m.RollbackTo.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n11 + i += n14 } if m.ProgressDeadlineSeconds != nil { dAtA[i] = 0x48 @@ -486,11 +574,11 @@ func (m *DeploymentStrategy) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.RollingUpdate.Size())) - n12, err := m.RollingUpdate.MarshalTo(dAtA[i:]) + n15, err := m.RollingUpdate.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n12 + i += n15 } return i, nil } @@ -535,21 +623,21 @@ func (m *RollingUpdateDeployment) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.MaxUnavailable.Size())) - n13, err := m.MaxUnavailable.MarshalTo(dAtA[i:]) + n16, err := m.MaxUnavailable.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n13 + i += n16 } if m.MaxSurge != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.MaxSurge.Size())) - n14, err := m.MaxSurge.MarshalTo(dAtA[i:]) + n17, err := m.MaxSurge.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n14 + i += n17 } return i, nil } @@ -572,27 +660,27 @@ func (m *Scale) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n15, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n18, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n15 + i += n18 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n16, err := m.Spec.MarshalTo(dAtA[i:]) + n19, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n16 + i += n19 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n17, err := m.Status.MarshalTo(dAtA[i:]) + n20, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n17 + i += n20 return i, nil } @@ -677,27 +765,27 @@ func (m *StatefulSet) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n18, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n21, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n18 + i += n21 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n19, err := m.Spec.MarshalTo(dAtA[i:]) + n22, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n19 + i += n22 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n20, err := m.Status.MarshalTo(dAtA[i:]) + n23, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n20 + i += n23 return i, nil } @@ -719,11 +807,11 @@ func (m *StatefulSetList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n21, err := m.ListMeta.MarshalTo(dAtA[i:]) + n24, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n21 + i += n24 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -763,20 +851,20 @@ func (m *StatefulSetSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) - n22, err := m.Selector.MarshalTo(dAtA[i:]) + n25, err := m.Selector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n22 + i += n25 } dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) - n23, err := m.Template.MarshalTo(dAtA[i:]) + n26, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n23 + i += n26 if len(m.VolumeClaimTemplates) > 0 { for _, msg := range m.VolumeClaimTemplates { dAtA[i] = 0x22 @@ -853,6 +941,31 @@ func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { dAtA[offset] = uint8(v) return offset + 1 } +func (m *ControllerRevision) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Data.Size() + n += 1 + l + sovGenerated(uint64(l)) + n += 1 + sovGenerated(uint64(m.Revision)) + return n +} + +func (m *ControllerRevisionList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + func (m *Deployment) Size() (n int) { var l int _ = l @@ -1108,6 +1221,29 @@ func sovGenerated(x uint64) (n int) { func sozGenerated(x uint64) (n int) { return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } +func (this *ControllerRevision) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ControllerRevision{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Data:` + strings.Replace(strings.Replace(this.Data.String(), "RawExtension", "k8s_io_apimachinery_pkg_runtime.RawExtension", 1), `&`, ``, 1) + `,`, + `Revision:` + fmt.Sprintf("%v", this.Revision) + `,`, + `}`, + }, "") + return s +} +func (this *ControllerRevisionList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ControllerRevisionList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ControllerRevision", "ControllerRevision", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} func (this *Deployment) String() string { if this == nil { return "nil" @@ -1336,6 +1472,246 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } +func (m *ControllerRevision) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ControllerRevision: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ControllerRevision: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Data.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Revision", wireType) + } + m.Revision = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Revision |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ControllerRevisionList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ControllerRevisionList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ControllerRevisionList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, ControllerRevision{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *Deployment) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 @@ -3920,105 +4296,108 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 1585 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x58, 0xcd, 0x6f, 0x1b, 0xb7, - 0x12, 0xf7, 0xda, 0x92, 0x2d, 0xd3, 0xb1, 0x1c, 0xd3, 0x7e, 0xb1, 0x9e, 0xf3, 0x20, 0x07, 0x3a, - 0xe4, 0xe3, 0x21, 0x59, 0xbd, 0x38, 0x79, 0xf9, 0xb0, 0x8b, 0xa0, 0x96, 0x93, 0xa6, 0x29, 0xec, - 0xc6, 0xa0, 0xec, 0xa0, 0x49, 0x53, 0xa0, 0xd4, 0x8a, 0x59, 0x33, 0xde, 0x2f, 0x2c, 0x29, 0x21, - 0xba, 0xf5, 0xd2, 0x43, 0x81, 0x1e, 0xfa, 0x0f, 0x14, 0xed, 0xb9, 0x28, 0xd0, 0x7f, 0xc3, 0x68, - 0x2f, 0x41, 0x4f, 0x45, 0x0f, 0x46, 0xed, 0xfc, 0x17, 0x39, 0x15, 0xe4, 0x72, 0xbf, 0xb4, 0x92, - 0x2d, 0xab, 0x68, 0x2e, 0xbd, 0x69, 0x39, 0xf3, 0xfb, 0xcd, 0x90, 0x9c, 0x19, 0xce, 0x08, 0xdc, - 0xde, 0xbb, 0xc3, 0x74, 0xea, 0x56, 0xf7, 0x5a, 0x0d, 0xe2, 0x3b, 0x84, 0x13, 0x56, 0xf5, 0xf6, - 0xcc, 0x2a, 0xf6, 0x28, 0xab, 0x62, 0xcf, 0x63, 0xd5, 0xf6, 0xf5, 0x06, 0xe1, 0xf8, 0x7a, 0xd5, - 0x24, 0x0e, 0xf1, 0x31, 0x27, 0x4d, 0xdd, 0xf3, 0x5d, 0xee, 0xc2, 0x4b, 0x01, 0x50, 0x8f, 0x81, - 0xba, 0xb7, 0x67, 0xea, 0x02, 0xa8, 0x0b, 0xa0, 0xae, 0x80, 0x8b, 0xd7, 0x4c, 0xca, 0x77, 0x5b,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, 0x18, 0x4a, 0x7a, 0xec, 0x64, 0xdd, 0x23, 0x46, 0xed, 0x8c, 0x32, - 0x92, 0x13, 0x5f, 0x48, 0x52, 0x42, 0x0c, 0xc6, 0x19, 0xc7, 0xbc, 0xc5, 0x4a, 0x63, 0x92, 0xfc, - 0xee, 0x30, 0xe4, 0x92, 0xa0, 0x56, 0x54, 0xf4, 0xe3, 0xc1, 0x37, 0x52, 0xc4, 0x95, 0xc3, 0x31, - 0x30, 0x17, 0x2b, 0xaf, 0xbb, 0x4e, 0x93, 0x72, 0xea, 0x3a, 0x70, 0x15, 0xe4, 0x78, 0xc7, 0x23, - 0xf2, 0xcc, 0x26, 0x6b, 0x97, 0x42, 0xe7, 0xb6, 0x3b, 0x1e, 0x79, 0x7b, 0xb0, 0xb4, 0xd0, 0x03, - 0x22, 0x44, 0x48, 0x82, 0xe0, 0x93, 0xc8, 0xef, 0x51, 0x09, 0xbf, 0x97, 0x36, 0xfe, 0xf6, 0x60, - 0xe9, 0xd8, 0x70, 0xd0, 0x23, 0xce, 0xb4, 0xb3, 0xf0, 0x22, 0x18, 0xf7, 0x09, 0x66, 0xae, 0x53, - 0xca, 0x49, 0xde, 0x68, 0x53, 0x48, 0xae, 0x22, 0x25, 0x85, 0x57, 0xc0, 0x84, 0x4d, 0x18, 0xc3, - 0x26, 0x29, 0xe5, 0xa5, 0xe2, 0x8c, 0x52, 0x9c, 0xd8, 0x0c, 0x96, 0x51, 0x28, 0x87, 0x2f, 0x41, - 0xd1, 0xc2, 0x8c, 0xef, 0x78, 0x4d, 0xcc, 0xc9, 0x36, 0xb5, 0x49, 0x69, 0x5c, 0x1e, 0xf5, 0x7f, - 0x07, 0x8b, 0x12, 0x81, 0xa8, 0x9d, 0x53, 0xec, 0xc5, 0x8d, 0x14, 0x13, 0xea, 0x62, 0x86, 0x6d, - 0x00, 0xc5, 0xca, 0xb6, 0x8f, 0x1d, 0x16, 0x1c, 0x99, 0xb0, 0x37, 0x71, 0x6a, 0x7b, 0x8b, 0xca, - 0x1e, 0xdc, 0xc8, 0xb0, 0xa1, 0x1e, 0x16, 0x2a, 0xfb, 0x1a, 0x28, 0xc6, 0x17, 0xb6, 0x41, 0x19, - 0x87, 0xcf, 0x33, 0x69, 0xa1, 0x0f, 0xe6, 0x80, 0x40, 0xcb, 0xa4, 0x38, 0xab, 0x9c, 0x28, 0x84, - 0x2b, 0x89, 0x94, 0xf8, 0x04, 0xe4, 0x29, 0x27, 0xb6, 0xb8, 0xfe, 0xb1, 0xcb, 0x53, 0xcb, 0x37, - 0x86, 0x08, 0xdb, 0xda, 0xb4, 0xe2, 0xcf, 0x3f, 0x12, 0x4c, 0x28, 0x20, 0xac, 0x7c, 0x3d, 0x06, - 0x60, 0xac, 0x84, 0x5c, 0xcb, 0x6a, 0x60, 0x63, 0x0f, 0x5e, 0x00, 0x39, 0x07, 0xdb, 0x61, 0xb4, - 0x46, 0xa9, 0xf4, 0x31, 0xb6, 0x09, 0x92, 0x12, 0xf8, 0x9d, 0x06, 0x60, 0x4b, 0x5e, 0x45, 0x73, - 0xcd, 0x71, 0x5c, 0x8e, 0xc5, 0xe9, 0x84, 0x0e, 0xd6, 0x87, 0x70, 0x30, 0xb4, 0xad, 0xef, 0x64, - 0x58, 0x1f, 0x38, 0xdc, 0xef, 0xc4, 0xb7, 0x94, 0x55, 0x40, 0x3d, 0x5c, 0x81, 0x7b, 0x00, 0xf8, - 0x8a, 0x73, 0xdb, 0x55, 0x09, 0x3f, 0x78, 0x35, 0x09, 0xdd, 0x59, 0x77, 0x9d, 0x17, 0xd4, 0x8c, - 0x4b, 0x16, 0x8a, 0x28, 0x51, 0x82, 0x7e, 0xf1, 0x01, 0x58, 0xe8, 0xe3, 0x37, 0x3c, 0x0b, 0xc6, - 0xf6, 0x48, 0x27, 0x38, 0x4a, 0x24, 0x7e, 0xc2, 0x79, 0x90, 0x6f, 0x63, 0xab, 0x45, 0x82, 0x6c, - 0x46, 0xc1, 0xc7, 0xca, 0xe8, 0x1d, 0xad, 0xf2, 0x7b, 0x3e, 0x19, 0x59, 0xa2, 0x72, 0xc1, 0xcb, - 0xa0, 0xe0, 0x13, 0xcf, 0xa2, 0x06, 0x66, 0x92, 0x23, 0x5f, 0x3b, 0x23, 0xa2, 0x04, 0xa9, 0x35, - 0x14, 0x49, 0xe1, 0x67, 0xa0, 0xc0, 0x88, 0x45, 0x0c, 0xee, 0xfa, 0xaa, 0x78, 0xde, 0x18, 0x30, - 0x06, 0x71, 0x83, 0x58, 0x75, 0x05, 0x0d, 0xe8, 0xc3, 0x2f, 0x14, 0x51, 0xc2, 0x4f, 0x41, 0x81, - 0x13, 0xdb, 0xb3, 0x30, 0x27, 0xea, 0x34, 0xaf, 0xf5, 0x3f, 0x4d, 0x41, 0xbb, 0xe5, 0x36, 0xb7, - 0x15, 0x40, 0x56, 0xe4, 0x28, 0xc2, 0xc3, 0x55, 0x14, 0x11, 0x42, 0x0a, 0x0a, 0x8c, 0x8b, 0x67, - 0xc7, 0xec, 0xc8, 0x5a, 0x34, 0xb5, 0xbc, 0x3a, 0x54, 0x6d, 0x0e, 0x28, 0x62, 0x53, 0xe1, 0x0a, - 0x8a, 0xe8, 0xe1, 0x1a, 0x98, 0xb1, 0xa9, 0x83, 0x08, 0x6e, 0x76, 0xea, 0xc4, 0x70, 0x9d, 0x26, - 0x93, 0x45, 0x2d, 0x5f, 0x5b, 0x50, 0xa0, 0x99, 0xcd, 0xb4, 0x18, 0x75, 0xeb, 0xc3, 0x0d, 0x30, - 0xef, 0x93, 0x36, 0x65, 0xd4, 0x75, 0x3e, 0xa4, 0x8c, 0xbb, 0x7e, 0x67, 0x83, 0xda, 0x94, 0xcb, - 0x52, 0x97, 0xaf, 0x95, 0x8e, 0x0e, 0x96, 0xe6, 0x51, 0x0f, 0x39, 0xea, 0x89, 0x12, 0x55, 0xd8, - 0xc3, 0x2d, 0x46, 0x9a, 0xb2, 0x74, 0x15, 0xe2, 0x2a, 0xbc, 0x25, 0x57, 0x91, 0x92, 0x42,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, 0xf8, 0x7f, 0x30, 0x25, 0x9a, 0x40, 0x6a, 0x10, 0x31, 0x99, 0xaa, 0xff, 0x26, 0xe6, - 0x14, 0xd1, 0x54, 0x3d, 0x16, 0xa1, 0xa4, 0x1e, 0xdc, 0x05, 0x73, 0x9e, 0xdb, 0xdc, 0xc4, 0x0e, - 0x36, 0x89, 0x78, 0x1a, 0xb7, 0xe4, 0x3f, 0x60, 0xb2, 0x7b, 0x9f, 0xac, 0xdd, 0x0a, 0xbb, 0xad, - 0xad, 0xac, 0xca, 0x5b, 0xd1, 0xf6, 0x66, 0x97, 0x65, 0xef, 0xd0, 0x8b, 0xb2, 0xf2, 0x95, 0x06, - 0x66, 0x33, 0xd9, 0x01, 0x3f, 0x38, 0xa6, 0xe7, 0x3d, 0xf7, 0x77, 0xf5, 0xbb, 0xb5, 0x2b, 0xfb, - 0x87, 0xe5, 0x91, 0xd7, 0x87, 0xe5, 0x91, 0xdf, 0x0e, 0xcb, 0x23, 0x5f, 0x1c, 0x95, 0xb5, 0xfd, - 0xa3, 0xb2, 0xf6, 0xfa, 0xa8, 0xac, 0xfd, 0x71, 0x54, 0xd6, 0xbe, 0x79, 0x53, 0x1e, 0x79, 0x36, - 0xa1, 0x62, 0xff, 0xcf, 0x00, 0x00, 0x00, 0xff, 0xff, 0xf2, 0xdb, 0x2f, 0x40, 0xf8, 0x15, 0x00, - 0x00, + // 1647 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x58, 0xcf, 0x4f, 0x1b, 0xc7, + 0x17, 0x67, 0x8d, 0x0d, 0x66, 0x08, 0x26, 0x0c, 0x7c, 0xc1, 0x5f, 0x52, 0x19, 0xe4, 0x43, 0x42, + 0xaa, 0x64, 0xdd, 0x90, 0x34, 0x3f, 0xa0, 0x8a, 0x8a, 0x49, 0x9a, 0xa6, 0x82, 0x82, 0xc6, 0x10, + 0x35, 0x69, 0x2a, 0x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 0x72, 0x06, + 0x23, 0x16, 0x2d, 0x66, 0xe6, 0x07, 0x17, 0x46, 0x17, 0x97, 0xd5, 0x3e, 0xab, 0x42, 0x4d, 0x5b, + 0x5b, 0x1d, 0x93, 0x7a, 0x72, 0x0f, 0x39, 0x22, 0xf2, 0x81, 0xcb, 0x3f, 0x67, 0x00, 0xb8, 0x47, + 0x5c, 0xd3, 0x69, 0x5b, 0xc4, 0x66, 0x67, 0x70, 0x95, 0x8f, 0x41, 0x96, 0xba, 0x44, 0x93, 0x57, + 0x79, 0xab, 0x6f, 0x8f, 0x22, 0x23, 0x6b, 0x2e, 0xd1, 0xa2, 0x4b, 0xe5, 0x5f, 0x48, 0x40, 0x42, + 0x0c, 0x86, 0x28, 0xc3, 0xac, 0x49, 0xc5, 0x95, 0x8e, 0x2e, 0xde, 0x39, 0x0d, 0xb8, 0x00, 0xa8, + 0x16, 0x24, 0xfc, 0x90, 0xff, 0x8d, 0x24, 0x70, 0xf9, 0x60, 0x10, 0x4c, 0x46, 0xcc, 0xab, 0x8e, + 0xdd, 0x30, 0x18, 0x2f, 0x81, 0x65, 0x90, 0x65, 0x6d, 0x97, 0x88, 0x98, 0x8d, 0x54, 0x2f, 0x05, + 0xc6, 0x6d, 0xb5, 0x5d, 0xf2, 0x76, 0x7f, 0x6e, 0xa6, 0x8b, 0x08, 0x27, 0x21, 0x21, 0x04, 0x1f, + 0x85, 0x76, 0x67, 0x84, 0xf8, 0xdd, 0xa4, 0xf2, 0xb7, 0xfb, 0x73, 0x47, 0x56, 0xb8, 0x1a, 0x62, + 0x26, 0x8d, 0x85, 0x17, 0xc1, 0x90, 0x47, 0x30, 0x75, 0xec, 0x62, 0x56, 0xe0, 0x86, 0x4e, 0x21, + 0x71, 0x8a, 0x24, 0x15, 0x5e, 0x06, 0xc3, 0x16, 0xa1, 0x14, 0xeb, 0xa4, 0x98, 0x13, 0x8c, 0xe3, + 0x92, 0x71, 0x78, 0xdd, 0x3f, 0x46, 0x01, 0x1d, 0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6, 0x03, 0x2e, 0x83, + 0x31, 0x8f, 0x57, 0x48, 0x68, 0xfa, 0xb0, 0x30, 0xfd, 0x7f, 0x52, 0x6c, 0x0c, 0xc5, 0x89, 0x28, + 0xc9, 0x0b, 0x97, 0x40, 0x41, 0x73, 0x4c, 0x53, 0x54, 0xc6, 0xaa, 0xd3, 0xb4, 0x99, 0x48, 0xee, + 0xc1, 0x2a, 0xe4, 0x33, 0xc0, 0x6a, 0x82, 0x82, 0x3a, 0x38, 0xcb, 0xbf, 0x29, 0xf1, 0x07, 0x2c, + 0x28, 0x77, 0xb8, 0x94, 0x18, 0xb7, 0x2e, 0x76, 0x8c, 0x5b, 0xd3, 0x69, 0x89, 0xd8, 0xb4, 0xd5, + 0x06, 0x63, 0xbc, 0x18, 0x0c, 0x5b, 0xf7, 0x13, 0x40, 0x36, 0xd3, 0x0f, 0x4f, 0x54, 0x6a, 0xa1, + 0x74, 0xec, 0x09, 0x9e, 0x10, 0x91, 0x88, 0x13, 0x51, 0x52, 0x53, 0xf9, 0x2e, 0x28, 0x24, 0xeb, + 0x34, 0xb1, 0x87, 0x28, 0xc7, 0xee, 0x21, 0x6f, 0x14, 0x30, 0xd3, 0x43, 0x3b, 0x34, 0x41, 0xc1, + 0xc2, 0x2f, 0x63, 0x39, 0x74, 0xec, 0xfc, 0xce, 0x57, 0x4a, 0xd5, 0x5f, 0x29, 0xd5, 0x87, 0x36, + 0xdb, 0xf0, 0x6a, 0xcc, 0x33, 0x6c, 0xdd, 0xbf, 0x97, 0xf5, 0x04, 0x16, 0xea, 0xc0, 0x86, 0x4f, + 0x40, 0xde, 0xc2, 0x2f, 0x6b, 0x4d, 0x4f, 0x0f, 0xe2, 0x77, 0x72, 0x3d, 0xe2, 0x25, 0x5a, 0x97, + 0x28, 0x28, 0xc4, 0x2b, 0x7f, 0x9f, 0x01, 0xb9, 0x9a, 0x86, 0x4d, 0x72, 0x06, 0xdb, 0xc8, 0x56, + 0x62, 0x1b, 0x59, 0xec, 0x3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47, 0x5d, 0x80, 0x51, 0x57, 0x75, + 0xf0, 0x7d, 0x30, 0xca, 0x87, 0x40, 0x43, 0x23, 0x7c, 0x33, 0x95, 0xff, 0x4d, 0x4c, 0x4a, 0xa0, + 0xd1, 0x5a, 0x44, 0x42, 0x71, 0x3e, 0xb8, 0x03, 0x26, 0x5d, 0xa7, 0xb1, 0x8e, 0x6d, 0xac, 0x13, + 0xfe, 0x34, 0x6e, 0x8a, 0x3f, 0x35, 0xc5, 0xf4, 0x3e, 0x52, 0xbd, 0x19, 0x4c, 0x5b, 0x9b, 0x69, + 0x96, 0xb7, 0x7c, 0xec, 0x4d, 0x1f, 0x8b, 0xd9, 0xa1, 0x1b, 0x64, 0xf9, 0x1b, 0x05, 0x4c, 0xa4, + 0xaa, 0x03, 0x7e, 0x74, 0xc4, 0xcc, 0x3b, 0xfd, 0x6f, 0xcd, 0xbb, 0xd5, 0xcb, 0x7b, 0x07, 0xa5, + 0x81, 0x57, 0x07, 0xa5, 0x81, 0xd7, 0x07, 0xa5, 0x81, 0xaf, 0x0e, 0x4b, 0xca, 0xde, 0x61, 0x49, + 0x79, 0x75, 0x58, 0x52, 0xfe, 0x3c, 0x2c, 0x29, 0xdf, 0xbd, 0x29, 0x0d, 0x3c, 0x19, 0x96, 0xb9, + 0xff, 0x77, 0x00, 0x00, 0x00, 0xff, 0xff, 0x5d, 0x5b, 0xd8, 0xe7, 0x95, 0x17, 0x00, 0x00, } diff --git a/pkg/apis/apps/v1beta1/generated.proto b/pkg/apis/apps/v1beta1/generated.proto index 5e3d4b99fe2de..367bc3eac5198 100644 --- a/pkg/apis/apps/v1beta1/generated.proto +++ b/pkg/apis/apps/v1beta1/generated.proto @@ -25,13 +25,44 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; import "k8s.io/kubernetes/pkg/apis/policy/v1beta1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; +// ControllerRevision implements an immutable snapshot of state data. Clients +// are responsible for serializing and deserializing the objects that contain +// their internal state. +// Once a ControllerRevision has been successfully created, it can not be updated. +// The API Server will fail validation of all requests that attempt to mutate +// the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both +// the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, +// it may be subject to name and representation changes in future releases, and clients should not +// depend on its stability. It is primarily for internal use by controllers. +message ControllerRevision { + // Standard object's metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Data is the serialized representation of the state. + optional k8s.io.apimachinery.pkg.runtime.RawExtension data = 2; + + // Revision indicates the revision of the state represented by Data. + optional int64 revision = 3; +} + +// ControllerRevisionList is a resource containing a list of ControllerRevision objects. +message ControllerRevisionList { + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // Items is the list of ControllerRevisions + repeated ControllerRevision items = 2; +} + // Deployment enables declarative updates for Pods and ReplicaSets. message Deployment { // Standard object metadata. @@ -194,7 +225,7 @@ message DeploymentStrategy { } message RollbackConfig { - // The revision to rollback to. If set to 0, rollbck to the last revision. + // The revision to rollback to. If set to 0, rollback to the last revision. // +optional optional int64 revision = 1; } diff --git a/pkg/apis/apps/v1beta1/register.go b/pkg/apis/apps/v1beta1/register.go index 077809652895b..5a4fd5bc3bb5f 100644 --- a/pkg/apis/apps/v1beta1/register.go +++ b/pkg/apis/apps/v1beta1/register.go @@ -57,6 +57,8 @@ func addKnownTypes(scheme *runtime.Scheme) error { &Scale{}, &StatefulSet{}, &StatefulSetList{}, + &ControllerRevision{}, + &ControllerRevisionList{}, ) metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil diff --git a/pkg/apis/apps/v1beta1/types.generated.go b/pkg/apis/apps/v1beta1/types.generated.go index 4ee127c438f94..c0c47f56fcf3d 100644 --- a/pkg/apis/apps/v1beta1/types.generated.go +++ b/pkg/apis/apps/v1beta1/types.generated.go @@ -27,6 +27,7 @@ import ( codec1978 "github.com/ugorji/go/codec" pkg4_resource "k8s.io/apimachinery/pkg/api/resource" pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg6_runtime "k8s.io/apimachinery/pkg/runtime" pkg2_types "k8s.io/apimachinery/pkg/types" pkg5_intstr "k8s.io/apimachinery/pkg/util/intstr" pkg3_v1 "k8s.io/kubernetes/pkg/api/v1" @@ -67,11 +68,12 @@ func init() { if false { // reference the types, but skip this branch at build/run time var v0 pkg4_resource.Quantity var v1 pkg1_v1.TypeMeta - var v2 pkg2_types.UID - var v3 pkg5_intstr.IntOrString - var v4 pkg3_v1.PodTemplateSpec - var v5 time.Time - _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5 + var v2 pkg6_runtime.RawExtension + var v3 pkg2_types.UID + var v4 pkg5_intstr.IntOrString + var v5 pkg3_v1.PodTemplateSpec + var v6 time.Time + _, _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5, v6 } } @@ -6152,6 +6154,808 @@ func (x *DeploymentList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } +func (x *ControllerRevision) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy15 := &x.Data + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(yy15) { + } else if !yym16 && z.IsJSONHandle() { + z.EncJSONMarshal(yy15) + } else { + z.EncFallback(yy15) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("data")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Data + yym18 := z.EncBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.EncExt(yy17) { + } else if !yym18 && z.IsJSONHandle() { + z.EncJSONMarshal(yy17) + } else { + z.EncFallback(yy17) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeInt(int64(x.Revision)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("revision")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym21 := z.EncBinary() + _ = yym21 + if false { + } else { + r.EncodeInt(int64(x.Revision)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ControllerRevision) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ControllerRevision) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "data": + if r.TryDecodeAsNil() { + x.Data = pkg6_runtime.RawExtension{} + } else { + yyv10 := &x.Data + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else if !yym11 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv10) + } else { + z.DecFallback(yyv10, false) + } + } + case "revision": + if r.TryDecodeAsNil() { + x.Revision = 0 + } else { + yyv12 := &x.Revision + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ControllerRevision) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv15 := &x.Kind + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv17 := &x.APIVersion + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv19 := &x.ObjectMeta + yym20 := z.DecBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else { + z.DecFallback(yyv19, false) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Data = pkg6_runtime.RawExtension{} + } else { + yyv21 := &x.Data + yym22 := z.DecBinary() + _ = yym22 + if false { + } else if z.HasExtensions() && z.DecExt(yyv21) { + } else if !yym22 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv21) + } else { + z.DecFallback(yyv21, false) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Revision = 0 + } else { + yyv23 := &x.Revision + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int64)(yyv23)) = int64(r.DecodeInt(64)) + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ControllerRevisionList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceControllerRevision(([]ControllerRevision)(x.Items), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceControllerRevision(([]ControllerRevision)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ControllerRevisionList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ControllerRevisionList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceControllerRevision((*[]ControllerRevision)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ControllerRevisionList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceControllerRevision((*[]ControllerRevision)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + func (x codecSelfer1234) encSlicev1_PersistentVolumeClaim(v []pkg3_v1.PersistentVolumeClaim, e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) @@ -6627,3 +7431,122 @@ func (x codecSelfer1234) decSliceDeployment(v *[]Deployment, d *codec1978.Decode *v = yyv1 } } + +func (x codecSelfer1234) encSliceControllerRevision(v []ControllerRevision, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceControllerRevision(v *[]ControllerRevision, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ControllerRevision{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 312) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]ControllerRevision, yyrl1) + } + } else { + yyv1 = make([]ControllerRevision, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ControllerRevision{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ControllerRevision{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ControllerRevision{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ControllerRevision{}) // var yyz1 ControllerRevision + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = ControllerRevision{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ControllerRevision{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} diff --git a/pkg/apis/apps/v1beta1/types.go b/pkg/apis/apps/v1beta1/types.go index c9843eed7dac9..5aa3d3a258130 100644 --- a/pkg/apis/apps/v1beta1/types.go +++ b/pkg/apis/apps/v1beta1/types.go @@ -18,6 +18,7 @@ package v1beta1 import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/util/intstr" "k8s.io/kubernetes/pkg/api/v1" ) @@ -259,7 +260,7 @@ type DeploymentRollback struct { } type RollbackConfig struct { - // The revision to rollback to. If set to 0, rollbck to the last revision. + // The revision to rollback to. If set to 0, rollback to the last revision. // +optional Revision int64 `json:"revision,omitempty" protobuf:"varint,1,opt,name=revision"` } @@ -407,3 +408,40 @@ type DeploymentList struct { // Items is the list of Deployments. Items []Deployment `json:"items" protobuf:"bytes,2,rep,name=items"` } + +// +genclient=true + +// ControllerRevision implements an immutable snapshot of state data. Clients +// are responsible for serializing and deserializing the objects that contain +// their internal state. +// Once a ControllerRevision has been successfully created, it can not be updated. +// The API Server will fail validation of all requests that attempt to mutate +// the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both +// the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, +// it may be subject to name and representation changes in future releases, and clients should not +// depend on its stability. It is primarily for internal use by controllers. +type ControllerRevision struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Data is the serialized representation of the state. + Data runtime.RawExtension `json:"data,omitempty" protobuf:"bytes,2,opt,name=data"` + + // Revision indicates the revision of the state represented by Data. + Revision int64 `json:"revision" protobuf:"varint,3,opt,name=revision"` +} + +// ControllerRevisionList is a resource containing a list of ControllerRevision objects. +type ControllerRevisionList struct { + metav1.TypeMeta `json:",inline"` + + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Items is the list of ControllerRevisions + Items []ControllerRevision `json:"items" protobuf:"bytes,2,rep,name=items"` +} diff --git a/pkg/apis/apps/v1beta1/types_swagger_doc_generated.go b/pkg/apis/apps/v1beta1/types_swagger_doc_generated.go index fffd81c31681e..b63d0d266dbbe 100644 --- a/pkg/apis/apps/v1beta1/types_swagger_doc_generated.go +++ b/pkg/apis/apps/v1beta1/types_swagger_doc_generated.go @@ -27,6 +27,27 @@ package v1beta1 // Those methods can be generated by using hack/update-generated-swagger-docs.sh // AUTO-GENERATED FUNCTIONS START HERE +var map_ControllerRevision = map[string]string{ + "": "ControllerRevision implements an immutable snapshot of state data. Clients are responsible for serializing and deserializing the objects that contain their internal state. Once a ControllerRevision has been successfully created, it can not be updated. The API Server will fail validation of all requests that attempt to mutate the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, it may be subject to name and representation changes in future releases, and clients should not depend on its stability. It is primarily for internal use by controllers.", + "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "data": "Data is the serialized representation of the state.", + "revision": "Revision indicates the revision of the state represented by Data.", +} + +func (ControllerRevision) SwaggerDoc() map[string]string { + return map_ControllerRevision +} + +var map_ControllerRevisionList = map[string]string{ + "": "ControllerRevisionList is a resource containing a list of ControllerRevision objects.", + "metadata": "More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "items": "Items is the list of ControllerRevisions", +} + +func (ControllerRevisionList) SwaggerDoc() map[string]string { + return map_ControllerRevisionList +} + var map_Deployment = map[string]string{ "": "Deployment enables declarative updates for Pods and ReplicaSets.", "metadata": "Standard object metadata.", @@ -117,7 +138,7 @@ func (DeploymentStrategy) SwaggerDoc() map[string]string { } var map_RollbackConfig = map[string]string{ - "revision": "The revision to rollback to. If set to 0, rollbck to the last revision.", + "revision": "The revision to rollback to. If set to 0, rollback to the last revision.", } func (RollbackConfig) SwaggerDoc() map[string]string { diff --git a/pkg/apis/apps/v1beta1/zz_generated.conversion.go b/pkg/apis/apps/v1beta1/zz_generated.conversion.go index 18994b66dd7f1..fe6da7594a1d0 100644 --- a/pkg/apis/apps/v1beta1/zz_generated.conversion.go +++ b/pkg/apis/apps/v1beta1/zz_generated.conversion.go @@ -38,6 +38,10 @@ func init() { // Public to allow building arbitrary schemes. func RegisterConversions(scheme *runtime.Scheme) error { return scheme.AddGeneratedConversionFuncs( + Convert_v1beta1_ControllerRevision_To_apps_ControllerRevision, + Convert_apps_ControllerRevision_To_v1beta1_ControllerRevision, + Convert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList, + Convert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList, Convert_v1beta1_StatefulSet_To_apps_StatefulSet, Convert_apps_StatefulSet_To_v1beta1_StatefulSet, Convert_v1beta1_StatefulSetList_To_apps_StatefulSetList, @@ -49,6 +53,76 @@ func RegisterConversions(scheme *runtime.Scheme) error { ) } +func autoConvert_v1beta1_ControllerRevision_To_apps_ControllerRevision(in *ControllerRevision, out *apps.ControllerRevision, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := runtime.Convert_runtime_RawExtension_To_runtime_Object(&in.Data, &out.Data, s); err != nil { + return err + } + out.Revision = in.Revision + return nil +} + +// Convert_v1beta1_ControllerRevision_To_apps_ControllerRevision is an autogenerated conversion function. +func Convert_v1beta1_ControllerRevision_To_apps_ControllerRevision(in *ControllerRevision, out *apps.ControllerRevision, s conversion.Scope) error { + return autoConvert_v1beta1_ControllerRevision_To_apps_ControllerRevision(in, out, s) +} + +func autoConvert_apps_ControllerRevision_To_v1beta1_ControllerRevision(in *apps.ControllerRevision, out *ControllerRevision, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := runtime.Convert_runtime_Object_To_runtime_RawExtension(&in.Data, &out.Data, s); err != nil { + return err + } + out.Revision = in.Revision + return nil +} + +// Convert_apps_ControllerRevision_To_v1beta1_ControllerRevision is an autogenerated conversion function. +func Convert_apps_ControllerRevision_To_v1beta1_ControllerRevision(in *apps.ControllerRevision, out *ControllerRevision, s conversion.Scope) error { + return autoConvert_apps_ControllerRevision_To_v1beta1_ControllerRevision(in, out, s) +} + +func autoConvert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList(in *ControllerRevisionList, out *apps.ControllerRevisionList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]apps.ControllerRevision, len(*in)) + for i := range *in { + if err := Convert_v1beta1_ControllerRevision_To_apps_ControllerRevision(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = nil + } + return nil +} + +// Convert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList is an autogenerated conversion function. +func Convert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList(in *ControllerRevisionList, out *apps.ControllerRevisionList, s conversion.Scope) error { + return autoConvert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList(in, out, s) +} + +func autoConvert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList(in *apps.ControllerRevisionList, out *ControllerRevisionList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ControllerRevision, len(*in)) + for i := range *in { + if err := Convert_apps_ControllerRevision_To_v1beta1_ControllerRevision(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = make([]ControllerRevision, 0) + } + return nil +} + +// Convert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList is an autogenerated conversion function. +func Convert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList(in *apps.ControllerRevisionList, out *ControllerRevisionList, s conversion.Scope) error { + return autoConvert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList(in, out, s) +} + func autoConvert_v1beta1_StatefulSet_To_apps_StatefulSet(in *StatefulSet, out *apps.StatefulSet, s conversion.Scope) error { out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_StatefulSetSpec_To_apps_StatefulSetSpec(&in.Spec, &out.Spec, s); err != nil { diff --git a/pkg/apis/apps/v1beta1/zz_generated.deepcopy.go b/pkg/apis/apps/v1beta1/zz_generated.deepcopy.go index cc348e2aa77ab..efd5a79aca1aa 100644 --- a/pkg/apis/apps/v1beta1/zz_generated.deepcopy.go +++ b/pkg/apis/apps/v1beta1/zz_generated.deepcopy.go @@ -37,6 +37,8 @@ func init() { // to allow building arbitrary schemes. func RegisterDeepCopies(scheme *runtime.Scheme) error { return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ControllerRevision, InType: reflect.TypeOf(&ControllerRevision{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ControllerRevisionList, InType: reflect.TypeOf(&ControllerRevisionList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_Deployment, InType: reflect.TypeOf(&Deployment{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentCondition, InType: reflect.TypeOf(&DeploymentCondition{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentList, InType: reflect.TypeOf(&DeploymentList{})}, @@ -56,6 +58,45 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_v1beta1_ControllerRevision is an autogenerated deepcopy function. +func DeepCopy_v1beta1_ControllerRevision(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ControllerRevision) + out := out.(*ControllerRevision) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if newVal, err := c.DeepCopy(&in.Data); err != nil { + return err + } else { + out.Data = *newVal.(*runtime.RawExtension) + } + return nil + } +} + +// DeepCopy_v1beta1_ControllerRevisionList is an autogenerated deepcopy function. +func DeepCopy_v1beta1_ControllerRevisionList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ControllerRevisionList) + out := out.(*ControllerRevisionList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ControllerRevision, len(*in)) + for i := range *in { + if err := DeepCopy_v1beta1_ControllerRevision(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + // DeepCopy_v1beta1_Deployment is an autogenerated deepcopy function. func DeepCopy_v1beta1_Deployment(in interface{}, out interface{}, c *conversion.Cloner) error { { diff --git a/pkg/apis/apps/validation/BUILD b/pkg/apis/apps/validation/BUILD index d399f5443db0d..2cd9d971bc627 100644 --- a/pkg/apis/apps/validation/BUILD +++ b/pkg/apis/apps/validation/BUILD @@ -32,6 +32,7 @@ go_test( "//pkg/api:go_default_library", "//pkg/apis/apps:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", ], ) diff --git a/pkg/apis/apps/validation/validation.go b/pkg/apis/apps/validation/validation.go index 413f4baa4cd20..7c37d6841c778 100644 --- a/pkg/apis/apps/validation/validation.go +++ b/pkg/apis/apps/validation/validation.go @@ -141,3 +141,34 @@ func ValidateStatefulSetStatusUpdate(statefulSet, oldStatefulSet *apps.StatefulS // TODO: Validate status. return allErrs } + +// ValidateControllerRevisionName can be used to check whether the given ControllerRevision name is valid. +// Prefix indicates this name will be used as part of generation, in which case +// trailing dashes are allowed. +var ValidateControllerRevisionName = apivalidation.NameIsDNSSubdomain + +// ValidateControllerRevision collects errors for the fields of state and returns those errors as an ErrorList. If the +// returned list is empty, state is valid. Validation is performed to ensure that state is a valid ObjectMeta, its name +// is valid, and that it doesn't exceed the MaxControllerRevisionSize. +func ValidateControllerRevision(revision *apps.ControllerRevision) field.ErrorList { + errs := field.ErrorList{} + + errs = append(errs, apivalidation.ValidateObjectMeta(&revision.ObjectMeta, true, ValidateControllerRevisionName, field.NewPath("metadata"))...) + if revision.Data == nil { + errs = append(errs, field.Required(field.NewPath("data"), "data is mandatory")) + } + errs = append(errs, apivalidation.ValidateNonnegativeField(revision.Revision, field.NewPath("revision"))...) + return errs +} + +// ValidateControllerRevisionUpdate collects errors pertaining to the mutation of an ControllerRevision Object. If the +// returned ErrorList is empty the update operation is valid. Any mutation to the ControllerRevision's Data or Revision +// is considered to be invalid. +func ValidateControllerRevisionUpdate(newHistory, oldHistory *apps.ControllerRevision) field.ErrorList { + errs := field.ErrorList{} + + errs = append(errs, apivalidation.ValidateObjectMetaUpdate(&newHistory.ObjectMeta, &oldHistory.ObjectMeta, field.NewPath("metadata"))...) + errs = append(errs, ValidateControllerRevision(newHistory)...) + errs = append(errs, apivalidation.ValidateImmutableField(newHistory.Data, oldHistory.Data, field.NewPath("data"))...) + return errs +} diff --git a/pkg/apis/apps/validation/validation_test.go b/pkg/apis/apps/validation/validation_test.go index 2aa31cd72f75a..6e56de16f7e26 100644 --- a/pkg/apis/apps/validation/validation_test.go +++ b/pkg/apis/apps/validation/validation_test.go @@ -21,6 +21,7 @@ import ( "testing" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/kubernetes/pkg/api" "k8s.io/kubernetes/pkg/apis/apps" ) @@ -432,3 +433,159 @@ func TestValidateStatefulSetUpdate(t *testing.T) { } } } + +func TestValidateControllerRevision(t *testing.T) { + newControllerRevision := func(name, namespace string, data runtime.Object, revision int64) apps.ControllerRevision { + return apps.ControllerRevision{ + ObjectMeta: metav1.ObjectMeta{ + Name: name, + Namespace: namespace, + }, + Data: data, + Revision: revision, + } + } + + ss := apps.StatefulSet{ + ObjectMeta: metav1.ObjectMeta{Name: "abc", Namespace: metav1.NamespaceDefault}, + Spec: apps.StatefulSetSpec{ + Selector: &metav1.LabelSelector{MatchLabels: map[string]string{"foo": "bar"}}, + Template: api.PodTemplateSpec{ + Spec: api.PodSpec{ + RestartPolicy: api.RestartPolicyAlways, + DNSPolicy: api.DNSClusterFirst, + }, + ObjectMeta: metav1.ObjectMeta{ + Labels: map[string]string{"foo": "bar"}, + }, + }, + }, + } + + var ( + valid = newControllerRevision("validname", "validns", &ss, 0) + badRevision = newControllerRevision("validname", "validns", &ss, -1) + emptyName = newControllerRevision("", "validns", &ss, 0) + invalidName = newControllerRevision("NoUppercaseOrSpecialCharsLike=Equals", "validns", &ss, 0) + emptyNs = newControllerRevision("validname", "", &ss, 100) + invalidNs = newControllerRevision("validname", "NoUppercaseOrSpecialCharsLike=Equals", &ss, 100) + nilData = newControllerRevision("validname", "NoUppercaseOrSpecialCharsLike=Equals", nil, 100) + ) + + tests := map[string]struct { + history apps.ControllerRevision + isValid bool + }{ + "valid": {valid, true}, + "negative revision": {badRevision, false}, + "empty name": {emptyName, false}, + "invalid name": {invalidName, false}, + "empty namespace": {emptyNs, false}, + "invalid namespace": {invalidNs, false}, + "nil data": {nilData, false}, + } + + for name, tc := range tests { + errs := ValidateControllerRevision(&tc.history) + if tc.isValid && len(errs) > 0 { + t.Errorf("%v: unexpected error: %v", name, errs) + } + if !tc.isValid && len(errs) == 0 { + t.Errorf("%v: unexpected non-error", name) + } + } +} + +func TestValidateControllerRevisionUpdate(t *testing.T) { + newControllerRevision := func(version, name, namespace string, data runtime.Object, revision int64) apps.ControllerRevision { + return apps.ControllerRevision{ + ObjectMeta: metav1.ObjectMeta{ + Name: name, + Namespace: namespace, + ResourceVersion: version, + }, + Data: data, + Revision: revision, + } + } + + ss := apps.StatefulSet{ + ObjectMeta: metav1.ObjectMeta{Name: "abc", Namespace: metav1.NamespaceDefault}, + Spec: apps.StatefulSetSpec{ + Selector: &metav1.LabelSelector{MatchLabels: map[string]string{"foo": "bar"}}, + Template: api.PodTemplateSpec{ + Spec: api.PodSpec{ + RestartPolicy: api.RestartPolicyAlways, + DNSPolicy: api.DNSClusterFirst, + }, + ObjectMeta: metav1.ObjectMeta{ + Labels: map[string]string{"foo": "bar"}, + }, + }, + }, + } + modifiedss := apps.StatefulSet{ + ObjectMeta: metav1.ObjectMeta{Name: "cdf", Namespace: metav1.NamespaceDefault}, + Spec: apps.StatefulSetSpec{ + Selector: &metav1.LabelSelector{MatchLabels: map[string]string{"foo": "bar"}}, + Template: api.PodTemplateSpec{ + Spec: api.PodSpec{ + RestartPolicy: api.RestartPolicyAlways, + DNSPolicy: api.DNSClusterFirst, + }, + ObjectMeta: metav1.ObjectMeta{ + Labels: map[string]string{"foo": "bar"}, + }, + }, + }, + } + + var ( + valid = newControllerRevision("1", "validname", "validns", &ss, 0) + noVersion = newControllerRevision("", "validname", "validns", &ss, 0) + changedData = newControllerRevision("1", "validname", "validns", &modifiedss, 0) + changedRevision = newControllerRevision("1", "validname", "validns", &ss, 1) + ) + + cases := []struct { + name string + newHistory apps.ControllerRevision + oldHistory apps.ControllerRevision + isValid bool + }{ + { + name: "valid", + newHistory: valid, + oldHistory: valid, + isValid: true, + }, + { + name: "invalid", + newHistory: noVersion, + oldHistory: valid, + isValid: false, + }, + { + name: "changed data", + newHistory: changedData, + oldHistory: valid, + isValid: false, + }, + { + name: "changed revision", + newHistory: changedRevision, + oldHistory: valid, + isValid: true, + }, + } + + for _, tc := range cases { + errs := ValidateControllerRevisionUpdate(&tc.newHistory, &tc.oldHistory) + if tc.isValid && len(errs) > 0 { + t.Errorf("%v: unexpected error: %v", tc.name, errs) + } + if !tc.isValid && len(errs) == 0 { + t.Errorf("%v: unexpected non-error", tc.name) + } + } +} diff --git a/pkg/apis/apps/zz_generated.deepcopy.go b/pkg/apis/apps/zz_generated.deepcopy.go index 6019cfa8a19ec..84e48618d0021 100644 --- a/pkg/apis/apps/zz_generated.deepcopy.go +++ b/pkg/apis/apps/zz_generated.deepcopy.go @@ -36,6 +36,8 @@ func init() { // to allow building arbitrary schemes. func RegisterDeepCopies(scheme *runtime.Scheme) error { return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_ControllerRevision, InType: reflect.TypeOf(&ControllerRevision{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_ControllerRevisionList, InType: reflect.TypeOf(&ControllerRevisionList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_StatefulSet, InType: reflect.TypeOf(&StatefulSet{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_StatefulSetList, InType: reflect.TypeOf(&StatefulSetList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_StatefulSetSpec, InType: reflect.TypeOf(&StatefulSetSpec{})}, @@ -43,6 +45,48 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_apps_ControllerRevision is an autogenerated deepcopy function. +func DeepCopy_apps_ControllerRevision(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ControllerRevision) + out := out.(*ControllerRevision) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + // in.Data is kind 'Interface' + if in.Data != nil { + if newVal, err := c.DeepCopy(&in.Data); err != nil { + return err + } else { + out.Data = *newVal.(*runtime.Object) + } + } + return nil + } +} + +// DeepCopy_apps_ControllerRevisionList is an autogenerated deepcopy function. +func DeepCopy_apps_ControllerRevisionList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ControllerRevisionList) + out := out.(*ControllerRevisionList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ControllerRevision, len(*in)) + for i := range *in { + if err := DeepCopy_apps_ControllerRevision(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + // DeepCopy_apps_StatefulSet is an autogenerated deepcopy function. func DeepCopy_apps_StatefulSet(in interface{}, out interface{}, c *conversion.Cloner) error { { diff --git a/pkg/apis/authentication/v1/generated.pb.go b/pkg/apis/authentication/v1/generated.pb.go index a484283fe7f88..94c117b959e58 100644 --- a/pkg/apis/authentication/v1/generated.pb.go +++ b/pkg/apis/authentication/v1/generated.pb.go @@ -1251,46 +1251,45 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 655 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x53, 0xcd, 0x6e, 0xd3, 0x4c, - 0x14, 0xb5, 0xf3, 0x53, 0x25, 0x93, 0xaf, 0x1f, 0x65, 0x24, 0xa4, 0x28, 0x12, 0x4e, 0x14, 0x58, - 0x74, 0x51, 0xc6, 0xa4, 0xa0, 0x52, 0x15, 0x10, 0xaa, 0x45, 0x85, 0xba, 0x00, 0xa4, 0x81, 0x22, - 0xc4, 0x06, 0x26, 0xce, 0xad, 0x63, 0x52, 0xff, 0x68, 0x3c, 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2, 0x6a, 0x3a, - 0x37, 0x0f, 0x8e, 0x2d, 0xe3, 0xf0, 0xd8, 0x32, 0xbe, 0x1f, 0x5b, 0xc6, 0xfe, 0xd4, 0x32, 0x0f, - 0xa6, 0x96, 0x79, 0x38, 0xb5, 0xcc, 0x9f, 0x53, 0xcb, 0xfc, 0xf8, 0xcb, 0x32, 0xde, 0x54, 0xb2, - 0xc1, 0xef, 0x00, 0x00, 0x00, 0xff, 0xff, 0xbb, 0x6b, 0x11, 0x20, 0xa4, 0x05, 0x00, 0x00, + // 637 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x53, 0xcd, 0x6e, 0xd3, 0x40, + 0x10, 0xb6, 0xf3, 0x53, 0x25, 0x1b, 0x0a, 0x65, 0x25, 0xa4, 0x28, 0x12, 0x4e, 0x14, 0x38, 0xf4, + 0x50, 0xd6, 0xa4, 0xa0, 0x52, 0x15, 0x10, 0xaa, 0x45, 0x85, 0x7a, 0x00, 0xa4, 0x85, 0x22, 0xc4, + 0x05, 0x36, 0xce, 0xd4, 0x59, 0x52, 0xff, 0x68, 0xbd, 0x0e, 0xf4, 0xd6, 0x47, 0xe0, 0xc8, 0x91, + 0xd7, 0xe0, 0x0d, 0x7a, 0xa3, 0x37, 0x38, 0xa0, 0x8a, 0x86, 0x17, 0x41, 0xbb, 0x5e, 0x1a, 0xb7, + 0xa5, 0x42, 0xe9, 0xcd, 0xfb, 0xcd, 0x7c, 0xdf, 0x7c, 0x33, 0xe3, 0x41, 0x0f, 0x46, 0xab, 0x29, + 0xe1, 0xb1, 0x3b, 0xca, 0xfa, 0x20, 0x22, 0x90, 0x90, 0xba, 0xc9, 0x28, 0x70, 0x59, 0xc2, 0x53, + 0x97, 0x65, 0x72, 0x08, 0x91, 0xe4, 0x3e, 0x93, 0x3c, 0x8e, 0xdc, 0x71, 0xcf, 0x0d, 0x20, 0x02, + 0xc1, 0x24, 0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x03, + 0x6d, 0xbc, 0xee, 0x35, 0x4c, 0x62, 0x79, 0x6b, 0xf3, 0x31, 0x55, 0x38, 0xee, 0xa2, 0xb9, 0x40, + 0xc4, 0x59, 0xa2, 0x96, 0xa9, 0xfe, 0x65, 0xa4, 0xf6, 0xf0, 0x44, 0x23, 0xd4, 0x44, 0xf0, 0x36, + 0xaa, 0x82, 0xfa, 0xf9, 0x9b, 0x95, 0x4e, 0x79, 0xb1, 0xb1, 0xbc, 0x7e, 0xb1, 0xee, 0x89, 0x3e, + 0xa0, 0x8d, 0x48, 0x8a, 0xdd, 0x42, 0x97, 0x0a, 0xa3, 0xb9, 0x7c, 0x4b, 0x98, 0x23, 0xd3, 0x39, + 0x78, 0x01, 0x95, 0x47, 0xb0, 0x9b, 0x77, 0x48, 0xd5, 0x27, 0x7e, 0x86, 0xaa, 0x63, 0x75, 0x7f, + 0x66, 0x0b, 0xab, 0xb3, 0xf9, 0x98, 0xde, 0x2f, 0xcd, 0x65, 0xd6, 0x4a, 0xab, 0xb6, 0x77, 0x73, + 0xff, 0xc8, 0xb1, 0x0e, 0x8e, 0x1c, 0xeb, 0xc7, 0x91, 0x63, 0xed, 0x4d, 0x1c, 0x7b, 0x7f, 0xe2, + 0xd8, 0x07, 0x13, 0xc7, 0xfe, 0x35, 0x71, 0xec, 0x4f, 0xbf, 0x1d, 0xeb, 0x4d, 0x69, 0xdc, 0xfb, + 0x13, 0x00, 0x00, 0xff, 0xff, 0x80, 0xcb, 0xcb, 0x29, 0x6e, 0x05, 0x00, 0x00, } diff --git a/pkg/apis/authentication/v1/generated.proto b/pkg/apis/authentication/v1/generated.proto index ea5203d37be16..6507b8764785e 100644 --- a/pkg/apis/authentication/v1/generated.proto +++ b/pkg/apis/authentication/v1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1"; diff --git a/pkg/apis/authentication/v1beta1/generated.pb.go b/pkg/apis/authentication/v1beta1/generated.pb.go index 61d03f1ff1c9d..5917c73de3c7c 100644 --- a/pkg/apis/authentication/v1beta1/generated.pb.go +++ b/pkg/apis/authentication/v1beta1/generated.pb.go @@ -1251,47 +1251,46 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 660 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x53, 0x4f, 0x6f, 0xd3, 0x4e, - 0x10, 0x8d, 0xf3, 0xa7, 0xbf, 0x64, 0xf3, 0x2b, 0x94, 0x95, 0x90, 0xa2, 0x48, 0x38, 0x51, 0xb8, - 0x14, 0x09, 0xd6, 0xa4, 0xa0, 0x52, 0xb5, 0xe2, 0x50, 0xab, 0x05, 0xf5, 0x80, 0x90, 0xb6, 0x94, - 0x03, 0x12, 0x12, 0x1b, 0x67, 0xea, 0x18, 0xc7, 0x7f, 0xb4, 0x5e, 0xa7, 0xed, 0xad, 0x1f, 0x81, - 0x23, 0x47, 0xbe, 0x0b, 0x97, 0x1e, 0x7b, 0xe0, 0xc0, 0x01, 0x55, 0x24, 0x7c, 0x11, 0xb4, 0xeb, - 0xa5, 0x76, 0x09, 0x15, 0xa2, 0xbd, 0x79, 0xdf, 0xcc, 0x7b, 0x33, 0x6f, 0xc6, 0x83, 0x36, 0xfd, - 0xb5, 0x84, 0x78, 0x91, 0xe5, 0xa7, 0x03, 0xe0, 0x21, 0x08, 0x48, 0xac, 0xd8, 0x77, 0x2d, 0x16, - 0x7b, 0x89, 0xc5, 0x52, 0x31, 0x82, 0x50, 0x78, 0x0e, 0x13, 0x5e, 0x14, 0x5a, 0x93, 0xfe, 0x00, - 0x04, 0xeb, 0x5b, 0x2e, 0x84,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0x32, 0x43, 0x16, 0x80, 0x9e, 0xc5, 0x92, 0x26, 0xa9, 0x1c, 0x89, 0xd3, 0xf3, - 0x0c, 0x7c, 0x07, 0x55, 0x52, 0x6f, 0xa8, 0xba, 0x6f, 0xd8, 0x4d, 0x9d, 0x58, 0xd9, 0xdb, 0xd9, - 0xa2, 0x12, 0xc7, 0x3d, 0xb4, 0xe0, 0xf2, 0x28, 0x8d, 0xe5, 0x5a, 0xe5, 0xaf, 0x8d, 0xe4, 0x32, - 0x9e, 0x2b, 0x84, 0xea, 0x08, 0xf6, 0x51, 0x0d, 0xe4, 0x2d, 0xb4, 0xaa, 0xdd, 0xca, 0x72, 0x73, - 0xe5, 0xd9, 0x35, 0x46, 0x40, 0xd4, 0x51, 0x6d, 0x87, 0x82, 0x1f, 0x15, 0xac, 0x4a, 0x8c, 0x66, - 0x35, 0xda, 0x07, 0xfa, 0xf0, 0x54, 0x0e, 0x5e, 0x42, 0x15, 0x1f, 0x8e, 0x32, 0x9b, 0x54, 0x7e, - 0xe2, 0x5d, 0x54, 0x9b, 0xc8, 0x9b, 0xd4, 0xfb, 0x78, 0x7a, 0x85, 0x66, 0xf2, 0xc3, 0xa6, 0x99, - 0xd6, 0x7a, 0x79, 0xcd, 0xb0, 0xef, 0x9d, 0x4c, 0xcd, 0xd2, 0xe9, 0xd4, 0x2c, 0x7d, 0x9d, 0x9a, - 0xa5, 0xe3, 0x99, 0x69, 0x9c, 0xcc, 0x4c, 0xe3, 0x74, 0x66, 0x1a, 0xdf, 0x67, 0xa6, 0xf1, 0xe1, - 0x87, 0x59, 0x7a, 0xf3, 0x9f, 0x16, 0xf8, 0x19, 0x00, 0x00, 0xff, 0xff, 0xc6, 0x0a, 0xc4, 0x2e, - 0xcc, 0x05, 0x00, 0x00, + // 645 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x53, 0x4d, 0x6f, 0xd3, 0x4c, + 0x10, 0xb6, 0xf3, 0xd1, 0x37, 0xd9, 0xbc, 0x7d, 0xdf, 0xb2, 0x12, 0x52, 0x14, 0x09, 0x27, 0x0a, + 0x97, 0x22, 0xc1, 0x9a, 0x14, 0x54, 0xaa, 0x56, 0x1c, 0x6a, 0xb5, 0xa0, 0x1e, 0x10, 0xd2, 0x96, + 0x72, 0x40, 0x42, 0x62, 0xe3, 0x4c, 0x9d, 0xc5, 0xf5, 0x87, 0xd6, 0xeb, 0x94, 0xde, 0xfa, 0x13, + 0x38, 0x72, 0xe4, 0xbf, 0x70, 0xe9, 0xb1, 0x07, 0x0e, 0x1c, 0x50, 0x45, 0xc2, 0x1f, 0x41, 0xbb, + 0x5e, 0x9a, 0xb4, 0x51, 0x85, 0x68, 0x6f, 0xde, 0x67, 0xe6, 0x79, 0xe6, 0x99, 0x19, 0x0f, 0xda, + 0x0c, 0xd7, 0x32, 0xc2, 0x13, 0x37, 0xcc, 0xfb, 0x20, 0x62, 0x90, 0x90, 0xb9, 0x69, 0x18, 0xb8, + 0x2c, 0xe5, 0x99, 0xcb, 0x72, 0x39, 0x84, 0x58, 0x72, 0x9f, 0x49, 0x9e, 0xc4, 0xee, 0xa8, 0xd7, + 0x07, 0xc9, 0x7a, 0x6e, 0x00, 0x31, 0x08, 0x26, 0x61, 0x40, 0x52, 0x91, 0xc8, 0x04, 0xf7, 0x0a, + 0x09, 0x32, 0x95, 0x20, 0x69, 0x18, 0x10, 0x25, 0x41, 0x2e, 0x4a, 0x10, 0x23, 0xd1, 0x7a, 0x10, + 0x70, 0x39, 0xcc, 0xfb, 0xc4, 0x4f, 0x22, 0x37, 0x48, 0x82, 0xc4, 0xd5, 0x4a, 0xfd, 0x7c, 0x5f, + 0xbf, 0xf4, 0x43, 0x7f, 0x15, 0x15, 0x5a, 0x8f, 0x8d, 0x49, 0x96, 0xf2, 0x88, 0xf9, 0x43, 0x1e, + 0x83, 0x38, 0x9a, 0xda, 0x8c, 0x40, 0x32, 0x77, 0x34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87, 0xa7, 0x73, 0xf0, 0x12, 0x2a, 0x87, 0x70, 0x54, 0xb4, 0x49, + 0xd5, 0x27, 0xde, 0x45, 0xd5, 0x91, 0xba, 0x49, 0xb3, 0x8f, 0xa7, 0xd7, 0x30, 0x33, 0x3d, 0x6c, + 0x5a, 0x68, 0xad, 0x97, 0xd6, 0x6c, 0xef, 0xde, 0xc9, 0xd8, 0xb1, 0x4e, 0xc7, 0x8e, 0xf5, 0x6d, + 0xec, 0x58, 0xc7, 0x13, 0xc7, 0x3e, 0x99, 0x38, 0xf6, 0xe9, 0xc4, 0xb1, 0x7f, 0x4c, 0x1c, 0xfb, + 0xe3, 0x4f, 0xc7, 0x7a, 0xf3, 0x8f, 0x11, 0xf8, 0x15, 0x00, 0x00, 0xff, 0xff, 0x45, 0x22, 0xbd, + 0x60, 0x96, 0x05, 0x00, 0x00, } diff --git a/pkg/apis/authentication/v1beta1/generated.proto b/pkg/apis/authentication/v1beta1/generated.proto index e0d3f0ddffeb4..6ae022f7d00bc 100644 --- a/pkg/apis/authentication/v1beta1/generated.proto +++ b/pkg/apis/authentication/v1beta1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; diff --git a/pkg/apis/authorization/v1/generated.pb.go b/pkg/apis/authorization/v1/generated.pb.go index 22d655ac9213d..1d2cafdc0c755 100644 --- a/pkg/apis/authorization/v1/generated.pb.go +++ b/pkg/apis/authorization/v1/generated.pb.go @@ -2298,62 +2298,61 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 898 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x56, 0x4f, 0x6f, 0x1b, 0x45, - 0x14, 0xf7, 0xfa, 0x5f, 0xec, 0x09, 0x90, 0x32, 0x55, 0xc9, 0x36, 0x48, 0xb6, 0x65, 0x10, 0x0a, - 0x02, 0x76, 0x49, 0xf9, 0xd3, 0xaa, 0x1c, 0x50, 0x56, 0x84, 0x3f, 0x12, 0x6d, 0xd1, 0x44, 0xe4, - 0x00, 0x17, 0xc6, 0x9b, 0x17, 0x7b, 0x6b, 0xef, 0xce, 0x32, 0x33, 0xbb, 0x6d, 0x38, 0xf5, 0xc6, - 0x15, 0x89, 0x0b, 0x47, 0xbe, 0x02, 0x1f, 0x00, 0xce, 0xb9, 0xd1, 0x03, 0x12, 0x1c, 0x90, 0x45, - 0x96, 0x0b, 0x1f, 0x03, 0xcd, 0xec, 0xc4, 0x6b, 0xe3, 0x0d, 0x95, 0xa1, 0x12, 0x1c, 0x72, 0xdb, - 0x79, 0xef, 0xf7, 0x7b, 0xef, 0xf7, 0x66, 0xde, 0xec, 0x1b, 0xf4, 0xd6, 0xf8, 0x86, 0x70, 0x02, - 0xe6, 0x8e, 0x93, 0x01, 0xf0, 0x08, 0x24, 0x08, 0x37, 0x1e, 0x0f, 0x5d, 0x1a, 0x07, 0xc2, 0xa5, - 0x89, 0x1c, 0x31, 0x1e, 0x7c, 0x41, 0x65, 0xc0, 0x22, 0x37, 0xdd, 0x71, 0x87, 0x10, 0x01, 0xa7, - 0x12, 0x0e, 0x9d, 0x98, 0x33, 0xc9, 0xf0, 0x4b, 0x39, 0xd9, 0x29, 0xc8, 0x4e, 0x3c, 0x1e, 0x3a, - 0x8a, 0xec, 0x2c, 0x90, 0x9d, 0x74, 0x67, 0xeb, 0x95, 0x61, 0x20, 0x47, 0xc9, 0xc0, 0xf1, 0x59, - 0xe8, 0x0e, 0xd9, 0x90, 0xb9, 0x3a, 0xc6, 0x20, 0x39, 0xd2, 0x2b, 0xbd, 0xd0, 0x5f, 0x79, 0xec, - 0xad, 0xd7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 0x4c, 0x25, 0x6d, 0x23, 0x79, 0xb2, 0xad, 0xcf, 0xcd, 0x8b, 0x48, - 0x63, 0xf0, 0x25, 0x54, 0x1b, 0xc3, 0x71, 0x3e, 0x15, 0x89, 0xfa, 0xc4, 0xb7, 0x50, 0x23, 0x55, - 0x8f, 0x25, 0xb3, 0xc1, 0xd7, 0x57, 0x52, 0x55, 0xbc, 0xb5, 0x48, 0x1e, 0xe5, 0x66, 0xf5, 0x86, - 0xd5, 0xff, 0xce, 0x42, 0x57, 0xcf, 0x6d, 0x50, 0x35, 0x26, 0xe9, 0x64, 0xc2, 0xee, 0xc1, 0xa1, - 0x96, 0xd1, 0x2a, 0xc6, 0xe4, 0x6e, 0x6e, 0x26, 0x67, 0x7e, 0xfc, 0x02, 0x6a, 0x72, 0xa0, 0x82, - 0x45, 0x66, 0x34, 0xcf, 0x7a, 0x9b, 0x68, 0x2b, 0x31, 0x5e, 0xbc, 0x8b, 0x36, 0x40, 0xa5, 0xd7, - 0xba, 0xf6, 0x38, 0x67, 0xdc, 0x1c, 0xd5, 0xa6, 0x21, 0x6c, 0xec, 0x2d, 0xba, 0xc9, 0x5f, 0xf1, - 0xde, 0xf3, 0x27, 0xa7, 0x9d, 0xca, 0xc3, 0xd3, 0x4e, 0xe5, 0x97, 0xd3, 0x4e, 0xe5, 0x41, 0xd6, - 0xb1, 0x4e, 0xb2, 0x8e, 0xf5, 0x30, 0xeb, 0x58, 0xbf, 0x65, 0x1d, 0xeb, 0xab, 0xdf, 0x3b, 0x95, - 0x4f, 0xaa, 0xe9, 0xce, 0x9f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x43, 0x53, 0x67, 0x22, 0x02, 0x0c, + // 882 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x56, 0x4f, 0x6f, 0xdc, 0x44, + 0x14, 0x5f, 0xef, 0xbf, 0xec, 0x4e, 0x80, 0x94, 0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99, 0x02, 0x5f, 0x5f, 0x4a, 0x55, 0xf9, 0xd6, 0x22, 0x45, 0x94, 0x9b, 0xf5, 0x1b, + 0x96, 0xf3, 0xbd, 0x85, 0xae, 0x9e, 0xdb, 0xa0, 0x6a, 0x4c, 0xd2, 0xc9, 0x84, 0xdd, 0x83, 0x7d, + 0x2d, 0xa3, 0x53, 0x8e, 0xc9, 0xed, 0xc2, 0x4c, 0x4e, 0xfc, 0xf8, 0x05, 0xd4, 0xe6, 0x40, 0x05, + 0x8b, 0xcd, 0x68, 0x9e, 0xf7, 0x36, 0xd1, 0x56, 0x62, 0xbc, 0x78, 0x1b, 0xad, 0x81, 0x4a, 0xaf, + 0x75, 0xed, 0x70, 0xce, 0xb8, 0x39, 0xaa, 0x75, 0x43, 0x58, 0xdb, 0x59, 0x74, 0x93, 0x87, 0xf1, + 0xfe, 0xf3, 0x47, 0xc7, 0xbd, 0xda, 0x83, 0xe3, 0x5e, 0xed, 0xd7, 0xe3, 0x5e, 0xed, 0x7e, 0xde, + 0xb3, 0x8e, 0xf2, 0x9e, 0xf5, 0x20, 0xef, 0x59, 0xbf, 0xe7, 0x3d, 0xeb, 0xeb, 0x3f, 0x7a, 0xb5, + 0x4f, 0xea, 0xd9, 0xd6, 0x5f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x75, 0x52, 0x96, 0xf3, 0xcc, 0x0b, 0x00, 0x00, } diff --git a/pkg/apis/authorization/v1/generated.proto b/pkg/apis/authorization/v1/generated.proto index 334e6a375161c..7a8fdb6ad8404 100644 --- a/pkg/apis/authorization/v1/generated.proto +++ b/pkg/apis/authorization/v1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1"; diff --git a/pkg/apis/authorization/v1beta1/generated.pb.go b/pkg/apis/authorization/v1beta1/generated.pb.go index 48908e69e1a39..26f8b5b4b2194 100644 --- a/pkg/apis/authorization/v1beta1/generated.pb.go +++ b/pkg/apis/authorization/v1beta1/generated.pb.go @@ -2298,62 +2298,61 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 898 bytes of a gzipped FileDescriptorProto + // 882 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x56, 0x4f, 0x6f, 0xdc, 0x44, - 0x14, 0x5f, 0xef, 0x9f, 0x64, 0x77, 0x02, 0xa4, 0x4c, 0x55, 0xe2, 0x06, 0x69, 0x77, 0xb5, 0x48, - 0x28, 0x95, 0xc0, 0x6e, 0xca, 0xbf, 0xaa, 0xe2, 0x40, 0x2c, 0xa2, 0xaa, 0x82, 0x16, 0x34, 0x81, - 0x1c, 0xe0, 0xc2, 0xd8, 0x79, 0xdd, 0x35, 0xbb, 0xf6, 0x58, 0x33, 0x63, 0xb7, 0xe1, 0xd4, 0x0f, - 0xc0, 0x81, 0x63, 0x8f, 0x7c, 0x05, 0xbe, 0x00, 0x57, 0x72, 0xec, 0x11, 0x24, 0xb4, 0x22, 0xe6, - 0x5b, 0x70, 0x42, 0x33, 0x9e, 0x5d, 0x67, 0x59, 0x87, 0x6a, 0xa1, 0x88, 0x1e, 0x72, 0xb3, 0xdf, - 0xfb, 0xbd, 0xdf, 0xfb, 0xbd, 0x99, 0x37, 0xf3, 0x06, 0x7d, 0x30, 0xbe, 0x29, 0x9c, 0x90, 0xb9, - 0xe3, 0xd4, 0x07, 0x1e, 0x83, 0x04, 0xe1, 0x26, 0xe3, 0xa1, 0x4b, 0x93, 0x50, 0xb8, 0x34, 0x95, - 0x23, 0xc6, 0xc3, 0x6f, 0xa8, 0x0c, 0x59, 0xec, 0x66, 0xbb, 0x3e, 0x48, 0xba, 0xeb, 0x0e, 0x21, - 0x06, 0x4e, 0x25, 0x1c, 0x39, 0x09, 0x67, 0x92, 0xe1, 0xeb, 0x05, 0x83, 0x53, 0x32, 0x38, 0xc9, - 0x78, 0xe8, 0x28, 0x06, 0x67, 0x81, 0xc1, 0x31, 0x0c, 0xdb, 0x6f, 0x0e, 0x43, 0x39, 0x4a, 0x7d, - 0x27, 0x60, 0x91, 0x3b, 0x64, 0x43, 0xe6, 0x6a, 0x22, 0x3f, 0xbd, 0xaf, 0xff, 0xf4, 0x8f, 0xfe, - 0x2a, 0x12, 0x6c, 0xbf, 0x6d, 0x24, 0xd2, 0x24, 0x8c, 0x68, 0x30, 0x0a, 0x63, 0xe0, 0xc7, 0xa5, - 0xc8, 0x08, 0x24, 0x75, 0xb3, 0x25, 0x59, 0xdb, 0xee, 0x79, 0x51, 0x3c, 0x8d, 0x65, 0x18, 0xc1, - 0x52, 0xc0, 0xbb, 0x4f, 0x0b, 0x10, 0xc1, 0x08, 0x22, 0xba, 0x14, 0xf7, 0xd6, 0x79, 0x71, 0xa9, - 0x0c, 0x27, 0x6e, 0x18, 0x4b, 0x21, 0xf9, 0x52, 0xd0, 0x99, 0x9a, 0x04, 0xf0, 0x0c, 0x78, 0x59, - 0x10, 0x3c, 0xa4, 0x51, 0x32, 0x81, 0x8a, 0x9a, 0x06, 0xef, 0x21, 0xb4, 0xff, 0x50, 0x72, 0x7a, - 0x48, 0x27, 0x29, 0xe0, 0x1e, 0x6a, 0x85, 0x12, 0x22, 0x61, 0x5b, 0xfd, 0xc6, 0x4e, 0xc7, 0xeb, - 0xe4, 0xd3, 0x5e, 0xeb, 0x8e, 0x32, 0x90, 0xc2, 0x7e, 0xab, 0xfd, 0xf8, 0xfb, 0x5e, 0xed, 0xd1, - 0xaf, 0xfd, 0xda, 0x60, 0x5a, 0x47, 0xf6, 0xc7, 0x2c, 0xa0, 0x93, 0x83, 0xd4, 0xff, 0x1a, 0x02, - 0xb9, 0x17, 0x04, 0x20, 0x04, 0x81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0xdf, 0xf2, 0xae, 0xf5, 0xdd, 0xef, 0xdd, 0xda, - 0x17, 0xeb, 0xa6, 0xe8, 0x3f, 0x03, 0x00, 0x00, 0xff, 0xff, 0x2a, 0x8e, 0xe3, 0x5a, 0x4b, 0x0c, + 0x14, 0x5f, 0xef, 0x9f, 0x64, 0x77, 0x02, 0xa4, 0x4c, 0x55, 0xe2, 0x06, 0xc9, 0xbb, 0x5a, 0x24, + 0x94, 0x4a, 0x60, 0x37, 0xe5, 0x5f, 0x55, 0x71, 0x20, 0x16, 0x51, 0x55, 0x41, 0x0b, 0x9a, 0x40, + 0x0e, 0x70, 0x61, 0xec, 0xbc, 0xee, 0x9a, 0xdd, 0xf5, 0x58, 0x33, 0x63, 0x97, 0x70, 0xea, 0x07, + 0xe0, 0xc0, 0xb1, 0x47, 0xbe, 0x02, 0x5f, 0x80, 0x2b, 0x39, 0xf6, 0x08, 0x12, 0x5a, 0x11, 0xf3, + 0x2d, 0x38, 0xa1, 0x19, 0xcf, 0xae, 0xb3, 0x5d, 0x87, 0x6a, 0xa1, 0x88, 0x1e, 0x72, 0xb3, 0xdf, + 0xfb, 0xbd, 0xdf, 0xfb, 0xcd, 0x9b, 0x37, 0xf3, 0x06, 0x7d, 0x30, 0xba, 0x29, 0xdc, 0x88, 0x79, + 0xa3, 0x34, 0x00, 0x1e, 0x83, 0x04, 0xe1, 0x25, 0xa3, 0x81, 0x47, 0x93, 0x48, 0x78, 0x34, 0x95, + 0x43, 0xc6, 0xa3, 0x6f, 0xa9, 0x8c, 0x58, 0xec, 0x65, 0xbb, 0x01, 0x48, 0xba, 0xeb, 0x0d, 0x20, + 0x06, 0x4e, 0x25, 0x1c, 0xb9, 0x09, 0x67, 0x92, 0xe1, 0xeb, 0x05, 0x83, 0x5b, 0x32, 0xb8, 0xc9, + 0x68, 0xe0, 0x2a, 0x06, 0x77, 0x81, 0xc1, 0x35, 0x0c, 0xdb, 0x6f, 0x0e, 0x22, 0x39, 0x4c, 0x03, + 0x37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 0xa4, 0xfd, 0x58, 0xf2, 0xe3, 0x72, 0x80, 0x69, 0x1b, 0x29, 0x32, 0x6e, 0x67, 0xe6, + 0x19, 0xa5, 0x31, 0xf8, 0x12, 0x6a, 0x8c, 0xe0, 0xb8, 0x18, 0xa0, 0x44, 0x7d, 0x62, 0x82, 0x5a, + 0x99, 0x7a, 0x61, 0x99, 0x42, 0xbf, 0xbf, 0xba, 0xb4, 0xf2, 0x95, 0x46, 0x0a, 0xaa, 0x5b, 0xf5, + 0x9b, 0x56, 0xff, 0x47, 0x0b, 0x5d, 0x3d, 0xb7, 0x65, 0xd5, 0x58, 0xa5, 0xe3, 0x31, 0x7b, 0x00, + 0x47, 0x5a, 0x4b, 0xbb, 0x1c, 0xab, 0x7b, 0x85, 0x99, 0xcc, 0xfc, 0xf8, 0x75, 0xb4, 0xc6, 0x81, + 0x0a, 0x16, 0x9b, 0x51, 0x3e, 0xef, 0x76, 0xa2, 0xad, 0xc4, 0x78, 0xf1, 0x1e, 0xda, 0x04, 0x95, + 0x5e, 0x8b, 0xdb, 0xe7, 0x9c, 0x71, 0xb3, 0x65, 0x5b, 0x26, 0x60, 0x73, 0x7f, 0xd1, 0x4d, 0x9e, + 0xc4, 0xfb, 0xd7, 0x4e, 0x4e, 0x9d, 0xda, 0xe3, 0x53, 0xa7, 0xf6, 0xcb, 0xa9, 0x53, 0x7b, 0x98, + 0x3b, 0xd6, 0x49, 0xee, 0x58, 0x8f, 0x73, 0xc7, 0xfa, 0x3d, 0x77, 0xac, 0xef, 0xff, 0x70, 0x6a, + 0x5f, 0xac, 0x9b, 0x45, 0xff, 0x15, 0x00, 0x00, 0xff, 0xff, 0x6e, 0x0d, 0x81, 0xe2, 0x15, 0x0c, 0x00, 0x00, } diff --git a/pkg/apis/authorization/v1beta1/generated.proto b/pkg/apis/authorization/v1beta1/generated.proto index 9258e4e06bbae..5653c29aa19b7 100644 --- a/pkg/apis/authorization/v1beta1/generated.proto +++ b/pkg/apis/authorization/v1beta1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; diff --git a/pkg/apis/autoscaling/v1/generated.pb.go b/pkg/apis/autoscaling/v1/generated.pb.go index e209f6c488134..164f517e6b72a 100644 --- a/pkg/apis/autoscaling/v1/generated.pb.go +++ b/pkg/apis/autoscaling/v1/generated.pb.go @@ -3420,85 +3420,85 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 1279 bytes of a gzipped FileDescriptorProto + // 1266 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x57, 0xcd, 0x6f, 0x1b, 0x45, - 0x14, 0xcf, 0xda, 0x4e, 0x94, 0xce, 0xa6, 0x1f, 0x4c, 0xaa, 0xd4, 0x4d, 0xa8, 0x37, 0x5a, 0x38, - 0xb4, 0xa8, 0xec, 0x12, 0x13, 0x2a, 0x22, 0x84, 0x50, 0x6c, 0x54, 0x5a, 0x51, 0xb7, 0x61, 0xe2, - 0x46, 0x7c, 0x09, 0x31, 0x59, 0x4f, 0x9d, 0x69, 0xbc, 0x1f, 0x9a, 0x1d, 0x5b, 0x4d, 0x24, 0x24, - 0x4e, 0x9c, 0xb9, 0x70, 0x46, 0xf0, 0x4f, 0x70, 0x2e, 0x12, 0x52, 0x8e, 0xbd, 0xc1, 0xc9, 0x22, - 0x0b, 0x37, 0xc4, 0x3f, 0x50, 0x71, 0x40, 0x3b, 0x3b, 0x5e, 0xef, 0xda, 0x5e, 0x27, 0x4e, 0xd3, - 0x22, 0x6e, 0xbb, 0x33, 0xef, 0xfd, 0x7e, 0xef, 0xfd, 0xe6, 0xcd,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, 0x40, 0x77, - 0x5b, 0xf4, 0xb5, 0xc6, 0x07, 0x51, 0x53, 0x0a, 0xbb, 0x43, 0xb8, 0x06, 0xf9, 0xca, 0x42, 0xd0, - 0xd5, 0xe0, 0xbd, 0xa1, 0x59, 0x34, 0xc2, 0x03, 0x5a, 0xe0, 0x6c, 0x0b, 0xfb, 0x3c, 0x52, 0x99, - 0xca, 0x46, 0xa4, 0x96, 0x5f, 0x3b, 0x5e, 0xd1, 0x86, 0x1e, 0x95, 0x97, 0x82, 0xae, 0x76, 0xf6, - 0x4e, 0x12, 0x04, 0xa5, 0x31, 0xe1, 0x3a, 0x38, 0x6f, 0xb5, 0x19, 0x23, 0x0e, 0x1f, 0x50, 0xfd, - 0x92, 0x54, 0xfd, 0x7c, 0x35, 0x3d, 0x8d, 0x06, 0xed, 0x43, 0x88, 0x06, 0xf1, 0x29, 0x23, 0x8d, - 0x18, 0xa2, 0x90, 0x86, 0x78, 0x3f, 0x3d, 0x8d, 0x06, 0xed, 0xa1, 0x0d, 0x34, 0x89, 0x9a, 0xb9, - 0x82, 0xd3, 0x02, 0xf2, 0x95, 0xa0, 0xab, 0x69, 0xd5, 0xf1, 0xa6, 0xe8, 0x28, 0x2c, 0xfd, 0xaf, - 0x1c, 0x00, 0x35, 0xc2, 0x19, 0xb5, 0xc4, 0x8e, 0x59, 0x05, 0x05, 0xbe, 0xe7, 0x11, 0x79, 0x14, - 0x2c, 0xf7, 0x9a, 0x59, 0x7d, 0xcf, 0x23, 0x4f, 0xbb, 0xda, 0x05, 0x69, 0x29, 0x8e, 0xe7, 0x70, - 0x0c, 0x09, 0x6b, 0x88, 0xc1, 0x8c, 0x2b, 0x76, 0x86, 0x5c, 0x97, 0x77, 0x27, 0xd8, 0x5e, 0x71, - 0x6f, 0x8e, 0x81, 0x2b, 0x20, 0xec, 0x68, 0x72, 0xab, 0x49, 0x60, 0xf8, 0x09, 0x28, 0x78, 0x6e, - 0xa3, 0xd7, 0x41, 0xdf, 0x99, 0x80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82, 0x63, 0x0b, 0x9d, 0x02, 0x35, 0xc1, 0x30, 0x99, 0x73, 0x68, 0xed, 0x93, 0x16, - 0xb1, 0xb8, 0xcb, 0xe4, 0x11, 0x12, 0x5b, 0x6f, 0xca, 0x71, 0x14, 0x5b, 0x54, 0x5e, 0x3d, 0x38, - 0x2c, 0x4d, 0x3d, 0x39, 0x2c, 0x4d, 0xfd, 0x76, 0x58, 0x9a, 0xfa, 0x3a, 0x28, 0x29, 0x07, 0x41, - 0x49, 0x79, 0x12, 0x94, 0x94, 0xdf, 0x83, 0x92, 0xf2, 0xed, 0x1f, 0xa5, 0xa9, 0x4f, 0x73, 0x9d, - 0x95, 0x7f, 0x03, 0x00, 0x00, 0xff, 0xff, 0x61, 0xfc, 0xd4, 0x31, 0x3f, 0x13, 0x00, 0x00, + 0x14, 0xcf, 0xda, 0x4e, 0x94, 0xce, 0xe6, 0x8b, 0x49, 0x95, 0xba, 0x09, 0xf5, 0x46, 0x0b, 0x87, + 0x16, 0x95, 0x5d, 0x62, 0x42, 0x45, 0x84, 0x10, 0x8a, 0x8d, 0x4a, 0x2b, 0xea, 0x36, 0x4c, 0xdc, + 0x88, 0x2f, 0x21, 0x26, 0xeb, 0xa9, 0x33, 0x8d, 0xf7, 0x43, 0xbb, 0x63, 0x8b, 0x44, 0x42, 0xe2, + 0xc4, 0x99, 0x0b, 0x67, 0x04, 0xff, 0x04, 0xe7, 0x22, 0x21, 0xe5, 0xd8, 0x1b, 0x9c, 0x56, 0x64, + 0xe1, 0x86, 0xf8, 0x07, 0x2a, 0x0e, 0x68, 0x67, 0xc7, 0xeb, 0x5d, 0xdb, 0xeb, 0xc4, 0x69, 0x5a, + 0xd4, 0xdb, 0xee, 0xcc, 0x7b, 0xbf, 0xdf, 0x7b, 0xbf, 0x79, 0xf3, 0x66, 0x06, 0x6c, 0xec, 0xbf, + 0xed, 0x69, 0xd4, 0xd6, 0xf7, 0xdb, 0xbb, 0xc4, 0xb5, 0x08, 0x23, 0x9e, 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 0xb2, 0x4d, 0x30, 0x49, 0x19, 0x31, 0xbd, 0x62, + 0x6e, 0x35, 0x7f, 0x55, 0x2e, 0x57, 0x9e, 0x3e, 0xdd, 0xca, 0xac, 0xa0, 0x9b, 0xbc, 0x1d, 0x02, + 0xa3, 0x08, 0x5f, 0xfd, 0x37, 0x97, 0x99, 0x66, 0x28, 0x3f, 0xfc, 0x56, 0x02, 0x73, 0xfc, 0xb7, + 0x8e, 0xdd, 0x26, 0x09, 0x2b, 0x5e, 0x64, 0x3b, 0xce, 0x6a, 0x8f, 0xd8, 0x39, 0x95, 0x25, 0x11, + 0xd6, 0xdc, 0x76, 0x8a, 0x05, 0xf5, 0xb1, 0xc2, 0x35, 0x20, 0x9b, 0xd4, 0x42, 0xc4, 0x69, 0x51, + 0x03, 0x7b, 0xbc, 0xe4, 0x26, 0x2b, 0xf3, 0x81, 0xaf, 0xc8, 0xb5, 0xde, 0x30, 0x4a, 0xda, 0xc0, + 0xb7, 0x80, 0x6c, 0xe2, 0xaf, 0x62, 0x97, 0x3c, 0x77, 0x59, 0x14, 0x7c, 0x72, 0xad, 0x37, 0x85, + 0x92, 0x76, 0xf0, 0x21, 0x28, 0x31, 0x4e, 0x5b, 0xdd, 0xba, 0x7f, 0x9f, 0xd1, 0x16, 0x3d, 0xc4, + 0x8c, 0xda, 0xd6, 0x16, 0x71, 0x0d, 0x62, 0x31, 0xdc, 0x24, 0xc5, 0x02, 0x47, 0x52, 0x03, 0x5f, + 0x29, 0xd5, 0x47, 0x5a, 0xa2, 0x13, 0x90, 0xd4, 0x47, 0x79, 0x70, 0x65, 0x64, 0x7d, 0xc2, 0x9b, + 0x00, 0xda, 0xbb, 0x1e, 0x71, 0x3b, 0xa4, 0xf1, 0x41, 0xd4, 0x94, 0xc2, 0xee, 0x10, 0xae, 0x41, + 0xbe, 0xb2, 0x14, 0xf8, 0x0a, 0xbc, 0x37, 0x30, 0x8b, 0x86, 0x78, 0x40, 0x03, 0xcc, 0xb6, 0xb0, + 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x33, 0x61, 0x67, 0xec, 0xce, 0xa0, 0x18, 0x5e, 0xfd, + 0x27, 0x07, 0x66, 0x84, 0x61, 0xb4, 0x41, 0xfe, 0x67, 0xbd, 0xa3, 0x53, 0xe4, 0x99, 0xe9, 0x1d, + 0xc1, 0x3f, 0x53, 0xbd, 0x23, 0x8a, 0x2c, 0xbd, 0x7f, 0xc8, 0x01, 0x38, 0x58, 0x60, 0xd0, 0x02, + 0x53, 0x51, 0x6b, 0x3b, 0xe7, 0xe3, 0x20, 0x3e, 0x8e, 0x45, 0xe7, 0x17, 0x2c, 0xe1, 0xe5, 0xc8, + 0xe4, 0xfc, 0x77, 0x7b, 0x97, 0xa8, 0xf8, 0x72, 0x52, 0x8b, 0x67, 0x50, 0xc2, 0x0a, 0x12, 0x20, + 0x47, 0xde, 0x3b, 0xb8, 0xd5, 0x26, 0x62, 0x1d, 0x46, 0x9e, 0xd2, 0x5a, 0x37, 0x6d, 0xed, 0xa3, + 0x36, 0xb6, 0x18, 0x65, 0x07, 0xbd, 0xf3, 0xa2, 0xde, 0x83, 0x42, 0x49, 0x5c, 0xf5, 0xa7, 0x7e, + 0x85, 0xa2, 0xba, 0x7c, 0x11, 0x14, 0xda, 0x03, 0x33, 0xa2, 0xbb, 0x3d, 0x8d, 0x44, 0x17, 0x05, + 0xcb, 0x4c, 0x35, 0x81, 0x85, 0x52, 0xc8, 0xea, 0x2f, 0x12, 0x58, 0xe8, 0x6f, 0x23, 0x7d, 0x21, + 0x4b, 0xa7, 0x0a, 0xf9, 0x10, 0xc0, 0x28, 0xe1, 0xcd, 0x0e, 0x71, 0x71, 0x93, 0x44, 0x81, 0xe7, + 0xce, 0x14, 0xf8, 0xb2, 0xe0, 0x82, 0xf5, 0x01, 0x44, 0x34, 0x84, 0x45, 0xfd, 0x35, 0x9d, 0x44, + 0xb4, 0xce, 0x67, 0x49, 0xe2, 0x6b, 0xb0, 0x28, 0xd4, 0x39, 0x87, 0x2c, 0x56, 0x04, 0xd9, 0x62,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 0x8f, 0x8f, 0x4b, 0x13, 0xbf, 0x1f, 0x97, 0x26, 0xbe, 0x09, 0x4a, + 0xd2, 0x51, 0x50, 0x92, 0x1e, 0x07, 0x25, 0xe9, 0x8f, 0xa0, 0x24, 0x7d, 0xf7, 0x67, 0x69, 0xe2, + 0xd3, 0x5c, 0x67, 0xed, 0xbf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x83, 0xac, 0x71, 0x0f, 0x09, 0x13, + 0x00, 0x00, } diff --git a/pkg/apis/autoscaling/v1/generated.proto b/pkg/apis/autoscaling/v1/generated.proto index 4953624af6879..d2c227f560307 100644 --- a/pkg/apis/autoscaling/v1/generated.proto +++ b/pkg/apis/autoscaling/v1/generated.proto @@ -26,7 +26,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; // Package-wide variables from generator "generated". diff --git a/pkg/apis/autoscaling/v2alpha1/generated.pb.go b/pkg/apis/autoscaling/v2alpha1/generated.pb.go index 7ad1f7a22b999..70f701490d985 100644 --- a/pkg/apis/autoscaling/v2alpha1/generated.pb.go +++ b/pkg/apis/autoscaling/v2alpha1/generated.pb.go @@ -2988,81 +2988,80 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 1208 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x57, 0x5b, 0x6f, 0x1b, 0x45, - 0x14, 0x8e, 0x2f, 0x49, 0xc3, 0x38, 0x37, 0x26, 0x55, 0xea, 0x26, 0xd4, 0x8e, 0xf6, 0xa9, 0x54, - 0xb0, 0x4b, 0x4c, 0x41, 0x54, 0x08, 0xa1, 0xd8, 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x0d, 0x91, 0x69, 0x7f, 0xe4, 0x01, 0x88, 0xc4, 0x87, 0x37, 0x41, 0x91, 0x1f, 0xb9, 0x44, - 0x5d, 0x17, 0xeb, 0x83, 0x51, 0xb7, 0x7b, 0xe4, 0x92, 0x27, 0xbd, 0xea, 0x92, 0xb2, 0x14, 0xb7, - 0x7f, 0xb0, 0x86, 0x84, 0x35, 0x6c, 0x83, 0x19, 0x47, 0x9c, 0x12, 0xa5, 0x53, 0x63, 0xe2, 0xd8, - 0xc3, 0x29, 0x1e, 0xc2, 0xd7, 0x41, 0x30, 0xef, 0xd4, 0xe1, 0x53, 0xf0, 0xf0, 0x73, 0x50, 0x74, - 0x9d, 0xd6, 0x60, 0xca, 0x6e, 0x4e, 0x4c, 0xb3, 0xe3, 0xb4, 0x58, 0x82, 0x64, 0x36, 0xc8, 0x2e, - 0x58, 0x45, 0x02, 0x18, 0x3a, 0x60, 0x76, 0xf0, 0xba, 0x11, 0x4a, 0x96, 0x6a, 0xef, 0x4e, 0x4c, - 0x82, 0x14, 0x40, 0x82, 0x68, 0x2e, 0x98, 0xa1, 0x83, 0x1d, 0x14, 0x92, 0x68, 0x7f, 0xe5, 0xc1, - 0x5c, 0x5c, 0xb8, 0xff, 0x86, 0x02, 0xb2, 0x87, 0x9e, 0xb2, 0x02, 0x92, 0xe4, 0x19, 0x28, 0x20, - 0x89, 0xb2, 0x14, 0xf8, 0x2e, 0x0f, 0x60, 0xba, 0xfd, 0x20, 0x07, 0x33, 0x5c, 0xcc, 0xf2, 0xa7, - 0x72, 0x89, 0x84, 0x17, 0xba, 0xba, 0x2f, 0x14, 0x57, 0xf0, 0xd4, 0x92, 0xd3, 0x76, 0x3b, 0x7a, - 0x92, 0x85, 0x4f, 0x9d, 0x66, 0xb8, 0x83, 0x62, 0x56, 0x90, 0x80, 0x92, 0xf4, 0xbe, 0x8f, 0x3b, - 0x3e, 0x51, 0xca, 0x8c, 0xbd, 0xe7, 0xf5, 0x41, 0xf2, 0xfa, 0x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x97, 0xee, 0x5a, 0xbf, 0x57, 0xbd, 0xda, 0xc8, 0x32, 0x42, 0xd9, 0xfe, 0x59, 0xdd, 0x57, - 0x78, 0x36, 0xdd, 0x57, 0xbf, 0x71, 0x72, 0x5a, 0x99, 0x7a, 0x74, 0x5a, 0x99, 0xfa, 0xf5, 0xb4, - 0x32, 0xf5, 0x55, 0xbf, 0x92, 0x3b, 0xe9, 0x57, 0x72, 0x8f, 0xfa, 0x95, 0xdc, 0x6f, 0xfd, 0x4a, - 0xee, 0x9b, 0xc7, 0x95, 0xa9, 0x4f, 0x66, 0x07, 0x83, 0xf0, 0xef, 0x00, 0x00, 0x00, 0xff, 0xff, - 0x95, 0xf2, 0xec, 0x8a, 0x16, 0x12, 0x00, 0x00, + // 1196 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x57, 0x5b, 0x6f, 0x1b, 0xc5, + 0x17, 0x8f, 0x2f, 0x49, 0xf3, 0x9f, 0x4d, 0x93, 0xfc, 0x27, 0x55, 0xea, 0x26, 0xd4, 0x8e, 0xf6, + 0xa9, 0x54, 0xb0, 0x4b, 0x4c, 0x41, 0x54, 0x08, 0xa1, 0xd8, 0x5c, 0x5a, 0x11, 0xa7, 0x61, 0x1a, + 0x2a, 0x04, 0x48, 0x30, 0x59, 0x4f, 0x9c, 0x21, 0xde, 0x8b, 0x76, 0x66, 0x2d, 0x12, 0xa9, 0x12, + 0x1f, 0x80, 0x07, 0x5e, 0xf8, 0x08, 0x48, 0x7c, 0x03, 0x9e, 0x41, 0x42, 0xca, 0x63, 0x79, 0xe3, + 0xc9, 0x22, 0xee, 0x1b, 0x1f, 0xa1, 0x12, 0x17, 0xed, 0xcc, 0x78, 0x2f, 0x5e, 0x6f, 0x88, 0x43, + 0x5a, 0xc1, 0x9b, 0x67, 0xe6, 0x9c, 0xdf, 0xef, 0x9c, 0xf3, 0x3b, 0x3e, 0x33, 0x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 0x8b, 0x04, 0x30, 0x74, 0xc1, 0xec, 0xf0, 0x9d, 0x22, 0x94, + 0xd4, 0xea, 0x6f, 0x4f, 0x4c, 0x82, 0x14, 0x40, 0x8a, 0x68, 0x2e, 0x9c, 0xa1, 0xc3, 0x13, 0x14, + 0x91, 0xe8, 0x7f, 0x16, 0xc1, 0x5c, 0x52, 0xb8, 0x7f, 0x87, 0x02, 0xb2, 0x87, 0x9e, 0xb2, 0x02, + 0x92, 0xe4, 0x19, 0x28, 0x20, 0x89, 0xf2, 0x14, 0xf8, 0xb6, 0x08, 0x60, 0xb6, 0xfd, 0x20, 0x07, + 0x33, 0x5c, 0xcc, 0xf2, 0xa7, 0x72, 0x89, 0x44, 0x17, 0xba, 0xba, 0x2f, 0x14, 0x57, 0xf8, 0xd4, + 0x92, 0xd3, 0x76, 0x2b, 0x7e, 0x92, 0x45, 0x4f, 0x9d, 0x56, 0x74, 0x82, 0x12, 0x56, 0x90, 0x00, + 0x4d, 0x7a, 0x3f, 0xc0, 0xdd, 0x80, 0x28, 0x65, 0x4e, 0xbd, 0xe7, 0x8d, 0x61, 0xf2, 0xc6, 0xfb, + 0x01, 0x76, 0x38, 0xe5, 0x87, 0xf1, 0x2d, 0xb3, 0x13, 0x43, 0xa1, 0x24, 0xae, 0xfe, 0xdd, 0x68, + 0x9d, 0x64, 0xbf, 0xfe, 0x77, 0xea, 0xb4, 0x0f, 0xe6, 0xd4, 0xf0, 0xfb, 0x27, 0x85, 0xba, 0xa2, + 0x58, 0xe6, 0x9a, 0x09, 0x2c, 0x94, 0x42, 0xd6, 0x7f, 0x2c, 0x80, 0xc5, 0xd1, 0x51, 0x33, 0x12, + 0x72, 0xe1, 0x4c, 0x21, 0x1f, 0x01, 0x28, 0x13, 0xde, 0xe8, 0x11, 0x1f, 0x77, 0x88, 0x0c, 0xbc, + 0x78, 0xae, 0xc0, 0x57, 0x14, 0x17, 0xdc, 0xc9, 0x20, 0xa2, 0x31, 0x2c, 0xfa, 0x4f, 0xe9, 0x24, + 0xa4, 0xda, 0xe7, 0x49, 0xe2, 0x21, 0x58, 0x52, 0xd5, 0xb9, 0x80, 0x2c, 0x56, 0x15, 0xd9, 0x52, + 0x33, 0x0b, 0x89, 0xc6, 0xf1, 0xe8, 0xdf, 0x17, 0xc1, 0x95, 0x71, 0x23, 0x19, 0xb6, 0xd4, 0x87, + 0x8f, 0xcc, 0xe2, 0x76, 0xf2, 0xc3, 0xe7, 0x49, 0xbf, 0xf6, 0xfc, 0x69, 0x5f, 0x70, 0xd1, 0x84, + 0x49, 0x7c, 0x25, 0x7d, 0x08, 0x2a, 0xa9, 0x2a, 0x7e, 0xc0, 0x69, 0x97, 0x1e, 0xc9, 0x17, 0x90, + 0x7c, 0xfc, 0x3d, 0x37, 0xe8, 0xd7, 0x2a, 0x3b, 0x39, 0x36, 0x28, 0xd7, 0x1b, 0xf6, 0xc6, 0x76, + 0xc1, 0xf9, 0xda, 0x77, 0x79, 0x82, 0x0e, 0xf8, 0x21, 0x5b, 0x39, 0xd9, 0x05, 0x17, 0x5c, 0xb9, + 0x8f, 0xc1, 0xb5, 0xb4, 0x70, 0xd9, 0xd2, 0x5d, 0x1f, 0xf4, 0x6b, 0xd7, 0x9a, 0x79, 0x46, 0x28, + 0xdf, 0x3f, 0xaf, 0xfb, 0x4a, 0xcf, 0xa6, 0xfb, 0x1a, 0x37, 0x8f, 0x4f, 0xaa, 0x53, 0x8f, 0x4e, + 0xaa, 0x53, 0xbf, 0x9c, 0x54, 0xa7, 0xbe, 0x1c, 0x54, 0x0b, 0xc7, 0x83, 0x6a, 0xe1, 0xd1, 0xa0, + 0x5a, 0xf8, 0x75, 0x50, 0x2d, 0x7c, 0xfd, 0xb8, 0x3a, 0xf5, 0xd1, 0xec, 0x70, 0x10, 0xfe, 0x15, + 0x00, 0x00, 0xff, 0xff, 0x08, 0xe1, 0xc3, 0x12, 0xe0, 0x11, 0x00, 0x00, } diff --git a/pkg/apis/autoscaling/v2alpha1/generated.proto b/pkg/apis/autoscaling/v2alpha1/generated.proto index 5dffa59979f25..912eead8f39b5 100644 --- a/pkg/apis/autoscaling/v2alpha1/generated.proto +++ b/pkg/apis/autoscaling/v2alpha1/generated.proto @@ -26,7 +26,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; import "k8s.io/kubernetes/pkg/apis/autoscaling/v1/generated.proto"; diff --git a/pkg/apis/batch/v1/generated.pb.go b/pkg/apis/batch/v1/generated.pb.go index 86622d9561212..5f33644b48d51 100644 --- a/pkg/apis/batch/v1/generated.pb.go +++ b/pkg/apis/batch/v1/generated.pb.go @@ -1526,61 +1526,60 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 885 bytes of a gzipped FileDescriptorProto + // 870 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x54, 0xdd, 0x6e, 0xe3, 0x44, 0x14, 0xce, 0x4f, 0xd3, 0x26, 0x93, 0xb6, 0xbb, 0x8c, 0x54, 0x29, 0xf4, 0x22, 0x59, 0x05, 0x84, 0x0a, 0xda, 0xb5, 0x49, 0xbb, 0x42, 0x88, 0x0b, 0x24, 0x5c, 0x84, 0x44, 0xd5, 0xb2, 0xd5, 0xa4, - 0x02, 0x89, 0x1f, 0x89, 0xb1, 0x7d, 0x9a, 0x0e, 0xb5, 0x3d, 0x96, 0x67, 0x12, 0xd1, 0x3b, 0xde, - 0x00, 0x1e, 0x06, 0x21, 0x1e, 0xa1, 0x97, 0xbd, 0xe4, 0x2a, 0xa2, 0xe6, 0x2d, 0xf6, 0x0a, 0xcd, - 0x78, 0xfc, 0x93, 0x4d, 0x0a, 0xd9, 0xbd, 0xb3, 0xcf, 0x7c, 0xdf, 0x37, 0x67, 0xce, 0xf9, 0xce, - 0x41, 0x47, 0xd7, 0x1f, 0x0b, 0x8b, 0x71, 0xfb, 0x7a, 0xea, 0x42, 0x12, 0x81, 0x04, 0x61, 0xc7, - 0xd7, 0x13, 0x9b, 0xc6, 0x4c, 0xd8, 0x2e, 0x95, 0xde, 0x95, 0x3d, 0x1b, 0xd9, 0x13, 0x88, 0x20, - 0xa1, 0x12, 0x7c, 0x2b, 0x4e, 0xb8, 0xe4, 0xf8, 0x9d, 0x8c, 0x64, 0x95, 0x24, 0x2b, 0xbe, 0x9e, - 0x58, 0x8a, 0x64, 0x69, 0x92, 0x35, 0x1b, 0xed, 0x3f, 0x9b, 0x30, 0x79, 0x35, 0x75, 0x2d, 0x8f, - 0x87, 0xf6, 0x84, 0x4f, 0xb8, 0xad, 0xb9, 0xee, 0xf4, 0x52, 0xff, 0xe9, 0x1f, 0xfd, 0x95, 0x69, - 0xee, 0x3f, 0x37, 0x89, 0xd0, 0x98, 0x85, 0xd4, 0xbb, 0x62, 0x11, 0x24, 0x37, 0x65, 0x2a, 0x21, - 0x48, 0xba, 0x22, 0x93, 0x7d, 0xfb, 0x21, 0x56, 0x32, 0x8d, 0x24, 0x0b, 0x61, 0x89, 0xf0, 0xd1, - 0xff, 0x11, 0x84, 0x77, 0x05, 0x21, 0x5d, 0xe2, 0x1d, 0x3d, 0xc4, 0x9b, 0x4a, 0x16, 0xd8, 0x2c, - 0x92, 0x42, 0x26, 0x4b, 0xa4, 0xca, 0x9b, 0x04, 0x24, 0x33, 0x48, 0xca, 0x07, 0xc1, 0xcf, 0x34, - 0x8c, 0x03, 0x58, 0xf5, 0xa6, 0xa7, 0x0f, 0xb6, 0x64, 0x05, 0x7a, 0xf8, 0x6b, 0x03, 0x35, 0x4f, - 0xb8, 0x8b, 0x7f, 0x44, 0x6d, 0x55, 0x24, 0x9f, 0x4a, 0xda, 0xab, 0x3f, 0xa9, 0x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, 0xfe, 0xd6, + 0x44, 0x9d, 0xe2, 0xb1, 0xc1, 0x80, 0x90, 0x97, 0x2f, 0xb4, 0xe8, 0xd5, 0xb5, 0x39, 0x46, 0xeb, + 0x9a, 0xa3, 0x78, 0x0a, 0xca, 0x17, 0xb6, 0x08, 0x09, 0x52, 0x11, 0xc6, 0xdf, 0xa0, 0x8e, 0x90, + 0x34, 0x91, 0x7a, 0x55, 0x1b, 0x8f, 0x5e, 0xd5, 0x9d, 0x74, 0x3e, 0xe8, 0x8c, 0x73, 0x01, 0x52, + 0x6a, 0xe1, 0x4b, 0xb4, 0x5b, 0xba, 0xe4, 0x7f, 0x3e, 0x3b, 0x7a, 0x24, 0xc7, 0x0b, 0x2a, 0xe4, + 0x0d, 0x55, 0xb5, 0xfc, 0x99, 0x8d, 0xb4, 0x57, 0x5a, 0xe5, 0xf2, 0x67, 0x9e, 0x23, 0xe6, 0x14, + 0xdb, 0xa8, 0x23, 0xa6, 0x9e, 0x07, 0xe0, 0x83, 0xaf, 0x27, 0xde, 0x72, 0xde, 0x32, 0xd0, 0xce, + 0x38, 0x3f, 0x20, 0x25, 0x46, 0x09, 0x5f, 0x52, 0x16, 0x80, 0xaf, 0x27, 0x5d, 0x11, 0xfe, 0x42, + 0x47, 0x89, 0x39, 0x75, 0xde, 0xbd, 0xbd, 0xef, 0xd7, 0xee, 0xee, 0xfb, 0xb5, 0x3f, 0xef, 0xfb, + 0xb5, 0x9f, 0xd3, 0x7e, 0xfd, 0x36, 0xed, 0xd7, 0xef, 0xd2, 0x7e, 0xfd, 0xaf, 0xb4, 0x5f, 0xff, + 0xf5, 0xef, 0x7e, 0xed, 0xdb, 0xc6, 0x6c, 0xf4, 0x4f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3b, 0xa8, + 0x29, 0x00, 0xc1, 0x08, 0x00, 0x00, } diff --git a/pkg/apis/batch/v1/generated.proto b/pkg/apis/batch/v1/generated.proto index fe946b2631983..5be64f661d4a0 100644 --- a/pkg/apis/batch/v1/generated.proto +++ b/pkg/apis/batch/v1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; // Package-wide variables from generator "generated". diff --git a/pkg/apis/batch/v2alpha1/generated.pb.go b/pkg/apis/batch/v2alpha1/generated.pb.go index e89789fcb4d95..a9fe7f098ce6b 100644 --- a/pkg/apis/batch/v2alpha1/generated.pb.go +++ b/pkg/apis/batch/v2alpha1/generated.pb.go @@ -1457,55 +1457,54 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 799 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x94, 0x4d, 0x4f, 0xe3, 0x46, - 0x18, 0xc7, 0xe3, 0x90, 0x37, 0x26, 0xa5, 0x05, 0xb7, 0x82, 0x28, 0x95, 0x9c, 0x28, 0x52, 0xa5, - 0x14, 0x81, 0x5d, 0x42, 0x85, 0x68, 0x6f, 0x35, 0x55, 0xd5, 0x22, 0xfa, 0x22, 0x07, 0xd4, 0xaa, - 0x42, 0x15, 0x63, 0xe7, 0x49, 0x32, 0xc4, 0x6f, 0xf5, 0x8c, 0xa3, 0xe6, 0xd6, 0x8f, 0xd0, 0x6f, - 0xd1, 0x6f, 0xb1, 0x97, 0xdd, 0x03, 0x47, 0x0e, 0x7b, 0xd8, 0xbd, 0x44, 0x8b, 0xf7, 0x5b, 0xec, - 0x69, 0xe5, 0x89, 0x13, 0x07, 0x1c, 0x2f, 0x61, 0x57, 0xe2, 0xe6, 0x19, 0x3f, 0xff, 0xdf, 0x3c, - 0xcf, 0xf3, 0x7f, 0x66, 0xd0, 0x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x60, 0x83, 0x91, 0x61, 0x38, 0x40, 0xe1, 0xb0, 0xee, 0xa6, - 0xf7, 0x2c, 0x7e, 0x2d, 0x34, 0xe8, 0x42, 0x68, 0x12, 0xc4, 0x17, 0xee, 0x3b, 0x0e, 0xd1, 0x22, - 0x98, 0x68, 0xa2, 0x75, 0x13, 0x53, 0x36, 0x9d, 0xc2, 0x53, 0x62, 0x01, 0xf7, 0xaf, 0xdc, 0xda, - 0x5e, 0xee, 0xa2, 0x85, 0x0a, 0xf5, 0xb3, 0x60, 0x5c, 0x5b, 0x3f, 0xb9, 0xc3, 0xd1, 0x12, 0xe4, - 0xc6, 0x4b, 0x01, 0xcd, 0xfb, 0xf4, 0x08, 0x8f, 0x61, 0x1f, 0x95, 0xd8, 0x74, 0xd8, 0xb2, 0x1f, - 0x3c, 0x6c, 0xb3, 0x5b, 0x3b, 0x9b, 0xb4, 0x19, 0xbd, 0xf1, 0x54, 0x40, 0x9f, 0xdc, 0x89, 0x7f, - 0x84, 0xfa, 0x7e, 0xb9, 0xf5, 0xd8, 0xef, 0x2c, 0x51, 0x1b, 0xaf, 0x2a, 0xed, 0x89, 0x57, 0xb7, - 0xaf, 0x6e, 0xa4, 0xcc, 0xf5, 0x8d, 0x94, 0x79, 0x71, 0x23, 0x65, 0xfe, 0x0d, 0x24, 0xe1, 0x2a, - 0x90, 0x84, 0xeb, 0x40, 0x12, 0x5e, 0x05, 0x92, 0xf0, 0xdf, 0x6b, 0x29, 0xf3, 0x67, 0x69, 0xda, - 0x9d, 0xb7, 0x01, 0x00, 0x00, 0xff, 0xff, 0x32, 0x5e, 0xac, 0x56, 0xd9, 0x08, 0x00, 0x00, + // 783 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x94, 0x4d, 0x4f, 0xdb, 0x48, + 0x18, 0xc7, 0xe3, 0x90, 0x37, 0x26, 0xcb, 0x2e, 0x78, 0x57, 0x10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0x75, 0xa1, 0x5e, 0x6c, 0x34, 0x6e, 0x5e, + 0x8e, 0xba, 0x14, 0xe2, 0xb3, 0x0f, 0x02, 0x90, 0x36, 0xe2, 0xd5, 0xde, 0x66, 0x26, 0x65, 0x04, + 0xf6, 0x89, 0x1b, 0xa0, 0x10, 0x8c, 0x6c, 0xcb, 0x33, 0x30, 0x2f, 0x63, 0x31, 0x4a, 0xab, 0x19, + 0xee, 0x6b, 0x93, 0x08, 0xf1, 0x08, 0xac, 0x51, 0x06, 0x5d, 0x46, 0xac, 0xce, 0x5d, 0x0c, 0x5b, + 0x06, 0xb1, 0x70, 0x13, 0x23, 0xdb, 0x6a, 0x51, 0xde, 0xd3, 0x05, 0xf5, 0x4f, 0x7f, 0x58, 0x59, + 0x6b, 0xce, 0x0e, 0xd1, 0x92, 0xb4, 0xe2, 0x31, 0x58, 0x41, 0xb6, 0x85, 0x3c, 0xd7, 0xc5, 0x16, + 0x1a, 0x3c, 0xb1, 0x0d, 0x82, 0x06, 0xbc, 0x91, 0x8b, 0xaa, 0x1c, 0x66, 0xb3, 0xb2, 0x77, 0x35, + 0xe0, 0xeb, 0xac, 0x4d, 0x2d, 0x0e, 0x12, 0xff, 0x02, 0x79, 0xea, 0x51, 0x07, 0x5b, 0xad, 0x52, + 0xa6, 0x2a, 0xd4, 0x0b, 0x6a, 0xd1, 0x1f, 0x56, 0xf2, 0xcd, 0xd1, 0x96, 0x36, 0xfe, 0x27, 0xbe, + 0x04, 0xc5, 0x53, 0x5b, 0x3f, 0xc4, 0xa6, 0x63, 0x40, 0x86, 0x4b, 0x59, 0xde, 0xd3, 0xff, 0x6f, + 0x60, 0xfc, 0x7e, 0xa4, 0xe6, 0x73, 0xfa, 0x7b, 0x98, 0x7a, 0x71, 0xea, 0x87, 0x36, 0x7d, 0x86, + 0xf8, 0x02, 0x94, 0xa9, 0x87, 0x10, 0xa6, 0xb4, 0xed, 0x19, 0xfb, 0xb6, 0x4e, 0xef, 0x13, 0xca, + 0x6c,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0xc2, 0xeb, 0x2f, 0x52, 0xea, 0x79, 0x61, 0xec, + 0xce, 0xb7, 0x00, 0x00, 0x00, 0xff, 0xff, 0x09, 0x9b, 0x4c, 0x2b, 0xa3, 0x08, 0x00, 0x00, } diff --git a/pkg/apis/batch/v2alpha1/generated.proto b/pkg/apis/batch/v2alpha1/generated.proto index a5230d9c0e161..d5e225257ab4d 100644 --- a/pkg/apis/batch/v2alpha1/generated.proto +++ b/pkg/apis/batch/v2alpha1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; import "k8s.io/kubernetes/pkg/apis/batch/v1/generated.proto"; diff --git a/pkg/apis/certificates/v1beta1/generated.pb.go b/pkg/apis/certificates/v1beta1/generated.pb.go index 7687d99316434..184296f9857d0 100644 --- a/pkg/apis/certificates/v1beta1/generated.pb.go +++ b/pkg/apis/certificates/v1beta1/generated.pb.go @@ -1632,58 +1632,56 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 833 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0xcf, 0x8f, 0xdb, 0x44, - 0x14, 0x8e, 0xf3, 0x6b, 0x93, 0xc9, 0xb2, 0xad, 0x46, 0xa8, 0x32, 0x2b, 0xd5, 0x5e, 0x59, 0x80, - 0xb6, 0x08, 0x6c, 0xb2, 0x20, 0x58, 0x95, 0x03, 0x92, 0x4b, 0x85, 0x0a, 0x2d, 0x3f, 0x66, 0x1b, - 0x24, 0x10, 0x07, 0x26, 0xce, 0xab, 0x77, 0x9a, 0xf8, 0x07, 0x9e, 0x71, 0xb4,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x4f, 0x2f, 0xac, 0xda, 0x6f, 0x17, 0x56, 0xed, 0xc9, 0xc2, 0x32, - 0xce, 0x17, 0x96, 0xf1, 0x74, 0x61, 0x19, 0x7f, 0x2c, 0x2c, 0xe3, 0xa7, 0x3f, 0xad, 0xda, 0x37, - 0x3b, 0xba, 0xb3, 0x7f, 0x02, 0x00, 0x00, 0xff, 0xff, 0xc5, 0x92, 0xb9, 0x6f, 0x52, 0x08, 0x00, - 0x00, + // 815 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0xcd, 0x8f, 0x1b, 0x35, + 0x14, 0xcf, 0xe4, 0x3b, 0xce, 0xb2, 0xad, 0x2c, 0x54, 0x0d, 0x91, 0x3a, 0x13, 0x8d, 0x00, 0x6d, + 0x11, 0xcc, 0x90, 0x05, 0xc1, 0xaa, 0x1c, 0x90, 0xa6, 0x54, 0xa8, 0xd0, 0xf2, 0xe1, 0x6d, 0x90, + 0x40, 0x1c, 0x70, 0x26, 0xaf, 0xb3, 0x6e, 0x76, 0x3e, 0x18, 0x7b, 0xa2, 0xe6, 0x82, 0x7a, 0xe3, + 0xca, 0x91, 0x0b, 0x12, 0x7f, 0xce, 0x1e, 0x7b, 0xe4, 0x80, 0x22, 0x36, 0x9c, 0xb8, 0xf0, 0x07, + 0xf4, 0x84, 0xec, 0x71, 0x32, 0x21, 0x51, 0xfa, 0x21, 0xe5, 0x66, 0xff, 0xfc, 0xde, 0xef, 0xf7, + 0xde, 0xcf, 0xcf, 0x46, 0x1f, 0x4f, 0x4e, 0xb8, 0xcb, 0x12, 0x6f, 0x92, 0x8f, 0x20, 0x8b, 0x41, + 0x00, 0xf7, 0xd2, 0x49, 0xe8, 0xd1, 0x94, 0x71, 0x2f, 0x80, 0x4c, 0xb0, 0x07, 0x2c, 0xa0, 0x12, + 0x9d, 0x0e, 0x46, 0x20, 0xe8, 0xc0, 0x0b, 0x21, 0x86, 0x8c, 0x0a, 0x18, 0xbb, 0x69, 0x96, 0x88, + 0x04, 0x7b, 0x05, 0x81, 0x5b, 0x12, 0xb8, 0xe9, 0x24, 0x74, 0x25, 0x81, 0xbb, 0x4e, 0xe0, 0x6a, + 0x82, 0xde, 0x3b, 0x21, 0x13, 0x67, 0xf9, 0xc8, 0x0d, 0x92, 0xc8, 0x0b, 0x93, 0x30, 0xf1, 0x14, + 0xcf, 0x28, 0x7f, 0xa0, 0x76, 0x6a, 0xa3, 0x56, 0x05, 0x7f, 0xef, 0x7d, 0x5d, 0x20, 0x4d, 0x59, + 0x44, 0x83, 0x33, 0x16, 0x43, 0x36, 0x2b, 0x4b, 0x8c, 0x40, 0x50, 0x6f, 0xba, 0x55, 0x55, 0xcf, + 0xdb, 0x95, 0x95, 0xe5, 0xb1, 0x60, 0x11, 0x6c, 0x25, 0x7c, 0xf0, 0xbc, 0x04, 0x1e, 0x9c, 0x41, + 0x44, 0xb7, 0xf2, 0xde, 0xdb, 0x95, 0x97, 0x0b, 0x76, 0xee, 0xb1, 0x58, 0x70, 0x91, 0x6d, 0x26, + 0x39, 0xff, 0x54, 0xd1, 0x6b, 0xb7, 0x4a, 0x6f, 0x4e, 0x59, 0x18, 0xb3, 0x38, 0x24, 0xf0, 0x63, + 0x0e, 0x5c, 0xe0, 0x1f, 0x50, 0x5b, 0xb6, 0x35, 0xa6, 0x82, 0x9a, 0x46, 0xdf, 0x38, 0xea, 0x1e, + 0xbf, 0xeb, 0x6a, 0x93, 0xd7, 0x55, 0x4a, 0x9b, 0x65, 0xb4, 0x3b, 0x1d, 0xb8, 0x5f, 0x8e, 0x1e, + 0x42, 0x20, 0xee, 0x81, 0xa0, 0x3e, 0xbe, 0x98, 0xdb, 0x95, 0xc5, 0xdc, 0x46, 0x25, 0x46, 0x56, + 0xac, 0x38, 0x45, 0x75, 0x9e, 0x42, 0x60, 0x56, 0x15, 0xfb, 0x17, 0xee, 0x4b, 0x5e, 0xa1, 0xbb, + 0xb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0xa4, 0x60, 0xba, 0x59, + 0x3d, 0x31, 0x9c, 0xb9, 0x81, 0xec, 0xe7, 0xfc, 0x18, 0xf8, 0x67, 0x03, 0xa1, 0x60, 0xf9, 0xa0, + 0xb9, 0x69, 0x28, 0x83, 0x4e, 0xf7, 0x67, 0xd0, 0xea, 0xb3, 0x28, 0x7f, 0xe3, 0x15, 0xc4, 0xc9, + 0x9a, 0x34, 0x1e, 0xa0, 0xee, 0x1a, 0xb5, 0xb2, 0xe2, 0xc0, 0xbf, 0xb2, 0x98, 0xdb, 0xdd, 0x35, + 0x72, 0xb2, 0x1e, 0xe3, 0x7c, 0xa8, 0x7d, 0x55, 0x9d, 0x63, 0x7b, 0xf9, 0x88, 0x0c, 0x35, 0x16, + 0x9d, 0xcd, 0xa1, 0xbf, 0xd9, 0xfe, 0xf5, 0x77, 0xbb, 0xf2, 0xf8, 0xcf, 0x7e, 0xc5, 0xbf, 0x71, + 0x71, 0x69, 0x55, 0x9e, 0x5c, 0x5a, 0x95, 0x3f, 0x2e, 0xad, 0xca, 0xe3, 0x85, 0x65, 0x5c, 0x2c, + 0x2c, 0xe3, 0xc9, 0xc2, 0x32, 0xfe, 0x5a, 0x58, 0xc6, 0x2f, 0x7f, 0x5b, 0x95, 0xef, 0x5a, 0xba, + 0xb3, 0xff, 0x02, 0x00, 0x00, 0xff, 0xff, 0x5b, 0xd3, 0xf0, 0x05, 0x1c, 0x08, 0x00, 0x00, } diff --git a/pkg/apis/certificates/v1beta1/generated.proto b/pkg/apis/certificates/v1beta1/generated.proto index 6d58d71614110..1b6b263c944d5 100644 --- a/pkg/apis/certificates/v1beta1/generated.proto +++ b/pkg/apis/certificates/v1beta1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; diff --git a/pkg/apis/componentconfig/types.go b/pkg/apis/componentconfig/types.go index 90efddee13d7a..1bfa1050369ef 100644 --- a/pkg/apis/componentconfig/types.go +++ b/pkg/apis/componentconfig/types.go @@ -219,11 +219,6 @@ type KubeletConfiguration struct { Authentication KubeletAuthentication // authorization specifies how requests to the Kubelet's server are authorized Authorization KubeletAuthorization - // podInfraContainerImage is the image whose network/ipc namespaces - // containers in each pod will use. - PodInfraContainerImage string - // dockerEndpoint is the path to the docker endpoint to communicate with. - DockerEndpoint string // rootDirectory is the directory path to place kubelet files (volume // mounts,etc). RootDirectory string @@ -316,22 +311,6 @@ type KubeletConfiguration struct { LowDiskSpaceThresholdMB int32 // How frequently to calculate and cache volume disk usage for all pods VolumeStatsAggPeriod metav1.Duration - // networkPluginName is the name of the network plugin to be invoked for - // various events in kubelet/pod lifecycle - NetworkPluginName string - // networkPluginMTU is the MTU to be passed to the network plugin, - // and overrides the default MTU for cases where it cannot be automatically - // computed (such as IPSEC). - NetworkPluginMTU int32 - // networkPluginDir is the full path of the directory in which to search - // for network plugins (and, for backwards-compat, CNI config files) - NetworkPluginDir string - // CNIConfDir is the full path of the directory in which to search for - // CNI config files - CNIConfDir string - // CNIBinDir is the full path of the directory in which to search for - // CNI plugin binaries - CNIBinDir string // volumePluginDir is the full path of the directory in which to search // for additional third party volume plugins VolumePluginDir string @@ -374,23 +353,8 @@ type KubeletConfiguration struct { // requests - pull, logs, exec and attach. // +optional RuntimeRequestTimeout metav1.Duration - // If no pulling progress is made before the deadline imagePullProgressDeadline, - // the image pulling will be cancelled. Defaults to 1m0s. - // +optional - ImagePullProgressDeadline metav1.Duration - // rktPath is the path of rkt binary. Leave empty to use the first rkt in - // $PATH. - // +optional - RktPath string // experimentalMounterPath is the path of mounter binary. Leave empty to use the default mount path ExperimentalMounterPath string - // rktApiEndpoint is the endpoint of the rkt API service to communicate with. - // +optional - RktAPIEndpoint string - // rktStage1Image is the image to use as stage1. Local paths and - // http/https URLs are supported. - // +optional - RktStage1Image string // lockFilePath is the path that kubelet will use to as a lock file. // It uses this file as a lock to synchronize with other kubelet processes // that may be running. @@ -411,10 +375,6 @@ type KubeletConfiguration struct { HairpinMode string // maxPods is the number of pods that can run on this Kubelet. MaxPods int32 - // dockerExecHandlerName is the handler to use when executing a command - // in a container. Valid values are 'native' and 'nsenter'. Defaults to - // 'native'. - DockerExecHandlerName string // The CIDR to use for pod IP addresses, only used in standalone mode. // In cluster mode, this is obtained from the master. PodCIDR string @@ -509,9 +469,6 @@ type KubeletConfiguration struct { // featureGates is a string of comma-separated key=value pairs that describe feature // gates for alpha/experimental features. FeatureGates string - // Enable dockershim only mode. - // +optional - ExperimentalDockershim bool // TODO(#34726:1.8.0): Remove the opt-in for failing when swap is enabled. // Tells the Kubelet to fail to start if swap is enabled on the node. ExperimentalFailSwapOn bool @@ -522,11 +479,6 @@ type KubeletConfiguration struct { // This flag, if set, instructs the kubelet to keep volumes from terminated pods mounted to the node. // This can be useful for debugging volume related issues. KeepTerminatedPodVolumes bool - // This flag, if set, disables use of a shared PID namespace for pods running in the docker CRI runtime. - // A shared PID namespace is the only option in non-docker runtimes and is required by the CRI. The ability to - // disable it for docker will be removed unless a compelling use case is discovered with widespread use. - // TODO: Remove once we no longer support disabling shared PID namespace (https://issues.k8s.io/41938) - DockerDisableSharedPID bool /* following flags are meant for Node Allocatable */ @@ -547,7 +499,7 @@ type KubeletConfiguration struct { // Refer to [Node Allocatable](https://github.com/kubernetes/community/blob/master/contributors/design-proposals/node-allocatable.md) doc for more information. KubeReservedCgroup string // This flag specifies the various Node Allocatable enforcements that Kubelet needs to perform. - // This flag accepts a list of options. Acceptible options are `pods`, `system-reserved` & `kube-reserved`. + // This flag accepts a list of options. Acceptable options are `pods`, `system-reserved` & `kube-reserved`. // Refer to [Node Allocatable](https://github.com/kubernetes/community/blob/master/contributors/design-proposals/node-allocatable.md) doc for more information. EnforceNodeAllocatable []string // This flag, if set, will avoid including `EvictionHard` limits while computing Node Allocatable. @@ -836,12 +788,9 @@ type KubeControllerManagerConfiguration struct { // clusterSigningCertFile is the filename containing a PEM-encoded // RSA or ECDSA private key used to issue cluster-scoped certificates ClusterSigningKeyFile string - // approveAllKubeletCSRs tells the CSR controller to approve all CSRs originating - // from the kubelet bootstrapping group automatically. - // WARNING: this grants all users with access to the certificates API group - // the ability to create credentials for any user that has access to the boostrapping - // user's credentials. - ApproveAllKubeletCSRsForGroup string + // clusterSigningDuration is the length of duration signed certificates + // will be given. + ClusterSigningDuration metav1.Duration // enableProfiling enables profiling via web interface host:port/debug/pprof/ EnableProfiling bool // enableContentionProfiling enables lock contention profiling, if enableProfiling is true. @@ -888,7 +837,7 @@ type KubeControllerManagerConfiguration struct { GCIgnoredResources []GroupResource // nodeEvictionRate is the number of nodes per second on which pods are deleted in case of node failure when a zone is healthy NodeEvictionRate float32 - // secondaryNodeEvictionRate is the number of nodes per second on which pods are deleted in case of node failure when a zone is unhealty + // secondaryNodeEvictionRate is the number of nodes per second on which pods are deleted in case of node failure when a zone is unhealthy SecondaryNodeEvictionRate float32 // secondaryNodeEvictionRate is implicitly overridden to 0 for clusters smaller than or equal to largeClusterSizeThreshold LargeClusterSizeThreshold int32 diff --git a/pkg/apis/componentconfig/v1alpha1/defaults.go b/pkg/apis/componentconfig/v1alpha1/defaults.go index 0421118fadf63..acb10c124e129 100644 --- a/pkg/apis/componentconfig/v1alpha1/defaults.go +++ b/pkg/apis/componentconfig/v1alpha1/defaults.go @@ -35,16 +35,6 @@ import ( const ( defaultRootDir = "/var/lib/kubelet" - // When these values are updated, also update test/e2e/framework/util.go - defaultPodInfraContainerImageName = "gcr.io/google_containers/pause" - defaultPodInfraContainerImageVersion = "3.0" - defaultPodInfraContainerImage = defaultPodInfraContainerImageName + - "-" + runtime.GOARCH + ":" + - defaultPodInfraContainerImageVersion - - // From pkg/kubelet/rkt/rkt.go to avoid circular import - defaultRktAPIServiceEndpoint = "localhost:15441" - AutoDetectCloudProvider = "auto-detect" defaultIPTablesMasqueradeBit = 14 @@ -240,18 +230,9 @@ func SetDefaults_KubeletConfiguration(obj *KubeletConfiguration) { if obj.RuntimeRequestTimeout == zeroDuration { obj.RuntimeRequestTimeout = metav1.Duration{Duration: 2 * time.Minute} } - if obj.ImagePullProgressDeadline == zeroDuration { - obj.ImagePullProgressDeadline = metav1.Duration{Duration: 1 * time.Minute} - } if obj.CPUCFSQuota == nil { obj.CPUCFSQuota = boolVar(true) } - if obj.DockerExecHandlerName == "" { - obj.DockerExecHandlerName = "native" - } - if obj.DockerEndpoint == "" && runtime.GOOS != "windows" { - obj.DockerEndpoint = "unix:///var/run/docker.sock" - } if obj.EventBurst == 0 { obj.EventBurst = 10 } @@ -301,9 +282,6 @@ func SetDefaults_KubeletConfiguration(obj *KubeletConfiguration) { temp := int32(80) obj.ImageGCLowThresholdPercent = &temp } - if obj.LowDiskSpaceThresholdMB == 0 { - obj.LowDiskSpaceThresholdMB = 256 - } if obj.MasterServiceNamespace == "" { obj.MasterServiceNamespace = metav1.NamespaceDefault } @@ -336,9 +314,6 @@ func SetDefaults_KubeletConfiguration(obj *KubeletConfiguration) { temp := int32(qos.KubeletOOMScoreAdj) obj.OOMScoreAdj = &temp } - if obj.PodInfraContainerImage == "" { - obj.PodInfraContainerImage = defaultPodInfraContainerImage - } if obj.Port == 0 { obj.Port = ports.KubeletPort } @@ -361,9 +336,6 @@ func SetDefaults_KubeletConfiguration(obj *KubeletConfiguration) { if obj.ResolverConfig == "" { obj.ResolverConfig = kubetypes.ResolvConfDefault } - if obj.RktAPIEndpoint == "" { - obj.RktAPIEndpoint = defaultRktAPIServiceEndpoint - } if obj.RootDirectory == "" { obj.RootDirectory = defaultRootDir } @@ -396,7 +368,7 @@ func SetDefaults_KubeletConfiguration(obj *KubeletConfiguration) { obj.HairpinMode = PromiscuousBridge } if obj.EvictionHard == nil { - temp := "memory.available<100Mi" + temp := "memory.available<100Mi,nodefs.available<10%,nodefs.inodesFree<5%" obj.EvictionHard = &temp } if obj.EvictionPressureTransitionPeriod == zeroDuration { @@ -435,8 +407,12 @@ func SetDefaults_KubeletConfiguration(obj *KubeletConfiguration) { if obj.EnforceNodeAllocatable == nil { obj.EnforceNodeAllocatable = defaultNodeAllocatableEnforcement } - if obj.ExperimentalDockershim == nil { - obj.ExperimentalDockershim = boolVar(false) + if obj.RemoteRuntimeEndpoint == "" { + if runtime.GOOS == "linux" { + obj.RemoteRuntimeEndpoint = "unix:///var/run/dockershim.sock" + } else if runtime.GOOS == "windows" { + obj.RemoteRuntimeEndpoint = "tcp://localhost:3735" + } } } diff --git a/pkg/apis/componentconfig/v1alpha1/types.go b/pkg/apis/componentconfig/v1alpha1/types.go index e7b9a47455185..2b010a2932bc0 100644 --- a/pkg/apis/componentconfig/v1alpha1/types.go +++ b/pkg/apis/componentconfig/v1alpha1/types.go @@ -293,11 +293,6 @@ type KubeletConfiguration struct { Authentication KubeletAuthentication `json:"authentication"` // authorization specifies how requests to the Kubelet's server are authorized Authorization KubeletAuthorization `json:"authorization"` - // podInfraContainerImage is the image whose network/ipc namespaces - // containers in each pod will use. - PodInfraContainerImage string `json:"podInfraContainerImage"` - // dockerEndpoint is the path to the docker endpoint to communicate with. - DockerEndpoint string `json:"dockerEndpoint"` // rootDirectory is the directory path to place kubelet files (volume // mounts,etc). RootDirectory string `json:"rootDirectory"` @@ -391,22 +386,6 @@ type KubeletConfiguration struct { LowDiskSpaceThresholdMB int32 `json:"lowDiskSpaceThresholdMB"` // How frequently to calculate and cache volume disk usage for all pods VolumeStatsAggPeriod metav1.Duration `json:"volumeStatsAggPeriod"` - // networkPluginName is the name of the network plugin to be invoked for - // various events in kubelet/pod lifecycle - NetworkPluginName string `json:"networkPluginName"` - // networkPluginDir is the full path of the directory in which to search - // for network plugins (and, for backwards-compat, CNI config files) - NetworkPluginDir string `json:"networkPluginDir"` - // CNIConfDir is the full path of the directory in which to search for - // CNI config files - CNIConfDir string `json:"cniConfDir"` - // CNIBinDir is the full path of the directory in which to search for - // CNI plugin binaries - CNIBinDir string `json:"cniBinDir"` - // networkPluginMTU is the MTU to be passed to the network plugin, - // and overrides the default MTU for cases where it cannot be automatically - // computed (such as IPSEC). - NetworkPluginMTU int32 `json:"networkPluginMTU"` // volumePluginDir is the full path of the directory in which to search // for additional third party volume plugins VolumePluginDir string `json:"volumePluginDir"` @@ -442,20 +421,9 @@ type KubeletConfiguration struct { // runtimeRequestTimeout is the timeout for all runtime requests except long running // requests - pull, logs, exec and attach. RuntimeRequestTimeout metav1.Duration `json:"runtimeRequestTimeout"` - // If no pulling progress is made before the deadline imagePullProgressDeadline, - // the image pulling will be cancelled. Defaults to 1m0s. - ImagePullProgressDeadline metav1.Duration `json:"imagePullProgressDeadline,omitempty"` - // rktPath is the path of rkt binary. Leave empty to use the first rkt in - // $PATH. - RktPath string `json:"rktPath"` // experimentalMounterPath is the path to mounter binary. If not set, kubelet will attempt to use mount // binary that is available via $PATH, ExperimentalMounterPath string `json:"experimentalMounterPath,omitempty"` - // rktApiEndpoint is the endpoint of the rkt API service to communicate with. - RktAPIEndpoint string `json:"rktAPIEndpoint"` - // rktStage1Image is the image to use as stage1. Local paths and - // http/https URLs are supported. - RktStage1Image string `json:"rktStage1Image"` // lockFilePath is the path that kubelet will use to as a lock file. // It uses this file as a lock to synchronize with other kubelet processes // that may be running. @@ -476,10 +444,6 @@ type KubeletConfiguration struct { HairpinMode string `json:"hairpinMode"` // maxPods is the number of pods that can run on this Kubelet. MaxPods int32 `json:"maxPods"` - // dockerExecHandlerName is the handler to use when executing a command - // in a container. Valid values are 'native' and 'nsenter'. Defaults to - // 'native'. - DockerExecHandlerName string `json:"dockerExecHandlerName"` // The CIDR to use for pod IP addresses, only used in standalone mode. // In cluster mode, this is obtained from the master. PodCIDR string `json:"podCIDR"` @@ -567,9 +531,6 @@ type KubeletConfiguration struct { // featureGates is a string of comma-separated key=value pairs that describe feature // gates for alpha/experimental features. FeatureGates string `json:"featureGates,omitempty"` - // Enable dockershim only mode. - // +optional - ExperimentalDockershim *bool `json:"experimentalDockershim,omitempty"` // TODO(#34726:1.8.0): Remove the opt-in for failing when swap is enabled. // Tells the Kubelet to fail to start if swap is enabled on the node. ExperimentalFailSwapOn bool `json:"experimentalFailSwapOn,omitempty"` @@ -580,8 +541,6 @@ type KubeletConfiguration struct { // This flag, if set, instructs the kubelet to keep volumes from terminated pods mounted to the node. // This can be useful for debugging volume related issues. KeepTerminatedPodVolumes bool `json:"keepTerminatedPodVolumes,omitempty"` - // This flag, if set, disables use of a shared PID namespace for pods run by the docker CRI runtime. - DockerDisableSharedPID *bool `json:"dockerDisableSharedPID,omitempty"` /* following flags are meant for Node Allocatable */ diff --git a/pkg/apis/componentconfig/v1alpha1/zz_generated.conversion.go b/pkg/apis/componentconfig/v1alpha1/zz_generated.conversion.go index 43f4d4d7eb93a..112a8ae332084 100644 --- a/pkg/apis/componentconfig/v1alpha1/zz_generated.conversion.go +++ b/pkg/apis/componentconfig/v1alpha1/zz_generated.conversion.go @@ -381,8 +381,6 @@ func autoConvert_v1alpha1_KubeletConfiguration_To_componentconfig_KubeletConfigu if err := Convert_v1alpha1_KubeletAuthorization_To_componentconfig_KubeletAuthorization(&in.Authorization, &out.Authorization, s); err != nil { return err } - out.PodInfraContainerImage = in.PodInfraContainerImage - out.DockerEndpoint = in.DockerEndpoint out.RootDirectory = in.RootDirectory out.SeccompProfileRoot = in.SeccompProfileRoot if err := v1.Convert_Pointer_bool_To_bool(&in.AllowPrivileged, &out.AllowPrivileged, s); err != nil { @@ -431,11 +429,6 @@ func autoConvert_v1alpha1_KubeletConfiguration_To_componentconfig_KubeletConfigu } out.LowDiskSpaceThresholdMB = in.LowDiskSpaceThresholdMB out.VolumeStatsAggPeriod = in.VolumeStatsAggPeriod - out.NetworkPluginName = in.NetworkPluginName - out.NetworkPluginDir = in.NetworkPluginDir - out.CNIConfDir = in.CNIConfDir - out.CNIBinDir = in.CNIBinDir - out.NetworkPluginMTU = in.NetworkPluginMTU out.VolumePluginDir = in.VolumePluginDir out.CloudProvider = in.CloudProvider out.CloudConfigFile = in.CloudConfigFile @@ -451,18 +444,13 @@ func autoConvert_v1alpha1_KubeletConfiguration_To_componentconfig_KubeletConfigu out.RemoteRuntimeEndpoint = in.RemoteRuntimeEndpoint out.RemoteImageEndpoint = in.RemoteImageEndpoint out.RuntimeRequestTimeout = in.RuntimeRequestTimeout - out.ImagePullProgressDeadline = in.ImagePullProgressDeadline - out.RktPath = in.RktPath out.ExperimentalMounterPath = in.ExperimentalMounterPath - out.RktAPIEndpoint = in.RktAPIEndpoint - out.RktStage1Image = in.RktStage1Image if err := v1.Convert_Pointer_string_To_string(&in.LockFilePath, &out.LockFilePath, s); err != nil { return err } out.ExitOnLockContention = in.ExitOnLockContention out.HairpinMode = in.HairpinMode out.MaxPods = in.MaxPods - out.DockerExecHandlerName = in.DockerExecHandlerName out.PodCIDR = in.PodCIDR out.ResolverConfig = in.ResolverConfig if err := v1.Convert_Pointer_bool_To_bool(&in.CPUCFSQuota, &out.CPUCFSQuota, s); err != nil { @@ -516,15 +504,9 @@ func autoConvert_v1alpha1_KubeletConfiguration_To_componentconfig_KubeletConfigu } out.AllowedUnsafeSysctls = *(*[]string)(unsafe.Pointer(&in.AllowedUnsafeSysctls)) out.FeatureGates = in.FeatureGates - if err := v1.Convert_Pointer_bool_To_bool(&in.ExperimentalDockershim, &out.ExperimentalDockershim, s); err != nil { - return err - } out.ExperimentalFailSwapOn = in.ExperimentalFailSwapOn out.ExperimentalCheckNodeCapabilitiesBeforeMount = in.ExperimentalCheckNodeCapabilitiesBeforeMount out.KeepTerminatedPodVolumes = in.KeepTerminatedPodVolumes - if err := v1.Convert_Pointer_bool_To_bool(&in.DockerDisableSharedPID, &out.DockerDisableSharedPID, s); err != nil { - return err - } out.SystemReserved = *(*componentconfig.ConfigurationMap)(unsafe.Pointer(&in.SystemReserved)) out.KubeReserved = *(*componentconfig.ConfigurationMap)(unsafe.Pointer(&in.KubeReserved)) out.SystemReservedCgroup = in.SystemReservedCgroup @@ -561,8 +543,6 @@ func autoConvert_componentconfig_KubeletConfiguration_To_v1alpha1_KubeletConfigu if err := Convert_componentconfig_KubeletAuthorization_To_v1alpha1_KubeletAuthorization(&in.Authorization, &out.Authorization, s); err != nil { return err } - out.PodInfraContainerImage = in.PodInfraContainerImage - out.DockerEndpoint = in.DockerEndpoint out.RootDirectory = in.RootDirectory out.SeccompProfileRoot = in.SeccompProfileRoot if err := v1.Convert_bool_To_Pointer_bool(&in.AllowPrivileged, &out.AllowPrivileged, s); err != nil { @@ -627,11 +607,6 @@ func autoConvert_componentconfig_KubeletConfiguration_To_v1alpha1_KubeletConfigu } out.LowDiskSpaceThresholdMB = in.LowDiskSpaceThresholdMB out.VolumeStatsAggPeriod = in.VolumeStatsAggPeriod - out.NetworkPluginName = in.NetworkPluginName - out.NetworkPluginMTU = in.NetworkPluginMTU - out.NetworkPluginDir = in.NetworkPluginDir - out.CNIConfDir = in.CNIConfDir - out.CNIBinDir = in.CNIBinDir out.VolumePluginDir = in.VolumePluginDir out.CloudProvider = in.CloudProvider out.CloudConfigFile = in.CloudConfigFile @@ -647,18 +622,13 @@ func autoConvert_componentconfig_KubeletConfiguration_To_v1alpha1_KubeletConfigu out.RemoteRuntimeEndpoint = in.RemoteRuntimeEndpoint out.RemoteImageEndpoint = in.RemoteImageEndpoint out.RuntimeRequestTimeout = in.RuntimeRequestTimeout - out.ImagePullProgressDeadline = in.ImagePullProgressDeadline - out.RktPath = in.RktPath out.ExperimentalMounterPath = in.ExperimentalMounterPath - out.RktAPIEndpoint = in.RktAPIEndpoint - out.RktStage1Image = in.RktStage1Image if err := v1.Convert_string_To_Pointer_string(&in.LockFilePath, &out.LockFilePath, s); err != nil { return err } out.ExitOnLockContention = in.ExitOnLockContention out.HairpinMode = in.HairpinMode out.MaxPods = in.MaxPods - out.DockerExecHandlerName = in.DockerExecHandlerName out.PodCIDR = in.PodCIDR out.ResolverConfig = in.ResolverConfig if err := v1.Convert_bool_To_Pointer_bool(&in.CPUCFSQuota, &out.CPUCFSQuota, s); err != nil { @@ -716,15 +686,9 @@ func autoConvert_componentconfig_KubeletConfiguration_To_v1alpha1_KubeletConfigu } out.AllowedUnsafeSysctls = *(*[]string)(unsafe.Pointer(&in.AllowedUnsafeSysctls)) out.FeatureGates = in.FeatureGates - if err := v1.Convert_bool_To_Pointer_bool(&in.ExperimentalDockershim, &out.ExperimentalDockershim, s); err != nil { - return err - } out.ExperimentalFailSwapOn = in.ExperimentalFailSwapOn out.ExperimentalCheckNodeCapabilitiesBeforeMount = in.ExperimentalCheckNodeCapabilitiesBeforeMount out.KeepTerminatedPodVolumes = in.KeepTerminatedPodVolumes - if err := v1.Convert_bool_To_Pointer_bool(&in.DockerDisableSharedPID, &out.DockerDisableSharedPID, s); err != nil { - return err - } out.SystemReserved = *(*map[string]string)(unsafe.Pointer(&in.SystemReserved)) out.KubeReserved = *(*map[string]string)(unsafe.Pointer(&in.KubeReserved)) out.SystemReservedCgroup = in.SystemReservedCgroup diff --git a/pkg/apis/componentconfig/v1alpha1/zz_generated.deepcopy.go b/pkg/apis/componentconfig/v1alpha1/zz_generated.deepcopy.go index 39e30e8a9428d..f12675b9ede27 100644 --- a/pkg/apis/componentconfig/v1alpha1/zz_generated.deepcopy.go +++ b/pkg/apis/componentconfig/v1alpha1/zz_generated.deepcopy.go @@ -335,16 +335,6 @@ func DeepCopy_v1alpha1_KubeletConfiguration(in interface{}, out interface{}, c * *out = make([]string, len(*in)) copy(*out, *in) } - if in.ExperimentalDockershim != nil { - in, out := &in.ExperimentalDockershim, &out.ExperimentalDockershim - *out = new(bool) - **out = **in - } - if in.DockerDisableSharedPID != nil { - in, out := &in.DockerDisableSharedPID, &out.DockerDisableSharedPID - *out = new(bool) - **out = **in - } if in.SystemReserved != nil { in, out := &in.SystemReserved, &out.SystemReserved *out = make(map[string]string) diff --git a/pkg/apis/extensions/types.go b/pkg/apis/extensions/types.go index 7c2c1c2856e21..40442bce9d63b 100644 --- a/pkg/apis/extensions/types.go +++ b/pkg/apis/extensions/types.go @@ -235,7 +235,7 @@ type DeploymentRollback struct { } type RollbackConfig struct { - // The revision to rollback to. If set to 0, rollbck to the last revision. + // The revision to rollback to. If set to 0, rollback to the last revision. // +optional Revision int64 } @@ -884,6 +884,10 @@ type PodSecurityPolicySpec struct { // will not be forced to. // +optional ReadOnlyRootFilesystem bool + // AllowedHostPaths is a white list of allowed host path prefixes. Empty indicates that all + // host paths may be used. + // +optional + AllowedHostPaths []string } // HostPortRange defines a range of host ports that will be enabled by a policy @@ -1042,6 +1046,7 @@ type PodSecurityPolicyList struct { // +genclient=true +// NetworkPolicy describes what network traffic is allowed for a set of Pods type NetworkPolicy struct { metav1.TypeMeta // +optional @@ -1061,13 +1066,12 @@ type NetworkPolicySpec struct { PodSelector metav1.LabelSelector // List of ingress rules to be applied to the selected pods. - // Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, + // Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod // OR if the traffic source is the pod's local node, // OR if the traffic matches at least one ingress rule across all of the NetworkPolicy // objects whose podSelector matches the pod. - // If this field is empty then this NetworkPolicy does not affect ingress isolation. - // If this field is present and contains at least one rule, this policy allows any traffic - // which matches at least one of the ingress rules in this list. + // If this field is empty then this NetworkPolicy does not allow any traffic + // (and serves solely to ensure that the pods it selects are isolated by default). // +optional Ingress []NetworkPolicyIngressRule } diff --git a/pkg/apis/extensions/v1beta1/BUILD b/pkg/apis/extensions/v1beta1/BUILD index bb3ae502b6cd9..1ff08fdf50ad5 100644 --- a/pkg/apis/extensions/v1beta1/BUILD +++ b/pkg/apis/extensions/v1beta1/BUILD @@ -28,6 +28,7 @@ go_library( "//pkg/api:go_default_library", "//pkg/api/v1:go_default_library", "//pkg/apis/extensions:go_default_library", + "//pkg/apis/networking:go_default_library", "//vendor/github.com/gogo/protobuf/proto:go_default_library", "//vendor/github.com/gogo/protobuf/sortkeys:go_default_library", "//vendor/github.com/ugorji/go/codec:go_default_library", diff --git a/pkg/apis/extensions/v1beta1/conversion.go b/pkg/apis/extensions/v1beta1/conversion.go index 38b8c2ac8f867..afbe42f67b0e4 100644 --- a/pkg/apis/extensions/v1beta1/conversion.go +++ b/pkg/apis/extensions/v1beta1/conversion.go @@ -23,8 +23,10 @@ import ( "k8s.io/apimachinery/pkg/conversion" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/util/intstr" + "k8s.io/kubernetes/pkg/api" v1 "k8s.io/kubernetes/pkg/api/v1" "k8s.io/kubernetes/pkg/apis/extensions" + "k8s.io/kubernetes/pkg/apis/networking" ) func addConversionFuncs(scheme *runtime.Scheme) error { @@ -42,6 +44,18 @@ func addConversionFuncs(scheme *runtime.Scheme) error { Convert_v1beta1_RollingUpdateDaemonSet_To_extensions_RollingUpdateDaemonSet, Convert_extensions_ReplicaSetSpec_To_v1beta1_ReplicaSetSpec, Convert_v1beta1_ReplicaSetSpec_To_extensions_ReplicaSetSpec, + Convert_v1beta1_NetworkPolicy_To_networking_NetworkPolicy, + Convert_networking_NetworkPolicy_To_v1beta1_NetworkPolicy, + Convert_v1beta1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule, + Convert_networking_NetworkPolicyIngressRule_To_v1beta1_NetworkPolicyIngressRule, + Convert_v1beta1_NetworkPolicyList_To_networking_NetworkPolicyList, + Convert_networking_NetworkPolicyList_To_v1beta1_NetworkPolicyList, + Convert_v1beta1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer, + Convert_networking_NetworkPolicyPeer_To_v1beta1_NetworkPolicyPeer, + Convert_v1beta1_NetworkPolicyPort_To_networking_NetworkPolicyPort, + Convert_networking_NetworkPolicyPort_To_v1beta1_NetworkPolicyPort, + Convert_v1beta1_NetworkPolicySpec_To_networking_NetworkPolicySpec, + Convert_networking_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec, ) if err != nil { return err @@ -260,3 +274,155 @@ func Convert_v1beta1_ReplicaSetSpec_To_extensions_ReplicaSetSpec(in *ReplicaSetS } return nil } + +func Convert_v1beta1_NetworkPolicy_To_networking_NetworkPolicy(in *NetworkPolicy, out *networking.NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + return Convert_v1beta1_NetworkPolicySpec_To_networking_NetworkPolicySpec(&in.Spec, &out.Spec, s) +} + +func Convert_networking_NetworkPolicy_To_v1beta1_NetworkPolicy(in *networking.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + return Convert_networking_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec(&in.Spec, &out.Spec, s) +} + +func Convert_v1beta1_NetworkPolicySpec_To_networking_NetworkPolicySpec(in *NetworkPolicySpec, out *networking.NetworkPolicySpec, s conversion.Scope) error { + if err := s.Convert(&in.PodSelector, &out.PodSelector, 0); err != nil { + return err + } + out.Ingress = make([]networking.NetworkPolicyIngressRule, len(in.Ingress)) + for i := range in.Ingress { + if err := Convert_v1beta1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(&in.Ingress[i], &out.Ingress[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_networking_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec(in *networking.NetworkPolicySpec, out *NetworkPolicySpec, s conversion.Scope) error { + if err := s.Convert(&in.PodSelector, &out.PodSelector, 0); err != nil { + return err + } + out.Ingress = make([]NetworkPolicyIngressRule, len(in.Ingress)) + for i := range in.Ingress { + if err := Convert_networking_NetworkPolicyIngressRule_To_v1beta1_NetworkPolicyIngressRule(&in.Ingress[i], &out.Ingress[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_v1beta1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(in *NetworkPolicyIngressRule, out *networking.NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = make([]networking.NetworkPolicyPort, len(in.Ports)) + for i := range in.Ports { + if err := Convert_v1beta1_NetworkPolicyPort_To_networking_NetworkPolicyPort(&in.Ports[i], &out.Ports[i], s); err != nil { + return err + } + } + out.From = make([]networking.NetworkPolicyPeer, len(in.From)) + for i := range in.From { + if err := Convert_v1beta1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(&in.From[i], &out.From[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_networking_NetworkPolicyIngressRule_To_v1beta1_NetworkPolicyIngressRule(in *networking.NetworkPolicyIngressRule, out *NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = make([]NetworkPolicyPort, len(in.Ports)) + for i := range in.Ports { + if err := Convert_networking_NetworkPolicyPort_To_v1beta1_NetworkPolicyPort(&in.Ports[i], &out.Ports[i], s); err != nil { + return err + } + } + out.From = make([]NetworkPolicyPeer, len(in.From)) + for i := range in.From { + if err := Convert_networking_NetworkPolicyPeer_To_v1beta1_NetworkPolicyPeer(&in.From[i], &out.From[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_v1beta1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(in *NetworkPolicyPeer, out *networking.NetworkPolicyPeer, s conversion.Scope) error { + if in.PodSelector != nil { + out.PodSelector = new(metav1.LabelSelector) + if err := s.Convert(in.PodSelector, out.PodSelector, 0); err != nil { + return err + } + } else { + out.PodSelector = nil + } + if in.NamespaceSelector != nil { + out.NamespaceSelector = new(metav1.LabelSelector) + if err := s.Convert(in.NamespaceSelector, out.NamespaceSelector, 0); err != nil { + return err + } + } else { + out.NamespaceSelector = nil + } + return nil +} + +func Convert_networking_NetworkPolicyPeer_To_v1beta1_NetworkPolicyPeer(in *networking.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { + if in.PodSelector != nil { + out.PodSelector = new(metav1.LabelSelector) + if err := s.Convert(in.PodSelector, out.PodSelector, 0); err != nil { + return err + } + } else { + out.PodSelector = nil + } + if in.NamespaceSelector != nil { + out.NamespaceSelector = new(metav1.LabelSelector) + if err := s.Convert(in.NamespaceSelector, out.NamespaceSelector, 0); err != nil { + return err + } + } else { + out.NamespaceSelector = nil + } + return nil +} + +func Convert_v1beta1_NetworkPolicyPort_To_networking_NetworkPolicyPort(in *NetworkPolicyPort, out *networking.NetworkPolicyPort, s conversion.Scope) error { + if in.Protocol != nil { + out.Protocol = new(api.Protocol) + *out.Protocol = api.Protocol(*in.Protocol) + } else { + out.Protocol = nil + } + out.Port = in.Port + return nil +} + +func Convert_networking_NetworkPolicyPort_To_v1beta1_NetworkPolicyPort(in *networking.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { + if in.Protocol != nil { + out.Protocol = new(v1.Protocol) + *out.Protocol = v1.Protocol(*in.Protocol) + } else { + out.Protocol = nil + } + out.Port = in.Port + return nil +} + +func Convert_v1beta1_NetworkPolicyList_To_networking_NetworkPolicyList(in *NetworkPolicyList, out *networking.NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = make([]networking.NetworkPolicy, len(in.Items)) + for i := range in.Items { + if err := Convert_v1beta1_NetworkPolicy_To_networking_NetworkPolicy(&in.Items[i], &out.Items[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_networking_NetworkPolicyList_To_v1beta1_NetworkPolicyList(in *networking.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = make([]NetworkPolicy, len(in.Items)) + for i := range in.Items { + if err := Convert_networking_NetworkPolicy_To_v1beta1_NetworkPolicy(&in.Items[i], &out.Items[i], s); err != nil { + return err + } + } + return nil +} diff --git a/pkg/apis/extensions/v1beta1/doc.go b/pkg/apis/extensions/v1beta1/doc.go index f4e544e67d481..0b074d0469300 100644 --- a/pkg/apis/extensions/v1beta1/doc.go +++ b/pkg/apis/extensions/v1beta1/doc.go @@ -18,6 +18,7 @@ limitations under the License. // +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/extensions // +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/autoscaling // +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/batch +// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/networking // +k8s:openapi-gen=true // +k8s:defaulter-gen=TypeMeta diff --git a/pkg/apis/extensions/v1beta1/generated.pb.go b/pkg/apis/extensions/v1beta1/generated.pb.go index a9cd040c461e3..f2397c0bc0d3f 100644 --- a/pkg/apis/extensions/v1beta1/generated.pb.go +++ b/pkg/apis/extensions/v1beta1/generated.pb.go @@ -93,7 +93,6 @@ import math "math" import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" import k8s_io_apimachinery_pkg_util_intstr "k8s.io/apimachinery/pkg/util/intstr" - import k8s_io_kubernetes_pkg_api_v1 "k8s.io/kubernetes/pkg/api/v1" import strings "strings" @@ -1989,6 +1988,21 @@ func (m *PodSecurityPolicySpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0 } i++ + if len(m.AllowedHostPaths) > 0 { + for _, s := range m.AllowedHostPaths { + dAtA[i] = 0x7a + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } return i, nil } @@ -3240,6 +3254,12 @@ func (m *PodSecurityPolicySpec) Size() (n int) { l = m.FSGroup.Size() n += 1 + l + sovGenerated(uint64(l)) n += 2 + if len(m.AllowedHostPaths) > 0 { + for _, s := range m.AllowedHostPaths { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } return n } @@ -3972,6 +3992,7 @@ func (this *PodSecurityPolicySpec) String() string { `SupplementalGroups:` + strings.Replace(strings.Replace(this.SupplementalGroups.String(), "SupplementalGroupsStrategyOptions", "SupplementalGroupsStrategyOptions", 1), `&`, ``, 1) + `,`, `FSGroup:` + strings.Replace(strings.Replace(this.FSGroup.String(), "FSGroupStrategyOptions", "FSGroupStrategyOptions", 1), `&`, ``, 1) + `,`, `ReadOnlyRootFilesystem:` + fmt.Sprintf("%v", this.ReadOnlyRootFilesystem) + `,`, + `AllowedHostPaths:` + fmt.Sprintf("%v", this.AllowedHostPaths) + `,`, `}`, }, "") return s @@ -9371,6 +9392,35 @@ func (m *PodSecurityPolicySpec) Unmarshal(dAtA []byte) error { } } m.ReadOnlyRootFilesystem = bool(v != 0) + case 15: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field AllowedHostPaths", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.AllowedHostPaths = append(m.AllowedHostPaths, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -11823,218 +11873,219 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 3402 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x5b, 0x4b, 0x6f, 0x1c, 0xc7, - 0xb5, 0x56, 0xcf, 0x43, 0x1c, 0x1e, 0x8a, 0xa4, 0x58, 0x94, 0xa9, 0x31, 0x6d, 0x93, 0x72, 0x5f, - 0x5c, 0x5b, 0xbe, 0xd7, 0x1e, 0x5e, 0xcb, 0x57, 0x8e, 0x2d, 0xdb, 0xb2, 0x39, 0xa4, 0x1e, 0x0c, - 0x48, 0x6a, 0x5c, 0x33, 0x14, 0x62, 0xf9, 0x95, 0xe6, 0x4c, 0x71, 0xd8, 0x52, 0xbf, 0xdc, 0x5d, - 0x4d, 0x73, 0x60, 0x24, 0x31, 0x10, 0xc4, 0xcb, 0x20, 0xd9, 0x04, 0x0e, 0x90, 0x2c, 0xb3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x05, 0xaa, 0xfc, 0x53, 0x09, 0x26, 0x2f, 0xb7, 0x5a, - 0x8d, 0x15, 0x83, 0x67, 0x80, 0x86, 0x42, 0xb7, 0x59, 0x8d, 0x61, 0x29, 0x74, 0x3b, 0x59, 0x63, - 0xb0, 0x39, 0xcc, 0x67, 0xd0, 0x36, 0x8c, 0xb0, 0xcc, 0x43, 0x8c, 0xce, 0x80, 0xd7, 0x03, 0x21, - 0xae, 0xee, 0x81, 0x84, 0xb5, 0xab, 0x18, 0xc0, 0x3e, 0xbc, 0xfc, 0x1e, 0x9c, 0x88, 0xa8, 0xc7, - 0xfc, 0xc5, 0x5f, 0x36, 0x51, 0x1b, 0xca, 0x4c, 0x13, 0xff, 0xdd, 0xb2, 0xdf, 0xe7, 0xb7, 0x84, - 0xc9, 0x61, 0x0d, 0xc6, 0x7e, 0x39, 0xd8, 0xc3, 0x96, 0xd7, 0x60, 0xfc, 0xb2, 0xe9, 0xd0, 0x86, - 0x69, 0x53, 0xee, 0x36, 0xf4, 0x08, 0x14, 0x75, 0xd5, 0x10, 0x27, 0xfc, 0x98, 0xe0, 0x29, 0xb2, - 0x33, 0x88, 0x8d, 0xf3, 0x69, 0x65, 0x57, 0x64, 0xb2, 0x70, 0x5a, 0xd9, 0xc5, 0x6c, 0x5c, 0xbe, - 0x04, 0x23, 0x62, 0x39, 0xa2, 0x40, 0xc5, 0x83, 0x81, 0x8a, 0x19, 0x40, 0xbf, 0x2c, 0xc0, 0x88, - 0xd0, 0x7e, 0x08, 0x17, 0xc1, 0x37, 0x62, 0x17, 0xc1, 0x73, 0x83, 0xad, 0x74, 0xee, 0x2d, 0xb0, - 0x93, 0xb8, 0x05, 0xbe, 0x38, 0x20, 0xfe, 0xc1, 0x57, 0xc0, 0x8f, 0x24, 0x98, 0x88, 0xc7, 0x1c, - 0x3a, 0x0b, 0x63, 0xec, 0x3c, 0x52, 0xdb, 0x64, 0x3d, 0x2c, 0xa8, 0x83, 0x47, 0x99, 0x66, 0x38, - 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0x6f, 0xcd, 0x1d, 0xf9, 0xec, - 0xd6, 0xdc, 0x91, 0xf7, 0xf7, 0xe7, 0xa4, 0x9b, 0xfb, 0x73, 0xd2, 0xa7, 0xfb, 0x73, 0xd2, 0xdf, - 0xf6, 0xe7, 0xa4, 0x1f, 0x7c, 0x31, 0x77, 0xe4, 0xda, 0x88, 0xc0, 0xfc, 0x57, 0x00, 0x00, 0x00, - 0xff, 0xff, 0x5a, 0xe3, 0x5a, 0x1b, 0x28, 0x3d, 0x00, 0x00, + // 3412 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x5b, 0xdd, 0x6f, 0x1c, 0x57, + 0x15, 0xcf, 0x78, 0xbd, 0xf1, 0xfa, 0x6c, 0x6c, 0xc7, 0xd7, 0xae, 0xb3, 0x75, 0x5b, 0x3b, 0x1d, + 0x44, 0x9b, 0x42, 0xbb, 0xa6, 0x29, 0x29, 0x6d, 0xda, 0xa6, 0xf5, 0xda, 0xf9, 0x30, 0xb2, 0x9d, + 0xed, 0xdd, 0x75, 0x44, 0xd3, 0x2f, 0xc6, 0xbb, 0xd7, 0xeb, 0x49, 0xe6, 0xab, 0x33, 0x77, 0x5c, + 0xaf, 0x2a, 0xa0, 0x12, 0xa2, 0x0f, 0x3c, 0x20, 0x78, 0x41, 0x45, 0x82, 0x47, 0x1e, 0x78, 0x81, + 0xf6, 0x01, 0x0a, 0x7f, 0x01, 0x79, 0x40, 0xa8, 0x48, 0x20, 0x55, 0xa8, 0x58, 0xc4, 0x15, 0xfd, + 0x07, 0xa0, 0x2f, 0x79, 0x42, 0xf7, 0xce, 0x9d, 0xef, 0x19, 0x27, 0xbb, 0x4e, 0x56, 0x48, 0xbc, + 0xed, 0xdc, 0x7b, 0xce, 0xef, 0x7c, 0xdc, 0x73, 0xcf, 0x3d, 0xf7, 0x63, 0xe1, 0x85, 0xeb, 0xcf, + 0x38, 0x55, 0xd5,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x9d, 0xc4, 0x12, 0xfa, 0x62, 0xff, 0x22, 0x0e, 0x5e, 0x43, 0x6f, 0x16, 0x60, + 0x2a, 0x24, 0x5e, 0x32, 0x8d, 0xb6, 0xca, 0xe7, 0xc4, 0x73, 0xb1, 0x98, 0x78, 0x34, 0x11, 0x13, + 0x27, 0x32, 0x58, 0x22, 0xf1, 0x70, 0x25, 0xd0, 0x7e, 0x88, 0xb3, 0x9f, 0x8b, 0x0b, 0xbf, 0xb5, + 0x37, 0x7f, 0x60, 0x3d, 0x5f, 0x0d, 0x30, 0xe3, 0xca, 0xa2, 0x47, 0xe0, 0xa8, 0x4d, 0x14, 0xc7, + 0x34, 0x78, 0x9a, 0x18, 0x0d, 0x8d, 0xc2, 0xbc, 0x15, 0x8b, 0x5e, 0xf4, 0x18, 0x8c, 0xe8, 0xc4, + 0x71, 0x94, 0x0e, 0xe1, 0x19, 0x61, 0xb4, 0x36, 0x21, 0x08, 0x47, 0xd6, 0xbc, 0x66, 0xec, 0xf7, + 0xa3, 0x6b, 0x30, 0xae, 0x29, 0x8e, 0x08, 0xed, 0xa6, 0xaa, 0x13, 0x3e, 0xe7, 0xcb, 0xa7, 0xbf, + 0x72, 0x67, 0x11, 0xc3, 0x38, 0xc2, 0x95, 0x68, 0x35, 0x86, 0x84, 0x13, 0xc8, 0x68, 0x07, 0x10, + 0x6b, 0x69, 0xda, 0x8a, 0xe1, 0x78, 0x2e, 0x63, 0xf2, 0x46, 0x7a, 0x96, 0x17, 0xe4, 0xb7, 0xd5, + 0x14, 0x1a, 0xce, 0x90, 0x20, 0xff, 0x59, 0x82, 0xf1, 0x70, 0xc0, 0x06, 0x50, 0x28, 0xbd, 0x11, + 0x2f, 0x94, 0x9e, 0xed, 0x3b, 0x78, 0x73, 0x2a, 0xa5, 0xf7, 0x0b, 0x80, 0x42, 0x22, 0x96, 0x1a, + 0x36, 0x95, 0xd6, 0xf5, 0x3b, 0xd8, 0x47, 0xfc, 0x52, 0x02, 0x24, 0x92, 0xf5, 0xa2, 0x61, 0x98, + 0x94, 0xe7, 0x7f, 0x5f, 0xcd, 0x57, 0xfa, 0x56, 0xd3, 0xd7, 0xa0, 0xba, 0x91, 0xc2, 0x3e, 0x6f, + 0x50, 0xbb, 0x1b, 0x8e, 0x58, 0x9a, 0x00, 0x67, 0x28, 0x84, 0xde, 0x02, 0xb0, 0x05, 0x66, 0xd3, + 0x14, 0x29, 0xe0, 0x85, 0x3e, 0xb2, 0x29, 0x03, 0x58, 0x32, 0x8d, 0x2d, 0xb5, 0x13, 0x26, 0x34, + 0x1c, 0x00, 0xe3, 0x88, 0x90, 0xd9, 0xf3, 0x70, 0x22, 0x47, 0x7b, 0x74, 0x1c, 0x0a, 0xd7, 0x49, + 0xd7, 0x73, 0x2b, 0x66, 0x3f, 0xd1, 0x74, 0x74, 0x3f, 0x36, 0x2a, 0xb6, 0x52, 0x67, 0x87, 0x9e, + 0x91, 0xe4, 0xcf, 0x8b, 0xd1, 0x58, 0xe3, 0x55, 0xec, 0x29, 0x28, 0xd9, 0xc4, 0xd2, 0xd4, 0x96, + 0xe2, 0x88, 0x7a, 0x86, 0x17, 0xa4, 0x58, 0xb4, 0xe1, 0xa0, 0x37, 0x56, 0xef, 0x0e, 0xdd, 0xdb, + 0x7a, 0xb7, 0x70, 0xb7, 0xeb, 0x5d, 0x13, 0x4a, 0x8e, 0x5f, 0xe8, 0x0e, 0x73, 0xf0, 0xc5, 0x43, + 0xe4, 0x6c, 0x51, 0xe3, 0x06, 0x02, 0x83, 0xea, 0x36, 0x10, 0x92, 0x55, 0xd7, 0x16, 0x7b, 0xac, + 0x6b, 0x57, 0x61, 0xda, 0x26, 0x3b, 0x2a, 0x53, 0xe3, 0x92, 0xea, 0x50, 0xd3, 0xee, 0xae, 0xaa, + 0xba, 0x4a, 0x45, 0xd9, 0x53, 0xd9, 0xdf, 0x9b, 0x9f, 0xc6, 0x19, 0xfd, 0x38, 0x93, 0x8b, 0x65, + 0x67, 0x4b, 0x71, 0x1d, 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 0xd4, 0x58, 0x32, 0x5d, 0x83, 0xf2, 0x40, + 0x2f, 0xd4, 0x10, 0xab, 0x13, 0x96, 0x62, 0x3d, 0x38, 0x41, 0x29, 0xff, 0x45, 0x8a, 0x2e, 0x6f, + 0x41, 0x99, 0x7e, 0x36, 0x56, 0x92, 0x3d, 0x92, 0x28, 0xc9, 0x66, 0xd2, 0x1c, 0x91, 0x8a, 0xec, + 0x7b, 0xd9, 0x15, 0xfa, 0x85, 0x43, 0x55, 0xe8, 0xe1, 0x32, 0x7d, 0xfb, 0x12, 0xfd, 0x43, 0x09, + 0x66, 0x2e, 0x34, 0x2e, 0xda, 0xa6, 0x6b, 0xf9, 0xea, 0x5d, 0xb6, 0x3c, 0x3f, 0x7f, 0x03, 0x86, + 0x6d, 0x57, 0xf3, 0xed, 0xfa, 0x92, 0x6f, 0x17, 0x76, 0x35, 0x66, 0xd7, 0x54, 0x82, 0xcb, 0x33, + 0x8a, 0x31, 0xa0, 0x37, 0xe0, 0xa8, 0xad, 0x18, 0x1d, 0xe2, 0x2f, 0xe0, 0x4f, 0xf7, 0x68, 0xcd, + 0xca, 0x32, 0x66, 0xec, 0x91, 0x32, 0x92, 0xa3, 0x61, 0x81, 0x2a, 0xff, 0x42, 0x82, 0x89, 0x4b, + 0xcd, 0x66, 0x7d, 0xc5, 0xe0, 0x19, 0xa0, 0xae, 0xd0, 0x6d, 0x56, 0x63, 0x58, 0x0a, 0xdd, 0x4e, + 0xd6, 0x18, 0xac, 0x0f, 0xf3, 0x1e, 0xb4, 0x0d, 0x23, 0x2c, 0xf3, 0x10, 0xa3, 0xdd, 0xe7, 0xf6, + 0x40, 0x88, 0xab, 0x79, 0x20, 0x61, 0xed, 0x2a, 0x1a, 0xb0, 0x0f, 0x2f, 0xbf, 0x03, 0xd3, 0x11, + 0xf5, 0x98, 0xbf, 0xf8, 0xc9, 0x26, 0x6a, 0x41, 0x91, 0x69, 0xe2, 0x9f, 0x5b, 0xf6, 0x7a, 0xfc, + 0x96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dc, + 0x08, 0x7a, 0x70, 0x84, 0x4a, 0xfe, 0x9b, 0x04, 0x63, 0xeb, 0x84, 0xbe, 0x6d, 0xda, 0xd7, 0xeb, + 0xfc, 0x72, 0x77, 0x00, 0x79, 0x7f, 0x33, 0x96, 0xf7, 0x5f, 0xea, 0x71, 0xcc, 0x62, 0xda, 0xe6, + 0x65, 0x7f, 0xf9, 0x5f, 0x12, 0x54, 0x62, 0x94, 0xd1, 0x34, 0x41, 0xa0, 0x68, 0x99, 0x36, 0xf5, + 0xd7, 0xf8, 0x43, 0x69, 0xc0, 0x52, 0x6a, 0x64, 0x95, 0x67, 0xb0, 0xd8, 0x43, 0x67, 0x76, 0x6e, + 0xd9, 0xa6, 0x2e, 0xe2, 0xfe, 0x70, 0x52, 0x08, 0xb1, 0x43, 0x3b, 0x2f, 0xd8, 0xa6, 0x8e, 0x39, + 0xb6, 0xfc, 0x57, 0x09, 0x26, 0x63, 0x94, 0x03, 0x48, 0xe9, 0x4a, 0x3c, 0xa5, 0x3f, 0x7f, 0x18, + 0xc3, 0x72, 0x12, 0xfb, 0x17, 0x49, 0xb3, 0x98, 0x03, 0xd0, 0x16, 0x94, 0x2d, 0xb3, 0xdd, 0xb8, + 0x0b, 0xb7, 0x7a, 0x13, 0x6c, 0x85, 0xac, 0x87, 0x58, 0x38, 0x0a, 0x8c, 0x76, 0x61, 0xd2, 0x50, + 0x74, 0xe2, 0x58, 0x4a, 0x8b, 0x34, 0xee, 0xc2, 0x99, 0xca, 0x7d, 0xfc, 0xa6, 0x21, 0x89, 0x88, + 0xd3, 0x42, 0xe4, 0xdf, 0xa5, 0xec, 0x36, 0x6d, 0x8a, 0x5e, 0x86, 0x12, 0x7f, 0x60, 0xd1, 0x32, + 0x35, 0xb1, 0xb4, 0x9d, 0x61, 0x43, 0x53, 0x17, 0x6d, 0xb7, 0xf6, 0xe6, 0xbf, 0x7c, 0xe0, 0x91, + 0xb0, 0x4f, 0x88, 0x03, 0x18, 0xb4, 0x0e, 0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, 0x1a, 0x78, 0x30, 0xa0, 0xc0, 0xa1, 0x30, 0xf4, 0x73, 0x09, 0x90, 0xe3, + 0x5a, 0x96, 0x46, 0x74, 0x62, 0x50, 0x45, 0xe3, 0xa7, 0x61, 0x4e, 0xe5, 0x18, 0xd7, 0xa1, 0xde, + 0xab, 0xdd, 0x29, 0xa0, 0xa4, 0x32, 0xc1, 0x31, 0x75, 0x9a, 0x14, 0x67, 0xe8, 0xc1, 0x86, 0x62, + 0xcb, 0xe1, 0xbf, 0x2b, 0x63, 0x7d, 0x0d, 0x45, 0xf6, 0xa9, 0x60, 0x38, 0x14, 0xa2, 0x1f, 0xfb, + 0x62, 0xd0, 0x15, 0x98, 0xb1, 0x89, 0xd2, 0xbe, 0x6c, 0x68, 0x5d, 0x6c, 0x9a, 0xf4, 0x82, 0xaa, + 0x11, 0xa7, 0xeb, 0x50, 0xa2, 0x57, 0xc6, 0x79, 0xd8, 0x04, 0xcf, 0x35, 0x70, 0x26, 0x15, 0xce, + 0xe1, 0x46, 0x2f, 0xc1, 0x71, 0x31, 0x31, 0x79, 0x68, 0xf2, 0x13, 0xb4, 0x09, 0x3e, 0x15, 0xa7, + 0xd9, 0x8e, 0x78, 0x31, 0xd1, 0x87, 0x53, 0xd4, 0xfc, 0x1d, 0x82, 0x38, 0x01, 0x1e, 0xcc, 0x4b, + 0xbe, 0xc3, 0xbd, 0x43, 0x08, 0x55, 0xbd, 0x67, 0xef, 0x10, 0x22, 0x22, 0x0e, 0x3e, 0x84, 0xfa, + 0x62, 0x08, 0xa6, 0x42, 0xe2, 0x3b, 0x7e, 0x87, 0x90, 0xc1, 0x32, 0x80, 0x77, 0x08, 0xd9, 0x17, + 0xf9, 0x85, 0x7b, 0x7d, 0x91, 0x7f, 0x0f, 0xde, 0x3f, 0xf0, 0xb7, 0x01, 0xa1, 0x13, 0xff, 0xf7, + 0xdf, 0x06, 0x84, 0xba, 0xe6, 0x14, 0x44, 0x7f, 0x18, 0x8a, 0x1a, 0xf4,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 0xda, 0xed, 0xba, 0x62, 0xd3, 0x2e, 0x16, 0xff, 0xe2, + 0x1a, 0xc0, 0x84, 0x3b, 0x03, 0xe5, 0x36, 0x71, 0x5a, 0xb6, 0xca, 0x9d, 0x25, 0xf6, 0x0a, 0xc1, + 0x49, 0xca, 0x72, 0xd8, 0x85, 0xa3, 0x74, 0xa8, 0x03, 0xa5, 0x1d, 0xef, 0x7f, 0x82, 0xfe, 0xdd, + 0x5d, 0xaf, 0xc5, 0x6c, 0xf8, 0x4f, 0xc3, 0x30, 0xbe, 0x44, 0x83, 0x83, 0x03, 0x70, 0xf9, 0x7d, + 0x09, 0x66, 0xd2, 0x8e, 0x59, 0x66, 0xaa, 0xdf, 0x7b, 0xe7, 0x3c, 0x08, 0xc3, 0x1c, 0x9d, 0x79, + 0xe5, 0x98, 0x77, 0x66, 0xce, 0x24, 0x63, 0xde, 0x2a, 0x7f, 0x2e, 0xc1, 0x6c, 0xb6, 0x6a, 0x03, + 0xd8, 0x4a, 0x5c, 0x8b, 0x6f, 0x25, 0x7a, 0x3d, 0x78, 0xc8, 0xd6, 0x3b, 0x67, 0x5b, 0xb1, 0x97, + 0x39, 0x06, 0x03, 0x30, 0x72, 0x2b, 0x6e, 0xe4, 0xe2, 0xa1, 0x8d, 0xcc, 0x36, 0xb0, 0xf6, 0xd8, + 0x8d, 0x9b, 0x73, 0x47, 0x3e, 0xbe, 0x39, 0x77, 0xe4, 0x93, 0x9b, 0x73, 0x47, 0xde, 0xdd, 0x9f, + 0x93, 0x6e, 0xec, 0xcf, 0x49, 0x1f, 0xef, 0xcf, 0x49, 0xff, 0xdc, 0x9f, 0x93, 0x7e, 0xfc, 0xd9, + 0xdc, 0x91, 0xab, 0x23, 0x02, 0xf3, 0xbf, 0x01, 0x00, 0x00, 0xff, 0xff, 0x6d, 0x3f, 0x0c, 0xbe, + 0x34, 0x3d, 0x00, 0x00, } diff --git a/pkg/apis/extensions/v1beta1/generated.proto b/pkg/apis/extensions/v1beta1/generated.proto index 6e12f519eef76..6611e1b0b6d9e 100644 --- a/pkg/apis/extensions/v1beta1/generated.proto +++ b/pkg/apis/extensions/v1beta1/generated.proto @@ -26,7 +26,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; import "k8s.io/kubernetes/pkg/apis/policy/v1beta1/generated.proto"; @@ -533,6 +532,7 @@ message IngressTLS { optional string secretName = 2; } +// NetworkPolicy describes what network traffic is allowed for a set of Pods message NetworkPolicy { // Standard object's metadata. // More info: https://github.com/kubernetes/community/blob/master/contributors/devel/api-conventions.md#metadata @@ -613,13 +613,12 @@ message NetworkPolicySpec { optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector podSelector = 1; // List of ingress rules to be applied to the selected pods. - // Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, + // Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod // OR if the traffic source is the pod's local node, // OR if the traffic matches at least one ingress rule across all of the NetworkPolicy // objects whose podSelector matches the pod. - // If this field is empty then this NetworkPolicy does not affect ingress isolation. - // If this field is present and contains at least one rule, this policy allows any traffic - // which matches at least one of the ingress rules in this list. + // If this field is empty then this NetworkPolicy does not allow any traffic + // (and serves solely to ensure that the pods it selects are isolated by default). // +optional repeated NetworkPolicyIngressRule ingress = 2; } @@ -711,6 +710,11 @@ message PodSecurityPolicySpec { // will not be forced to. // +optional optional bool readOnlyRootFilesystem = 14; + + // AllowedHostPaths is a white list of allowed host path prefixes. Empty indicates that all + // host paths may be used. + // +optional + repeated string allowedHostPaths = 15; } // ReplicaSet represents the configuration of a ReplicaSet. @@ -831,7 +835,7 @@ message ReplicationControllerDummy { } message RollbackConfig { - // The revision to rollback to. If set to 0, rollbck to the last revision. + // The revision to rollback to. If set to 0, rollback to the last revision. // +optional optional int64 revision = 1; } diff --git a/pkg/apis/extensions/v1beta1/types.generated.go b/pkg/apis/extensions/v1beta1/types.generated.go index 513737be10c2b..8a542d51ccaec 100644 --- a/pkg/apis/extensions/v1beta1/types.generated.go +++ b/pkg/apis/extensions/v1beta1/types.generated.go @@ -14595,7 +14595,7 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { } else { yysep2 := !z.EncBinary() yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [14]bool + var yyq2 [15]bool _, _, _ = yysep2, yyq2, yy2arr2 const yyr2 bool = false yyq2[0] = x.Privileged != false @@ -14608,9 +14608,10 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { yyq2[7] = x.HostPID != false yyq2[8] = x.HostIPC != false yyq2[13] = x.ReadOnlyRootFilesystem != false + yyq2[14] = len(x.AllowedHostPaths) != 0 var yynn2 int if yyr2 || yy2arr2 { - r.EncodeArrayStart(14) + r.EncodeArrayStart(15) } else { yynn2 = 4 for _, b := range yyq2 { @@ -14955,6 +14956,39 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[14] { + if x.AllowedHostPaths == nil { + r.EncodeNil() + } else { + yym54 := z.EncBinary() + _ = yym54 + if false { + } else { + z.F.EncSliceStringV(x.AllowedHostPaths, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[14] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("allowedHostPaths")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.AllowedHostPaths == nil { + r.EncodeNil() + } else { + yym55 := z.EncBinary() + _ = yym55 + if false { + } else { + z.F.EncSliceStringV(x.AllowedHostPaths, false, e) + } + } + } + } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { @@ -15164,6 +15198,18 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromMap(l int, d *codec1978.Decod *((*bool)(yyv26)) = r.DecodeBool() } } + case "allowedHostPaths": + if r.TryDecodeAsNil() { + x.AllowedHostPaths = nil + } else { + yyv28 := &x.AllowedHostPaths + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + z.F.DecSliceStringX(yyv28, false, d) + } + } default: z.DecStructFieldNotFound(-1, yys3) } // end switch yys3 @@ -15175,16 +15221,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj28 int - var yyb28 bool - var yyhl28 bool = l >= 0 - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + var yyj30 int + var yyb30 bool + var yyhl30 bool = l >= 0 + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15192,21 +15238,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Privileged = false } else { - yyv29 := &x.Privileged - yym30 := z.DecBinary() - _ = yym30 + yyv31 := &x.Privileged + yym32 := z.DecBinary() + _ = yym32 if false { } else { - *((*bool)(yyv29)) = r.DecodeBool() + *((*bool)(yyv31)) = r.DecodeBool() } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15214,21 +15260,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.DefaultAddCapabilities = nil } else { - yyv31 := &x.DefaultAddCapabilities - yym32 := z.DecBinary() - _ = yym32 + yyv33 := &x.DefaultAddCapabilities + yym34 := z.DecBinary() + _ = yym34 if false { } else { - h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv31), d) + h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv33), d) } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15236,21 +15282,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.RequiredDropCapabilities = nil } else { - yyv33 := &x.RequiredDropCapabilities - yym34 := z.DecBinary() - _ = yym34 + yyv35 := &x.RequiredDropCapabilities + yym36 := z.DecBinary() + _ = yym36 if false { } else { - h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv33), d) + h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv35), d) } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15258,21 +15304,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.AllowedCapabilities = nil } else { - yyv35 := &x.AllowedCapabilities - yym36 := z.DecBinary() - _ = yym36 + yyv37 := &x.AllowedCapabilities + yym38 := z.DecBinary() + _ = yym38 if false { } else { - h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv35), d) + h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv37), d) } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15280,21 +15326,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Volumes = nil } else { - yyv37 := &x.Volumes - yym38 := z.DecBinary() - _ = yym38 + yyv39 := &x.Volumes + yym40 := z.DecBinary() + _ = yym40 if false { } else { - h.decSliceFSType((*[]FSType)(yyv37), d) + h.decSliceFSType((*[]FSType)(yyv39), d) } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15302,21 +15348,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.HostNetwork = false } else { - yyv39 := &x.HostNetwork - yym40 := z.DecBinary() - _ = yym40 + yyv41 := &x.HostNetwork + yym42 := z.DecBinary() + _ = yym42 if false { } else { - *((*bool)(yyv39)) = r.DecodeBool() + *((*bool)(yyv41)) = r.DecodeBool() } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15324,21 +15370,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.HostPorts = nil } else { - yyv41 := &x.HostPorts - yym42 := z.DecBinary() - _ = yym42 + yyv43 := &x.HostPorts + yym44 := z.DecBinary() + _ = yym44 if false { } else { - h.decSliceHostPortRange((*[]HostPortRange)(yyv41), d) + h.decSliceHostPortRange((*[]HostPortRange)(yyv43), d) } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15346,21 +15392,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.HostPID = false } else { - yyv43 := &x.HostPID - yym44 := z.DecBinary() - _ = yym44 + yyv45 := &x.HostPID + yym46 := z.DecBinary() + _ = yym46 if false { } else { - *((*bool)(yyv43)) = r.DecodeBool() + *((*bool)(yyv45)) = r.DecodeBool() } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15368,21 +15414,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.HostIPC = false } else { - yyv45 := &x.HostIPC - yym46 := z.DecBinary() - _ = yym46 + yyv47 := &x.HostIPC + yym48 := z.DecBinary() + _ = yym48 if false { } else { - *((*bool)(yyv45)) = r.DecodeBool() + *((*bool)(yyv47)) = r.DecodeBool() } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15390,16 +15436,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.SELinux = SELinuxStrategyOptions{} } else { - yyv47 := &x.SELinux - yyv47.CodecDecodeSelf(d) + yyv49 := &x.SELinux + yyv49.CodecDecodeSelf(d) } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15407,16 +15453,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.RunAsUser = RunAsUserStrategyOptions{} } else { - yyv48 := &x.RunAsUser - yyv48.CodecDecodeSelf(d) + yyv50 := &x.RunAsUser + yyv50.CodecDecodeSelf(d) } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15424,16 +15470,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.SupplementalGroups = SupplementalGroupsStrategyOptions{} } else { - yyv49 := &x.SupplementalGroups - yyv49.CodecDecodeSelf(d) + yyv51 := &x.SupplementalGroups + yyv51.CodecDecodeSelf(d) } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15441,16 +15487,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.FSGroup = FSGroupStrategyOptions{} } else { - yyv50 := &x.FSGroup - yyv50.CodecDecodeSelf(d) + yyv52 := &x.FSGroup + yyv52.CodecDecodeSelf(d) } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15458,26 +15504,48 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.ReadOnlyRootFilesystem = false } else { - yyv51 := &x.ReadOnlyRootFilesystem - yym52 := z.DecBinary() - _ = yym52 + yyv53 := &x.ReadOnlyRootFilesystem + yym54 := z.DecBinary() + _ = yym54 + if false { + } else { + *((*bool)(yyv53)) = r.DecodeBool() + } + } + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l + } else { + yyb30 = r.CheckBreak() + } + if yyb30 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.AllowedHostPaths = nil + } else { + yyv55 := &x.AllowedHostPaths + yym56 := z.DecBinary() + _ = yym56 if false { } else { - *((*bool)(yyv51)) = r.DecodeBool() + z.F.DecSliceStringX(yyv55, false, d) } } for { - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj28-1, "") + z.DecStructFieldNotFound(yyj30-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -21266,7 +21334,7 @@ func (x codecSelfer1234) decSlicePodSecurityPolicy(v *[]PodSecurityPolicy, d *co yyrg1 := len(yyv1) > 0 yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 560) + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 584) if yyrt1 { if yyrl1 <= cap(yyv1) { yyv1 = yyv1[:yyrl1] diff --git a/pkg/apis/extensions/v1beta1/types.go b/pkg/apis/extensions/v1beta1/types.go index 196f3137538cf..a97bb8427caef 100644 --- a/pkg/apis/extensions/v1beta1/types.go +++ b/pkg/apis/extensions/v1beta1/types.go @@ -228,7 +228,7 @@ type DeploymentRollback struct { } type RollbackConfig struct { - // The revision to rollback to. If set to 0, rollbck to the last revision. + // The revision to rollback to. If set to 0, rollback to the last revision. // +optional Revision int64 `json:"revision,omitempty" protobuf:"varint,1,opt,name=revision"` } @@ -909,6 +909,10 @@ type PodSecurityPolicySpec struct { // will not be forced to. // +optional ReadOnlyRootFilesystem bool `json:"readOnlyRootFilesystem,omitempty" protobuf:"varint,14,opt,name=readOnlyRootFilesystem"` + // AllowedHostPaths is a white list of allowed host path prefixes. Empty indicates that all + // host paths may be used. + // +optional + AllowedHostPaths []string `json:"allowedHostPaths,omitempty" protobuf:"bytes,15,opt,name=allowedHostPaths"` } // FS Type gives strong typing to different file systems that are used by volumes. @@ -1055,6 +1059,7 @@ type PodSecurityPolicyList struct { Items []PodSecurityPolicy `json:"items" protobuf:"bytes,2,rep,name=items"` } +// NetworkPolicy describes what network traffic is allowed for a set of Pods type NetworkPolicy struct { metav1.TypeMeta `json:",inline"` // Standard object's metadata. @@ -1076,13 +1081,12 @@ type NetworkPolicySpec struct { PodSelector metav1.LabelSelector `json:"podSelector" protobuf:"bytes,1,opt,name=podSelector"` // List of ingress rules to be applied to the selected pods. - // Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, + // Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod // OR if the traffic source is the pod's local node, // OR if the traffic matches at least one ingress rule across all of the NetworkPolicy // objects whose podSelector matches the pod. - // If this field is empty then this NetworkPolicy does not affect ingress isolation. - // If this field is present and contains at least one rule, this policy allows any traffic - // which matches at least one of the ingress rules in this list. + // If this field is empty then this NetworkPolicy does not allow any traffic + // (and serves solely to ensure that the pods it selects are isolated by default). // +optional Ingress []NetworkPolicyIngressRule `json:"ingress,omitempty" protobuf:"bytes,2,rep,name=ingress"` } diff --git a/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go b/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go index d94bc009e9d42..213f8494ad06c 100644 --- a/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go +++ b/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go @@ -331,6 +331,7 @@ func (IngressTLS) SwaggerDoc() map[string]string { } var map_NetworkPolicy = map[string]string{ + "": "NetworkPolicy describes what network traffic is allowed for a set of Pods", "metadata": "Standard object's metadata. More info: https://github.com/kubernetes/community/blob/master/contributors/devel/api-conventions.md#metadata", "spec": "Specification of the desired behavior for this NetworkPolicy.", } @@ -379,7 +380,7 @@ func (NetworkPolicyPort) SwaggerDoc() map[string]string { var map_NetworkPolicySpec = map[string]string{ "podSelector": "Selects the pods to which this NetworkPolicy object applies. The array of ingress rules is applied to any pods selected by this field. Multiple network policies can select the same set of pods. In this case, the ingress rules for each are combined additively. This field is NOT optional and follows standard label selector semantics. An empty podSelector matches all pods in this namespace.", - "ingress": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not affect ingress isolation. If this field is present and contains at least one rule, this policy allows any traffic which matches at least one of the ingress rules in this list.", + "ingress": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default).", } func (NetworkPolicySpec) SwaggerDoc() map[string]string { @@ -422,6 +423,7 @@ var map_PodSecurityPolicySpec = map[string]string{ "supplementalGroups": "SupplementalGroups is the strategy that will dictate what supplemental groups are used by the SecurityContext.", "fsGroup": "FSGroup is the strategy that will dictate what fs group is used by the SecurityContext.", "readOnlyRootFilesystem": "ReadOnlyRootFilesystem when set to true will force containers to run with a read only root file system. If the container specifically requests to run with a non-read only root file system the PSP should deny the pod. If set to false the container may run with a read only root file system if it wishes but it will not be forced to.", + "allowedHostPaths": "AllowedHostPaths is a white list of allowed host path prefixes. Empty indicates that all host paths may be used.", } func (PodSecurityPolicySpec) SwaggerDoc() map[string]string { @@ -497,7 +499,7 @@ func (ReplicationControllerDummy) SwaggerDoc() map[string]string { } var map_RollbackConfig = map[string]string{ - "revision": "The revision to rollback to. If set to 0, rollbck to the last revision.", + "revision": "The revision to rollback to. If set to 0, rollback to the last revision.", } func (RollbackConfig) SwaggerDoc() map[string]string { diff --git a/pkg/apis/extensions/v1beta1/zz_generated.conversion.go b/pkg/apis/extensions/v1beta1/zz_generated.conversion.go index 42e080ff1313a..2fa3e94e2cd07 100644 --- a/pkg/apis/extensions/v1beta1/zz_generated.conversion.go +++ b/pkg/apis/extensions/v1beta1/zz_generated.conversion.go @@ -1215,6 +1215,7 @@ func autoConvert_v1beta1_PodSecurityPolicySpec_To_extensions_PodSecurityPolicySp return err } out.ReadOnlyRootFilesystem = in.ReadOnlyRootFilesystem + out.AllowedHostPaths = *(*[]string)(unsafe.Pointer(&in.AllowedHostPaths)) return nil } @@ -1256,6 +1257,7 @@ func autoConvert_extensions_PodSecurityPolicySpec_To_v1beta1_PodSecurityPolicySp return err } out.ReadOnlyRootFilesystem = in.ReadOnlyRootFilesystem + out.AllowedHostPaths = *(*[]string)(unsafe.Pointer(&in.AllowedHostPaths)) return nil } diff --git a/pkg/apis/extensions/v1beta1/zz_generated.deepcopy.go b/pkg/apis/extensions/v1beta1/zz_generated.deepcopy.go index 1228dab37b875..3d2d35f090f04 100644 --- a/pkg/apis/extensions/v1beta1/zz_generated.deepcopy.go +++ b/pkg/apis/extensions/v1beta1/zz_generated.deepcopy.go @@ -826,6 +826,11 @@ func DeepCopy_v1beta1_PodSecurityPolicySpec(in interface{}, out interface{}, c * if err := DeepCopy_v1beta1_FSGroupStrategyOptions(&in.FSGroup, &out.FSGroup, c); err != nil { return err } + if in.AllowedHostPaths != nil { + in, out := &in.AllowedHostPaths, &out.AllowedHostPaths + *out = make([]string, len(*in)) + copy(*out, *in) + } return nil } } diff --git a/pkg/apis/extensions/zz_generated.deepcopy.go b/pkg/apis/extensions/zz_generated.deepcopy.go index 829367c8e5b07..aa2c01c6d2f9c 100644 --- a/pkg/apis/extensions/zz_generated.deepcopy.go +++ b/pkg/apis/extensions/zz_generated.deepcopy.go @@ -818,6 +818,11 @@ func DeepCopy_extensions_PodSecurityPolicySpec(in interface{}, out interface{}, if err := DeepCopy_extensions_FSGroupStrategyOptions(&in.FSGroup, &out.FSGroup, c); err != nil { return err } + if in.AllowedHostPaths != nil { + in, out := &in.AllowedHostPaths, &out.AllowedHostPaths + *out = make([]string, len(*in)) + copy(*out, *in) + } return nil } } diff --git a/pkg/apis/imagepolicy/v1alpha1/generated.pb.go b/pkg/apis/imagepolicy/v1alpha1/generated.pb.go index 93e9485964b80..00276ac69b252 100644 --- a/pkg/apis/imagepolicy/v1alpha1/generated.pb.go +++ b/pkg/apis/imagepolicy/v1alpha1/generated.pb.go @@ -1030,42 +1030,41 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 592 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x92, 0xbf, 0x6f, 0xd3, 0x4e, - 0x18, 0xc6, 0xe3, 0xa4, 0xbf, 0x72, 0xf9, 0x7e, 0x69, 0x7b, 0x30, 0x44, 0x19, 0xdc, 0x2a, 0x48, - 0xa8, 0x20, 0x71, 0x47, 0x0b, 0x42, 0x15, 0x03, 0xa5, 0x46, 0x0c, 0x1d, 0x00, 0x71, 0x6c, 0x4c, - 0x5c, 0xdc, 0xb7, 0xce, 0x35, 0xf6, 0x9d, 0xe5, 0x3b, 0xbb, 0x64, 0x40, 0x62, 0x64, 0x60, 0xe0, - 0x3f, 0x62, 0xed, 0xd8, 0x91, 0xa9, 0xa2, 0xe1, 0x1f, 0x41, 0x3e, 0x3b, 0xb5, 0x69, 0xa8, 0x10, - 0xca, 0xe6, 0xf7, 0xde, 0x7b, 0x3f, 0xcf, 0xf3, 0xde, 0x63, 0xb4, 0x37, 0xda, 0xd5, 0x44, 0x28, - 0x3a, 0x4a, 0x07, 0x90, 0x48, 0x30, 0xa0, 0x69, 0x3c, 0x0a, 0x28, 0x8f, 0x85, 0xa6, 0x22, 0xe2, - 0x01, 0xc4, 0x2a, 0x14, 0xfe, 0x98, 0x66, 0xdb, 0x3c, 0x8c, 0x87, 0x7c, 0x9b, 0x06, 0x20, 0x21, - 0xe1, 0x06, 0x0e, 0x49, 0x9c, 0x28, 0xa3, 0x30, 0x2d, 0x00, 0xa4, 0x02, 0x90, 0x78, 0x14, 0x90, - 0x1c, 0x40, 0x6a, 0x00, 0x32, 0x05, 0xf4, 0xee, 0x07, 0xc2, 0x0c, 0xd3, 0x01, 0xf1, 0x55, 0x44, - 0x03, 0x15, 0x28, 0x6a, 0x39, 0x83, 0xf4, 0xc8, 0x56, 0xb6, 0xb0, 0x5f, 0x05, 0xbf, 0xf7, 0xa8, - 0x34, 0xc8, 0x63, 0x11, 0x71, 0x7f, 0x28, 0x24, 0x24, 0xe3, 0xca, 0x62, 0x04, 0x86, 0xd3, 0x6c, - 0xc6, 0x55, 0x8f, 0x5e, 0x37, 0x95, 0xa4, 0xd2, 0x88, 0x08, 0x66, 0x06, 0x1e, 0xff, 0x6d, 0x40, - 0xfb, 0x43, 0x88, 0xf8, 0xcc, 0xdc, 0xc3, 0xeb, 0xe6, 0x52, 0x23, 0x42, 0x2a, 0xa4, 0xd1, 0x26, - 0x99, 0x19, 0xaa, 0xed,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0x05, 0x00, 0x00, + // 574 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x92, 0xb1, 0x6f, 0xd3, 0x40, + 0x14, 0xc6, 0xe3, 0xa4, 0x49, 0x93, 0x0b, 0xd0, 0xf6, 0x60, 0xb0, 0x32, 0xb8, 0x55, 0x90, 0x50, + 0x41, 0xe2, 0x8e, 0x14, 0x84, 0x2a, 0x06, 0x4a, 0x8d, 0x18, 0x3a, 0x00, 0xe2, 0xd8, 0x98, 0xb8, + 0x38, 0x57, 0xe7, 0x1a, 0xfb, 0xce, 0xf2, 0x9d, 0x53, 0x65, 0x40, 0x62, 0x64, 0x60, 0xe0, 0x3f, + 0x62, 0xcd, 0xd8, 0x91, 0xa9, 0x22, 0xe1, 0x1f, 0x41, 0x3e, 0x3b, 0xb5, 0x49, 0x54, 0xa1, 0x2a, + 0x9b, 0xdf, 0xbd, 0xfb, 0x7e, 0xdf, 0x77, 0xef, 0x19, 0x1c, 0x8d, 0x0e, 0x15, 0xe2, 0x12, 0x8f, + 0x92, 0x3e, 0x8b, 0x05, 0xd3, 0x4c, 0xe1, 0x68, 0xe4, 0x63, 0x1a, 0x71, 0x85, 0x79, 0x48, 0x7d, + 0x16, 0xc9, 0x80, 0x7b, 0x13, 0x3c, 0xee, 0xd1, 0x20, 0x1a, 0xd2, 0x1e, 0xf6, 0x99, 0x60, 0x31, + 0xd5, 0x6c, 0x80, 0xa2, 0x58, 0x6a, 0x09, 0x71, 0x06, 0x40, 0x05, 0x00, 0x45, 0x23, 0x1f, 0xa5, + 0x00, 0x54, 0x02, 0xa0, 0x05, 0xa0, 0xf3, 0xd8, 0xe7, 0x7a, 0x98, 0xf4, 0x91, 0x27, 0x43, 0xec, + 0x4b, 0x5f, 0x62, 0xc3, 0xe9, 0x27, 0xa7, 0xa6, 0x32, 0x85, 0xf9, 0xca, 0xf8, 0x9d, 0x67, 0x79, + 0x40, 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0x3a, 0x77, 0xac, 0xe9, 0xdc, + 0xb1, 0x2e, 0xe6, 0x8e, 0xf5, 0x7b, 0xee, 0x58, 0x3f, 0xfe, 0x38, 0x95, 0x4f, 0xcd, 0xc5, 0x1c, + 0xff, 0x06, 0x00, 0x00, 0xff, 0xff, 0x71, 0xd1, 0xdc, 0xe2, 0x1b, 0x05, 0x00, 0x00, } diff --git a/pkg/apis/imagepolicy/v1alpha1/generated.proto b/pkg/apis/imagepolicy/v1alpha1/generated.proto index d4c5bbbcedc44..424c63fcf3321 100644 --- a/pkg/apis/imagepolicy/v1alpha1/generated.proto +++ b/pkg/apis/imagepolicy/v1alpha1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1alpha1"; diff --git a/pkg/apis/networking/BUILD b/pkg/apis/networking/BUILD new file mode 100644 index 0000000000000..385b9ef719555 --- /dev/null +++ b/pkg/apis/networking/BUILD @@ -0,0 +1,45 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/apis/networking/install:all-srcs", + "//pkg/apis/networking/v1:all-srcs", + "//pkg/apis/networking/validation:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/apis/networking/OWNERS b/pkg/apis/networking/OWNERS new file mode 100755 index 0000000000000..97bde97282c90 --- /dev/null +++ b/pkg/apis/networking/OWNERS @@ -0,0 +1,4 @@ +reviewers: +- caseydavenport +- danwinship +- thockin diff --git a/pkg/apis/networking/doc.go b/pkg/apis/networking/doc.go new file mode 100644 index 0000000000000..b583051ca4c72 --- /dev/null +++ b/pkg/apis/networking/doc.go @@ -0,0 +1,19 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// +k8s:deepcopy-gen=package,register +// +groupName=networking.k8s.io +package networking // import "k8s.io/kubernetes/pkg/apis/networking" diff --git a/pkg/apis/networking/install/BUILD b/pkg/apis/networking/install/BUILD new file mode 100644 index 0000000000000..0ecf69ea6b520 --- /dev/null +++ b/pkg/apis/networking/install/BUILD @@ -0,0 +1,35 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["install.go"], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/networking:go_default_library", + "//pkg/apis/networking/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/apis/networking/install/install.go b/pkg/apis/networking/install/install.go new file mode 100644 index 0000000000000..1d118c768047a --- /dev/null +++ b/pkg/apis/networking/install/install.go @@ -0,0 +1,49 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// Package install installs the experimental API group, making it available as +// an option to all of the API encoding/decoding machinery. +package install + +import ( + "k8s.io/apimachinery/pkg/apimachinery/announced" + "k8s.io/apimachinery/pkg/apimachinery/registered" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/networking" + "k8s.io/kubernetes/pkg/apis/networking/v1" +) + +func init() { + Install(api.GroupFactoryRegistry, api.Registry, api.Scheme) +} + +// Install registers the API group and adds types to a scheme +func Install(groupFactoryRegistry announced.APIGroupFactoryRegistry, registry *registered.APIRegistrationManager, scheme *runtime.Scheme) { + if err := announced.NewGroupMetaFactory( + &announced.GroupMetaFactoryArgs{ + GroupName: networking.GroupName, + VersionPreferenceOrder: []string{v1.SchemeGroupVersion.Version}, + ImportPrefix: "k8s.io/kubernetes/pkg/apis/networking", + AddInternalObjectsToScheme: networking.AddToScheme, + }, + announced.VersionToSchemeFunc{ + v1.SchemeGroupVersion.Version: v1.AddToScheme, + }, + ).Announce(groupFactoryRegistry).RegisterAndEnable(registry, scheme); err != nil { + panic(err) + } +} diff --git a/pkg/apis/networking/register.go b/pkg/apis/networking/register.go new file mode 100644 index 0000000000000..4d58a210da29a --- /dev/null +++ b/pkg/apis/networking/register.go @@ -0,0 +1,51 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package networking + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupName is the group name use in this package +const GroupName = "networking.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} + +// Kind takes an unqualified kind and returns a Group qualified GroupKind +func Kind(kind string) schema.GroupKind { + return SchemeGroupVersion.WithKind(kind).GroupKind() +} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) + AddToScheme = SchemeBuilder.AddToScheme +) + +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &NetworkPolicy{}, + &NetworkPolicyList{}, + ) + return nil +} diff --git a/pkg/apis/networking/types.go b/pkg/apis/networking/types.go new file mode 100644 index 0000000000000..f889543ed75e3 --- /dev/null +++ b/pkg/apis/networking/types.go @@ -0,0 +1,115 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package networking + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/intstr" + "k8s.io/kubernetes/pkg/api" +) + +// +genclient=true + +// NetworkPolicy describes what network traffic is allowed for a set of Pods +type NetworkPolicy struct { + metav1.TypeMeta + // +optional + metav1.ObjectMeta + + // Specification of the desired behavior for this NetworkPolicy. + // +optional + Spec NetworkPolicySpec +} + +// NetworkPolicySpec provides the specification of a NetworkPolicy +type NetworkPolicySpec struct { + // Selects the pods to which this NetworkPolicy object applies. The array of + // ingress rules is applied to any pods selected by this field. Multiple network + // policies can select the same set of pods. In this case, the ingress rules for + // each are combined additively. This field is NOT optional and follows standard + // label selector semantics. An empty podSelector matches all pods in this + // namespace. + PodSelector metav1.LabelSelector + + // List of ingress rules to be applied to the selected pods. Traffic is allowed to + // a pod if there are no NetworkPolicies selecting the pod + // (and cluster policy otherwise allows the traffic), OR if the traffic source is + // the pod's local node, OR if the traffic matches at least one ingress rule + // across all of the NetworkPolicy objects whose podSelector matches the pod. If + // this field is empty then this NetworkPolicy does not allow any traffic (and serves + // solely to ensure that the pods it selects are isolated by default) + // +optional + Ingress []NetworkPolicyIngressRule +} + +// NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods +// matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from. +type NetworkPolicyIngressRule struct { + // List of ports which should be made accessible on the pods selected for this + // rule. Each item in this list is combined using a logical OR. If this field is + // empty or missing, this rule matches all ports (traffic not restricted by port). + // If this field is present and contains at least one item, then this rule allows + // traffic only if the traffic matches at least one port in the list. + // +optional + Ports []NetworkPolicyPort + + // List of sources which should be able to access the pods selected for this rule. + // Items in this list are combined using a logical OR operation. If this field is + // empty or missing, this rule matches all sources (traffic not restricted by + // source). If this field is present and contains at least on item, this rule + // allows traffic only if the traffic matches at least one item in the from list. + // +optional + From []NetworkPolicyPeer +} + +// NetworkPolicyPort describes a port to allow traffic on +type NetworkPolicyPort struct { + // The protocol (TCP or UDP) which traffic must match. If not specified, this + // field defaults to TCP. + // +optional + Protocol *api.Protocol + + // The port on the given protocol. This can either be a numerical or named port on + // a pod. If this field is not provided, this matches all port names and numbers. + // +optional + Port *intstr.IntOrString +} + +// NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields +// must be specified. +type NetworkPolicyPeer struct { + // This is a label selector which selects Pods in this namespace. This field + // follows standard label selector semantics. If present but empty, this selector + // selects all pods in this namespace. + // +optional + PodSelector *metav1.LabelSelector + + // Selects Namespaces using cluster scoped-labels. This matches all pods in all + // namespaces selected by this label selector. This field follows standard label + // selector semantics. If present but empty, this selector selects all namespaces. + // +optional + NamespaceSelector *metav1.LabelSelector +} + +// NetworkPolicyList is a list of NetworkPolicy objects. +type NetworkPolicyList struct { + metav1.TypeMeta + // +optional + metav1.ListMeta + + Items []NetworkPolicy +} diff --git a/pkg/apis/networking/v1/BUILD b/pkg/apis/networking/v1/BUILD new file mode 100644 index 0000000000000..1401c9accc90a --- /dev/null +++ b/pkg/apis/networking/v1/BUILD @@ -0,0 +1,53 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/api/v1:go_default_library", + "//pkg/apis/extensions:go_default_library", + "//pkg/apis/networking:go_default_library", + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/apis/networking/v1/conversion.go b/pkg/apis/networking/v1/conversion.go new file mode 100644 index 0000000000000..b6d1a36df72f3 --- /dev/null +++ b/pkg/apis/networking/v1/conversion.go @@ -0,0 +1,195 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/pkg/apis/extensions" +) + +func addConversionFuncs(scheme *runtime.Scheme) error { + return scheme.AddConversionFuncs( + Convert_v1_NetworkPolicy_To_extensions_NetworkPolicy, + Convert_extensions_NetworkPolicy_To_v1_NetworkPolicy, + Convert_v1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIngressRule, + Convert_extensions_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule, + Convert_v1_NetworkPolicyList_To_extensions_NetworkPolicyList, + Convert_extensions_NetworkPolicyList_To_v1_NetworkPolicyList, + Convert_v1_NetworkPolicyPeer_To_extensions_NetworkPolicyPeer, + Convert_extensions_NetworkPolicyPeer_To_v1_NetworkPolicyPeer, + Convert_v1_NetworkPolicyPort_To_extensions_NetworkPolicyPort, + Convert_extensions_NetworkPolicyPort_To_v1_NetworkPolicyPort, + Convert_v1_NetworkPolicySpec_To_extensions_NetworkPolicySpec, + Convert_extensions_NetworkPolicySpec_To_v1_NetworkPolicySpec, + ) +} + +func Convert_v1_NetworkPolicy_To_extensions_NetworkPolicy(in *NetworkPolicy, out *extensions.NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + return Convert_v1_NetworkPolicySpec_To_extensions_NetworkPolicySpec(&in.Spec, &out.Spec, s) +} + +func Convert_extensions_NetworkPolicy_To_v1_NetworkPolicy(in *extensions.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + return Convert_extensions_NetworkPolicySpec_To_v1_NetworkPolicySpec(&in.Spec, &out.Spec, s) +} + +func Convert_v1_NetworkPolicySpec_To_extensions_NetworkPolicySpec(in *NetworkPolicySpec, out *extensions.NetworkPolicySpec, s conversion.Scope) error { + if err := s.Convert(&in.PodSelector, &out.PodSelector, 0); err != nil { + return err + } + out.Ingress = make([]extensions.NetworkPolicyIngressRule, len(in.Ingress)) + for i := range in.Ingress { + if err := Convert_v1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIngressRule(&in.Ingress[i], &out.Ingress[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_extensions_NetworkPolicySpec_To_v1_NetworkPolicySpec(in *extensions.NetworkPolicySpec, out *NetworkPolicySpec, s conversion.Scope) error { + if err := s.Convert(&in.PodSelector, &out.PodSelector, 0); err != nil { + return err + } + out.Ingress = make([]NetworkPolicyIngressRule, len(in.Ingress)) + for i := range in.Ingress { + if err := Convert_extensions_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(&in.Ingress[i], &out.Ingress[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_v1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIngressRule(in *NetworkPolicyIngressRule, out *extensions.NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = make([]extensions.NetworkPolicyPort, len(in.Ports)) + for i := range in.Ports { + if err := Convert_v1_NetworkPolicyPort_To_extensions_NetworkPolicyPort(&in.Ports[i], &out.Ports[i], s); err != nil { + return err + } + } + out.From = make([]extensions.NetworkPolicyPeer, len(in.From)) + for i := range in.From { + if err := Convert_v1_NetworkPolicyPeer_To_extensions_NetworkPolicyPeer(&in.From[i], &out.From[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_extensions_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(in *extensions.NetworkPolicyIngressRule, out *NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = make([]NetworkPolicyPort, len(in.Ports)) + for i := range in.Ports { + if err := Convert_extensions_NetworkPolicyPort_To_v1_NetworkPolicyPort(&in.Ports[i], &out.Ports[i], s); err != nil { + return err + } + } + out.From = make([]NetworkPolicyPeer, len(in.From)) + for i := range in.From { + if err := Convert_extensions_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(&in.From[i], &out.From[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_v1_NetworkPolicyPeer_To_extensions_NetworkPolicyPeer(in *NetworkPolicyPeer, out *extensions.NetworkPolicyPeer, s conversion.Scope) error { + if in.PodSelector != nil { + out.PodSelector = new(metav1.LabelSelector) + if err := s.Convert(in.PodSelector, out.PodSelector, 0); err != nil { + return err + } + } else { + out.PodSelector = nil + } + if in.NamespaceSelector != nil { + out.NamespaceSelector = new(metav1.LabelSelector) + if err := s.Convert(in.NamespaceSelector, out.NamespaceSelector, 0); err != nil { + return err + } + } else { + out.NamespaceSelector = nil + } + return nil +} + +func Convert_extensions_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(in *extensions.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { + if in.PodSelector != nil { + out.PodSelector = new(metav1.LabelSelector) + if err := s.Convert(in.PodSelector, out.PodSelector, 0); err != nil { + return err + } + } else { + out.PodSelector = nil + } + if in.NamespaceSelector != nil { + out.NamespaceSelector = new(metav1.LabelSelector) + if err := s.Convert(in.NamespaceSelector, out.NamespaceSelector, 0); err != nil { + return err + } + } else { + out.NamespaceSelector = nil + } + return nil +} + +func Convert_v1_NetworkPolicyPort_To_extensions_NetworkPolicyPort(in *NetworkPolicyPort, out *extensions.NetworkPolicyPort, s conversion.Scope) error { + if in.Protocol != nil { + out.Protocol = new(api.Protocol) + *out.Protocol = api.Protocol(*in.Protocol) + } else { + out.Protocol = nil + } + out.Port = in.Port + return nil +} + +func Convert_extensions_NetworkPolicyPort_To_v1_NetworkPolicyPort(in *extensions.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { + if in.Protocol != nil { + out.Protocol = new(v1.Protocol) + *out.Protocol = v1.Protocol(*in.Protocol) + } else { + out.Protocol = nil + } + out.Port = in.Port + return nil +} + +func Convert_v1_NetworkPolicyList_To_extensions_NetworkPolicyList(in *NetworkPolicyList, out *extensions.NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = make([]extensions.NetworkPolicy, len(in.Items)) + for i := range in.Items { + if err := Convert_v1_NetworkPolicy_To_extensions_NetworkPolicy(&in.Items[i], &out.Items[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_extensions_NetworkPolicyList_To_v1_NetworkPolicyList(in *extensions.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = make([]NetworkPolicy, len(in.Items)) + for i := range in.Items { + if err := Convert_extensions_NetworkPolicy_To_v1_NetworkPolicy(&in.Items[i], &out.Items[i], s); err != nil { + return err + } + } + return nil +} diff --git a/pkg/apis/networking/v1/defaults.go b/pkg/apis/networking/v1/defaults.go new file mode 100644 index 0000000000000..e4aeaaa68b093 --- /dev/null +++ b/pkg/apis/networking/v1/defaults.go @@ -0,0 +1,34 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/kubernetes/pkg/api/v1" +) + +func addDefaultingFuncs(scheme *runtime.Scheme) error { + return RegisterDefaults(scheme) +} + +func SetDefaults_NetworkPolicyPort(obj *NetworkPolicyPort) { + // Default any undefined Protocol fields to TCP. + if obj.Protocol == nil { + proto := v1.ProtocolTCP + obj.Protocol = &proto + } +} diff --git a/pkg/apis/networking/v1/doc.go b/pkg/apis/networking/v1/doc.go new file mode 100644 index 0000000000000..e4000f86c9767 --- /dev/null +++ b/pkg/apis/networking/v1/doc.go @@ -0,0 +1,22 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// +k8s:deepcopy-gen=package,register +// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/networking +// +k8s:openapi-gen=true +// +k8s:defaulter-gen=TypeMeta +// +groupName=networking.k8s.io +package v1 // import "k8s.io/kubernetes/pkg/apis/networking/v1" diff --git a/pkg/apis/networking/v1/generated.pb.go b/pkg/apis/networking/v1/generated.pb.go new file mode 100644 index 0000000000000..969ea9dd17b22 --- /dev/null +++ b/pkg/apis/networking/v1/generated.pb.go @@ -0,0 +1,1345 @@ +/* +Copyright 2017 The Kubernetes 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 protoc-gen-gogo. +// source: k8s.io/kubernetes/pkg/apis/networking/v1/generated.proto +// DO NOT EDIT! + +/* + Package v1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/pkg/apis/networking/v1/generated.proto + + It has these top-level messages: + NetworkPolicy + NetworkPolicyIngressRule + NetworkPolicyList + NetworkPolicyPeer + NetworkPolicyPort + NetworkPolicySpec +*/ +package v1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + +import k8s_io_apimachinery_pkg_util_intstr "k8s.io/apimachinery/pkg/util/intstr" + +import k8s_io_kubernetes_pkg_api_v1 "k8s.io/kubernetes/pkg/api/v1" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *NetworkPolicy) Reset() { *m = NetworkPolicy{} } +func (*NetworkPolicy) ProtoMessage() {} +func (*NetworkPolicy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func (m *NetworkPolicyIngressRule) Reset() { *m = NetworkPolicyIngressRule{} } +func (*NetworkPolicyIngressRule) ProtoMessage() {} +func (*NetworkPolicyIngressRule) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{1} +} + +func (m *NetworkPolicyList) Reset() { *m = NetworkPolicyList{} } +func (*NetworkPolicyList) ProtoMessage() {} +func (*NetworkPolicyList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } + +func (m *NetworkPolicyPeer) Reset() { *m = NetworkPolicyPeer{} } +func (*NetworkPolicyPeer) ProtoMessage() {} +func (*NetworkPolicyPeer) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } + +func (m *NetworkPolicyPort) Reset() { *m = NetworkPolicyPort{} } +func (*NetworkPolicyPort) ProtoMessage() {} +func (*NetworkPolicyPort) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } + +func (m *NetworkPolicySpec) Reset() { *m = NetworkPolicySpec{} } +func (*NetworkPolicySpec) ProtoMessage() {} +func (*NetworkPolicySpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } + +func init() { + proto.RegisterType((*NetworkPolicy)(nil), "k8s.io.kubernetes.pkg.apis.networking.v1.NetworkPolicy") + proto.RegisterType((*NetworkPolicyIngressRule)(nil), "k8s.io.kubernetes.pkg.apis.networking.v1.NetworkPolicyIngressRule") + proto.RegisterType((*NetworkPolicyList)(nil), "k8s.io.kubernetes.pkg.apis.networking.v1.NetworkPolicyList") + proto.RegisterType((*NetworkPolicyPeer)(nil), "k8s.io.kubernetes.pkg.apis.networking.v1.NetworkPolicyPeer") + proto.RegisterType((*NetworkPolicyPort)(nil), "k8s.io.kubernetes.pkg.apis.networking.v1.NetworkPolicyPort") + proto.RegisterType((*NetworkPolicySpec)(nil), "k8s.io.kubernetes.pkg.apis.networking.v1.NetworkPolicySpec") +} +func (m *NetworkPolicy) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicy) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n2, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n2 + return i, nil +} + +func (m *NetworkPolicyIngressRule) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicyIngressRule) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Ports) > 0 { + for _, msg := range m.Ports { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if len(m.From) > 0 { + for _, msg := range m.From { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *NetworkPolicyList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicyList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n3, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *NetworkPolicyPeer) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicyPeer) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.PodSelector != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.PodSelector.Size())) + n4, err := m.PodSelector.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + } + if m.NamespaceSelector != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.NamespaceSelector.Size())) + n5, err := m.NamespaceSelector.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 + } + return i, nil +} + +func (m *NetworkPolicyPort) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicyPort) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.Protocol != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Protocol))) + i += copy(dAtA[i:], *m.Protocol) + } + if m.Port != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Port.Size())) + n6, err := m.Port.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n6 + } + return i, nil +} + +func (m *NetworkPolicySpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicySpec) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.PodSelector.Size())) + n7, err := m.PodSelector.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n7 + if len(m.Ingress) > 0 { + for _, msg := range m.Ingress { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *NetworkPolicy) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *NetworkPolicyIngressRule) Size() (n int) { + var l int + _ = l + if len(m.Ports) > 0 { + for _, e := range m.Ports { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.From) > 0 { + for _, e := range m.From { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *NetworkPolicyList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *NetworkPolicyPeer) Size() (n int) { + var l int + _ = l + if m.PodSelector != nil { + l = m.PodSelector.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.NamespaceSelector != nil { + l = m.NamespaceSelector.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *NetworkPolicyPort) Size() (n int) { + var l int + _ = l + if m.Protocol != nil { + l = len(*m.Protocol) + n += 1 + l + sovGenerated(uint64(l)) + } + if m.Port != nil { + l = m.Port.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *NetworkPolicySpec) Size() (n int) { + var l int + _ = l + l = m.PodSelector.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Ingress) > 0 { + for _, e := range m.Ingress { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *NetworkPolicy) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicy{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "NetworkPolicySpec", "NetworkPolicySpec", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicyIngressRule) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicyIngressRule{`, + `Ports:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Ports), "NetworkPolicyPort", "NetworkPolicyPort", 1), `&`, ``, 1) + `,`, + `From:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.From), "NetworkPolicyPeer", "NetworkPolicyPeer", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicyList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicyList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "NetworkPolicy", "NetworkPolicy", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicyPeer) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicyPeer{`, + `PodSelector:` + strings.Replace(fmt.Sprintf("%v", this.PodSelector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, + `NamespaceSelector:` + strings.Replace(fmt.Sprintf("%v", this.NamespaceSelector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicyPort) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicyPort{`, + `Protocol:` + valueToStringGenerated(this.Protocol) + `,`, + `Port:` + strings.Replace(fmt.Sprintf("%v", this.Port), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicySpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicySpec{`, + `PodSelector:` + strings.Replace(strings.Replace(this.PodSelector.String(), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1), `&`, ``, 1) + `,`, + `Ingress:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Ingress), "NetworkPolicyIngressRule", "NetworkPolicyIngressRule", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *NetworkPolicy) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicy: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicy: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicyIngressRule) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicyIngressRule: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicyIngressRule: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Ports", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Ports = append(m.Ports, NetworkPolicyPort{}) + if err := m.Ports[len(m.Ports)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field From", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.From = append(m.From, NetworkPolicyPeer{}) + if err := m.From[len(m.From)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicyList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicyList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicyList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, NetworkPolicy{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicyPeer) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicyPeer: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicyPeer: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PodSelector", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.PodSelector == nil { + m.PodSelector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} + } + if err := m.PodSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field NamespaceSelector", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.NamespaceSelector == nil { + m.NamespaceSelector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} + } + if err := m.NamespaceSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicyPort) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicyPort: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicyPort: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Protocol", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := k8s_io_kubernetes_pkg_api_v1.Protocol(dAtA[iNdEx:postIndex]) + m.Protocol = &s + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Port == nil { + m.Port = &k8s_io_apimachinery_pkg_util_intstr.IntOrString{} + } + if err := m.Port.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicySpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicySpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicySpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PodSelector", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.PodSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Ingress", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Ingress = append(m.Ingress, NetworkPolicyIngressRule{}) + if err := m.Ingress[len(m.Ingress)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/kubernetes/pkg/apis/networking/v1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 663 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0xcf, 0x4f, 0x13, 0x41, + 0x18, 0xed, 0x56, 0x08, 0x75, 0x90, 0x20, 0x6b, 0x4c, 0x1a, 0x0e, 0x5b, 0xd2, 0x68, 0xc2, 0x41, + 0x67, 0xad, 0xf8, 0x03, 0x63, 0xbc, 0xec, 0xc1, 0x84, 0x44, 0xa1, 0x2e, 0x37, 0x83, 0x09, 0xd3, + 0xe5, 0x63, 0x19, 0xda, 0x9d, 0xd9, 0xcc, 0x4c, 0x2b, 0xdc, 0xfc, 0x13, 0xfc, 0x6b, 0xfc, 0x1b, + 0xb8, 0xc9, 0xd1, 0xc4, 0xa4, 0x91, 0xf5, 0xee, 0xcd, 0x8b, 0x27, 0x33, 0xbb, 0x53, 0xb6, 0xb0, + 0x2c, 0x92, 0xe2, 0x6d, 0x66, 0xf2, 0xbd, 0xf7, 0xbe, 0x37, 0xef, 0x9b, 0x41, 0xab, 0xdd, 0x55, + 0x89, 0x29, 0x77, 0xbb, 0xfd, 0x0e, 0x08, 0x06, 0x0a, 0xa4, 0x1b, 0x77, 0x43, 0x97, 0xc4, 0x54, + 0xba, 0x0c, 0xd4, 0x47, 0x2e, 0xba, 0x94, 0x85, 0xee, 0xa0, 0xe5, 0x86, 0xc0, 0x40, 0x10, 0x05, + 0x3b, 0x38, 0x16, 0x5c, 0x71, 0x7b, 0x39, 0x43, 0xe2, 0x1c, 0x89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0x85, 0xf5, 0xf3, 0x8c, 0x7e, 0x51, 0xa4, 0xf9, 0xa5, 0xe0, + 0x9b, 0x0b, 0x65, 0xbf, 0x43, 0xb5, 0xf4, 0x65, 0x06, 0xbc, 0x97, 0x9a, 0xbe, 0xe9, 0x3d, 0xd5, + 0xa9, 0xb4, 0xcd, 0xd9, 0x9f, 0x61, 0xe3, 0xfe, 0x65, 0x5f, 0x0b, 0x1e, 0x15, 0xfa, 0xa7, 0x34, + 0xf6, 0x3a, 0x9a, 0xd2, 0xa3, 0x69, 0x5c, 0x95, 0xbf, 0x66, 0xfd, 0x9f, 0xe1, 0xec, 0x3f, 0xc3, + 0x6b, 0x4c, 0x6d, 0x88, 0x4d, 0x25, 0x28, 0x0b, 0xbd, 0x9a, 0x1e, 0x41, 0xdd, 0x9c, 0x9f, 0xf2, + 0x34, 0x7f, 0x9d, 0x6f, 0x5c, 0x3f, 0x3e, 0x7b, 0xff, 0xbf, 0x05, 0x76, 0xc7, 0x8c, 0x49, 0x79, + 0x68, 0x11, 0x9a, 0xa1, 0xd9, 0xa3, 0x36, 0x23, 0xe9, 0x4d, 0x38, 0x92, 0x63, 0x5f, 0x83, 0x37, + 0x6f, 0x64, 0x67, 0x46, 0x87, 0x23, 0x0d, 0xef, 0xde, 0xd1, 0x89, 0x53, 0x39, 0x3e, 0x71, 0x2a, + 0xdf, 0x4e, 0x9c, 0xca, 0xa7, 0xc4, 0xb1, 0x8e, 0x12, 0xc7, 0x3a, 0x4e, 0x1c, 0xeb, 0x47, 0xe2, + 0x58, 0x9f, 0x7f, 0x3a, 0x95, 0xf7, 0xd5, 0x41, 0xeb, 0x6f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x7c, + 0x88, 0xbe, 0x48, 0x5a, 0x07, 0x00, 0x00, +} diff --git a/pkg/apis/networking/v1/generated.proto b/pkg/apis/networking/v1/generated.proto new file mode 100644 index 0000000000000..ef2d211d2ce0b --- /dev/null +++ b/pkg/apis/networking/v1/generated.proto @@ -0,0 +1,127 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.kubernetes.pkg.apis.networking.v1; + +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; +import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; +import "k8s.io/kubernetes/pkg/apis/extensions/v1beta1/generated.proto"; +import "k8s.io/kubernetes/pkg/apis/policy/v1beta1/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v1"; + +// NetworkPolicy describes what network traffic is allowed for a set of Pods +message NetworkPolicy { + // Standard object's metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Specification of the desired behavior for this NetworkPolicy. + // +optional + optional NetworkPolicySpec spec = 2; +} + +// NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods +// matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from. +message NetworkPolicyIngressRule { + // List of ports which should be made accessible on the pods selected for this + // rule. Each item in this list is combined using a logical OR. If this field is + // empty or missing, this rule matches all ports (traffic not restricted by port). + // If this field is present and contains at least one item, then this rule allows + // traffic only if the traffic matches at least one port in the list. + // +optional + repeated NetworkPolicyPort ports = 1; + + // List of sources which should be able to access the pods selected for this rule. + // Items in this list are combined using a logical OR operation. If this field is + // empty or missing, this rule matches all sources (traffic not restricted by + // source). If this field is present and contains at least on item, this rule + // allows traffic only if the traffic matches at least one item in the from list. + // +optional + repeated NetworkPolicyPeer from = 2; +} + +// NetworkPolicyList is a list of NetworkPolicy objects. +message NetworkPolicyList { + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // Items is a list of schema objects. + repeated NetworkPolicy items = 2; +} + +// NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields +// must be specified. +message NetworkPolicyPeer { + // This is a label selector which selects Pods in this namespace. This field + // follows standard label selector semantics. If present but empty, this selector + // selects all pods in this namespace. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector podSelector = 1; + + // Selects Namespaces using cluster scoped-labels. This matches all pods in all + // namespaces selected by this label selector. This field follows standard label + // selector semantics. If present but empty, this selector selects all namespaces. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector namespaceSelector = 2; +} + +// NetworkPolicyPort describes a port to allow traffic on +message NetworkPolicyPort { + // The protocol (TCP or UDP) which traffic must match. If not specified, this + // field defaults to TCP. + // +optional + optional string protocol = 1; + + // The port on the given protocol. This can either be a numerical or named port on + // a pod. If this field is not provided, this matches all port names and numbers. + // +optional + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString port = 2; +} + +// NetworkPolicySpec provides the specification of a NetworkPolicy +message NetworkPolicySpec { + // Selects the pods to which this NetworkPolicy object applies. The array of + // ingress rules is applied to any pods selected by this field. Multiple network + // policies can select the same set of pods. In this case, the ingress rules for + // each are combined additively. This field is NOT optional and follows standard + // label selector semantics. An empty podSelector matches all pods in this + // namespace. + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector podSelector = 1; + + // List of ingress rules to be applied to the selected pods. Traffic is allowed to + // a pod if there are no NetworkPolicies selecting the pod + // (and cluster policy otherwise allows the traffic), OR if the traffic source is + // the pod's local node, OR if the traffic matches at least one ingress rule + // across all of the NetworkPolicy objects whose podSelector matches the pod. If + // this field is empty then this NetworkPolicy does not allow any traffic (and serves + // solely to ensure that the pods it selects are isolated by default) + // +optional + repeated NetworkPolicyIngressRule ingress = 2; +} + diff --git a/pkg/apis/networking/v1/register.go b/pkg/apis/networking/v1/register.go new file mode 100644 index 0000000000000..c8d3c83bcc906 --- /dev/null +++ b/pkg/apis/networking/v1/register.go @@ -0,0 +1,50 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupName is the group name use in this package +const GroupName = "networking.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addDefaultingFuncs, addConversionFuncs) + AddToScheme = SchemeBuilder.AddToScheme +) + +// Adds the list of known types to api.Scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &NetworkPolicy{}, + &NetworkPolicyList{}, + ) + + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) + return nil +} diff --git a/pkg/apis/networking/v1/types.generated.go b/pkg/apis/networking/v1/types.generated.go new file mode 100644 index 0000000000000..38d6af90a43b9 --- /dev/null +++ b/pkg/apis/networking/v1/types.generated.go @@ -0,0 +1,2322 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +// ************************************************************ +// DO NOT EDIT. +// THIS FILE IS AUTO-GENERATED BY codecgen. +// ************************************************************ + +package v1 + +import ( + "errors" + "fmt" + codec1978 "github.com/ugorji/go/codec" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" + pkg4_intstr "k8s.io/apimachinery/pkg/util/intstr" + pkg3_v1 "k8s.io/kubernetes/pkg/api/v1" + "reflect" + "runtime" + time "time" +) + +const ( + // ----- content types ---- + codecSelferC_UTF81234 = 1 + codecSelferC_RAW1234 = 0 + // ----- value types used ---- + codecSelferValueTypeArray1234 = 10 + codecSelferValueTypeMap1234 = 9 + // ----- containerStateValues ---- + codecSelfer_containerMapKey1234 = 2 + codecSelfer_containerMapValue1234 = 3 + codecSelfer_containerMapEnd1234 = 4 + codecSelfer_containerArrayElem1234 = 6 + codecSelfer_containerArrayEnd1234 = 7 +) + +var ( + codecSelferBitsize1234 = uint8(reflect.TypeOf(uint(0)).Bits()) + codecSelferOnlyMapOrArrayEncodeToStructErr1234 = errors.New(`only encoded map or array can be decoded into a struct`) +) + +type codecSelfer1234 struct{} + +func init() { + if codec1978.GenVersion != 5 { + _, file, _, _ := runtime.Caller(0) + err := fmt.Errorf("codecgen version mismatch: current: %v, need %v. Re-generate file: %v", + 5, codec1978.GenVersion, file) + panic(err) + } + if false { // reference the types, but skip this branch at build/run time + var v0 pkg1_v1.TypeMeta + var v1 pkg2_types.UID + var v2 pkg4_intstr.IntOrString + var v3 pkg3_v1.Protocol + var v4 time.Time + _, _, _, _, _ = v0, v1, v2, v3, v4 + } +} + +func (x *NetworkPolicy) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("spec")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicy) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "spec": + if r.TryDecodeAsNil() { + x.Spec = NetworkPolicySpec{} + } else { + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv12 := &x.Kind + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv14 := &x.APIVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv16 := &x.ObjectMeta + yym17 := z.DecBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.DecExt(yyv16) { + } else { + z.DecFallback(yyv16, false) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Spec = NetworkPolicySpec{} + } else { + yyv18 := &x.Spec + yyv18.CodecDecodeSelf(d) + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = len(x.Ingress) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy4 := &x.PodSelector + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(yy4) { + } else { + z.EncFallback(yy4) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("podSelector")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy6 := &x.PodSelector + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(yy6) { + } else { + z.EncFallback(yy6) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Ingress == nil { + r.EncodeNil() + } else { + yym9 := z.EncBinary() + _ = yym9 + if false { + } else { + h.encSliceNetworkPolicyIngressRule(([]NetworkPolicyIngressRule)(x.Ingress), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("ingress")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Ingress == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + h.encSliceNetworkPolicyIngressRule(([]NetworkPolicyIngressRule)(x.Ingress), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicySpec) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicySpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "podSelector": + if r.TryDecodeAsNil() { + x.PodSelector = pkg1_v1.LabelSelector{} + } else { + yyv4 := &x.PodSelector + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(yyv4) { + } else { + z.DecFallback(yyv4, false) + } + } + case "ingress": + if r.TryDecodeAsNil() { + x.Ingress = nil + } else { + yyv6 := &x.Ingress + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSliceNetworkPolicyIngressRule((*[]NetworkPolicyIngressRule)(yyv6), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.PodSelector = pkg1_v1.LabelSelector{} + } else { + yyv9 := &x.PodSelector + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(yyv9) { + } else { + z.DecFallback(yyv9, false) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Ingress = nil + } else { + yyv11 := &x.Ingress + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + h.decSliceNetworkPolicyIngressRule((*[]NetworkPolicyIngressRule)(yyv11), d) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicyIngressRule) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Ports) != 0 + yyq2[1] = len(x.From) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Ports == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSliceNetworkPolicyPort(([]NetworkPolicyPort)(x.Ports), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("ports")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Ports == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSliceNetworkPolicyPort(([]NetworkPolicyPort)(x.Ports), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.From == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encSliceNetworkPolicyPeer(([]NetworkPolicyPeer)(x.From), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("from")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.From == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encSliceNetworkPolicyPeer(([]NetworkPolicyPeer)(x.From), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicyIngressRule) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicyIngressRule) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "ports": + if r.TryDecodeAsNil() { + x.Ports = nil + } else { + yyv4 := &x.Ports + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSliceNetworkPolicyPort((*[]NetworkPolicyPort)(yyv4), d) + } + } + case "from": + if r.TryDecodeAsNil() { + x.From = nil + } else { + yyv6 := &x.From + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSliceNetworkPolicyPeer((*[]NetworkPolicyPeer)(yyv6), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicyIngressRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Ports = nil + } else { + yyv9 := &x.Ports + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + h.decSliceNetworkPolicyPort((*[]NetworkPolicyPort)(yyv9), d) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.From = nil + } else { + yyv11 := &x.From + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + h.decSliceNetworkPolicyPeer((*[]NetworkPolicyPeer)(yyv11), d) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicyPort) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Protocol != nil + yyq2[1] = x.Port != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Protocol == nil { + r.EncodeNil() + } else { + yy4 := *x.Protocol + yysf5 := &yy4 + yysf5.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("protocol")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Protocol == nil { + r.EncodeNil() + } else { + yy6 := *x.Protocol + yysf7 := &yy6 + yysf7.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Port == nil { + r.EncodeNil() + } else { + yym9 := z.EncBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.EncExt(x.Port) { + } else if !yym9 && z.IsJSONHandle() { + z.EncJSONMarshal(x.Port) + } else { + z.EncFallback(x.Port) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("port")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Port == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.Port) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(x.Port) + } else { + z.EncFallback(x.Port) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicyPort) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicyPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "protocol": + if r.TryDecodeAsNil() { + if x.Protocol != nil { + x.Protocol = nil + } + } else { + if x.Protocol == nil { + x.Protocol = new(pkg3_v1.Protocol) + } + x.Protocol.CodecDecodeSelf(d) + } + case "port": + if r.TryDecodeAsNil() { + if x.Port != nil { + x.Port = nil + } + } else { + if x.Port == nil { + x.Port = new(pkg4_intstr.IntOrString) + } + yym6 := z.DecBinary() + _ = yym6 + if false { + } else if z.HasExtensions() && z.DecExt(x.Port) { + } else if !yym6 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.Port) + } else { + z.DecFallback(x.Port, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicyPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Protocol != nil { + x.Protocol = nil + } + } else { + if x.Protocol == nil { + x.Protocol = new(pkg3_v1.Protocol) + } + x.Protocol.CodecDecodeSelf(d) + } + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Port != nil { + x.Port = nil + } + } else { + if x.Port == nil { + x.Port = new(pkg4_intstr.IntOrString) + } + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(x.Port) { + } else if !yym10 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.Port) + } else { + z.DecFallback(x.Port, false) + } + } + for { + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj7-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicyPeer) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.PodSelector != nil + yyq2[1] = x.NamespaceSelector != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.PodSelector == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else if z.HasExtensions() && z.EncExt(x.PodSelector) { + } else { + z.EncFallback(x.PodSelector) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("podSelector")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.PodSelector == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(x.PodSelector) { + } else { + z.EncFallback(x.PodSelector) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.NamespaceSelector == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(x.NamespaceSelector) { + } else { + z.EncFallback(x.NamespaceSelector) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("namespaceSelector")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.NamespaceSelector == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(x.NamespaceSelector) { + } else { + z.EncFallback(x.NamespaceSelector) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicyPeer) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicyPeer) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "podSelector": + if r.TryDecodeAsNil() { + if x.PodSelector != nil { + x.PodSelector = nil + } + } else { + if x.PodSelector == nil { + x.PodSelector = new(pkg1_v1.LabelSelector) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(x.PodSelector) { + } else { + z.DecFallback(x.PodSelector, false) + } + } + case "namespaceSelector": + if r.TryDecodeAsNil() { + if x.NamespaceSelector != nil { + x.NamespaceSelector = nil + } + } else { + if x.NamespaceSelector == nil { + x.NamespaceSelector = new(pkg1_v1.LabelSelector) + } + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(x.NamespaceSelector) { + } else { + z.DecFallback(x.NamespaceSelector, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicyPeer) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.PodSelector != nil { + x.PodSelector = nil + } + } else { + if x.PodSelector == nil { + x.PodSelector = new(pkg1_v1.LabelSelector) + } + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(x.PodSelector) { + } else { + z.DecFallback(x.PodSelector, false) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.NamespaceSelector != nil { + x.NamespaceSelector = nil + } + } else { + if x.NamespaceSelector == nil { + x.NamespaceSelector = new(pkg1_v1.LabelSelector) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.DecExt(x.NamespaceSelector) { + } else { + z.DecFallback(x.NamespaceSelector, false) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicyList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceNetworkPolicy(([]NetworkPolicy)(x.Items), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceNetworkPolicy(([]NetworkPolicy)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicyList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicyList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceNetworkPolicy((*[]NetworkPolicy)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicyList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceNetworkPolicy((*[]NetworkPolicy)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) encSliceNetworkPolicyIngressRule(v []NetworkPolicyIngressRule, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceNetworkPolicyIngressRule(v *[]NetworkPolicyIngressRule, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicyIngressRule{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 48) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]NetworkPolicyIngressRule, yyrl1) + } + } else { + yyv1 = make([]NetworkPolicyIngressRule, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyIngressRule{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicyIngressRule{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyIngressRule{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicyIngressRule{}) // var yyz1 NetworkPolicyIngressRule + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyIngressRule{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicyIngressRule{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceNetworkPolicyPort(v []NetworkPolicyPort, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceNetworkPolicyPort(v *[]NetworkPolicyPort, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicyPort{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]NetworkPolicyPort, yyrl1) + } + } else { + yyv1 = make([]NetworkPolicyPort, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPort{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicyPort{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPort{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicyPort{}) // var yyz1 NetworkPolicyPort + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPort{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicyPort{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceNetworkPolicyPeer(v []NetworkPolicyPeer, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceNetworkPolicyPeer(v *[]NetworkPolicyPeer, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicyPeer{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]NetworkPolicyPeer, yyrl1) + } + } else { + yyv1 = make([]NetworkPolicyPeer, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPeer{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicyPeer{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPeer{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicyPeer{}) // var yyz1 NetworkPolicyPeer + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPeer{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicyPeer{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceNetworkPolicy(v []NetworkPolicy, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceNetworkPolicy(v *[]NetworkPolicy, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicy{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 320) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]NetworkPolicy, yyrl1) + } + } else { + yyv1 = make([]NetworkPolicy, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicy{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicy{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicy{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicy{}) // var yyz1 NetworkPolicy + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicy{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicy{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} diff --git a/pkg/apis/networking/v1/types.go b/pkg/apis/networking/v1/types.go new file mode 100644 index 0000000000000..b5b57d34c9a85 --- /dev/null +++ b/pkg/apis/networking/v1/types.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/intstr" + "k8s.io/kubernetes/pkg/api/v1" +) + +// +genclient=true + +// NetworkPolicy describes what network traffic is allowed for a set of Pods +type NetworkPolicy struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Specification of the desired behavior for this NetworkPolicy. + // +optional + Spec NetworkPolicySpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` +} + +// NetworkPolicySpec provides the specification of a NetworkPolicy +type NetworkPolicySpec struct { + // Selects the pods to which this NetworkPolicy object applies. The array of + // ingress rules is applied to any pods selected by this field. Multiple network + // policies can select the same set of pods. In this case, the ingress rules for + // each are combined additively. This field is NOT optional and follows standard + // label selector semantics. An empty podSelector matches all pods in this + // namespace. + PodSelector metav1.LabelSelector `json:"podSelector" protobuf:"bytes,1,opt,name=podSelector"` + + // List of ingress rules to be applied to the selected pods. Traffic is allowed to + // a pod if there are no NetworkPolicies selecting the pod + // (and cluster policy otherwise allows the traffic), OR if the traffic source is + // the pod's local node, OR if the traffic matches at least one ingress rule + // across all of the NetworkPolicy objects whose podSelector matches the pod. If + // this field is empty then this NetworkPolicy does not allow any traffic (and serves + // solely to ensure that the pods it selects are isolated by default) + // +optional + Ingress []NetworkPolicyIngressRule `json:"ingress,omitempty" protobuf:"bytes,2,rep,name=ingress"` +} + +// NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods +// matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from. +type NetworkPolicyIngressRule struct { + // List of ports which should be made accessible on the pods selected for this + // rule. Each item in this list is combined using a logical OR. If this field is + // empty or missing, this rule matches all ports (traffic not restricted by port). + // If this field is present and contains at least one item, then this rule allows + // traffic only if the traffic matches at least one port in the list. + // +optional + Ports []NetworkPolicyPort `json:"ports,omitempty" protobuf:"bytes,1,rep,name=ports"` + + // List of sources which should be able to access the pods selected for this rule. + // Items in this list are combined using a logical OR operation. If this field is + // empty or missing, this rule matches all sources (traffic not restricted by + // source). If this field is present and contains at least on item, this rule + // allows traffic only if the traffic matches at least one item in the from list. + // +optional + From []NetworkPolicyPeer `json:"from,omitempty" protobuf:"bytes,2,rep,name=from"` +} + +// NetworkPolicyPort describes a port to allow traffic on +type NetworkPolicyPort struct { + // The protocol (TCP or UDP) which traffic must match. If not specified, this + // field defaults to TCP. + // +optional + Protocol *v1.Protocol `json:"protocol,omitempty" protobuf:"bytes,1,opt,name=protocol,casttype=k8s.io/kubernetes/pkg/api/v1.Protocol"` + + // The port on the given protocol. This can either be a numerical or named port on + // a pod. If this field is not provided, this matches all port names and numbers. + // +optional + Port *intstr.IntOrString `json:"port,omitempty" protobuf:"bytes,2,opt,name=port"` +} + +// NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields +// must be specified. +type NetworkPolicyPeer struct { + // This is a label selector which selects Pods in this namespace. This field + // follows standard label selector semantics. If present but empty, this selector + // selects all pods in this namespace. + // +optional + PodSelector *metav1.LabelSelector `json:"podSelector,omitempty" protobuf:"bytes,1,opt,name=podSelector"` + + // Selects Namespaces using cluster scoped-labels. This matches all pods in all + // namespaces selected by this label selector. This field follows standard label + // selector semantics. If present but empty, this selector selects all namespaces. + // +optional + NamespaceSelector *metav1.LabelSelector `json:"namespaceSelector,omitempty" protobuf:"bytes,2,opt,name=namespaceSelector"` +} + +// NetworkPolicyList is a list of NetworkPolicy objects. +type NetworkPolicyList struct { + metav1.TypeMeta `json:",inline"` + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Items is a list of schema objects. + Items []NetworkPolicy `json:"items" protobuf:"bytes,2,rep,name=items"` +} diff --git a/pkg/apis/networking/v1/types_swagger_doc_generated.go b/pkg/apis/networking/v1/types_swagger_doc_generated.go new file mode 100644 index 0000000000000..0df3f14013c96 --- /dev/null +++ b/pkg/apis/networking/v1/types_swagger_doc_generated.go @@ -0,0 +1,90 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +package v1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_NetworkPolicy = map[string]string{ + "": "NetworkPolicy describes what network traffic is allowed for a set of Pods", + "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "spec": "Specification of the desired behavior for this NetworkPolicy.", +} + +func (NetworkPolicy) SwaggerDoc() map[string]string { + return map_NetworkPolicy +} + +var map_NetworkPolicyIngressRule = map[string]string{ + "": "NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from.", + "ports": "List of ports which should be made accessible on the pods selected for this rule. Each item in this list is combined using a logical OR. If this field is empty or missing, this rule matches all ports (traffic not restricted by port). If this field is present and contains at least one item, then this rule allows traffic only if the traffic matches at least one port in the list.", + "from": "List of sources which should be able to access the pods selected for this rule. Items in this list are combined using a logical OR operation. If this field is empty or missing, this rule matches all sources (traffic not restricted by source). If this field is present and contains at least on item, this rule allows traffic only if the traffic matches at least one item in the from list.", +} + +func (NetworkPolicyIngressRule) SwaggerDoc() map[string]string { + return map_NetworkPolicyIngressRule +} + +var map_NetworkPolicyList = map[string]string{ + "": "NetworkPolicyList is a list of NetworkPolicy objects.", + "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "items": "Items is a list of schema objects.", +} + +func (NetworkPolicyList) SwaggerDoc() map[string]string { + return map_NetworkPolicyList +} + +var map_NetworkPolicyPeer = map[string]string{ + "": "NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields must be specified.", + "podSelector": "This is a label selector which selects Pods in this namespace. This field follows standard label selector semantics. If present but empty, this selector selects all pods in this namespace.", + "namespaceSelector": "Selects Namespaces using cluster scoped-labels. This matches all pods in all namespaces selected by this label selector. This field follows standard label selector semantics. If present but empty, this selector selects all namespaces.", +} + +func (NetworkPolicyPeer) SwaggerDoc() map[string]string { + return map_NetworkPolicyPeer +} + +var map_NetworkPolicyPort = map[string]string{ + "": "NetworkPolicyPort describes a port to allow traffic on", + "protocol": "The protocol (TCP or UDP) which traffic must match. If not specified, this field defaults to TCP.", + "port": "The port on the given protocol. This can either be a numerical or named port on a pod. If this field is not provided, this matches all port names and numbers.", +} + +func (NetworkPolicyPort) SwaggerDoc() map[string]string { + return map_NetworkPolicyPort +} + +var map_NetworkPolicySpec = map[string]string{ + "": "NetworkPolicySpec provides the specification of a NetworkPolicy", + "podSelector": "Selects the pods to which this NetworkPolicy object applies. The array of ingress rules is applied to any pods selected by this field. Multiple network policies can select the same set of pods. In this case, the ingress rules for each are combined additively. This field is NOT optional and follows standard label selector semantics. An empty podSelector matches all pods in this namespace.", + "ingress": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod (and cluster policy otherwise allows the traffic), OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default)", +} + +func (NetworkPolicySpec) SwaggerDoc() map[string]string { + return map_NetworkPolicySpec +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/pkg/apis/networking/v1/zz_generated.conversion.go b/pkg/apis/networking/v1/zz_generated.conversion.go new file mode 100644 index 0000000000000..b011eb90ab3cc --- /dev/null +++ b/pkg/apis/networking/v1/zz_generated.conversion.go @@ -0,0 +1,195 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" + api "k8s.io/kubernetes/pkg/api" + api_v1 "k8s.io/kubernetes/pkg/api/v1" + networking "k8s.io/kubernetes/pkg/apis/networking" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v1_NetworkPolicy_To_networking_NetworkPolicy, + Convert_networking_NetworkPolicy_To_v1_NetworkPolicy, + Convert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule, + Convert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule, + Convert_v1_NetworkPolicyList_To_networking_NetworkPolicyList, + Convert_networking_NetworkPolicyList_To_v1_NetworkPolicyList, + Convert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer, + Convert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer, + Convert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort, + Convert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort, + Convert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec, + Convert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec, + ) +} + +func autoConvert_v1_NetworkPolicy_To_networking_NetworkPolicy(in *NetworkPolicy, out *networking.NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + return nil +} + +// Convert_v1_NetworkPolicy_To_networking_NetworkPolicy is an autogenerated conversion function. +func Convert_v1_NetworkPolicy_To_networking_NetworkPolicy(in *NetworkPolicy, out *networking.NetworkPolicy, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicy_To_networking_NetworkPolicy(in, out, s) +} + +func autoConvert_networking_NetworkPolicy_To_v1_NetworkPolicy(in *networking.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + return nil +} + +// Convert_networking_NetworkPolicy_To_v1_NetworkPolicy is an autogenerated conversion function. +func Convert_networking_NetworkPolicy_To_v1_NetworkPolicy(in *networking.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicy_To_v1_NetworkPolicy(in, out, s) +} + +func autoConvert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(in *NetworkPolicyIngressRule, out *networking.NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = *(*[]networking.NetworkPolicyPort)(unsafe.Pointer(&in.Ports)) + out.From = *(*[]networking.NetworkPolicyPeer)(unsafe.Pointer(&in.From)) + return nil +} + +// Convert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule is an autogenerated conversion function. +func Convert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(in *NetworkPolicyIngressRule, out *networking.NetworkPolicyIngressRule, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(in, out, s) +} + +func autoConvert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(in *networking.NetworkPolicyIngressRule, out *NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = *(*[]NetworkPolicyPort)(unsafe.Pointer(&in.Ports)) + out.From = *(*[]NetworkPolicyPeer)(unsafe.Pointer(&in.From)) + return nil +} + +// Convert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule is an autogenerated conversion function. +func Convert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(in *networking.NetworkPolicyIngressRule, out *NetworkPolicyIngressRule, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(in, out, s) +} + +func autoConvert_v1_NetworkPolicyList_To_networking_NetworkPolicyList(in *NetworkPolicyList, out *networking.NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]networking.NetworkPolicy)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1_NetworkPolicyList_To_networking_NetworkPolicyList is an autogenerated conversion function. +func Convert_v1_NetworkPolicyList_To_networking_NetworkPolicyList(in *NetworkPolicyList, out *networking.NetworkPolicyList, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicyList_To_networking_NetworkPolicyList(in, out, s) +} + +func autoConvert_networking_NetworkPolicyList_To_v1_NetworkPolicyList(in *networking.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]NetworkPolicy, 0) + } else { + out.Items = *(*[]NetworkPolicy)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_networking_NetworkPolicyList_To_v1_NetworkPolicyList is an autogenerated conversion function. +func Convert_networking_NetworkPolicyList_To_v1_NetworkPolicyList(in *networking.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicyList_To_v1_NetworkPolicyList(in, out, s) +} + +func autoConvert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(in *NetworkPolicyPeer, out *networking.NetworkPolicyPeer, s conversion.Scope) error { + out.PodSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.PodSelector)) + out.NamespaceSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.NamespaceSelector)) + return nil +} + +// Convert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer is an autogenerated conversion function. +func Convert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(in *NetworkPolicyPeer, out *networking.NetworkPolicyPeer, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(in, out, s) +} + +func autoConvert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(in *networking.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { + out.PodSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.PodSelector)) + out.NamespaceSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.NamespaceSelector)) + return nil +} + +// Convert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer is an autogenerated conversion function. +func Convert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(in *networking.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(in, out, s) +} + +func autoConvert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort(in *NetworkPolicyPort, out *networking.NetworkPolicyPort, s conversion.Scope) error { + out.Protocol = (*api.Protocol)(unsafe.Pointer(in.Protocol)) + out.Port = (*intstr.IntOrString)(unsafe.Pointer(in.Port)) + return nil +} + +// Convert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort is an autogenerated conversion function. +func Convert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort(in *NetworkPolicyPort, out *networking.NetworkPolicyPort, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort(in, out, s) +} + +func autoConvert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort(in *networking.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { + out.Protocol = (*api_v1.Protocol)(unsafe.Pointer(in.Protocol)) + out.Port = (*intstr.IntOrString)(unsafe.Pointer(in.Port)) + return nil +} + +// Convert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort is an autogenerated conversion function. +func Convert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort(in *networking.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort(in, out, s) +} + +func autoConvert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec(in *NetworkPolicySpec, out *networking.NetworkPolicySpec, s conversion.Scope) error { + out.PodSelector = in.PodSelector + out.Ingress = *(*[]networking.NetworkPolicyIngressRule)(unsafe.Pointer(&in.Ingress)) + return nil +} + +// Convert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec is an autogenerated conversion function. +func Convert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec(in *NetworkPolicySpec, out *networking.NetworkPolicySpec, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec(in, out, s) +} + +func autoConvert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec(in *networking.NetworkPolicySpec, out *NetworkPolicySpec, s conversion.Scope) error { + out.PodSelector = in.PodSelector + out.Ingress = *(*[]NetworkPolicyIngressRule)(unsafe.Pointer(&in.Ingress)) + return nil +} + +// Convert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec is an autogenerated conversion function. +func Convert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec(in *networking.NetworkPolicySpec, out *NetworkPolicySpec, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec(in, out, s) +} diff --git a/pkg/apis/networking/v1/zz_generated.deepcopy.go b/pkg/apis/networking/v1/zz_generated.deepcopy.go new file mode 100644 index 0000000000000..38ef883463928 --- /dev/null +++ b/pkg/apis/networking/v1/zz_generated.deepcopy.go @@ -0,0 +1,182 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" + api_v1 "k8s.io/kubernetes/pkg/api/v1" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicy, InType: reflect.TypeOf(&NetworkPolicy{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicyIngressRule, InType: reflect.TypeOf(&NetworkPolicyIngressRule{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicyList, InType: reflect.TypeOf(&NetworkPolicyList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicyPeer, InType: reflect.TypeOf(&NetworkPolicyPeer{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicyPort, InType: reflect.TypeOf(&NetworkPolicyPort{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicySpec, InType: reflect.TypeOf(&NetworkPolicySpec{})}, + ) +} + +// DeepCopy_v1_NetworkPolicy is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicy(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicy) + out := out.(*NetworkPolicy) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) + } + if err := DeepCopy_v1_NetworkPolicySpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicyIngressRule is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicyIngressRule(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyIngressRule) + out := out.(*NetworkPolicyIngressRule) + *out = *in + if in.Ports != nil { + in, out := &in.Ports, &out.Ports + *out = make([]NetworkPolicyPort, len(*in)) + for i := range *in { + if err := DeepCopy_v1_NetworkPolicyPort(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.From != nil { + in, out := &in.From, &out.From + *out = make([]NetworkPolicyPeer, len(*in)) + for i := range *in { + if err := DeepCopy_v1_NetworkPolicyPeer(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicyList is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicyList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyList) + out := out.(*NetworkPolicyList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]NetworkPolicy, len(*in)) + for i := range *in { + if err := DeepCopy_v1_NetworkPolicy(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicyPeer is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicyPeer(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyPeer) + out := out.(*NetworkPolicyPeer) + *out = *in + if in.PodSelector != nil { + in, out := &in.PodSelector, &out.PodSelector + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*meta_v1.LabelSelector) + } + } + if in.NamespaceSelector != nil { + in, out := &in.NamespaceSelector, &out.NamespaceSelector + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*meta_v1.LabelSelector) + } + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicyPort is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicyPort(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyPort) + out := out.(*NetworkPolicyPort) + *out = *in + if in.Protocol != nil { + in, out := &in.Protocol, &out.Protocol + *out = new(api_v1.Protocol) + **out = **in + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(intstr.IntOrString) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicySpec is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicySpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicySpec) + out := out.(*NetworkPolicySpec) + *out = *in + if newVal, err := c.DeepCopy(&in.PodSelector); err != nil { + return err + } else { + out.PodSelector = *newVal.(*meta_v1.LabelSelector) + } + if in.Ingress != nil { + in, out := &in.Ingress, &out.Ingress + *out = make([]NetworkPolicyIngressRule, len(*in)) + for i := range *in { + if err := DeepCopy_v1_NetworkPolicyIngressRule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} diff --git a/pkg/apis/networking/v1/zz_generated.defaults.go b/pkg/apis/networking/v1/zz_generated.defaults.go new file mode 100644 index 0000000000000..0319c88a76f7d --- /dev/null +++ b/pkg/apis/networking/v1/zz_generated.defaults.go @@ -0,0 +1,51 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + scheme.AddTypeDefaultingFunc(&NetworkPolicy{}, func(obj interface{}) { SetObjectDefaults_NetworkPolicy(obj.(*NetworkPolicy)) }) + scheme.AddTypeDefaultingFunc(&NetworkPolicyList{}, func(obj interface{}) { SetObjectDefaults_NetworkPolicyList(obj.(*NetworkPolicyList)) }) + return nil +} + +func SetObjectDefaults_NetworkPolicy(in *NetworkPolicy) { + for i := range in.Spec.Ingress { + a := &in.Spec.Ingress[i] + for j := range a.Ports { + b := &a.Ports[j] + SetDefaults_NetworkPolicyPort(b) + } + } +} + +func SetObjectDefaults_NetworkPolicyList(in *NetworkPolicyList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_NetworkPolicy(a) + } +} diff --git a/pkg/apis/networking/validation/BUILD b/pkg/apis/networking/validation/BUILD new file mode 100644 index 0000000000000..534c0b5e2950f --- /dev/null +++ b/pkg/apis/networking/validation/BUILD @@ -0,0 +1,50 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["validation_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/networking:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = ["validation.go"], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/api/validation:go_default_library", + "//pkg/apis/networking:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1/validation:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation/field:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/apis/networking/validation/validation.go b/pkg/apis/networking/validation/validation.go new file mode 100644 index 0000000000000..e2db31430fe88 --- /dev/null +++ b/pkg/apis/networking/validation/validation.go @@ -0,0 +1,99 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package validation + +import ( + "reflect" + + unversionedvalidation "k8s.io/apimachinery/pkg/apis/meta/v1/validation" + "k8s.io/apimachinery/pkg/util/intstr" + "k8s.io/apimachinery/pkg/util/validation" + "k8s.io/apimachinery/pkg/util/validation/field" + "k8s.io/kubernetes/pkg/api" + apivalidation "k8s.io/kubernetes/pkg/api/validation" + "k8s.io/kubernetes/pkg/apis/networking" +) + +// ValidateNetworkPolicyName can be used to check whether the given networkpolicy +// name is valid. +func ValidateNetworkPolicyName(name string, prefix bool) []string { + return apivalidation.NameIsDNSSubdomain(name, prefix) +} + +// ValidateNetworkPolicySpec tests if required fields in the networkpolicy spec are set. +func ValidateNetworkPolicySpec(spec *networking.NetworkPolicySpec, fldPath *field.Path) field.ErrorList { + allErrs := field.ErrorList{} + allErrs = append(allErrs, unversionedvalidation.ValidateLabelSelector(&spec.PodSelector, fldPath.Child("podSelector"))...) + + // Validate ingress rules. + for i, ingress := range spec.Ingress { + ingressPath := fldPath.Child("ingress").Index(i) + for i, port := range ingress.Ports { + portPath := ingressPath.Child("ports").Index(i) + if port.Protocol != nil && *port.Protocol != api.ProtocolTCP && *port.Protocol != api.ProtocolUDP { + allErrs = append(allErrs, field.NotSupported(portPath.Child("protocol"), *port.Protocol, []string{string(api.ProtocolTCP), string(api.ProtocolUDP)})) + } + if port.Port != nil { + if port.Port.Type == intstr.Int { + for _, msg := range validation.IsValidPortNum(int(port.Port.IntVal)) { + allErrs = append(allErrs, field.Invalid(portPath.Child("port"), port.Port.IntVal, msg)) + } + } else { + for _, msg := range validation.IsValidPortName(port.Port.StrVal) { + allErrs = append(allErrs, field.Invalid(portPath.Child("port"), port.Port.StrVal, msg)) + } + } + } + } + for i, from := range ingress.From { + fromPath := ingressPath.Child("from").Index(i) + numFroms := 0 + if from.PodSelector != nil { + numFroms++ + allErrs = append(allErrs, unversionedvalidation.ValidateLabelSelector(from.PodSelector, fromPath.Child("podSelector"))...) + } + if from.NamespaceSelector != nil { + numFroms++ + allErrs = append(allErrs, unversionedvalidation.ValidateLabelSelector(from.NamespaceSelector, fromPath.Child("namespaceSelector"))...) + } + + if numFroms == 0 { + allErrs = append(allErrs, field.Required(fromPath, "must specify a from type")) + } else if numFroms > 1 { + allErrs = append(allErrs, field.Forbidden(fromPath, "may not specify more than 1 from type")) + } + } + } + return allErrs +} + +// ValidateNetworkPolicy validates a networkpolicy. +func ValidateNetworkPolicy(np *networking.NetworkPolicy) field.ErrorList { + allErrs := apivalidation.ValidateObjectMeta(&np.ObjectMeta, true, ValidateNetworkPolicyName, field.NewPath("metadata")) + allErrs = append(allErrs, ValidateNetworkPolicySpec(&np.Spec, field.NewPath("spec"))...) + return allErrs +} + +// ValidateNetworkPolicyUpdate tests if an update to a NetworkPolicy is valid. +func ValidateNetworkPolicyUpdate(update, old *networking.NetworkPolicy) field.ErrorList { + allErrs := field.ErrorList{} + allErrs = append(allErrs, apivalidation.ValidateObjectMetaUpdate(&update.ObjectMeta, &old.ObjectMeta, field.NewPath("metadata"))...) + if !reflect.DeepEqual(update.Spec, old.Spec) { + allErrs = append(allErrs, field.Forbidden(field.NewPath("spec"), "updates to networkpolicy spec are forbidden.")) + } + return allErrs +} diff --git a/pkg/apis/networking/validation/validation_test.go b/pkg/apis/networking/validation/validation_test.go new file mode 100644 index 0000000000000..6001d5bc4e6fd --- /dev/null +++ b/pkg/apis/networking/validation/validation_test.go @@ -0,0 +1,346 @@ +/* +Copyright 2014 The Kubernetes 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. +*/ + +package validation + +import ( + "testing" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/intstr" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/networking" +) + +func TestValidateNetworkPolicy(t *testing.T) { + protocolTCP := api.ProtocolTCP + protocolUDP := api.ProtocolUDP + protocolICMP := api.Protocol("ICMP") + + successCases := []networking.NetworkPolicy{ + { + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{ + MatchLabels: map[string]string{"a": "b"}, + }, + Ingress: []networking.NetworkPolicyIngressRule{}, + }, + }, + { + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{ + MatchLabels: map[string]string{"a": "b"}, + }, + Ingress: []networking.NetworkPolicyIngressRule{ + { + From: []networking.NetworkPolicyPeer{}, + Ports: []networking.NetworkPolicyPort{}, + }, + }, + }, + }, + { + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{ + MatchLabels: map[string]string{"a": "b"}, + }, + Ingress: []networking.NetworkPolicyIngressRule{ + { + Ports: []networking.NetworkPolicyPort{ + { + Protocol: nil, + Port: &intstr.IntOrString{Type: intstr.Int, IntVal: 80}, + }, + { + Protocol: &protocolTCP, + Port: nil, + }, + { + Protocol: &protocolTCP, + Port: &intstr.IntOrString{Type: intstr.Int, IntVal: 443}, + }, + { + Protocol: &protocolUDP, + Port: &intstr.IntOrString{Type: intstr.String, StrVal: "dns"}, + }, + }, + }, + }, + }, + }, + { + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{ + MatchLabels: map[string]string{"a": "b"}, + }, + Ingress: []networking.NetworkPolicyIngressRule{ + { + From: []networking.NetworkPolicyPeer{ + { + PodSelector: &metav1.LabelSelector{ + MatchLabels: map[string]string{"c": "d"}, + }, + }, + }, + }, + }, + }, + }, + { + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{ + MatchLabels: map[string]string{"a": "b"}, + }, + Ingress: []networking.NetworkPolicyIngressRule{ + { + From: []networking.NetworkPolicyPeer{ + { + NamespaceSelector: &metav1.LabelSelector{ + MatchLabels: map[string]string{"c": "d"}, + }, + }, + }, + }, + }, + }, + }, + } + + // Success cases are expected to pass validation. + for k, v := range successCases { + if errs := ValidateNetworkPolicy(&v); len(errs) != 0 { + t.Errorf("Expected success for %d, got %v", k, errs) + } + } + + invalidSelector := map[string]string{"NoUppercaseOrSpecialCharsLike=Equals": "b"} + errorCases := map[string]networking.NetworkPolicy{ + "namespaceSelector and podSelector": { + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{ + MatchLabels: map[string]string{"a": "b"}, + }, + Ingress: []networking.NetworkPolicyIngressRule{ + { + From: []networking.NetworkPolicyPeer{ + { + PodSelector: &metav1.LabelSelector{ + MatchLabels: map[string]string{"c": "d"}, + }, + NamespaceSelector: &metav1.LabelSelector{ + MatchLabels: map[string]string{"c": "d"}, + }, + }, + }, + }, + }, + }, + }, + "invalid spec.podSelector": { + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{ + MatchLabels: invalidSelector, + }, + Ingress: []networking.NetworkPolicyIngressRule{ + { + From: []networking.NetworkPolicyPeer{ + { + NamespaceSelector: &metav1.LabelSelector{ + MatchLabels: map[string]string{"c": "d"}, + }, + }, + }, + }, + }, + }, + }, + "invalid ingress.ports.protocol": { + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{}, + Ingress: []networking.NetworkPolicyIngressRule{ + { + Ports: []networking.NetworkPolicyPort{ + { + Protocol: &protocolICMP, + Port: &intstr.IntOrString{Type: intstr.Int, IntVal: 80}, + }, + }, + }, + }, + }, + }, + "invalid ingress.ports.port (int)": { + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{}, + Ingress: []networking.NetworkPolicyIngressRule{ + { + Ports: []networking.NetworkPolicyPort{ + { + Protocol: &protocolTCP, + Port: &intstr.IntOrString{Type: intstr.Int, IntVal: 123456789}, + }, + }, + }, + }, + }, + }, + "invalid ingress.ports.port (str)": { + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{}, + Ingress: []networking.NetworkPolicyIngressRule{ + { + Ports: []networking.NetworkPolicyPort{ + { + Protocol: &protocolTCP, + Port: &intstr.IntOrString{Type: intstr.String, StrVal: "!@#$"}, + }, + }, + }, + }, + }, + }, + "invalid ingress.from.podSelector": { + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{}, + Ingress: []networking.NetworkPolicyIngressRule{ + { + From: []networking.NetworkPolicyPeer{ + { + PodSelector: &metav1.LabelSelector{ + MatchLabels: invalidSelector, + }, + }, + }, + }, + }, + }, + }, + "invalid ingress.from.namespaceSelector": { + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{}, + Ingress: []networking.NetworkPolicyIngressRule{ + { + From: []networking.NetworkPolicyPeer{ + { + NamespaceSelector: &metav1.LabelSelector{ + MatchLabels: invalidSelector, + }, + }, + }, + }, + }, + }, + }, + } + + // Error cases are not expected to pass validation. + for testName, networkPolicy := range errorCases { + if errs := ValidateNetworkPolicy(&networkPolicy); len(errs) == 0 { + t.Errorf("Expected failure for test: %s", testName) + } + } +} + +func TestValidateNetworkPolicyUpdate(t *testing.T) { + type npUpdateTest struct { + old networking.NetworkPolicy + update networking.NetworkPolicy + } + successCases := []npUpdateTest{ + { + old: networking.NetworkPolicy{ + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{ + MatchLabels: map[string]string{"a": "b"}, + }, + Ingress: []networking.NetworkPolicyIngressRule{}, + }, + }, + update: networking.NetworkPolicy{ + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{ + MatchLabels: map[string]string{"a": "b"}, + }, + Ingress: []networking.NetworkPolicyIngressRule{}, + }, + }, + }, + } + + for _, successCase := range successCases { + successCase.old.ObjectMeta.ResourceVersion = "1" + successCase.update.ObjectMeta.ResourceVersion = "1" + if errs := ValidateNetworkPolicyUpdate(&successCase.update, &successCase.old); len(errs) != 0 { + t.Errorf("expected success: %v", errs) + } + } + errorCases := map[string]npUpdateTest{ + "change name": { + old: networking.NetworkPolicy{ + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{}, + Ingress: []networking.NetworkPolicyIngressRule{}, + }, + }, + update: networking.NetworkPolicy{ + ObjectMeta: metav1.ObjectMeta{Name: "baz", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{}, + Ingress: []networking.NetworkPolicyIngressRule{}, + }, + }, + }, + "change spec": { + old: networking.NetworkPolicy{ + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{}, + Ingress: []networking.NetworkPolicyIngressRule{}, + }, + }, + update: networking.NetworkPolicy{ + ObjectMeta: metav1.ObjectMeta{Name: "foo", Namespace: "bar"}, + Spec: networking.NetworkPolicySpec{ + PodSelector: metav1.LabelSelector{ + MatchLabels: map[string]string{"a": "b"}, + }, + Ingress: []networking.NetworkPolicyIngressRule{}, + }, + }, + }, + } + + for testName, errorCase := range errorCases { + if errs := ValidateNetworkPolicyUpdate(&errorCase.update, &errorCase.old); len(errs) == 0 { + t.Errorf("expected failure: %s", testName) + } + } +} diff --git a/pkg/apis/networking/zz_generated.deepcopy.go b/pkg/apis/networking/zz_generated.deepcopy.go new file mode 100644 index 0000000000000..0cec26223f97a --- /dev/null +++ b/pkg/apis/networking/zz_generated.deepcopy.go @@ -0,0 +1,182 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package networking + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" + api "k8s.io/kubernetes/pkg/api" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicy, InType: reflect.TypeOf(&NetworkPolicy{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicyIngressRule, InType: reflect.TypeOf(&NetworkPolicyIngressRule{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicyList, InType: reflect.TypeOf(&NetworkPolicyList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicyPeer, InType: reflect.TypeOf(&NetworkPolicyPeer{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicyPort, InType: reflect.TypeOf(&NetworkPolicyPort{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicySpec, InType: reflect.TypeOf(&NetworkPolicySpec{})}, + ) +} + +// DeepCopy_networking_NetworkPolicy is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicy(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicy) + out := out.(*NetworkPolicy) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if err := DeepCopy_networking_NetworkPolicySpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicyIngressRule is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicyIngressRule(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyIngressRule) + out := out.(*NetworkPolicyIngressRule) + *out = *in + if in.Ports != nil { + in, out := &in.Ports, &out.Ports + *out = make([]NetworkPolicyPort, len(*in)) + for i := range *in { + if err := DeepCopy_networking_NetworkPolicyPort(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.From != nil { + in, out := &in.From, &out.From + *out = make([]NetworkPolicyPeer, len(*in)) + for i := range *in { + if err := DeepCopy_networking_NetworkPolicyPeer(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicyList is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicyList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyList) + out := out.(*NetworkPolicyList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]NetworkPolicy, len(*in)) + for i := range *in { + if err := DeepCopy_networking_NetworkPolicy(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicyPeer is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicyPeer(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyPeer) + out := out.(*NetworkPolicyPeer) + *out = *in + if in.PodSelector != nil { + in, out := &in.PodSelector, &out.PodSelector + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*v1.LabelSelector) + } + } + if in.NamespaceSelector != nil { + in, out := &in.NamespaceSelector, &out.NamespaceSelector + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*v1.LabelSelector) + } + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicyPort is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicyPort(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyPort) + out := out.(*NetworkPolicyPort) + *out = *in + if in.Protocol != nil { + in, out := &in.Protocol, &out.Protocol + *out = new(api.Protocol) + **out = **in + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(intstr.IntOrString) + **out = **in + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicySpec is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicySpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicySpec) + out := out.(*NetworkPolicySpec) + *out = *in + if newVal, err := c.DeepCopy(&in.PodSelector); err != nil { + return err + } else { + out.PodSelector = *newVal.(*v1.LabelSelector) + } + if in.Ingress != nil { + in, out := &in.Ingress, &out.Ingress + *out = make([]NetworkPolicyIngressRule, len(*in)) + for i := range *in { + if err := DeepCopy_networking_NetworkPolicyIngressRule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} diff --git a/pkg/apis/policy/v1beta1/generated.pb.go b/pkg/apis/policy/v1beta1/generated.pb.go index 9744516323a5a..3d7d88817234c 100644 --- a/pkg/apis/policy/v1beta1/generated.pb.go +++ b/pkg/apis/policy/v1beta1/generated.pb.go @@ -1394,56 +1394,55 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 805 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x94, 0xdf, 0x6e, 0xe3, 0x44, - 0x14, 0xc6, 0xe3, 0xa6, 0x29, 0x65, 0x36, 0x89, 0xca, 0xc0, 0x42, 0x89, 0x84, 0x83, 0x72, 0xb5, - 0x8b, 0x60, 0x4c, 0x77, 0x11, 0x2a, 0x5c, 0xac, 0x58, 0x93, 0x0a, 0x16, 0x6d, 0xd5, 0xd5, 0x14, - 0x84, 0x84, 0x40, 0x62, 0x6c, 0x9f, 0x75, 0x87, 0x8c, 0xff, 0x68, 0x3c, 0x0e, 0xcd, 0x1d, 0x8f, - 0xc0, 0x05, 0x0f, 0x55, 0x09, 0x09, 0xed, 0x25, 0x42, 0x28, 0xa2, 0xe6, 0x19, 0xb8, 0x47, 0x1e, - 0x4f, 0x9a, 0xb8, 0x49, 0xb4, 0x81, 0x22, 0xee, 0x3c, 0x33, 0xe7, 0xf7, 0x7d, 0xe7, 0x9c, 0x39, - 0x63, 0xf4, 0xc1, 0xe8, 0x30, 0x23, 0x3c, 0x71, 0x46, 0xb9, 0x07, 0x32, 0x06, 0x05, 0x99, 0x93, - 0x8e, 0x42, 0x87, 0xa5, 0x3c, 0x73, 0xd2, 0x44, 0x70, 0x7f, 0xe2, 0x8c, 0x0f, 0x3c, 0x50, 0xec, - 0xc0, 0x09, 0x21, 0x06, 0xc9, 0x14, 0x04, 0x24, 0x95, 0x89, 0x4a, 0xf0, 0xdd, 0x0a, 0x25, 0x73, - 0x94, 0xa4, 0xa3, 0x90, 0x94, 0x28, 0xa9, 0x50, 0x62, 0xd0, 0xde, 0x3b, 0x21, 0x57, 0x67, 0xb9, - 0x47, 0xfc, 0x24, 0x72, 0xc2, 0x24, 0x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 0x74, 0xfb, 0x68, 0xe1, 0x8c, 0xd6, 0x22, 0x7b, 0x02, 0xe1, - 0xe5, 0x26, 0xe2, 0x3d, 0xd4, 0x1c, 0xc1, 0x44, 0x5f, 0xf9, 0x8b, 0xb4, 0xfc, 0xc4, 0x1f, 0xa1, - 0xd6, 0x98, 0x89, 0x1c, 0xcc, 0xec, 0xbf, 0xb5, 0xd9, 0xec, 0x7f, 0xce, 0x23, 0xa0, 0x15, 0xf8, - 0xe1, 0xd6, 0xa1, 0xe5, 0xde, 0xbd, 0xb8, 0xb4, 0x1b, 0xcf, 0x2e, 0xed, 0xc6, 0xaf, 0x97, 0x76, - 0xe3, 0x87, 0xc2, 0xb6, 0x2e, 0x0a, 0xdb, 0x7a, 0x56, 0xd8, 0xd6, 0x1f, 0x85, 0x6d, 0xfd, 0xf8, - 0xa7, 0xdd, 0xf8, 0xea, 0x05, 0x73, 0xe9, 0x7f, 0x07, 0x00, 0x00, 0xff, 0xff, 0xc4, 0xc0, 0x72, - 0x96, 0xcb, 0x08, 0x00, 0x00, + // 787 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x94, 0x4b, 0x6f, 0xeb, 0x44, + 0x14, 0xc7, 0xe3, 0x3c, 0x4a, 0x98, 0x9b, 0x44, 0x65, 0xe0, 0x42, 0x88, 0x84, 0x83, 0xb2, 0xba, + 0x17, 0xc1, 0x98, 0xde, 0x8b, 0x50, 0x61, 0x51, 0x51, 0x93, 0x0a, 0x8a, 0x1a, 0xa5, 0x9a, 0x82, + 0x90, 0x10, 0x48, 0x8c, 0xed, 0x53, 0x67, 0x88, 0x5f, 0xb2, 0xc7, 0xa1, 0xd9, 0xf1, 0x11, 0x58, + 0xf0, 0xa1, 0x2a, 0x21, 0xa1, 0x2e, 0x11, 0x42, 0x11, 0x35, 0x9f, 0x81, 0x3d, 0xb2, 0x3d, 0x79, + 0xb8, 0x49, 0xd4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x86, 0x54, 0x78, 0x5c, 0xf0, 0x9d, 0x5f, 0xa2, 0x1b, 0x40, 0x7c, 0x84, 0x5a, 0x66, + 0x1c, 0x86, 0xe0, 0x89, 0x4f, 0x81, 0x39, 0x62, 0x34, 0x6d, 0x57, 0x33, 0xa9, 0x57, 0xa5, 0x54, + 0xeb, 0xe3, 0xc2, 0x29, 0xbd, 0x73, 0x3b, 0xe5, 0x2d, 0x88, 0x78, 0x08, 0xd6, 0x9c, 0xaf, 0x15, + 0xf9, 0x7e, 0xe1, 0x94, 0xde, 0xb9, 0x8d, 0x0f, 0x51, 0x03, 0xae, 0x02, 0x30, 0xe7, 0x19, 0xef, + 0x65, 0xf4, 0x2b, 0x92, 0x6e, 0x9c, 0xac, 0x9c, 0xd1, 0xc2, 0xcd, 0x8e, 0x83, 0xf0, 0x7a, 0x88, + 0x78, 0x1f, 0x55, 0xc6, 0x30, 0xcd, 0x3e, 0xf9, 0x8b, 0x34, 0xfd, 0x89, 0x3f, 0x42, 0xb5, 0x09, + 0x73, 0x62, 0x90, 0xb3, 0xff, 0xd6, 0x6e, 0xb3, 0xff, 0x39, 0x77, 0x81, 0xe6, 0xe0, 0x87, 0xe5, + 0x43, 0x45, 0x7f, 0x7a, 0x7d, 0xab, 0x96, 0x6e, 0x6e, 0xd5, 0xd2, 0xaf, 0xb7, 0x6a, 0xe9, 0x87, + 0x44, 0x55, 0xae, 0x13, 0x55, 0xb9, 0x49, 0x54, 0xe5, 0x8f, 0x44, 0x55, 0x7e, 0xfc, 0x53, 0x2d, + 0x7d, 0xf5, 0x82, 0xfc, 0xe8, 0x7f, 0x07, 0x00, 0x00, 0xff, 0xff, 0xff, 0x18, 0xbb, 0x8c, 0x95, + 0x08, 0x00, 0x00, } diff --git a/pkg/apis/policy/v1beta1/generated.proto b/pkg/apis/policy/v1beta1/generated.proto index 3350c06c39c66..be840713fba99 100644 --- a/pkg/apis/policy/v1beta1/generated.proto +++ b/pkg/apis/policy/v1beta1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; // Package-wide variables from generator "generated". diff --git a/pkg/apis/rbac/v1alpha1/generated.pb.go b/pkg/apis/rbac/v1alpha1/generated.pb.go index d79580ee8bbd2..2e4b12a43791f 100644 --- a/pkg/apis/rbac/v1alpha1/generated.pb.go +++ b/pkg/apis/rbac/v1alpha1/generated.pb.go @@ -2766,58 +2766,57 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 841 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x54, 0x4d, 0x6f, 0xe3, 0x44, - 0x18, 0xce, 0xb4, 0x09, 0x4d, 0xde, 0x52, 0x95, 0x0e, 0x12, 0x32, 0x3d, 0x38, 0x95, 0x4f, 0x15, + // 826 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x54, 0xcf, 0x6f, 0xe3, 0x44, + 0x14, 0xce, 0xb4, 0x09, 0x4d, 0x5e, 0xa9, 0x4a, 0x07, 0x09, 0x99, 0x1e, 0x9c, 0xca, 0xa7, 0x8a, 0x1f, 0x36, 0x2d, 0x0b, 0xec, 0x01, 0x0e, 0x6b, 0x0e, 0xa8, 0x62, 0x29, 0xd5, 0xac, 0x58, 0x89, - 0xd5, 0x4a, 0x30, 0x71, 0x66, 0x93, 0x21, 0xfe, 0xd2, 0x8c, 0x1d, 0xb1, 0x42, 0x48, 0x1c, 0x39, - 0xf2, 0x2b, 0x38, 0x72, 0x40, 0xe2, 0xc8, 0x89, 0x4b, 0x05,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7, 0x66, 0xe7, 0x9b, 0xcc, 0x44, 0xa7, 0x99, 0x89, 0xce, 0x32, 0x13, 0xfd, - 0x99, 0x99, 0xe8, 0xbb, 0xbf, 0xcc, 0xce, 0xa3, 0x7e, 0x79, 0xf1, 0xff, 0x04, 0x00, 0x00, 0xff, - 0xff, 0x22, 0x38, 0x96, 0xd3, 0x59, 0x0c, 0x00, 0x00, + 0xd5, 0x4a, 0x30, 0x71, 0x66, 0x93, 0x21, 0xfe, 0xa5, 0x19, 0x3b, 0xd2, 0x0a, 0x21, 0x71, 0xe4, + 0xc8, 0x5f, 0xc1, 0x91, 0x03, 0x12, 0x47, 0x4e, 0x5c, 0x2a, 0xb8, 0xec, 0x11, 0x2e, 0x11, 0x35, + 0x7f, 0x08, 0xc8, 0xe3, 0xf1, 0x8f, 0x34, 0xa9, 0x9a, 0x16, 0x29, 0x12, 0xd2, 0x9e, 0x12, 0xbf, + 0xf7, 0x7d, 0xdf, 0xbc, 0x6f, 0x9e, 0xfd, 0xc1, 0xdd, 0xc9, 0x5d, 0x69, 0xf3, 0xc8, 0x99, 0xa4, + 0x03, 0x26, 0x42, 0x96, 0x30, 0xe9, 0xc4, 0x93, 0x91, 0x43, 0x63, 0x2e, 0x1d, 0x31, 0xa0, 0x9e, + 0x33, 0x3d, 0xa2, 0x7e, 0x3c, 0xa6, 0x47, 0xce, 0x88, 0x85, 0x4c, 0xd0, 0x84, 0x0d, 0xed, 0x58, + 0x44, 0x49, 0x84, 0x0f, 0x0b, 0xa6, 0x5d, 0x33, 0xed, 0x78, 0x32, 0xb2, 0x73, 0xa6, 0x9d, 0x33, + 0xed, 0x92, 0xb9, 0xff, 0xe6, 0x88, 0x27, 0xe3, 0x74, 0x60, 0x7b, 0x51, 0xe0, 0x8c, 0xa2, 0x51, + 0xe4, 0x28, 0x81, 0x41, 0xfa, 0x44, 0x3d, 0xa9, 0x07, 0xf5, 0xaf, 0x10, 0xde, 0xbf, 0xa3, 0x47, + 0xa2, 0x31, 0x0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 0x1f, 0xc3, 0x96, 0x88, 0x7c, 0x46, 0xd8, 0x13, + 0x63, 0x53, 0x39, 0xb8, 0x81, 0x3e, 0x29, 0x88, 0xee, 0xae, 0xd6, 0xdf, 0xd2, 0x05, 0x52, 0x4a, + 0x5a, 0x3f, 0x20, 0x78, 0x75, 0xf1, 0xde, 0xdc, 0x94, 0xfb, 0x43, 0x26, 0xf0, 0x77, 0x08, 0xb0, + 0xb7, 0xd0, 0xd5, 0x37, 0xf9, 0xfe, 0xea, 0x73, 0x2c, 0x39, 0x61, 0x5f, 0x8f, 0xb4, 0x64, 0x6b, + 0x64, 0xc9, 0x99, 0xd6, 0x9f, 0x08, 0x5e, 0x59, 0x84, 0xde, 0xe7, 0x32, 0xc1, 0x8f, 0x17, 0x96, + 0x6c, 0xaf, 0xb6, 0xe4, 0x9c, 0xad, 0x56, 0x5c, 0xdd, 0x7f, 0x59, 0x69, 0x2c, 0x98, 0x42, 0x87, + 0x27, 0x2c, 0x28, 0xb7, 0xfb, 0xdf, 0x5c, 0x57, 0x2f, 0xef, 0x49, 0x2e, 0x49, 0x0a, 0x65, 0xeb, + 0x77, 0x04, 0xbb, 0x0d, 0xf0, 0x1a, 0x4c, 0x3d, 0x9a, 0x37, 0xf5, 0xce, 0xed, 0x4c, 0x2d, 0x77, + 0xf3, 0x0f, 0x02, 0xa8, 0xbf, 0x57, 0xdc, 0x87, 0xce, 0x94, 0x89, 0x81, 0x34, 0xd0, 0xc1, 0xe6, + 0x61, 0xcf, 0xed, 0xe5, 0xf8, 0x87, 0x79, 0x81, 0x14, 0x75, 0xfc, 0x3a, 0xf4, 0x68, 0xcc, 0x3f, + 0x12, 0x51, 0x1a, 0x4b, 0x63, 0x53, 0x81, 0x76, 0xb2, 0x59, 0xbf, 0x77, 0xef, 0xec, 0xa4, 0x28, + 0x92, 0xba, 0x9f, 0x83, 0x05, 0x93, 0x51, 0x2a, 0x3c, 0x26, 0x8d, 0x76, 0x0d, 0x26, 0x65, 0x91, + 0xd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, 0x14, 0xea, 0x73, 0xab, 0x2f, 0xe5, 0xde, 0xd9, 0x89, + 0xee, 0x90, 0x06, 0xea, 0xfa, 0x19, 0xb0, 0x03, 0xbd, 0xfc, 0x57, 0xc6, 0xd4, 0x63, 0x46, 0x5b, + 0xc1, 0xf6, 0x34, 0xac, 0x77, 0x5a, 0x36, 0x48, 0x8d, 0x71, 0x5f, 0x3b, 0xbf, 0x30, 0x5b, 0xcf, + 0x2e, 0xcc, 0xd6, 0x1f, 0x17, 0x66, 0xeb, 0xdb, 0xcc, 0x44, 0xe7, 0x99, 0x89, 0x9e, 0x65, 0x26, + 0xfa, 0x2b, 0x33, 0xd1, 0xf7, 0x7f, 0x9b, 0xad, 0x47, 0xdd, 0xf2, 0xe2, 0xff, 0x0d, 0x00, 0x00, + 0xff, 0xff, 0x2d, 0x29, 0xd0, 0x2d, 0x23, 0x0c, 0x00, 0x00, } diff --git a/pkg/apis/rbac/v1alpha1/generated.proto b/pkg/apis/rbac/v1alpha1/generated.proto index 75302176c3aec..3832ef3ddce4c 100644 --- a/pkg/apis/rbac/v1alpha1/generated.proto +++ b/pkg/apis/rbac/v1alpha1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1alpha1"; diff --git a/pkg/apis/rbac/v1beta1/generated.pb.go b/pkg/apis/rbac/v1beta1/generated.pb.go index 83bea96e98657..b631dcc685a36 100644 --- a/pkg/apis/rbac/v1beta1/generated.pb.go +++ b/pkg/apis/rbac/v1beta1/generated.pb.go @@ -2766,57 +2766,56 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 824 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x54, 0xbf, 0x8f, 0xe3, 0x44, - 0x18, 0xcd, 0x64, 0x13, 0x6d, 0x3c, 0x4b, 0x14, 0x76, 0x90, 0x90, 0x49, 0xe1, 0x44, 0x6e, 0x58, - 0x04, 0x67, 0xdf, 0xde, 0x9d, 0x38, 0x24, 0x44, 0x81, 0x29, 0xd0, 0x89, 0x63, 0x39, 0x0d, 0x02, - 0xf1, 0x4b, 0xe8, 0x26, 0xce, 0x9c, 0x77, 0x88, 0x7f, 0x69, 0x66, 0x1c, 0x71, 0x82, 0x82, 0x8e, - 0x96, 0x7f, 0x82, 0xee, 0x3a, 0x5a, 0x2a, 0xaa, 0x85, 0xea, 0xca, 0xad, 0x22, 0xd6, 0xfc, 0x21, - 0x20, 0xdb, 0xe3, 0x1f, 0xc1, 0x59, 0x36, 0x2c, 0x52, 0x24, 0xa4, 0xab, 0x76, 0xe7, 0xfb, 0xde, - 0xfb, 0xe6, 0xbd, 0xf9, 0x9c, 0x07, 0xef, 0x2e, 0xde, 0x10, 0x16, 0x8b, 0xec, 0x45, 0x32, 0xa3, - 0x3c, 0xa4, 0x92, 0x0a, 0x3b, 0x5e, 0x78, 0x36, 0x89, 0x99, 0xb0, 0xf9, 0x8c, 0xb8, 0xf6, 0xf2, - 0x78, 0x46, 0x25, 0x39, 0xb6, 0x3d, 0x1a, 0x52, 0x4e, 0x24, 0x9d, 0x5b, 0x31, 0x8f, 0x64, 0x84, - 0x5e, 0x2e, 0x88, 0x56, 0x4d, 0xb4, 0xe2, 0x85, 0x67, 0x65, 0x44, 0x2b, 0x23, 0x5a, 0x8a, 0x38, - 0xbe, 0xe1, 0x31, 0x79, 0x9a, 0xcc, 0x2c, 0x37, 0x0a, 0x6c, 0x2f, 0xf2, 0x22, 0x3b, 0xe7, 0xcf, - 0x92, 0x47, 0xf9, 0x29, 0x3f, 0xe4, 0xff, 0x15, 0x73, 0xc7, 0x77, 0x94, 0x20, 0x12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, 0x22, 0xae, 0xfb, 0x19, 0x98, - 0x53, 0x11, 0x25, 0xdc, 0xa5, 0x42, 0xdf, 0xab, 0xc1, 0xb8, 0x2c, 0xe2, 0xba, 0x8f, 0xee, 0xc2, - 0x61, 0x79, 0x38, 0x21, 0x01, 0x15, 0x7a, 0x2f, 0x27, 0x1c, 0xa6, 0xab, 0xc9, 0x10, 0x37, 0x1b, - 0x78, 0x1d, 0x87, 0xde, 0x82, 0xa3, 0x30, 0x0a, 0x4b, 0xc8, 0x47, 0xf8, 0xbe, 0xd0, 0xfb, 0x39, - 0xf5, 0x85, 0x74, 0x35, 0x19, 0x9d, 0xac, 0xb7, 0xf0, 0xdf, 0xb1, 0xe6, 0xb7, 0xf0, 0xb0, 0x91, - 0x55, 0xea, 0x87, 0xe4, 0x41, 0x18, 0x57, 0x45, 0xb5, 0xd1, 0x6b, 0x65, 0x5f, 0x15, 0x45, 0x75, - 0x0d, 0x37, 0x46, 0x9b, 0xbf, 0x00, 0xd8, 0xfb, 0xdf, 0x47, 0xf9, 0x93, 0x2e, 0x3c, 0x78, 0x96, - 0xe1, 0x5b, 0x67, 0x78, 0x16, 0x20, 0xbb, 0x0d, 0xc5, 0x6b, 0x07, 0xc8, 0xd5, 0x69, 0xf8, 0x33, - 0x80, 0x83, 0x1d, 0xc5, 0x20, 0x5e, 0x77, 0x71, 0xe3, 0xdf, 0xb9, 0xd8, 0x2c, 0xff, 0x1b, 0x58, - 0xee, 0x07, 0xbd, 0x06, 0x07, 0x65, 0x74, 0xe5, 0xe2, 0xb5, 0x5a, 0x4c, 0x99, 0x6e, 0xb8, 0x42, - 0xa0, 0x29, 0xec, 0x2d, 0x58, 0x38, 0xd7, 0xbb, 0x39, 0xf2, 0x39, 0x85, 0xec, 0xbd, 0xc7, 0xc2, - 0x39, 0xce, 0x3b, 0x19, 0x22, 0x24, 0x01, 0xcd, 0x3f, 0xa0, 0x06, 0x22, 0x0b, 0x2d, 0x9c, 0x77, - 0xcc, 0x27, 0x00, 0xee, 0xab, 0x8f, 0xaf, 0x9a, 0x07, 0x2e, 0x9d, 0xd7, 0xd4, 0xd7, 0xdd, 0x46, - 0xdf, 0x3f, 0xdf, 0x8e, 0x6c, 0xa8, 0x65, 0x7f, 0x45, 0x4c, 0x5c, 0xaa, 0xf7, 0x72, 0xd8, 0xa1, - 0x82, 0x69, 0x27, 0x65, 0x03, 0xd7, 0x18, 0xe7, 0x95, 0xb3, 0x0b, 0xa3, 0xf3, 0xf4, 0xc2, 0xe8, - 0x9c, 0x5f, 0x18, 0x9d, 0xef, 0x52, 0x03, 0x9c, 0xa5, 0x06, 0x78, 0x9a, 0x1a, 0xe0, 0xf7, 0xd4, - 0x00, 0x3f, 0xfc, 0x61, 0x74, 0x3e, 0xdb, 0x57, 0x2f, 0xfe, 0x57, 0x00, 0x00, 0x00, 0xff, 0xff, - 0x2d, 0xfe, 0x9c, 0x61, 0x44, 0x0c, 0x00, 0x00, + // 804 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x54, 0x4b, 0x6f, 0xf3, 0x44, + 0x14, 0xcd, 0xe4, 0xa1, 0xc4, 0x13, 0xa2, 0xd0, 0x41, 0x42, 0x26, 0x0b, 0x27, 0xf2, 0x86, 0x22, + 0xf8, 0xec, 0xbe, 0x44, 0x91, 0x10, 0x0b, 0xcc, 0x02, 0x55, 0x94, 0x52, 0x0d, 0x02, 0xf1, 0x12, + 0xaa, 0xe3, 0x4c, 0xdd, 0x21, 0x7e, 0xc9, 0x33, 0x8e, 0x54, 0xc1, 0x82, 0x1d, 0x5b, 0xfe, 0x04, + 0xbb, 0xee, 0xd8, 0xb2, 0x62, 0x55, 0x58, 0x75, 0xd9, 0x55, 0x44, 0xcd, 0x0f, 0x01, 0xd9, 0x1e, + 0x3f, 0xd2, 0xa4, 0x34, 0x14, 0x29, 0x12, 0xd2, 0xb7, 0x6a, 0xe7, 0xde, 0x73, 0xce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b5, 0x33, + 0x3c, 0x09, 0x90, 0xcd, 0x86, 0xe2, 0x93, 0x03, 0xe4, 0xf1, 0x34, 0xfc, 0x05, 0xc0, 0xce, 0x86, + 0x62, 0x10, 0x2f, 0xba, 0x78, 0xf6, 0xef, 0x5c, 0xac, 0x1e, 0xff, 0x5b, 0x98, 0xef, 0x07, 0xbd, + 0x01, 0x3b, 0x79, 0x74, 0xa5, 0xc3, 0x4b, 0xe5, 0x30, 0x79, 0xba, 0xe1, 0x02, 0x81, 0x46, 0xb0, + 0x39, 0xa5, 0xde, 0x44, 0xae, 0xa7, 0xc8, 0x17, 0x04, 0xb2, 0xf9, 0x01, 0xf5, 0x26, 0x38, 0xed, + 0x24, 0x08, 0xcf, 0x74, 0x49, 0xfa, 0x01, 0x55, 0x10, 0x49, 0x68, 0xe1, 0xb4, 0xa3, 0x5e, 0x01, + 0xd8, 0x16, 0x1f, 0x5f, 0xa1, 0x07, 0x1e, 0xd4, 0xab, 0xce, 0x57, 0x5f, 0x67, 0xbe, 0x7f, 0xbe, + 0x1d, 0xe9, 0x50, 0x4a, 0xfe, 0xb2, 0xc0, 0xb4, 0x88, 0xdc, 0x4c, 0x61, 0x5b, 0x02, 0x26, 0x9d, + 0xe4, 0x0d, 0x5c, 0x62, 0x8c, 0xd7, 0xae, 0xef, 0x94, 0xda, 0xcd, 0x9d, 0x52, 0xbb, 0xbd, 0x53, + 0x6a, 0xdf, 0xc7, 0x0a, 0xb8, 0x8e, 0x15, 0x70, 0x13, 0x2b, 0xe0, 0x8f, 0x58, 0x01, 0x3f, 0xfe, + 0xa9, 0xd4, 0xbe, 0x68, 0x8b, 0x17, 0xff, 0x3b, 0x00, 0x00, 0xff, 0xff, 0x98, 0x18, 0x7e, 0x05, + 0x0e, 0x0c, 0x00, 0x00, } diff --git a/pkg/apis/rbac/v1beta1/generated.proto b/pkg/apis/rbac/v1beta1/generated.proto index b18fc0fd95352..39f99487a8cba 100644 --- a/pkg/apis/rbac/v1beta1/generated.proto +++ b/pkg/apis/rbac/v1beta1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; diff --git a/pkg/apis/settings/v1alpha1/generated.pb.go b/pkg/apis/settings/v1alpha1/generated.pb.go index 62cf893588c6e..769040e136acb 100644 --- a/pkg/apis/settings/v1alpha1/generated.pb.go +++ b/pkg/apis/settings/v1alpha1/generated.pb.go @@ -891,40 +891,39 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 550 bytes of a gzipped FileDescriptorProto + // 535 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x92, 0x41, 0x8b, 0xd3, 0x40, - 0x14, 0xc7, 0x9b, 0x6d, 0x4b, 0xeb, 0xb4, 0x8b, 0x12, 0x3c, 0x84, 0x1e, 0xb2, 0x4b, 0xf1, 0xb0, - 0xea, 0x3a, 0xb1, 0xab, 0xa8, 0xa0, 0xa7, 0xc8, 0x0a, 0x82, 0xcb, 0x2e, 0x29, 0xf4, 0x20, 0x2b, - 0x38, 0x4d, 0x9f, 0x69, 0x6c, 0x93, 0x09, 0x33, 0x93, 0xa0, 0x37, 0x3f, 0x82, 0x5f, 0x4a, 0x28, - 0xe8, 0x61, 0x8f, 0x9e, 0x16, 0x5b, 0xbf, 0x88, 0xcc, 0x74, 0xd2, 0x44, 0xba, 0x65, 0xab, 0xb7, - 0x79, 0x8f, 0xf7, 0xff, 0xbd, 0xff, 0x3f, 0x2f, 0xe8, 0xc5, 0xe4, 0x19, 0xc7, 0x21, 0x75, 0x26, - 0xe9, 0x10, 0x58, 0x0c, 0x02, 0xb8, 0x93,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x8a, 0xe0, 0x0f, 0xa8, 0x7f, 0x6f, 0x3a, 0x73, 0x2b, 0x97, 0x33, 0xb7, 0xf2, + 0x63, 0xe6, 0x56, 0x3e, 0xcf, 0x5d, 0x6b, 0x3a, 0x77, 0xad, 0xcb, 0xb9, 0x6b, 0xfd, 0x9c, 0xbb, + 0xd6, 0x97, 0x5f, 0x6e, 0xe5, 0x6d, 0xa3, 0xf8, 0x27, 0x7e, 0x07, 0x00, 0x00, 0xff, 0xff, 0xe9, + 0x9c, 0x18, 0x84, 0xf9, 0x04, 0x00, 0x00, } diff --git a/pkg/apis/settings/v1alpha1/generated.proto b/pkg/apis/settings/v1alpha1/generated.proto index c27c921f7aeb5..1f3eaf5ad86ba 100644 --- a/pkg/apis/settings/v1alpha1/generated.proto +++ b/pkg/apis/settings/v1alpha1/generated.proto @@ -24,7 +24,6 @@ package k8s.io.kubernetes.pkg.apis.settings.v1alpha1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; // Package-wide variables from generator "generated". diff --git a/pkg/apis/storage/v1/generated.pb.go b/pkg/apis/storage/v1/generated.pb.go index 9e90596e569f0..61c2608a007b8 100644 --- a/pkg/apis/storage/v1/generated.pb.go +++ b/pkg/apis/storage/v1/generated.pb.go @@ -707,35 +707,34 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 474 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x92, 0x4f, 0x6f, 0xd3, 0x30, - 0x18, 0xc6, 0xe3, 0x54, 0x95, 0x36, 0x17, 0x44, 0x15, 0x38, 0x54, 0x3d, 0x64, 0xd5, 0x04, 0x52, + // 458 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x91, 0xcf, 0x6f, 0xd3, 0x30, + 0x14, 0xc7, 0xe3, 0x54, 0x95, 0x36, 0x17, 0x44, 0x15, 0x38, 0x54, 0x3d, 0x78, 0xd5, 0x04, 0x52, 0x2f, 0xd8, 0x74, 0x63, 0x68, 0x42, 0xe2, 0xd2, 0x89, 0x03, 0x12, 0x88, 0x29, 0x5c, 0x10, 0xe2, - 0x80, 0xdb, 0xbd, 0xa4, 0x26, 0x4d, 0x1c, 0xd9, 0x6f, 0x02, 0xbd, 0xf1, 0x11, 0xf8, 0x58, 0x15, - 0xa7, 0x1d, 0x39, 0x0d, 0x1a, 0xbe, 0x08, 0xca, 0x1f, 0x96, 0x88, 0x6c, 0xa2, 0xda, 0x2d, 0xaf, - 0xed, 0xdf, 0xe3, 0xe7, 0x79, 0x1c, 0x7a, 0x14, 0x1c, 0x1b, 0x26, 0x15, 0x0f, 0x92, 0x19, 0xe8, - 0x08, 0x10, 0x0c, 0x8f, 0x03, 0x9f, 0x8b, 0x58, 0x1a, 0x6e, 0x50, 0x69, 0xe1, 0x03, 0x4f, 0x27, - 0xdc, 0x87, 0x08, 0xb4, 0x40, 0x38, 0x63, 0xb1, 0x56, 0xa8, 0x9c, 0x07, 0x25, 0xc6, 0x6a, 0x8c, - 0xc5, 0x81, 0xcf, 0x72, 0x8c, 0x55, 0x18, 0x4b, 0x27, 0xc3, 0x87, 0xbe, 0xc4, 0x45, 0x32, 0x63, - 0x73, 0x15, 0x72, 0x5f, 0xf9, 0x8a, 0x17, 0xf4, 0x2c, 0xf9, 0x58, 0x4c, 0xc5, 0x50, 0x7c, 0x95, - 0xaa, 0xc3, 0xc7, 0x95, 0x19, 0x11, 0xcb, 0x50, 0xcc, 0x17, 0x32, 0x02, 0xbd, 0xaa, 0xed, 0x84, - 0x80, 0xe2, 0x0a, 0x2f, 0x43, 0x7e, 0x1d, 0xa5, 0x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 0x8c, 0x7b, 0x07, 0x27, 0xfc, 0x46, 0x1f, 0xcd, 0xdb, 0x13, 0xf2, 0xd3, 0xcb, + 0x94, 0xe7, 0x31, 0x9a, 0x55, 0xd3, 0x6d, 0x73, 0xe0, 0xb7, 0x9e, 0x1a, 0x3e, 0xa3, 0x77, 0xae, + 0x20, 0x5e, 0x9f, 0x76, 0x42, 0x58, 0x95, 0x7e, 0x76, 0xfd, 0x62, 0xe9, 0xdd, 0xa3, 0xdd, 0x4c, + 0x2e, 0x53, 0xa8, 0xc6, 0xf1, 0xab, 0xe2, 0xa9, 0x7b, 0x4c, 0xf6, 0xbf, 0x11, 0xda, 0x6f, 0xbf, + 0xff, 0x52, 0x59, 0xf4, 0xde, 0x6f, 0x59, 0xe6, 0x37, 0xb3, 0x5c, 0xd0, 0xa5, 0xe3, 0x7e, 0xdd, + 0xf5, 0xce, 0x9f, 0x9d, 0x96, 0xe1, 0xb7, 0xb4, 0xab, 0x10, 0x22, 0x3b, 0x70, 0x4b, 0x4b, 0x87, + 0xff, 0x61, 0x69, 0x7a, 0xbb, 0xce, 0xef, 0xbe, 0x28, 0x92, 0xfc, 0x2a, 0x70, 0x7a, 0x7f, 0xbd, + 0x61, 0xce, 0xf9, 0x86, 0x39, 0xdf, 0x37, 0xcc, 0xf9, 0x92, 0x33, 0xb2, 0xce, 0x19, 0x39, 0xcf, + 0x19, 0xf9, 0x99, 0x33, 0xf2, 0xf5, 0x17, 0x73, 0xde, 0xb9, 0xd9, 0xe4, 0x77, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xab, 0x11, 0xb9, 0x95, 0xb6, 0x03, 0x00, 0x00, } diff --git a/pkg/apis/storage/v1/generated.proto b/pkg/apis/storage/v1/generated.proto index 9457ee7aeb3dc..5e5440b99cb80 100644 --- a/pkg/apis/storage/v1/generated.proto +++ b/pkg/apis/storage/v1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1"; diff --git a/pkg/apis/storage/v1beta1/generated.pb.go b/pkg/apis/storage/v1beta1/generated.pb.go index 9c3e0c5749b1d..98884e4440951 100644 --- a/pkg/apis/storage/v1beta1/generated.pb.go +++ b/pkg/apis/storage/v1beta1/generated.pb.go @@ -707,35 +707,34 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 479 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x92, 0x4d, 0x8b, 0xd3, 0x40, - 0x1c, 0xc6, 0x33, 0x2d, 0xc5, 0xdd, 0xa9, 0x62, 0x89, 0x1e, 0x4a, 0x0f, 0xd9, 0xb2, 0xa7, 0x2a, - 0x38, 0x63, 0xd7, 0x17, 0xca, 0x82, 0x97, 0x8a, 0xa0, 0xa0, 0xb8, 0xc4, 0x9b, 0x28, 0x38, 0xe9, - 0xfe, 0x4d, 0xc7, 0x34, 0x99, 0x30, 0xf3, 0x4f, 0xb0, 0xe0, 0xc1, 0x8f, 0xe0, 0xc7, 0xea, 0xcd, - 0x3d, 0x7a, 0x5a, 0x6c, 0xf4, 0x83, 0x48, 0x5e, 0xdc, 0x04, 0xe3, 0x62, 0xf1, 0x96, 0x79, 0xf9, - 0x3d, 0xff, 0xe7, 0x79, 0x26, 0xf4, 0x38, 0x98, 0x19, 0x26, 0x15, 0x0f, 0x12, 0x0f, 0x74, 0x04, - 0x08, 0x86, 0xc7, 0x81, 0xcf, 0x45, 0x2c, 0x0d, 0x37, 0xa8, 0xb4, 0xf0, 0x81, 0xa7, 0x53, 0x0f, - 0x50, 0x4c, 0xb9, 0x0f, 0x11, 0x68, 0x81, 0x70, 0xca, 0x62, 0xad, 0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, 0x8d, 0x0a, 0xe9, 0x9f, 0xd4, 0x47, 0x6e, 0xf3, 0x9e, 0xfd, 0x89, 0xd2, 0x58, 0x68, 0x11, - 0x02, 0x82, 0x36, 0xc3, 0xee, 0xb8, 0x3b, 0xe9, 0x1f, 0x3d, 0x65, 0xbb, 0xff, 0x23, 0xac, 0x19, - 0x93, 0x9d, 0x5c, 0x48, 0x3d, 0x89, 0x50, 0xaf, 0x6b, 0xcb, 0xf5, 0x81, 0xdb, 0x98, 0x37, 0x7a, - 0x44, 0xaf, 0xff, 0x81, 0xd8, 0x03, 0xda, 0x0d, 0x60, 0x5d, 0x94, 0xb4, 0xef, 0xe6, 0x9f, 0xf6, - 0x4d, 0xda, 0x4b, 0xc5, 0x2a, 0x81, 0x32, 0x93, 0x5b, 0x2e, 0x8e, 0x3b, 0x33, 0x72, 0xf8, 0x95, - 0xd0, 0x41, 0x73, 0xfe, 0x73, 0x69, 0xd0, 0x7e, 0xd3, 0xaa, 0x9a, 0xed, 0x56, 0x75, 0x4e, 0x17, - 0x45, 0x0f, 0x2a, 0xd7, 0x7b, 0xbf, 0x77, 0x1a, 0x35, 0xbf, 0xa5, 0x3d, 0x89, 0x10, 0x9a, 0x61, - 0xa7, 0xa8, 0x6a, 0xf6, 0xbf, 0x55, 0xcd, 0xaf, 0x55, 0x43, 0x7a, 0xcf, 0x72, 0x39, 0xb7, 0x54, - 0x9d, 0xdf, 0xda, 0x6c, 0x1d, 0xeb, 0x6c, 0xeb, 0x58, 0xdf, 0xb6, 0x8e, 0xf5, 0x39, 0x73, 0xc8, - 0x26, 0x73, 0xc8, 0x59, 0xe6, 0x90, 0xef, 0x99, 0x43, 0xbe, 0xfc, 0x70, 0xac, 0xd7, 0x57, 0x2a, - 0xb5, 0x5f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x7e, 0xb2, 0x39, 0x2a, 0x05, 0x04, 0x00, 0x00, + // 463 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x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, 0xd0, 0xec, 0xff, 0x5a, 0x1a, 0xb4, 0x3f, 0xb4, 0x54, 0xb3, 0xdd, 0x54, 0xe7, 0x74, + 0x21, 0x7a, 0x50, 0x4d, 0xbd, 0xf7, 0xef, 0xa4, 0xa1, 0xf9, 0x23, 0xed, 0x49, 0x84, 0xd0, 0x0c, + 0x3b, 0x85, 0xaa, 0xd9, 0x75, 0x55, 0xcd, 0x6f, 0x55, 0x4d, 0x7a, 0xaf, 0xf2, 0x38, 0xb7, 0x4c, + 0x9d, 0xdf, 0xdb, 0x6c, 0x1d, 0xeb, 0x6c, 0xeb, 0x58, 0x3f, 0xb7, 0x8e, 0xf5, 0x2d, 0x73, 0xc8, + 0x26, 0x73, 0xc8, 0x59, 0xe6, 0x90, 0x5f, 0x99, 0x43, 0xbe, 0xff, 0x76, 0xac, 0xf7, 0x37, 0xaa, + 0xb4, 0xbf, 0x01, 0x00, 0x00, 0xff, 0xff, 0x90, 0xa9, 0x9d, 0x71, 0xcf, 0x03, 0x00, 0x00, } diff --git a/pkg/apis/storage/v1beta1/generated.proto b/pkg/apis/storage/v1beta1/generated.proto index 28080dd611010..bc306838aefe4 100644 --- a/pkg/apis/storage/v1beta1/generated.proto +++ b/pkg/apis/storage/v1beta1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; diff --git a/pkg/client/clientset_generated/clientset/BUILD b/pkg/client/clientset_generated/clientset/BUILD index 7b32d6280d658..c35ae87d0ceda 100644 --- a/pkg/client/clientset_generated/clientset/BUILD +++ b/pkg/client/clientset_generated/clientset/BUILD @@ -29,6 +29,7 @@ go_library( "//pkg/apis/rbac/install:go_default_library", "//pkg/apis/settings/install:go_default_library", "//pkg/apis/storage/install:go_default_library", + "//pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1:go_default_library", "//pkg/client/clientset_generated/clientset/typed/apps/v1beta1:go_default_library", "//pkg/client/clientset_generated/clientset/typed/authentication/v1:go_default_library", "//pkg/client/clientset_generated/clientset/typed/authentication/v1beta1:go_default_library", @@ -41,6 +42,7 @@ go_library( "//pkg/client/clientset_generated/clientset/typed/certificates/v1beta1:go_default_library", "//pkg/client/clientset_generated/clientset/typed/core/v1:go_default_library", "//pkg/client/clientset_generated/clientset/typed/extensions/v1beta1:go_default_library", + "//pkg/client/clientset_generated/clientset/typed/networking/v1:go_default_library", "//pkg/client/clientset_generated/clientset/typed/policy/v1beta1:go_default_library", "//pkg/client/clientset_generated/clientset/typed/rbac/v1alpha1:go_default_library", "//pkg/client/clientset_generated/clientset/typed/rbac/v1beta1:go_default_library", @@ -67,6 +69,7 @@ filegroup( ":package-srcs", "//pkg/client/clientset_generated/clientset/fake:all-srcs", "//pkg/client/clientset_generated/clientset/scheme:all-srcs", + "//pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1:all-srcs", "//pkg/client/clientset_generated/clientset/typed/apps/v1beta1:all-srcs", "//pkg/client/clientset_generated/clientset/typed/authentication/v1:all-srcs", "//pkg/client/clientset_generated/clientset/typed/authentication/v1beta1:all-srcs", @@ -79,6 +82,7 @@ filegroup( "//pkg/client/clientset_generated/clientset/typed/certificates/v1beta1:all-srcs", "//pkg/client/clientset_generated/clientset/typed/core/v1:all-srcs", "//pkg/client/clientset_generated/clientset/typed/extensions/v1beta1:all-srcs", + "//pkg/client/clientset_generated/clientset/typed/networking/v1:all-srcs", "//pkg/client/clientset_generated/clientset/typed/policy/v1beta1:all-srcs", "//pkg/client/clientset_generated/clientset/typed/rbac/v1alpha1:all-srcs", "//pkg/client/clientset_generated/clientset/typed/rbac/v1beta1:all-srcs", diff --git a/pkg/client/clientset_generated/clientset/clientset.go b/pkg/client/clientset_generated/clientset/clientset.go index 88df7ab770d34..f477de366ed8a 100644 --- a/pkg/client/clientset_generated/clientset/clientset.go +++ b/pkg/client/clientset_generated/clientset/clientset.go @@ -21,6 +21,7 @@ import ( discovery "k8s.io/client-go/discovery" rest "k8s.io/client-go/rest" flowcontrol "k8s.io/client-go/util/flowcontrol" + admissionregistrationv1alpha1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1" appsv1beta1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/apps/v1beta1" authenticationv1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/authentication/v1" authenticationv1beta1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/authentication/v1beta1" @@ -33,6 +34,7 @@ import ( certificatesv1beta1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/certificates/v1beta1" corev1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/core/v1" extensionsv1beta1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/extensions/v1beta1" + networkingv1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/networking/v1" policyv1beta1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/policy/v1beta1" rbacv1alpha1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/rbac/v1alpha1" rbacv1beta1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/rbac/v1beta1" @@ -43,6 +45,9 @@ import ( type Interface interface { Discovery() discovery.DiscoveryInterface + AdmissionregistrationV1alpha1() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface + // Deprecated: please explicitly pick a version if possible. + Admissionregistration() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface CoreV1() corev1.CoreV1Interface // Deprecated: please explicitly pick a version if possible. Core() corev1.CoreV1Interface @@ -71,6 +76,9 @@ type Interface interface { ExtensionsV1beta1() extensionsv1beta1.ExtensionsV1beta1Interface // Deprecated: please explicitly pick a version if possible. Extensions() extensionsv1beta1.ExtensionsV1beta1Interface + NetworkingV1() networkingv1.NetworkingV1Interface + // Deprecated: please explicitly pick a version if possible. + Networking() networkingv1.NetworkingV1Interface PolicyV1beta1() policyv1beta1.PolicyV1beta1Interface // Deprecated: please explicitly pick a version if possible. Policy() policyv1beta1.PolicyV1beta1Interface @@ -91,6 +99,7 @@ type Interface interface { // version included in a Clientset. type Clientset struct { *discovery.DiscoveryClient + *admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Client *corev1.CoreV1Client *appsv1beta1.AppsV1beta1Client *authenticationv1.AuthenticationV1Client @@ -103,6 +112,7 @@ type Clientset struct { *batchv2alpha1.BatchV2alpha1Client *certificatesv1beta1.CertificatesV1beta1Client *extensionsv1beta1.ExtensionsV1beta1Client + *networkingv1.NetworkingV1Client *policyv1beta1.PolicyV1beta1Client *rbacv1beta1.RbacV1beta1Client *rbacv1alpha1.RbacV1alpha1Client @@ -111,6 +121,23 @@ type Clientset struct { *storagev1.StorageV1Client } +// AdmissionregistrationV1alpha1 retrieves the AdmissionregistrationV1alpha1Client +func (c *Clientset) AdmissionregistrationV1alpha1() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface { + if c == nil { + return nil + } + return c.AdmissionregistrationV1alpha1Client +} + +// Deprecated: Admissionregistration retrieves the default version of AdmissionregistrationClient. +// Please explicitly pick a version. +func (c *Clientset) Admissionregistration() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface { + if c == nil { + return nil + } + return c.AdmissionregistrationV1alpha1Client +} + // CoreV1 retrieves the CoreV1Client func (c *Clientset) CoreV1() corev1.CoreV1Interface { if c == nil { @@ -279,6 +306,23 @@ func (c *Clientset) Extensions() extensionsv1beta1.ExtensionsV1beta1Interface { return c.ExtensionsV1beta1Client } +// NetworkingV1 retrieves the NetworkingV1Client +func (c *Clientset) NetworkingV1() networkingv1.NetworkingV1Interface { + if c == nil { + return nil + } + return c.NetworkingV1Client +} + +// Deprecated: Networking retrieves the default version of NetworkingClient. +// Please explicitly pick a version. +func (c *Clientset) Networking() networkingv1.NetworkingV1Interface { + if c == nil { + return nil + } + return c.NetworkingV1Client +} + // PolicyV1beta1 retrieves the PolicyV1beta1Client func (c *Clientset) PolicyV1beta1() policyv1beta1.PolicyV1beta1Interface { if c == nil { @@ -379,6 +423,10 @@ func NewForConfig(c *rest.Config) (*Clientset, error) { } var cs Clientset var err error + cs.AdmissionregistrationV1alpha1Client, err = admissionregistrationv1alpha1.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } cs.CoreV1Client, err = corev1.NewForConfig(&configShallowCopy) if err != nil { return nil, err @@ -427,6 +475,10 @@ func NewForConfig(c *rest.Config) (*Clientset, error) { if err != nil { return nil, err } + cs.NetworkingV1Client, err = networkingv1.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } cs.PolicyV1beta1Client, err = policyv1beta1.NewForConfig(&configShallowCopy) if err != nil { return nil, err @@ -464,6 +516,7 @@ func NewForConfig(c *rest.Config) (*Clientset, error) { // panics if there is an error in the config. func NewForConfigOrDie(c *rest.Config) *Clientset { var cs Clientset + cs.AdmissionregistrationV1alpha1Client = admissionregistrationv1alpha1.NewForConfigOrDie(c) cs.CoreV1Client = corev1.NewForConfigOrDie(c) cs.AppsV1beta1Client = appsv1beta1.NewForConfigOrDie(c) cs.AuthenticationV1Client = authenticationv1.NewForConfigOrDie(c) @@ -476,6 +529,7 @@ func NewForConfigOrDie(c *rest.Config) *Clientset { cs.BatchV2alpha1Client = batchv2alpha1.NewForConfigOrDie(c) cs.CertificatesV1beta1Client = certificatesv1beta1.NewForConfigOrDie(c) cs.ExtensionsV1beta1Client = extensionsv1beta1.NewForConfigOrDie(c) + cs.NetworkingV1Client = networkingv1.NewForConfigOrDie(c) cs.PolicyV1beta1Client = policyv1beta1.NewForConfigOrDie(c) cs.RbacV1beta1Client = rbacv1beta1.NewForConfigOrDie(c) cs.RbacV1alpha1Client = rbacv1alpha1.NewForConfigOrDie(c) @@ -490,6 +544,7 @@ func NewForConfigOrDie(c *rest.Config) *Clientset { // New creates a new Clientset for the given RESTClient. func New(c rest.Interface) *Clientset { var cs Clientset + cs.AdmissionregistrationV1alpha1Client = admissionregistrationv1alpha1.New(c) cs.CoreV1Client = corev1.New(c) cs.AppsV1beta1Client = appsv1beta1.New(c) cs.AuthenticationV1Client = authenticationv1.New(c) @@ -502,6 +557,7 @@ func New(c rest.Interface) *Clientset { cs.BatchV2alpha1Client = batchv2alpha1.New(c) cs.CertificatesV1beta1Client = certificatesv1beta1.New(c) cs.ExtensionsV1beta1Client = extensionsv1beta1.New(c) + cs.NetworkingV1Client = networkingv1.New(c) cs.PolicyV1beta1Client = policyv1beta1.New(c) cs.RbacV1beta1Client = rbacv1beta1.New(c) cs.RbacV1alpha1Client = rbacv1alpha1.New(c) diff --git a/pkg/client/clientset_generated/clientset/fake/BUILD b/pkg/client/clientset_generated/clientset/fake/BUILD index b21d5aabfec71..27321e58e8ed1 100644 --- a/pkg/client/clientset_generated/clientset/fake/BUILD +++ b/pkg/client/clientset_generated/clientset/fake/BUILD @@ -17,6 +17,7 @@ go_library( tags = ["automanaged"], deps = [ "//pkg/api/v1:go_default_library", + "//pkg/apis/admissionregistration/v1alpha1:go_default_library", "//pkg/apis/apps/v1beta1:go_default_library", "//pkg/apis/authentication/v1:go_default_library", "//pkg/apis/authentication/v1beta1:go_default_library", @@ -28,6 +29,7 @@ go_library( "//pkg/apis/batch/v2alpha1:go_default_library", "//pkg/apis/certificates/v1beta1:go_default_library", "//pkg/apis/extensions/v1beta1:go_default_library", + "//pkg/apis/networking/v1:go_default_library", "//pkg/apis/policy/v1beta1:go_default_library", "//pkg/apis/rbac/v1alpha1:go_default_library", "//pkg/apis/rbac/v1beta1:go_default_library", @@ -35,6 +37,8 @@ go_library( "//pkg/apis/storage/v1:go_default_library", "//pkg/apis/storage/v1beta1:go_default_library", "//pkg/client/clientset_generated/clientset:go_default_library", + "//pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1:go_default_library", + "//pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake:go_default_library", "//pkg/client/clientset_generated/clientset/typed/apps/v1beta1:go_default_library", "//pkg/client/clientset_generated/clientset/typed/apps/v1beta1/fake:go_default_library", "//pkg/client/clientset_generated/clientset/typed/authentication/v1:go_default_library", @@ -59,6 +63,8 @@ go_library( "//pkg/client/clientset_generated/clientset/typed/core/v1/fake:go_default_library", "//pkg/client/clientset_generated/clientset/typed/extensions/v1beta1:go_default_library", "//pkg/client/clientset_generated/clientset/typed/extensions/v1beta1/fake:go_default_library", + "//pkg/client/clientset_generated/clientset/typed/networking/v1:go_default_library", + "//pkg/client/clientset_generated/clientset/typed/networking/v1/fake:go_default_library", "//pkg/client/clientset_generated/clientset/typed/policy/v1beta1:go_default_library", "//pkg/client/clientset_generated/clientset/typed/policy/v1beta1/fake:go_default_library", "//pkg/client/clientset_generated/clientset/typed/rbac/v1alpha1:go_default_library", diff --git a/pkg/client/clientset_generated/clientset/fake/clientset_generated.go b/pkg/client/clientset_generated/clientset/fake/clientset_generated.go index 0e2a2ee2e01a7..005ce74810dd1 100644 --- a/pkg/client/clientset_generated/clientset/fake/clientset_generated.go +++ b/pkg/client/clientset_generated/clientset/fake/clientset_generated.go @@ -23,6 +23,8 @@ import ( fakediscovery "k8s.io/client-go/discovery/fake" "k8s.io/client-go/testing" clientset "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" + admissionregistrationv1alpha1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1" + fakeadmissionregistrationv1alpha1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake" appsv1beta1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/apps/v1beta1" fakeappsv1beta1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/fake" authenticationv1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/authentication/v1" @@ -47,6 +49,8 @@ import ( fakecorev1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/core/v1/fake" extensionsv1beta1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/extensions/v1beta1" fakeextensionsv1beta1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/extensions/v1beta1/fake" + networkingv1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/networking/v1" + fakenetworkingv1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/networking/v1/fake" policyv1beta1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/policy/v1beta1" fakepolicyv1beta1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/policy/v1beta1/fake" rbacv1alpha1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/rbac/v1alpha1" @@ -94,6 +98,16 @@ func (c *Clientset) Discovery() discovery.DiscoveryInterface { var _ clientset.Interface = &Clientset{} +// AdmissionregistrationV1alpha1 retrieves the AdmissionregistrationV1alpha1Client +func (c *Clientset) AdmissionregistrationV1alpha1() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface { + return &fakeadmissionregistrationv1alpha1.FakeAdmissionregistrationV1alpha1{Fake: &c.Fake} +} + +// Admissionregistration retrieves the AdmissionregistrationV1alpha1Client +func (c *Clientset) Admissionregistration() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface { + return &fakeadmissionregistrationv1alpha1.FakeAdmissionregistrationV1alpha1{Fake: &c.Fake} +} + // CoreV1 retrieves the CoreV1Client func (c *Clientset) CoreV1() corev1.CoreV1Interface { return &fakecorev1.FakeCoreV1{Fake: &c.Fake} @@ -194,6 +208,16 @@ func (c *Clientset) Extensions() extensionsv1beta1.ExtensionsV1beta1Interface { return &fakeextensionsv1beta1.FakeExtensionsV1beta1{Fake: &c.Fake} } +// NetworkingV1 retrieves the NetworkingV1Client +func (c *Clientset) NetworkingV1() networkingv1.NetworkingV1Interface { + return &fakenetworkingv1.FakeNetworkingV1{Fake: &c.Fake} +} + +// Networking retrieves the NetworkingV1Client +func (c *Clientset) Networking() networkingv1.NetworkingV1Interface { + return &fakenetworkingv1.FakeNetworkingV1{Fake: &c.Fake} +} + // PolicyV1beta1 retrieves the PolicyV1beta1Client func (c *Clientset) PolicyV1beta1() policyv1beta1.PolicyV1beta1Interface { return &fakepolicyv1beta1.FakePolicyV1beta1{Fake: &c.Fake} diff --git a/pkg/client/clientset_generated/clientset/fake/register.go b/pkg/client/clientset_generated/clientset/fake/register.go index ef472db773975..9e3b49e915e3e 100644 --- a/pkg/client/clientset_generated/clientset/fake/register.go +++ b/pkg/client/clientset_generated/clientset/fake/register.go @@ -22,6 +22,7 @@ import ( schema "k8s.io/apimachinery/pkg/runtime/schema" serializer "k8s.io/apimachinery/pkg/runtime/serializer" corev1 "k8s.io/kubernetes/pkg/api/v1" + admissionregistrationv1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" appsv1beta1 "k8s.io/kubernetes/pkg/apis/apps/v1beta1" authenticationv1 "k8s.io/kubernetes/pkg/apis/authentication/v1" authenticationv1beta1 "k8s.io/kubernetes/pkg/apis/authentication/v1beta1" @@ -33,6 +34,7 @@ import ( batchv2alpha1 "k8s.io/kubernetes/pkg/apis/batch/v2alpha1" certificatesv1beta1 "k8s.io/kubernetes/pkg/apis/certificates/v1beta1" extensionsv1beta1 "k8s.io/kubernetes/pkg/apis/extensions/v1beta1" + networkingv1 "k8s.io/kubernetes/pkg/apis/networking/v1" policyv1beta1 "k8s.io/kubernetes/pkg/apis/policy/v1beta1" rbacv1alpha1 "k8s.io/kubernetes/pkg/apis/rbac/v1alpha1" rbacv1beta1 "k8s.io/kubernetes/pkg/apis/rbac/v1beta1" @@ -65,6 +67,7 @@ func init() { // After this, RawExtensions in Kubernetes types will serialize kube-aggregator types // correctly. func AddToScheme(scheme *runtime.Scheme) { + admissionregistrationv1alpha1.AddToScheme(scheme) corev1.AddToScheme(scheme) appsv1beta1.AddToScheme(scheme) authenticationv1.AddToScheme(scheme) @@ -77,6 +80,7 @@ func AddToScheme(scheme *runtime.Scheme) { batchv2alpha1.AddToScheme(scheme) certificatesv1beta1.AddToScheme(scheme) extensionsv1beta1.AddToScheme(scheme) + networkingv1.AddToScheme(scheme) policyv1beta1.AddToScheme(scheme) rbacv1beta1.AddToScheme(scheme) rbacv1alpha1.AddToScheme(scheme) diff --git a/pkg/client/clientset_generated/clientset/scheme/BUILD b/pkg/client/clientset_generated/clientset/scheme/BUILD index ceb7d393e9dec..214fc6ef245c1 100644 --- a/pkg/client/clientset_generated/clientset/scheme/BUILD +++ b/pkg/client/clientset_generated/clientset/scheme/BUILD @@ -16,6 +16,7 @@ go_library( tags = ["automanaged"], deps = [ "//pkg/api/v1:go_default_library", + "//pkg/apis/admissionregistration/v1alpha1:go_default_library", "//pkg/apis/apps/v1beta1:go_default_library", "//pkg/apis/authentication/v1:go_default_library", "//pkg/apis/authentication/v1beta1:go_default_library", @@ -27,6 +28,7 @@ go_library( "//pkg/apis/batch/v2alpha1:go_default_library", "//pkg/apis/certificates/v1beta1:go_default_library", "//pkg/apis/extensions/v1beta1:go_default_library", + "//pkg/apis/networking/v1:go_default_library", "//pkg/apis/policy/v1beta1:go_default_library", "//pkg/apis/rbac/v1alpha1:go_default_library", "//pkg/apis/rbac/v1beta1:go_default_library", diff --git a/pkg/client/clientset_generated/clientset/scheme/register.go b/pkg/client/clientset_generated/clientset/scheme/register.go index 813426e915227..1047b67a65d36 100644 --- a/pkg/client/clientset_generated/clientset/scheme/register.go +++ b/pkg/client/clientset_generated/clientset/scheme/register.go @@ -22,6 +22,7 @@ import ( schema "k8s.io/apimachinery/pkg/runtime/schema" serializer "k8s.io/apimachinery/pkg/runtime/serializer" corev1 "k8s.io/kubernetes/pkg/api/v1" + admissionregistrationv1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" appsv1beta1 "k8s.io/kubernetes/pkg/apis/apps/v1beta1" authenticationv1 "k8s.io/kubernetes/pkg/apis/authentication/v1" authenticationv1beta1 "k8s.io/kubernetes/pkg/apis/authentication/v1beta1" @@ -33,6 +34,7 @@ import ( batchv2alpha1 "k8s.io/kubernetes/pkg/apis/batch/v2alpha1" certificatesv1beta1 "k8s.io/kubernetes/pkg/apis/certificates/v1beta1" extensionsv1beta1 "k8s.io/kubernetes/pkg/apis/extensions/v1beta1" + networkingv1 "k8s.io/kubernetes/pkg/apis/networking/v1" policyv1beta1 "k8s.io/kubernetes/pkg/apis/policy/v1beta1" rbacv1alpha1 "k8s.io/kubernetes/pkg/apis/rbac/v1alpha1" rbacv1beta1 "k8s.io/kubernetes/pkg/apis/rbac/v1beta1" @@ -65,6 +67,7 @@ func init() { // After this, RawExtensions in Kubernetes types will serialize kube-aggregator types // correctly. func AddToScheme(scheme *runtime.Scheme) { + admissionregistrationv1alpha1.AddToScheme(scheme) corev1.AddToScheme(scheme) appsv1beta1.AddToScheme(scheme) authenticationv1.AddToScheme(scheme) @@ -77,6 +80,7 @@ func AddToScheme(scheme *runtime.Scheme) { batchv2alpha1.AddToScheme(scheme) certificatesv1beta1.AddToScheme(scheme) extensionsv1beta1.AddToScheme(scheme) + networkingv1.AddToScheme(scheme) policyv1beta1.AddToScheme(scheme) rbacv1beta1.AddToScheme(scheme) rbacv1alpha1.AddToScheme(scheme) diff --git a/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/BUILD b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/BUILD new file mode 100644 index 0000000000000..028bc495b2754 --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/BUILD @@ -0,0 +1,45 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "admissionregistration_client.go", + "doc.go", + "externaladmissionhookconfiguration.go", + "generated_expansion.go", + "initializerconfiguration.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//pkg/client/clientset_generated/clientset/scheme:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/admissionregistration_client.go b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/admissionregistration_client.go new file mode 100644 index 0000000000000..688e9b68dcaa0 --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/admissionregistration_client.go @@ -0,0 +1,93 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +import ( + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + rest "k8s.io/client-go/rest" + v1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" + "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/scheme" +) + +type AdmissionregistrationV1alpha1Interface interface { + RESTClient() rest.Interface + ExternalAdmissionHookConfigurationsGetter + InitializerConfigurationsGetter +} + +// AdmissionregistrationV1alpha1Client is used to interact with features provided by the admissionregistration.k8s.io group. +type AdmissionregistrationV1alpha1Client struct { + restClient rest.Interface +} + +func (c *AdmissionregistrationV1alpha1Client) ExternalAdmissionHookConfigurations(namespace string) ExternalAdmissionHookConfigurationInterface { + return newExternalAdmissionHookConfigurations(c, namespace) +} + +func (c *AdmissionregistrationV1alpha1Client) InitializerConfigurations(namespace string) InitializerConfigurationInterface { + return newInitializerConfigurations(c, namespace) +} + +// NewForConfig creates a new AdmissionregistrationV1alpha1Client for the given config. +func NewForConfig(c *rest.Config) (*AdmissionregistrationV1alpha1Client, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &AdmissionregistrationV1alpha1Client{client}, nil +} + +// NewForConfigOrDie creates a new AdmissionregistrationV1alpha1Client for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *AdmissionregistrationV1alpha1Client { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new AdmissionregistrationV1alpha1Client for the given RESTClient. +func New(c rest.Interface) *AdmissionregistrationV1alpha1Client { + return &AdmissionregistrationV1alpha1Client{c} +} + +func setConfigDefaults(config *rest.Config) error { + gv := v1alpha1.SchemeGroupVersion + config.GroupVersion = &gv + config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *AdmissionregistrationV1alpha1Client) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/doc.go b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/doc.go similarity index 100% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/doc.go rename to pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/doc.go diff --git a/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go new file mode 100644 index 0000000000000..bb70893e283d7 --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" + v1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" + scheme "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/scheme" +) + +// ExternalAdmissionHookConfigurationsGetter has a method to return a ExternalAdmissionHookConfigurationInterface. +// A group's client should implement this interface. +type ExternalAdmissionHookConfigurationsGetter interface { + ExternalAdmissionHookConfigurations(namespace string) ExternalAdmissionHookConfigurationInterface +} + +// ExternalAdmissionHookConfigurationInterface has methods to work with ExternalAdmissionHookConfiguration resources. +type ExternalAdmissionHookConfigurationInterface interface { + Create(*v1alpha1.ExternalAdmissionHookConfiguration) (*v1alpha1.ExternalAdmissionHookConfiguration, error) + Update(*v1alpha1.ExternalAdmissionHookConfiguration) (*v1alpha1.ExternalAdmissionHookConfiguration, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1alpha1.ExternalAdmissionHookConfiguration, error) + List(opts v1.ListOptions) (*v1alpha1.ExternalAdmissionHookConfigurationList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) + ExternalAdmissionHookConfigurationExpansion +} + +// externalAdmissionHookConfigurations implements ExternalAdmissionHookConfigurationInterface +type externalAdmissionHookConfigurations struct { + client rest.Interface + ns string +} + +// newExternalAdmissionHookConfigurations returns a ExternalAdmissionHookConfigurations +func newExternalAdmissionHookConfigurations(c *AdmissionregistrationV1alpha1Client, namespace string) *externalAdmissionHookConfigurations { + return &externalAdmissionHookConfigurations{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a externalAdmissionHookConfiguration and creates it. Returns the server's representation of the externalAdmissionHookConfiguration, and an error, if there is any. +func (c *externalAdmissionHookConfigurations) Create(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + result = &v1alpha1.ExternalAdmissionHookConfiguration{} + err = c.client.Post(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + Body(externalAdmissionHookConfiguration). + Do(). + Into(result) + return +} + +// Update takes the representation of a externalAdmissionHookConfiguration and updates it. Returns the server's representation of the externalAdmissionHookConfiguration, and an error, if there is any. +func (c *externalAdmissionHookConfigurations) Update(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + result = &v1alpha1.ExternalAdmissionHookConfiguration{} + err = c.client.Put(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + Name(externalAdmissionHookConfiguration.Name). + Body(externalAdmissionHookConfiguration). + Do(). + Into(result) + return +} + +// Delete takes name of the externalAdmissionHookConfiguration and deletes it. Returns an error if one occurs. +func (c *externalAdmissionHookConfigurations) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *externalAdmissionHookConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the externalAdmissionHookConfiguration, and returns the corresponding externalAdmissionHookConfiguration object, and an error if there is any. +func (c *externalAdmissionHookConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + result = &v1alpha1.ExternalAdmissionHookConfiguration{} + err = c.client.Get(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of ExternalAdmissionHookConfigurations that match those selectors. +func (c *externalAdmissionHookConfigurations) List(opts v1.ListOptions) (result *v1alpha1.ExternalAdmissionHookConfigurationList, err error) { + result = &v1alpha1.ExternalAdmissionHookConfigurationList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested externalAdmissionHookConfigurations. +func (c *externalAdmissionHookConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched externalAdmissionHookConfiguration. +func (c *externalAdmissionHookConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + result = &v1alpha1.ExternalAdmissionHookConfiguration{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/BUILD b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/BUILD new file mode 100644 index 0000000000000..5e4c3aeb3360d --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/BUILD @@ -0,0 +1,43 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "fake_admissionregistration_client.go", + "fake_externaladmissionhookconfiguration.go", + "fake_initializerconfiguration.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + "//vendor/k8s.io/client-go/testing:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/fake/doc.go b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/doc.go similarity index 100% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/fake/doc.go rename to pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/doc.go diff --git a/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/fake_admissionregistration_client.go b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/fake_admissionregistration_client.go new file mode 100644 index 0000000000000..7e9fb050ab456 --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/fake_admissionregistration_client.go @@ -0,0 +1,42 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + rest "k8s.io/client-go/rest" + testing "k8s.io/client-go/testing" + v1alpha1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1" +) + +type FakeAdmissionregistrationV1alpha1 struct { + *testing.Fake +} + +func (c *FakeAdmissionregistrationV1alpha1) ExternalAdmissionHookConfigurations(namespace string) v1alpha1.ExternalAdmissionHookConfigurationInterface { + return &FakeExternalAdmissionHookConfigurations{c, namespace} +} + +func (c *FakeAdmissionregistrationV1alpha1) InitializerConfigurations(namespace string) v1alpha1.InitializerConfigurationInterface { + return &FakeInitializerConfigurations{c, namespace} +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *FakeAdmissionregistrationV1alpha1) RESTClient() rest.Interface { + var ret *rest.RESTClient + return ret +} diff --git a/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/fake_externaladmissionhookconfiguration.go b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/fake_externaladmissionhookconfiguration.go new file mode 100644 index 0000000000000..39c8fc091edf7 --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/fake_externaladmissionhookconfiguration.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + labels "k8s.io/apimachinery/pkg/labels" + schema "k8s.io/apimachinery/pkg/runtime/schema" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + testing "k8s.io/client-go/testing" + v1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" +) + +// FakeExternalAdmissionHookConfigurations implements ExternalAdmissionHookConfigurationInterface +type FakeExternalAdmissionHookConfigurations struct { + Fake *FakeAdmissionregistrationV1alpha1 + ns string +} + +var externaladmissionhookconfigurationsResource = schema.GroupVersionResource{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Resource: "externaladmissionhookconfigurations"} + +var externaladmissionhookconfigurationsKind = schema.GroupVersionKind{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Kind: "ExternalAdmissionHookConfiguration"} + +func (c *FakeExternalAdmissionHookConfigurations) Create(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewCreateAction(externaladmissionhookconfigurationsResource, c.ns, externalAdmissionHookConfiguration), &v1alpha1.ExternalAdmissionHookConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), err +} + +func (c *FakeExternalAdmissionHookConfigurations) Update(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewUpdateAction(externaladmissionhookconfigurationsResource, c.ns, externalAdmissionHookConfiguration), &v1alpha1.ExternalAdmissionHookConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), err +} + +func (c *FakeExternalAdmissionHookConfigurations) Delete(name string, options *v1.DeleteOptions) error { + _, err := c.Fake. + Invokes(testing.NewDeleteAction(externaladmissionhookconfigurationsResource, c.ns, name), &v1alpha1.ExternalAdmissionHookConfiguration{}) + + return err +} + +func (c *FakeExternalAdmissionHookConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + action := testing.NewDeleteCollectionAction(externaladmissionhookconfigurationsResource, c.ns, listOptions) + + _, err := c.Fake.Invokes(action, &v1alpha1.ExternalAdmissionHookConfigurationList{}) + return err +} + +func (c *FakeExternalAdmissionHookConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewGetAction(externaladmissionhookconfigurationsResource, c.ns, name), &v1alpha1.ExternalAdmissionHookConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), err +} + +func (c *FakeExternalAdmissionHookConfigurations) List(opts v1.ListOptions) (result *v1alpha1.ExternalAdmissionHookConfigurationList, err error) { + obj, err := c.Fake. + Invokes(testing.NewListAction(externaladmissionhookconfigurationsResource, externaladmissionhookconfigurationsKind, c.ns, opts), &v1alpha1.ExternalAdmissionHookConfigurationList{}) + + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &v1alpha1.ExternalAdmissionHookConfigurationList{} + for _, item := range obj.(*v1alpha1.ExternalAdmissionHookConfigurationList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested externalAdmissionHookConfigurations. +func (c *FakeExternalAdmissionHookConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + return c.Fake. + InvokesWatch(testing.NewWatchAction(externaladmissionhookconfigurationsResource, c.ns, opts)) + +} + +// Patch applies the patch and returns the patched externalAdmissionHookConfiguration. +func (c *FakeExternalAdmissionHookConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewPatchSubresourceAction(externaladmissionhookconfigurationsResource, c.ns, name, data, subresources...), &v1alpha1.ExternalAdmissionHookConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), err +} diff --git a/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/fake_initializerconfiguration.go b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/fake_initializerconfiguration.go new file mode 100644 index 0000000000000..e047683ecc4d3 --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/fake/fake_initializerconfiguration.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + labels "k8s.io/apimachinery/pkg/labels" + schema "k8s.io/apimachinery/pkg/runtime/schema" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + testing "k8s.io/client-go/testing" + v1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" +) + +// FakeInitializerConfigurations implements InitializerConfigurationInterface +type FakeInitializerConfigurations struct { + Fake *FakeAdmissionregistrationV1alpha1 + ns string +} + +var initializerconfigurationsResource = schema.GroupVersionResource{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Resource: "initializerconfigurations"} + +var initializerconfigurationsKind = schema.GroupVersionKind{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Kind: "InitializerConfiguration"} + +func (c *FakeInitializerConfigurations) Create(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewCreateAction(initializerconfigurationsResource, c.ns, initializerConfiguration), &v1alpha1.InitializerConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.InitializerConfiguration), err +} + +func (c *FakeInitializerConfigurations) Update(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewUpdateAction(initializerconfigurationsResource, c.ns, initializerConfiguration), &v1alpha1.InitializerConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.InitializerConfiguration), err +} + +func (c *FakeInitializerConfigurations) Delete(name string, options *v1.DeleteOptions) error { + _, err := c.Fake. + Invokes(testing.NewDeleteAction(initializerconfigurationsResource, c.ns, name), &v1alpha1.InitializerConfiguration{}) + + return err +} + +func (c *FakeInitializerConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + action := testing.NewDeleteCollectionAction(initializerconfigurationsResource, c.ns, listOptions) + + _, err := c.Fake.Invokes(action, &v1alpha1.InitializerConfigurationList{}) + return err +} + +func (c *FakeInitializerConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.InitializerConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewGetAction(initializerconfigurationsResource, c.ns, name), &v1alpha1.InitializerConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.InitializerConfiguration), err +} + +func (c *FakeInitializerConfigurations) List(opts v1.ListOptions) (result *v1alpha1.InitializerConfigurationList, err error) { + obj, err := c.Fake. + Invokes(testing.NewListAction(initializerconfigurationsResource, initializerconfigurationsKind, c.ns, opts), &v1alpha1.InitializerConfigurationList{}) + + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &v1alpha1.InitializerConfigurationList{} + for _, item := range obj.(*v1alpha1.InitializerConfigurationList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested initializerConfigurations. +func (c *FakeInitializerConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + return c.Fake. + InvokesWatch(testing.NewWatchAction(initializerconfigurationsResource, c.ns, opts)) + +} + +// Patch applies the patch and returns the patched initializerConfiguration. +func (c *FakeInitializerConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.InitializerConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewPatchSubresourceAction(initializerconfigurationsResource, c.ns, name, data, subresources...), &v1alpha1.InitializerConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.InitializerConfiguration), err +} diff --git a/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/generated_expansion.go b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/generated_expansion.go new file mode 100644 index 0000000000000..eef439ab4725a --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/generated_expansion.go @@ -0,0 +1,21 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +type ExternalAdmissionHookConfigurationExpansion interface{} + +type InitializerConfigurationExpansion interface{} diff --git a/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/initializerconfiguration.go b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/initializerconfiguration.go new file mode 100644 index 0000000000000..0452150d493b1 --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/admissionregistration/v1alpha1/initializerconfiguration.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" + v1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" + scheme "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/scheme" +) + +// InitializerConfigurationsGetter has a method to return a InitializerConfigurationInterface. +// A group's client should implement this interface. +type InitializerConfigurationsGetter interface { + InitializerConfigurations(namespace string) InitializerConfigurationInterface +} + +// InitializerConfigurationInterface has methods to work with InitializerConfiguration resources. +type InitializerConfigurationInterface interface { + Create(*v1alpha1.InitializerConfiguration) (*v1alpha1.InitializerConfiguration, error) + Update(*v1alpha1.InitializerConfiguration) (*v1alpha1.InitializerConfiguration, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1alpha1.InitializerConfiguration, error) + List(opts v1.ListOptions) (*v1alpha1.InitializerConfigurationList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.InitializerConfiguration, err error) + InitializerConfigurationExpansion +} + +// initializerConfigurations implements InitializerConfigurationInterface +type initializerConfigurations struct { + client rest.Interface + ns string +} + +// newInitializerConfigurations returns a InitializerConfigurations +func newInitializerConfigurations(c *AdmissionregistrationV1alpha1Client, namespace string) *initializerConfigurations { + return &initializerConfigurations{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a initializerConfiguration and creates it. Returns the server's representation of the initializerConfiguration, and an error, if there is any. +func (c *initializerConfigurations) Create(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) { + result = &v1alpha1.InitializerConfiguration{} + err = c.client.Post(). + Namespace(c.ns). + Resource("initializerconfigurations"). + Body(initializerConfiguration). + Do(). + Into(result) + return +} + +// Update takes the representation of a initializerConfiguration and updates it. Returns the server's representation of the initializerConfiguration, and an error, if there is any. +func (c *initializerConfigurations) Update(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) { + result = &v1alpha1.InitializerConfiguration{} + err = c.client.Put(). + Namespace(c.ns). + Resource("initializerconfigurations"). + Name(initializerConfiguration.Name). + Body(initializerConfiguration). + Do(). + Into(result) + return +} + +// Delete takes name of the initializerConfiguration and deletes it. Returns an error if one occurs. +func (c *initializerConfigurations) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("initializerconfigurations"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *initializerConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("initializerconfigurations"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the initializerConfiguration, and returns the corresponding initializerConfiguration object, and an error if there is any. +func (c *initializerConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.InitializerConfiguration, err error) { + result = &v1alpha1.InitializerConfiguration{} + err = c.client.Get(). + Namespace(c.ns). + Resource("initializerconfigurations"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of InitializerConfigurations that match those selectors. +func (c *initializerConfigurations) List(opts v1.ListOptions) (result *v1alpha1.InitializerConfigurationList, err error) { + result = &v1alpha1.InitializerConfigurationList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("initializerconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested initializerConfigurations. +func (c *initializerConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("initializerconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched initializerConfiguration. +func (c *initializerConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.InitializerConfiguration, err error) { + result = &v1alpha1.InitializerConfiguration{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("initializerconfigurations"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/BUILD b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/BUILD index 9f9b021022aa1..9312f7fa97af0 100644 --- a/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/BUILD +++ b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/BUILD @@ -11,6 +11,7 @@ go_library( name = "go_default_library", srcs = [ "apps_client.go", + "controllerrevision.go", "deployment.go", "doc.go", "generated_expansion.go", diff --git a/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/apps_client.go b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/apps_client.go index c15b515927438..18ab6a6f1059b 100644 --- a/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/apps_client.go +++ b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/apps_client.go @@ -25,6 +25,7 @@ import ( type AppsV1beta1Interface interface { RESTClient() rest.Interface + ControllerRevisionsGetter DeploymentsGetter ScalesGetter StatefulSetsGetter @@ -35,6 +36,10 @@ type AppsV1beta1Client struct { restClient rest.Interface } +func (c *AppsV1beta1Client) ControllerRevisions(namespace string) ControllerRevisionInterface { + return newControllerRevisions(c, namespace) +} + func (c *AppsV1beta1Client) Deployments(namespace string) DeploymentInterface { return newDeployments(c, namespace) } diff --git a/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/controllerrevision.go b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/controllerrevision.go new file mode 100644 index 0000000000000..ce536b0ddf0e1 --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/controllerrevision.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1beta1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" + v1beta1 "k8s.io/kubernetes/pkg/apis/apps/v1beta1" + scheme "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/scheme" +) + +// ControllerRevisionsGetter has a method to return a ControllerRevisionInterface. +// A group's client should implement this interface. +type ControllerRevisionsGetter interface { + ControllerRevisions(namespace string) ControllerRevisionInterface +} + +// ControllerRevisionInterface has methods to work with ControllerRevision resources. +type ControllerRevisionInterface interface { + Create(*v1beta1.ControllerRevision) (*v1beta1.ControllerRevision, error) + Update(*v1beta1.ControllerRevision) (*v1beta1.ControllerRevision, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1beta1.ControllerRevision, error) + List(opts v1.ListOptions) (*v1beta1.ControllerRevisionList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ControllerRevision, err error) + ControllerRevisionExpansion +} + +// controllerRevisions implements ControllerRevisionInterface +type controllerRevisions struct { + client rest.Interface + ns string +} + +// newControllerRevisions returns a ControllerRevisions +func newControllerRevisions(c *AppsV1beta1Client, namespace string) *controllerRevisions { + return &controllerRevisions{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a controllerRevision and creates it. Returns the server's representation of the controllerRevision, and an error, if there is any. +func (c *controllerRevisions) Create(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) { + result = &v1beta1.ControllerRevision{} + err = c.client.Post(). + Namespace(c.ns). + Resource("controllerrevisions"). + Body(controllerRevision). + Do(). + Into(result) + return +} + +// Update takes the representation of a controllerRevision and updates it. Returns the server's representation of the controllerRevision, and an error, if there is any. +func (c *controllerRevisions) Update(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) { + result = &v1beta1.ControllerRevision{} + err = c.client.Put(). + Namespace(c.ns). + Resource("controllerrevisions"). + Name(controllerRevision.Name). + Body(controllerRevision). + Do(). + Into(result) + return +} + +// Delete takes name of the controllerRevision and deletes it. Returns an error if one occurs. +func (c *controllerRevisions) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("controllerrevisions"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *controllerRevisions) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("controllerrevisions"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the controllerRevision, and returns the corresponding controllerRevision object, and an error if there is any. +func (c *controllerRevisions) Get(name string, options v1.GetOptions) (result *v1beta1.ControllerRevision, err error) { + result = &v1beta1.ControllerRevision{} + err = c.client.Get(). + Namespace(c.ns). + Resource("controllerrevisions"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of ControllerRevisions that match those selectors. +func (c *controllerRevisions) List(opts v1.ListOptions) (result *v1beta1.ControllerRevisionList, err error) { + result = &v1beta1.ControllerRevisionList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("controllerrevisions"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested controllerRevisions. +func (c *controllerRevisions) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("controllerrevisions"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched controllerRevision. +func (c *controllerRevisions) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ControllerRevision, err error) { + result = &v1beta1.ControllerRevision{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("controllerrevisions"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/fake/BUILD b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/fake/BUILD index 2ed6808e04d48..d728a4a24d185 100644 --- a/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/fake/BUILD +++ b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/fake/BUILD @@ -12,6 +12,7 @@ go_library( srcs = [ "doc.go", "fake_apps_client.go", + "fake_controllerrevision.go", "fake_deployment.go", "fake_scale.go", "fake_statefulset.go", diff --git a/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/fake/fake_apps_client.go b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/fake/fake_apps_client.go index 41dcf725ff2c7..fd73e179614f6 100644 --- a/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/fake/fake_apps_client.go +++ b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/fake/fake_apps_client.go @@ -26,6 +26,10 @@ type FakeAppsV1beta1 struct { *testing.Fake } +func (c *FakeAppsV1beta1) ControllerRevisions(namespace string) v1beta1.ControllerRevisionInterface { + return &FakeControllerRevisions{c, namespace} +} + func (c *FakeAppsV1beta1) Deployments(namespace string) v1beta1.DeploymentInterface { return &FakeDeployments{c, namespace} } diff --git a/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/fake/fake_controllerrevision.go b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/fake/fake_controllerrevision.go new file mode 100644 index 0000000000000..0a44b54646717 --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/fake/fake_controllerrevision.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + labels "k8s.io/apimachinery/pkg/labels" + schema "k8s.io/apimachinery/pkg/runtime/schema" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + testing "k8s.io/client-go/testing" + v1beta1 "k8s.io/kubernetes/pkg/apis/apps/v1beta1" +) + +// FakeControllerRevisions implements ControllerRevisionInterface +type FakeControllerRevisions struct { + Fake *FakeAppsV1beta1 + ns string +} + +var controllerrevisionsResource = schema.GroupVersionResource{Group: "apps", Version: "v1beta1", Resource: "controllerrevisions"} + +var controllerrevisionsKind = schema.GroupVersionKind{Group: "apps", Version: "v1beta1", Kind: "ControllerRevision"} + +func (c *FakeControllerRevisions) Create(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) { + obj, err := c.Fake. + Invokes(testing.NewCreateAction(controllerrevisionsResource, c.ns, controllerRevision), &v1beta1.ControllerRevision{}) + + if obj == nil { + return nil, err + } + return obj.(*v1beta1.ControllerRevision), err +} + +func (c *FakeControllerRevisions) Update(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) { + obj, err := c.Fake. + Invokes(testing.NewUpdateAction(controllerrevisionsResource, c.ns, controllerRevision), &v1beta1.ControllerRevision{}) + + if obj == nil { + return nil, err + } + return obj.(*v1beta1.ControllerRevision), err +} + +func (c *FakeControllerRevisions) Delete(name string, options *v1.DeleteOptions) error { + _, err := c.Fake. + Invokes(testing.NewDeleteAction(controllerrevisionsResource, c.ns, name), &v1beta1.ControllerRevision{}) + + return err +} + +func (c *FakeControllerRevisions) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + action := testing.NewDeleteCollectionAction(controllerrevisionsResource, c.ns, listOptions) + + _, err := c.Fake.Invokes(action, &v1beta1.ControllerRevisionList{}) + return err +} + +func (c *FakeControllerRevisions) Get(name string, options v1.GetOptions) (result *v1beta1.ControllerRevision, err error) { + obj, err := c.Fake. + Invokes(testing.NewGetAction(controllerrevisionsResource, c.ns, name), &v1beta1.ControllerRevision{}) + + if obj == nil { + return nil, err + } + return obj.(*v1beta1.ControllerRevision), err +} + +func (c *FakeControllerRevisions) List(opts v1.ListOptions) (result *v1beta1.ControllerRevisionList, err error) { + obj, err := c.Fake. + Invokes(testing.NewListAction(controllerrevisionsResource, controllerrevisionsKind, c.ns, opts), &v1beta1.ControllerRevisionList{}) + + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &v1beta1.ControllerRevisionList{} + for _, item := range obj.(*v1beta1.ControllerRevisionList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested controllerRevisions. +func (c *FakeControllerRevisions) Watch(opts v1.ListOptions) (watch.Interface, error) { + return c.Fake. + InvokesWatch(testing.NewWatchAction(controllerrevisionsResource, c.ns, opts)) + +} + +// Patch applies the patch and returns the patched controllerRevision. +func (c *FakeControllerRevisions) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ControllerRevision, err error) { + obj, err := c.Fake. + Invokes(testing.NewPatchSubresourceAction(controllerrevisionsResource, c.ns, name, data, subresources...), &v1beta1.ControllerRevision{}) + + if obj == nil { + return nil, err + } + return obj.(*v1beta1.ControllerRevision), err +} diff --git a/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/generated_expansion.go b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/generated_expansion.go index deca5c8663968..a091b902adfff 100644 --- a/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/generated_expansion.go +++ b/pkg/client/clientset_generated/clientset/typed/apps/v1beta1/generated_expansion.go @@ -16,6 +16,8 @@ limitations under the License. package v1beta1 +type ControllerRevisionExpansion interface{} + type DeploymentExpansion interface{} type ScaleExpansion interface{} diff --git a/pkg/client/clientset_generated/clientset/typed/networking/v1/BUILD b/pkg/client/clientset_generated/clientset/typed/networking/v1/BUILD new file mode 100644 index 0000000000000..5825141a6cc9a --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/networking/v1/BUILD @@ -0,0 +1,44 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "generated_expansion.go", + "networking_client.go", + "networkpolicy.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/networking/v1:go_default_library", + "//pkg/client/clientset_generated/clientset/scheme:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/client/clientset_generated/clientset/typed/networking/v1/fake:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/client/clientset_generated/clientset/typed/networking/v1/doc.go b/pkg/client/clientset_generated/clientset/typed/networking/v1/doc.go new file mode 100644 index 0000000000000..54673bfa73825 --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/networking/v1/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package has the automatically generated typed clients. +package v1 diff --git a/pkg/client/clientset_generated/clientset/typed/networking/v1/fake/BUILD b/pkg/client/clientset_generated/clientset/typed/networking/v1/fake/BUILD new file mode 100644 index 0000000000000..7a937d07ca324 --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/networking/v1/fake/BUILD @@ -0,0 +1,42 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "fake_networking_client.go", + "fake_networkpolicy.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/networking/v1:go_default_library", + "//pkg/client/clientset_generated/clientset/typed/networking/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + "//vendor/k8s.io/client-go/testing:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/client/clientset_generated/clientset/typed/networking/v1/fake/doc.go b/pkg/client/clientset_generated/clientset/typed/networking/v1/fake/doc.go new file mode 100644 index 0000000000000..c6548330a0d0a --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/networking/v1/fake/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This package is generated by client-gen with custom arguments. + +// Package fake has the automatically generated clients. +package fake diff --git a/pkg/client/clientset_generated/clientset/typed/networking/v1/fake/fake_networking_client.go b/pkg/client/clientset_generated/clientset/typed/networking/v1/fake/fake_networking_client.go new file mode 100644 index 0000000000000..9a3e3ca35dd76 --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/networking/v1/fake/fake_networking_client.go @@ -0,0 +1,38 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + rest "k8s.io/client-go/rest" + testing "k8s.io/client-go/testing" + v1 "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/networking/v1" +) + +type FakeNetworkingV1 struct { + *testing.Fake +} + +func (c *FakeNetworkingV1) NetworkPolicies(namespace string) v1.NetworkPolicyInterface { + return &FakeNetworkPolicies{c, namespace} +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *FakeNetworkingV1) RESTClient() rest.Interface { + var ret *rest.RESTClient + return ret +} diff --git a/pkg/client/clientset_generated/clientset/typed/networking/v1/fake/fake_networkpolicy.go b/pkg/client/clientset_generated/clientset/typed/networking/v1/fake/fake_networkpolicy.go new file mode 100644 index 0000000000000..adac8ab62e38b --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/networking/v1/fake/fake_networkpolicy.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + labels "k8s.io/apimachinery/pkg/labels" + schema "k8s.io/apimachinery/pkg/runtime/schema" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + testing "k8s.io/client-go/testing" + v1 "k8s.io/kubernetes/pkg/apis/networking/v1" +) + +// FakeNetworkPolicies implements NetworkPolicyInterface +type FakeNetworkPolicies struct { + Fake *FakeNetworkingV1 + ns string +} + +var networkpoliciesResource = schema.GroupVersionResource{Group: "networking.k8s.io", Version: "v1", Resource: "networkpolicies"} + +var networkpoliciesKind = schema.GroupVersionKind{Group: "networking.k8s.io", Version: "v1", Kind: "NetworkPolicy"} + +func (c *FakeNetworkPolicies) Create(networkPolicy *v1.NetworkPolicy) (result *v1.NetworkPolicy, err error) { + obj, err := c.Fake. + Invokes(testing.NewCreateAction(networkpoliciesResource, c.ns, networkPolicy), &v1.NetworkPolicy{}) + + if obj == nil { + return nil, err + } + return obj.(*v1.NetworkPolicy), err +} + +func (c *FakeNetworkPolicies) Update(networkPolicy *v1.NetworkPolicy) (result *v1.NetworkPolicy, err error) { + obj, err := c.Fake. + Invokes(testing.NewUpdateAction(networkpoliciesResource, c.ns, networkPolicy), &v1.NetworkPolicy{}) + + if obj == nil { + return nil, err + } + return obj.(*v1.NetworkPolicy), err +} + +func (c *FakeNetworkPolicies) Delete(name string, options *meta_v1.DeleteOptions) error { + _, err := c.Fake. + Invokes(testing.NewDeleteAction(networkpoliciesResource, c.ns, name), &v1.NetworkPolicy{}) + + return err +} + +func (c *FakeNetworkPolicies) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { + action := testing.NewDeleteCollectionAction(networkpoliciesResource, c.ns, listOptions) + + _, err := c.Fake.Invokes(action, &v1.NetworkPolicyList{}) + return err +} + +func (c *FakeNetworkPolicies) Get(name string, options meta_v1.GetOptions) (result *v1.NetworkPolicy, err error) { + obj, err := c.Fake. + Invokes(testing.NewGetAction(networkpoliciesResource, c.ns, name), &v1.NetworkPolicy{}) + + if obj == nil { + return nil, err + } + return obj.(*v1.NetworkPolicy), err +} + +func (c *FakeNetworkPolicies) List(opts meta_v1.ListOptions) (result *v1.NetworkPolicyList, err error) { + obj, err := c.Fake. + Invokes(testing.NewListAction(networkpoliciesResource, networkpoliciesKind, c.ns, opts), &v1.NetworkPolicyList{}) + + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &v1.NetworkPolicyList{} + for _, item := range obj.(*v1.NetworkPolicyList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested networkPolicies. +func (c *FakeNetworkPolicies) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + return c.Fake. + InvokesWatch(testing.NewWatchAction(networkpoliciesResource, c.ns, opts)) + +} + +// Patch applies the patch and returns the patched networkPolicy. +func (c *FakeNetworkPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.NetworkPolicy, err error) { + obj, err := c.Fake. + Invokes(testing.NewPatchSubresourceAction(networkpoliciesResource, c.ns, name, data, subresources...), &v1.NetworkPolicy{}) + + if obj == nil { + return nil, err + } + return obj.(*v1.NetworkPolicy), err +} diff --git a/pkg/client/clientset_generated/clientset/typed/networking/v1/generated_expansion.go b/pkg/client/clientset_generated/clientset/typed/networking/v1/generated_expansion.go new file mode 100644 index 0000000000000..cdd70ae3536bd --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/networking/v1/generated_expansion.go @@ -0,0 +1,19 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +type NetworkPolicyExpansion interface{} diff --git a/pkg/client/clientset_generated/clientset/typed/networking/v1/networking_client.go b/pkg/client/clientset_generated/clientset/typed/networking/v1/networking_client.go new file mode 100644 index 0000000000000..fcfd62ca3c251 --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/networking/v1/networking_client.go @@ -0,0 +1,88 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +import ( + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + rest "k8s.io/client-go/rest" + v1 "k8s.io/kubernetes/pkg/apis/networking/v1" + "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/scheme" +) + +type NetworkingV1Interface interface { + RESTClient() rest.Interface + NetworkPoliciesGetter +} + +// NetworkingV1Client is used to interact with features provided by the networking.k8s.io group. +type NetworkingV1Client struct { + restClient rest.Interface +} + +func (c *NetworkingV1Client) NetworkPolicies(namespace string) NetworkPolicyInterface { + return newNetworkPolicies(c, namespace) +} + +// NewForConfig creates a new NetworkingV1Client for the given config. +func NewForConfig(c *rest.Config) (*NetworkingV1Client, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &NetworkingV1Client{client}, nil +} + +// NewForConfigOrDie creates a new NetworkingV1Client for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *NetworkingV1Client { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new NetworkingV1Client for the given RESTClient. +func New(c rest.Interface) *NetworkingV1Client { + return &NetworkingV1Client{c} +} + +func setConfigDefaults(config *rest.Config) error { + gv := v1.SchemeGroupVersion + config.GroupVersion = &gv + config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *NetworkingV1Client) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/pkg/client/clientset_generated/clientset/typed/networking/v1/networkpolicy.go b/pkg/client/clientset_generated/clientset/typed/networking/v1/networkpolicy.go new file mode 100644 index 0000000000000..a4bbaa6c17c2f --- /dev/null +++ b/pkg/client/clientset_generated/clientset/typed/networking/v1/networkpolicy.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" + v1 "k8s.io/kubernetes/pkg/apis/networking/v1" + scheme "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/scheme" +) + +// NetworkPoliciesGetter has a method to return a NetworkPolicyInterface. +// A group's client should implement this interface. +type NetworkPoliciesGetter interface { + NetworkPolicies(namespace string) NetworkPolicyInterface +} + +// NetworkPolicyInterface has methods to work with NetworkPolicy resources. +type NetworkPolicyInterface interface { + Create(*v1.NetworkPolicy) (*v1.NetworkPolicy, error) + Update(*v1.NetworkPolicy) (*v1.NetworkPolicy, error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.NetworkPolicy, error) + List(opts meta_v1.ListOptions) (*v1.NetworkPolicyList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.NetworkPolicy, err error) + NetworkPolicyExpansion +} + +// networkPolicies implements NetworkPolicyInterface +type networkPolicies struct { + client rest.Interface + ns string +} + +// newNetworkPolicies returns a NetworkPolicies +func newNetworkPolicies(c *NetworkingV1Client, namespace string) *networkPolicies { + return &networkPolicies{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a networkPolicy and creates it. Returns the server's representation of the networkPolicy, and an error, if there is any. +func (c *networkPolicies) Create(networkPolicy *v1.NetworkPolicy) (result *v1.NetworkPolicy, err error) { + result = &v1.NetworkPolicy{} + err = c.client.Post(). + Namespace(c.ns). + Resource("networkpolicies"). + Body(networkPolicy). + Do(). + Into(result) + return +} + +// Update takes the representation of a networkPolicy and updates it. Returns the server's representation of the networkPolicy, and an error, if there is any. +func (c *networkPolicies) Update(networkPolicy *v1.NetworkPolicy) (result *v1.NetworkPolicy, err error) { + result = &v1.NetworkPolicy{} + err = c.client.Put(). + Namespace(c.ns). + Resource("networkpolicies"). + Name(networkPolicy.Name). + Body(networkPolicy). + Do(). + Into(result) + return +} + +// Delete takes name of the networkPolicy and deletes it. Returns an error if one occurs. +func (c *networkPolicies) Delete(name string, options *meta_v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("networkpolicies"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *networkPolicies) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("networkpolicies"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the networkPolicy, and returns the corresponding networkPolicy object, and an error if there is any. +func (c *networkPolicies) Get(name string, options meta_v1.GetOptions) (result *v1.NetworkPolicy, err error) { + result = &v1.NetworkPolicy{} + err = c.client.Get(). + Namespace(c.ns). + Resource("networkpolicies"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of NetworkPolicies that match those selectors. +func (c *networkPolicies) List(opts meta_v1.ListOptions) (result *v1.NetworkPolicyList, err error) { + result = &v1.NetworkPolicyList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("networkpolicies"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested networkPolicies. +func (c *networkPolicies) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("networkpolicies"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched networkPolicy. +func (c *networkPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.NetworkPolicy, err error) { + result = &v1.NetworkPolicy{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("networkpolicies"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/pkg/client/clientset_generated/internalclientset/BUILD b/pkg/client/clientset_generated/internalclientset/BUILD index 59ced73dcafae..9f943605f46fc 100644 --- a/pkg/client/clientset_generated/internalclientset/BUILD +++ b/pkg/client/clientset_generated/internalclientset/BUILD @@ -15,6 +15,7 @@ go_library( ], tags = ["automanaged"], deps = [ + "//pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/apps/internalversion:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/authentication/internalversion:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/authorization/internalversion:go_default_library", @@ -23,6 +24,7 @@ go_library( "//pkg/client/clientset_generated/internalclientset/typed/certificates/internalversion:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/core/internalversion:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/extensions/internalversion:go_default_library", + "//pkg/client/clientset_generated/internalclientset/typed/networking/internalversion:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/policy/internalversion:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/rbac/internalversion:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/settings/internalversion:go_default_library", @@ -47,6 +49,7 @@ filegroup( ":package-srcs", "//pkg/client/clientset_generated/internalclientset/fake:all-srcs", "//pkg/client/clientset_generated/internalclientset/scheme:all-srcs", + "//pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion:all-srcs", "//pkg/client/clientset_generated/internalclientset/typed/apps/internalversion:all-srcs", "//pkg/client/clientset_generated/internalclientset/typed/authentication/internalversion:all-srcs", "//pkg/client/clientset_generated/internalclientset/typed/authorization/internalversion:all-srcs", @@ -55,6 +58,7 @@ filegroup( "//pkg/client/clientset_generated/internalclientset/typed/certificates/internalversion:all-srcs", "//pkg/client/clientset_generated/internalclientset/typed/core/internalversion:all-srcs", "//pkg/client/clientset_generated/internalclientset/typed/extensions/internalversion:all-srcs", + "//pkg/client/clientset_generated/internalclientset/typed/networking/internalversion:all-srcs", "//pkg/client/clientset_generated/internalclientset/typed/policy/internalversion:all-srcs", "//pkg/client/clientset_generated/internalclientset/typed/rbac/internalversion:all-srcs", "//pkg/client/clientset_generated/internalclientset/typed/settings/internalversion:all-srcs", diff --git a/pkg/client/clientset_generated/internalclientset/clientset.go b/pkg/client/clientset_generated/internalclientset/clientset.go index 406531c16bc3f..d717dd8141f59 100644 --- a/pkg/client/clientset_generated/internalclientset/clientset.go +++ b/pkg/client/clientset_generated/internalclientset/clientset.go @@ -21,6 +21,7 @@ import ( discovery "k8s.io/client-go/discovery" rest "k8s.io/client-go/rest" flowcontrol "k8s.io/client-go/util/flowcontrol" + admissionregistrationinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion" appsinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion" authenticationinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/authentication/internalversion" authorizationinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/authorization/internalversion" @@ -29,6 +30,7 @@ import ( certificatesinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/certificates/internalversion" coreinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/core/internalversion" extensionsinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/extensions/internalversion" + networkinginternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion" policyinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/policy/internalversion" rbacinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/rbac/internalversion" settingsinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/settings/internalversion" @@ -37,6 +39,7 @@ import ( type Interface interface { Discovery() discovery.DiscoveryInterface + Admissionregistration() admissionregistrationinternalversion.AdmissionregistrationInterface Core() coreinternalversion.CoreInterface Apps() appsinternalversion.AppsInterface Authentication() authenticationinternalversion.AuthenticationInterface @@ -45,6 +48,7 @@ type Interface interface { Batch() batchinternalversion.BatchInterface Certificates() certificatesinternalversion.CertificatesInterface Extensions() extensionsinternalversion.ExtensionsInterface + Networking() networkinginternalversion.NetworkingInterface Policy() policyinternalversion.PolicyInterface Rbac() rbacinternalversion.RbacInterface Settings() settingsinternalversion.SettingsInterface @@ -55,6 +59,7 @@ type Interface interface { // version included in a Clientset. type Clientset struct { *discovery.DiscoveryClient + *admissionregistrationinternalversion.AdmissionregistrationClient *coreinternalversion.CoreClient *appsinternalversion.AppsClient *authenticationinternalversion.AuthenticationClient @@ -63,12 +68,21 @@ type Clientset struct { *batchinternalversion.BatchClient *certificatesinternalversion.CertificatesClient *extensionsinternalversion.ExtensionsClient + *networkinginternalversion.NetworkingClient *policyinternalversion.PolicyClient *rbacinternalversion.RbacClient *settingsinternalversion.SettingsClient *storageinternalversion.StorageClient } +// Admissionregistration retrieves the AdmissionregistrationClient +func (c *Clientset) Admissionregistration() admissionregistrationinternalversion.AdmissionregistrationInterface { + if c == nil { + return nil + } + return c.AdmissionregistrationClient +} + // Core retrieves the CoreClient func (c *Clientset) Core() coreinternalversion.CoreInterface { if c == nil { @@ -133,6 +147,14 @@ func (c *Clientset) Extensions() extensionsinternalversion.ExtensionsInterface { return c.ExtensionsClient } +// Networking retrieves the NetworkingClient +func (c *Clientset) Networking() networkinginternalversion.NetworkingInterface { + if c == nil { + return nil + } + return c.NetworkingClient +} + // Policy retrieves the PolicyClient func (c *Clientset) Policy() policyinternalversion.PolicyInterface { if c == nil { @@ -181,6 +203,10 @@ func NewForConfig(c *rest.Config) (*Clientset, error) { } var cs Clientset var err error + cs.AdmissionregistrationClient, err = admissionregistrationinternalversion.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } cs.CoreClient, err = coreinternalversion.NewForConfig(&configShallowCopy) if err != nil { return nil, err @@ -213,6 +239,10 @@ func NewForConfig(c *rest.Config) (*Clientset, error) { if err != nil { return nil, err } + cs.NetworkingClient, err = networkinginternalversion.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } cs.PolicyClient, err = policyinternalversion.NewForConfig(&configShallowCopy) if err != nil { return nil, err @@ -242,6 +272,7 @@ func NewForConfig(c *rest.Config) (*Clientset, error) { // panics if there is an error in the config. func NewForConfigOrDie(c *rest.Config) *Clientset { var cs Clientset + cs.AdmissionregistrationClient = admissionregistrationinternalversion.NewForConfigOrDie(c) cs.CoreClient = coreinternalversion.NewForConfigOrDie(c) cs.AppsClient = appsinternalversion.NewForConfigOrDie(c) cs.AuthenticationClient = authenticationinternalversion.NewForConfigOrDie(c) @@ -250,6 +281,7 @@ func NewForConfigOrDie(c *rest.Config) *Clientset { cs.BatchClient = batchinternalversion.NewForConfigOrDie(c) cs.CertificatesClient = certificatesinternalversion.NewForConfigOrDie(c) cs.ExtensionsClient = extensionsinternalversion.NewForConfigOrDie(c) + cs.NetworkingClient = networkinginternalversion.NewForConfigOrDie(c) cs.PolicyClient = policyinternalversion.NewForConfigOrDie(c) cs.RbacClient = rbacinternalversion.NewForConfigOrDie(c) cs.SettingsClient = settingsinternalversion.NewForConfigOrDie(c) @@ -262,6 +294,7 @@ func NewForConfigOrDie(c *rest.Config) *Clientset { // New creates a new Clientset for the given RESTClient. func New(c rest.Interface) *Clientset { var cs Clientset + cs.AdmissionregistrationClient = admissionregistrationinternalversion.New(c) cs.CoreClient = coreinternalversion.New(c) cs.AppsClient = appsinternalversion.New(c) cs.AuthenticationClient = authenticationinternalversion.New(c) @@ -270,6 +303,7 @@ func New(c rest.Interface) *Clientset { cs.BatchClient = batchinternalversion.New(c) cs.CertificatesClient = certificatesinternalversion.New(c) cs.ExtensionsClient = extensionsinternalversion.New(c) + cs.NetworkingClient = networkinginternalversion.New(c) cs.PolicyClient = policyinternalversion.New(c) cs.RbacClient = rbacinternalversion.New(c) cs.SettingsClient = settingsinternalversion.New(c) diff --git a/pkg/client/clientset_generated/internalclientset/fake/BUILD b/pkg/client/clientset_generated/internalclientset/fake/BUILD index 040d73a65fe54..97c9d17f46079 100644 --- a/pkg/client/clientset_generated/internalclientset/fake/BUILD +++ b/pkg/client/clientset_generated/internalclientset/fake/BUILD @@ -17,6 +17,7 @@ go_library( tags = ["automanaged"], deps = [ "//pkg/api:go_default_library", + "//pkg/apis/admissionregistration:go_default_library", "//pkg/apis/apps:go_default_library", "//pkg/apis/authentication:go_default_library", "//pkg/apis/authorization:go_default_library", @@ -24,11 +25,14 @@ go_library( "//pkg/apis/batch:go_default_library", "//pkg/apis/certificates:go_default_library", "//pkg/apis/extensions:go_default_library", + "//pkg/apis/networking:go_default_library", "//pkg/apis/policy:go_default_library", "//pkg/apis/rbac:go_default_library", "//pkg/apis/settings:go_default_library", "//pkg/apis/storage:go_default_library", "//pkg/client/clientset_generated/internalclientset:go_default_library", + "//pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion:go_default_library", + "//pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/apps/internalversion:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/fake:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/authentication/internalversion:go_default_library", @@ -45,6 +49,8 @@ go_library( "//pkg/client/clientset_generated/internalclientset/typed/core/internalversion/fake:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/extensions/internalversion:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/extensions/internalversion/fake:go_default_library", + "//pkg/client/clientset_generated/internalclientset/typed/networking/internalversion:go_default_library", + "//pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/policy/internalversion:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/policy/internalversion/fake:go_default_library", "//pkg/client/clientset_generated/internalclientset/typed/rbac/internalversion:go_default_library", diff --git a/pkg/client/clientset_generated/internalclientset/fake/clientset_generated.go b/pkg/client/clientset_generated/internalclientset/fake/clientset_generated.go index 5ae8510411ad4..8367c16d49030 100644 --- a/pkg/client/clientset_generated/internalclientset/fake/clientset_generated.go +++ b/pkg/client/clientset_generated/internalclientset/fake/clientset_generated.go @@ -23,6 +23,8 @@ import ( fakediscovery "k8s.io/client-go/discovery/fake" "k8s.io/client-go/testing" clientset "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset" + admissionregistrationinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion" + fakeadmissionregistrationinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake" appsinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion" fakeappsinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/fake" authenticationinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/authentication/internalversion" @@ -39,6 +41,8 @@ import ( fakecoreinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/core/internalversion/fake" extensionsinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/extensions/internalversion" fakeextensionsinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/extensions/internalversion/fake" + networkinginternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion" + fakenetworkinginternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake" policyinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/policy/internalversion" fakepolicyinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/policy/internalversion/fake" rbacinternalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/rbac/internalversion" @@ -82,6 +86,11 @@ func (c *Clientset) Discovery() discovery.DiscoveryInterface { var _ clientset.Interface = &Clientset{} +// Admissionregistration retrieves the AdmissionregistrationClient +func (c *Clientset) Admissionregistration() admissionregistrationinternalversion.AdmissionregistrationInterface { + return &fakeadmissionregistrationinternalversion.FakeAdmissionregistration{Fake: &c.Fake} +} + // Core retrieves the CoreClient func (c *Clientset) Core() coreinternalversion.CoreInterface { return &fakecoreinternalversion.FakeCore{Fake: &c.Fake} @@ -122,6 +131,11 @@ func (c *Clientset) Extensions() extensionsinternalversion.ExtensionsInterface { return &fakeextensionsinternalversion.FakeExtensions{Fake: &c.Fake} } +// Networking retrieves the NetworkingClient +func (c *Clientset) Networking() networkinginternalversion.NetworkingInterface { + return &fakenetworkinginternalversion.FakeNetworking{Fake: &c.Fake} +} + // Policy retrieves the PolicyClient func (c *Clientset) Policy() policyinternalversion.PolicyInterface { return &fakepolicyinternalversion.FakePolicy{Fake: &c.Fake} diff --git a/pkg/client/clientset_generated/internalclientset/fake/register.go b/pkg/client/clientset_generated/internalclientset/fake/register.go index d418245c49f8c..d7ea1feb497cd 100644 --- a/pkg/client/clientset_generated/internalclientset/fake/register.go +++ b/pkg/client/clientset_generated/internalclientset/fake/register.go @@ -22,6 +22,7 @@ import ( schema "k8s.io/apimachinery/pkg/runtime/schema" serializer "k8s.io/apimachinery/pkg/runtime/serializer" coreinternalversion "k8s.io/kubernetes/pkg/api" + admissionregistrationinternalversion "k8s.io/kubernetes/pkg/apis/admissionregistration" appsinternalversion "k8s.io/kubernetes/pkg/apis/apps" authenticationinternalversion "k8s.io/kubernetes/pkg/apis/authentication" authorizationinternalversion "k8s.io/kubernetes/pkg/apis/authorization" @@ -29,6 +30,7 @@ import ( batchinternalversion "k8s.io/kubernetes/pkg/apis/batch" certificatesinternalversion "k8s.io/kubernetes/pkg/apis/certificates" extensionsinternalversion "k8s.io/kubernetes/pkg/apis/extensions" + networkinginternalversion "k8s.io/kubernetes/pkg/apis/networking" policyinternalversion "k8s.io/kubernetes/pkg/apis/policy" rbacinternalversion "k8s.io/kubernetes/pkg/apis/rbac" settingsinternalversion "k8s.io/kubernetes/pkg/apis/settings" @@ -59,6 +61,7 @@ func init() { // After this, RawExtensions in Kubernetes types will serialize kube-aggregator types // correctly. func AddToScheme(scheme *runtime.Scheme) { + admissionregistrationinternalversion.AddToScheme(scheme) coreinternalversion.AddToScheme(scheme) appsinternalversion.AddToScheme(scheme) authenticationinternalversion.AddToScheme(scheme) @@ -67,6 +70,7 @@ func AddToScheme(scheme *runtime.Scheme) { batchinternalversion.AddToScheme(scheme) certificatesinternalversion.AddToScheme(scheme) extensionsinternalversion.AddToScheme(scheme) + networkinginternalversion.AddToScheme(scheme) policyinternalversion.AddToScheme(scheme) rbacinternalversion.AddToScheme(scheme) settingsinternalversion.AddToScheme(scheme) diff --git a/pkg/client/clientset_generated/internalclientset/scheme/BUILD b/pkg/client/clientset_generated/internalclientset/scheme/BUILD index e16d55c6568e8..674af6164a7c8 100644 --- a/pkg/client/clientset_generated/internalclientset/scheme/BUILD +++ b/pkg/client/clientset_generated/internalclientset/scheme/BUILD @@ -17,6 +17,7 @@ go_library( tags = ["automanaged"], deps = [ "//pkg/api/install:go_default_library", + "//pkg/apis/admissionregistration/install:go_default_library", "//pkg/apis/apps/install:go_default_library", "//pkg/apis/authentication/install:go_default_library", "//pkg/apis/authorization/install:go_default_library", @@ -25,6 +26,7 @@ go_library( "//pkg/apis/certificates/install:go_default_library", "//pkg/apis/componentconfig/install:go_default_library", "//pkg/apis/extensions/install:go_default_library", + "//pkg/apis/networking/install:go_default_library", "//pkg/apis/policy/install:go_default_library", "//pkg/apis/rbac/install:go_default_library", "//pkg/apis/settings/install:go_default_library", diff --git a/pkg/client/clientset_generated/internalclientset/scheme/register.go b/pkg/client/clientset_generated/internalclientset/scheme/register.go index e524195a5db69..4abac4a62356b 100644 --- a/pkg/client/clientset_generated/internalclientset/scheme/register.go +++ b/pkg/client/clientset_generated/internalclientset/scheme/register.go @@ -24,6 +24,7 @@ import ( schema "k8s.io/apimachinery/pkg/runtime/schema" serializer "k8s.io/apimachinery/pkg/runtime/serializer" core "k8s.io/kubernetes/pkg/api/install" + admissionregistration "k8s.io/kubernetes/pkg/apis/admissionregistration/install" apps "k8s.io/kubernetes/pkg/apis/apps/install" authentication "k8s.io/kubernetes/pkg/apis/authentication/install" authorization "k8s.io/kubernetes/pkg/apis/authorization/install" @@ -31,6 +32,7 @@ import ( batch "k8s.io/kubernetes/pkg/apis/batch/install" certificates "k8s.io/kubernetes/pkg/apis/certificates/install" extensions "k8s.io/kubernetes/pkg/apis/extensions/install" + networking "k8s.io/kubernetes/pkg/apis/networking/install" policy "k8s.io/kubernetes/pkg/apis/policy/install" rbac "k8s.io/kubernetes/pkg/apis/rbac/install" settings "k8s.io/kubernetes/pkg/apis/settings/install" @@ -52,6 +54,7 @@ func init() { // Install registers the API group and adds types to a scheme func Install(groupFactoryRegistry announced.APIGroupFactoryRegistry, registry *registered.APIRegistrationManager, scheme *runtime.Scheme) { + admissionregistration.Install(groupFactoryRegistry, registry, scheme) core.Install(groupFactoryRegistry, registry, scheme) apps.Install(groupFactoryRegistry, registry, scheme) authentication.Install(groupFactoryRegistry, registry, scheme) @@ -60,6 +63,7 @@ func Install(groupFactoryRegistry announced.APIGroupFactoryRegistry, registry *r batch.Install(groupFactoryRegistry, registry, scheme) certificates.Install(groupFactoryRegistry, registry, scheme) extensions.Install(groupFactoryRegistry, registry, scheme) + networking.Install(groupFactoryRegistry, registry, scheme) policy.Install(groupFactoryRegistry, registry, scheme) rbac.Install(groupFactoryRegistry, registry, scheme) settings.Install(groupFactoryRegistry, registry, scheme) diff --git a/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/BUILD b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/BUILD new file mode 100644 index 0000000000000..c8e974c5f0faa --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/BUILD @@ -0,0 +1,44 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "admissionregistration_client.go", + "doc.go", + "externaladmissionhookconfiguration.go", + "generated_expansion.go", + "initializerconfiguration.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/admissionregistration:go_default_library", + "//pkg/client/clientset_generated/internalclientset/scheme:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/admissionregistration_client.go b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/admissionregistration_client.go new file mode 100644 index 0000000000000..a6e023ef16337 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/admissionregistration_client.go @@ -0,0 +1,104 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package internalversion + +import ( + rest "k8s.io/client-go/rest" + "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/scheme" +) + +type AdmissionregistrationInterface interface { + RESTClient() rest.Interface + ExternalAdmissionHookConfigurationsGetter + InitializerConfigurationsGetter +} + +// AdmissionregistrationClient is used to interact with features provided by the admissionregistration.k8s.io group. +type AdmissionregistrationClient struct { + restClient rest.Interface +} + +func (c *AdmissionregistrationClient) ExternalAdmissionHookConfigurations(namespace string) ExternalAdmissionHookConfigurationInterface { + return newExternalAdmissionHookConfigurations(c, namespace) +} + +func (c *AdmissionregistrationClient) InitializerConfigurations(namespace string) InitializerConfigurationInterface { + return newInitializerConfigurations(c, namespace) +} + +// NewForConfig creates a new AdmissionregistrationClient for the given config. +func NewForConfig(c *rest.Config) (*AdmissionregistrationClient, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &AdmissionregistrationClient{client}, nil +} + +// NewForConfigOrDie creates a new AdmissionregistrationClient for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *AdmissionregistrationClient { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new AdmissionregistrationClient for the given RESTClient. +func New(c rest.Interface) *AdmissionregistrationClient { + return &AdmissionregistrationClient{c} +} + +func setConfigDefaults(config *rest.Config) error { + g, err := scheme.Registry.Group("admissionregistration.k8s.io") + if err != nil { + return err + } + + config.APIPath = "/apis" + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + if config.GroupVersion == nil || config.GroupVersion.Group != g.GroupVersion.Group { + gv := g.GroupVersion + config.GroupVersion = &gv + } + config.NegotiatedSerializer = scheme.Codecs + + if config.QPS == 0 { + config.QPS = 5 + } + if config.Burst == 0 { + config.Burst = 10 + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *AdmissionregistrationClient) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/doc.go b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/doc.go new file mode 100644 index 0000000000000..0a27970fbb3b7 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This package is generated by client-gen with the default arguments. + +// This package has the automatically generated typed clients. +package internalversion diff --git a/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/externaladmissionhookconfiguration.go b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/externaladmissionhookconfiguration.go new file mode 100644 index 0000000000000..1d81625c6d2c9 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/externaladmissionhookconfiguration.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package internalversion + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" + admissionregistration "k8s.io/kubernetes/pkg/apis/admissionregistration" + scheme "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/scheme" +) + +// ExternalAdmissionHookConfigurationsGetter has a method to return a ExternalAdmissionHookConfigurationInterface. +// A group's client should implement this interface. +type ExternalAdmissionHookConfigurationsGetter interface { + ExternalAdmissionHookConfigurations(namespace string) ExternalAdmissionHookConfigurationInterface +} + +// ExternalAdmissionHookConfigurationInterface has methods to work with ExternalAdmissionHookConfiguration resources. +type ExternalAdmissionHookConfigurationInterface interface { + Create(*admissionregistration.ExternalAdmissionHookConfiguration) (*admissionregistration.ExternalAdmissionHookConfiguration, error) + Update(*admissionregistration.ExternalAdmissionHookConfiguration) (*admissionregistration.ExternalAdmissionHookConfiguration, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*admissionregistration.ExternalAdmissionHookConfiguration, error) + List(opts v1.ListOptions) (*admissionregistration.ExternalAdmissionHookConfigurationList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *admissionregistration.ExternalAdmissionHookConfiguration, err error) + ExternalAdmissionHookConfigurationExpansion +} + +// externalAdmissionHookConfigurations implements ExternalAdmissionHookConfigurationInterface +type externalAdmissionHookConfigurations struct { + client rest.Interface + ns string +} + +// newExternalAdmissionHookConfigurations returns a ExternalAdmissionHookConfigurations +func newExternalAdmissionHookConfigurations(c *AdmissionregistrationClient, namespace string) *externalAdmissionHookConfigurations { + return &externalAdmissionHookConfigurations{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a externalAdmissionHookConfiguration and creates it. Returns the server's representation of the externalAdmissionHookConfiguration, and an error, if there is any. +func (c *externalAdmissionHookConfigurations) Create(externalAdmissionHookConfiguration *admissionregistration.ExternalAdmissionHookConfiguration) (result *admissionregistration.ExternalAdmissionHookConfiguration, err error) { + result = &admissionregistration.ExternalAdmissionHookConfiguration{} + err = c.client.Post(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + Body(externalAdmissionHookConfiguration). + Do(). + Into(result) + return +} + +// Update takes the representation of a externalAdmissionHookConfiguration and updates it. Returns the server's representation of the externalAdmissionHookConfiguration, and an error, if there is any. +func (c *externalAdmissionHookConfigurations) Update(externalAdmissionHookConfiguration *admissionregistration.ExternalAdmissionHookConfiguration) (result *admissionregistration.ExternalAdmissionHookConfiguration, err error) { + result = &admissionregistration.ExternalAdmissionHookConfiguration{} + err = c.client.Put(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + Name(externalAdmissionHookConfiguration.Name). + Body(externalAdmissionHookConfiguration). + Do(). + Into(result) + return +} + +// Delete takes name of the externalAdmissionHookConfiguration and deletes it. Returns an error if one occurs. +func (c *externalAdmissionHookConfigurations) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *externalAdmissionHookConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the externalAdmissionHookConfiguration, and returns the corresponding externalAdmissionHookConfiguration object, and an error if there is any. +func (c *externalAdmissionHookConfigurations) Get(name string, options v1.GetOptions) (result *admissionregistration.ExternalAdmissionHookConfiguration, err error) { + result = &admissionregistration.ExternalAdmissionHookConfiguration{} + err = c.client.Get(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of ExternalAdmissionHookConfigurations that match those selectors. +func (c *externalAdmissionHookConfigurations) List(opts v1.ListOptions) (result *admissionregistration.ExternalAdmissionHookConfigurationList, err error) { + result = &admissionregistration.ExternalAdmissionHookConfigurationList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested externalAdmissionHookConfigurations. +func (c *externalAdmissionHookConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched externalAdmissionHookConfiguration. +func (c *externalAdmissionHookConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *admissionregistration.ExternalAdmissionHookConfiguration, err error) { + result = &admissionregistration.ExternalAdmissionHookConfiguration{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/BUILD b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/BUILD new file mode 100644 index 0000000000000..925360762aef5 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/BUILD @@ -0,0 +1,43 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "fake_admissionregistration_client.go", + "fake_externaladmissionhookconfiguration.go", + "fake_initializerconfiguration.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/admissionregistration:go_default_library", + "//pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + "//vendor/k8s.io/client-go/testing:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/doc.go b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/doc.go new file mode 100644 index 0000000000000..a0ecb96ba17bd --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This package is generated by client-gen with the default arguments. + +// Package fake has the automatically generated clients. +package fake diff --git a/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/fake_admissionregistration_client.go b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/fake_admissionregistration_client.go new file mode 100644 index 0000000000000..b375ff9e7d146 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/fake_admissionregistration_client.go @@ -0,0 +1,42 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + rest "k8s.io/client-go/rest" + testing "k8s.io/client-go/testing" + internalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion" +) + +type FakeAdmissionregistration struct { + *testing.Fake +} + +func (c *FakeAdmissionregistration) ExternalAdmissionHookConfigurations(namespace string) internalversion.ExternalAdmissionHookConfigurationInterface { + return &FakeExternalAdmissionHookConfigurations{c, namespace} +} + +func (c *FakeAdmissionregistration) InitializerConfigurations(namespace string) internalversion.InitializerConfigurationInterface { + return &FakeInitializerConfigurations{c, namespace} +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *FakeAdmissionregistration) RESTClient() rest.Interface { + var ret *rest.RESTClient + return ret +} diff --git a/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/fake_externaladmissionhookconfiguration.go b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/fake_externaladmissionhookconfiguration.go new file mode 100644 index 0000000000000..299972a068a39 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/fake_externaladmissionhookconfiguration.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + labels "k8s.io/apimachinery/pkg/labels" + schema "k8s.io/apimachinery/pkg/runtime/schema" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + testing "k8s.io/client-go/testing" + admissionregistration "k8s.io/kubernetes/pkg/apis/admissionregistration" +) + +// FakeExternalAdmissionHookConfigurations implements ExternalAdmissionHookConfigurationInterface +type FakeExternalAdmissionHookConfigurations struct { + Fake *FakeAdmissionregistration + ns string +} + +var externaladmissionhookconfigurationsResource = schema.GroupVersionResource{Group: "admissionregistration.k8s.io", Version: "", Resource: "externaladmissionhookconfigurations"} + +var externaladmissionhookconfigurationsKind = schema.GroupVersionKind{Group: "admissionregistration.k8s.io", Version: "", Kind: "ExternalAdmissionHookConfiguration"} + +func (c *FakeExternalAdmissionHookConfigurations) Create(externalAdmissionHookConfiguration *admissionregistration.ExternalAdmissionHookConfiguration) (result *admissionregistration.ExternalAdmissionHookConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewCreateAction(externaladmissionhookconfigurationsResource, c.ns, externalAdmissionHookConfiguration), &admissionregistration.ExternalAdmissionHookConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*admissionregistration.ExternalAdmissionHookConfiguration), err +} + +func (c *FakeExternalAdmissionHookConfigurations) Update(externalAdmissionHookConfiguration *admissionregistration.ExternalAdmissionHookConfiguration) (result *admissionregistration.ExternalAdmissionHookConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewUpdateAction(externaladmissionhookconfigurationsResource, c.ns, externalAdmissionHookConfiguration), &admissionregistration.ExternalAdmissionHookConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*admissionregistration.ExternalAdmissionHookConfiguration), err +} + +func (c *FakeExternalAdmissionHookConfigurations) Delete(name string, options *v1.DeleteOptions) error { + _, err := c.Fake. + Invokes(testing.NewDeleteAction(externaladmissionhookconfigurationsResource, c.ns, name), &admissionregistration.ExternalAdmissionHookConfiguration{}) + + return err +} + +func (c *FakeExternalAdmissionHookConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + action := testing.NewDeleteCollectionAction(externaladmissionhookconfigurationsResource, c.ns, listOptions) + + _, err := c.Fake.Invokes(action, &admissionregistration.ExternalAdmissionHookConfigurationList{}) + return err +} + +func (c *FakeExternalAdmissionHookConfigurations) Get(name string, options v1.GetOptions) (result *admissionregistration.ExternalAdmissionHookConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewGetAction(externaladmissionhookconfigurationsResource, c.ns, name), &admissionregistration.ExternalAdmissionHookConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*admissionregistration.ExternalAdmissionHookConfiguration), err +} + +func (c *FakeExternalAdmissionHookConfigurations) List(opts v1.ListOptions) (result *admissionregistration.ExternalAdmissionHookConfigurationList, err error) { + obj, err := c.Fake. + Invokes(testing.NewListAction(externaladmissionhookconfigurationsResource, externaladmissionhookconfigurationsKind, c.ns, opts), &admissionregistration.ExternalAdmissionHookConfigurationList{}) + + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &admissionregistration.ExternalAdmissionHookConfigurationList{} + for _, item := range obj.(*admissionregistration.ExternalAdmissionHookConfigurationList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested externalAdmissionHookConfigurations. +func (c *FakeExternalAdmissionHookConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + return c.Fake. + InvokesWatch(testing.NewWatchAction(externaladmissionhookconfigurationsResource, c.ns, opts)) + +} + +// Patch applies the patch and returns the patched externalAdmissionHookConfiguration. +func (c *FakeExternalAdmissionHookConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *admissionregistration.ExternalAdmissionHookConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewPatchSubresourceAction(externaladmissionhookconfigurationsResource, c.ns, name, data, subresources...), &admissionregistration.ExternalAdmissionHookConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*admissionregistration.ExternalAdmissionHookConfiguration), err +} diff --git a/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/fake_initializerconfiguration.go b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/fake_initializerconfiguration.go new file mode 100644 index 0000000000000..72f39df33e141 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/fake/fake_initializerconfiguration.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + labels "k8s.io/apimachinery/pkg/labels" + schema "k8s.io/apimachinery/pkg/runtime/schema" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + testing "k8s.io/client-go/testing" + admissionregistration "k8s.io/kubernetes/pkg/apis/admissionregistration" +) + +// FakeInitializerConfigurations implements InitializerConfigurationInterface +type FakeInitializerConfigurations struct { + Fake *FakeAdmissionregistration + ns string +} + +var initializerconfigurationsResource = schema.GroupVersionResource{Group: "admissionregistration.k8s.io", Version: "", Resource: "initializerconfigurations"} + +var initializerconfigurationsKind = schema.GroupVersionKind{Group: "admissionregistration.k8s.io", Version: "", Kind: "InitializerConfiguration"} + +func (c *FakeInitializerConfigurations) Create(initializerConfiguration *admissionregistration.InitializerConfiguration) (result *admissionregistration.InitializerConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewCreateAction(initializerconfigurationsResource, c.ns, initializerConfiguration), &admissionregistration.InitializerConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*admissionregistration.InitializerConfiguration), err +} + +func (c *FakeInitializerConfigurations) Update(initializerConfiguration *admissionregistration.InitializerConfiguration) (result *admissionregistration.InitializerConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewUpdateAction(initializerconfigurationsResource, c.ns, initializerConfiguration), &admissionregistration.InitializerConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*admissionregistration.InitializerConfiguration), err +} + +func (c *FakeInitializerConfigurations) Delete(name string, options *v1.DeleteOptions) error { + _, err := c.Fake. + Invokes(testing.NewDeleteAction(initializerconfigurationsResource, c.ns, name), &admissionregistration.InitializerConfiguration{}) + + return err +} + +func (c *FakeInitializerConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + action := testing.NewDeleteCollectionAction(initializerconfigurationsResource, c.ns, listOptions) + + _, err := c.Fake.Invokes(action, &admissionregistration.InitializerConfigurationList{}) + return err +} + +func (c *FakeInitializerConfigurations) Get(name string, options v1.GetOptions) (result *admissionregistration.InitializerConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewGetAction(initializerconfigurationsResource, c.ns, name), &admissionregistration.InitializerConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*admissionregistration.InitializerConfiguration), err +} + +func (c *FakeInitializerConfigurations) List(opts v1.ListOptions) (result *admissionregistration.InitializerConfigurationList, err error) { + obj, err := c.Fake. + Invokes(testing.NewListAction(initializerconfigurationsResource, initializerconfigurationsKind, c.ns, opts), &admissionregistration.InitializerConfigurationList{}) + + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &admissionregistration.InitializerConfigurationList{} + for _, item := range obj.(*admissionregistration.InitializerConfigurationList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested initializerConfigurations. +func (c *FakeInitializerConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + return c.Fake. + InvokesWatch(testing.NewWatchAction(initializerconfigurationsResource, c.ns, opts)) + +} + +// Patch applies the patch and returns the patched initializerConfiguration. +func (c *FakeInitializerConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *admissionregistration.InitializerConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewPatchSubresourceAction(initializerconfigurationsResource, c.ns, name, data, subresources...), &admissionregistration.InitializerConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*admissionregistration.InitializerConfiguration), err +} diff --git a/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/generated_expansion.go b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/generated_expansion.go new file mode 100644 index 0000000000000..631817dea3f77 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/generated_expansion.go @@ -0,0 +1,21 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package internalversion + +type ExternalAdmissionHookConfigurationExpansion interface{} + +type InitializerConfigurationExpansion interface{} diff --git a/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/initializerconfiguration.go b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/initializerconfiguration.go new file mode 100644 index 0000000000000..bcb4a8bb4b48c --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/admissionregistration/internalversion/initializerconfiguration.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package internalversion + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" + admissionregistration "k8s.io/kubernetes/pkg/apis/admissionregistration" + scheme "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/scheme" +) + +// InitializerConfigurationsGetter has a method to return a InitializerConfigurationInterface. +// A group's client should implement this interface. +type InitializerConfigurationsGetter interface { + InitializerConfigurations(namespace string) InitializerConfigurationInterface +} + +// InitializerConfigurationInterface has methods to work with InitializerConfiguration resources. +type InitializerConfigurationInterface interface { + Create(*admissionregistration.InitializerConfiguration) (*admissionregistration.InitializerConfiguration, error) + Update(*admissionregistration.InitializerConfiguration) (*admissionregistration.InitializerConfiguration, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*admissionregistration.InitializerConfiguration, error) + List(opts v1.ListOptions) (*admissionregistration.InitializerConfigurationList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *admissionregistration.InitializerConfiguration, err error) + InitializerConfigurationExpansion +} + +// initializerConfigurations implements InitializerConfigurationInterface +type initializerConfigurations struct { + client rest.Interface + ns string +} + +// newInitializerConfigurations returns a InitializerConfigurations +func newInitializerConfigurations(c *AdmissionregistrationClient, namespace string) *initializerConfigurations { + return &initializerConfigurations{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a initializerConfiguration and creates it. Returns the server's representation of the initializerConfiguration, and an error, if there is any. +func (c *initializerConfigurations) Create(initializerConfiguration *admissionregistration.InitializerConfiguration) (result *admissionregistration.InitializerConfiguration, err error) { + result = &admissionregistration.InitializerConfiguration{} + err = c.client.Post(). + Namespace(c.ns). + Resource("initializerconfigurations"). + Body(initializerConfiguration). + Do(). + Into(result) + return +} + +// Update takes the representation of a initializerConfiguration and updates it. Returns the server's representation of the initializerConfiguration, and an error, if there is any. +func (c *initializerConfigurations) Update(initializerConfiguration *admissionregistration.InitializerConfiguration) (result *admissionregistration.InitializerConfiguration, err error) { + result = &admissionregistration.InitializerConfiguration{} + err = c.client.Put(). + Namespace(c.ns). + Resource("initializerconfigurations"). + Name(initializerConfiguration.Name). + Body(initializerConfiguration). + Do(). + Into(result) + return +} + +// Delete takes name of the initializerConfiguration and deletes it. Returns an error if one occurs. +func (c *initializerConfigurations) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("initializerconfigurations"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *initializerConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("initializerconfigurations"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the initializerConfiguration, and returns the corresponding initializerConfiguration object, and an error if there is any. +func (c *initializerConfigurations) Get(name string, options v1.GetOptions) (result *admissionregistration.InitializerConfiguration, err error) { + result = &admissionregistration.InitializerConfiguration{} + err = c.client.Get(). + Namespace(c.ns). + Resource("initializerconfigurations"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of InitializerConfigurations that match those selectors. +func (c *initializerConfigurations) List(opts v1.ListOptions) (result *admissionregistration.InitializerConfigurationList, err error) { + result = &admissionregistration.InitializerConfigurationList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("initializerconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested initializerConfigurations. +func (c *initializerConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("initializerconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched initializerConfiguration. +func (c *initializerConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *admissionregistration.InitializerConfiguration, err error) { + result = &admissionregistration.InitializerConfiguration{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("initializerconfigurations"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/BUILD b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/BUILD index bbe7a974f3a9e..67dd8b7c70429 100644 --- a/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/BUILD +++ b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/BUILD @@ -11,6 +11,7 @@ go_library( name = "go_default_library", srcs = [ "apps_client.go", + "controllerrevision.go", "doc.go", "generated_expansion.go", "statefulset.go", diff --git a/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/apps_client.go b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/apps_client.go index 7c948201932e0..718e82c478ca3 100644 --- a/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/apps_client.go +++ b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/apps_client.go @@ -23,6 +23,7 @@ import ( type AppsInterface interface { RESTClient() rest.Interface + ControllerRevisionsGetter StatefulSetsGetter } @@ -31,6 +32,10 @@ type AppsClient struct { restClient rest.Interface } +func (c *AppsClient) ControllerRevisions(namespace string) ControllerRevisionInterface { + return newControllerRevisions(c, namespace) +} + func (c *AppsClient) StatefulSets(namespace string) StatefulSetInterface { return newStatefulSets(c, namespace) } diff --git a/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/controllerrevision.go b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/controllerrevision.go new file mode 100644 index 0000000000000..7c99d696c5134 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/controllerrevision.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package internalversion + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" + apps "k8s.io/kubernetes/pkg/apis/apps" + scheme "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/scheme" +) + +// ControllerRevisionsGetter has a method to return a ControllerRevisionInterface. +// A group's client should implement this interface. +type ControllerRevisionsGetter interface { + ControllerRevisions(namespace string) ControllerRevisionInterface +} + +// ControllerRevisionInterface has methods to work with ControllerRevision resources. +type ControllerRevisionInterface interface { + Create(*apps.ControllerRevision) (*apps.ControllerRevision, error) + Update(*apps.ControllerRevision) (*apps.ControllerRevision, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*apps.ControllerRevision, error) + List(opts v1.ListOptions) (*apps.ControllerRevisionList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *apps.ControllerRevision, err error) + ControllerRevisionExpansion +} + +// controllerRevisions implements ControllerRevisionInterface +type controllerRevisions struct { + client rest.Interface + ns string +} + +// newControllerRevisions returns a ControllerRevisions +func newControllerRevisions(c *AppsClient, namespace string) *controllerRevisions { + return &controllerRevisions{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a controllerRevision and creates it. Returns the server's representation of the controllerRevision, and an error, if there is any. +func (c *controllerRevisions) Create(controllerRevision *apps.ControllerRevision) (result *apps.ControllerRevision, err error) { + result = &apps.ControllerRevision{} + err = c.client.Post(). + Namespace(c.ns). + Resource("controllerrevisions"). + Body(controllerRevision). + Do(). + Into(result) + return +} + +// Update takes the representation of a controllerRevision and updates it. Returns the server's representation of the controllerRevision, and an error, if there is any. +func (c *controllerRevisions) Update(controllerRevision *apps.ControllerRevision) (result *apps.ControllerRevision, err error) { + result = &apps.ControllerRevision{} + err = c.client.Put(). + Namespace(c.ns). + Resource("controllerrevisions"). + Name(controllerRevision.Name). + Body(controllerRevision). + Do(). + Into(result) + return +} + +// Delete takes name of the controllerRevision and deletes it. Returns an error if one occurs. +func (c *controllerRevisions) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("controllerrevisions"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *controllerRevisions) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("controllerrevisions"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the controllerRevision, and returns the corresponding controllerRevision object, and an error if there is any. +func (c *controllerRevisions) Get(name string, options v1.GetOptions) (result *apps.ControllerRevision, err error) { + result = &apps.ControllerRevision{} + err = c.client.Get(). + Namespace(c.ns). + Resource("controllerrevisions"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of ControllerRevisions that match those selectors. +func (c *controllerRevisions) List(opts v1.ListOptions) (result *apps.ControllerRevisionList, err error) { + result = &apps.ControllerRevisionList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("controllerrevisions"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested controllerRevisions. +func (c *controllerRevisions) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("controllerrevisions"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched controllerRevision. +func (c *controllerRevisions) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *apps.ControllerRevision, err error) { + result = &apps.ControllerRevision{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("controllerrevisions"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/fake/BUILD b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/fake/BUILD index ea5b2209c2d8d..4cc26e947ff4c 100644 --- a/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/fake/BUILD +++ b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/fake/BUILD @@ -12,6 +12,7 @@ go_library( srcs = [ "doc.go", "fake_apps_client.go", + "fake_controllerrevision.go", "fake_statefulset.go", ], tags = ["automanaged"], diff --git a/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/fake/fake_apps_client.go b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/fake/fake_apps_client.go index 540106848d96e..e677f9d283aff 100644 --- a/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/fake/fake_apps_client.go +++ b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/fake/fake_apps_client.go @@ -26,6 +26,10 @@ type FakeApps struct { *testing.Fake } +func (c *FakeApps) ControllerRevisions(namespace string) internalversion.ControllerRevisionInterface { + return &FakeControllerRevisions{c, namespace} +} + func (c *FakeApps) StatefulSets(namespace string) internalversion.StatefulSetInterface { return &FakeStatefulSets{c, namespace} } diff --git a/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/fake/fake_controllerrevision.go b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/fake/fake_controllerrevision.go new file mode 100644 index 0000000000000..8d587d14441c2 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/fake/fake_controllerrevision.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + labels "k8s.io/apimachinery/pkg/labels" + schema "k8s.io/apimachinery/pkg/runtime/schema" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + testing "k8s.io/client-go/testing" + apps "k8s.io/kubernetes/pkg/apis/apps" +) + +// FakeControllerRevisions implements ControllerRevisionInterface +type FakeControllerRevisions struct { + Fake *FakeApps + ns string +} + +var controllerrevisionsResource = schema.GroupVersionResource{Group: "apps", Version: "", Resource: "controllerrevisions"} + +var controllerrevisionsKind = schema.GroupVersionKind{Group: "apps", Version: "", Kind: "ControllerRevision"} + +func (c *FakeControllerRevisions) Create(controllerRevision *apps.ControllerRevision) (result *apps.ControllerRevision, err error) { + obj, err := c.Fake. + Invokes(testing.NewCreateAction(controllerrevisionsResource, c.ns, controllerRevision), &apps.ControllerRevision{}) + + if obj == nil { + return nil, err + } + return obj.(*apps.ControllerRevision), err +} + +func (c *FakeControllerRevisions) Update(controllerRevision *apps.ControllerRevision) (result *apps.ControllerRevision, err error) { + obj, err := c.Fake. + Invokes(testing.NewUpdateAction(controllerrevisionsResource, c.ns, controllerRevision), &apps.ControllerRevision{}) + + if obj == nil { + return nil, err + } + return obj.(*apps.ControllerRevision), err +} + +func (c *FakeControllerRevisions) Delete(name string, options *v1.DeleteOptions) error { + _, err := c.Fake. + Invokes(testing.NewDeleteAction(controllerrevisionsResource, c.ns, name), &apps.ControllerRevision{}) + + return err +} + +func (c *FakeControllerRevisions) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + action := testing.NewDeleteCollectionAction(controllerrevisionsResource, c.ns, listOptions) + + _, err := c.Fake.Invokes(action, &apps.ControllerRevisionList{}) + return err +} + +func (c *FakeControllerRevisions) Get(name string, options v1.GetOptions) (result *apps.ControllerRevision, err error) { + obj, err := c.Fake. + Invokes(testing.NewGetAction(controllerrevisionsResource, c.ns, name), &apps.ControllerRevision{}) + + if obj == nil { + return nil, err + } + return obj.(*apps.ControllerRevision), err +} + +func (c *FakeControllerRevisions) List(opts v1.ListOptions) (result *apps.ControllerRevisionList, err error) { + obj, err := c.Fake. + Invokes(testing.NewListAction(controllerrevisionsResource, controllerrevisionsKind, c.ns, opts), &apps.ControllerRevisionList{}) + + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &apps.ControllerRevisionList{} + for _, item := range obj.(*apps.ControllerRevisionList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested controllerRevisions. +func (c *FakeControllerRevisions) Watch(opts v1.ListOptions) (watch.Interface, error) { + return c.Fake. + InvokesWatch(testing.NewWatchAction(controllerrevisionsResource, c.ns, opts)) + +} + +// Patch applies the patch and returns the patched controllerRevision. +func (c *FakeControllerRevisions) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *apps.ControllerRevision, err error) { + obj, err := c.Fake. + Invokes(testing.NewPatchSubresourceAction(controllerrevisionsResource, c.ns, name, data, subresources...), &apps.ControllerRevision{}) + + if obj == nil { + return nil, err + } + return obj.(*apps.ControllerRevision), err +} diff --git a/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/generated_expansion.go b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/generated_expansion.go index 29b6b52318494..3b3f37336a7ec 100644 --- a/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/generated_expansion.go +++ b/pkg/client/clientset_generated/internalclientset/typed/apps/internalversion/generated_expansion.go @@ -16,4 +16,6 @@ limitations under the License. package internalversion +type ControllerRevisionExpansion interface{} + type StatefulSetExpansion interface{} diff --git a/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/BUILD b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/BUILD new file mode 100644 index 0000000000000..2af7d8d64babe --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/BUILD @@ -0,0 +1,43 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "generated_expansion.go", + "networking_client.go", + "networkpolicy.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/networking:go_default_library", + "//pkg/client/clientset_generated/internalclientset/scheme:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/doc.go b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/doc.go new file mode 100644 index 0000000000000..0a27970fbb3b7 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This package is generated by client-gen with the default arguments. + +// This package has the automatically generated typed clients. +package internalversion diff --git a/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake/BUILD b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake/BUILD new file mode 100644 index 0000000000000..67398435befaa --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake/BUILD @@ -0,0 +1,42 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "fake_networking_client.go", + "fake_networkpolicy.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/networking:go_default_library", + "//pkg/client/clientset_generated/internalclientset/typed/networking/internalversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + "//vendor/k8s.io/client-go/testing:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake/doc.go b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake/doc.go new file mode 100644 index 0000000000000..a0ecb96ba17bd --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This package is generated by client-gen with the default arguments. + +// Package fake has the automatically generated clients. +package fake diff --git a/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake/fake_networking_client.go b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake/fake_networking_client.go new file mode 100644 index 0000000000000..9c0941a310875 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake/fake_networking_client.go @@ -0,0 +1,38 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + rest "k8s.io/client-go/rest" + testing "k8s.io/client-go/testing" + internalversion "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion" +) + +type FakeNetworking struct { + *testing.Fake +} + +func (c *FakeNetworking) NetworkPolicies(namespace string) internalversion.NetworkPolicyInterface { + return &FakeNetworkPolicies{c, namespace} +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *FakeNetworking) RESTClient() rest.Interface { + var ret *rest.RESTClient + return ret +} diff --git a/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake/fake_networkpolicy.go b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake/fake_networkpolicy.go new file mode 100644 index 0000000000000..aa5be6084e1a0 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/fake/fake_networkpolicy.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + labels "k8s.io/apimachinery/pkg/labels" + schema "k8s.io/apimachinery/pkg/runtime/schema" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + testing "k8s.io/client-go/testing" + networking "k8s.io/kubernetes/pkg/apis/networking" +) + +// FakeNetworkPolicies implements NetworkPolicyInterface +type FakeNetworkPolicies struct { + Fake *FakeNetworking + ns string +} + +var networkpoliciesResource = schema.GroupVersionResource{Group: "networking.k8s.io", Version: "", Resource: "networkpolicies"} + +var networkpoliciesKind = schema.GroupVersionKind{Group: "networking.k8s.io", Version: "", Kind: "NetworkPolicy"} + +func (c *FakeNetworkPolicies) Create(networkPolicy *networking.NetworkPolicy) (result *networking.NetworkPolicy, err error) { + obj, err := c.Fake. + Invokes(testing.NewCreateAction(networkpoliciesResource, c.ns, networkPolicy), &networking.NetworkPolicy{}) + + if obj == nil { + return nil, err + } + return obj.(*networking.NetworkPolicy), err +} + +func (c *FakeNetworkPolicies) Update(networkPolicy *networking.NetworkPolicy) (result *networking.NetworkPolicy, err error) { + obj, err := c.Fake. + Invokes(testing.NewUpdateAction(networkpoliciesResource, c.ns, networkPolicy), &networking.NetworkPolicy{}) + + if obj == nil { + return nil, err + } + return obj.(*networking.NetworkPolicy), err +} + +func (c *FakeNetworkPolicies) Delete(name string, options *v1.DeleteOptions) error { + _, err := c.Fake. + Invokes(testing.NewDeleteAction(networkpoliciesResource, c.ns, name), &networking.NetworkPolicy{}) + + return err +} + +func (c *FakeNetworkPolicies) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + action := testing.NewDeleteCollectionAction(networkpoliciesResource, c.ns, listOptions) + + _, err := c.Fake.Invokes(action, &networking.NetworkPolicyList{}) + return err +} + +func (c *FakeNetworkPolicies) Get(name string, options v1.GetOptions) (result *networking.NetworkPolicy, err error) { + obj, err := c.Fake. + Invokes(testing.NewGetAction(networkpoliciesResource, c.ns, name), &networking.NetworkPolicy{}) + + if obj == nil { + return nil, err + } + return obj.(*networking.NetworkPolicy), err +} + +func (c *FakeNetworkPolicies) List(opts v1.ListOptions) (result *networking.NetworkPolicyList, err error) { + obj, err := c.Fake. + Invokes(testing.NewListAction(networkpoliciesResource, networkpoliciesKind, c.ns, opts), &networking.NetworkPolicyList{}) + + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &networking.NetworkPolicyList{} + for _, item := range obj.(*networking.NetworkPolicyList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested networkPolicies. +func (c *FakeNetworkPolicies) Watch(opts v1.ListOptions) (watch.Interface, error) { + return c.Fake. + InvokesWatch(testing.NewWatchAction(networkpoliciesResource, c.ns, opts)) + +} + +// Patch applies the patch and returns the patched networkPolicy. +func (c *FakeNetworkPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *networking.NetworkPolicy, err error) { + obj, err := c.Fake. + Invokes(testing.NewPatchSubresourceAction(networkpoliciesResource, c.ns, name, data, subresources...), &networking.NetworkPolicy{}) + + if obj == nil { + return nil, err + } + return obj.(*networking.NetworkPolicy), err +} diff --git a/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/generated_expansion.go b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/generated_expansion.go new file mode 100644 index 0000000000000..c2c8709d69120 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/generated_expansion.go @@ -0,0 +1,19 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package internalversion + +type NetworkPolicyExpansion interface{} diff --git a/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/networking_client.go b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/networking_client.go new file mode 100644 index 0000000000000..4469af1716508 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/networking_client.go @@ -0,0 +1,99 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package internalversion + +import ( + rest "k8s.io/client-go/rest" + "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/scheme" +) + +type NetworkingInterface interface { + RESTClient() rest.Interface + NetworkPoliciesGetter +} + +// NetworkingClient is used to interact with features provided by the networking.k8s.io group. +type NetworkingClient struct { + restClient rest.Interface +} + +func (c *NetworkingClient) NetworkPolicies(namespace string) NetworkPolicyInterface { + return newNetworkPolicies(c, namespace) +} + +// NewForConfig creates a new NetworkingClient for the given config. +func NewForConfig(c *rest.Config) (*NetworkingClient, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &NetworkingClient{client}, nil +} + +// NewForConfigOrDie creates a new NetworkingClient for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *NetworkingClient { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new NetworkingClient for the given RESTClient. +func New(c rest.Interface) *NetworkingClient { + return &NetworkingClient{c} +} + +func setConfigDefaults(config *rest.Config) error { + g, err := scheme.Registry.Group("networking.k8s.io") + if err != nil { + return err + } + + config.APIPath = "/apis" + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + if config.GroupVersion == nil || config.GroupVersion.Group != g.GroupVersion.Group { + gv := g.GroupVersion + config.GroupVersion = &gv + } + config.NegotiatedSerializer = scheme.Codecs + + if config.QPS == 0 { + config.QPS = 5 + } + if config.Burst == 0 { + config.Burst = 10 + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *NetworkingClient) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/networkpolicy.go b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/networkpolicy.go new file mode 100644 index 0000000000000..adab846159f70 --- /dev/null +++ b/pkg/client/clientset_generated/internalclientset/typed/networking/internalversion/networkpolicy.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package internalversion + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" + networking "k8s.io/kubernetes/pkg/apis/networking" + scheme "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/scheme" +) + +// NetworkPoliciesGetter has a method to return a NetworkPolicyInterface. +// A group's client should implement this interface. +type NetworkPoliciesGetter interface { + NetworkPolicies(namespace string) NetworkPolicyInterface +} + +// NetworkPolicyInterface has methods to work with NetworkPolicy resources. +type NetworkPolicyInterface interface { + Create(*networking.NetworkPolicy) (*networking.NetworkPolicy, error) + Update(*networking.NetworkPolicy) (*networking.NetworkPolicy, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*networking.NetworkPolicy, error) + List(opts v1.ListOptions) (*networking.NetworkPolicyList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *networking.NetworkPolicy, err error) + NetworkPolicyExpansion +} + +// networkPolicies implements NetworkPolicyInterface +type networkPolicies struct { + client rest.Interface + ns string +} + +// newNetworkPolicies returns a NetworkPolicies +func newNetworkPolicies(c *NetworkingClient, namespace string) *networkPolicies { + return &networkPolicies{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a networkPolicy and creates it. Returns the server's representation of the networkPolicy, and an error, if there is any. +func (c *networkPolicies) Create(networkPolicy *networking.NetworkPolicy) (result *networking.NetworkPolicy, err error) { + result = &networking.NetworkPolicy{} + err = c.client.Post(). + Namespace(c.ns). + Resource("networkpolicies"). + Body(networkPolicy). + Do(). + Into(result) + return +} + +// Update takes the representation of a networkPolicy and updates it. Returns the server's representation of the networkPolicy, and an error, if there is any. +func (c *networkPolicies) Update(networkPolicy *networking.NetworkPolicy) (result *networking.NetworkPolicy, err error) { + result = &networking.NetworkPolicy{} + err = c.client.Put(). + Namespace(c.ns). + Resource("networkpolicies"). + Name(networkPolicy.Name). + Body(networkPolicy). + Do(). + Into(result) + return +} + +// Delete takes name of the networkPolicy and deletes it. Returns an error if one occurs. +func (c *networkPolicies) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("networkpolicies"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *networkPolicies) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("networkpolicies"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the networkPolicy, and returns the corresponding networkPolicy object, and an error if there is any. +func (c *networkPolicies) Get(name string, options v1.GetOptions) (result *networking.NetworkPolicy, err error) { + result = &networking.NetworkPolicy{} + err = c.client.Get(). + Namespace(c.ns). + Resource("networkpolicies"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of NetworkPolicies that match those selectors. +func (c *networkPolicies) List(opts v1.ListOptions) (result *networking.NetworkPolicyList, err error) { + result = &networking.NetworkPolicyList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("networkpolicies"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested networkPolicies. +func (c *networkPolicies) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("networkpolicies"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched networkPolicy. +func (c *networkPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *networking.NetworkPolicy, err error) { + result = &networking.NetworkPolicy{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("networkpolicies"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/pkg/client/informers/informers_generated/externalversions/BUILD b/pkg/client/informers/informers_generated/externalversions/BUILD index d1154c1bd22b1..b2af98c2df6a0 100644 --- a/pkg/client/informers/informers_generated/externalversions/BUILD +++ b/pkg/client/informers/informers_generated/externalversions/BUILD @@ -16,6 +16,7 @@ go_library( tags = ["automanaged"], deps = [ "//pkg/api/v1:go_default_library", + "//pkg/apis/admissionregistration/v1alpha1:go_default_library", "//pkg/apis/apps/v1beta1:go_default_library", "//pkg/apis/autoscaling/v1:go_default_library", "//pkg/apis/autoscaling/v2alpha1:go_default_library", @@ -23,6 +24,7 @@ go_library( "//pkg/apis/batch/v2alpha1:go_default_library", "//pkg/apis/certificates/v1beta1:go_default_library", "//pkg/apis/extensions/v1beta1:go_default_library", + "//pkg/apis/networking/v1:go_default_library", "//pkg/apis/policy/v1beta1:go_default_library", "//pkg/apis/rbac/v1alpha1:go_default_library", "//pkg/apis/rbac/v1beta1:go_default_library", @@ -30,6 +32,7 @@ go_library( "//pkg/apis/storage/v1:go_default_library", "//pkg/apis/storage/v1beta1:go_default_library", "//pkg/client/clientset_generated/clientset:go_default_library", + "//pkg/client/informers/informers_generated/externalversions/admissionregistration:go_default_library", "//pkg/client/informers/informers_generated/externalversions/apps:go_default_library", "//pkg/client/informers/informers_generated/externalversions/autoscaling:go_default_library", "//pkg/client/informers/informers_generated/externalversions/batch:go_default_library", @@ -37,6 +40,7 @@ go_library( "//pkg/client/informers/informers_generated/externalversions/core:go_default_library", "//pkg/client/informers/informers_generated/externalversions/extensions:go_default_library", "//pkg/client/informers/informers_generated/externalversions/internalinterfaces:go_default_library", + "//pkg/client/informers/informers_generated/externalversions/networking:go_default_library", "//pkg/client/informers/informers_generated/externalversions/policy:go_default_library", "//pkg/client/informers/informers_generated/externalversions/rbac:go_default_library", "//pkg/client/informers/informers_generated/externalversions/settings:go_default_library", @@ -58,6 +62,7 @@ filegroup( name = "all-srcs", srcs = [ ":package-srcs", + "//pkg/client/informers/informers_generated/externalversions/admissionregistration:all-srcs", "//pkg/client/informers/informers_generated/externalversions/apps:all-srcs", "//pkg/client/informers/informers_generated/externalversions/autoscaling:all-srcs", "//pkg/client/informers/informers_generated/externalversions/batch:all-srcs", @@ -65,6 +70,7 @@ filegroup( "//pkg/client/informers/informers_generated/externalversions/core:all-srcs", "//pkg/client/informers/informers_generated/externalversions/extensions:all-srcs", "//pkg/client/informers/informers_generated/externalversions/internalinterfaces:all-srcs", + "//pkg/client/informers/informers_generated/externalversions/networking:all-srcs", "//pkg/client/informers/informers_generated/externalversions/policy:all-srcs", "//pkg/client/informers/informers_generated/externalversions/rbac:all-srcs", "//pkg/client/informers/informers_generated/externalversions/settings:all-srcs", diff --git a/pkg/client/informers/informers_generated/externalversions/admissionregistration/BUILD b/pkg/client/informers/informers_generated/externalversions/admissionregistration/BUILD new file mode 100644 index 0000000000000..d494439362c4f --- /dev/null +++ b/pkg/client/informers/informers_generated/externalversions/admissionregistration/BUILD @@ -0,0 +1,34 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["interface.go"], + tags = ["automanaged"], + deps = [ + "//pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1:go_default_library", + "//pkg/client/informers/informers_generated/externalversions/internalinterfaces:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/client/informers/informers_generated/externalversions/admissionregistration/interface.go b/pkg/client/informers/informers_generated/externalversions/admissionregistration/interface.go new file mode 100644 index 0000000000000..d5e2faea682ec --- /dev/null +++ b/pkg/client/informers/informers_generated/externalversions/admissionregistration/interface.go @@ -0,0 +1,44 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package admissionregistration + +import ( + v1alpha1 "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1" + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/internalinterfaces" +) + +// Interface provides access to each of this group's versions. +type Interface interface { + // V1alpha1 provides access to shared informers for resources in V1alpha1. + V1alpha1() v1alpha1.Interface +} + +type group struct { + internalinterfaces.SharedInformerFactory +} + +// New returns a new Interface. +func New(f internalinterfaces.SharedInformerFactory) Interface { + return &group{f} +} + +// V1alpha1 returns a new v1alpha1.Interface. +func (g *group) V1alpha1() v1alpha1.Interface { + return v1alpha1.New(g.SharedInformerFactory) +} diff --git a/pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1/BUILD b/pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1/BUILD new file mode 100644 index 0000000000000..a57fc8f5f6733 --- /dev/null +++ b/pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1/BUILD @@ -0,0 +1,41 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "externaladmissionhookconfiguration.go", + "initializerconfiguration.go", + "interface.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//pkg/client/clientset_generated/clientset:go_default_library", + "//pkg/client/informers/informers_generated/externalversions/internalinterfaces:go_default_library", + "//pkg/client/listers/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go b/pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go new file mode 100644 index 0000000000000..94231ed14c8d8 --- /dev/null +++ b/pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go @@ -0,0 +1,68 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + cache "k8s.io/client-go/tools/cache" + admissionregistration_v1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" + clientset "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/internalinterfaces" + v1alpha1 "k8s.io/kubernetes/pkg/client/listers/admissionregistration/v1alpha1" + time "time" +) + +// ExternalAdmissionHookConfigurationInformer provides access to a shared informer and lister for +// ExternalAdmissionHookConfigurations. +type ExternalAdmissionHookConfigurationInformer interface { + Informer() cache.SharedIndexInformer + Lister() v1alpha1.ExternalAdmissionHookConfigurationLister +} + +type externalAdmissionHookConfigurationInformer struct { + factory internalinterfaces.SharedInformerFactory +} + +func newExternalAdmissionHookConfigurationInformer(client clientset.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + sharedIndexInformer := cache.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options v1.ListOptions) (runtime.Object, error) { + return client.AdmissionregistrationV1alpha1().ExternalAdmissionHookConfigurations(v1.NamespaceAll).List(options) + }, + WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { + return client.AdmissionregistrationV1alpha1().ExternalAdmissionHookConfigurations(v1.NamespaceAll).Watch(options) + }, + }, + &admissionregistration_v1alpha1.ExternalAdmissionHookConfiguration{}, + resyncPeriod, + cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, + ) + + return sharedIndexInformer +} + +func (f *externalAdmissionHookConfigurationInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&admissionregistration_v1alpha1.ExternalAdmissionHookConfiguration{}, newExternalAdmissionHookConfigurationInformer) +} + +func (f *externalAdmissionHookConfigurationInformer) Lister() v1alpha1.ExternalAdmissionHookConfigurationLister { + return v1alpha1.NewExternalAdmissionHookConfigurationLister(f.Informer().GetIndexer()) +} diff --git a/pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1/initializerconfiguration.go b/pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1/initializerconfiguration.go new file mode 100644 index 0000000000000..343b66980edce --- /dev/null +++ b/pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1/initializerconfiguration.go @@ -0,0 +1,68 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + cache "k8s.io/client-go/tools/cache" + admissionregistration_v1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" + clientset "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/internalinterfaces" + v1alpha1 "k8s.io/kubernetes/pkg/client/listers/admissionregistration/v1alpha1" + time "time" +) + +// InitializerConfigurationInformer provides access to a shared informer and lister for +// InitializerConfigurations. +type InitializerConfigurationInformer interface { + Informer() cache.SharedIndexInformer + Lister() v1alpha1.InitializerConfigurationLister +} + +type initializerConfigurationInformer struct { + factory internalinterfaces.SharedInformerFactory +} + +func newInitializerConfigurationInformer(client clientset.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + sharedIndexInformer := cache.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options v1.ListOptions) (runtime.Object, error) { + return client.AdmissionregistrationV1alpha1().InitializerConfigurations(v1.NamespaceAll).List(options) + }, + WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { + return client.AdmissionregistrationV1alpha1().InitializerConfigurations(v1.NamespaceAll).Watch(options) + }, + }, + &admissionregistration_v1alpha1.InitializerConfiguration{}, + resyncPeriod, + cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, + ) + + return sharedIndexInformer +} + +func (f *initializerConfigurationInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&admissionregistration_v1alpha1.InitializerConfiguration{}, newInitializerConfigurationInformer) +} + +func (f *initializerConfigurationInformer) Lister() v1alpha1.InitializerConfigurationLister { + return v1alpha1.NewInitializerConfigurationLister(f.Informer().GetIndexer()) +} diff --git a/pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1/interface.go b/pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1/interface.go new file mode 100644 index 0000000000000..51f83597475d1 --- /dev/null +++ b/pkg/client/informers/informers_generated/externalversions/admissionregistration/v1alpha1/interface.go @@ -0,0 +1,50 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package v1alpha1 + +import ( + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/internalinterfaces" +) + +// Interface provides access to all the informers in this group version. +type Interface interface { + // ExternalAdmissionHookConfigurations returns a ExternalAdmissionHookConfigurationInformer. + ExternalAdmissionHookConfigurations() ExternalAdmissionHookConfigurationInformer + // InitializerConfigurations returns a InitializerConfigurationInformer. + InitializerConfigurations() InitializerConfigurationInformer +} + +type version struct { + internalinterfaces.SharedInformerFactory +} + +// New returns a new Interface. +func New(f internalinterfaces.SharedInformerFactory) Interface { + return &version{f} +} + +// ExternalAdmissionHookConfigurations returns a ExternalAdmissionHookConfigurationInformer. +func (v *version) ExternalAdmissionHookConfigurations() ExternalAdmissionHookConfigurationInformer { + return &externalAdmissionHookConfigurationInformer{factory: v.SharedInformerFactory} +} + +// InitializerConfigurations returns a InitializerConfigurationInformer. +func (v *version) InitializerConfigurations() InitializerConfigurationInformer { + return &initializerConfigurationInformer{factory: v.SharedInformerFactory} +} diff --git a/pkg/client/informers/informers_generated/externalversions/apps/v1beta1/BUILD b/pkg/client/informers/informers_generated/externalversions/apps/v1beta1/BUILD index cfcd77020a2cd..18ef9ee37879c 100644 --- a/pkg/client/informers/informers_generated/externalversions/apps/v1beta1/BUILD +++ b/pkg/client/informers/informers_generated/externalversions/apps/v1beta1/BUILD @@ -10,6 +10,7 @@ load( go_library( name = "go_default_library", srcs = [ + "controllerrevision.go", "deployment.go", "interface.go", "statefulset.go", diff --git a/pkg/client/informers/informers_generated/externalversions/apps/v1beta1/controllerrevision.go b/pkg/client/informers/informers_generated/externalversions/apps/v1beta1/controllerrevision.go new file mode 100644 index 0000000000000..a9aa1ed7fa130 --- /dev/null +++ b/pkg/client/informers/informers_generated/externalversions/apps/v1beta1/controllerrevision.go @@ -0,0 +1,68 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package v1beta1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + cache "k8s.io/client-go/tools/cache" + apps_v1beta1 "k8s.io/kubernetes/pkg/apis/apps/v1beta1" + clientset "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/internalinterfaces" + v1beta1 "k8s.io/kubernetes/pkg/client/listers/apps/v1beta1" + time "time" +) + +// ControllerRevisionInformer provides access to a shared informer and lister for +// ControllerRevisions. +type ControllerRevisionInformer interface { + Informer() cache.SharedIndexInformer + Lister() v1beta1.ControllerRevisionLister +} + +type controllerRevisionInformer struct { + factory internalinterfaces.SharedInformerFactory +} + +func newControllerRevisionInformer(client clientset.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + sharedIndexInformer := cache.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options v1.ListOptions) (runtime.Object, error) { + return client.AppsV1beta1().ControllerRevisions(v1.NamespaceAll).List(options) + }, + WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { + return client.AppsV1beta1().ControllerRevisions(v1.NamespaceAll).Watch(options) + }, + }, + &apps_v1beta1.ControllerRevision{}, + resyncPeriod, + cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, + ) + + return sharedIndexInformer +} + +func (f *controllerRevisionInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&apps_v1beta1.ControllerRevision{}, newControllerRevisionInformer) +} + +func (f *controllerRevisionInformer) Lister() v1beta1.ControllerRevisionLister { + return v1beta1.NewControllerRevisionLister(f.Informer().GetIndexer()) +} diff --git a/pkg/client/informers/informers_generated/externalversions/apps/v1beta1/interface.go b/pkg/client/informers/informers_generated/externalversions/apps/v1beta1/interface.go index aff7a33b85eae..1b07f56c4d971 100644 --- a/pkg/client/informers/informers_generated/externalversions/apps/v1beta1/interface.go +++ b/pkg/client/informers/informers_generated/externalversions/apps/v1beta1/interface.go @@ -24,6 +24,8 @@ import ( // Interface provides access to all the informers in this group version. type Interface interface { + // ControllerRevisions returns a ControllerRevisionInformer. + ControllerRevisions() ControllerRevisionInformer // Deployments returns a DeploymentInformer. Deployments() DeploymentInformer // StatefulSets returns a StatefulSetInformer. @@ -39,6 +41,11 @@ func New(f internalinterfaces.SharedInformerFactory) Interface { return &version{f} } +// ControllerRevisions returns a ControllerRevisionInformer. +func (v *version) ControllerRevisions() ControllerRevisionInformer { + return &controllerRevisionInformer{factory: v.SharedInformerFactory} +} + // Deployments returns a DeploymentInformer. func (v *version) Deployments() DeploymentInformer { return &deploymentInformer{factory: v.SharedInformerFactory} diff --git a/pkg/client/informers/informers_generated/externalversions/factory.go b/pkg/client/informers/informers_generated/externalversions/factory.go index 913335df07d40..9671be8046ce2 100644 --- a/pkg/client/informers/informers_generated/externalversions/factory.go +++ b/pkg/client/informers/informers_generated/externalversions/factory.go @@ -23,6 +23,7 @@ import ( schema "k8s.io/apimachinery/pkg/runtime/schema" cache "k8s.io/client-go/tools/cache" clientset "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" + admissionregistration "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/admissionregistration" apps "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/apps" autoscaling "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/autoscaling" batch "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/batch" @@ -30,6 +31,7 @@ import ( core "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/core" extensions "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/extensions" internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/internalinterfaces" + networking "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/networking" policy "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/policy" rbac "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/rbac" settings "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/settings" @@ -119,18 +121,24 @@ type SharedInformerFactory interface { ForResource(resource schema.GroupVersionResource) (GenericInformer, error) WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool + Admissionregistration() admissionregistration.Interface Apps() apps.Interface Autoscaling() autoscaling.Interface Batch() batch.Interface Certificates() certificates.Interface Core() core.Interface Extensions() extensions.Interface + Networking() networking.Interface Policy() policy.Interface Rbac() rbac.Interface Settings() settings.Interface Storage() storage.Interface } +func (f *sharedInformerFactory) Admissionregistration() admissionregistration.Interface { + return admissionregistration.New(f) +} + func (f *sharedInformerFactory) Apps() apps.Interface { return apps.New(f) } @@ -155,6 +163,10 @@ func (f *sharedInformerFactory) Extensions() extensions.Interface { return extensions.New(f) } +func (f *sharedInformerFactory) Networking() networking.Interface { + return networking.New(f) +} + func (f *sharedInformerFactory) Policy() policy.Interface { return policy.New(f) } diff --git a/pkg/client/informers/informers_generated/externalversions/generic.go b/pkg/client/informers/informers_generated/externalversions/generic.go index a1b7344d6fb39..2f91d7c7559e6 100644 --- a/pkg/client/informers/informers_generated/externalversions/generic.go +++ b/pkg/client/informers/informers_generated/externalversions/generic.go @@ -23,6 +23,7 @@ import ( schema "k8s.io/apimachinery/pkg/runtime/schema" cache "k8s.io/client-go/tools/cache" api_v1 "k8s.io/kubernetes/pkg/api/v1" + v1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" v1beta1 "k8s.io/kubernetes/pkg/apis/apps/v1beta1" v1 "k8s.io/kubernetes/pkg/apis/autoscaling/v1" v2alpha1 "k8s.io/kubernetes/pkg/apis/autoscaling/v2alpha1" @@ -30,8 +31,9 @@ import ( batch_v2alpha1 "k8s.io/kubernetes/pkg/apis/batch/v2alpha1" certificates_v1beta1 "k8s.io/kubernetes/pkg/apis/certificates/v1beta1" extensions_v1beta1 "k8s.io/kubernetes/pkg/apis/extensions/v1beta1" + networking_v1 "k8s.io/kubernetes/pkg/apis/networking/v1" policy_v1beta1 "k8s.io/kubernetes/pkg/apis/policy/v1beta1" - v1alpha1 "k8s.io/kubernetes/pkg/apis/rbac/v1alpha1" + rbac_v1alpha1 "k8s.io/kubernetes/pkg/apis/rbac/v1alpha1" rbac_v1beta1 "k8s.io/kubernetes/pkg/apis/rbac/v1beta1" settings_v1alpha1 "k8s.io/kubernetes/pkg/apis/settings/v1alpha1" storage_v1 "k8s.io/kubernetes/pkg/apis/storage/v1" @@ -64,7 +66,15 @@ func (f *genericInformer) Lister() cache.GenericLister { // TODO extend this to unknown resources with a client pool func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource) (GenericInformer, error) { switch resource { - // Group=Apps, Version=V1beta1 + // Group=Admissionregistration, Version=V1alpha1 + case v1alpha1.SchemeGroupVersion.WithResource("externaladmissionhookconfigurations"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Admissionregistration().V1alpha1().ExternalAdmissionHookConfigurations().Informer()}, nil + case v1alpha1.SchemeGroupVersion.WithResource("initializerconfigurations"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Admissionregistration().V1alpha1().InitializerConfigurations().Informer()}, nil + + // Group=Apps, Version=V1beta1 + case v1beta1.SchemeGroupVersion.WithResource("controllerrevisions"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Apps().V1beta1().ControllerRevisions().Informer()}, nil case v1beta1.SchemeGroupVersion.WithResource("deployments"): return &genericInformer{resource: resource.GroupResource(), informer: f.Apps().V1beta1().Deployments().Informer()}, nil case v1beta1.SchemeGroupVersion.WithResource("statefulsets"): @@ -138,18 +148,22 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource case extensions_v1beta1.SchemeGroupVersion.WithResource("thirdpartyresources"): return &genericInformer{resource: resource.GroupResource(), informer: f.Extensions().V1beta1().ThirdPartyResources().Informer()}, nil + // Group=Networking, Version=V1 + case networking_v1.SchemeGroupVersion.WithResource("networkpolicies"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Networking().V1().NetworkPolicies().Informer()}, nil + // Group=Policy, Version=V1beta1 case policy_v1beta1.SchemeGroupVersion.WithResource("poddisruptionbudgets"): return &genericInformer{resource: resource.GroupResource(), informer: f.Policy().V1beta1().PodDisruptionBudgets().Informer()}, nil // Group=Rbac, Version=V1alpha1 - case v1alpha1.SchemeGroupVersion.WithResource("clusterroles"): + case rbac_v1alpha1.SchemeGroupVersion.WithResource("clusterroles"): return &genericInformer{resource: resource.GroupResource(), informer: f.Rbac().V1alpha1().ClusterRoles().Informer()}, nil - case v1alpha1.SchemeGroupVersion.WithResource("clusterrolebindings"): + case rbac_v1alpha1.SchemeGroupVersion.WithResource("clusterrolebindings"): return &genericInformer{resource: resource.GroupResource(), informer: f.Rbac().V1alpha1().ClusterRoleBindings().Informer()}, nil - case v1alpha1.SchemeGroupVersion.WithResource("roles"): + case rbac_v1alpha1.SchemeGroupVersion.WithResource("roles"): return &genericInformer{resource: resource.GroupResource(), informer: f.Rbac().V1alpha1().Roles().Informer()}, nil - case v1alpha1.SchemeGroupVersion.WithResource("rolebindings"): + case rbac_v1alpha1.SchemeGroupVersion.WithResource("rolebindings"): return &genericInformer{resource: resource.GroupResource(), informer: f.Rbac().V1alpha1().RoleBindings().Informer()}, nil // Group=Rbac, Version=V1beta1 diff --git a/pkg/client/informers/informers_generated/externalversions/networking/BUILD b/pkg/client/informers/informers_generated/externalversions/networking/BUILD new file mode 100644 index 0000000000000..32fb63b840d6e --- /dev/null +++ b/pkg/client/informers/informers_generated/externalversions/networking/BUILD @@ -0,0 +1,34 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["interface.go"], + tags = ["automanaged"], + deps = [ + "//pkg/client/informers/informers_generated/externalversions/internalinterfaces:go_default_library", + "//pkg/client/informers/informers_generated/externalversions/networking/v1:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/client/informers/informers_generated/externalversions/networking/v1:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/client/informers/informers_generated/externalversions/networking/interface.go b/pkg/client/informers/informers_generated/externalversions/networking/interface.go new file mode 100644 index 0000000000000..00a649262fb11 --- /dev/null +++ b/pkg/client/informers/informers_generated/externalversions/networking/interface.go @@ -0,0 +1,44 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package networking + +import ( + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/internalinterfaces" + v1 "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/networking/v1" +) + +// Interface provides access to each of this group's versions. +type Interface interface { + // V1 provides access to shared informers for resources in V1. + V1() v1.Interface +} + +type group struct { + internalinterfaces.SharedInformerFactory +} + +// New returns a new Interface. +func New(f internalinterfaces.SharedInformerFactory) Interface { + return &group{f} +} + +// V1 returns a new v1.Interface. +func (g *group) V1() v1.Interface { + return v1.New(g.SharedInformerFactory) +} diff --git a/pkg/client/informers/informers_generated/externalversions/networking/v1/BUILD b/pkg/client/informers/informers_generated/externalversions/networking/v1/BUILD new file mode 100644 index 0000000000000..defb3d0aebeaa --- /dev/null +++ b/pkg/client/informers/informers_generated/externalversions/networking/v1/BUILD @@ -0,0 +1,40 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "interface.go", + "networkpolicy.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/networking/v1:go_default_library", + "//pkg/client/clientset_generated/clientset:go_default_library", + "//pkg/client/informers/informers_generated/externalversions/internalinterfaces:go_default_library", + "//pkg/client/listers/networking/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/client/informers/informers_generated/externalversions/networking/v1/interface.go b/pkg/client/informers/informers_generated/externalversions/networking/v1/interface.go new file mode 100644 index 0000000000000..4b7146595cdac --- /dev/null +++ b/pkg/client/informers/informers_generated/externalversions/networking/v1/interface.go @@ -0,0 +1,43 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package v1 + +import ( + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/internalinterfaces" +) + +// Interface provides access to all the informers in this group version. +type Interface interface { + // NetworkPolicies returns a NetworkPolicyInformer. + NetworkPolicies() NetworkPolicyInformer +} + +type version struct { + internalinterfaces.SharedInformerFactory +} + +// New returns a new Interface. +func New(f internalinterfaces.SharedInformerFactory) Interface { + return &version{f} +} + +// NetworkPolicies returns a NetworkPolicyInformer. +func (v *version) NetworkPolicies() NetworkPolicyInformer { + return &networkPolicyInformer{factory: v.SharedInformerFactory} +} diff --git a/pkg/client/informers/informers_generated/externalversions/networking/v1/networkpolicy.go b/pkg/client/informers/informers_generated/externalversions/networking/v1/networkpolicy.go new file mode 100644 index 0000000000000..a8912ca43cec0 --- /dev/null +++ b/pkg/client/informers/informers_generated/externalversions/networking/v1/networkpolicy.go @@ -0,0 +1,68 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + cache "k8s.io/client-go/tools/cache" + networking_v1 "k8s.io/kubernetes/pkg/apis/networking/v1" + clientset "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/internalinterfaces" + v1 "k8s.io/kubernetes/pkg/client/listers/networking/v1" + time "time" +) + +// NetworkPolicyInformer provides access to a shared informer and lister for +// NetworkPolicies. +type NetworkPolicyInformer interface { + Informer() cache.SharedIndexInformer + Lister() v1.NetworkPolicyLister +} + +type networkPolicyInformer struct { + factory internalinterfaces.SharedInformerFactory +} + +func newNetworkPolicyInformer(client clientset.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + sharedIndexInformer := cache.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options meta_v1.ListOptions) (runtime.Object, error) { + return client.NetworkingV1().NetworkPolicies(meta_v1.NamespaceAll).List(options) + }, + WatchFunc: func(options meta_v1.ListOptions) (watch.Interface, error) { + return client.NetworkingV1().NetworkPolicies(meta_v1.NamespaceAll).Watch(options) + }, + }, + &networking_v1.NetworkPolicy{}, + resyncPeriod, + cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, + ) + + return sharedIndexInformer +} + +func (f *networkPolicyInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&networking_v1.NetworkPolicy{}, newNetworkPolicyInformer) +} + +func (f *networkPolicyInformer) Lister() v1.NetworkPolicyLister { + return v1.NewNetworkPolicyLister(f.Informer().GetIndexer()) +} diff --git a/pkg/client/informers/informers_generated/internalversion/BUILD b/pkg/client/informers/informers_generated/internalversion/BUILD index 97bddd2a357f5..b3229b23ddeb9 100644 --- a/pkg/client/informers/informers_generated/internalversion/BUILD +++ b/pkg/client/informers/informers_generated/internalversion/BUILD @@ -16,16 +16,19 @@ go_library( tags = ["automanaged"], deps = [ "//pkg/api:go_default_library", + "//pkg/apis/admissionregistration:go_default_library", "//pkg/apis/apps:go_default_library", "//pkg/apis/autoscaling:go_default_library", "//pkg/apis/batch:go_default_library", "//pkg/apis/certificates:go_default_library", "//pkg/apis/extensions:go_default_library", + "//pkg/apis/networking:go_default_library", "//pkg/apis/policy:go_default_library", "//pkg/apis/rbac:go_default_library", "//pkg/apis/settings:go_default_library", "//pkg/apis/storage:go_default_library", "//pkg/client/clientset_generated/internalclientset:go_default_library", + "//pkg/client/informers/informers_generated/internalversion/admissionregistration:go_default_library", "//pkg/client/informers/informers_generated/internalversion/apps:go_default_library", "//pkg/client/informers/informers_generated/internalversion/autoscaling:go_default_library", "//pkg/client/informers/informers_generated/internalversion/batch:go_default_library", @@ -33,6 +36,7 @@ go_library( "//pkg/client/informers/informers_generated/internalversion/core:go_default_library", "//pkg/client/informers/informers_generated/internalversion/extensions:go_default_library", "//pkg/client/informers/informers_generated/internalversion/internalinterfaces:go_default_library", + "//pkg/client/informers/informers_generated/internalversion/networking:go_default_library", "//pkg/client/informers/informers_generated/internalversion/policy:go_default_library", "//pkg/client/informers/informers_generated/internalversion/rbac:go_default_library", "//pkg/client/informers/informers_generated/internalversion/settings:go_default_library", @@ -54,6 +58,7 @@ filegroup( name = "all-srcs", srcs = [ ":package-srcs", + "//pkg/client/informers/informers_generated/internalversion/admissionregistration:all-srcs", "//pkg/client/informers/informers_generated/internalversion/apps:all-srcs", "//pkg/client/informers/informers_generated/internalversion/autoscaling:all-srcs", "//pkg/client/informers/informers_generated/internalversion/batch:all-srcs", @@ -61,6 +66,7 @@ filegroup( "//pkg/client/informers/informers_generated/internalversion/core:all-srcs", "//pkg/client/informers/informers_generated/internalversion/extensions:all-srcs", "//pkg/client/informers/informers_generated/internalversion/internalinterfaces:all-srcs", + "//pkg/client/informers/informers_generated/internalversion/networking:all-srcs", "//pkg/client/informers/informers_generated/internalversion/policy:all-srcs", "//pkg/client/informers/informers_generated/internalversion/rbac:all-srcs", "//pkg/client/informers/informers_generated/internalversion/settings:all-srcs", diff --git a/pkg/client/informers/informers_generated/internalversion/admissionregistration/BUILD b/pkg/client/informers/informers_generated/internalversion/admissionregistration/BUILD new file mode 100644 index 0000000000000..cdf05aa89302c --- /dev/null +++ b/pkg/client/informers/informers_generated/internalversion/admissionregistration/BUILD @@ -0,0 +1,34 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["interface.go"], + tags = ["automanaged"], + deps = [ + "//pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion:go_default_library", + "//pkg/client/informers/informers_generated/internalversion/internalinterfaces:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/client/informers/informers_generated/internalversion/admissionregistration/interface.go b/pkg/client/informers/informers_generated/internalversion/admissionregistration/interface.go new file mode 100644 index 0000000000000..036ae9754b608 --- /dev/null +++ b/pkg/client/informers/informers_generated/internalversion/admissionregistration/interface.go @@ -0,0 +1,44 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package admissionregistration + +import ( + internalversion "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion" + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/internalinterfaces" +) + +// Interface provides access to each of this group's versions. +type Interface interface { + // InternalVersion provides access to shared informers for resources in InternalVersion. + InternalVersion() internalversion.Interface +} + +type group struct { + internalinterfaces.SharedInformerFactory +} + +// New returns a new Interface. +func New(f internalinterfaces.SharedInformerFactory) Interface { + return &group{f} +} + +// InternalVersion returns a new internalversion.Interface. +func (g *group) InternalVersion() internalversion.Interface { + return internalversion.New(g.SharedInformerFactory) +} diff --git a/pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion/BUILD b/pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion/BUILD new file mode 100644 index 0000000000000..d653f6eeb755a --- /dev/null +++ b/pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion/BUILD @@ -0,0 +1,41 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "externaladmissionhookconfiguration.go", + "initializerconfiguration.go", + "interface.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/admissionregistration:go_default_library", + "//pkg/client/clientset_generated/internalclientset:go_default_library", + "//pkg/client/informers/informers_generated/internalversion/internalinterfaces:go_default_library", + "//pkg/client/listers/admissionregistration/internalversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion/externaladmissionhookconfiguration.go b/pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion/externaladmissionhookconfiguration.go new file mode 100644 index 0000000000000..1d703db10beac --- /dev/null +++ b/pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion/externaladmissionhookconfiguration.go @@ -0,0 +1,68 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package internalversion + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + cache "k8s.io/client-go/tools/cache" + admissionregistration "k8s.io/kubernetes/pkg/apis/admissionregistration" + internalclientset "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset" + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/internalinterfaces" + internalversion "k8s.io/kubernetes/pkg/client/listers/admissionregistration/internalversion" + time "time" +) + +// ExternalAdmissionHookConfigurationInformer provides access to a shared informer and lister for +// ExternalAdmissionHookConfigurations. +type ExternalAdmissionHookConfigurationInformer interface { + Informer() cache.SharedIndexInformer + Lister() internalversion.ExternalAdmissionHookConfigurationLister +} + +type externalAdmissionHookConfigurationInformer struct { + factory internalinterfaces.SharedInformerFactory +} + +func newExternalAdmissionHookConfigurationInformer(client internalclientset.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + sharedIndexInformer := cache.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options v1.ListOptions) (runtime.Object, error) { + return client.Admissionregistration().ExternalAdmissionHookConfigurations(v1.NamespaceAll).List(options) + }, + WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { + return client.Admissionregistration().ExternalAdmissionHookConfigurations(v1.NamespaceAll).Watch(options) + }, + }, + &admissionregistration.ExternalAdmissionHookConfiguration{}, + resyncPeriod, + cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, + ) + + return sharedIndexInformer +} + +func (f *externalAdmissionHookConfigurationInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&admissionregistration.ExternalAdmissionHookConfiguration{}, newExternalAdmissionHookConfigurationInformer) +} + +func (f *externalAdmissionHookConfigurationInformer) Lister() internalversion.ExternalAdmissionHookConfigurationLister { + return internalversion.NewExternalAdmissionHookConfigurationLister(f.Informer().GetIndexer()) +} diff --git a/pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion/initializerconfiguration.go b/pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion/initializerconfiguration.go new file mode 100644 index 0000000000000..ecff18037d186 --- /dev/null +++ b/pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion/initializerconfiguration.go @@ -0,0 +1,68 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package internalversion + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + cache "k8s.io/client-go/tools/cache" + admissionregistration "k8s.io/kubernetes/pkg/apis/admissionregistration" + internalclientset "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset" + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/internalinterfaces" + internalversion "k8s.io/kubernetes/pkg/client/listers/admissionregistration/internalversion" + time "time" +) + +// InitializerConfigurationInformer provides access to a shared informer and lister for +// InitializerConfigurations. +type InitializerConfigurationInformer interface { + Informer() cache.SharedIndexInformer + Lister() internalversion.InitializerConfigurationLister +} + +type initializerConfigurationInformer struct { + factory internalinterfaces.SharedInformerFactory +} + +func newInitializerConfigurationInformer(client internalclientset.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + sharedIndexInformer := cache.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options v1.ListOptions) (runtime.Object, error) { + return client.Admissionregistration().InitializerConfigurations(v1.NamespaceAll).List(options) + }, + WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { + return client.Admissionregistration().InitializerConfigurations(v1.NamespaceAll).Watch(options) + }, + }, + &admissionregistration.InitializerConfiguration{}, + resyncPeriod, + cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, + ) + + return sharedIndexInformer +} + +func (f *initializerConfigurationInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&admissionregistration.InitializerConfiguration{}, newInitializerConfigurationInformer) +} + +func (f *initializerConfigurationInformer) Lister() internalversion.InitializerConfigurationLister { + return internalversion.NewInitializerConfigurationLister(f.Informer().GetIndexer()) +} diff --git a/pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion/interface.go b/pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion/interface.go new file mode 100644 index 0000000000000..bd0803e2759fe --- /dev/null +++ b/pkg/client/informers/informers_generated/internalversion/admissionregistration/internalversion/interface.go @@ -0,0 +1,50 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package internalversion + +import ( + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/internalinterfaces" +) + +// Interface provides access to all the informers in this group version. +type Interface interface { + // ExternalAdmissionHookConfigurations returns a ExternalAdmissionHookConfigurationInformer. + ExternalAdmissionHookConfigurations() ExternalAdmissionHookConfigurationInformer + // InitializerConfigurations returns a InitializerConfigurationInformer. + InitializerConfigurations() InitializerConfigurationInformer +} + +type version struct { + internalinterfaces.SharedInformerFactory +} + +// New returns a new Interface. +func New(f internalinterfaces.SharedInformerFactory) Interface { + return &version{f} +} + +// ExternalAdmissionHookConfigurations returns a ExternalAdmissionHookConfigurationInformer. +func (v *version) ExternalAdmissionHookConfigurations() ExternalAdmissionHookConfigurationInformer { + return &externalAdmissionHookConfigurationInformer{factory: v.SharedInformerFactory} +} + +// InitializerConfigurations returns a InitializerConfigurationInformer. +func (v *version) InitializerConfigurations() InitializerConfigurationInformer { + return &initializerConfigurationInformer{factory: v.SharedInformerFactory} +} diff --git a/pkg/client/informers/informers_generated/internalversion/apps/internalversion/BUILD b/pkg/client/informers/informers_generated/internalversion/apps/internalversion/BUILD index 8c07c7126787e..05854af6d8ecc 100644 --- a/pkg/client/informers/informers_generated/internalversion/apps/internalversion/BUILD +++ b/pkg/client/informers/informers_generated/internalversion/apps/internalversion/BUILD @@ -10,6 +10,7 @@ load( go_library( name = "go_default_library", srcs = [ + "controllerrevision.go", "interface.go", "statefulset.go", ], diff --git a/pkg/client/informers/informers_generated/internalversion/apps/internalversion/controllerrevision.go b/pkg/client/informers/informers_generated/internalversion/apps/internalversion/controllerrevision.go new file mode 100644 index 0000000000000..7909e9fbb0462 --- /dev/null +++ b/pkg/client/informers/informers_generated/internalversion/apps/internalversion/controllerrevision.go @@ -0,0 +1,68 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package internalversion + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + cache "k8s.io/client-go/tools/cache" + apps "k8s.io/kubernetes/pkg/apis/apps" + internalclientset "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset" + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/internalinterfaces" + internalversion "k8s.io/kubernetes/pkg/client/listers/apps/internalversion" + time "time" +) + +// ControllerRevisionInformer provides access to a shared informer and lister for +// ControllerRevisions. +type ControllerRevisionInformer interface { + Informer() cache.SharedIndexInformer + Lister() internalversion.ControllerRevisionLister +} + +type controllerRevisionInformer struct { + factory internalinterfaces.SharedInformerFactory +} + +func newControllerRevisionInformer(client internalclientset.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + sharedIndexInformer := cache.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options v1.ListOptions) (runtime.Object, error) { + return client.Apps().ControllerRevisions(v1.NamespaceAll).List(options) + }, + WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { + return client.Apps().ControllerRevisions(v1.NamespaceAll).Watch(options) + }, + }, + &apps.ControllerRevision{}, + resyncPeriod, + cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, + ) + + return sharedIndexInformer +} + +func (f *controllerRevisionInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&apps.ControllerRevision{}, newControllerRevisionInformer) +} + +func (f *controllerRevisionInformer) Lister() internalversion.ControllerRevisionLister { + return internalversion.NewControllerRevisionLister(f.Informer().GetIndexer()) +} diff --git a/pkg/client/informers/informers_generated/internalversion/apps/internalversion/interface.go b/pkg/client/informers/informers_generated/internalversion/apps/internalversion/interface.go index 30534bcc1681b..bd5ec23b1522f 100644 --- a/pkg/client/informers/informers_generated/internalversion/apps/internalversion/interface.go +++ b/pkg/client/informers/informers_generated/internalversion/apps/internalversion/interface.go @@ -24,6 +24,8 @@ import ( // Interface provides access to all the informers in this group version. type Interface interface { + // ControllerRevisions returns a ControllerRevisionInformer. + ControllerRevisions() ControllerRevisionInformer // StatefulSets returns a StatefulSetInformer. StatefulSets() StatefulSetInformer } @@ -37,6 +39,11 @@ func New(f internalinterfaces.SharedInformerFactory) Interface { return &version{f} } +// ControllerRevisions returns a ControllerRevisionInformer. +func (v *version) ControllerRevisions() ControllerRevisionInformer { + return &controllerRevisionInformer{factory: v.SharedInformerFactory} +} + // StatefulSets returns a StatefulSetInformer. func (v *version) StatefulSets() StatefulSetInformer { return &statefulSetInformer{factory: v.SharedInformerFactory} diff --git a/pkg/client/informers/informers_generated/internalversion/factory.go b/pkg/client/informers/informers_generated/internalversion/factory.go index b7613c1d211d8..54822806b30ca 100644 --- a/pkg/client/informers/informers_generated/internalversion/factory.go +++ b/pkg/client/informers/informers_generated/internalversion/factory.go @@ -23,6 +23,7 @@ import ( schema "k8s.io/apimachinery/pkg/runtime/schema" cache "k8s.io/client-go/tools/cache" internalclientset "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset" + admissionregistration "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/admissionregistration" apps "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/apps" autoscaling "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/autoscaling" batch "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/batch" @@ -30,6 +31,7 @@ import ( core "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/core" extensions "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/extensions" internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/internalinterfaces" + networking "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/networking" policy "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/policy" rbac "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/rbac" settings "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/settings" @@ -119,18 +121,24 @@ type SharedInformerFactory interface { ForResource(resource schema.GroupVersionResource) (GenericInformer, error) WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool + Admissionregistration() admissionregistration.Interface Apps() apps.Interface Autoscaling() autoscaling.Interface Batch() batch.Interface Certificates() certificates.Interface Core() core.Interface Extensions() extensions.Interface + Networking() networking.Interface Policy() policy.Interface Rbac() rbac.Interface Settings() settings.Interface Storage() storage.Interface } +func (f *sharedInformerFactory) Admissionregistration() admissionregistration.Interface { + return admissionregistration.New(f) +} + func (f *sharedInformerFactory) Apps() apps.Interface { return apps.New(f) } @@ -155,6 +163,10 @@ func (f *sharedInformerFactory) Extensions() extensions.Interface { return extensions.New(f) } +func (f *sharedInformerFactory) Networking() networking.Interface { + return networking.New(f) +} + func (f *sharedInformerFactory) Policy() policy.Interface { return policy.New(f) } diff --git a/pkg/client/informers/informers_generated/internalversion/generic.go b/pkg/client/informers/informers_generated/internalversion/generic.go index f12c17b5bd03e..724584d070828 100644 --- a/pkg/client/informers/informers_generated/internalversion/generic.go +++ b/pkg/client/informers/informers_generated/internalversion/generic.go @@ -23,11 +23,13 @@ import ( schema "k8s.io/apimachinery/pkg/runtime/schema" cache "k8s.io/client-go/tools/cache" api "k8s.io/kubernetes/pkg/api" + admissionregistration "k8s.io/kubernetes/pkg/apis/admissionregistration" apps "k8s.io/kubernetes/pkg/apis/apps" autoscaling "k8s.io/kubernetes/pkg/apis/autoscaling" batch "k8s.io/kubernetes/pkg/apis/batch" certificates "k8s.io/kubernetes/pkg/apis/certificates" extensions "k8s.io/kubernetes/pkg/apis/extensions" + networking "k8s.io/kubernetes/pkg/apis/networking" policy "k8s.io/kubernetes/pkg/apis/policy" rbac "k8s.io/kubernetes/pkg/apis/rbac" settings "k8s.io/kubernetes/pkg/apis/settings" @@ -60,7 +62,15 @@ func (f *genericInformer) Lister() cache.GenericLister { // TODO extend this to unknown resources with a client pool func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource) (GenericInformer, error) { switch resource { - // Group=Apps, Version=InternalVersion + // Group=Admissionregistration, Version=InternalVersion + case admissionregistration.SchemeGroupVersion.WithResource("externaladmissionhookconfigurations"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Admissionregistration().InternalVersion().ExternalAdmissionHookConfigurations().Informer()}, nil + case admissionregistration.SchemeGroupVersion.WithResource("initializerconfigurations"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Admissionregistration().InternalVersion().InitializerConfigurations().Informer()}, nil + + // Group=Apps, Version=InternalVersion + case apps.SchemeGroupVersion.WithResource("controllerrevisions"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Apps().InternalVersion().ControllerRevisions().Informer()}, nil case apps.SchemeGroupVersion.WithResource("statefulsets"): return &genericInformer{resource: resource.GroupResource(), informer: f.Apps().InternalVersion().StatefulSets().Informer()}, nil @@ -128,6 +138,10 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource case extensions.SchemeGroupVersion.WithResource("thirdpartyresources"): return &genericInformer{resource: resource.GroupResource(), informer: f.Extensions().InternalVersion().ThirdPartyResources().Informer()}, nil + // Group=Networking, Version=InternalVersion + case networking.SchemeGroupVersion.WithResource("networkpolicies"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Networking().InternalVersion().NetworkPolicies().Informer()}, nil + // Group=Policy, Version=InternalVersion case policy.SchemeGroupVersion.WithResource("poddisruptionbudgets"): return &genericInformer{resource: resource.GroupResource(), informer: f.Policy().InternalVersion().PodDisruptionBudgets().Informer()}, nil diff --git a/pkg/client/informers/informers_generated/internalversion/networking/BUILD b/pkg/client/informers/informers_generated/internalversion/networking/BUILD new file mode 100644 index 0000000000000..63b4fc3d45e5f --- /dev/null +++ b/pkg/client/informers/informers_generated/internalversion/networking/BUILD @@ -0,0 +1,34 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["interface.go"], + tags = ["automanaged"], + deps = [ + "//pkg/client/informers/informers_generated/internalversion/internalinterfaces:go_default_library", + "//pkg/client/informers/informers_generated/internalversion/networking/internalversion:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/client/informers/informers_generated/internalversion/networking/internalversion:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/client/informers/informers_generated/internalversion/networking/interface.go b/pkg/client/informers/informers_generated/internalversion/networking/interface.go new file mode 100644 index 0000000000000..bae69a5041414 --- /dev/null +++ b/pkg/client/informers/informers_generated/internalversion/networking/interface.go @@ -0,0 +1,44 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package networking + +import ( + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/internalinterfaces" + internalversion "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/networking/internalversion" +) + +// Interface provides access to each of this group's versions. +type Interface interface { + // InternalVersion provides access to shared informers for resources in InternalVersion. + InternalVersion() internalversion.Interface +} + +type group struct { + internalinterfaces.SharedInformerFactory +} + +// New returns a new Interface. +func New(f internalinterfaces.SharedInformerFactory) Interface { + return &group{f} +} + +// InternalVersion returns a new internalversion.Interface. +func (g *group) InternalVersion() internalversion.Interface { + return internalversion.New(g.SharedInformerFactory) +} diff --git a/pkg/client/informers/informers_generated/internalversion/networking/internalversion/BUILD b/pkg/client/informers/informers_generated/internalversion/networking/internalversion/BUILD new file mode 100644 index 0000000000000..dffb4f61c9d7d --- /dev/null +++ b/pkg/client/informers/informers_generated/internalversion/networking/internalversion/BUILD @@ -0,0 +1,40 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "interface.go", + "networkpolicy.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/networking:go_default_library", + "//pkg/client/clientset_generated/internalclientset:go_default_library", + "//pkg/client/informers/informers_generated/internalversion/internalinterfaces:go_default_library", + "//pkg/client/listers/networking/internalversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/client/informers/informers_generated/internalversion/networking/internalversion/interface.go b/pkg/client/informers/informers_generated/internalversion/networking/internalversion/interface.go new file mode 100644 index 0000000000000..e3eb5fa8181a8 --- /dev/null +++ b/pkg/client/informers/informers_generated/internalversion/networking/internalversion/interface.go @@ -0,0 +1,43 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package internalversion + +import ( + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/internalinterfaces" +) + +// Interface provides access to all the informers in this group version. +type Interface interface { + // NetworkPolicies returns a NetworkPolicyInformer. + NetworkPolicies() NetworkPolicyInformer +} + +type version struct { + internalinterfaces.SharedInformerFactory +} + +// New returns a new Interface. +func New(f internalinterfaces.SharedInformerFactory) Interface { + return &version{f} +} + +// NetworkPolicies returns a NetworkPolicyInformer. +func (v *version) NetworkPolicies() NetworkPolicyInformer { + return &networkPolicyInformer{factory: v.SharedInformerFactory} +} diff --git a/pkg/client/informers/informers_generated/internalversion/networking/internalversion/networkpolicy.go b/pkg/client/informers/informers_generated/internalversion/networking/internalversion/networkpolicy.go new file mode 100644 index 0000000000000..b53166255f6e2 --- /dev/null +++ b/pkg/client/informers/informers_generated/internalversion/networking/internalversion/networkpolicy.go @@ -0,0 +1,68 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package internalversion + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + cache "k8s.io/client-go/tools/cache" + networking "k8s.io/kubernetes/pkg/apis/networking" + internalclientset "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset" + internalinterfaces "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/internalinterfaces" + internalversion "k8s.io/kubernetes/pkg/client/listers/networking/internalversion" + time "time" +) + +// NetworkPolicyInformer provides access to a shared informer and lister for +// NetworkPolicies. +type NetworkPolicyInformer interface { + Informer() cache.SharedIndexInformer + Lister() internalversion.NetworkPolicyLister +} + +type networkPolicyInformer struct { + factory internalinterfaces.SharedInformerFactory +} + +func newNetworkPolicyInformer(client internalclientset.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + sharedIndexInformer := cache.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options v1.ListOptions) (runtime.Object, error) { + return client.Networking().NetworkPolicies(v1.NamespaceAll).List(options) + }, + WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { + return client.Networking().NetworkPolicies(v1.NamespaceAll).Watch(options) + }, + }, + &networking.NetworkPolicy{}, + resyncPeriod, + cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, + ) + + return sharedIndexInformer +} + +func (f *networkPolicyInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&networking.NetworkPolicy{}, newNetworkPolicyInformer) +} + +func (f *networkPolicyInformer) Lister() internalversion.NetworkPolicyLister { + return internalversion.NewNetworkPolicyLister(f.Informer().GetIndexer()) +} diff --git a/pkg/client/listers/admissionregistration/internalversion/BUILD b/pkg/client/listers/admissionregistration/internalversion/BUILD new file mode 100644 index 0000000000000..5b6b5e51bbb77 --- /dev/null +++ b/pkg/client/listers/admissionregistration/internalversion/BUILD @@ -0,0 +1,37 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "expansion_generated.go", + "externaladmissionhookconfiguration.go", + "initializerconfiguration.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/admissionregistration:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/client/listers/admissionregistration/internalversion/expansion_generated.go b/pkg/client/listers/admissionregistration/internalversion/expansion_generated.go new file mode 100644 index 0000000000000..1312196a18105 --- /dev/null +++ b/pkg/client/listers/admissionregistration/internalversion/expansion_generated.go @@ -0,0 +1,35 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package internalversion + +// ExternalAdmissionHookConfigurationListerExpansion allows custom methods to be added to +// ExternalAdmissionHookConfigurationLister. +type ExternalAdmissionHookConfigurationListerExpansion interface{} + +// ExternalAdmissionHookConfigurationNamespaceListerExpansion allows custom methods to be added to +// ExternalAdmissionHookConfigurationNamespaceLister. +type ExternalAdmissionHookConfigurationNamespaceListerExpansion interface{} + +// InitializerConfigurationListerExpansion allows custom methods to be added to +// InitializerConfigurationLister. +type InitializerConfigurationListerExpansion interface{} + +// InitializerConfigurationNamespaceListerExpansion allows custom methods to be added to +// InitializerConfigurationNamespaceLister. +type InitializerConfigurationNamespaceListerExpansion interface{} diff --git a/pkg/client/listers/admissionregistration/internalversion/externaladmissionhookconfiguration.go b/pkg/client/listers/admissionregistration/internalversion/externaladmissionhookconfiguration.go new file mode 100644 index 0000000000000..5faafe8cc80dc --- /dev/null +++ b/pkg/client/listers/admissionregistration/internalversion/externaladmissionhookconfiguration.go @@ -0,0 +1,94 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package internalversion + +import ( + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/client-go/tools/cache" + admissionregistration "k8s.io/kubernetes/pkg/apis/admissionregistration" +) + +// ExternalAdmissionHookConfigurationLister helps list ExternalAdmissionHookConfigurations. +type ExternalAdmissionHookConfigurationLister interface { + // List lists all ExternalAdmissionHookConfigurations in the indexer. + List(selector labels.Selector) (ret []*admissionregistration.ExternalAdmissionHookConfiguration, err error) + // ExternalAdmissionHookConfigurations returns an object that can list and get ExternalAdmissionHookConfigurations. + ExternalAdmissionHookConfigurations(namespace string) ExternalAdmissionHookConfigurationNamespaceLister + ExternalAdmissionHookConfigurationListerExpansion +} + +// externalAdmissionHookConfigurationLister implements the ExternalAdmissionHookConfigurationLister interface. +type externalAdmissionHookConfigurationLister struct { + indexer cache.Indexer +} + +// NewExternalAdmissionHookConfigurationLister returns a new ExternalAdmissionHookConfigurationLister. +func NewExternalAdmissionHookConfigurationLister(indexer cache.Indexer) ExternalAdmissionHookConfigurationLister { + return &externalAdmissionHookConfigurationLister{indexer: indexer} +} + +// List lists all ExternalAdmissionHookConfigurations in the indexer. +func (s *externalAdmissionHookConfigurationLister) List(selector labels.Selector) (ret []*admissionregistration.ExternalAdmissionHookConfiguration, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*admissionregistration.ExternalAdmissionHookConfiguration)) + }) + return ret, err +} + +// ExternalAdmissionHookConfigurations returns an object that can list and get ExternalAdmissionHookConfigurations. +func (s *externalAdmissionHookConfigurationLister) ExternalAdmissionHookConfigurations(namespace string) ExternalAdmissionHookConfigurationNamespaceLister { + return externalAdmissionHookConfigurationNamespaceLister{indexer: s.indexer, namespace: namespace} +} + +// ExternalAdmissionHookConfigurationNamespaceLister helps list and get ExternalAdmissionHookConfigurations. +type ExternalAdmissionHookConfigurationNamespaceLister interface { + // List lists all ExternalAdmissionHookConfigurations in the indexer for a given namespace. + List(selector labels.Selector) (ret []*admissionregistration.ExternalAdmissionHookConfiguration, err error) + // Get retrieves the ExternalAdmissionHookConfiguration from the indexer for a given namespace and name. + Get(name string) (*admissionregistration.ExternalAdmissionHookConfiguration, error) + ExternalAdmissionHookConfigurationNamespaceListerExpansion +} + +// externalAdmissionHookConfigurationNamespaceLister implements the ExternalAdmissionHookConfigurationNamespaceLister +// interface. +type externalAdmissionHookConfigurationNamespaceLister struct { + indexer cache.Indexer + namespace string +} + +// List lists all ExternalAdmissionHookConfigurations in the indexer for a given namespace. +func (s externalAdmissionHookConfigurationNamespaceLister) List(selector labels.Selector) (ret []*admissionregistration.ExternalAdmissionHookConfiguration, err error) { + err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { + ret = append(ret, m.(*admissionregistration.ExternalAdmissionHookConfiguration)) + }) + return ret, err +} + +// Get retrieves the ExternalAdmissionHookConfiguration from the indexer for a given namespace and name. +func (s externalAdmissionHookConfigurationNamespaceLister) Get(name string) (*admissionregistration.ExternalAdmissionHookConfiguration, error) { + obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(admissionregistration.Resource("externaladmissionhookconfiguration"), name) + } + return obj.(*admissionregistration.ExternalAdmissionHookConfiguration), nil +} diff --git a/pkg/client/listers/admissionregistration/internalversion/initializerconfiguration.go b/pkg/client/listers/admissionregistration/internalversion/initializerconfiguration.go new file mode 100644 index 0000000000000..3f9a3ccf30845 --- /dev/null +++ b/pkg/client/listers/admissionregistration/internalversion/initializerconfiguration.go @@ -0,0 +1,94 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package internalversion + +import ( + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/client-go/tools/cache" + admissionregistration "k8s.io/kubernetes/pkg/apis/admissionregistration" +) + +// InitializerConfigurationLister helps list InitializerConfigurations. +type InitializerConfigurationLister interface { + // List lists all InitializerConfigurations in the indexer. + List(selector labels.Selector) (ret []*admissionregistration.InitializerConfiguration, err error) + // InitializerConfigurations returns an object that can list and get InitializerConfigurations. + InitializerConfigurations(namespace string) InitializerConfigurationNamespaceLister + InitializerConfigurationListerExpansion +} + +// initializerConfigurationLister implements the InitializerConfigurationLister interface. +type initializerConfigurationLister struct { + indexer cache.Indexer +} + +// NewInitializerConfigurationLister returns a new InitializerConfigurationLister. +func NewInitializerConfigurationLister(indexer cache.Indexer) InitializerConfigurationLister { + return &initializerConfigurationLister{indexer: indexer} +} + +// List lists all InitializerConfigurations in the indexer. +func (s *initializerConfigurationLister) List(selector labels.Selector) (ret []*admissionregistration.InitializerConfiguration, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*admissionregistration.InitializerConfiguration)) + }) + return ret, err +} + +// InitializerConfigurations returns an object that can list and get InitializerConfigurations. +func (s *initializerConfigurationLister) InitializerConfigurations(namespace string) InitializerConfigurationNamespaceLister { + return initializerConfigurationNamespaceLister{indexer: s.indexer, namespace: namespace} +} + +// InitializerConfigurationNamespaceLister helps list and get InitializerConfigurations. +type InitializerConfigurationNamespaceLister interface { + // List lists all InitializerConfigurations in the indexer for a given namespace. + List(selector labels.Selector) (ret []*admissionregistration.InitializerConfiguration, err error) + // Get retrieves the InitializerConfiguration from the indexer for a given namespace and name. + Get(name string) (*admissionregistration.InitializerConfiguration, error) + InitializerConfigurationNamespaceListerExpansion +} + +// initializerConfigurationNamespaceLister implements the InitializerConfigurationNamespaceLister +// interface. +type initializerConfigurationNamespaceLister struct { + indexer cache.Indexer + namespace string +} + +// List lists all InitializerConfigurations in the indexer for a given namespace. +func (s initializerConfigurationNamespaceLister) List(selector labels.Selector) (ret []*admissionregistration.InitializerConfiguration, err error) { + err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { + ret = append(ret, m.(*admissionregistration.InitializerConfiguration)) + }) + return ret, err +} + +// Get retrieves the InitializerConfiguration from the indexer for a given namespace and name. +func (s initializerConfigurationNamespaceLister) Get(name string) (*admissionregistration.InitializerConfiguration, error) { + obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(admissionregistration.Resource("initializerconfiguration"), name) + } + return obj.(*admissionregistration.InitializerConfiguration), nil +} diff --git a/pkg/client/listers/admissionregistration/v1alpha1/BUILD b/pkg/client/listers/admissionregistration/v1alpha1/BUILD new file mode 100644 index 0000000000000..266abec4d1f75 --- /dev/null +++ b/pkg/client/listers/admissionregistration/v1alpha1/BUILD @@ -0,0 +1,37 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "expansion_generated.go", + "externaladmissionhookconfiguration.go", + "initializerconfiguration.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/client/listers/admissionregistration/v1alpha1/expansion_generated.go b/pkg/client/listers/admissionregistration/v1alpha1/expansion_generated.go new file mode 100644 index 0000000000000..3282a8bcfeb23 --- /dev/null +++ b/pkg/client/listers/admissionregistration/v1alpha1/expansion_generated.go @@ -0,0 +1,35 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package v1alpha1 + +// ExternalAdmissionHookConfigurationListerExpansion allows custom methods to be added to +// ExternalAdmissionHookConfigurationLister. +type ExternalAdmissionHookConfigurationListerExpansion interface{} + +// ExternalAdmissionHookConfigurationNamespaceListerExpansion allows custom methods to be added to +// ExternalAdmissionHookConfigurationNamespaceLister. +type ExternalAdmissionHookConfigurationNamespaceListerExpansion interface{} + +// InitializerConfigurationListerExpansion allows custom methods to be added to +// InitializerConfigurationLister. +type InitializerConfigurationListerExpansion interface{} + +// InitializerConfigurationNamespaceListerExpansion allows custom methods to be added to +// InitializerConfigurationNamespaceLister. +type InitializerConfigurationNamespaceListerExpansion interface{} diff --git a/pkg/client/listers/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go b/pkg/client/listers/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go new file mode 100644 index 0000000000000..e594077be5d83 --- /dev/null +++ b/pkg/client/listers/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go @@ -0,0 +1,94 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package v1alpha1 + +import ( + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/client-go/tools/cache" + v1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" +) + +// ExternalAdmissionHookConfigurationLister helps list ExternalAdmissionHookConfigurations. +type ExternalAdmissionHookConfigurationLister interface { + // List lists all ExternalAdmissionHookConfigurations in the indexer. + List(selector labels.Selector) (ret []*v1alpha1.ExternalAdmissionHookConfiguration, err error) + // ExternalAdmissionHookConfigurations returns an object that can list and get ExternalAdmissionHookConfigurations. + ExternalAdmissionHookConfigurations(namespace string) ExternalAdmissionHookConfigurationNamespaceLister + ExternalAdmissionHookConfigurationListerExpansion +} + +// externalAdmissionHookConfigurationLister implements the ExternalAdmissionHookConfigurationLister interface. +type externalAdmissionHookConfigurationLister struct { + indexer cache.Indexer +} + +// NewExternalAdmissionHookConfigurationLister returns a new ExternalAdmissionHookConfigurationLister. +func NewExternalAdmissionHookConfigurationLister(indexer cache.Indexer) ExternalAdmissionHookConfigurationLister { + return &externalAdmissionHookConfigurationLister{indexer: indexer} +} + +// List lists all ExternalAdmissionHookConfigurations in the indexer. +func (s *externalAdmissionHookConfigurationLister) List(selector labels.Selector) (ret []*v1alpha1.ExternalAdmissionHookConfiguration, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*v1alpha1.ExternalAdmissionHookConfiguration)) + }) + return ret, err +} + +// ExternalAdmissionHookConfigurations returns an object that can list and get ExternalAdmissionHookConfigurations. +func (s *externalAdmissionHookConfigurationLister) ExternalAdmissionHookConfigurations(namespace string) ExternalAdmissionHookConfigurationNamespaceLister { + return externalAdmissionHookConfigurationNamespaceLister{indexer: s.indexer, namespace: namespace} +} + +// ExternalAdmissionHookConfigurationNamespaceLister helps list and get ExternalAdmissionHookConfigurations. +type ExternalAdmissionHookConfigurationNamespaceLister interface { + // List lists all ExternalAdmissionHookConfigurations in the indexer for a given namespace. + List(selector labels.Selector) (ret []*v1alpha1.ExternalAdmissionHookConfiguration, err error) + // Get retrieves the ExternalAdmissionHookConfiguration from the indexer for a given namespace and name. + Get(name string) (*v1alpha1.ExternalAdmissionHookConfiguration, error) + ExternalAdmissionHookConfigurationNamespaceListerExpansion +} + +// externalAdmissionHookConfigurationNamespaceLister implements the ExternalAdmissionHookConfigurationNamespaceLister +// interface. +type externalAdmissionHookConfigurationNamespaceLister struct { + indexer cache.Indexer + namespace string +} + +// List lists all ExternalAdmissionHookConfigurations in the indexer for a given namespace. +func (s externalAdmissionHookConfigurationNamespaceLister) List(selector labels.Selector) (ret []*v1alpha1.ExternalAdmissionHookConfiguration, err error) { + err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { + ret = append(ret, m.(*v1alpha1.ExternalAdmissionHookConfiguration)) + }) + return ret, err +} + +// Get retrieves the ExternalAdmissionHookConfiguration from the indexer for a given namespace and name. +func (s externalAdmissionHookConfigurationNamespaceLister) Get(name string) (*v1alpha1.ExternalAdmissionHookConfiguration, error) { + obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(v1alpha1.Resource("externaladmissionhookconfiguration"), name) + } + return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), nil +} diff --git a/pkg/client/listers/admissionregistration/v1alpha1/initializerconfiguration.go b/pkg/client/listers/admissionregistration/v1alpha1/initializerconfiguration.go new file mode 100644 index 0000000000000..3387032c7f93b --- /dev/null +++ b/pkg/client/listers/admissionregistration/v1alpha1/initializerconfiguration.go @@ -0,0 +1,94 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package v1alpha1 + +import ( + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/client-go/tools/cache" + v1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" +) + +// InitializerConfigurationLister helps list InitializerConfigurations. +type InitializerConfigurationLister interface { + // List lists all InitializerConfigurations in the indexer. + List(selector labels.Selector) (ret []*v1alpha1.InitializerConfiguration, err error) + // InitializerConfigurations returns an object that can list and get InitializerConfigurations. + InitializerConfigurations(namespace string) InitializerConfigurationNamespaceLister + InitializerConfigurationListerExpansion +} + +// initializerConfigurationLister implements the InitializerConfigurationLister interface. +type initializerConfigurationLister struct { + indexer cache.Indexer +} + +// NewInitializerConfigurationLister returns a new InitializerConfigurationLister. +func NewInitializerConfigurationLister(indexer cache.Indexer) InitializerConfigurationLister { + return &initializerConfigurationLister{indexer: indexer} +} + +// List lists all InitializerConfigurations in the indexer. +func (s *initializerConfigurationLister) List(selector labels.Selector) (ret []*v1alpha1.InitializerConfiguration, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*v1alpha1.InitializerConfiguration)) + }) + return ret, err +} + +// InitializerConfigurations returns an object that can list and get InitializerConfigurations. +func (s *initializerConfigurationLister) InitializerConfigurations(namespace string) InitializerConfigurationNamespaceLister { + return initializerConfigurationNamespaceLister{indexer: s.indexer, namespace: namespace} +} + +// InitializerConfigurationNamespaceLister helps list and get InitializerConfigurations. +type InitializerConfigurationNamespaceLister interface { + // List lists all InitializerConfigurations in the indexer for a given namespace. + List(selector labels.Selector) (ret []*v1alpha1.InitializerConfiguration, err error) + // Get retrieves the InitializerConfiguration from the indexer for a given namespace and name. + Get(name string) (*v1alpha1.InitializerConfiguration, error) + InitializerConfigurationNamespaceListerExpansion +} + +// initializerConfigurationNamespaceLister implements the InitializerConfigurationNamespaceLister +// interface. +type initializerConfigurationNamespaceLister struct { + indexer cache.Indexer + namespace string +} + +// List lists all InitializerConfigurations in the indexer for a given namespace. +func (s initializerConfigurationNamespaceLister) List(selector labels.Selector) (ret []*v1alpha1.InitializerConfiguration, err error) { + err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { + ret = append(ret, m.(*v1alpha1.InitializerConfiguration)) + }) + return ret, err +} + +// Get retrieves the InitializerConfiguration from the indexer for a given namespace and name. +func (s initializerConfigurationNamespaceLister) Get(name string) (*v1alpha1.InitializerConfiguration, error) { + obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(v1alpha1.Resource("initializerconfiguration"), name) + } + return obj.(*v1alpha1.InitializerConfiguration), nil +} diff --git a/pkg/client/listers/apps/internalversion/BUILD b/pkg/client/listers/apps/internalversion/BUILD index a7be0424d8b96..cf4f3c2a02786 100644 --- a/pkg/client/listers/apps/internalversion/BUILD +++ b/pkg/client/listers/apps/internalversion/BUILD @@ -10,6 +10,7 @@ load( go_library( name = "go_default_library", srcs = [ + "controllerrevision.go", "expansion_generated.go", "statefulset.go", "statefulset_expansion.go", diff --git a/pkg/client/listers/apps/internalversion/controllerrevision.go b/pkg/client/listers/apps/internalversion/controllerrevision.go new file mode 100644 index 0000000000000..89efbf8c8cbc5 --- /dev/null +++ b/pkg/client/listers/apps/internalversion/controllerrevision.go @@ -0,0 +1,94 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package internalversion + +import ( + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/client-go/tools/cache" + apps "k8s.io/kubernetes/pkg/apis/apps" +) + +// ControllerRevisionLister helps list ControllerRevisions. +type ControllerRevisionLister interface { + // List lists all ControllerRevisions in the indexer. + List(selector labels.Selector) (ret []*apps.ControllerRevision, err error) + // ControllerRevisions returns an object that can list and get ControllerRevisions. + ControllerRevisions(namespace string) ControllerRevisionNamespaceLister + ControllerRevisionListerExpansion +} + +// controllerRevisionLister implements the ControllerRevisionLister interface. +type controllerRevisionLister struct { + indexer cache.Indexer +} + +// NewControllerRevisionLister returns a new ControllerRevisionLister. +func NewControllerRevisionLister(indexer cache.Indexer) ControllerRevisionLister { + return &controllerRevisionLister{indexer: indexer} +} + +// List lists all ControllerRevisions in the indexer. +func (s *controllerRevisionLister) List(selector labels.Selector) (ret []*apps.ControllerRevision, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*apps.ControllerRevision)) + }) + return ret, err +} + +// ControllerRevisions returns an object that can list and get ControllerRevisions. +func (s *controllerRevisionLister) ControllerRevisions(namespace string) ControllerRevisionNamespaceLister { + return controllerRevisionNamespaceLister{indexer: s.indexer, namespace: namespace} +} + +// ControllerRevisionNamespaceLister helps list and get ControllerRevisions. +type ControllerRevisionNamespaceLister interface { + // List lists all ControllerRevisions in the indexer for a given namespace. + List(selector labels.Selector) (ret []*apps.ControllerRevision, err error) + // Get retrieves the ControllerRevision from the indexer for a given namespace and name. + Get(name string) (*apps.ControllerRevision, error) + ControllerRevisionNamespaceListerExpansion +} + +// controllerRevisionNamespaceLister implements the ControllerRevisionNamespaceLister +// interface. +type controllerRevisionNamespaceLister struct { + indexer cache.Indexer + namespace string +} + +// List lists all ControllerRevisions in the indexer for a given namespace. +func (s controllerRevisionNamespaceLister) List(selector labels.Selector) (ret []*apps.ControllerRevision, err error) { + err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { + ret = append(ret, m.(*apps.ControllerRevision)) + }) + return ret, err +} + +// Get retrieves the ControllerRevision from the indexer for a given namespace and name. +func (s controllerRevisionNamespaceLister) Get(name string) (*apps.ControllerRevision, error) { + obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(apps.Resource("controllerrevision"), name) + } + return obj.(*apps.ControllerRevision), nil +} diff --git a/pkg/client/listers/apps/internalversion/expansion_generated.go b/pkg/client/listers/apps/internalversion/expansion_generated.go index a510c6ad7ed04..9aa9ff54cfd9c 100644 --- a/pkg/client/listers/apps/internalversion/expansion_generated.go +++ b/pkg/client/listers/apps/internalversion/expansion_generated.go @@ -17,3 +17,11 @@ limitations under the License. // This file was automatically generated by lister-gen package internalversion + +// ControllerRevisionListerExpansion allows custom methods to be added to +// ControllerRevisionLister. +type ControllerRevisionListerExpansion interface{} + +// ControllerRevisionNamespaceListerExpansion allows custom methods to be added to +// ControllerRevisionNamespaceLister. +type ControllerRevisionNamespaceListerExpansion interface{} diff --git a/pkg/client/listers/apps/v1beta1/BUILD b/pkg/client/listers/apps/v1beta1/BUILD index 87137b8a7a591..ae663dbf4cf3d 100644 --- a/pkg/client/listers/apps/v1beta1/BUILD +++ b/pkg/client/listers/apps/v1beta1/BUILD @@ -10,6 +10,7 @@ load( go_library( name = "go_default_library", srcs = [ + "controllerrevision.go", "deployment.go", "expansion_generated.go", "scale.go", diff --git a/pkg/client/listers/apps/v1beta1/controllerrevision.go b/pkg/client/listers/apps/v1beta1/controllerrevision.go new file mode 100644 index 0000000000000..f6569c34f72bf --- /dev/null +++ b/pkg/client/listers/apps/v1beta1/controllerrevision.go @@ -0,0 +1,94 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package v1beta1 + +import ( + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/client-go/tools/cache" + v1beta1 "k8s.io/kubernetes/pkg/apis/apps/v1beta1" +) + +// ControllerRevisionLister helps list ControllerRevisions. +type ControllerRevisionLister interface { + // List lists all ControllerRevisions in the indexer. + List(selector labels.Selector) (ret []*v1beta1.ControllerRevision, err error) + // ControllerRevisions returns an object that can list and get ControllerRevisions. + ControllerRevisions(namespace string) ControllerRevisionNamespaceLister + ControllerRevisionListerExpansion +} + +// controllerRevisionLister implements the ControllerRevisionLister interface. +type controllerRevisionLister struct { + indexer cache.Indexer +} + +// NewControllerRevisionLister returns a new ControllerRevisionLister. +func NewControllerRevisionLister(indexer cache.Indexer) ControllerRevisionLister { + return &controllerRevisionLister{indexer: indexer} +} + +// List lists all ControllerRevisions in the indexer. +func (s *controllerRevisionLister) List(selector labels.Selector) (ret []*v1beta1.ControllerRevision, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*v1beta1.ControllerRevision)) + }) + return ret, err +} + +// ControllerRevisions returns an object that can list and get ControllerRevisions. +func (s *controllerRevisionLister) ControllerRevisions(namespace string) ControllerRevisionNamespaceLister { + return controllerRevisionNamespaceLister{indexer: s.indexer, namespace: namespace} +} + +// ControllerRevisionNamespaceLister helps list and get ControllerRevisions. +type ControllerRevisionNamespaceLister interface { + // List lists all ControllerRevisions in the indexer for a given namespace. + List(selector labels.Selector) (ret []*v1beta1.ControllerRevision, err error) + // Get retrieves the ControllerRevision from the indexer for a given namespace and name. + Get(name string) (*v1beta1.ControllerRevision, error) + ControllerRevisionNamespaceListerExpansion +} + +// controllerRevisionNamespaceLister implements the ControllerRevisionNamespaceLister +// interface. +type controllerRevisionNamespaceLister struct { + indexer cache.Indexer + namespace string +} + +// List lists all ControllerRevisions in the indexer for a given namespace. +func (s controllerRevisionNamespaceLister) List(selector labels.Selector) (ret []*v1beta1.ControllerRevision, err error) { + err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { + ret = append(ret, m.(*v1beta1.ControllerRevision)) + }) + return ret, err +} + +// Get retrieves the ControllerRevision from the indexer for a given namespace and name. +func (s controllerRevisionNamespaceLister) Get(name string) (*v1beta1.ControllerRevision, error) { + obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(v1beta1.Resource("controllerrevision"), name) + } + return obj.(*v1beta1.ControllerRevision), nil +} diff --git a/pkg/client/listers/apps/v1beta1/expansion_generated.go b/pkg/client/listers/apps/v1beta1/expansion_generated.go index a648745f11a0e..441ceecdd43a6 100644 --- a/pkg/client/listers/apps/v1beta1/expansion_generated.go +++ b/pkg/client/listers/apps/v1beta1/expansion_generated.go @@ -18,6 +18,14 @@ limitations under the License. package v1beta1 +// ControllerRevisionListerExpansion allows custom methods to be added to +// ControllerRevisionLister. +type ControllerRevisionListerExpansion interface{} + +// ControllerRevisionNamespaceListerExpansion allows custom methods to be added to +// ControllerRevisionNamespaceLister. +type ControllerRevisionNamespaceListerExpansion interface{} + // DeploymentListerExpansion allows custom methods to be added to // DeploymentLister. type DeploymentListerExpansion interface{} diff --git a/pkg/client/listers/networking/internalversion/BUILD b/pkg/client/listers/networking/internalversion/BUILD new file mode 100644 index 0000000000000..2c095eaac972f --- /dev/null +++ b/pkg/client/listers/networking/internalversion/BUILD @@ -0,0 +1,36 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "expansion_generated.go", + "networkpolicy.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/networking:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/client/listers/networking/internalversion/expansion_generated.go b/pkg/client/listers/networking/internalversion/expansion_generated.go new file mode 100644 index 0000000000000..085ac329ce11a --- /dev/null +++ b/pkg/client/listers/networking/internalversion/expansion_generated.go @@ -0,0 +1,27 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package internalversion + +// NetworkPolicyListerExpansion allows custom methods to be added to +// NetworkPolicyLister. +type NetworkPolicyListerExpansion interface{} + +// NetworkPolicyNamespaceListerExpansion allows custom methods to be added to +// NetworkPolicyNamespaceLister. +type NetworkPolicyNamespaceListerExpansion interface{} diff --git a/pkg/client/listers/networking/internalversion/networkpolicy.go b/pkg/client/listers/networking/internalversion/networkpolicy.go new file mode 100644 index 0000000000000..3b7a618e398de --- /dev/null +++ b/pkg/client/listers/networking/internalversion/networkpolicy.go @@ -0,0 +1,94 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package internalversion + +import ( + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/client-go/tools/cache" + networking "k8s.io/kubernetes/pkg/apis/networking" +) + +// NetworkPolicyLister helps list NetworkPolicies. +type NetworkPolicyLister interface { + // List lists all NetworkPolicies in the indexer. + List(selector labels.Selector) (ret []*networking.NetworkPolicy, err error) + // NetworkPolicies returns an object that can list and get NetworkPolicies. + NetworkPolicies(namespace string) NetworkPolicyNamespaceLister + NetworkPolicyListerExpansion +} + +// networkPolicyLister implements the NetworkPolicyLister interface. +type networkPolicyLister struct { + indexer cache.Indexer +} + +// NewNetworkPolicyLister returns a new NetworkPolicyLister. +func NewNetworkPolicyLister(indexer cache.Indexer) NetworkPolicyLister { + return &networkPolicyLister{indexer: indexer} +} + +// List lists all NetworkPolicies in the indexer. +func (s *networkPolicyLister) List(selector labels.Selector) (ret []*networking.NetworkPolicy, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*networking.NetworkPolicy)) + }) + return ret, err +} + +// NetworkPolicies returns an object that can list and get NetworkPolicies. +func (s *networkPolicyLister) NetworkPolicies(namespace string) NetworkPolicyNamespaceLister { + return networkPolicyNamespaceLister{indexer: s.indexer, namespace: namespace} +} + +// NetworkPolicyNamespaceLister helps list and get NetworkPolicies. +type NetworkPolicyNamespaceLister interface { + // List lists all NetworkPolicies in the indexer for a given namespace. + List(selector labels.Selector) (ret []*networking.NetworkPolicy, err error) + // Get retrieves the NetworkPolicy from the indexer for a given namespace and name. + Get(name string) (*networking.NetworkPolicy, error) + NetworkPolicyNamespaceListerExpansion +} + +// networkPolicyNamespaceLister implements the NetworkPolicyNamespaceLister +// interface. +type networkPolicyNamespaceLister struct { + indexer cache.Indexer + namespace string +} + +// List lists all NetworkPolicies in the indexer for a given namespace. +func (s networkPolicyNamespaceLister) List(selector labels.Selector) (ret []*networking.NetworkPolicy, err error) { + err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { + ret = append(ret, m.(*networking.NetworkPolicy)) + }) + return ret, err +} + +// Get retrieves the NetworkPolicy from the indexer for a given namespace and name. +func (s networkPolicyNamespaceLister) Get(name string) (*networking.NetworkPolicy, error) { + obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(networking.Resource("networkpolicy"), name) + } + return obj.(*networking.NetworkPolicy), nil +} diff --git a/pkg/client/listers/networking/v1/BUILD b/pkg/client/listers/networking/v1/BUILD new file mode 100644 index 0000000000000..e6bb81356f6c3 --- /dev/null +++ b/pkg/client/listers/networking/v1/BUILD @@ -0,0 +1,36 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "expansion_generated.go", + "networkpolicy.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/networking/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/client/listers/networking/v1/expansion_generated.go b/pkg/client/listers/networking/v1/expansion_generated.go new file mode 100644 index 0000000000000..91fe5e772f8c2 --- /dev/null +++ b/pkg/client/listers/networking/v1/expansion_generated.go @@ -0,0 +1,27 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package v1 + +// NetworkPolicyListerExpansion allows custom methods to be added to +// NetworkPolicyLister. +type NetworkPolicyListerExpansion interface{} + +// NetworkPolicyNamespaceListerExpansion allows custom methods to be added to +// NetworkPolicyNamespaceLister. +type NetworkPolicyNamespaceListerExpansion interface{} diff --git a/pkg/client/listers/networking/v1/networkpolicy.go b/pkg/client/listers/networking/v1/networkpolicy.go new file mode 100644 index 0000000000000..da78889d4a51f --- /dev/null +++ b/pkg/client/listers/networking/v1/networkpolicy.go @@ -0,0 +1,94 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package v1 + +import ( + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/client-go/tools/cache" + v1 "k8s.io/kubernetes/pkg/apis/networking/v1" +) + +// NetworkPolicyLister helps list NetworkPolicies. +type NetworkPolicyLister interface { + // List lists all NetworkPolicies in the indexer. + List(selector labels.Selector) (ret []*v1.NetworkPolicy, err error) + // NetworkPolicies returns an object that can list and get NetworkPolicies. + NetworkPolicies(namespace string) NetworkPolicyNamespaceLister + NetworkPolicyListerExpansion +} + +// networkPolicyLister implements the NetworkPolicyLister interface. +type networkPolicyLister struct { + indexer cache.Indexer +} + +// NewNetworkPolicyLister returns a new NetworkPolicyLister. +func NewNetworkPolicyLister(indexer cache.Indexer) NetworkPolicyLister { + return &networkPolicyLister{indexer: indexer} +} + +// List lists all NetworkPolicies in the indexer. +func (s *networkPolicyLister) List(selector labels.Selector) (ret []*v1.NetworkPolicy, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*v1.NetworkPolicy)) + }) + return ret, err +} + +// NetworkPolicies returns an object that can list and get NetworkPolicies. +func (s *networkPolicyLister) NetworkPolicies(namespace string) NetworkPolicyNamespaceLister { + return networkPolicyNamespaceLister{indexer: s.indexer, namespace: namespace} +} + +// NetworkPolicyNamespaceLister helps list and get NetworkPolicies. +type NetworkPolicyNamespaceLister interface { + // List lists all NetworkPolicies in the indexer for a given namespace. + List(selector labels.Selector) (ret []*v1.NetworkPolicy, err error) + // Get retrieves the NetworkPolicy from the indexer for a given namespace and name. + Get(name string) (*v1.NetworkPolicy, error) + NetworkPolicyNamespaceListerExpansion +} + +// networkPolicyNamespaceLister implements the NetworkPolicyNamespaceLister +// interface. +type networkPolicyNamespaceLister struct { + indexer cache.Indexer + namespace string +} + +// List lists all NetworkPolicies in the indexer for a given namespace. +func (s networkPolicyNamespaceLister) List(selector labels.Selector) (ret []*v1.NetworkPolicy, err error) { + err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { + ret = append(ret, m.(*v1.NetworkPolicy)) + }) + return ret, err +} + +// Get retrieves the NetworkPolicy from the indexer for a given namespace and name. +func (s networkPolicyNamespaceLister) Get(name string) (*v1.NetworkPolicy, error) { + obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(v1.Resource("networkpolicy"), name) + } + return obj.(*v1.NetworkPolicy), nil +} diff --git a/pkg/cloudprovider/providers/aws/aws.go b/pkg/cloudprovider/providers/aws/aws.go index 7c5cac8d3521a..977a81394abcd 100644 --- a/pkg/cloudprovider/providers/aws/aws.go +++ b/pkg/cloudprovider/providers/aws/aws.go @@ -1522,6 +1522,28 @@ func (c *Cloud) getAwsInstance(nodeName types.NodeName) (*awsInstance, error) { return awsInstance, nil } +// wrapAttachError wraps the error returned by an AttachVolume request with +// additional information, if needed and possible. +func wrapAttachError(err error, disk *awsDisk, instance string) error { + if awsError, ok := err.(awserr.Error); ok { + if awsError.Code() == "VolumeInUse" { + info, err := disk.describeVolume() + if err != nil { + glog.Errorf("Error describing volume %q: %v", disk.awsID, err) + } else { + for _, a := range info.Attachments { + if disk.awsID != awsVolumeID(aws.StringValue(a.VolumeId)) { + glog.Warningf("Expected to get attachment info of volume %q but instead got info of %q", disk.awsID, aws.StringValue(a.VolumeId)) + } else if aws.StringValue(a.State) == "attached" { + return fmt.Errorf("Error attaching EBS volume %q to instance %q: %v. The volume is currently attached to instance %q", disk.awsID, instance, awsError, aws.StringValue(a.InstanceId)) + } + } + } + } + } + return fmt.Errorf("Error attaching EBS volume %q to instance %q: %v", disk.awsID, instance, err) +} + // AttachDisk implements Volumes.AttachDisk func (c *Cloud) AttachDisk(diskName KubernetesVolumeID, nodeName types.NodeName, readOnly bool) (string, error) { disk, err := newAWSDisk(c, diskName) @@ -1578,7 +1600,7 @@ func (c *Cloud) AttachDisk(diskName KubernetesVolumeID, nodeName types.NodeName, if err != nil { attachEnded = true // TODO: Check if the volume was concurrently attached? - return "", fmt.Errorf("Error attaching EBS volume %q to instance %q: %v", disk.awsID, awsInstance.awsID, err) + return "", wrapAttachError(err, disk, awsInstance.awsID) } if da, ok := c.deviceAllocators[awsInstance.nodeName]; ok { da.Deprioritize(mountDevice) @@ -2599,7 +2621,7 @@ func (c *Cloud) EnsureLoadBalancer(clusterName string, apiService *v1.Service, n return nil, fmt.Errorf("LoadBalancerIP cannot be specified for AWS ELB") } - instances, err := c.getInstancesByNodeNamesCached(nodeNames(nodes)) + instances, err := c.getInstancesByNodeNamesCached(nodeNames(nodes), "running") if err != nil { return nil, err } @@ -2804,9 +2826,28 @@ func (c *Cloud) EnsureLoadBalancer(clusterName string, apiService *v1.Service, n return nil, err } - err = c.ensureLoadBalancerHealthCheck(loadBalancer, listeners) - if err != nil { - return nil, err + if path, healthCheckNodePort := service.GetServiceHealthCheckPathPort(apiService); path != "" { + glog.V(4).Infof("service %v (%v) needs health checks on :%d%s)", apiService.Name, loadBalancerName, healthCheckNodePort, path) + err = c.ensureLoadBalancerHealthCheck(loadBalancer, "HTTP", healthCheckNodePort, path) + if err != nil { + return nil, fmt.Errorf("Failed to ensure health check for localized service %v on node port %v: %v", loadBalancerName, healthCheckNodePort, err) + } + } else { + glog.V(4).Infof("service %v does not need custom health checks", apiService.Name) + // We only configure a TCP health-check on the first port + var tcpHealthCheckPort int32 + for _, listener := range listeners { + if listener.InstancePort == nil { + continue + } + tcpHealthCheckPort = int32(*listener.InstancePort) + break + } + // there must be no path on TCP health check + err = c.ensureLoadBalancerHealthCheck(loadBalancer, "TCP", tcpHealthCheckPort, "") + if err != nil { + return nil, err + } } err = c.updateInstanceSecurityGroupsForLoadBalancer(loadBalancer, instances) @@ -3157,7 +3198,7 @@ func (c *Cloud) EnsureLoadBalancerDeleted(clusterName string, service *v1.Servic // UpdateLoadBalancer implements LoadBalancer.UpdateLoadBalancer func (c *Cloud) UpdateLoadBalancer(clusterName string, service *v1.Service, nodes []*v1.Node) error { - instances, err := c.getInstancesByNodeNamesCached(nodeNames(nodes)) + instances, err := c.getInstancesByNodeNamesCached(nodeNames(nodes), "running") if err != nil { return err } @@ -3229,10 +3270,11 @@ func (c *Cloud) getInstancesByIDs(instanceIDs []*string) (map[string]*ec2.Instan return instancesByID, nil } -// Fetches and caches instances by node names; returns an error if any cannot be found. +// Fetches and caches instances in the given state, by node names; returns an error if any cannot be found. If no states +// are given, no state filter is used and instances of all states are fetched. // This is implemented with a multi value filter on the node names, fetching the desired instances with a single query. // TODO(therc): make all the caching more rational during the 1.4 timeframe -func (c *Cloud) getInstancesByNodeNamesCached(nodeNames sets.String) ([]*ec2.Instance, error) { +func (c *Cloud) getInstancesByNodeNamesCached(nodeNames sets.String, states ...string) ([]*ec2.Instance, error) { c.mutex.Lock() defer c.mutex.Unlock() if nodeNames.Equal(c.lastNodeNames) { @@ -3243,7 +3285,7 @@ func (c *Cloud) getInstancesByNodeNamesCached(nodeNames sets.String) ([]*ec2.Ins return c.lastInstancesByNodeNames, nil } } - instances, err := c.getInstancesByNodeNames(nodeNames.List()) + instances, err := c.getInstancesByNodeNames(nodeNames.List(), states...) if err != nil { return nil, err @@ -3259,7 +3301,7 @@ func (c *Cloud) getInstancesByNodeNamesCached(nodeNames sets.String) ([]*ec2.Ins return instances, nil } -func (c *Cloud) getInstancesByNodeNames(nodeNames []string) ([]*ec2.Instance, error) { +func (c *Cloud) getInstancesByNodeNames(nodeNames []string, states ...string) ([]*ec2.Instance, error) { names := aws.StringSlice(nodeNames) nodeNameFilter := &ec2.Filter{ @@ -3267,9 +3309,9 @@ func (c *Cloud) getInstancesByNodeNames(nodeNames []string) ([]*ec2.Instance, er Values: names, } - filters := []*ec2.Filter{ - nodeNameFilter, - newEc2Filter("instance-state-name", "running"), + filters := []*ec2.Filter{nodeNameFilter} + if len(states) > 0 { + filters = append(filters, newEc2Filter("instance-state-name", states...)) } instances, err := c.describeInstances(filters) diff --git a/pkg/cloudprovider/providers/aws/aws_loadbalancer.go b/pkg/cloudprovider/providers/aws/aws_loadbalancer.go index df0eb7bb6321a..c4409740f827c 100644 --- a/pkg/cloudprovider/providers/aws/aws_loadbalancer.go +++ b/pkg/cloudprovider/providers/aws/aws_loadbalancer.go @@ -355,8 +355,8 @@ func (c *Cloud) ensureLoadBalancer(namespacedName types.NamespacedName, loadBala return loadBalancer, nil } -// Makes sure that the health check for an ELB matches the configured listeners -func (c *Cloud) ensureLoadBalancerHealthCheck(loadBalancer *elb.LoadBalancerDescription, listeners []*elb.Listener) error { +// Makes sure that the health check for an ELB matches the configured health check node port +func (c *Cloud) ensureLoadBalancerHealthCheck(loadBalancer *elb.LoadBalancerDescription, protocol string, port int32, path string) error { name := aws.StringValue(loadBalancer.LoadBalancerName) actual := loadBalancer.HealthCheck @@ -367,19 +367,7 @@ func (c *Cloud) ensureLoadBalancerHealthCheck(loadBalancer *elb.LoadBalancerDesc expectedTimeout := int64(5) expectedInterval := int64(10) - // We only configure a TCP health-check on the first port - expectedTarget := "" - for _, listener := range listeners { - if listener.InstancePort == nil { - continue - } - expectedTarget = "TCP:" + strconv.FormatInt(*listener.InstancePort, 10) - break - } - - if expectedTarget == "" { - return fmt.Errorf("unable to determine health check port for %q (no valid listeners)", name) - } + expectedTarget := protocol + ":" + strconv.FormatInt(int64(port), 10) + path if expectedTarget == orEmpty(actual.Target) && expectedHealthyThreshold == orZero(actual.HealthyThreshold) && diff --git a/pkg/cloudprovider/providers/aws/aws_test.go b/pkg/cloudprovider/providers/aws/aws_test.go index ff45d40371014..9d059dbdb1679 100644 --- a/pkg/cloudprovider/providers/aws/aws_test.go +++ b/pkg/cloudprovider/providers/aws/aws_test.go @@ -1050,7 +1050,7 @@ func TestFindInstancesByNodeNameCached(t *testing.T) { } nodeNames := sets.NewString(nodeNameOne) - returnedInstances, errr := c.getInstancesByNodeNamesCached(nodeNames) + returnedInstances, errr := c.getInstancesByNodeNamesCached(nodeNames, "running") if errr != nil { t.Errorf("Failed to find instance: %v", err) diff --git a/pkg/cloudprovider/providers/aws/tags.go b/pkg/cloudprovider/providers/aws/tags.go index 33c2719e99319..ef89d17266bad 100644 --- a/pkg/cloudprovider/providers/aws/tags.go +++ b/pkg/cloudprovider/providers/aws/tags.go @@ -174,7 +174,11 @@ func (c *awsTagging) readRepairClusterTags(client EC2, resourceID string, lifecy } } - if err := c.createTags(client, resourceID, lifecycle, additionalTags); err != nil { + if len(addTags) == 0 { + return nil + } + + if err := c.createTags(client, resourceID, lifecycle, addTags); err != nil { return fmt.Errorf("error adding missing tags to resource %q: %v", resourceID, err) } diff --git a/pkg/cloudprovider/providers/gce/BUILD b/pkg/cloudprovider/providers/gce/BUILD index ea1367033e005..beee30431bb03 100644 --- a/pkg/cloudprovider/providers/gce/BUILD +++ b/pkg/cloudprovider/providers/gce/BUILD @@ -41,7 +41,9 @@ go_library( "//pkg/client/clientset_generated/clientset:go_default_library", "//pkg/cloudprovider:go_default_library", "//pkg/controller:go_default_library", + "//pkg/master/ports:go_default_library", "//pkg/util/net/sets:go_default_library", + "//pkg/util/version:go_default_library", "//pkg/volume:go_default_library", "//vendor/cloud.google.com/go/compute/metadata:go_default_library", "//vendor/github.com/golang/glog:go_default_library", @@ -68,9 +70,20 @@ go_library( go_test( name = "go_default_test", - srcs = ["gce_test.go"], + srcs = [ + "gce_disks_test.go", + "gce_healthchecks_test.go", + "gce_test.go", + ], library = ":go_default_library", tags = ["automanaged"], + deps = [ + "//pkg/api/v1:go_default_library", + "//pkg/cloudprovider:go_default_library", + "//vendor/google.golang.org/api/compute/v1:go_default_library", + "//vendor/google.golang.org/api/googleapi:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + ], ) filegroup( diff --git a/pkg/cloudprovider/providers/gce/OWNERS b/pkg/cloudprovider/providers/gce/OWNERS index 8b6b599964a31..2941ce492b5e1 100644 --- a/pkg/cloudprovider/providers/gce/OWNERS +++ b/pkg/cloudprovider/providers/gce/OWNERS @@ -2,3 +2,7 @@ approvers: - saad-ali - jingxu97 - bowei +- freehan +- nicksardo +- mrhohn +- dnardo diff --git a/pkg/cloudprovider/providers/gce/gce.go b/pkg/cloudprovider/providers/gce/gce.go index 64004fa94400f..5cb2d7bf447d6 100644 --- a/pkg/cloudprovider/providers/gce/gce.go +++ b/pkg/cloudprovider/providers/gce/gce.go @@ -22,12 +22,14 @@ import ( "net/http" "regexp" "strings" + "sync" "time" "cloud.google.com/go/compute/metadata" "gopkg.in/gcfg.v1" + "k8s.io/apimachinery/pkg/util/sets" "k8s.io/apimachinery/pkg/util/wait" "k8s.io/client-go/util/flowcontrol" "k8s.io/kubernetes/pkg/cloudprovider" @@ -76,21 +78,51 @@ const ( // GCECloud is an implementation of Interface, LoadBalancer and Instances for Google Compute Engine. type GCECloud struct { + ClusterID ClusterID + service *compute.Service serviceBeta *computebeta.Service containerService *container.Service clientBuilder controller.ControllerClientBuilder - ClusterId ClusterId projectID string region string localZone string // The zone in which we are running managedZones []string // List of zones we are spanning (for multi-AZ clusters, primarily when running on master) networkURL string subnetworkURL string - nodeTags []string // List of tags to use on firewall rules for load balancers - nodeInstancePrefix string // If non-"", an advisory prefix for all nodes in the cluster + networkProjectID string + onXPN bool + nodeTags []string // List of tags to use on firewall rules for load balancers + lastComputedNodeTags []string // List of node tags calculated in GetHostTags() + lastKnownNodeNames sets.String // List of hostnames used to calculate lastComputedHostTags in GetHostTags(names) + computeNodeTagLock sync.Mutex // Lock for computing and setting node tags + nodeInstancePrefix string // If non-"", an advisory prefix for all nodes in the cluster useMetadataServer bool operationPollRateLimiter flowcontrol.RateLimiter + manager ServiceManager + // sharedResourceLock is used to serialize GCE operations that may mutate shared state to + // prevent inconsistencies. For example, load balancers manipulation methods will take the + // lock to prevent shared resources from being prematurely deleted while the operation is + // in progress. + sharedResourceLock sync.Mutex +} + +type ServiceManager interface { + // Creates a new persistent disk on GCE with the given disk spec. + CreateDisk(project string, zone string, disk *compute.Disk) (*compute.Operation, error) + + // Gets the persistent disk from GCE with the given diskName. + GetDisk(project string, zone string, diskName string) (*compute.Disk, error) + + // Deletes the persistent disk from GCE with the given diskName. + DeleteDisk(project string, zone string, disk string) (*compute.Operation, error) + + // Waits until GCE reports the given operation in the given zone as done. + WaitForZoneOp(op *compute.Operation, zone string, mc *metricContext) error +} + +type GCEServiceManager struct { + gce *GCECloud } type Config struct { @@ -218,6 +250,12 @@ func CreateGCECloud(projectID, region, zone string, managedZones []string, netwo networkURL = gceNetworkURL(projectID, networkName) } + networkProjectID, err := getProjectIDInURL(networkURL) + if err != nil { + return nil, err + } + onXPN := networkProjectID != projectID + if len(managedZones) == 0 { managedZones, err = getZonesForRegion(service, projectID, region) if err != nil { @@ -230,11 +268,13 @@ func CreateGCECloud(projectID, region, zone string, managedZones []string, netwo operationPollRateLimiter := flowcontrol.NewTokenBucketRateLimiter(10, 100) // 10 qps, 100 bucket size. - return &GCECloud{ + gce := &GCECloud{ service: service, serviceBeta: serviceBeta, containerService: containerService, projectID: projectID, + networkProjectID: networkProjectID, + onXPN: onXPN, region: region, localZone: zone, managedZones: managedZones, @@ -244,14 +284,17 @@ func CreateGCECloud(projectID, region, zone string, managedZones []string, netwo nodeInstancePrefix: nodeInstancePrefix, useMetadataServer: useMetadataServer, operationPollRateLimiter: operationPollRateLimiter, - }, nil + } + + gce.manager = &GCEServiceManager{gce} + return gce, nil } // Initialize takes in a clientBuilder and spawns a goroutine for watching the clusterid configmap. -// This must be called before utilizing the funcs of gce.ClusterId +// This must be called before utilizing the funcs of gce.ClusterID func (gce *GCECloud) Initialize(clientBuilder controller.ControllerClientBuilder) { gce.clientBuilder = clientBuilder - go gce.watchClusterId() + go gce.watchClusterID() } // LoadBalancer returns an implementation of LoadBalancer for Google Compute Engine. @@ -283,6 +326,26 @@ func (gce *GCECloud) ProviderName() string { return ProviderName } +// Region returns the region +func (gce *GCECloud) Region() string { + return gce.region +} + +// OnXPN returns true if the cluster is running on a cross project network (XPN) +func (gce *GCECloud) OnXPN() bool { + return gce.onXPN +} + +// NetworkURL returns the network url +func (gce *GCECloud) NetworkURL() string { + return gce.networkURL +} + +// SubnetworkURL returns the subnetwork url +func (gce *GCECloud) SubnetworkURL() string { + return gce.subnetworkURL +} + // Known-useless DNS search path. var uselessDNSSearchRE = regexp.MustCompile(`^[0-9]+.google.internal.$`) @@ -308,6 +371,20 @@ func gceSubnetworkURL(project, region, subnetwork string) string { return fmt.Sprintf("https://www.googleapis.com/compute/v1/projects/%s/regions/%s/subnetworks/%s", project, region, subnetwork) } +// getProjectIDInURL parses typical full resource URLS and shorter URLS +// https://www.googleapis.com/compute/v1/projects/myproject/global/networks/mycustom +// projects/myproject/global/networks/mycustom +// All return "myproject" +func getProjectIDInURL(urlStr string) (string, error) { + fields := strings.Split(urlStr, "/") + for i, v := range fields { + if v == "projects" && i < len(fields)-1 { + return fields[i+1], nil + } + } + return "", fmt.Errorf("could not find project field in url: %v", urlStr) +} + func getNetworkNameViaMetadata() (string, error) { result, err := metadata.Get("instance/network-interfaces/0/network") if err != nil { @@ -383,3 +460,31 @@ func newOauthClient(tokenSource oauth2.TokenSource) (*http.Client, error) { return oauth2.NewClient(oauth2.NoContext, tokenSource), nil } + +func (manager *GCEServiceManager) CreateDisk( + project string, + zone string, + disk *compute.Disk) (*compute.Operation, error) { + + return manager.gce.service.Disks.Insert(project, zone, disk).Do() +} + +func (manager *GCEServiceManager) GetDisk( + project string, + zone string, + diskName string) (*compute.Disk, error) { + + return manager.gce.service.Disks.Get(project, zone, diskName).Do() +} + +func (manager *GCEServiceManager) DeleteDisk( + project string, + zone string, + diskName string) (*compute.Operation, error) { + + return manager.gce.service.Disks.Delete(project, zone, diskName).Do() +} + +func (manager *GCEServiceManager) WaitForZoneOp(op *compute.Operation, zone string, mc *metricContext) error { + return manager.gce.waitForZoneOp(op, zone, mc) +} diff --git a/pkg/cloudprovider/providers/gce/gce_backendservice.go b/pkg/cloudprovider/providers/gce/gce_backendservice.go index 02b20e8ede962..1d79dfde0d3fb 100644 --- a/pkg/cloudprovider/providers/gce/gce_backendservice.go +++ b/pkg/cloudprovider/providers/gce/gce_backendservice.go @@ -30,15 +30,15 @@ func newBackendServiceMetricContext(request string) *metricContext { } } -// GetBackendService retrieves a backend by name. -func (gce *GCECloud) GetBackendService(name string) (*compute.BackendService, error) { +// GetGlobalBackendService retrieves a backend by name. +func (gce *GCECloud) GetGlobalBackendService(name string) (*compute.BackendService, error) { mc := newBackendServiceMetricContext("get") v, err := gce.service.BackendServices.Get(gce.projectID, name).Do() return v, mc.Observe(err) } -// UpdateBackendService applies the given BackendService as an update to an existing service. -func (gce *GCECloud) UpdateBackendService(bg *compute.BackendService) error { +// UpdateGlobalBackendService applies the given BackendService as an update to an existing service. +func (gce *GCECloud) UpdateGlobalBackendService(bg *compute.BackendService) error { mc := newBackendServiceMetricContext("update") op, err := gce.service.BackendServices.Update(gce.projectID, bg.Name, bg).Do() if err != nil { @@ -48,8 +48,8 @@ func (gce *GCECloud) UpdateBackendService(bg *compute.BackendService) error { return gce.waitForGlobalOp(op, mc) } -// DeleteBackendService deletes the given BackendService by name. -func (gce *GCECloud) DeleteBackendService(name string) error { +// DeleteGlobalBackendService deletes the given BackendService by name. +func (gce *GCECloud) DeleteGlobalBackendService(name string) error { mc := newBackendServiceMetricContext("delete") op, err := gce.service.BackendServices.Delete(gce.projectID, name).Do() if err != nil { @@ -62,8 +62,8 @@ func (gce *GCECloud) DeleteBackendService(name string) error { return gce.waitForGlobalOp(op, mc) } -// CreateBackendService creates the given BackendService. -func (gce *GCECloud) CreateBackendService(bg *compute.BackendService) error { +// CreateGlobalBackendService creates the given BackendService. +func (gce *GCECloud) CreateGlobalBackendService(bg *compute.BackendService) error { mc := newBackendServiceMetricContext("create") op, err := gce.service.BackendServices.Insert(gce.projectID, bg).Do() if err != nil { @@ -73,16 +73,81 @@ func (gce *GCECloud) CreateBackendService(bg *compute.BackendService) error { return gce.waitForGlobalOp(op, mc) } -// ListBackendServices lists all backend services in the project. -func (gce *GCECloud) ListBackendServices() (*compute.BackendServiceList, error) { +// ListGlobalBackendServices lists all backend services in the project. +func (gce *GCECloud) ListGlobalBackendServices() (*compute.BackendServiceList, error) { + mc := newBackendServiceMetricContext("list") // TODO: use PageToken to list all not just the first 500 - return gce.service.BackendServices.List(gce.projectID).Do() + v, err := gce.service.BackendServices.List(gce.projectID).Do() + return v, mc.Observe(err) +} + +// GetGlobalBackendServiceHealth returns the health of the BackendService identified by the given +// name, in the given instanceGroup. The instanceGroupLink is the fully +// qualified self link of an instance group. +func (gce *GCECloud) GetGlobalBackendServiceHealth(name string, instanceGroupLink string) (*compute.BackendServiceGroupHealth, error) { + mc := newBackendServiceMetricContext("get_health") + groupRef := &compute.ResourceGroupReference{Group: instanceGroupLink} + v, err := gce.service.BackendServices.GetHealth(gce.projectID, name, groupRef).Do() + return v, mc.Observe(err) +} + +// GetRegionBackendService retrieves a backend by name. +func (gce *GCECloud) GetRegionBackendService(name, region string) (*compute.BackendService, error) { + mc := newBackendServiceMetricContext("get") + v, err := gce.service.RegionBackendServices.Get(gce.projectID, region, name).Do() + return v, mc.Observe(err) +} + +// UpdateRegionBackendService applies the given BackendService as an update to an existing service. +func (gce *GCECloud) UpdateRegionBackendService(bg *compute.BackendService) error { + mc := newBackendServiceMetricContext("update") + op, err := gce.service.RegionBackendServices.Update(gce.projectID, bg.Region, bg.Name, bg).Do() + if err != nil { + return mc.Observe(err) + } + + return gce.waitForRegionOp(op, bg.Region, mc) +} + +// DeleteRegionBackendService deletes the given BackendService by name. +func (gce *GCECloud) DeleteRegionBackendService(name, region string) error { + mc := newBackendServiceMetricContext("delete") + op, err := gce.service.RegionBackendServices.Delete(gce.projectID, region, name).Do() + if err != nil { + if isHTTPErrorCode(err, http.StatusNotFound) { + return nil + } + return mc.Observe(err) + } + + return gce.waitForRegionOp(op, region, mc) +} + +// CreateRegionBackendService creates the given BackendService. +func (gce *GCECloud) CreateRegionBackendService(bg *compute.BackendService) error { + mc := newBackendServiceMetricContext("create") + op, err := gce.service.RegionBackendServices.Insert(gce.projectID, bg.Region, bg).Do() + if err != nil { + return mc.Observe(err) + } + + return gce.waitForRegionOp(op, bg.Region, mc) } -// GetHealth returns the health of the BackendService identified by the given +// ListRegionBackendServices lists all backend services in the project. +func (gce *GCECloud) ListRegionBackendServices(region string) (*compute.BackendServiceList, error) { + mc := newBackendServiceMetricContext("list") + // TODO: use PageToken to list all not just the first 500 + v, err := gce.service.RegionBackendServices.List(gce.projectID, region).Do() + return v, mc.Observe(err) +} + +// GetRegionalBackendServiceHealth returns the health of the BackendService identified by the given // name, in the given instanceGroup. The instanceGroupLink is the fully // qualified self link of an instance group. -func (gce *GCECloud) GetHealth(name string, instanceGroupLink string) (*compute.BackendServiceGroupHealth, error) { +func (gce *GCECloud) GetRegionalBackendServiceHealth(name, region string, instanceGroupLink string) (*compute.BackendServiceGroupHealth, error) { + mc := newBackendServiceMetricContext("get_health") groupRef := &compute.ResourceGroupReference{Group: instanceGroupLink} - return gce.service.BackendServices.GetHealth(gce.projectID, name, groupRef).Do() + v, err := gce.service.RegionBackendServices.GetHealth(gce.projectID, region, name, groupRef).Do() + return v, mc.Observe(err) } diff --git a/pkg/cloudprovider/providers/gce/gce_clusterid.go b/pkg/cloudprovider/providers/gce/gce_clusterid.go index 21e533cb17b6f..621e927670afc 100644 --- a/pkg/cloudprovider/providers/gce/gce_clusterid.go +++ b/pkg/cloudprovider/providers/gce/gce_clusterid.go @@ -1,5 +1,5 @@ /* -Copyright 2014 The Kubernetes Authors. +Copyright 2017 The Kubernetes Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -49,18 +49,18 @@ const ( updateFuncFrequency = 10 * time.Minute ) -type ClusterId struct { +type ClusterID struct { idLock sync.RWMutex client clientset.Interface cfgMapKey string store cache.Store - providerId *string - clusterId *string + providerID *string + clusterID *string } -// Continually watches for changes to the cluser id config map -func (gce *GCECloud) watchClusterId() { - gce.ClusterId = ClusterId{ +// Continually watches for changes to the cluster id config map +func (gce *GCECloud) watchClusterID() { + gce.ClusterID = ClusterID{ cfgMapKey: fmt.Sprintf("%v/%v", UIDNamespace, UIDConfigMapName), client: gce.clientBuilder.ClientOrDie("cloud-provider"), } @@ -77,8 +77,8 @@ func (gce *GCECloud) watchClusterId() { return } - glog.V(4).Infof("Observed new configmap for clusterid: %v, %v; setting local values", m.Name, m.Data) - gce.ClusterId.setIds(m) + glog.V(4).Infof("Observed new configmap for clusteriD: %v, %v; setting local values", m.Name, m.Data) + gce.ClusterID.update(m) }, UpdateFunc: func(old, cur interface{}) { m, ok := cur.(*v1.ConfigMap) @@ -96,71 +96,71 @@ func (gce *GCECloud) watchClusterId() { return } - glog.V(4).Infof("Observed updated configmap for clusterid %v, %v; setting local values", m.Name, m.Data) - gce.ClusterId.setIds(m) + glog.V(4).Infof("Observed updated configmap for clusteriD %v, %v; setting local values", m.Name, m.Data) + gce.ClusterID.update(m) }, } - listerWatcher := cache.NewListWatchFromClient(gce.ClusterId.client.Core().RESTClient(), "configmaps", UIDNamespace, fields.Everything()) + listerWatcher := cache.NewListWatchFromClient(gce.ClusterID.client.Core().RESTClient(), "configmaps", UIDNamespace, fields.Everything()) var controller cache.Controller - gce.ClusterId.store, controller = cache.NewInformer(newSingleObjectListerWatcher(listerWatcher, UIDConfigMapName), &v1.ConfigMap{}, updateFuncFrequency, mapEventHandler) + gce.ClusterID.store, controller = cache.NewInformer(newSingleObjectListerWatcher(listerWatcher, UIDConfigMapName), &v1.ConfigMap{}, updateFuncFrequency, mapEventHandler) controller.Run(nil) } -// GetId returns the id which is unique to this cluster +// GetID returns the id which is unique to this cluster // if federated, return the provider id (unique to the cluster) // if not federated, return the cluster id -func (ci *ClusterId) GetId() (string, error) { +func (ci *ClusterID) GetID() (string, error) { if err := ci.getOrInitialize(); err != nil { return "", err } ci.idLock.RLock() defer ci.idLock.RUnlock() - if ci.clusterId == nil { + if ci.clusterID == nil { return "", errors.New("Could not retrieve cluster id") } // If provider ID is set, (Federation is enabled) use this field - if ci.providerId != nil && *ci.providerId != *ci.clusterId { - return *ci.providerId, nil + if ci.providerID != nil { + return *ci.providerID, nil } - // providerId is not set, use the cluster id - return *ci.clusterId, nil + // providerID is not set, use the cluster id + return *ci.clusterID, nil } // GetFederationId returns the id which could represent the entire Federation // or just the cluster if not federated. -func (ci *ClusterId) GetFederationId() (string, bool, error) { +func (ci *ClusterID) GetFederationId() (string, bool, error) { if err := ci.getOrInitialize(); err != nil { return "", false, err } ci.idLock.RLock() defer ci.idLock.RUnlock() - if ci.clusterId == nil { + if ci.clusterID == nil { return "", false, errors.New("Could not retrieve cluster id") } // If provider ID is not set, return false - if ci.providerId == nil || *ci.clusterId == *ci.providerId { + if ci.providerID == nil || *ci.clusterID == *ci.providerID { return "", false, nil } - return *ci.clusterId, true, nil + return *ci.clusterID, true, nil } // getOrInitialize either grabs the configmaps current value or defines the value -// and sets the configmap. This is for the case of the user calling GetClusterId() +// and sets the configmap. This is for the case of the user calling GetClusterID() // before the watch has begun. -func (ci *ClusterId) getOrInitialize() error { +func (ci *ClusterID) getOrInitialize() error { if ci.store == nil { - return errors.New("GCECloud.ClusterId is not ready. Call Initialize() before using.") + return errors.New("GCECloud.ClusterID is not ready. Call Initialize() before using.") } - if ci.clusterId != nil { + if ci.clusterID != nil { return nil } @@ -177,7 +177,7 @@ func (ci *ClusterId) getOrInitialize() error { return err } - glog.V(4).Infof("Creating clusterid: %v", newId) + glog.V(4).Infof("Creating clusteriD: %v", newId) cfg := &v1.ConfigMap{ ObjectMeta: metav1.ObjectMeta{ Name: UIDConfigMapName, @@ -194,12 +194,12 @@ func (ci *ClusterId) getOrInitialize() error { return err } - glog.V(2).Infof("Created a config map containing clusterid: %v", newId) - ci.setIds(cfg) + glog.V(2).Infof("Created a config map containing clusteriD: %v", newId) + ci.update(cfg) return nil } -func (ci *ClusterId) getConfigMap() (bool, error) { +func (ci *ClusterID) getConfigMap() (bool, error) { item, exists, err := ci.store.GetByKey(ci.cfgMapKey) if err != nil { return false, err @@ -214,18 +214,18 @@ func (ci *ClusterId) getConfigMap() (bool, error) { glog.Error(err) return false, err } - ci.setIds(m) + ci.update(m) return true, nil } -func (ci *ClusterId) setIds(m *v1.ConfigMap) { +func (ci *ClusterID) update(m *v1.ConfigMap) { ci.idLock.Lock() defer ci.idLock.Unlock() - if clusterId, exists := m.Data[UIDCluster]; exists { - ci.clusterId = &clusterId + if clusterID, exists := m.Data[UIDCluster]; exists { + ci.clusterID = &clusterID } if provId, exists := m.Data[UIDProvider]; exists { - ci.providerId = &provId + ci.providerID = &provId } } diff --git a/pkg/cloudprovider/providers/gce/gce_disks.go b/pkg/cloudprovider/providers/gce/gce_disks.go index fab96f9081e1a..9f0ea55205ea9 100644 --- a/pkg/cloudprovider/providers/gce/gce_disks.go +++ b/pkg/cloudprovider/providers/gce/gce_disks.go @@ -244,7 +244,7 @@ func (gce *GCECloud) CreateDisk( } mc := newDiskMetricContext("create", zone) - createOp, err := gce.service.Disks.Insert(gce.projectID, zone, diskToCreate).Do() + createOp, err := gce.manager.CreateDisk(gce.projectID, zone, diskToCreate) if isGCEError(err, "alreadyExists") { glog.Warningf("GCE PD %q already exists, reusing", name) return nil @@ -252,7 +252,7 @@ func (gce *GCECloud) CreateDisk( return mc.Observe(err) } - err = gce.waitForZoneOp(createOp, zone, mc) + err = gce.manager.WaitForZoneOp(createOp, zone, mc) if isGCEError(err, "alreadyExists") { glog.Warningf("GCE PD %q already exists, reusing", name) return nil @@ -323,7 +323,7 @@ func (gce *GCECloud) GetAutoLabelsForPD(name string, zone string) (map[string]st // If not found, returns (nil, nil) func (gce *GCECloud) findDiskByName(diskName string, zone string) (*GCEDisk, error) { mc := newDiskMetricContext("get", zone) - disk, err := gce.service.Disks.Get(gce.projectID, zone, diskName).Do() + disk, err := gce.manager.GetDisk(gce.projectID, zone, diskName) if err == nil { d := &GCEDisk{ Zone: lastComponent(disk.Zone), @@ -410,12 +410,12 @@ func (gce *GCECloud) doDeleteDisk(diskToDelete string) error { mc := newDiskMetricContext("delete", disk.Zone) - deleteOp, err := gce.service.Disks.Delete(gce.projectID, disk.Zone, disk.Name).Do() + deleteOp, err := gce.manager.DeleteDisk(gce.projectID, disk.Zone, disk.Name) if err != nil { return mc.Observe(err) } - return gce.waitForZoneOp(deleteOp, disk.Zone, mc) + return gce.manager.WaitForZoneOp(deleteOp, disk.Zone, mc) } // Converts a Disk resource to an AttachedDisk resource. diff --git a/pkg/cloudprovider/providers/gce/gce_disks_test.go b/pkg/cloudprovider/providers/gce/gce_disks_test.go new file mode 100644 index 0000000000000..0c27977138a35 --- /dev/null +++ b/pkg/cloudprovider/providers/gce/gce_disks_test.go @@ -0,0 +1,502 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package gce + +import ( + "testing" + + "fmt" + compute "google.golang.org/api/compute/v1" + "google.golang.org/api/googleapi" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/kubernetes/pkg/cloudprovider" +) + +func TestCreateDisk_Basic(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + projectId := "test-project" + gce := GCECloud{ + manager: fakeManager, + managedZones: []string{"zone1"}, + projectID: projectId, + } + + diskName := "disk" + diskType := DiskTypeSSD + zone := "zone1" + const sizeGb int64 = 128 + tags := make(map[string]string) + tags["test-tag"] = "test-value" + + diskTypeUri := fmt.Sprintf(diskTypeUriTemplate, projectId, zone, diskType) + expectedDescription := "{\"test-tag\":\"test-value\"}" + + /* Act */ + err := gce.CreateDisk(diskName, diskType, zone, sizeGb, tags) + + /* Assert */ + if err != nil { + t.Error(err) + } + if !fakeManager.createDiskCalled { + t.Error("Never called GCE disk create.") + } + if !fakeManager.doesOpMatch { + t.Error("Ops used in WaitForZoneOp does not match what's returned by CreateDisk.") + } + + // Partial check of equality between disk description sent to GCE and parameters of method. + diskToCreate := fakeManager.diskToCreate + if diskToCreate.Name != diskName { + t.Errorf("Expected disk name: %s; Actual: %s", diskName, diskToCreate.Name) + } + + if diskToCreate.Type != diskTypeUri { + t.Errorf("Expected disk type: %s; Actual: %s", diskTypeUri, diskToCreate.Type) + } + if diskToCreate.SizeGb != sizeGb { + t.Errorf("Expected disk size: %d; Actual: %d", sizeGb, diskToCreate.SizeGb) + } + if diskToCreate.Description != expectedDescription { + t.Errorf("Expected tag string: %s; Actual: %s", expectedDescription, diskToCreate.Description) + } +} + +func TestCreateDisk_DiskAlreadyExists(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + gce := GCECloud{manager: fakeManager, managedZones: []string{"zone1"}} + + // Inject disk AlreadyExists error. + alreadyExistsError := googleapi.ErrorItem{Reason: "alreadyExists"} + fakeManager.waitForZoneOpError = &googleapi.Error{ + Errors: []googleapi.ErrorItem{alreadyExistsError}, + } + + /* Act */ + err := gce.CreateDisk("disk", DiskTypeSSD, "zone1", 128, nil) + + /* Assert */ + if err != nil { + t.Error( + "Expected success when a disk with the given name already exists, but an error is returned.") + } +} + +func TestCreateDisk_WrongZone(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + gce := GCECloud{manager: fakeManager, managedZones: []string{"zone1"}} + + diskName := "disk" + diskType := DiskTypeSSD + const sizeGb int64 = 128 + + /* Act */ + err := gce.CreateDisk(diskName, diskType, "zone2", sizeGb, nil) + + /* Assert */ + if err == nil { + t.Error("Expected error when zone is not managed, but none returned.") + } +} + +func TestCreateDisk_NoManagedZone(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + gce := GCECloud{manager: fakeManager, managedZones: []string{}} + + diskName := "disk" + diskType := DiskTypeSSD + const sizeGb int64 = 128 + + /* Act */ + err := gce.CreateDisk(diskName, diskType, "zone1", sizeGb, nil) + + /* Assert */ + if err == nil { + t.Error("Expected error when managedZones is empty, but none returned.") + } +} + +func TestCreateDisk_BadDiskType(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + gce := GCECloud{manager: fakeManager, managedZones: []string{"zone1"}} + + diskName := "disk" + diskType := "arbitrary-disk" + zone := "zone1" + const sizeGb int64 = 128 + + /* Act */ + err := gce.CreateDisk(diskName, diskType, zone, sizeGb, nil) + + /* Assert */ + if err == nil { + t.Error("Expected error when disk type is not supported, but none returned.") + } +} + +func TestCreateDisk_MultiZone(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + gce := GCECloud{manager: fakeManager, managedZones: []string{"zone1", "zone2", "zone3"}} + + diskName := "disk" + diskType := DiskTypeStandard + const sizeGb int64 = 128 + + /* Act & Assert */ + for _, zone := range gce.managedZones { + diskName = zone + "disk" + err := gce.CreateDisk(diskName, diskType, zone, sizeGb, nil) + if err != nil { + t.Errorf("Error creating disk in zone '%v'; error: \"%v\"", zone, err) + } + } +} + +func TestDeleteDisk_Basic(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + gce := GCECloud{manager: fakeManager, managedZones: []string{"zone1"}} + diskName := "disk" + diskType := DiskTypeSSD + zone := "zone1" + const sizeGb int64 = 128 + + gce.CreateDisk(diskName, diskType, zone, sizeGb, nil) + + /* Act */ + err := gce.DeleteDisk(diskName) + + /* Assert */ + if err != nil { + t.Error(err) + } + if !fakeManager.deleteDiskCalled { + t.Error("Never called GCE disk delete.") + } + if !fakeManager.doesOpMatch { + t.Error("Ops used in WaitForZoneOp does not match what's returned by DeleteDisk.") + } + +} + +func TestDeleteDisk_NotFound(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + gce := GCECloud{manager: fakeManager, managedZones: []string{"zone1"}} + diskName := "disk" + + /* Act */ + err := gce.DeleteDisk(diskName) + + /* Assert */ + if err != nil { + t.Error("Expected successful operation when disk is not found, but an error is returned.") + } +} + +func TestDeleteDisk_ResourceBeingUsed(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + gce := GCECloud{manager: fakeManager, managedZones: []string{"zone1"}} + diskName := "disk" + diskType := DiskTypeSSD + zone := "zone1" + const sizeGb int64 = 128 + + gce.CreateDisk(diskName, diskType, zone, sizeGb, nil) + fakeManager.resourceInUse = true + + /* Act */ + err := gce.DeleteDisk(diskName) + + /* Assert */ + if err == nil { + t.Error("Expected error when disk is in use, but none returned.") + } +} + +func TestDeleteDisk_SameDiskMultiZone(t *testing.T) { + /* Assert */ + fakeManager := newFakeManager() + gce := GCECloud{manager: fakeManager, managedZones: []string{"zone1", "zone2", "zone3"}} + diskName := "disk" + diskType := DiskTypeSSD + const sizeGb int64 = 128 + + for _, zone := range gce.managedZones { + gce.CreateDisk(diskName, diskType, zone, sizeGb, nil) + } + + /* Act */ + // DeleteDisk will call FakeServiceManager.GetDisk() with all zones, + // and FakeServiceManager.GetDisk() always returns a disk, + // so DeleteDisk thinks a disk with diskName exists in all zones. + err := gce.DeleteDisk(diskName) + + /* Assert */ + if err == nil { + t.Error("Expected error when disk is found in multiple zones, but none returned.") + } +} + +func TestDeleteDisk_DiffDiskMultiZone(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + gce := GCECloud{manager: fakeManager, managedZones: []string{"zone1"}} + diskName := "disk" + diskType := DiskTypeSSD + const sizeGb int64 = 128 + + for _, zone := range gce.managedZones { + diskName = zone + "disk" + gce.CreateDisk(diskName, diskType, zone, sizeGb, nil) + } + + /* Act & Assert */ + var err error + for _, zone := range gce.managedZones { + diskName = zone + "disk" + err = gce.DeleteDisk(diskName) + if err != nil { + t.Errorf("Error deleting disk in zone '%v'; error: \"%v\"", zone, err) + } + } +} + +func TestGetAutoLabelsForPD_Basic(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + diskName := "disk" + diskType := DiskTypeSSD + zone := "us-central1-c" + const sizeGb int64 = 128 + gce := GCECloud{manager: fakeManager, managedZones: []string{zone}} + + gce.CreateDisk(diskName, diskType, zone, sizeGb, nil) + + /* Act */ + labels, err := gce.GetAutoLabelsForPD(diskName, zone) + + /* Assert */ + if err != nil { + t.Error(err) + } + if labels[metav1.LabelZoneFailureDomain] != zone { + t.Errorf("Failure domain is '%v', but zone is '%v'", + labels[metav1.LabelZoneFailureDomain], zone) + } + if labels[metav1.LabelZoneRegion] != "us-central1" { + t.Errorf("Region is '%v', but zone is 'us-central1'", labels[metav1.LabelZoneRegion]) + } +} + +func TestGetAutoLabelsForPD_NoZone(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + diskName := "disk" + diskType := DiskTypeStandard + zone := "europe-west1-d" + const sizeGb int64 = 128 + gce := GCECloud{manager: fakeManager, managedZones: []string{zone}} + gce.CreateDisk(diskName, diskType, zone, sizeGb, nil) + + /* Act */ + labels, err := gce.GetAutoLabelsForPD(diskName, "") + + /* Assert */ + if err != nil { + t.Error(err) + } + if labels[metav1.LabelZoneFailureDomain] != zone { + t.Errorf("Failure domain is '%v', but zone is '%v'", + labels[metav1.LabelZoneFailureDomain], zone) + } + if labels[metav1.LabelZoneRegion] != "europe-west1" { + t.Errorf("Region is '%v', but zone is 'europe-west1'", labels[metav1.LabelZoneRegion]) + } +} + +func TestGetAutoLabelsForPD_DiskNotFound(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + diskName := "disk" + zone := "asia-northeast1-a" + gce := GCECloud{manager: fakeManager, managedZones: []string{zone}} + + /* Act */ + _, err := gce.GetAutoLabelsForPD(diskName, zone) + + /* Assert */ + if err == nil { + t.Error("Expected error when the specified disk does not exist, but none returned.") + } +} + +func TestGetAutoLabelsForPD_DiskNotFoundAndNoZone(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + diskName := "disk" + gce := GCECloud{manager: fakeManager, managedZones: []string{}} + + /* Act */ + _, err := gce.GetAutoLabelsForPD(diskName, "") + + /* Assert */ + if err == nil { + t.Error("Expected error when the specified disk does not exist, but none returned.") + } +} + +func TestGetAutoLabelsForPD_DupDisk(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + diskName := "disk" + diskType := DiskTypeStandard + zone := "us-west1-b" + const sizeGb int64 = 128 + + gce := GCECloud{manager: fakeManager, managedZones: []string{"us-west1-b", "asia-southeast1-a"}} + for _, zone := range gce.managedZones { + gce.CreateDisk(diskName, diskType, zone, sizeGb, nil) + } + + /* Act */ + labels, err := gce.GetAutoLabelsForPD(diskName, zone) + + /* Assert */ + if err != nil { + t.Error("Disk name and zone uniquely identifies a disk, yet an error is returned.") + } + if labels[metav1.LabelZoneFailureDomain] != zone { + t.Errorf("Failure domain is '%v', but zone is '%v'", + labels[metav1.LabelZoneFailureDomain], zone) + } + if labels[metav1.LabelZoneRegion] != "us-west1" { + t.Errorf("Region is '%v', but zone is 'us-west1'", labels[metav1.LabelZoneRegion]) + } +} + +func TestGetAutoLabelsForPD_DupDiskNoZone(t *testing.T) { + /* Arrange */ + fakeManager := newFakeManager() + diskName := "disk" + diskType := DiskTypeStandard + const sizeGb int64 = 128 + + gce := GCECloud{manager: fakeManager, managedZones: []string{"us-west1-b", "asia-southeast1-a"}} + for _, zone := range gce.managedZones { + gce.CreateDisk(diskName, diskType, zone, sizeGb, nil) + } + + /* Act */ + _, err := gce.GetAutoLabelsForPD(diskName, "") + + /* Assert */ + if err == nil { + t.Error("Expected error when the disk is duplicated and zone is not specified, but none returned.") + } +} + +type FakeServiceManager struct { + // Common fields shared among tests + op *compute.Operation // Mocks an operation returned by GCE API calls + doesOpMatch bool + disks map[string]string // zone: diskName + waitForZoneOpError error // Error to be returned by WaitForZoneOp + + // Fields for TestCreateDisk + createDiskCalled bool + diskToCreate *compute.Disk + + // Fields for TestDeleteDisk + deleteDiskCalled bool + resourceInUse bool // Marks the disk as in-use +} + +func newFakeManager() *FakeServiceManager { + return &FakeServiceManager{disks: make(map[string]string)} +} + +/** + * Upon disk creation, disk info is stored in FakeServiceManager + * to be used by other tested methods. + */ +func (manager *FakeServiceManager) CreateDisk( + project string, + zone string, + disk *compute.Disk) (*compute.Operation, error) { + + manager.createDiskCalled = true + op := &compute.Operation{} + manager.op = op + manager.diskToCreate = disk + manager.disks[zone] = disk.Name + return op, nil +} + +/** + * Gets disk info stored in the FakeServiceManager. + */ +func (manager *FakeServiceManager) GetDisk( + project string, + zone string, + diskName string) (*compute.Disk, error) { + + if manager.disks[zone] == "" { + return nil, cloudprovider.DiskNotFound + } + + if manager.resourceInUse { + errorItem := googleapi.ErrorItem{Reason: "resourceInUseByAnotherResource"} + err := &googleapi.Error{Errors: []googleapi.ErrorItem{errorItem}} + return nil, err + } + + disk := &compute.Disk{Name: diskName, Zone: zone, Kind: "compute#disk"} + return disk, nil +} + +/** + * Disk info is removed from the FakeServiceManager. + */ +func (manager *FakeServiceManager) DeleteDisk( + project string, + zone string, + disk string) (*compute.Operation, error) { + + manager.deleteDiskCalled = true + op := &compute.Operation{} + manager.op = op + manager.disks[zone] = "" + return op, nil +} + +func (manager *FakeServiceManager) WaitForZoneOp( + op *compute.Operation, + zone string, + mc *metricContext) error { + if op == manager.op { + manager.doesOpMatch = true + } + return manager.waitForZoneOpError +} diff --git a/pkg/cloudprovider/providers/gce/gce_firewall.go b/pkg/cloudprovider/providers/gce/gce_firewall.go index 1826f20eb679c..668f2e0552224 100644 --- a/pkg/cloudprovider/providers/gce/gce_firewall.go +++ b/pkg/cloudprovider/providers/gce/gce_firewall.go @@ -19,96 +19,51 @@ package gce import ( "time" - "k8s.io/kubernetes/pkg/api/v1" - netsets "k8s.io/kubernetes/pkg/util/net/sets" - compute "google.golang.org/api/compute/v1" ) -func newFirewallMetricContext(request string, region string) *metricContext { +func newFirewallMetricContext(request string) *metricContext { return &metricContext{ start: time.Now(), - attributes: []string{"firewall_" + request, region, unusedMetricLabel}, + attributes: []string{"firewall_" + request, unusedMetricLabel, unusedMetricLabel}, } } // GetFirewall returns the Firewall by name. func (gce *GCECloud) GetFirewall(name string) (*compute.Firewall, error) { - mc := newFirewallMetricContext("get", "") + mc := newFirewallMetricContext("get") v, err := gce.service.Firewalls.Get(gce.projectID, name).Do() return v, mc.Observe(err) } -// CreateFirewall creates the given firewall rule. -func (gce *GCECloud) CreateFirewall(name, desc string, sourceRanges netsets.IPNet, ports []int64, hostNames []string) error { - region, err := GetGCERegion(gce.localZone) +// CreateFirewall creates the passed firewall +func (gce *GCECloud) CreateFirewall(f *compute.Firewall) error { + mc := newFirewallMetricContext("create") + op, err := gce.service.Firewalls.Insert(gce.projectID, f).Do() if err != nil { - return err - } - - mc := newFirewallMetricContext("create", region) - // TODO: This completely breaks modularity in the cloudprovider but - // the methods shared with the TCPLoadBalancer take v1.ServicePorts. - svcPorts := []v1.ServicePort{} - // TODO: Currently the only consumer of this method is the GCE L7 - // loadbalancer controller, which never needs a protocol other than - // TCP. We should pipe through a mapping of port:protocol and - // default to TCP if UDP ports are required. This means the method - // signature will change forcing downstream clients to refactor - // interfaces. - for _, p := range ports { - svcPorts = append(svcPorts, v1.ServicePort{Port: int32(p), Protocol: v1.ProtocolTCP}) + return mc.Observe(err) } - hosts, err := gce.getInstancesByNames(hostNames) - if err != nil { - mc.Observe(err) - return err - } - - return mc.Observe(gce.createFirewall(name, region, desc, sourceRanges, svcPorts, hosts)) + return gce.waitForGlobalOp(op, mc) } // DeleteFirewall deletes the given firewall rule. func (gce *GCECloud) DeleteFirewall(name string) error { - region, err := GetGCERegion(gce.localZone) + mc := newFirewallMetricContext("delete") + op, err := gce.service.Firewalls.Delete(gce.projectID, name).Do() if err != nil { - return err + return mc.Observe(err) } - - mc := newFirewallMetricContext("delete", region) - - return mc.Observe(gce.deleteFirewall(name, region)) + return gce.waitForGlobalOp(op, mc) } -// UpdateFirewall applies the given firewall rule as an update to an -// existing firewall rule with the same name. -func (gce *GCECloud) UpdateFirewall(name, desc string, sourceRanges netsets.IPNet, ports []int64, hostNames []string) error { - - region, err := GetGCERegion(gce.localZone) - if err != nil { - return err - } - - mc := newFirewallMetricContext("update", region) - // TODO: This completely breaks modularity in the cloudprovider but - // the methods shared with the TCPLoadBalancer take v1.ServicePorts. - svcPorts := []v1.ServicePort{} - // TODO: Currently the only consumer of this method is the GCE L7 - // loadbalancer controller, which never needs a protocol other than - // TCP. We should pipe through a mapping of port:protocol and - // default to TCP if UDP ports are required. This means the method - // signature will change, forcing downstream clients to refactor - // interfaces. - for _, p := range ports { - svcPorts = append(svcPorts, v1.ServicePort{Port: int32(p), Protocol: v1.ProtocolTCP}) - } - - hosts, err := gce.getInstancesByNames(hostNames) +// UpdateFirewall applies the given firewall as an update to an existing service. +func (gce *GCECloud) UpdateFirewall(f *compute.Firewall) error { + mc := newFirewallMetricContext("update") + op, err := gce.service.Firewalls.Update(gce.projectID, f.Name, f).Do() if err != nil { - mc.Observe(err) - return err + return mc.Observe(err) } - return mc.Observe(gce.updateFirewall(name, region, desc, sourceRanges, svcPorts, hosts)) + return gce.waitForGlobalOp(op, mc) } diff --git a/pkg/cloudprovider/providers/gce/gce_healthchecks.go b/pkg/cloudprovider/providers/gce/gce_healthchecks.go index bf168a029f520..7bd060b54a78d 100644 --- a/pkg/cloudprovider/providers/gce/gce_healthchecks.go +++ b/pkg/cloudprovider/providers/gce/gce_healthchecks.go @@ -17,11 +17,34 @@ limitations under the License. package gce import ( + "fmt" "time" + "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/pkg/master/ports" + utilversion "k8s.io/kubernetes/pkg/util/version" + + "github.com/golang/glog" compute "google.golang.org/api/compute/v1" ) +const ( + nodesHealthCheckPath = "/healthz" + lbNodesHealthCheckPort = ports.ProxyHealthzPort +) + +var ( + minNodesHealthCheckVersion *utilversion.Version +) + +func init() { + if v, err := utilversion.ParseGeneric("1.7.0"); err != nil { + panic(err) + } else { + minNodesHealthCheckVersion = v + } +} + func newHealthcheckMetricContext(request string) *metricContext { return &metricContext{ start: time.Now(), @@ -178,3 +201,53 @@ func (gce *GCECloud) ListHealthChecks() (*compute.HealthCheckList, error) { v, err := gce.service.HealthChecks.List(gce.projectID).Do() return v, mc.Observe(err) } + +// GetNodesHealthCheckPort returns the health check port used by the GCE load +// balancers (l4) for performing health checks on nodes. +func GetNodesHealthCheckPort() int32 { + return lbNodesHealthCheckPort +} + +// getNodesHealthCheckPath returns the health check path used by the GCE load +// balancers (l4) for performing health checks on nodes. +func getNodesHealthCheckPath() string { + return nodesHealthCheckPath +} + +// makeNodesHealthCheckName returns name of the health check resource used by +// the GCE load balancers (l4) for performing health checks on nodes. +func makeNodesHealthCheckName(clusterID string) string { + return fmt.Sprintf("k8s-%v-node", clusterID) +} + +// MakeHealthCheckFirewallName returns the firewall name used by the GCE load +// balancers (l4) for performing health checks. +func MakeHealthCheckFirewallName(clusterID, hcName string, isNodesHealthCheck bool) string { + if isNodesHealthCheck { + // TODO: Change below fwName to match the proposed schema: k8s-{clusteriD}-{namespace}-{name}-{shortid}-hc. + return makeNodesHealthCheckName(clusterID) + "-http-hc" + } + return "k8s-" + hcName + "-http-hc" +} + +// isAtLeastMinNodesHealthCheckVersion checks if a version is higher than +// `minNodesHealthCheckVersion`. +func isAtLeastMinNodesHealthCheckVersion(vstring string) bool { + version, err := utilversion.ParseGeneric(vstring) + if err != nil { + glog.Errorf("vstring (%s) is not a valid version string: %v", vstring, err) + return false + } + return version.AtLeast(minNodesHealthCheckVersion) +} + +// supportsNodesHealthCheck returns false if anyone of the nodes has version +// lower than `minNodesHealthCheckVersion`. +func supportsNodesHealthCheck(nodes []*v1.Node) bool { + for _, node := range nodes { + if !isAtLeastMinNodesHealthCheckVersion(node.Status.NodeInfo.KubeProxyVersion) { + return false + } + } + return true +} diff --git a/pkg/cloudprovider/providers/gce/gce_healthchecks_test.go b/pkg/cloudprovider/providers/gce/gce_healthchecks_test.go new file mode 100644 index 0000000000000..11be67954302f --- /dev/null +++ b/pkg/cloudprovider/providers/gce/gce_healthchecks_test.go @@ -0,0 +1,123 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package gce + +import ( + "testing" + + "k8s.io/kubernetes/pkg/api/v1" +) + +func TestIsAtLeastMinNodesHealthCheckVersion(t *testing.T) { + testCases := []struct { + version string + expect bool + }{ + {"v1.7.1", true}, + {"v1.7.0-alpha.2.597+276d289b90d322", true}, + {"v1.6.0-beta.3.472+831q821c907t31a", false}, + {"v1.5.2", false}, + } + + for _, tc := range testCases { + if res := isAtLeastMinNodesHealthCheckVersion(tc.version); res != tc.expect { + t.Errorf("%v: want %v, got %v", tc.version, tc.expect, res) + } + } +} + +func TestSupportsNodesHealthCheck(t *testing.T) { + testCases := []struct { + desc string + nodes []*v1.Node + expect bool + }{ + { + "All nodes support nodes health check", + []*v1.Node{ + { + Status: v1.NodeStatus{ + NodeInfo: v1.NodeSystemInfo{ + KubeProxyVersion: "v1.7.1", + }, + }, + }, + { + Status: v1.NodeStatus{ + NodeInfo: v1.NodeSystemInfo{ + KubeProxyVersion: "v1.7.0-alpha.2.597+276d289b90d322", + }, + }, + }, + }, + true, + }, + { + "All nodes don't support nodes health check", + []*v1.Node{ + { + Status: v1.NodeStatus{ + NodeInfo: v1.NodeSystemInfo{ + KubeProxyVersion: "v1.6.0-beta.3.472+831q821c907t31a", + }, + }, + }, + { + Status: v1.NodeStatus{ + NodeInfo: v1.NodeSystemInfo{ + KubeProxyVersion: "v1.5.2", + }, + }, + }, + }, + false, + }, + { + "One node doesn't support nodes health check", + []*v1.Node{ + { + Status: v1.NodeStatus{ + NodeInfo: v1.NodeSystemInfo{ + KubeProxyVersion: "v1.7.1", + }, + }, + }, + { + Status: v1.NodeStatus{ + NodeInfo: v1.NodeSystemInfo{ + KubeProxyVersion: "v1.7.0-alpha.2.597+276d289b90d322", + }, + }, + }, + { + Status: v1.NodeStatus{ + NodeInfo: v1.NodeSystemInfo{ + KubeProxyVersion: "v1.5.2", + }, + }, + }, + }, + false, + }, + } + + for _, tc := range testCases { + if res := supportsNodesHealthCheck(tc.nodes); res != tc.expect { + t.Errorf("%v: want %v, got %v", tc.desc, tc.expect, res) + } + } +} diff --git a/pkg/cloudprovider/providers/gce/gce_instancegroup.go b/pkg/cloudprovider/providers/gce/gce_instancegroup.go index e5ee03be020b0..c25aeb1af08ab 100644 --- a/pkg/cloudprovider/providers/gce/gce_instancegroup.go +++ b/pkg/cloudprovider/providers/gce/gce_instancegroup.go @@ -17,12 +17,8 @@ limitations under the License. package gce import ( - "fmt" - "net/http" - "strings" "time" - "github.com/golang/glog" compute "google.golang.org/api/compute/v1" ) @@ -37,7 +33,6 @@ func newInstanceGroupMetricContext(request string, zone string) *metricContext { // instances. It is the callers responsibility to add named ports. func (gce *GCECloud) CreateInstanceGroup(name string, zone string) (*compute.InstanceGroup, error) { mc := newInstanceGroupMetricContext("create", zone) - op, err := gce.service.InstanceGroups.Insert( gce.projectID, zone, &compute.InstanceGroup{Name: name}).Do() if err != nil { @@ -55,12 +50,10 @@ func (gce *GCECloud) CreateInstanceGroup(name string, zone string) (*compute.Ins // DeleteInstanceGroup deletes an instance group. func (gce *GCECloud) DeleteInstanceGroup(name string, zone string) error { mc := newInstanceGroupMetricContext("delete", zone) - op, err := gce.service.InstanceGroups.Delete( gce.projectID, zone, name).Do() if err != nil { - mc.Observe(err) - return err + return mc.Observe(err) } return gce.waitForZoneOp(op, zone, mc) @@ -103,10 +96,8 @@ func (gce *GCECloud) AddInstancesToInstanceGroup(name string, zone string, insta &compute.InstanceGroupsAddInstancesRequest{ Instances: instances, }).Do() - if err != nil { - mc.Observe(err) - return err + return mc.Observe(err) } return gce.waitForZoneOp(op, zone, mc) @@ -130,55 +121,24 @@ func (gce *GCECloud) RemoveInstancesFromInstanceGroup(name string, zone string, &compute.InstanceGroupsRemoveInstancesRequest{ Instances: instances, }).Do() - if err != nil { - if isHTTPErrorCode(err, http.StatusNotFound) { - mc.Observe(nil) - return nil - } - - mc.Observe(err) - return err + return mc.Observe(err) } return gce.waitForZoneOp(op, zone, mc) } -// AddPortToInstanceGroup adds a port to the given instance group. -func (gce *GCECloud) AddPortToInstanceGroup(ig *compute.InstanceGroup, port int64) (*compute.NamedPort, error) { - mc := newInstanceGroupMetricContext("add_port", ig.Zone) - for _, np := range ig.NamedPorts { - if np.Port == port { - glog.V(3).Infof("Instance group %v already has named port %+v", ig.Name, np) - return np, nil - } - } - - glog.Infof("Adding port %v to instance group %v with %d ports", port, ig.Name, len(ig.NamedPorts)) - namedPort := compute.NamedPort{Name: fmt.Sprintf("port%v", port), Port: port} - ig.NamedPorts = append(ig.NamedPorts, &namedPort) - - // setNamedPorts is a zonal endpoint, meaning we invoke it by re-creating a URL like: - // {project}/zones/{zone}/instanceGroups/{instanceGroup}/setNamedPorts, so the "zone" - // parameter given to SetNamedPorts must not be the entire zone URL. - zoneURLParts := strings.Split(ig.Zone, "/") - zone := zoneURLParts[len(zoneURLParts)-1] - +// SetNamedPortsOfInstanceGroup sets the list of named ports on a given instance group +func (gce *GCECloud) SetNamedPortsOfInstanceGroup(igName, zone string, namedPorts []*compute.NamedPort) error { + mc := newInstanceGroupMetricContext("set_namedports", zone) op, err := gce.service.InstanceGroups.SetNamedPorts( - gce.projectID, zone, ig.Name, - &compute.InstanceGroupsSetNamedPortsRequest{ - NamedPorts: ig.NamedPorts}).Do() - + gce.projectID, zone, igName, + &compute.InstanceGroupsSetNamedPortsRequest{NamedPorts: namedPorts}).Do() if err != nil { - mc.Observe(err) - return nil, err + return mc.Observe(err) } - if err = gce.waitForZoneOp(op, zone, mc); err != nil { - return nil, err - } - - return &namedPort, nil + return gce.waitForZoneOp(op, zone, mc) } // GetInstanceGroup returns an instance group by name. diff --git a/pkg/cloudprovider/providers/gce/gce_instances.go b/pkg/cloudprovider/providers/gce/gce_instances.go index 6446f26ff18af..33437a34628f8 100644 --- a/pkg/cloudprovider/providers/gce/gce_instances.go +++ b/pkg/cloudprovider/providers/gce/gce_instances.go @@ -443,3 +443,117 @@ func (gce *GCECloud) isCurrentInstance(instanceID string) bool { return currentInstanceID == canonicalizeInstanceName(instanceID) } + +// ComputeHostTags grabs all tags from all instances being added to the pool. +// * The longest tag that is a prefix of the instance name is used +// * If any instance has no matching prefix tag, return error +// Invoking this method to get host tags is risky since it depends on the format +// of the host names in the cluster. Only use it as a fallback if gce.nodeTags +// is unspecified +func (gce *GCECloud) computeHostTags(hosts []*gceInstance) ([]string, error) { + // TODO: We could store the tags in gceInstance, so we could have already fetched it + hostNamesByZone := make(map[string]map[string]bool) // map of zones -> map of names -> bool (for easy lookup) + nodeInstancePrefix := gce.nodeInstancePrefix + for _, host := range hosts { + if !strings.HasPrefix(host.Name, gce.nodeInstancePrefix) { + glog.Warningf("instance '%s' does not conform to prefix '%s', ignoring filter", host, gce.nodeInstancePrefix) + nodeInstancePrefix = "" + } + + z, ok := hostNamesByZone[host.Zone] + if !ok { + z = make(map[string]bool) + hostNamesByZone[host.Zone] = z + } + z[host.Name] = true + } + + tags := sets.NewString() + + for zone, hostNames := range hostNamesByZone { + pageToken := "" + page := 0 + for ; page == 0 || (pageToken != "" && page < maxPages); page++ { + listCall := gce.service.Instances.List(gce.projectID, zone) + + if nodeInstancePrefix != "" { + // Add the filter for hosts + listCall = listCall.Filter("name eq " + nodeInstancePrefix + ".*") + } + + // Add the fields we want + // TODO(zmerlynn): Internal bug 29524655 + // listCall = listCall.Fields("items(name,tags)") + + if pageToken != "" { + listCall = listCall.PageToken(pageToken) + } + + res, err := listCall.Do() + if err != nil { + return nil, err + } + pageToken = res.NextPageToken + for _, instance := range res.Items { + if !hostNames[instance.Name] { + continue + } + + longest_tag := "" + for _, tag := range instance.Tags.Items { + if strings.HasPrefix(instance.Name, tag) && len(tag) > len(longest_tag) { + longest_tag = tag + } + } + if len(longest_tag) > 0 { + tags.Insert(longest_tag) + } else { + return nil, fmt.Errorf("Could not find any tag that is a prefix of instance name for instance %s", instance.Name) + } + } + } + if page >= maxPages { + glog.Errorf("computeHostTags exceeded maxPages=%d for Instances.List: truncating.", maxPages) + } + } + if len(tags) == 0 { + return nil, fmt.Errorf("No instances found") + } + return tags.List(), nil +} + +// GetNodeTags will first try returning the list of tags specified in GCE cloud Configuration. +// If they weren't provided, it'll compute the host tags with the given hostnames. If the list +// of hostnames has not changed, a cached set of nodetags are returned. +func (gce *GCECloud) GetNodeTags(nodeNames []string) ([]string, error) { + // If nodeTags were specified through configuration, use them + if len(gce.nodeTags) > 0 { + return gce.nodeTags, nil + } + + gce.computeNodeTagLock.Lock() + defer gce.computeNodeTagLock.Unlock() + + // Early return if hosts have not changed + hosts := sets.NewString(nodeNames...) + if hosts.Equal(gce.lastKnownNodeNames) { + return gce.lastComputedNodeTags, nil + } + + // Get GCE instance data by hostname + instances, err := gce.getInstancesByNames(nodeNames) + if err != nil { + return nil, err + } + + // Determine list of host tags + tags, err := gce.computeHostTags(instances) + if err != nil { + return nil, err + } + + // Save the list of tags + gce.lastKnownNodeNames = hosts + gce.lastComputedNodeTags = tags + return tags, nil +} diff --git a/pkg/cloudprovider/providers/gce/gce_loadbalancer.go b/pkg/cloudprovider/providers/gce/gce_loadbalancer.go index f6aa1cad3f5bc..b3cf4e7792cfb 100644 --- a/pkg/cloudprovider/providers/gce/gce_loadbalancer.go +++ b/pkg/cloudprovider/providers/gce/gce_loadbalancer.go @@ -21,7 +21,6 @@ import ( "fmt" "net" "net/http" - "sort" "strconv" "strings" "time" @@ -140,6 +139,7 @@ func (gce *GCECloud) EnsureLoadBalancer(clusterName string, apiService *v1.Servi } hostNames := nodeNames(nodes) + supportsNodesHealthCheck := supportsNodesHealthCheck(nodes) hosts, err := gce.getInstancesByNames(hostNames) if err != nil { return nil, err @@ -289,13 +289,13 @@ func (gce *GCECloud) EnsureLoadBalancer(clusterName string, apiService *v1.Servi // without needing to be deleted and recreated. if firewallExists { glog.Infof("EnsureLoadBalancer(%v(%v)): updating firewall", loadBalancerName, serviceName) - if err := gce.updateFirewall(loadBalancerName, gce.region, desc, sourceRanges, ports, hosts); err != nil { + if err := gce.updateFirewall(makeFirewallName(loadBalancerName), gce.region, desc, sourceRanges, ports, hosts); err != nil { return nil, err } glog.Infof("EnsureLoadBalancer(%v(%v)): updated firewall", loadBalancerName, serviceName) } else { glog.Infof("EnsureLoadBalancer(%v(%v)): creating firewall", loadBalancerName, serviceName) - if err := gce.createFirewall(loadBalancerName, gce.region, desc, sourceRanges, ports, hosts); err != nil { + if err := gce.createFirewall(makeFirewallName(loadBalancerName), gce.region, desc, sourceRanges, ports, hosts); err != nil { return nil, err } glog.Infof("EnsureLoadBalancer(%v(%v)): created firewall", loadBalancerName, serviceName) @@ -310,34 +310,43 @@ func (gce *GCECloud) EnsureLoadBalancer(clusterName string, apiService *v1.Servi glog.Infof("Target pool %v for Service %v/%v doesn't exist", loadBalancerName, apiService.Namespace, apiService.Name) } - // Ensure health checks are created for this target pool to pass to createTargetPool for health check links - // Alternately, if the service has ExternalTrafficPolicy field set from Local to Global, we need to recreate - // the target pool without health checks. This needs to be prior to the forwarding rule deletion below otherwise - // it is not possible to delete just the target pool or http health checks later. - var hcToCreate *compute.HttpHealthCheck - hcExisting, err := gce.GetHttpHealthCheck(loadBalancerName) + clusterID, err := gce.ClusterID.GetID() + if err != nil { + return nil, fmt.Errorf("error getting cluster ID %s: %v", loadBalancerName, err) + } + // Check which health check needs to create and which health check needs to delete. + // Health check management is coupled with target pool operation to prevent leaking. + var hcToCreate, hcToDelete *compute.HttpHealthCheck + hcLocalTrafficExisting, err := gce.GetHttpHealthCheck(loadBalancerName) if err != nil && !isHTTPErrorCode(err, http.StatusNotFound) { - return nil, fmt.Errorf("Error checking HTTP health check %s: %v", loadBalancerName, err) + return nil, fmt.Errorf("error checking HTTP health check %s: %v", loadBalancerName, err) } if path, healthCheckNodePort := apiservice.GetServiceHealthCheckPathPort(apiService); path != "" { - glog.V(4).Infof("service %v (%v) needs health checks on :%d%s)", apiService.Name, loadBalancerName, healthCheckNodePort, path) - if err != nil { - // This logic exists to detect a transition for a pre-existing service and turn on - // the tpNeedsUpdate flag to delete/recreate fwdrule/tpool adding the health check - // to the target pool. - glog.V(2).Infof("ExternalTrafficPolicy field set to Local on new or pre-existing service") + glog.V(4).Infof("service %v (%v) needs local traffic health checks on: %d%s)", apiService.Name, loadBalancerName, healthCheckNodePort, path) + if hcLocalTrafficExisting == nil { + // This logic exists to detect a transition for non-OnlyLocal to OnlyLocal service + // turn on the tpNeedsUpdate flag to delete/recreate fwdrule/tpool updating the + // target pool to use local traffic health check. + glog.V(2).Infof("Updating from nodes health checks to local traffic health checks for service %v LB %v", apiService.Name, loadBalancerName) + if supportsNodesHealthCheck { + hcToDelete = makeHttpHealthCheck(makeNodesHealthCheckName(clusterID), getNodesHealthCheckPath(), GetNodesHealthCheckPort()) + } tpNeedsUpdate = true } - hcToCreate, err = gce.ensureHttpHealthCheck(loadBalancerName, path, healthCheckNodePort) - if err != nil { - return nil, fmt.Errorf("Failed to ensure health check for localized service %v on node port %v: %v", loadBalancerName, healthCheckNodePort, err) - } + hcToCreate = makeHttpHealthCheck(loadBalancerName, path, healthCheckNodePort) } else { - glog.V(4).Infof("service %v does not need health checks", apiService.Name) - if err == nil { - glog.V(2).Infof("Deleting stale health checks for service %v LB %v", apiService.Name, loadBalancerName) + glog.V(4).Infof("Service %v needs nodes health checks.", apiService.Name) + if hcLocalTrafficExisting != nil { + // This logic exists to detect a transition from OnlyLocal to non-OnlyLocal service + // and turn on the tpNeedsUpdate flag to delete/recreate fwdrule/tpool updating the + // target pool to use nodes health check. + glog.V(2).Infof("Updating from local traffic health checks to nodes health checks for service %v LB %v", apiService.Name, loadBalancerName) + hcToDelete = hcLocalTrafficExisting tpNeedsUpdate = true } + if supportsNodesHealthCheck { + hcToCreate = makeHttpHealthCheck(makeNodesHealthCheckName(clusterID), getNodesHealthCheckPath(), GetNodesHealthCheckPort()) + } } // Now we get to some slightly more interesting logic. // First, neither target pools nor forwarding rules can be updated in place - @@ -357,17 +366,12 @@ func (gce *GCECloud) EnsureLoadBalancer(clusterName string, apiService *v1.Servi glog.Infof("EnsureLoadBalancer(%v(%v)): deleted forwarding rule", loadBalancerName, serviceName) } if tpExists && tpNeedsUpdate { - // Generate the list of health checks for this target pool to pass to deleteTargetPool - if path, _ := apiservice.GetServiceHealthCheckPathPort(apiService); path != "" { - var err error - hcExisting, err = gce.GetHttpHealthCheck(loadBalancerName) - if err != nil && !isHTTPErrorCode(err, http.StatusNotFound) { - glog.Infof("Failed to retrieve health check %v:%v", loadBalancerName, err) - } + // Pass healthchecks to deleteTargetPool to cleanup health checks after cleaning up the target pool itself. + var hcNames []string + if hcToDelete != nil { + hcNames = append(hcNames, hcToDelete.Name) } - - // Pass healthchecks to deleteTargetPool to cleanup health checks prior to cleaning up the target pool itself. - if err := gce.deleteTargetPool(loadBalancerName, gce.region, hcExisting); err != nil { + if err := gce.deleteTargetPool(loadBalancerName, gce.region, hcNames...); err != nil { return nil, fmt.Errorf("failed to delete existing target pool %s for load balancer update: %v", loadBalancerName, err) } glog.Infof("EnsureLoadBalancer(%v(%v)): deleted target pool", loadBalancerName, serviceName) @@ -381,11 +385,11 @@ func (gce *GCECloud) EnsureLoadBalancer(clusterName string, apiService *v1.Servi createInstances = createInstances[:maxTargetPoolCreateInstances] } // Pass healthchecks to createTargetPool which needs them as health check links in the target pool - if err := gce.createTargetPool(loadBalancerName, serviceName.String(), gce.region, createInstances, affinityType, hcToCreate); err != nil { + if err := gce.createTargetPool(loadBalancerName, serviceName.String(), ipAddress, gce.region, createInstances, affinityType, hcToCreate); err != nil { return nil, fmt.Errorf("failed to create target pool %s: %v", loadBalancerName, err) } if hcToCreate != nil { - glog.Infof("EnsureLoadBalancer(%v(%v)): created health checks for target pool", loadBalancerName, serviceName) + glog.Infof("EnsureLoadBalancer(%v(%v)): created health checks %v for target pool", loadBalancerName, serviceName, hcToCreate.Name) } if len(hosts) <= maxTargetPoolCreateInstances { glog.Infof("EnsureLoadBalancer(%v(%v)): created target pool", loadBalancerName, serviceName) @@ -447,18 +451,29 @@ func (gce *GCECloud) EnsureLoadBalancerDeleted(clusterName string, service *v1.S glog.V(2).Infof("EnsureLoadBalancerDeleted(%v, %v, %v, %v, %v)", clusterName, service.Namespace, service.Name, loadBalancerName, gce.region) - var hc *compute.HttpHealthCheck + var hcNames []string if path, _ := apiservice.GetServiceHealthCheckPathPort(service); path != "" { - var err error - hc, err = gce.GetHttpHealthCheck(loadBalancerName) + hcToDelete, err := gce.GetHttpHealthCheck(loadBalancerName) if err != nil && !isHTTPErrorCode(err, http.StatusNotFound) { glog.Infof("Failed to retrieve health check %v:%v", loadBalancerName, err) return err } + hcNames = append(hcNames, hcToDelete.Name) + } else { + clusterID, err := gce.ClusterID.GetID() + if err != nil { + return fmt.Errorf("error getting cluster ID %s: %v", loadBalancerName, err) + } + // EnsureLoadBalancerDeleted() could be triggered by changing service from + // LoadBalancer type to others. In this case we have no idea whether it was + // using local traffic health check or nodes health check. Attempt to delete + // both to prevent leaking. + hcNames = append(hcNames, loadBalancerName) + hcNames = append(hcNames, makeNodesHealthCheckName(clusterID)) } errs := utilerrors.AggregateGoroutines( - func() error { return gce.deleteFirewall(loadBalancerName, gce.region) }, + func() error { return gce.deleteFirewall(makeFirewallName(loadBalancerName), gce.region) }, // Even though we don't hold on to static IPs for load balancers, it's // possible that EnsureLoadBalancer left one around in a failed // creation/update attempt, so make sure we clean it up here just in case. @@ -469,7 +484,7 @@ func (gce *GCECloud) EnsureLoadBalancerDeleted(clusterName string, service *v1.S if err := gce.deleteForwardingRule(loadBalancerName, gce.region); err != nil { return err } - if err := gce.deleteTargetPool(loadBalancerName, gce.region, hc); err != nil { + if err := gce.deleteTargetPool(loadBalancerName, gce.region, hcNames...); err != nil { return err } return nil @@ -509,15 +524,15 @@ func (gce *GCECloud) deleteForwardingRule(name, region string) error { } // DeleteTargetPool deletes the given target pool. -func (gce *GCECloud) DeleteTargetPool(name string, hc *compute.HttpHealthCheck) error { +func (gce *GCECloud) DeleteTargetPool(name string, hcNames ...string) error { region, err := GetGCERegion(gce.localZone) if err != nil { return err } - return gce.deleteTargetPool(name, region, hc) + return gce.deleteTargetPool(name, region, hcNames...) } -func (gce *GCECloud) deleteTargetPool(name, region string, hc *compute.HttpHealthCheck) error { +func (gce *GCECloud) deleteTargetPool(name, region string, hcNames ...string) error { mc := newTargetPoolMetricContext("delete", region) op, err := gce.service.TargetPools.Delete(gce.projectID, region, name).Do() @@ -535,41 +550,86 @@ func (gce *GCECloud) deleteTargetPool(name, region string, hc *compute.HttpHealt } // Deletion of health checks is allowed only after the TargetPool reference is deleted - if hc != nil { - glog.Infof("Deleting health check %v", hc.Name) - if err := gce.DeleteHttpHealthCheck(hc.Name); err != nil { - glog.Warningf("Failed to delete health check %v: %v", hc, err) + for _, hcName := range hcNames { + if err = func() error { + // Check whether it is nodes health check, which has different name from the load-balancer. + isNodesHealthCheck := hcName != name + if isNodesHealthCheck { + // Lock to prevent deleting necessary nodes health check before it gets attached + // to target pool. + gce.sharedResourceLock.Lock() + defer gce.sharedResourceLock.Unlock() + } + glog.Infof("Deleting health check %v", hcName) + if err := gce.DeleteHttpHealthCheck(hcName); err != nil { + // Delete nodes health checks will fail if any other target pool is using it. + if isInUsedByError(err) { + glog.V(4).Infof("Health check %v is in used: %v.", hcName, err) + return nil + } else if !isHTTPErrorCode(err, http.StatusNotFound) { + glog.Warningf("Failed to delete health check %v: %v", hcName, err) + return err + } + // StatusNotFound could happen when: + // - This is the first attempt but we pass in a healthcheck that is already deleted + // to prevent leaking. + // - This is the first attempt but user manually deleted the heathcheck. + // - This is a retry and in previous round we failed to delete the healthcheck firewall + // after deleted the healthcheck. + // We continue to delete the healthcheck firewall to prevent leaking. + glog.V(4).Infof("Health check %v is already deleted.", hcName) + } + clusterID, err := gce.ClusterID.GetID() + if err != nil { + return fmt.Errorf("error getting cluster ID: %v", err) + } + // If health check is deleted without error, it means no load-balancer is using it. + // So we should delete the health check firewall as well. + fwName := MakeHealthCheckFirewallName(clusterID, hcName, isNodesHealthCheck) + glog.Infof("Deleting firewall %v.", fwName) + if err := gce.DeleteFirewall(fwName); err != nil { + if isHTTPErrorCode(err, http.StatusNotFound) { + glog.V(4).Infof("Firewall %v is already deleted.", fwName) + return nil + } + return err + } + return nil + }(); err != nil { return err } - } else { - // This is a HC cleanup attempt to prevent stale HCs when errors are encountered - // during HC deletion in a prior pass through EnsureLoadBalancer. - // The HC name matches the load balancer name - normally this is expected to fail. - if err := gce.DeleteHttpHealthCheck(name); err == nil { - // We only print a warning if this deletion actually succeeded (which - // means there was indeed a stale health check with the LB name. - glog.Warningf("Deleted stale http health check for LB: %s", name) - } } + return nil } -func (gce *GCECloud) createTargetPool(name, serviceName, region string, hosts []*gceInstance, affinityType v1.ServiceAffinity, hc *compute.HttpHealthCheck) error { - var instances []string - for _, host := range hosts { - instances = append(instances, makeHostURL(gce.projectID, host.Zone, host.Name)) - } +func (gce *GCECloud) createTargetPool(name, serviceName, ipAddress, region string, hosts []*gceInstance, affinityType v1.ServiceAffinity, hc *compute.HttpHealthCheck) error { // health check management is coupled with targetPools to prevent leaks. A // target pool is the only thing that requires a health check, so we delete // associated checks on teardown, and ensure checks on setup. hcLinks := []string{} if hc != nil { + // Check whether it is nodes health check, which has different name from the load-balancer. + isNodesHealthCheck := hc.Name != name + if isNodesHealthCheck { + // Lock to prevent necessary nodes health check / firewall gets deleted. + gce.sharedResourceLock.Lock() + defer gce.sharedResourceLock.Unlock() + } + if err := gce.ensureHttpHealthCheckFirewall(serviceName, ipAddress, gce.region, hosts, hc.Name, int32(hc.Port), isNodesHealthCheck); err != nil { + return err + } var err error - if hc, err = gce.ensureHttpHealthCheck(name, hc.RequestPath, int32(hc.Port)); err != nil || hc == nil { + if hc, err = gce.ensureHttpHealthCheck(hc.Name, hc.RequestPath, int32(hc.Port)); err != nil || hc == nil { return fmt.Errorf("Failed to ensure health check for %v port %d path %v: %v", name, hc.Port, hc.RequestPath, err) } hcLinks = append(hcLinks, hc.SelfLink) } + + var instances []string + for _, host := range hosts { + instances = append(instances, makeHostURL(gce.projectID, host.Zone, host.Name)) + } glog.Infof("Creating targetpool %v with %d healthchecks", name, len(hcLinks)) pool := &compute.TargetPool{ Name: name, @@ -651,8 +711,8 @@ func (gce *GCECloud) targetPoolURL(name, region string) string { return fmt.Sprintf("https://www.googleapis.com/compute/v1/projects/%s/regions/%s/targetPools/%s", gce.projectID, region, name) } -func (gce *GCECloud) ensureHttpHealthCheck(name, path string, port int32) (hc *compute.HttpHealthCheck, err error) { - newHC := &compute.HttpHealthCheck{ +func makeHttpHealthCheck(name, path string, port int32) *compute.HttpHealthCheck { + return &compute.HttpHealthCheck{ Name: name, Port: int64(port), RequestPath: path, @@ -663,7 +723,10 @@ func (gce *GCECloud) ensureHttpHealthCheck(name, path string, port int32) (hc *c HealthyThreshold: gceHcHealthyThreshold, UnhealthyThreshold: gceHcUnhealthyThreshold, } +} +func (gce *GCECloud) ensureHttpHealthCheck(name, path string, port int32) (hc *compute.HttpHealthCheck, err error) { + newHC := makeHttpHealthCheck(name, path, port) hc, err = gce.GetHttpHealthCheck(name) if hc == nil || err != nil && isHTTPErrorCode(err, http.StatusNotFound) { glog.Infof("Did not find health check %v, creating port %v path %v", name, port, path) @@ -843,7 +906,7 @@ func (gce *GCECloud) firewallNeedsUpdate(name, serviceName, region, ipAddress st if isHTTPErrorCode(err, http.StatusNotFound) { return false, true, nil } - return false, false, fmt.Errorf("error getting load balancer's target pool: %v", err) + return false, false, fmt.Errorf("error getting load balancer's firewall: %v", err) } if fw.Description != makeFirewallDescription(serviceName, ipAddress) { return true, true, nil @@ -856,7 +919,7 @@ func (gce *GCECloud) firewallNeedsUpdate(name, serviceName, region, ipAddress st for ix := range ports { allowedPorts[ix] = strconv.Itoa(int(ports[ix].Port)) } - if !slicesEqual(allowedPorts, fw.Allowed[0].Ports) { + if !equalStringSets(allowedPorts, fw.Allowed[0].Ports) { return true, true, nil } // The service controller already verified that the protocol matches on all ports, no need to check. @@ -875,18 +938,47 @@ func (gce *GCECloud) firewallNeedsUpdate(name, serviceName, region, ipAddress st return true, false, nil } -func slicesEqual(x, y []string) bool { - if len(x) != len(y) { - return false +func (gce *GCECloud) ensureHttpHealthCheckFirewall(serviceName, ipAddress, region string, hosts []*gceInstance, hcName string, hcPort int32, isNodesHealthCheck bool) error { + clusterID, err := gce.ClusterID.GetID() + if err != nil { + return fmt.Errorf("error getting cluster ID: %v", err) + } + + // Prepare the firewall params for creating / checking. + desc := fmt.Sprintf(`{"kubernetes.io/cluster-id":"%s"}`, clusterID) + if !isNodesHealthCheck { + desc = makeFirewallDescription(serviceName, ipAddress) } - sort.Strings(x) - sort.Strings(y) - for i := range x { - if x[i] != y[i] { - return false + sourceRanges := lbSrcRngsFlag.ipn + ports := []v1.ServicePort{{Protocol: "tcp", Port: hcPort}} + + fwName := MakeHealthCheckFirewallName(clusterID, hcName, isNodesHealthCheck) + fw, err := gce.service.Firewalls.Get(gce.projectID, fwName).Do() + if err != nil { + if !isHTTPErrorCode(err, http.StatusNotFound) { + return fmt.Errorf("error getting firewall for health checks: %v", err) + } + glog.Infof("Creating firewall %v for health checks.", fwName) + if err := gce.createFirewall(fwName, region, desc, sourceRanges, ports, hosts); err != nil { + return err + } + glog.Infof("Created firewall %v for health checks.", fwName) + return nil + } + // Validate firewall fields. + if fw.Description != desc || + len(fw.Allowed) != 1 || + fw.Allowed[0].IPProtocol != string(ports[0].Protocol) || + !equalStringSets(fw.Allowed[0].Ports, []string{string(ports[0].Port)}) || + !equalStringSets(fw.SourceRanges, sourceRanges.StringSlice()) { + glog.Warningf("Firewall %v exists but parameters have drifted - updating...", fwName) + if err := gce.updateFirewall(fwName, region, desc, sourceRanges, ports, hosts); err != nil { + glog.Warningf("Failed to reconcile firewall %v parameters.", fwName) + return err } + glog.V(4).Infof("Corrected firewall %v parameters successful", fwName) } - return true + return nil } func (gce *GCECloud) createForwardingRule(name, serviceName, region, ipAddress string, ports []v1.ServicePort) error { @@ -918,7 +1010,7 @@ func (gce *GCECloud) createForwardingRule(name, serviceName, region, ipAddress s } func (gce *GCECloud) createFirewall(name, region, desc string, sourceRanges netsets.IPNet, ports []v1.ServicePort, hosts []*gceInstance) error { - mc := newFirewallMetricContext("create", region) + mc := newFirewallMetricContext("create") firewall, err := gce.firewallObject(name, region, desc, sourceRanges, ports, hosts) if err != nil { return mc.Observe(err) @@ -937,12 +1029,12 @@ func (gce *GCECloud) createFirewall(name, region, desc string, sourceRanges nets } func (gce *GCECloud) updateFirewall(name, region, desc string, sourceRanges netsets.IPNet, ports []v1.ServicePort, hosts []*gceInstance) error { - mc := newFirewallMetricContext("update", region) + mc := newFirewallMetricContext("update") firewall, err := gce.firewallObject(name, region, desc, sourceRanges, ports, hosts) if err != nil { return mc.Observe(err) } - op, err := gce.service.Firewalls.Update(gce.projectID, makeFirewallName(name), firewall).Do() + op, err := gce.service.Firewalls.Update(gce.projectID, name, firewall).Do() if err != nil && !isHTTPErrorCode(err, http.StatusConflict) { return mc.Observe(err) } @@ -971,7 +1063,7 @@ func (gce *GCECloud) firewallObject(name, region, desc string, sourceRanges nets } firewall := &compute.Firewall{ - Name: makeFirewallName(name), + Name: name, Description: desc, Network: gce.networkURL, SourceRanges: sourceRanges.StringSlice(), @@ -991,84 +1083,6 @@ func (gce *GCECloud) firewallObject(name, region, desc string, sourceRanges nets return firewall, nil } -// ComputeHostTags grabs all tags from all instances being added to the pool. -// * The longest tag that is a prefix of the instance name is used -// * If any instance has no matching prefix tag, return error -// Invoking this method to get host tags is risky since it depends on the format -// of the host names in the cluster. Only use it as a fallback if gce.nodeTags -// is unspecified -func (gce *GCECloud) computeHostTags(hosts []*gceInstance) ([]string, error) { - // TODO: We could store the tags in gceInstance, so we could have already fetched it - hostNamesByZone := make(map[string]map[string]bool) // map of zones -> map of names -> bool (for easy lookup) - nodeInstancePrefix := gce.nodeInstancePrefix - for _, host := range hosts { - if !strings.HasPrefix(host.Name, gce.nodeInstancePrefix) { - glog.Warningf("instance '%s' does not conform to prefix '%s', ignoring filter", host, gce.nodeInstancePrefix) - nodeInstancePrefix = "" - } - - z, ok := hostNamesByZone[host.Zone] - if !ok { - z = make(map[string]bool) - hostNamesByZone[host.Zone] = z - } - z[host.Name] = true - } - - tags := sets.NewString() - - for zone, hostNames := range hostNamesByZone { - pageToken := "" - page := 0 - for ; page == 0 || (pageToken != "" && page < maxPages); page++ { - listCall := gce.service.Instances.List(gce.projectID, zone) - - if nodeInstancePrefix != "" { - // Add the filter for hosts - listCall = listCall.Filter("name eq " + nodeInstancePrefix + ".*") - } - - // Add the fields we want - // TODO(zmerlynn): Internal bug 29524655 - // listCall = listCall.Fields("items(name,tags)") - - if pageToken != "" { - listCall = listCall.PageToken(pageToken) - } - - res, err := listCall.Do() - if err != nil { - return nil, err - } - pageToken = res.NextPageToken - for _, instance := range res.Items { - if !hostNames[instance.Name] { - continue - } - - longest_tag := "" - for _, tag := range instance.Tags.Items { - if strings.HasPrefix(instance.Name, tag) && len(tag) > len(longest_tag) { - longest_tag = tag - } - } - if len(longest_tag) > 0 { - tags.Insert(longest_tag) - } else { - return nil, fmt.Errorf("Could not find any tag that is a prefix of instance name for instance %s", instance.Name) - } - } - } - if page >= maxPages { - glog.Errorf("computeHostTags exceeded maxPages=%d for Instances.List: truncating.", maxPages) - } - } - if len(tags) == 0 { - return nil, fmt.Errorf("No instances found") - } - return tags.List(), nil -} - func (gce *GCECloud) projectOwnsStaticIP(name, region string, ipAddress string) (bool, error) { pageToken := "" page := 0 @@ -1140,18 +1154,17 @@ func (gce *GCECloud) ensureStaticIP(name, serviceName, region, existingIP string } func (gce *GCECloud) deleteFirewall(name, region string) error { - mc := newFirewallMetricContext("delete", region) - fwName := makeFirewallName(name) - op, err := gce.service.Firewalls.Delete(gce.projectID, fwName).Do() + mc := newFirewallMetricContext("delete") + op, err := gce.service.Firewalls.Delete(gce.projectID, name).Do() if err != nil && isHTTPErrorCode(err, http.StatusNotFound) { glog.V(2).Infof("Firewall %s already deleted. Continuing to delete other resources.", name) } else if err != nil { - glog.Warningf("Failed to delete firewall %s, got error %v", fwName, err) + glog.Warningf("Failed to delete firewall %s, got error %v", name, err) return mc.Observe(err) } else { if err := gce.waitForGlobalOp(op, mc); err != nil { - glog.Warningf("Failed waiting for Firewall %s to be deleted. Got error: %v", fwName, err) + glog.Warningf("Failed waiting for Firewall %s to be deleted. Got error: %v", name, err) return err } } diff --git a/pkg/cloudprovider/providers/gce/gce_test.go b/pkg/cloudprovider/providers/gce/gce_test.go index c05f0bdccbe9a..c04473f9380ce 100644 --- a/pkg/cloudprovider/providers/gce/gce_test.go +++ b/pkg/cloudprovider/providers/gce/gce_test.go @@ -149,16 +149,6 @@ func TestScrubDNS(t *testing.T) { } } -func TestCreateFirewallFails(t *testing.T) { - name := "loadbalancer" - region := "us-central1" - desc := "description" - gce := &GCECloud{} - if err := gce.createFirewall(name, region, desc, nil, nil, nil); err == nil { - t.Errorf("error expected when creating firewall without any tags found") - } -} - func TestSplitProviderID(t *testing.T) { providers := []struct { providerID string diff --git a/pkg/cloudprovider/providers/gce/gce_util.go b/pkg/cloudprovider/providers/gce/gce_util.go index 8f59cd5c495ec..90b51759f22cb 100644 --- a/pkg/cloudprovider/providers/gce/gce_util.go +++ b/pkg/cloudprovider/providers/gce/gce_util.go @@ -19,10 +19,12 @@ package gce import ( "errors" "fmt" + "net/http" "regexp" "strings" "k8s.io/apimachinery/pkg/types" + "k8s.io/apimachinery/pkg/util/sets" "cloud.google.com/go/compute/metadata" compute "google.golang.org/api/compute/v1" @@ -105,6 +107,14 @@ func isHTTPErrorCode(err error, code int) bool { return ok && apiErr.Code == code } +func isInUsedByError(err error) bool { + apiErr, ok := err.(*googleapi.Error) + if !ok || apiErr.Code != http.StatusBadRequest { + return false + } + return strings.Contains(apiErr.Message, "being used by") +} + // splitProviderID splits a provider's id into core components. // A providerID is build out of '${ProviderName}://${project-id}/${zone}/${instance-name}' // See cloudprovider.GetInstanceProviderID. @@ -115,3 +125,12 @@ func splitProviderID(providerID string) (project, zone, instance string, err err } return matches[1], matches[2], matches[3], nil } + +func equalStringSets(x, y []string) bool { + if len(x) != len(y) { + return false + } + xString := sets.NewString(x...) + yString := sets.NewString(y...) + return xString.Equal(yString) +} diff --git a/pkg/cloudprovider/providers/openstack/BUILD b/pkg/cloudprovider/providers/openstack/BUILD index bff0ea1d3c422..7ee996e03223b 100644 --- a/pkg/cloudprovider/providers/openstack/BUILD +++ b/pkg/cloudprovider/providers/openstack/BUILD @@ -13,6 +13,7 @@ go_library( srcs = [ "metadata.go", "openstack.go", + "openstack_client.go", "openstack_instances.go", "openstack_loadbalancer.go", "openstack_metrics.go", diff --git a/pkg/cloudprovider/providers/openstack/openstack.go b/pkg/cloudprovider/providers/openstack/openstack.go index 5aa71e9b06fdb..08a35565e64b4 100644 --- a/pkg/cloudprovider/providers/openstack/openstack.go +++ b/pkg/cloudprovider/providers/openstack/openstack.go @@ -428,19 +428,13 @@ func (os *OpenStack) LoadBalancer() (cloudprovider.LoadBalancer, bool) { glog.V(4).Info("openstack.LoadBalancer() called") // TODO: Search for and support Rackspace loadbalancer API, and others. - network, err := openstack.NewNetworkV2(os.provider, gophercloud.EndpointOpts{ - Region: os.region, - }) + network, err := os.NewNetworkV2() if err != nil { - glog.Warningf("Failed to find network endpoint: %v", err) return nil, false } - compute, err := openstack.NewComputeV2(os.provider, gophercloud.EndpointOpts{ - Region: os.region, - }) + compute, err := os.NewComputeV2() if err != nil { - glog.Warningf("Failed to find compute endpoint: %v", err) return nil, false } @@ -504,11 +498,8 @@ func (os *OpenStack) GetZone() (cloudprovider.Zone, error) { func (os *OpenStack) Routes() (cloudprovider.Routes, bool) { glog.V(4).Info("openstack.Routes() called") - network, err := openstack.NewNetworkV2(os.provider, gophercloud.EndpointOpts{ - Region: os.region, - }) + network, err := os.NewNetworkV2() if err != nil { - glog.Warningf("Failed to find network endpoint: %v", err) return nil, false } @@ -523,11 +514,8 @@ func (os *OpenStack) Routes() (cloudprovider.Routes, bool) { return nil, false } - compute, err := openstack.NewComputeV2(os.provider, gophercloud.EndpointOpts{ - Region: os.region, - }) + compute, err := os.NewComputeV2() if err != nil { - glog.Warningf("Failed to find compute endpoint: %v", err) return nil, false } @@ -595,29 +583,20 @@ func (os *OpenStack) volumeService(forceVersion string) (volumeService, error) { switch bsVersion { case "v1": - sClient, err := openstack.NewBlockStorageV1(os.provider, gophercloud.EndpointOpts{ - Region: os.region, - }) - if err != nil || sClient == nil { - glog.Errorf("Unable to initialize cinder client for region: %s", os.region) + sClient, err := os.NewBlockStorageV1() + if err != nil { return nil, err } return &VolumesV1{sClient, os.bsOpts}, nil case "v2": - sClient, err := openstack.NewBlockStorageV2(os.provider, gophercloud.EndpointOpts{ - Region: os.region, - }) - if err != nil || sClient == nil { - glog.Errorf("Unable to initialize cinder v2 client for region: %s", os.region) + sClient, err := os.NewBlockStorageV2() + if err != nil { return nil, err } return &VolumesV2{sClient, os.bsOpts}, nil case "auto": - sClient, err := openstack.NewBlockStorageV1(os.provider, gophercloud.EndpointOpts{ - Region: os.region, - }) - if err != nil || sClient == nil { - glog.Errorf("Unable to initialize cinder client for region: %s", os.region) + sClient, err := os.NewBlockStorageV1() + if err != nil { return nil, err } availableApiVersions := []apiversions_v1.APIVersion{} diff --git a/pkg/cloudprovider/providers/openstack/openstack_client.go b/pkg/cloudprovider/providers/openstack/openstack_client.go new file mode 100644 index 0000000000000..71b0078bfd06e --- /dev/null +++ b/pkg/cloudprovider/providers/openstack/openstack_client.go @@ -0,0 +1,68 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package openstack + +import ( + "github.com/gophercloud/gophercloud" + "github.com/gophercloud/gophercloud/openstack" + + "github.com/golang/glog" +) + +func (os *OpenStack) NewNetworkV2() (*gophercloud.ServiceClient, error) { + network, err := openstack.NewNetworkV2(os.provider, gophercloud.EndpointOpts{ + Region: os.region, + }) + if err != nil { + glog.Warningf("Failed to find network v2 endpoint: %v", err) + return nil, err + } + return network, nil +} + +func (os *OpenStack) NewComputeV2() (*gophercloud.ServiceClient, error) { + compute, err := openstack.NewComputeV2(os.provider, gophercloud.EndpointOpts{ + Region: os.region, + }) + if err != nil { + glog.Warningf("Failed to find compute v2 endpoint: %v", err) + return nil, err + } + return compute, nil +} + +func (os *OpenStack) NewBlockStorageV1() (*gophercloud.ServiceClient, error) { + storage, err := openstack.NewBlockStorageV1(os.provider, gophercloud.EndpointOpts{ + Region: os.region, + }) + if err != nil { + glog.Errorf("Unable to initialize cinder v1 client for region: %s", os.region) + return nil, err + } + return storage, nil +} + +func (os *OpenStack) NewBlockStorageV2() (*gophercloud.ServiceClient, error) { + storage, err := openstack.NewBlockStorageV2(os.provider, gophercloud.EndpointOpts{ + Region: os.region, + }) + if err != nil { + glog.Errorf("Unable to initialize cinder v2 client for region: %s", os.region) + return nil, err + } + return storage, nil +} diff --git a/pkg/cloudprovider/providers/openstack/openstack_instances.go b/pkg/cloudprovider/providers/openstack/openstack_instances.go index 3d4f749c7bc3c..4f42d4e4a2a1e 100644 --- a/pkg/cloudprovider/providers/openstack/openstack_instances.go +++ b/pkg/cloudprovider/providers/openstack/openstack_instances.go @@ -21,7 +21,6 @@ import ( "github.com/golang/glog" "github.com/gophercloud/gophercloud" - "github.com/gophercloud/gophercloud/openstack" "github.com/gophercloud/gophercloud/openstack/compute/v2/servers" "github.com/gophercloud/gophercloud/pagination" @@ -38,11 +37,8 @@ type Instances struct { func (os *OpenStack) Instances() (cloudprovider.Instances, bool) { glog.V(4).Info("openstack.Instances() called") - compute, err := openstack.NewComputeV2(os.provider, gophercloud.EndpointOpts{ - Region: os.region, - }) + compute, err := os.NewComputeV2() if err != nil { - glog.Warningf("Failed to find compute endpoint: %v", err) return nil, false } diff --git a/pkg/cloudprovider/providers/openstack/openstack_volumes.go b/pkg/cloudprovider/providers/openstack/openstack_volumes.go index 7db442abbf3eb..7f7b499bb7744 100644 --- a/pkg/cloudprovider/providers/openstack/openstack_volumes.go +++ b/pkg/cloudprovider/providers/openstack/openstack_volumes.go @@ -27,7 +27,6 @@ import ( k8s_volume "k8s.io/kubernetes/pkg/volume" "github.com/gophercloud/gophercloud" - "github.com/gophercloud/gophercloud/openstack" volumes_v1 "github.com/gophercloud/gophercloud/openstack/blockstorage/v1/volumes" volumes_v2 "github.com/gophercloud/gophercloud/openstack/blockstorage/v2/volumes" "github.com/gophercloud/gophercloud/openstack/compute/v2/extensions/volumeattach" @@ -221,11 +220,8 @@ func (os *OpenStack) AttachDisk(instanceID, volumeID string) (string, error) { glog.Errorf(errmsg) return "", errors.New(errmsg) } - cClient, err := openstack.NewComputeV2(os.provider, gophercloud.EndpointOpts{ - Region: os.region, - }) - if err != nil || cClient == nil { - glog.Errorf("Unable to initialize nova client for region: %s", os.region) + cClient, err := os.NewComputeV2() + if err != nil { return "", err } @@ -267,11 +263,8 @@ func (os *OpenStack) DetachDisk(instanceID, volumeID string) error { glog.Errorf(errmsg) return errors.New(errmsg) } - cClient, err := openstack.NewComputeV2(os.provider, gophercloud.EndpointOpts{ - Region: os.region, - }) - if err != nil || cClient == nil { - glog.Errorf("Unable to initialize nova client for region: %s", os.region) + cClient, err := os.NewComputeV2() + if err != nil { return err } if volume.AttachedServerId != instanceID { diff --git a/pkg/controller/BUILD b/pkg/controller/BUILD index 5faa984329943..9b4df49d7ef0b 100644 --- a/pkg/controller/BUILD +++ b/pkg/controller/BUILD @@ -125,6 +125,7 @@ filegroup( "//pkg/controller/statefulset:all-srcs", "//pkg/controller/ttl:all-srcs", "//pkg/controller/volume/attachdetach:all-srcs", + "//pkg/controller/volume/events:all-srcs", "//pkg/controller/volume/persistentvolume:all-srcs", ], tags = ["automanaged"], diff --git a/pkg/controller/certificates/BUILD b/pkg/controller/certificates/BUILD index 38e61a8b073e5..d7d54540da2b4 100644 --- a/pkg/controller/certificates/BUILD +++ b/pkg/controller/certificates/BUILD @@ -66,5 +66,6 @@ go_test( "//pkg/client/informers/informers_generated/externalversions:go_default_library", "//pkg/controller:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", ], ) diff --git a/pkg/controller/certificates/approver/BUILD b/pkg/controller/certificates/approver/BUILD index fa8cdacd04b4a..95e6aa9325d2b 100644 --- a/pkg/controller/certificates/approver/BUILD +++ b/pkg/controller/certificates/approver/BUILD @@ -10,22 +10,29 @@ load( go_test( name = "go_default_test", - srcs = ["groupapprove_test.go"], + srcs = ["sarapprove_test.go"], library = ":go_default_library", tags = ["automanaged"], - deps = ["//pkg/apis/certificates/v1beta1:go_default_library"], + deps = [ + "//pkg/apis/authorization/v1beta1:go_default_library", + "//pkg/apis/certificates/v1beta1:go_default_library", + "//pkg/client/clientset_generated/clientset/fake:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/client-go/testing:go_default_library", + ], ) go_library( name = "go_default_library", - srcs = ["groupapprove.go"], + srcs = ["sarapprove.go"], tags = ["automanaged"], deps = [ + "//pkg/apis/authorization/v1beta1:go_default_library", "//pkg/apis/certificates/v1beta1:go_default_library", "//pkg/client/clientset_generated/clientset:go_default_library", "//pkg/client/informers/informers_generated/externalversions/certificates/v1beta1:go_default_library", "//pkg/controller/certificates:go_default_library", - "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", ], ) diff --git a/pkg/controller/certificates/approver/groupapprove.go b/pkg/controller/certificates/approver/groupapprove.go deleted file mode 100644 index 60db46aa8d1ab..0000000000000 --- a/pkg/controller/certificates/approver/groupapprove.go +++ /dev/null @@ -1,131 +0,0 @@ -/* -Copyright 2016 The Kubernetes 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. -*/ - -// Package approver implements an automated approver for kubelet certificates. -package approver - -import ( - "fmt" - "reflect" - "strings" - - utilruntime "k8s.io/apimachinery/pkg/util/runtime" - capi "k8s.io/kubernetes/pkg/apis/certificates/v1beta1" - "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" - certificatesinformers "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/certificates/v1beta1" - "k8s.io/kubernetes/pkg/controller/certificates" -) - -func NewCSRApprovingController( - client clientset.Interface, - csrInformer certificatesinformers.CertificateSigningRequestInformer, - approveAllKubeletCSRsForGroup string, -) (*certificates.CertificateController, error) { - approver := &groupApprover{ - approveAllKubeletCSRsForGroup: approveAllKubeletCSRsForGroup, - client: client, - } - return certificates.NewCertificateController( - client, - csrInformer, - approver.handle, - ) -} - -// groupApprover implements AutoApprover for signing Kubelet certificates. -type groupApprover struct { - approveAllKubeletCSRsForGroup string - client clientset.Interface -} - -func (ga *groupApprover) handle(csr *capi.CertificateSigningRequest) error { - // short-circuit if we're already approved or denied - if approved, denied := certificates.GetCertApprovalCondition(&csr.Status); approved || denied { - return nil - } - csr, err := ga.autoApprove(csr) - if err != nil { - return fmt.Errorf("error auto approving csr: %v", err) - } - _, err = ga.client.Certificates().CertificateSigningRequests().UpdateApproval(csr) - if err != nil { - return fmt.Errorf("error updating approval for csr: %v", err) - } - return nil -} - -func (cc *groupApprover) autoApprove(csr *capi.CertificateSigningRequest) (*capi.CertificateSigningRequest, error) { - isKubeletBootstrapGroup := false - for _, g := range csr.Spec.Groups { - if g == cc.approveAllKubeletCSRsForGroup { - isKubeletBootstrapGroup = true - break - } - } - if !isKubeletBootstrapGroup { - return csr, nil - } - - x509cr, err := capi.ParseCSR(csr) - if err != nil { - utilruntime.HandleError(fmt.Errorf("unable to parse csr %q: %v", csr.Name, err)) - return csr, nil - } - if !reflect.DeepEqual([]string{"system:nodes"}, x509cr.Subject.Organization) { - return csr, nil - } - if !strings.HasPrefix(x509cr.Subject.CommonName, "system:node:") { - return csr, nil - } - if len(x509cr.DNSNames)+len(x509cr.EmailAddresses)+len(x509cr.IPAddresses) != 0 { - return csr, nil - } - if !hasExactUsages(csr, kubeletClientUsages) { - return csr, nil - } - - csr.Status.Conditions = append(csr.Status.Conditions, capi.CertificateSigningRequestCondition{ - Type: capi.CertificateApproved, - Reason: "AutoApproved", - Message: "Auto approving of all kubelet CSRs is enabled on the controller manager", - }) - return csr, nil -} - -var kubeletClientUsages = []capi.KeyUsage{ - capi.UsageKeyEncipherment, - capi.UsageDigitalSignature, - capi.UsageClientAuth, -} - -func hasExactUsages(csr *capi.CertificateSigningRequest, usages []capi.KeyUsage) bool { - if len(usages) != len(csr.Spec.Usages) { - return false - } - - usageMap := map[capi.KeyUsage]struct{}{} - for _, u := range usages { - usageMap[u] = struct{}{} - } - - for _, u := range csr.Spec.Usages { - if _, ok := usageMap[u]; !ok { - return false - } - } - - return true -} diff --git a/pkg/controller/certificates/approver/groupapprove_test.go b/pkg/controller/certificates/approver/groupapprove_test.go deleted file mode 100644 index e85c7cc99d1b8..0000000000000 --- a/pkg/controller/certificates/approver/groupapprove_test.go +++ /dev/null @@ -1,71 +0,0 @@ -/* -Copyright 2017 The Kubernetes 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. -*/ - -package approver - -import ( - "testing" - - api "k8s.io/kubernetes/pkg/apis/certificates/v1beta1" -) - -func TestHasKubeletUsages(t *testing.T) { - cases := []struct { - usages []api.KeyUsage - expected bool - }{ - { - usages: nil, - expected: false, - }, - { - usages: []api.KeyUsage{}, - expected: false, - }, - { - usages: []api.KeyUsage{ - api.UsageKeyEncipherment, - api.UsageDigitalSignature, - }, - expected: false, - }, - { - usages: []api.KeyUsage{ - api.UsageKeyEncipherment, - api.UsageDigitalSignature, - api.UsageServerAuth, - }, - expected: false, - }, - { - usages: []api.KeyUsage{ - api.UsageKeyEncipherment, - api.UsageDigitalSignature, - api.UsageClientAuth, - }, - expected: true, - }, - } - for _, c := range cases { - if hasExactUsages(&api.CertificateSigningRequest{ - Spec: api.CertificateSigningRequestSpec{ - Usages: c.usages, - }, - }, kubeletClientUsages) != c.expected { - t.Errorf("unexpected result of hasKubeletUsages(%v), expecting: %v", c.usages, c.expected) - } - } -} diff --git a/pkg/controller/certificates/approver/sarapprove.go b/pkg/controller/certificates/approver/sarapprove.go new file mode 100644 index 0000000000000..3bf50937480e2 --- /dev/null +++ b/pkg/controller/certificates/approver/sarapprove.go @@ -0,0 +1,200 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +// Package approver implements an automated approver for kubelet certificates. +package approver + +import ( + "crypto/x509" + "fmt" + "reflect" + "strings" + + authorization "k8s.io/kubernetes/pkg/apis/authorization/v1beta1" + capi "k8s.io/kubernetes/pkg/apis/certificates/v1beta1" + "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" + certificatesinformers "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions/certificates/v1beta1" + "k8s.io/kubernetes/pkg/controller/certificates" +) + +type csrRecognizer struct { + recognize func(csr *capi.CertificateSigningRequest, x509cr *x509.CertificateRequest) bool + permission authorization.ResourceAttributes + successMessage string +} + +type sarApprover struct { + client clientset.Interface + recognizers []csrRecognizer +} + +func NewCSRApprovingController(client clientset.Interface, csrInformer certificatesinformers.CertificateSigningRequestInformer) (*certificates.CertificateController, error) { + approver := &sarApprover{ + client: client, + recognizers: recognizers(), + } + return certificates.NewCertificateController( + client, + csrInformer, + approver.handle, + ) +} + +func recognizers() []csrRecognizer { + return []csrRecognizer{ + { + recognize: isSelfNodeClientCert, + permission: authorization.ResourceAttributes{Group: "certificates.k8s.io", Resource: "certificatesigningrequests", Verb: "create", Subresource: "selfnodeclient"}, + successMessage: "Auto approving self kubelet client certificate after SubjectAccessReview.", + }, + { + recognize: isNodeClientCert, + permission: authorization.ResourceAttributes{Group: "certificates.k8s.io", Resource: "certificatesigningrequests", Verb: "create", Subresource: "nodeclient"}, + successMessage: "Auto approving kubelet client certificate after SubjectAccessReview.", + }, + { + recognize: isSelfNodeServerCert, + permission: authorization.ResourceAttributes{Group: "certificates.k8s.io", Resource: "certificatesigningrequests", Verb: "create", Subresource: "selfnodeserver"}, + successMessage: "Auto approving self kubelet server certificate after SubjectAccessReview.", + }, + } +} + +func (a *sarApprover) handle(csr *capi.CertificateSigningRequest) error { + if len(csr.Status.Certificate) != 0 { + return nil + } + if approved, denied := certificates.GetCertApprovalCondition(&csr.Status); approved || denied { + return nil + } + x509cr, err := capi.ParseCSR(csr) + if err != nil { + return fmt.Errorf("unable to parse csr %q: %v", csr.Name, err) + } + + for _, r := range a.recognizers { + if !r.recognize(csr, x509cr) { + continue + } + approved, err := a.authorize(csr, r.permission) + if err != nil { + return err + } + if approved { + appendApprovalCondition(csr, r.successMessage) + _, err = a.client.Certificates().CertificateSigningRequests().UpdateApproval(csr) + if err != nil { + return fmt.Errorf("error updating approval for csr: %v", err) + } + return nil + } + } + return nil +} + +func (a *sarApprover) authorize(csr *capi.CertificateSigningRequest, rattrs authorization.ResourceAttributes) (bool, error) { + extra := make(map[string]authorization.ExtraValue) + for k, v := range csr.Spec.Extra { + extra[k] = authorization.ExtraValue(v) + } + + sar := &authorization.SubjectAccessReview{ + Spec: authorization.SubjectAccessReviewSpec{ + User: csr.Spec.Username, + Groups: csr.Spec.Groups, + Extra: extra, + ResourceAttributes: &rattrs, + }, + } + sar, err := a.client.AuthorizationV1beta1().SubjectAccessReviews().Create(sar) + if err != nil { + return false, err + } + return sar.Status.Allowed, nil +} + +func appendApprovalCondition(csr *capi.CertificateSigningRequest, message string) { + csr.Status.Conditions = append(csr.Status.Conditions, capi.CertificateSigningRequestCondition{ + Type: capi.CertificateApproved, + Reason: "AutoApproved", + Message: message, + }) +} + +func hasExactUsages(csr *capi.CertificateSigningRequest, usages []capi.KeyUsage) bool { + if len(usages) != len(csr.Spec.Usages) { + return false + } + + usageMap := map[capi.KeyUsage]struct{}{} + for _, u := range usages { + usageMap[u] = struct{}{} + } + + for _, u := range csr.Spec.Usages { + if _, ok := usageMap[u]; !ok { + return false + } + } + + return true +} + +var kubeletClientUsages = []capi.KeyUsage{ + capi.UsageKeyEncipherment, + capi.UsageDigitalSignature, + capi.UsageClientAuth, +} + +func isNodeClientCert(csr *capi.CertificateSigningRequest, x509cr *x509.CertificateRequest) bool { + if !reflect.DeepEqual([]string{"system:nodes"}, x509cr.Subject.Organization) { + return false + } + if (len(x509cr.DNSNames) > 0) || (len(x509cr.EmailAddresses) > 0) || (len(x509cr.IPAddresses) > 0) { + return false + } + if !hasExactUsages(csr, kubeletClientUsages) { + return false + } + if !strings.HasPrefix(x509cr.Subject.CommonName, "system:node:") { + return false + } + return true +} + +func isSelfNodeClientCert(csr *capi.CertificateSigningRequest, x509cr *x509.CertificateRequest) bool { + if !isNodeClientCert(csr, x509cr) { + return false + } + if csr.Spec.Username != x509cr.Subject.CommonName { + return false + } + return true +} + +var kubeletServerUsages = []capi.KeyUsage{ + capi.UsageKeyEncipherment, + capi.UsageDigitalSignature, + capi.UsageServerAuth, +} + +func isSelfNodeServerCert(csr *capi.CertificateSigningRequest, x509cr *x509.CertificateRequest) bool { + if !hasExactUsages(csr, kubeletServerUsages) { + return false + } + //TODO(jcbsmpsn): implement the rest of this + return false +} diff --git a/pkg/controller/certificates/approver/sarapprove_test.go b/pkg/controller/certificates/approver/sarapprove_test.go new file mode 100644 index 0000000000000..1dd3e3d322bbb --- /dev/null +++ b/pkg/controller/certificates/approver/sarapprove_test.go @@ -0,0 +1,296 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package approver + +import ( + "crypto/ecdsa" + "crypto/elliptic" + "crypto/x509" + "crypto/x509/pkix" + "encoding/pem" + "fmt" + "math/rand" + "net" + "testing" + + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + testclient "k8s.io/client-go/testing" + authorization "k8s.io/kubernetes/pkg/apis/authorization/v1beta1" + capi "k8s.io/kubernetes/pkg/apis/certificates/v1beta1" + "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/fake" +) + +func TestHasKubeletUsages(t *testing.T) { + cases := []struct { + usages []capi.KeyUsage + expected bool + }{ + { + usages: nil, + expected: false, + }, + { + usages: []capi.KeyUsage{}, + expected: false, + }, + { + usages: []capi.KeyUsage{ + capi.UsageKeyEncipherment, + capi.UsageDigitalSignature, + }, + expected: false, + }, + { + usages: []capi.KeyUsage{ + capi.UsageKeyEncipherment, + capi.UsageDigitalSignature, + capi.UsageServerAuth, + }, + expected: false, + }, + { + usages: []capi.KeyUsage{ + capi.UsageKeyEncipherment, + capi.UsageDigitalSignature, + capi.UsageClientAuth, + }, + expected: true, + }, + } + for _, c := range cases { + if hasExactUsages(&capi.CertificateSigningRequest{ + Spec: capi.CertificateSigningRequestSpec{ + Usages: c.usages, + }, + }, kubeletClientUsages) != c.expected { + t.Errorf("unexpected result of hasKubeletUsages(%v), expecting: %v", c.usages, c.expected) + } + } +} + +func TestHandle(t *testing.T) { + cases := []struct { + message string + allowed bool + recognized bool + verify func(*testing.T, []testclient.Action) + }{ + { + recognized: false, + allowed: false, + verify: func(t *testing.T, as []testclient.Action) { + if len(as) != 0 { + t.Errorf("expected no client calls but got: %#v", as) + } + }, + }, + { + recognized: false, + allowed: true, + verify: func(t *testing.T, as []testclient.Action) { + if len(as) != 0 { + t.Errorf("expected no client calls but got: %#v", as) + } + }, + }, + { + recognized: true, + allowed: false, + verify: func(t *testing.T, as []testclient.Action) { + if len(as) != 1 { + t.Errorf("expected 1 call but got: %#v", as) + return + } + _ = as[0].(testclient.CreateActionImpl) + }, + }, + { + recognized: true, + allowed: true, + verify: func(t *testing.T, as []testclient.Action) { + if len(as) != 2 { + t.Errorf("expected two calls but got: %#v", as) + return + } + _ = as[0].(testclient.CreateActionImpl) + a := as[1].(testclient.UpdateActionImpl) + if got, expected := a.Verb, "update"; got != expected { + t.Errorf("got: %v, expected: %v", got, expected) + } + if got, expected := a.Resource, (schema.GroupVersionResource{Group: "certificates.k8s.io", Version: "v1beta1", Resource: "certificatesigningrequests"}); got != expected { + t.Errorf("got: %v, expected: %v", got, expected) + } + if got, expected := a.Subresource, "approval"; got != expected { + t.Errorf("got: %v, expected: %v", got, expected) + } + csr := a.Object.(*capi.CertificateSigningRequest) + if len(csr.Status.Conditions) != 1 { + t.Errorf("expected CSR to have approved condition: %#v", csr) + } + c := csr.Status.Conditions[0] + if got, expected := c.Type, capi.CertificateApproved; got != expected { + t.Errorf("got: %v, expected: %v", got, expected) + } + if got, expected := c.Reason, "AutoApproved"; got != expected { + t.Errorf("got: %v, expected: %v", got, expected) + } + }, + }, + } + + for _, c := range cases { + t.Run(fmt.Sprintf("recognized:%v,allowed: %v", c.recognized, c.allowed), func(t *testing.T) { + client := &fake.Clientset{} + client.AddReactor("create", "subjectaccessreviews", func(action testclient.Action) (handled bool, ret runtime.Object, err error) { + return true, &authorization.SubjectAccessReview{ + Status: authorization.SubjectAccessReviewStatus{ + Allowed: c.allowed, + }, + }, nil + }) + approver := sarApprover{ + client: client, + recognizers: []csrRecognizer{ + { + successMessage: "tester", + permission: authorization.ResourceAttributes{Group: "foo", Resource: "bar", Subresource: "baz"}, + recognize: func(csr *capi.CertificateSigningRequest, x509cr *x509.CertificateRequest) bool { + return c.recognized + }, + }, + }, + } + csr := makeTestCsr() + if err := approver.handle(csr); err != nil { + t.Errorf("unexpected err: %v", err) + } + c.verify(t, client.Actions()) + }) + } +} + +func TestRecognizers(t *testing.T) { + goodCases := []func(b *csrBuilder){ + func(b *csrBuilder) { + }, + } + + testRecognizer(t, goodCases, isNodeClientCert, true) + testRecognizer(t, goodCases, isSelfNodeClientCert, true) + + badCases := []func(b *csrBuilder){ + func(b *csrBuilder) { + b.cn = "mike" + }, + func(b *csrBuilder) { + b.orgs = nil + }, + func(b *csrBuilder) { + b.orgs = []string{"system:master"} + }, + func(b *csrBuilder) { + b.usages = append(b.usages, capi.UsageServerAuth) + }, + } + + testRecognizer(t, badCases, isNodeClientCert, false) + testRecognizer(t, badCases, isSelfNodeClientCert, false) + + // cn different then requestor + differentCN := []func(b *csrBuilder){ + func(b *csrBuilder) { + b.requestor = "joe" + }, + func(b *csrBuilder) { + b.cn = "system:node:bar" + }, + } + + testRecognizer(t, differentCN, isNodeClientCert, true) + testRecognizer(t, differentCN, isSelfNodeClientCert, false) +} + +func testRecognizer(t *testing.T, cases []func(b *csrBuilder), recognizeFunc func(csr *capi.CertificateSigningRequest, x509cr *x509.CertificateRequest) bool, shouldRecognize bool) { + for _, c := range cases { + b := csrBuilder{ + cn: "system:node:foo", + orgs: []string{"system:nodes"}, + requestor: "system:node:foo", + usages: []capi.KeyUsage{ + capi.UsageKeyEncipherment, + capi.UsageDigitalSignature, + capi.UsageClientAuth, + }, + } + c(&b) + t.Run(fmt.Sprintf("csr:%#v", b), func(t *testing.T) { + csr := makeFancyTestCsr(b) + x509cr, err := capi.ParseCSR(csr) + if err != nil { + t.Errorf("unexpected err: %v", err) + } + if recognizeFunc(csr, x509cr) != shouldRecognize { + t.Errorf("expected recognized to be %v", shouldRecognize) + } + }) + } +} + +// noncryptographic for faster testing +// DO NOT COPY THIS CODE +var insecureRand = rand.New(rand.NewSource(0)) + +func makeTestCsr() *capi.CertificateSigningRequest { + return makeFancyTestCsr(csrBuilder{cn: "test-cert"}) +} + +type csrBuilder struct { + cn string + orgs []string + requestor string + usages []capi.KeyUsage + dns []string + emails []string + ips []net.IP +} + +func makeFancyTestCsr(b csrBuilder) *capi.CertificateSigningRequest { + pk, err := ecdsa.GenerateKey(elliptic.P224(), insecureRand) + if err != nil { + panic(err) + } + csrb, err := x509.CreateCertificateRequest(insecureRand, &x509.CertificateRequest{ + Subject: pkix.Name{ + CommonName: b.cn, + Organization: b.orgs, + }, + DNSNames: b.dns, + EmailAddresses: b.emails, + IPAddresses: b.ips, + }, pk) + if err != nil { + panic(err) + } + return &capi.CertificateSigningRequest{ + Spec: capi.CertificateSigningRequestSpec{ + Username: b.requestor, + Usages: b.usages, + Request: pem.EncodeToMemory(&pem.Block{Type: "CERTIFICATE REQUEST", Bytes: csrb}), + }, + } +} diff --git a/pkg/controller/certificates/certificate_controller_test.go b/pkg/controller/certificates/certificate_controller_test.go index 1828759fbe11a..2d5af91543381 100644 --- a/pkg/controller/certificates/certificate_controller_test.go +++ b/pkg/controller/certificates/certificate_controller_test.go @@ -18,8 +18,10 @@ package certificates import ( "testing" + "time" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/wait" certificates "k8s.io/kubernetes/pkg/apis/certificates/v1beta1" "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/fake" informers "k8s.io/kubernetes/pkg/client/informers/informers_generated/externalversions" @@ -37,7 +39,7 @@ func TestCertificateController(t *testing.T) { } client := fake.NewSimpleClientset(csr) - informerFactory := informers.NewSharedInformerFactory(client, controller.NoResyncPeriodFunc()) + informerFactory := informers.NewSharedInformerFactory(fake.NewSimpleClientset(csr), controller.NoResyncPeriodFunc()) handler := func(csr *certificates.CertificateSigningRequest) error { csr.Status.Conditions = append(csr.Status.Conditions, certificates.CertificateSigningRequestCondition{ @@ -64,21 +66,19 @@ func TestCertificateController(t *testing.T) { stopCh := make(chan struct{}) defer close(stopCh) - go informerFactory.Start(stopCh) + informerFactory.Start(stopCh) + informerFactory.WaitForCacheSync(stopCh) + wait.PollUntil(10*time.Millisecond, func() (bool, error) { + return controller.queue.Len() >= 1, nil + }, stopCh) controller.processNextWorkItem() actions := client.Actions() - if len(actions) != 3 { - t.Errorf("expected 3 actions") + if len(actions) != 1 { + t.Errorf("expected 1 actions") } - if a := actions[0]; !a.Matches("list", "certificatesigningrequests") { - t.Errorf("unexpected action: %#v", a) - } - if a := actions[1]; !a.Matches("watch", "certificatesigningrequests") { - t.Errorf("unexpected action: %#v", a) - } - if a := actions[2]; !a.Matches("update", "certificatesigningrequests") || + if a := actions[0]; !a.Matches("update", "certificatesigningrequests") || a.GetSubresource() != "approval" { t.Errorf("unexpected action: %#v", a) } diff --git a/pkg/controller/certificates/signer/cfssl_signer.go b/pkg/controller/certificates/signer/cfssl_signer.go index fc1ad2339223a..e8309e59f3cd5 100644 --- a/pkg/controller/certificates/signer/cfssl_signer.go +++ b/pkg/controller/certificates/signer/cfssl_signer.go @@ -23,6 +23,7 @@ import ( "fmt" "io/ioutil" "os" + "time" capi "k8s.io/kubernetes/pkg/apis/certificates/v1beta1" "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" @@ -35,20 +36,13 @@ import ( "github.com/cloudflare/cfssl/signer/local" ) -var onlySigningPolicy = &config.Signing{ - Default: &config.SigningProfile{ - Usage: []string{"signing"}, - Expiry: helpers.OneYear, - ExpiryString: "8760h", - }, -} - func NewCSRSigningController( client clientset.Interface, csrInformer certificatesinformers.CertificateSigningRequestInformer, caFile, caKeyFile string, + certificateDuration time.Duration, ) (*certificates.CertificateController, error) { - signer, err := newCFSSLSigner(caFile, caKeyFile, client) + signer, err := newCFSSLSigner(caFile, caKeyFile, client, certificateDuration) if err != nil { return nil, err } @@ -60,13 +54,14 @@ func NewCSRSigningController( } type cfsslSigner struct { - ca *x509.Certificate - priv crypto.Signer - sigAlgo x509.SignatureAlgorithm - client clientset.Interface + ca *x509.Certificate + priv crypto.Signer + sigAlgo x509.SignatureAlgorithm + client clientset.Interface + certificateDuration time.Duration } -func newCFSSLSigner(caFile, caKeyFile string, client clientset.Interface) (*cfsslSigner, error) { +func newCFSSLSigner(caFile, caKeyFile string, client clientset.Interface, certificateDuration time.Duration) (*cfsslSigner, error) { ca, err := ioutil.ReadFile(caFile) if err != nil { return nil, err @@ -92,10 +87,11 @@ func newCFSSLSigner(caFile, caKeyFile string, client clientset.Interface) (*cfss return nil, fmt.Errorf("Malformed private key %v", err) } return &cfsslSigner{ - priv: priv, - ca: parsedCa, - sigAlgo: signer.DefaultSigAlgo(priv), - client: client, + priv: priv, + ca: parsedCa, + sigAlgo: signer.DefaultSigAlgo(priv), + client: client, + certificateDuration: certificateDuration, }, nil } @@ -122,8 +118,8 @@ func (s *cfsslSigner) sign(csr *capi.CertificateSigningRequest) (*capi.Certifica policy := &config.Signing{ Default: &config.SigningProfile{ Usage: usages, - Expiry: helpers.OneYear, - ExpiryString: "8760h", + Expiry: s.certificateDuration, + ExpiryString: s.certificateDuration.String(), }, } cfs, err := local.NewSigner(s.priv, s.ca, s.sigAlgo, policy) diff --git a/pkg/controller/certificates/signer/cfssl_signer_test.go b/pkg/controller/certificates/signer/cfssl_signer_test.go index 6d6c2f2374898..8ba6c95da427d 100644 --- a/pkg/controller/certificates/signer/cfssl_signer_test.go +++ b/pkg/controller/certificates/signer/cfssl_signer_test.go @@ -21,13 +21,14 @@ import ( "io/ioutil" "reflect" "testing" + "time" "k8s.io/client-go/util/cert" capi "k8s.io/kubernetes/pkg/apis/certificates/v1beta1" ) func TestSigner(t *testing.T) { - s, err := newCFSSLSigner("./testdata/ca.crt", "./testdata/ca.key", nil) + s, err := newCFSSLSigner("./testdata/ca.crt", "./testdata/ca.key", nil, 1*time.Hour) if err != nil { t.Fatalf("failed to create signer: %v", err) } diff --git a/pkg/controller/daemon/daemoncontroller.go b/pkg/controller/daemon/daemoncontroller.go index ac34546ba8b41..8e3b35c35e72e 100644 --- a/pkg/controller/daemon/daemoncontroller.go +++ b/pkg/controller/daemon/daemoncontroller.go @@ -425,13 +425,46 @@ func (dsc *DaemonSetsController) addNode(obj interface{}) { } } +// nodeInSameCondition returns true if all effective types ("Status" is true) equals; +// otherwise, returns false. +func nodeInSameCondition(old []v1.NodeCondition, cur []v1.NodeCondition) bool { + if len(old) == 0 && len(cur) == 0 { + return true + } + + c1map := map[v1.NodeConditionType]v1.ConditionStatus{} + for _, c := range old { + if c.Status == v1.ConditionTrue { + c1map[c.Type] = c.Status + } + } + + for _, c := range cur { + if c.Status != v1.ConditionTrue { + continue + } + + if _, found := c1map[c.Type]; !found { + return false + } + + delete(c1map, c.Type) + } + + return len(c1map) == 0 +} + func (dsc *DaemonSetsController) updateNode(old, cur interface{}) { oldNode := old.(*v1.Node) curNode := cur.(*v1.Node) - if reflect.DeepEqual(oldNode.Labels, curNode.Labels) && reflect.DeepEqual(oldNode.Spec.Taints, curNode.Spec.Taints) { - // If node labels and taints didn't change, we can ignore this update. + + if reflect.DeepEqual(oldNode.Labels, curNode.Labels) && + reflect.DeepEqual(oldNode.Spec.Taints, curNode.Spec.Taints) && + nodeInSameCondition(oldNode.Status.Conditions, curNode.Status.Conditions) { + // If node labels, taints and condition didn't change, we can ignore this update. return } + dsList, err := dsc.dsLister.List(labels.Everything()) if err != nil { glog.V(4).Infof("Error enqueueing daemon sets: %v", err) diff --git a/pkg/controller/daemon/daemoncontroller_test.go b/pkg/controller/daemon/daemoncontroller_test.go index d7ee241d448e4..b4703e0dd6c9c 100644 --- a/pkg/controller/daemon/daemoncontroller_test.go +++ b/pkg/controller/daemon/daemoncontroller_test.go @@ -1219,6 +1219,43 @@ func TestUpdateNode(t *testing.T) { ds: newDaemonSet("ds"), shouldEnqueue: true, }, + { + test: "Node conditions changed", + oldNode: func() *v1.Node { + node := newNode("node1", nil) + node.Status.Conditions = []v1.NodeCondition{ + {Type: v1.NodeOutOfDisk, Status: v1.ConditionTrue}, + } + return node + }(), + newNode: newNode("node1", nil), + ds: newDaemonSet("ds"), + shouldEnqueue: true, + }, + { + test: "Node conditions not changed", + oldNode: func() *v1.Node { + node := newNode("node1", nil) + node.Status.Conditions = []v1.NodeCondition{ + {Type: v1.NodeOutOfDisk, Status: v1.ConditionTrue}, + {Type: v1.NodeMemoryPressure, Status: v1.ConditionFalse}, + {Type: v1.NodeDiskPressure, Status: v1.ConditionFalse}, + {Type: v1.NodeNetworkUnavailable, Status: v1.ConditionFalse}, + {Type: v1.NodeInodePressure, Status: v1.ConditionFalse}, + } + return node + }(), + newNode: func() *v1.Node { + node := newNode("node1", nil) + node.Status.Conditions = []v1.NodeCondition{ + {Type: v1.NodeOutOfDisk, Status: v1.ConditionTrue}, + {Type: v1.NodeInodePressure, Status: v1.ConditionFalse}, + } + return node + }(), + ds: newDaemonSet("ds"), + shouldEnqueue: false, + }, } for _, c := range cases { manager, podControl, _ := newTestController() diff --git a/pkg/controller/disruption/disruption.go b/pkg/controller/disruption/disruption.go index eed47823626c3..d5a3038cd7158 100644 --- a/pkg/controller/disruption/disruption.go +++ b/pkg/controller/disruption/disruption.go @@ -421,6 +421,8 @@ func (dc *DisruptionController) getPdbForPod(pod *v1.Pod) *policy.PodDisruptionB return pdbs[0] } +// This function returns pods using the PodDisruptionBudget object. +// IMPORTANT NOTE : the returned pods should NOT be modified. func (dc *DisruptionController) getPodsForPdb(pdb *policy.PodDisruptionBudget) ([]*v1.Pod, error) { sel, err := metav1.LabelSelectorAsSelector(pdb.Spec.Selector) if sel.Empty() { @@ -433,12 +435,7 @@ func (dc *DisruptionController) getPodsForPdb(pdb *policy.PodDisruptionBudget) ( if err != nil { return []*v1.Pod{}, err } - // TODO: Do we need to copy here? - result := make([]*v1.Pod, 0, len(pods)) - for i := range pods { - result = append(result, &(*pods[i])) - } - return result, nil + return pods, nil } func (dc *DisruptionController) worker() { diff --git a/pkg/controller/node/nodecontroller.go b/pkg/controller/node/nodecontroller.go index 9df927ee234f7..fc244f64430c1 100644 --- a/pkg/controller/node/nodecontroller.go +++ b/pkg/controller/node/nodecontroller.go @@ -294,7 +294,7 @@ func NewNodeController( }, DeleteFunc: func(obj interface{}) { pod, isPod := obj.(*v1.Pod) - // We can get DeletedFinalStateUnknown instead of *v1.Node here and we need to handle that correctly. #34692 + // We can get DeletedFinalStateUnknown instead of *v1.Pod here and we need to handle that correctly. if !isPod { deletedState, ok := obj.(cache.DeletedFinalStateUnknown) if !ok { @@ -303,7 +303,7 @@ func NewNodeController( } pod, ok = deletedState.Obj.(*v1.Pod) if !ok { - glog.Errorf("DeletedFinalStateUnknown contained non-Node object: %v", deletedState.Obj) + glog.Errorf("DeletedFinalStateUnknown contained non-Pod object: %v", deletedState.Obj) return } } diff --git a/pkg/controller/node/taint_controller.go b/pkg/controller/node/taint_controller.go index d0a8132149eed..a793f2a903b0c 100644 --- a/pkg/controller/node/taint_controller.go +++ b/pkg/controller/node/taint_controller.go @@ -61,7 +61,7 @@ type podUpdateItem struct { newTolerations []v1.Toleration } -// NoExecuteTaintManager listens to Taint/Toleration changes and is resposible for removing Pods +// NoExecuteTaintManager listens to Taint/Toleration changes and is responsible for removing Pods // from Nodes tainted with NoExecute Taints. type NoExecuteTaintManager struct { client clientset.Interface diff --git a/pkg/controller/volume/attachdetach/attach_detach_controller.go b/pkg/controller/volume/attachdetach/attach_detach_controller.go index cdfd24923ff66..8db0839241830 100644 --- a/pkg/controller/volume/attachdetach/attach_detach_controller.go +++ b/pkg/controller/volume/attachdetach/attach_detach_controller.go @@ -552,6 +552,12 @@ func (adc *attachDetachController) GetSecretFunc() func(namespace, name string) } } +func (adc *attachDetachController) GetConfigMapFunc() func(namespace, name string) (*v1.ConfigMap, error) { + return func(_, _ string) (*v1.ConfigMap, error) { + return nil, fmt.Errorf("GetConfigMap unsupported in attachDetachController") + } +} + func (adc *attachDetachController) addNodeToDswp(node *v1.Node, nodeName types.NodeName) { if _, exists := node.Annotations[volumehelper.ControllerManagedAttachAnnotation]; exists { keepTerminatedPodVolumes := false @@ -565,3 +571,7 @@ func (adc *attachDetachController) addNodeToDswp(node *v1.Node, nodeName types.N adc.desiredStateOfWorld.AddNode(nodeName, keepTerminatedPodVolumes) } } + +func (adc *attachDetachController) GetNodeLabels() (map[string]string, error) { + return nil, fmt.Errorf("GetNodeLabels() unsupported in Attach/Detach controller") +} diff --git a/pkg/controller/volume/attachdetach/cache/actual_state_of_world.go b/pkg/controller/volume/attachdetach/cache/actual_state_of_world.go index bece129d39524..1c01d931c136e 100644 --- a/pkg/controller/volume/attachdetach/cache/actual_state_of_world.go +++ b/pkg/controller/volume/attachdetach/cache/actual_state_of_world.go @@ -125,6 +125,10 @@ type ActualStateOfWorld interface { // GetNodesToUpdateStatusFor returns the map of nodeNames to nodeToUpdateStatusFor GetNodesToUpdateStatusFor() map[types.NodeName]nodeToUpdateStatusFor + + // Removes the given node from the record of attach updates. The node's entire + // volumesToReportAsAttached list is removed. + RemoveNodeFromAttachUpdates(nodeName types.NodeName) error } // AttachedVolume represents a volume that is attached to a node. @@ -260,6 +264,19 @@ func (asw *actualStateOfWorld) AddVolumeToReportAsAttached( asw.addVolumeToReportAsAttached(volumeName, nodeName) } +func (asw *actualStateOfWorld) RemoveNodeFromAttachUpdates(nodeName types.NodeName) error { + asw.Lock() + defer asw.Unlock() + + _, nodeToUpdateExists := asw.nodesToUpdateStatusFor[nodeName] + if nodeToUpdateExists { + delete(asw.nodesToUpdateStatusFor, nodeName) + return nil + } + return fmt.Errorf("node %q does not exist in volumesToReportAsAttached list", + nodeName) +} + func (asw *actualStateOfWorld) AddVolumeNode( uniqueName v1.UniqueVolumeName, volumeSpec *volume.Spec, nodeName types.NodeName, devicePath string) (v1.UniqueVolumeName, error) { asw.Lock() diff --git a/pkg/controller/volume/attachdetach/cache/actual_state_of_world_test.go b/pkg/controller/volume/attachdetach/cache/actual_state_of_world_test.go index fa19728b335e9..88ae500d828d6 100644 --- a/pkg/controller/volume/attachdetach/cache/actual_state_of_world_test.go +++ b/pkg/controller/volume/attachdetach/cache/actual_state_of_world_test.go @@ -1165,6 +1165,89 @@ func Test_updateNodeStatusUpdateNeededError(t *testing.T) { } } +// Test_RemoveNodeFromAttachUpdates_Positive expects an entire node entry to be removed +// from nodesToUpdateStatusFor +func Test_RemoveNodeFromAttachUpdates_Positive(t *testing.T) { + // Arrange + volumePluginMgr, _ := volumetesting.GetTestVolumePluginMgr(t) + asw := &actualStateOfWorld{ + attachedVolumes: make(map[v1.UniqueVolumeName]attachedVolume), + nodesToUpdateStatusFor: make(map[types.NodeName]nodeToUpdateStatusFor), + volumePluginMgr: volumePluginMgr, + } + nodeName := types.NodeName("node-1") + nodeToUpdate := nodeToUpdateStatusFor{ + nodeName: nodeName, + statusUpdateNeeded: true, + volumesToReportAsAttached: make(map[v1.UniqueVolumeName]v1.UniqueVolumeName), + } + asw.nodesToUpdateStatusFor[nodeName] = nodeToUpdate + + // Act + err := asw.RemoveNodeFromAttachUpdates(nodeName) + + // Assert + if err != nil { + t.Fatalf("RemoveNodeFromAttachUpdates should not return error, but got: %v", err) + } + if len(asw.nodesToUpdateStatusFor) > 0 { + t.Fatal("nodesToUpdateStatusFor should be empty as its only entry has been deleted.") + } +} + +// Test_RemoveNodeFromAttachUpdates_Negative_NodeDoesNotExist expects an error to be thrown +// when nodeName is not in nodesToUpdateStatusFor. +func Test_RemoveNodeFromAttachUpdates_Negative_NodeDoesNotExist(t *testing.T) { + // Arrange + volumePluginMgr, _ := volumetesting.GetTestVolumePluginMgr(t) + asw := &actualStateOfWorld{ + attachedVolumes: make(map[v1.UniqueVolumeName]attachedVolume), + nodesToUpdateStatusFor: make(map[types.NodeName]nodeToUpdateStatusFor), + volumePluginMgr: volumePluginMgr, + } + nodeName := types.NodeName("node-1") + nodeToUpdate := nodeToUpdateStatusFor{ + nodeName: nodeName, + statusUpdateNeeded: true, + volumesToReportAsAttached: make(map[v1.UniqueVolumeName]v1.UniqueVolumeName), + } + asw.nodesToUpdateStatusFor[nodeName] = nodeToUpdate + + // Act + err := asw.RemoveNodeFromAttachUpdates("node-2") + + // Assert + if err == nil { + t.Fatal("RemoveNodeFromAttachUpdates should return an error as the nodeName doesn't exist.") + } + if len(asw.nodesToUpdateStatusFor) != 1 { + t.Fatal("The length of nodesToUpdateStatusFor should not change because no operation was performed.") + } +} + +// Test_RemoveNodeFromAttachUpdates_Negative_Empty expects an error to be thrown +// when a nodesToUpdateStatusFor is empty. +func Test_RemoveNodeFromAttachUpdates_Negative_Empty(t *testing.T) { + // Arrange + volumePluginMgr, _ := volumetesting.GetTestVolumePluginMgr(t) + asw := &actualStateOfWorld{ + attachedVolumes: make(map[v1.UniqueVolumeName]attachedVolume), + nodesToUpdateStatusFor: make(map[types.NodeName]nodeToUpdateStatusFor), + volumePluginMgr: volumePluginMgr, + } + + // Act + err := asw.RemoveNodeFromAttachUpdates("node-1") + + // Assert + if err == nil { + t.Fatal("RemoveNodeFromAttachUpdates should return an error as nodeToUpdateStatusFor is empty.") + } + if len(asw.nodesToUpdateStatusFor) != 0 { + t.Fatal("The length of nodesToUpdateStatusFor should be 0.") + } +} + func verifyAttachedVolume( t *testing.T, attachedVolumes []AttachedVolume, diff --git a/pkg/controller/volume/attachdetach/statusupdater/BUILD b/pkg/controller/volume/attachdetach/statusupdater/BUILD index 566a01a18ebc8..88b3bc4bad62f 100644 --- a/pkg/controller/volume/attachdetach/statusupdater/BUILD +++ b/pkg/controller/volume/attachdetach/statusupdater/BUILD @@ -21,6 +21,7 @@ go_library( "//pkg/client/listers/core/v1:go_default_library", "//pkg/controller/volume/attachdetach/cache:go_default_library", "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/strategicpatch:go_default_library", ], ) diff --git a/pkg/controller/volume/attachdetach/statusupdater/node_status_updater.go b/pkg/controller/volume/attachdetach/statusupdater/node_status_updater.go index 7feaa01aa984b..cb62444e3c5c5 100644 --- a/pkg/controller/volume/attachdetach/statusupdater/node_status_updater.go +++ b/pkg/controller/volume/attachdetach/statusupdater/node_status_updater.go @@ -24,6 +24,7 @@ import ( "github.com/golang/glog" + "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/util/strategicpatch" "k8s.io/kubernetes/pkg/api" "k8s.io/kubernetes/pkg/api/v1" @@ -64,14 +65,20 @@ func (nsu *nodeStatusUpdater) UpdateNodeStatuses() error { nodesToUpdate := nsu.actualStateOfWorld.GetVolumesToReportAttached() for nodeName, attachedVolumes := range nodesToUpdate { nodeObj, err := nsu.nodeLister.Get(string(nodeName)) - if nodeObj == nil || err != nil { - // If node does not exist, its status cannot be updated, log error and - // reset flag statusUpdateNeeded back to true to indicate this node status - // needs to be updated again + if errors.IsNotFound(err) { + // If node does not exist, its status cannot be updated. + // Remove the node entry from the collection of attach updates, preventing the + // status updater from unnecessarily updating the node. glog.V(2).Infof( - "Could not update node status. Failed to find node %q in NodeInformer cache. %v", + "Could not update node status. Failed to find node %q in NodeInformer cache. Error: '%v'", nodeName, err) + nsu.actualStateOfWorld.RemoveNodeFromAttachUpdates(nodeName) + continue + } else if err != nil { + // For all other errors, log error and reset flag statusUpdateNeeded + // back to true to indicate this node status needs to be updated again. + glog.V(2).Infof("Error retrieving nodes from node lister. Error: %v", err) nsu.actualStateOfWorld.SetNodeStatusUpdateNeeded(nodeName) continue } diff --git a/pkg/controller/volume/events/BUILD b/pkg/controller/volume/events/BUILD new file mode 100644 index 0000000000000..bcca6b23aea4c --- /dev/null +++ b/pkg/controller/volume/events/BUILD @@ -0,0 +1,27 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["event.go"], + tags = ["automanaged"], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/controller/volume/events/event.go b/pkg/controller/volume/events/event.go new file mode 100644 index 0000000000000..b5ac3fb7be89a --- /dev/null +++ b/pkg/controller/volume/events/event.go @@ -0,0 +1,32 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package events + +const ( + // volume relevant event reasons + FailedBinding = "FailedBinding" + VolumeMismatch = "VolumeMismatch" + VolumeFailedRecycle = "VolumeFailedRecycle" + VolumeRecycled = "VolumeRecycled" + RecyclerPod = "RecyclerPod" + VolumeDelete = "VolumeDelete" + VolumeFailedDelete = "VolumeFailedDelete" + ExternalProvisioning = "ExternalProvisioning" + ProvisioningFailed = "ProvisioningFailed" + ProvisioningCleanupFailed = "ProvisioningCleanupFailed" + ProvisioningSucceeded = "ProvisioningSucceeded" +) diff --git a/pkg/controller/volume/persistentvolume/BUILD b/pkg/controller/volume/persistentvolume/BUILD index 4eb9a647ccf83..0d6da56ec02ca 100644 --- a/pkg/controller/volume/persistentvolume/BUILD +++ b/pkg/controller/volume/persistentvolume/BUILD @@ -30,6 +30,7 @@ go_library( "//pkg/client/listers/storage/v1:go_default_library", "//pkg/cloudprovider:go_default_library", "//pkg/controller:go_default_library", + "//pkg/controller/volume/events:go_default_library", "//pkg/util/goroutinemap:go_default_library", "//pkg/util/goroutinemap/exponentialbackoff:go_default_library", "//pkg/util/io:go_default_library", diff --git a/pkg/controller/volume/persistentvolume/pv_controller.go b/pkg/controller/volume/persistentvolume/pv_controller.go index 0b336711dc606..97ef17f6b7a05 100644 --- a/pkg/controller/volume/persistentvolume/pv_controller.go +++ b/pkg/controller/volume/persistentvolume/pv_controller.go @@ -35,6 +35,7 @@ import ( corelisters "k8s.io/kubernetes/pkg/client/listers/core/v1" storagelisters "k8s.io/kubernetes/pkg/client/listers/storage/v1" "k8s.io/kubernetes/pkg/cloudprovider" + "k8s.io/kubernetes/pkg/controller/volume/events" "k8s.io/kubernetes/pkg/util/goroutinemap" "k8s.io/kubernetes/pkg/util/goroutinemap/exponentialbackoff" vol "k8s.io/kubernetes/pkg/volume" @@ -268,7 +269,7 @@ func (ctrl *PersistentVolumeController) syncUnboundClaim(claim *v1.PersistentVol } // Mark the claim as Pending and try to find a match in the next // periodic syncClaim - ctrl.eventRecorder.Event(claim, v1.EventTypeNormal, "FailedBinding", "no persistent volumes available for this claim and no storage class is set") + ctrl.eventRecorder.Event(claim, v1.EventTypeNormal, events.FailedBinding, "no persistent volumes available for this claim and no storage class is set") if _, err = ctrl.updateClaimStatus(claim, v1.ClaimPending, nil); err != nil { return err } @@ -315,7 +316,7 @@ func (ctrl *PersistentVolumeController) syncUnboundClaim(claim *v1.PersistentVol if err = checkVolumeSatisfyClaim(volume, claim); err != nil { glog.V(4).Infof("Can't bind the claim to volume %q: %v", volume.Name, err) //send a event - ctrl.eventRecorder.Event(volume, v1.EventTypeWarning, "VolumeMismatch", "Volume's size is smaller than requested or volume's class does not match with claim") + ctrl.eventRecorder.Event(volume, v1.EventTypeWarning, events.VolumeMismatch, "Volume's size is smaller than requested or volume's class does not match with claim") //volume does not satisfy the requirements of the claim if _, err = ctrl.updateClaimStatus(claim, v1.ClaimPending, nil); err != nil { return err @@ -1029,7 +1030,7 @@ func (ctrl *PersistentVolumeController) recycleVolumeOperation(arg interface{}) plugin, err := ctrl.volumePluginMgr.FindRecyclablePluginBySpec(spec) if err != nil { // No recycler found. Emit an event and mark the volume Failed. - if _, err = ctrl.updateVolumePhaseWithEvent(volume, v1.VolumeFailed, v1.EventTypeWarning, "VolumeFailedRecycle", "No recycler plugin found for the volume!"); err != nil { + if _, err = ctrl.updateVolumePhaseWithEvent(volume, v1.VolumeFailed, v1.EventTypeWarning, events.VolumeFailedRecycle, "No recycler plugin found for the volume!"); err != nil { glog.V(4).Infof("recycleVolumeOperation [%s]: failed to mark volume as failed: %v", volume.Name, err) // Save failed, retry on the next deletion attempt return @@ -1045,7 +1046,7 @@ func (ctrl *PersistentVolumeController) recycleVolumeOperation(arg interface{}) if err = plugin.Recycle(volume.Name, spec, recorder); err != nil { // Recycler failed strerr := fmt.Sprintf("Recycle failed: %s", err) - if _, err = ctrl.updateVolumePhaseWithEvent(volume, v1.VolumeFailed, v1.EventTypeWarning, "VolumeFailedRecycle", strerr); err != nil { + if _, err = ctrl.updateVolumePhaseWithEvent(volume, v1.VolumeFailed, v1.EventTypeWarning, events.VolumeFailedRecycle, strerr); err != nil { glog.V(4).Infof("recycleVolumeOperation [%s]: failed to mark volume as failed: %v", volume.Name, err) // Save failed, retry on the next deletion attempt return @@ -1057,7 +1058,7 @@ func (ctrl *PersistentVolumeController) recycleVolumeOperation(arg interface{}) glog.V(2).Infof("volume %q recycled", volume.Name) // Send an event - ctrl.eventRecorder.Event(volume, v1.EventTypeNormal, "VolumeRecycled", "Volume recycled") + ctrl.eventRecorder.Event(volume, v1.EventTypeNormal, events.VolumeRecycled, "Volume recycled") // Make the volume available again if err = ctrl.unbindVolume(volume); err != nil { // Oops, could not save the volume and therefore the controller will @@ -1106,11 +1107,11 @@ func (ctrl *PersistentVolumeController) deleteVolumeOperation(arg interface{}) e if vol.IsDeletedVolumeInUse(err) { // The plugin needs more time, don't mark the volume as Failed // and send Normal event only - ctrl.eventRecorder.Event(volume, v1.EventTypeNormal, "VolumeDelete", err.Error()) + ctrl.eventRecorder.Event(volume, v1.EventTypeNormal, events.VolumeDelete, err.Error()) } else { // The plugin failed, mark the volume as Failed and send Warning // event - if _, err := ctrl.updateVolumePhaseWithEvent(volume, v1.VolumeFailed, v1.EventTypeWarning, "VolumeFailedDelete", err.Error()); err != nil { + if _, err := ctrl.updateVolumePhaseWithEvent(volume, v1.VolumeFailed, v1.EventTypeWarning, events.VolumeFailedDelete, err.Error()); err != nil { glog.V(4).Infof("deleteVolumeOperation [%s]: failed to mark volume as failed: %v", volume.Name, err) // Save failed, retry on the next deletion attempt return err @@ -1252,35 +1253,29 @@ func (ctrl *PersistentVolumeController) provisionClaimOperation(claimObj interfa plugin, storageClass, err := ctrl.findProvisionablePlugin(claim) if err != nil { - ctrl.eventRecorder.Event(claim, v1.EventTypeWarning, "ProvisioningFailed", err.Error()) + ctrl.eventRecorder.Event(claim, v1.EventTypeWarning, events.ProvisioningFailed, err.Error()) glog.V(2).Infof("error finding provisioning plugin for claim %s: %v", claimToClaimKey(claim), err) // The controller will retry provisioning the volume in every // syncVolume() call. return } - if storageClass != nil { - // Add provisioner annotation so external provisioners know when to start - newClaim, err := ctrl.setClaimProvisioner(claim, storageClass) - if err != nil { - // Save failed, the controller will retry in the next sync - glog.V(2).Infof("error saving claim %s: %v", claimToClaimKey(claim), err) - return - } - claim = newClaim + // Add provisioner annotation so external provisioners know when to start + newClaim, err := ctrl.setClaimProvisioner(claim, storageClass) + if err != nil { + // Save failed, the controller will retry in the next sync + glog.V(2).Infof("error saving claim %s: %v", claimToClaimKey(claim), err) + return } + claim = newClaim if plugin == nil { // findProvisionablePlugin returned no error nor plugin. // This means that an unknown provisioner is requested. Report an event // and wait for the external provisioner - if storageClass != nil { - msg := fmt.Sprintf("waiting for a volume to be created, either by external provisioner %q or manually created by system administrator", storageClass.Provisioner) - ctrl.eventRecorder.Event(claim, v1.EventTypeNormal, "ExternalProvisioning", msg) - glog.V(3).Infof("provisioning claim %q: %s", claimToClaimKey(claim), msg) - } else { - glog.V(3).Infof("cannot find storage class for claim %q", claimToClaimKey(claim)) - } + msg := fmt.Sprintf("waiting for a volume to be created, either by external provisioner %q or manually created by system administrator", storageClass.Provisioner) + ctrl.eventRecorder.Event(claim, v1.EventTypeNormal, events.ExternalProvisioning, msg) + glog.V(3).Infof("provisioning claim %q: %s", claimToClaimKey(claim), msg) return } @@ -1326,7 +1321,7 @@ func (ctrl *PersistentVolumeController) provisionClaimOperation(claimObj interfa if err != nil { strerr := fmt.Sprintf("Failed to create provisioner: %v", err) glog.V(2).Infof("failed to create provisioner for claim %q with StorageClass %q: %v", claimToClaimKey(claim), storageClass.Name, err) - ctrl.eventRecorder.Event(claim, v1.EventTypeWarning, "ProvisioningFailed", strerr) + ctrl.eventRecorder.Event(claim, v1.EventTypeWarning, events.ProvisioningFailed, strerr) return } @@ -1334,7 +1329,7 @@ func (ctrl *PersistentVolumeController) provisionClaimOperation(claimObj interfa if err != nil { strerr := fmt.Sprintf("Failed to provision volume with StorageClass %q: %v", storageClass.Name, err) glog.V(2).Infof("failed to provision volume for claim %q with StorageClass %q: %v", claimToClaimKey(claim), storageClass.Name, err) - ctrl.eventRecorder.Event(claim, v1.EventTypeWarning, "ProvisioningFailed", strerr) + ctrl.eventRecorder.Event(claim, v1.EventTypeWarning, events.ProvisioningFailed, strerr) return } @@ -1380,7 +1375,7 @@ func (ctrl *PersistentVolumeController) provisionClaimOperation(claimObj interfa // times. strerr := fmt.Sprintf("Error creating provisioned PV object for claim %s: %v. Deleting the volume.", claimToClaimKey(claim), err) glog.V(3).Info(strerr) - ctrl.eventRecorder.Event(claim, v1.EventTypeWarning, "ProvisioningFailed", strerr) + ctrl.eventRecorder.Event(claim, v1.EventTypeWarning, events.ProvisioningFailed, strerr) var deleteErr error var deleted bool @@ -1408,12 +1403,12 @@ func (ctrl *PersistentVolumeController) provisionClaimOperation(claimObj interfa // is nothing we can do about it. strerr := fmt.Sprintf("Error cleaning provisioned volume for claim %s: %v. Please delete manually.", claimToClaimKey(claim), deleteErr) glog.V(2).Info(strerr) - ctrl.eventRecorder.Event(claim, v1.EventTypeWarning, "ProvisioningCleanupFailed", strerr) + ctrl.eventRecorder.Event(claim, v1.EventTypeWarning, events.ProvisioningCleanupFailed, strerr) } } else { glog.V(2).Infof("volume %q provisioned for claim %q", volume.Name, claimToClaimKey(claim)) msg := fmt.Sprintf("Successfully provisioned volume %s using %s", volume.Name, plugin.GetPluginName()) - ctrl.eventRecorder.Event(claim, v1.EventTypeNormal, "ProvisioningSucceeded", msg) + ctrl.eventRecorder.Event(claim, v1.EventTypeNormal, events.ProvisioningSucceeded, msg) } } @@ -1450,7 +1445,7 @@ func (ctrl *PersistentVolumeController) scheduleOperation(operationName string, // to given volume. func (ctrl *PersistentVolumeController) newRecyclerEventRecorder(volume *v1.PersistentVolume) vol.RecycleEventRecorder { return func(eventtype, message string) { - ctrl.eventRecorder.Eventf(volume, eventtype, "RecyclerPod", "Recycler pod: %s", message) + ctrl.eventRecorder.Eventf(volume, eventtype, events.RecyclerPod, "Recycler pod: %s", message) } } diff --git a/pkg/controller/volume/persistentvolume/volume_host.go b/pkg/controller/volume/persistentvolume/volume_host.go index c495c00215927..f545f54639153 100644 --- a/pkg/controller/volume/persistentvolume/volume_host.go +++ b/pkg/controller/volume/persistentvolume/volume_host.go @@ -86,3 +86,13 @@ func (adc *PersistentVolumeController) GetSecretFunc() func(namespace, name stri return nil, fmt.Errorf("GetSecret unsupported in PersistentVolumeController") } } + +func (adc *PersistentVolumeController) GetConfigMapFunc() func(namespace, name string) (*v1.ConfigMap, error) { + return func(_, _ string) (*v1.ConfigMap, error) { + return nil, fmt.Errorf("GetConfigMap unsupported in PersistentVolumeController") + } +} + +func (ctrl *PersistentVolumeController) GetNodeLabels() (map[string]string, error) { + return nil, fmt.Errorf("GetNodeLabels() unsupported in PersistentVolumeController") +} diff --git a/pkg/features/kube_features.go b/pkg/features/kube_features.go index c325bb0c43e15..3e6828f69e06e 100644 --- a/pkg/features/kube_features.go +++ b/pkg/features/kube_features.go @@ -25,8 +25,8 @@ const ( // Every feature gate should add method here following this template: // // // owner: @username - // // alpha: v1.4 - // MyFeature() bool + // // alpha: v1.X + // MyFeature utilfeature.Feature = "MyFeature" // owner: @timstclair // beta: v1.4 @@ -89,11 +89,25 @@ const ( // to take advantage of NoExecute Taints and Tolerations. TaintBasedEvictions utilfeature.Feature = "TaintBasedEvictions" + // owner: @jcbsmpsn + // alpha: v1.7 + // + // Gets a server certificate for the kubelet from the Certificate Signing + // Request API instead of generating one self signed and auto rotates the + // certificate as expiration approaches. + RotateKubeletServerCertificate utilfeature.Feature = "RotateKubeletServerCertificate" + // owner: @msau // alpha: v1.7 // // A new volume type that supports local disks on a node. PersistentLocalVolumes utilfeature.Feature = "PersistentLocalVolumes" + + // owner: @jinxu + // alpha: v1.7 + // + // New local storage types to support local storage capacity isolation + LocalStorageCapacityIsolation utilfeature.Feature = "LocalStorageCapacityIsolation" ) func init() { @@ -113,9 +127,12 @@ var defaultKubernetesFeatureGates = map[utilfeature.Feature]utilfeature.FeatureS AffinityInAnnotations: {Default: false, PreRelease: utilfeature.Alpha}, Accelerators: {Default: false, PreRelease: utilfeature.Alpha}, TaintBasedEvictions: {Default: false, PreRelease: utilfeature.Alpha}, + RotateKubeletServerCertificate: {Default: false, PreRelease: utilfeature.Alpha}, PersistentLocalVolumes: {Default: false, PreRelease: utilfeature.Alpha}, + LocalStorageCapacityIsolation: {Default: false, PreRelease: utilfeature.Alpha}, // inherited features from generic apiserver, relisted here to get a conflict if it is changed // unintentionally on either side: - StreamingProxyRedirects: {Default: true, PreRelease: utilfeature.Beta}, + StreamingProxyRedirects: {Default: true, PreRelease: utilfeature.Beta}, + genericfeatures.AdvancedAuditing: {Default: false, PreRelease: utilfeature.Alpha}, } diff --git a/pkg/generated/openapi/BUILD b/pkg/generated/openapi/BUILD index 49d8ce308805f..269878c27d865 100644 --- a/pkg/generated/openapi/BUILD +++ b/pkg/generated/openapi/BUILD @@ -14,6 +14,7 @@ openapi_library( "pkg/apis/abac/v0", "pkg/apis/abac/v1beta1", "pkg/apis/admission/v1alpha1", + "pkg/apis/admissionregistration/v1alpha1", "pkg/apis/apps/v1beta1", "pkg/apis/authentication/v1", "pkg/apis/authentication/v1beta1", @@ -27,6 +28,7 @@ openapi_library( "pkg/apis/componentconfig/v1alpha1", "pkg/apis/extensions/v1beta1", "pkg/apis/imagepolicy/v1alpha1", + "pkg/apis/networking/v1", "pkg/apis/policy/v1beta1", "pkg/apis/rbac/v1alpha1", "pkg/apis/rbac/v1beta1", diff --git a/pkg/kubeapiserver/admission/BUILD b/pkg/kubeapiserver/admission/BUILD index 333d3f76e4c2e..a55bf4ec166bd 100644 --- a/pkg/kubeapiserver/admission/BUILD +++ b/pkg/kubeapiserver/admission/BUILD @@ -42,6 +42,9 @@ filegroup( filegroup( name = "all-srcs", - srcs = [":package-srcs"], + srcs = [ + ":package-srcs", + "//pkg/kubeapiserver/admission/configuration:all-srcs", + ], tags = ["automanaged"], ) diff --git a/pkg/kubeapiserver/admission/configuration/BUILD b/pkg/kubeapiserver/admission/configuration/BUILD new file mode 100644 index 0000000000000..d557d01dff7e3 --- /dev/null +++ b/pkg/kubeapiserver/admission/configuration/BUILD @@ -0,0 +1,49 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["initializer_manager_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "configuration_manager.go", + "external_admission_hook_manager.go", + "initializer_manager.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/kubeapiserver/admission/configuration/configuration_manager.go b/pkg/kubeapiserver/admission/configuration/configuration_manager.go new file mode 100644 index 0000000000000..cce198ec4d92e --- /dev/null +++ b/pkg/kubeapiserver/admission/configuration/configuration_manager.go @@ -0,0 +1,100 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package configuration + +import ( + "fmt" + "sync" + "time" + + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/wait" +) + +const ( + defaultInterval = 1 * time.Second + defaultFailureThreshold = 5 +) + +type getFunc func() (runtime.Object, error) + +// When running, poller calls `get` every `interval`. If `get` is +// successful, `Ready()` returns ready and `configuration()` returns the +// `mergedConfiguration`; if `get` has failed more than `failureThreshold ` times, +// `Ready()` returns not ready and `configuration()` returns nil configuration. +// In an HA setup, the poller is consistent only if the `get` is +// doing consistent read. +type poller struct { + // a function to consistently read the latest configuration + get getFunc + // consistent read interval + interval time.Duration + // if the number of consecutive read failure equals or exceeds the failureThreshold , the + // configuration is regarded as not ready. + failureThreshold int + // if the configuration is regarded as ready. + ready bool + mergedConfiguration runtime.Object + // lock much be hold when reading ready or mergedConfiguration + lock sync.RWMutex +} + +func newPoller(get getFunc) *poller { + return &poller{ + get: get, + interval: defaultInterval, + failureThreshold: defaultFailureThreshold, + } +} + +func (a *poller) notReady() { + a.lock.Lock() + defer a.lock.Unlock() + a.ready = false +} + +func (a *poller) configuration() (runtime.Object, error) { + a.lock.RLock() + defer a.lock.RUnlock() + if !a.ready { + return nil, fmt.Errorf("configuration is not ready") + } + return a.mergedConfiguration, nil +} + +func (a *poller) setConfigurationAndReady(value runtime.Object) { + a.lock.Lock() + defer a.lock.Unlock() + a.mergedConfiguration = value + a.ready = true +} + +func (a *poller) Run(stopCh <-chan struct{}) { + var failure int + go wait.Until(func() { + configuration, err := a.get() + if err != nil { + failure++ + if failure >= a.failureThreshold { + a.notReady() + } + return + } + failure = 0 + a.setConfigurationAndReady(configuration) + }, a.interval, stopCh) +} diff --git a/pkg/kubeapiserver/admission/configuration/external_admission_hook_manager.go b/pkg/kubeapiserver/admission/configuration/external_admission_hook_manager.go new file mode 100644 index 0000000000000..56faf029f0c88 --- /dev/null +++ b/pkg/kubeapiserver/admission/configuration/external_admission_hook_manager.go @@ -0,0 +1,71 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package configuration + +import ( + "fmt" + "reflect" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" +) + +type ExternalAdmissionHookConfigurationLister interface { + List(opts metav1.ListOptions) (*v1alpha1.ExternalAdmissionHookConfigurationList, error) +} + +type ExternalAdmissionHookConfigurationManager struct { + *poller +} + +// ExternalAdmissionHooks returns the merged ExternalAdmissionHookConfiguration. +func (im *ExternalAdmissionHookConfigurationManager) ExternalAdmissionHooks() (*v1alpha1.ExternalAdmissionHookConfiguration, error) { + configuration, err := im.poller.configuration() + if err != nil { + return nil, err + } + externalAdmissionHookConfiguration, ok := configuration.(*v1alpha1.ExternalAdmissionHookConfiguration) + if !ok { + return nil, fmt.Errorf("expected type %v, got type %v", reflect.TypeOf(externalAdmissionHookConfiguration), reflect.TypeOf(configuration)) + } + return externalAdmissionHookConfiguration, nil +} + +func NewExternalAdmissionHookConfigurationManager(c ExternalAdmissionHookConfigurationLister) *ExternalAdmissionHookConfigurationManager { + getFn := func() (runtime.Object, error) { + list, err := c.List(metav1.ListOptions{}) + if err != nil { + return nil, err + } + return mergeExternalAdmissionHookConfigurations(list), nil + } + + return &ExternalAdmissionHookConfigurationManager{ + newPoller(getFn)} +} + +func mergeExternalAdmissionHookConfigurations( + list *v1alpha1.ExternalAdmissionHookConfigurationList, +) *v1alpha1.ExternalAdmissionHookConfiguration { + configurations := list.Items + var ret v1alpha1.ExternalAdmissionHookConfiguration + for _, c := range configurations { + ret.ExternalAdmissionHooks = append(ret.ExternalAdmissionHooks, c.ExternalAdmissionHooks...) + } + return &ret +} diff --git a/pkg/kubeapiserver/admission/configuration/initializer_manager.go b/pkg/kubeapiserver/admission/configuration/initializer_manager.go new file mode 100644 index 0000000000000..eba763f943b0d --- /dev/null +++ b/pkg/kubeapiserver/admission/configuration/initializer_manager.go @@ -0,0 +1,76 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package configuration + +import ( + "fmt" + "reflect" + "sort" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" +) + +type InitializerConfigurationLister interface { + List(opts metav1.ListOptions) (*v1alpha1.InitializerConfigurationList, error) +} + +type InitializerConfigurationManager struct { + *poller +} + +// Initializers returns the merged InitializerConfiguration. +func (im *InitializerConfigurationManager) Initializers() (*v1alpha1.InitializerConfiguration, error) { + configuration, err := im.poller.configuration() + if err != nil { + return nil, err + } + initializerConfiguration, ok := configuration.(*v1alpha1.InitializerConfiguration) + if !ok { + return nil, fmt.Errorf("expected type %v, got type %v", reflect.TypeOf(initializerConfiguration), reflect.TypeOf(configuration)) + } + return initializerConfiguration, nil +} + +func NewInitializerConfigurationManager(c InitializerConfigurationLister) *InitializerConfigurationManager { + getFn := func() (runtime.Object, error) { + list, err := c.List(metav1.ListOptions{}) + if err != nil { + return nil, err + } + return mergeInitializerConfigurations(list), nil + } + return &InitializerConfigurationManager{ + newPoller(getFn)} +} + +func mergeInitializerConfigurations(initializerConfigurationList *v1alpha1.InitializerConfigurationList) *v1alpha1.InitializerConfiguration { + configurations := initializerConfigurationList.Items + sort.SliceStable(configurations, InitializerConfigurationSorter(configurations).ByName) + var ret v1alpha1.InitializerConfiguration + for _, c := range configurations { + ret.Initializers = append(ret.Initializers, c.Initializers...) + } + return &ret +} + +type InitializerConfigurationSorter []v1alpha1.InitializerConfiguration + +func (a InitializerConfigurationSorter) ByName(i, j int) bool { + return a[i].Name < a[j].Name +} diff --git a/pkg/kubeapiserver/admission/configuration/initializer_manager_test.go b/pkg/kubeapiserver/admission/configuration/initializer_manager_test.go new file mode 100644 index 0000000000000..7f6bfd235062f --- /dev/null +++ b/pkg/kubeapiserver/admission/configuration/initializer_manager_test.go @@ -0,0 +1,171 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package configuration + +import ( + "fmt" + "reflect" + "testing" + "time" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" +) + +type mockLister struct { + invoked int + successes int + failures int + stopCh chan struct{} + configurationList v1alpha1.InitializerConfigurationList + t *testing.T +} + +func newMockLister(successes, failures int, configurationList v1alpha1.InitializerConfigurationList, t *testing.T) *mockLister { + return &mockLister{ + failures: failures, + successes: successes, + configurationList: configurationList, + stopCh: make(chan struct{}), + t: t, + } +} + +// The first List will be successful; the next m.failures List will +// fail; the next m.successes List will be successful; the stopCh is closed at +// the 1+m.failures+m.successes call. +func (m *mockLister) List(options metav1.ListOptions) (*v1alpha1.InitializerConfigurationList, error) { + m.invoked++ + // m.successes could be 0, so call this `if` first. + if m.invoked == 1+m.failures+m.successes { + close(m.stopCh) + } + if m.invoked == 1 { + return &m.configurationList, nil + } + if m.invoked <= 1+m.failures { + return nil, fmt.Errorf("some error") + } + if m.invoked <= 1+m.failures+m.successes { + return &m.configurationList, nil + } + m.t.Fatalf("unexpected call to List, stopCh has been closed at the %d time call", 1+m.successes+m.failures) + return nil, nil +} + +var _ InitializerConfigurationLister = &mockLister{} + +func TestConfiguration(t *testing.T) { + cases := []struct { + name string + failures int + // note that the first call to mockLister is always a success. + successes int + expectReady bool + }{ + { + name: "number of failures hasn't reached failureThreshold", + failures: defaultFailureThreshold - 1, + expectReady: true, + }, + { + name: "number of failures just reaches failureThreshold", + failures: defaultFailureThreshold, + expectReady: false, + }, + { + name: "number of failures exceeds failureThreshold", + failures: defaultFailureThreshold + 1, + expectReady: false, + }, + { + name: "number of failures exceeds failureThreshold, but then get another success", + failures: defaultFailureThreshold + 1, + successes: 1, + expectReady: true, + }, + } + for _, c := range cases { + mock := newMockLister(c.successes, c.failures, v1alpha1.InitializerConfigurationList{}, t) + manager := NewInitializerConfigurationManager(mock) + manager.interval = 1 * time.Millisecond + manager.Run(mock.stopCh) + <-mock.stopCh + _, err := manager.Initializers() + if err != nil && c.expectReady { + t.Errorf("case %s, expect ready, got: %v", c.name, err) + } + if err == nil && !c.expectReady { + t.Errorf("case %s, expect not ready", c.name) + } + } +} + +func TestMergeInitializerConfigurations(t *testing.T) { + configurationsList := v1alpha1.InitializerConfigurationList{ + Items: []v1alpha1.InitializerConfiguration{ + { + ObjectMeta: metav1.ObjectMeta{ + Name: "provider_2", + }, + Initializers: []v1alpha1.Initializer{ + { + Name: "initializer_a", + }, + { + Name: "initializer_b", + }, + }, + }, + { + ObjectMeta: metav1.ObjectMeta{ + Name: "provider_1", + }, + Initializers: []v1alpha1.Initializer{ + { + Name: "initializer_c", + }, + { + Name: "initializer_d", + }, + }, + }, + }, + } + + expected := &v1alpha1.InitializerConfiguration{ + Initializers: []v1alpha1.Initializer{ + { + Name: "initializer_c", + }, + { + Name: "initializer_d", + }, + { + Name: "initializer_a", + }, + { + Name: "initializer_b", + }, + }, + } + + got := mergeInitializerConfigurations(&configurationsList) + if !reflect.DeepEqual(got, expected) { + t.Errorf("expected: %#v, got: %#v", expected, got) + } +} diff --git a/pkg/kubeapiserver/authorizer/BUILD b/pkg/kubeapiserver/authorizer/BUILD index 3970871031070..95d4851d0140d 100644 --- a/pkg/kubeapiserver/authorizer/BUILD +++ b/pkg/kubeapiserver/authorizer/BUILD @@ -26,10 +26,13 @@ go_library( deps = [ "//pkg/apis/rbac:go_default_library", "//pkg/auth/authorizer/abac:go_default_library", + "//pkg/auth/nodeidentifier:go_default_library", "//pkg/client/informers/informers_generated/internalversion:go_default_library", "//pkg/client/listers/rbac/internalversion:go_default_library", "//pkg/kubeapiserver/authorizer/modes:go_default_library", + "//plugin/pkg/auth/authorizer/node:go_default_library", "//plugin/pkg/auth/authorizer/rbac:go_default_library", + "//plugin/pkg/auth/authorizer/rbac/bootstrappolicy:go_default_library", "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", "//vendor/k8s.io/apiserver/pkg/authorization/authorizer:go_default_library", "//vendor/k8s.io/apiserver/pkg/authorization/authorizerfactory:go_default_library", diff --git a/pkg/kubeapiserver/authorizer/config.go b/pkg/kubeapiserver/authorizer/config.go index 5f5a8a7410786..ca275dd4db705 100644 --- a/pkg/kubeapiserver/authorizer/config.go +++ b/pkg/kubeapiserver/authorizer/config.go @@ -28,10 +28,13 @@ import ( "k8s.io/apiserver/plugin/pkg/authorizer/webhook" rbacapi "k8s.io/kubernetes/pkg/apis/rbac" "k8s.io/kubernetes/pkg/auth/authorizer/abac" + "k8s.io/kubernetes/pkg/auth/nodeidentifier" informers "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion" rbaclisters "k8s.io/kubernetes/pkg/client/listers/rbac/internalversion" "k8s.io/kubernetes/pkg/kubeapiserver/authorizer/modes" + "k8s.io/kubernetes/plugin/pkg/auth/authorizer/node" "k8s.io/kubernetes/plugin/pkg/auth/authorizer/rbac" + "k8s.io/kubernetes/plugin/pkg/auth/authorizer/rbac/bootstrappolicy" ) type AuthorizationConfig struct { @@ -51,11 +54,6 @@ type AuthorizationConfig struct { // TTL for caching of unauthorized responses from the webhook server. WebhookCacheUnauthorizedTTL time.Duration - // Options for RBAC - - // User which can bootstrap role policies - RBACSuperUser string - InformerFactory informers.SharedInformerFactory } @@ -107,6 +105,19 @@ func (config AuthorizationConfig) New() (authorizer.Authorizer, error) { } // Keep cases in sync with constant list above. switch authorizationMode { + case modes.ModeNode: + graph := node.NewGraph() + node.AddGraphEventHandlers( + graph, + config.InformerFactory.Core().InternalVersion().Pods(), + config.InformerFactory.Core().InternalVersion().PersistentVolumes(), + ) + nodeAuthorizer := node.NewAuthorizer(graph, nodeidentifier.NewDefaultNodeIdentifier(), bootstrappolicy.NodeRules()) + authorizers = append(authorizers, nodeAuthorizer) + + // Don't bind system:nodes to the system:node role + bootstrappolicy.AddClusterRoleBindingFilter(bootstrappolicy.OmitNodesGroupBinding) + case modes.ModeAlwaysAllow: authorizers = append(authorizers, authorizerfactory.NewAlwaysAllowAuthorizer()) case modes.ModeAlwaysDeny: @@ -151,9 +162,6 @@ func (config AuthorizationConfig) New() (authorizer.Authorizer, error) { if !authorizerMap[modes.ModeWebhook] && config.WebhookConfigFile != "" { return nil, errors.New("Cannot specify --authorization-webhook-config-file without mode Webhook") } - if !authorizerMap[modes.ModeRBAC] && config.RBACSuperUser != "" { - return nil, errors.New("Cannot specify --authorization-rbac-super-user without mode RBAC") - } return union.New(authorizers...), nil } diff --git a/pkg/kubeapiserver/authorizer/modes/modes.go b/pkg/kubeapiserver/authorizer/modes/modes.go index 0d2c2442090a7..56a708a6b1d53 100644 --- a/pkg/kubeapiserver/authorizer/modes/modes.go +++ b/pkg/kubeapiserver/authorizer/modes/modes.go @@ -22,9 +22,10 @@ const ( ModeABAC string = "ABAC" ModeWebhook string = "Webhook" ModeRBAC string = "RBAC" + ModeNode string = "Node" ) -var AuthorizationModeChoices = []string{ModeAlwaysAllow, ModeAlwaysDeny, ModeABAC, ModeWebhook, ModeRBAC} +var AuthorizationModeChoices = []string{ModeAlwaysAllow, ModeAlwaysDeny, ModeABAC, ModeWebhook, ModeRBAC, ModeNode} // IsValidAuthorizationMode returns true if the given authorization mode is a valid one for the apiserver func IsValidAuthorizationMode(authzMode string) bool { diff --git a/pkg/kubeapiserver/server/BUILD b/pkg/kubeapiserver/server/BUILD index 82c48fa032981..0c6f4c43221d0 100644 --- a/pkg/kubeapiserver/server/BUILD +++ b/pkg/kubeapiserver/server/BUILD @@ -16,8 +16,10 @@ go_library( "//vendor/k8s.io/apiserver/pkg/authentication/user:go_default_library", "//vendor/k8s.io/apiserver/pkg/endpoints/filters:go_default_library", "//vendor/k8s.io/apiserver/pkg/endpoints/request:go_default_library", + "//vendor/k8s.io/apiserver/pkg/features:go_default_library", "//vendor/k8s.io/apiserver/pkg/server:go_default_library", "//vendor/k8s.io/apiserver/pkg/server/filters:go_default_library", + "//vendor/k8s.io/apiserver/pkg/util/feature:go_default_library", "//vendor/k8s.io/client-go/rest:go_default_library", ], ) diff --git a/pkg/kubeapiserver/server/insecure_handler.go b/pkg/kubeapiserver/server/insecure_handler.go index 2e8eee2eb7fef..24127f546a896 100644 --- a/pkg/kubeapiserver/server/insecure_handler.go +++ b/pkg/kubeapiserver/server/insecure_handler.go @@ -25,8 +25,10 @@ import ( "k8s.io/apiserver/pkg/authentication/user" genericapifilters "k8s.io/apiserver/pkg/endpoints/filters" apirequest "k8s.io/apiserver/pkg/endpoints/request" + "k8s.io/apiserver/pkg/features" "k8s.io/apiserver/pkg/server" genericfilters "k8s.io/apiserver/pkg/server/filters" + utilfeature "k8s.io/apiserver/pkg/util/feature" "k8s.io/client-go/rest" ) @@ -35,7 +37,12 @@ import ( // InsecureServingInfo *ServingInfo func BuildInsecureHandlerChain(apiHandler http.Handler, c *server.Config) http.Handler { - handler := genericapifilters.WithAudit(apiHandler, c.RequestContextMapper, c.AuditBackend, c.AuditPolicy, c.LongRunningFunc) + handler := apiHandler + if utilfeature.DefaultFeatureGate.Enabled(features.AdvancedAuditing) { + handler = genericapifilters.WithAudit(handler, c.RequestContextMapper, c.AuditBackend, c.AuditPolicyChecker, c.LongRunningFunc) + } else { + handler = genericapifilters.WithLegacyAudit(handler, c.RequestContextMapper, c.LegacyAuditWriter) + } handler = genericapifilters.WithAuthentication(handler, c.RequestContextMapper, insecureSuperuser{}, nil) handler = genericfilters.WithCORS(handler, c.CorsAllowedOriginList, nil, nil, nil, "true") handler = genericfilters.WithPanicRecovery(handler) diff --git a/pkg/kubectl/cmd/BUILD b/pkg/kubectl/cmd/BUILD index f220998f16a49..8e8e119b5af33 100644 --- a/pkg/kubectl/cmd/BUILD +++ b/pkg/kubectl/cmd/BUILD @@ -12,6 +12,7 @@ go_library( "annotate.go", "apiversions.go", "apply.go", + "apply_edit_last_applied.go", "apply_set_last_applied.go", "apply_view_last_applied.go", "attach.go", diff --git a/pkg/kubectl/cmd/apply.go b/pkg/kubectl/cmd/apply.go index 7ec30a461fd7a..7b8ccb76a9673 100644 --- a/pkg/kubectl/cmd/apply.go +++ b/pkg/kubectl/cmd/apply.go @@ -131,6 +131,7 @@ func NewCmdApply(f cmdutil.Factory, out, errOut io.Writer) *cobra.Command { // apply subcommands cmd.AddCommand(NewCmdApplyViewLastApplied(f, out, errOut)) cmd.AddCommand(NewCmdApplySetLastApplied(f, out, errOut)) + cmd.AddCommand(NewCmdApplyEditLastApplied(f, out, errOut)) return cmd } diff --git a/pkg/kubectl/cmd/apply_edit_last_applied.go b/pkg/kubectl/cmd/apply_edit_last_applied.go new file mode 100644 index 0000000000000..fcf4201d00535 --- /dev/null +++ b/pkg/kubectl/cmd/apply_edit_last_applied.go @@ -0,0 +1,103 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package cmd + +import ( + "io" + gruntime "runtime" + + "github.com/spf13/cobra" + + "k8s.io/kubernetes/pkg/kubectl" + "k8s.io/kubernetes/pkg/kubectl/cmd/templates" + cmdutil "k8s.io/kubernetes/pkg/kubectl/cmd/util" + "k8s.io/kubernetes/pkg/kubectl/cmd/util/editor" + "k8s.io/kubernetes/pkg/printers" +) + +var ( + applyEditLastAppliedLong = templates.LongDesc(` + Edit the latest last-applied-configuration annotations of resources from the default editor. + + The edit-last-applied command allows you to directly edit any API resource you can retrieve via the + command line tools. It will open the editor defined by your KUBE_EDITOR, or EDITOR + environment variables, or fall back to 'vi' for Linux or 'notepad' for Windows. + You can edit multiple objects, although changes are applied one at a time. The command + accepts filenames as well as command line arguments, although the files you point to must + be previously saved versions of resources. + + The default format is YAML. To edit in JSON, specify "-o json". + + The flag --windows-line-endings can be used to force Windows line endings, + otherwise the default for your operating system will be used. + + In the event an error occurs while updating, a temporary file will be created on disk + that contains your unapplied changes. The most common error when updating a resource + is another editor changing the resource on the server. When this occurs, you will have + to apply your changes to the newer version of the resource, or update your temporary + saved copy to include the latest resource version.`) + + applyEditLastAppliedExample = templates.Examples(` + # Edit the last-applied-configuration annotations by type/name in YAML. + kubectl apply edit-last-applied deployment/nginx + + # Edit the last-applied-configuration annotations by file in JSON. + kubectl apply edit-last-applied -f deploy.yaml -o json`) +) + +func NewCmdApplyEditLastApplied(f cmdutil.Factory, out, errOut io.Writer) *cobra.Command { + options := &editor.EditOptions{ + EditMode: editor.ApplyEditMode, + } + + // retrieve a list of handled resources from printer as valid args + validArgs, argAliases := []string{}, []string{} + p, err := f.Printer(nil, printers.PrintOptions{ + ColumnLabels: []string{}, + }) + cmdutil.CheckErr(err) + if p != nil { + validArgs = p.HandledResources() + argAliases = kubectl.ResourceAliases(validArgs) + } + + cmd := &cobra.Command{ + Use: "edit-last-applied (RESOURCE/NAME | -f FILENAME)", + Short: "Edit latest last-applied-configuration annotations of a resource/object", + Long: applyEditLastAppliedLong, + Example: applyEditLastAppliedExample, + Run: func(cmd *cobra.Command, args []string) { + options.ChangeCause = f.Command(cmd, false) + if err := options.Complete(f, out, errOut, args); err != nil { + cmdutil.CheckErr(err) + } + if err := options.Run(); err != nil { + cmdutil.CheckErr(err) + } + }, + ValidArgs: validArgs, + ArgAliases: argAliases, + } + + usage := "to use to edit the resource" + cmdutil.AddFilenameOptionFlags(cmd, &options.FilenameOptions, usage) + cmd.Flags().StringVarP(&options.Output, "output", "o", "yaml", "Output format. One of: yaml|json.") + cmd.Flags().BoolVar(&options.WindowsLineEndings, "windows-line-endings", gruntime.GOOS == "windows", "Use Windows line-endings (default Unix line-endings)") + cmdutil.AddRecordVarFlag(cmd, &options.Record) + + return cmd +} diff --git a/pkg/kubectl/cmd/apply_set_last_applied.go b/pkg/kubectl/cmd/apply_set_last_applied.go index 09b8b9e6e8674..6f7ccbf4a841c 100644 --- a/pkg/kubectl/cmd/apply_set_last_applied.go +++ b/pkg/kubectl/cmd/apply_set_last_applied.go @@ -35,6 +35,7 @@ import ( "k8s.io/kubernetes/pkg/kubectl" "k8s.io/kubernetes/pkg/kubectl/cmd/templates" cmdutil "k8s.io/kubernetes/pkg/kubectl/cmd/util" + "k8s.io/kubernetes/pkg/kubectl/cmd/util/editor" "k8s.io/kubernetes/pkg/kubectl/resource" "k8s.io/kubernetes/pkg/util/i18n" ) @@ -52,12 +53,17 @@ type SetLastAppliedOptions struct { CreateAnnotation bool Output string Codec runtime.Encoder - PatchBufferList [][]byte + PatchBufferList []PatchBuffer Factory cmdutil.Factory Out io.Writer ErrOut io.Writer } +type PatchBuffer struct { + Patch []byte + PatchType types.PatchType +} + var ( applySetLastAppliedLong = templates.LongDesc(i18n.T(` Set the latest last-applied-configuration annotations by setting it to match the contents of a file. @@ -137,8 +143,7 @@ func (o *SetLastAppliedOptions) Validate(f cmdutil.Factory, cmd *cobra.Command) return err } - var diffBuf, patchBuf []byte - patchBuf, diffBuf, err = o.getPatch(info) + patchBuf, diffBuf, patchType, err := editor.GetApplyPatch(info.VersionedObject, o.Codec) if err != nil { return err } @@ -161,7 +166,8 @@ func (o *SetLastAppliedOptions) Validate(f cmdutil.Factory, cmd *cobra.Command) //only add to PatchBufferList when changed if !bytes.Equal(cmdutil.StripComments(oringalBuf), cmdutil.StripComments(diffBuf)) { - o.PatchBufferList = append(o.PatchBufferList, patchBuf) + p := PatchBuffer{Patch: patchBuf, PatchType: patchType} + o.PatchBufferList = append(o.PatchBufferList, p) o.InfoList = append(o.InfoList, info) } else { fmt.Fprintf(o.Out, "set-last-applied %s: no changes required.\n", info.Name) @@ -185,7 +191,7 @@ func (o *SetLastAppliedOptions) RunSetLastApplied(f cmdutil.Factory, cmd *cobra. return err } helper := resource.NewHelper(client, mapping) - patchedObj, err := helper.Patch(o.Namespace, info.Name, types.MergePatchType, patch) + patchedObj, err := helper.Patch(o.Namespace, info.Name, patch.PatchType, patch.Patch) if err != nil { return err } @@ -197,7 +203,7 @@ func (o *SetLastAppliedOptions) RunSetLastApplied(f cmdutil.Factory, cmd *cobra. cmdutil.PrintSuccess(o.Mapper, o.ShortOutput, o.Out, info.Mapping.Resource, info.Name, o.DryRun, "configured") } else { - err := o.formatPrinter(o.Output, patch) + err := o.formatPrinter(o.Output, patch.Patch, o.Out) if err != nil { return err } @@ -207,7 +213,7 @@ func (o *SetLastAppliedOptions) RunSetLastApplied(f cmdutil.Factory, cmd *cobra. return nil } -func (o *SetLastAppliedOptions) formatPrinter(output string, buf []byte) error { +func (o *SetLastAppliedOptions) formatPrinter(output string, buf []byte, w io.Writer) error { yamlOutput, err := yaml.JSONToYAML(buf) if err != nil { return err @@ -219,9 +225,9 @@ func (o *SetLastAppliedOptions) formatPrinter(output string, buf []byte) error { if err != nil { return err } - fmt.Fprintf(o.Out, string(jsonBuffer.Bytes())) + fmt.Fprintf(w, string(jsonBuffer.Bytes())) case "yaml": - fmt.Fprintf(o.Out, string(yamlOutput)) + fmt.Fprintf(w, string(yamlOutput)) } return nil } diff --git a/pkg/kubectl/cmd/attach_test.go b/pkg/kubectl/cmd/attach_test.go index d5f32249380e4..bbe04e26fd6c8 100644 --- a/pkg/kubectl/cmd/attach_test.go +++ b/pkg/kubectl/cmd/attach_test.go @@ -157,19 +157,19 @@ func TestPodAndContainerAttach(t *testing.T) { err := options.Complete(f, cmd, test.args) if test.expectError && err == nil { - t.Errorf("unexpected non-error (%s)", test.name) + t.Errorf("%s: unexpected non-error", test.name) } if !test.expectError && err != nil { - t.Errorf("unexpected error: %v (%s)", err, test.name) + t.Errorf("%s: unexpected error: %v", test.name, err) } if err != nil { continue } if options.PodName != test.expectedPod { - t.Errorf("expected: %s, got: %s (%s)", test.expectedPod, options.PodName, test.name) + t.Errorf("%s: expected: %s, got: %s", test.name, test.expectedPod, options.PodName) } if options.ContainerName != test.expectedContainer { - t.Errorf("expected: %s, got: %s (%s)", test.expectedContainer, options.ContainerName, test.name) + t.Errorf("%s: expected: %s, got: %s", test.name, test.expectedContainer, options.ContainerName) } } } diff --git a/pkg/kubectl/cmd/cmd.go b/pkg/kubectl/cmd/cmd.go index 91639dddfda3b..4bda4489cc2e0 100644 --- a/pkg/kubectl/cmd/cmd.go +++ b/pkg/kubectl/cmd/cmd.go @@ -378,7 +378,7 @@ func NewKubectlCommand(f cmdutil.Factory, in io.Reader, out, err io.Writer) *cob cmds.AddCommand(NewCmdVersion(f, out)) cmds.AddCommand(NewCmdApiVersions(f, out)) cmds.AddCommand(deprecatedAlias("apiversions", NewCmdApiVersions(f, out))) - cmds.AddCommand(NewCmdOptions()) + cmds.AddCommand(NewCmdOptions(out)) return cmds } diff --git a/pkg/kubectl/cmd/config/BUILD b/pkg/kubectl/cmd/config/BUILD index a0eb1492a757e..71213a2fb9f04 100644 --- a/pkg/kubectl/cmd/config/BUILD +++ b/pkg/kubectl/cmd/config/BUILD @@ -19,6 +19,7 @@ go_library( "get_clusters.go", "get_contexts.go", "navigation_step_parser.go", + "rename_context.go", "set.go", "unset.go", "use_context.go", @@ -50,6 +51,7 @@ go_test( srcs = [ "config_test.go", "create_authinfo_test.go", + "create_cluster_test.go", "create_context_test.go", "current_context_test.go", "delete_cluster_test.go", @@ -57,6 +59,7 @@ go_test( "get_clusters_test.go", "get_contexts_test.go", "navigation_step_parser_test.go", + "rename_context_test.go", "set_test.go", "unset_test.go", "use_context_test.go", diff --git a/pkg/kubectl/cmd/config/config.go b/pkg/kubectl/cmd/config/config.go index 93ab585e6046e..c90586cc440cb 100644 --- a/pkg/kubectl/cmd/config/config.go +++ b/pkg/kubectl/cmd/config/config.go @@ -64,6 +64,7 @@ func NewCmdConfig(pathOptions *clientcmd.PathOptions, out, errOut io.Writer) *co cmd.AddCommand(NewCmdConfigGetClusters(out, pathOptions)) cmd.AddCommand(NewCmdConfigDeleteCluster(out, pathOptions)) cmd.AddCommand(NewCmdConfigDeleteContext(out, errOut, pathOptions)) + cmd.AddCommand(NewCmdConfigRenameContext(out, pathOptions)) return cmd } diff --git a/pkg/kubectl/cmd/config/create_authinfo_test.go b/pkg/kubectl/cmd/config/create_authinfo_test.go index c851ec365121c..16cd959106d2a 100644 --- a/pkg/kubectl/cmd/config/create_authinfo_test.go +++ b/pkg/kubectl/cmd/config/create_authinfo_test.go @@ -18,10 +18,14 @@ package config import ( "bytes" + "io/ioutil" + "os" "reflect" "testing" "k8s.io/apiserver/pkg/util/flag" + "k8s.io/client-go/tools/clientcmd" + clientcmdapi "k8s.io/client-go/tools/clientcmd/api" ) func stringFlagFor(s string) flag.StringFlag { @@ -188,3 +192,69 @@ func TestCreateAuthInfoOptions(t *testing.T) { } } } + +type createAuthInfoTest struct { + description string + config clientcmdapi.Config + args []string + flags []string + expected string + expectedConfig clientcmdapi.Config +} + +func TestCreateAuthInfo(t *testing.T) { + conf := clientcmdapi.Config{} + test := createAuthInfoTest{ + description: "Testing for create aythinfo", + config: conf, + args: []string{"cluster-admin"}, + flags: []string{ + "--username=admin", + "--password=uXFGweU9l35qcif", + }, + expected: `User "cluster-admin" set.` + "\n", + expectedConfig: clientcmdapi.Config{ + AuthInfos: map[string]*clientcmdapi.AuthInfo{ + "cluster-admin": {Username: "admin", Password: "uXFGweU9l35qcif"}}, + }, + } + test.run(t) +} +func (test createAuthInfoTest) run(t *testing.T) { + fakeKubeFile, err := ioutil.TempFile(os.TempDir(), "") + if err != nil { + t.Fatalf("unexpected error: %v", err) + } + defer os.Remove(fakeKubeFile.Name()) + err = clientcmd.WriteToFile(test.config, fakeKubeFile.Name()) + if err != nil { + t.Fatalf("unexpected error: %v", err) + } + + pathOptions := clientcmd.NewDefaultPathOptions() + pathOptions.GlobalFile = fakeKubeFile.Name() + pathOptions.EnvVar = "" + buf := bytes.NewBuffer([]byte{}) + cmd := NewCmdConfigSetAuthInfo(buf, pathOptions) + cmd.SetArgs(test.args) + cmd.Flags().Parse(test.flags) + if err := cmd.Execute(); err != nil { + t.Fatalf("unexpected error executing command: %v,kubectl config set-credentials args: %v,flags: %v", err, test.args, test.flags) + } + config, err := clientcmd.LoadFromFile(fakeKubeFile.Name()) + if err != nil { + t.Fatalf("unexpected error loading kubeconfig file: %v", err) + } + if len(test.expected) != 0 { + if buf.String() != test.expected { + t.Errorf("Fail in %q:\n expected %v\n but got %v\n", test.description, test.expected, buf.String()) + } + } + if test.expectedConfig.AuthInfos != nil { + expectAuthInfo := test.expectedConfig.AuthInfos[test.args[0]] + actualAuthInfo := config.AuthInfos[test.args[0]] + if expectAuthInfo.Username != actualAuthInfo.Username || expectAuthInfo.Password != actualAuthInfo.Password { + t.Errorf("Fail in %q:\n expected AuthInfo%v\n but found %v in kubeconfig\n", test.description, expectAuthInfo, actualAuthInfo) + } + } +} diff --git a/pkg/kubectl/cmd/config/create_cluster_test.go b/pkg/kubectl/cmd/config/create_cluster_test.go new file mode 100644 index 0000000000000..f961468fab698 --- /dev/null +++ b/pkg/kubectl/cmd/config/create_cluster_test.go @@ -0,0 +1,119 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package config + +import ( + "bytes" + "io/ioutil" + "os" + "testing" + + "k8s.io/client-go/tools/clientcmd" + clientcmdapi "k8s.io/client-go/tools/clientcmd/api" +) + +type createClusterTest struct { + description string + config clientcmdapi.Config + args []string + flags []string + expected string + expectedConfig clientcmdapi.Config +} + +func TestCreateCluster(t *testing.T) { + conf := clientcmdapi.Config{} + test := createClusterTest{ + description: "Testing 'kubectl config set-cluster' with a new cluster", + config: conf, + args: []string{"my-cluster"}, + flags: []string{ + "--server=http://192.168.0.1", + }, + expected: `Cluster "my-cluster" set.` + "\n", + expectedConfig: clientcmdapi.Config{ + Clusters: map[string]*clientcmdapi.Cluster{ + "my-cluster": {Server: "http://192.168.0.1"}, + }, + }, + } + test.run(t) +} + +func TestModifyCluster(t *testing.T) { + conf := clientcmdapi.Config{ + Clusters: map[string]*clientcmdapi.Cluster{ + "my-cluster": {Server: "https://192.168.0.1"}, + }, + } + test := createClusterTest{ + description: "Testing 'kubectl config set-cluster' with an existing cluster", + config: conf, + args: []string{"my-cluster"}, + flags: []string{ + "--server=https://192.168.0.99", + }, + expected: `Cluster "my-cluster" set.` + "\n", + expectedConfig: clientcmdapi.Config{ + Clusters: map[string]*clientcmdapi.Cluster{ + "my-cluster": {Server: "https://192.168.0.99"}, + }, + }, + } + test.run(t) +} + +func (test createClusterTest) run(t *testing.T) { + fakeKubeFile, err := ioutil.TempFile(os.TempDir(), "") + if err != nil { + t.Fatalf("unexpected error: %v", err) + } + defer os.Remove(fakeKubeFile.Name()) + err = clientcmd.WriteToFile(test.config, fakeKubeFile.Name()) + if err != nil { + t.Fatalf("unexpected error: %v", err) + } + pathOptions := clientcmd.NewDefaultPathOptions() + pathOptions.GlobalFile = fakeKubeFile.Name() + pathOptions.EnvVar = "" + buf := bytes.NewBuffer([]byte{}) + cmd := NewCmdConfigSetCluster(buf, pathOptions) + cmd.SetArgs(test.args) + cmd.Flags().Parse(test.flags) + if err := cmd.Execute(); err != nil { + t.Fatalf("unexpected error executing command: %v, args: %v, flags: %v", err, test.args, test.flags) + } + config, err := clientcmd.LoadFromFile(fakeKubeFile.Name()) + if err != nil { + t.Fatalf("unexpected error loading kubeconfig file: %v", err) + } + if len(test.expected) != 0 { + if buf.String() != test.expected { + t.Errorf("Failed in %q\n expected %v\n but got %v", test.description, test.expected, buf.String()) + } + } + if len(test.args) > 0 { + cluster, ok := config.Clusters[test.args[0]] + if !ok { + t.Errorf("expected cluster %v, but got nil", test.args[0]) + return + } + if cluster.Server != test.expectedConfig.Clusters[test.args[0]].Server { + t.Errorf("Fail in %q\n expected cluster server %v\n but got %v\n ", test.description, test.expectedConfig.Clusters[test.args[0]].Server, cluster.Server) + } + } +} diff --git a/pkg/kubectl/cmd/config/create_context.go b/pkg/kubectl/cmd/config/create_context.go index a8fab9d687ade..59415b398869a 100644 --- a/pkg/kubectl/cmd/config/create_context.go +++ b/pkg/kubectl/cmd/config/create_context.go @@ -60,8 +60,13 @@ func NewCmdConfigSetContext(out io.Writer, configAccess clientcmd.ConfigAccess) Example: create_context_example, Run: func(cmd *cobra.Command, args []string) { cmdutil.CheckErr(options.complete(cmd)) - cmdutil.CheckErr(options.run()) - fmt.Fprintf(out, "Context %q set.\n", options.name) + exists, err := options.run() + cmdutil.CheckErr(err) + if exists { + fmt.Fprintf(out, "Context %q modified.\n", options.name) + } else { + fmt.Fprintf(out, "Context %q created.\n", options.name) + } }, } @@ -72,15 +77,15 @@ func NewCmdConfigSetContext(out io.Writer, configAccess clientcmd.ConfigAccess) return cmd } -func (o createContextOptions) run() error { +func (o createContextOptions) run() (bool, error) { err := o.validate() if err != nil { - return err + return false, err } config, err := o.configAccess.GetStartingConfig() if err != nil { - return err + return false, err } startingStanza, exists := config.Contexts[o.name] @@ -91,10 +96,10 @@ func (o createContextOptions) run() error { config.Contexts[o.name] = &context if err := clientcmd.ModifyConfig(o.configAccess, *config, true); err != nil { - return err + return exists, err } - return nil + return exists, nil } func (o *createContextOptions) modifyContext(existingContext clientcmdapi.Context) clientcmdapi.Context { diff --git a/pkg/kubectl/cmd/config/create_context_test.go b/pkg/kubectl/cmd/config/create_context_test.go index 83904197a37f8..d1187742b1b20 100644 --- a/pkg/kubectl/cmd/config/create_context_test.go +++ b/pkg/kubectl/cmd/config/create_context_test.go @@ -46,7 +46,7 @@ func TestCreateContext(t *testing.T) { "--user=user_nickname", "--namespace=namespace", }, - expected: `Context "shaker-context" set.` + "\n", + expected: `Context "shaker-context" created.` + "\n", expectedConfig: clientcmdapi.Config{ Contexts: map[string]*clientcmdapi.Context{ "shaker-context": {AuthInfo: "user_nickname", Cluster: "cluster_nickname", Namespace: "namespace"}}, @@ -68,7 +68,7 @@ func TestModifyContext(t *testing.T) { "--user=user_nickname", "--namespace=namespace", }, - expected: `Context "shaker-context" set.` + "\n", + expected: `Context "shaker-context" modified.` + "\n", expectedConfig: clientcmdapi.Config{ Contexts: map[string]*clientcmdapi.Context{ "shaker-context": {AuthInfo: "user_nickname", Cluster: "cluster_nickname", Namespace: "namespace"}, diff --git a/pkg/kubectl/cmd/config/current_context_test.go b/pkg/kubectl/cmd/config/current_context_test.go index 1b3f386c24e09..69b466f426311 100644 --- a/pkg/kubectl/cmd/config/current_context_test.go +++ b/pkg/kubectl/cmd/config/current_context_test.go @@ -57,9 +57,12 @@ func TestCurrentContextWithUnsetContext(t *testing.T) { } func (test currentContextTest) run(t *testing.T) { - fakeKubeFile, _ := ioutil.TempFile("", "") + fakeKubeFile, err := ioutil.TempFile("", "") + if err != nil { + t.Fatalf("unexpected error: %v", err) + } defer os.Remove(fakeKubeFile.Name()) - err := clientcmd.WriteToFile(test.startingConfig, fakeKubeFile.Name()) + err = clientcmd.WriteToFile(test.startingConfig, fakeKubeFile.Name()) if err != nil { t.Fatalf("unexpected error: %v", err) } diff --git a/pkg/kubectl/cmd/config/delete_cluster_test.go b/pkg/kubectl/cmd/config/delete_cluster_test.go index 684e47bf795b9..5e7457a68cc52 100644 --- a/pkg/kubectl/cmd/config/delete_cluster_test.go +++ b/pkg/kubectl/cmd/config/delete_cluster_test.go @@ -53,9 +53,12 @@ func TestDeleteCluster(t *testing.T) { } func (test deleteClusterTest) run(t *testing.T) { - fakeKubeFile, _ := ioutil.TempFile("", "") + fakeKubeFile, err := ioutil.TempFile("", "") + if err != nil { + t.Fatalf("unexpected error: %v", err) + } defer os.Remove(fakeKubeFile.Name()) - err := clientcmd.WriteToFile(test.config, fakeKubeFile.Name()) + err = clientcmd.WriteToFile(test.config, fakeKubeFile.Name()) if err != nil { t.Fatalf("unexpected error: %v", err) } diff --git a/pkg/kubectl/cmd/config/delete_context_test.go b/pkg/kubectl/cmd/config/delete_context_test.go index 36bad7c9fe614..8f7b958264455 100644 --- a/pkg/kubectl/cmd/config/delete_context_test.go +++ b/pkg/kubectl/cmd/config/delete_context_test.go @@ -53,9 +53,12 @@ func TestDeleteContext(t *testing.T) { } func (test deleteContextTest) run(t *testing.T) { - fakeKubeFile, _ := ioutil.TempFile("", "") + fakeKubeFile, err := ioutil.TempFile("", "") + if err != nil { + t.Fatalf("unexpected error: %v", err) + } defer os.Remove(fakeKubeFile.Name()) - err := clientcmd.WriteToFile(test.config, fakeKubeFile.Name()) + err = clientcmd.WriteToFile(test.config, fakeKubeFile.Name()) if err != nil { t.Fatalf("unexpected error: %v", err) } diff --git a/pkg/kubectl/cmd/config/get_clusters_test.go b/pkg/kubectl/cmd/config/get_clusters_test.go index 4c9d3da892673..9eaf808f0bd26 100644 --- a/pkg/kubectl/cmd/config/get_clusters_test.go +++ b/pkg/kubectl/cmd/config/get_clusters_test.go @@ -57,9 +57,12 @@ func TestGetClustersEmpty(t *testing.T) { } func (test getClustersTest) run(t *testing.T) { - fakeKubeFile, _ := ioutil.TempFile("", "") + fakeKubeFile, err := ioutil.TempFile("", "") + if err != nil { + t.Fatalf("unexpected error: %v", err) + } defer os.Remove(fakeKubeFile.Name()) - err := clientcmd.WriteToFile(test.config, fakeKubeFile.Name()) + err = clientcmd.WriteToFile(test.config, fakeKubeFile.Name()) if err != nil { t.Fatalf("unexpected error: %v", err) } diff --git a/pkg/kubectl/cmd/config/get_contexts_test.go b/pkg/kubectl/cmd/config/get_contexts_test.go index 5a7da24ebb0ba..8d84b7f9a409f 100644 --- a/pkg/kubectl/cmd/config/get_contexts_test.go +++ b/pkg/kubectl/cmd/config/get_contexts_test.go @@ -123,9 +123,12 @@ func TestGetContextsSelectOneOfTwo(t *testing.T) { } func (test getContextsTest) run(t *testing.T) { - fakeKubeFile, _ := ioutil.TempFile("", "") + fakeKubeFile, err := ioutil.TempFile("", "") + if err != nil { + t.Fatalf("unexpected error: %v", err) + } defer os.Remove(fakeKubeFile.Name()) - err := clientcmd.WriteToFile(test.startingConfig, fakeKubeFile.Name()) + err = clientcmd.WriteToFile(test.startingConfig, fakeKubeFile.Name()) if err != nil { t.Fatalf("unexpected error: %v", err) } diff --git a/pkg/kubectl/cmd/config/rename_context.go b/pkg/kubectl/cmd/config/rename_context.go new file mode 100644 index 0000000000000..7d00eb83ac8c6 --- /dev/null +++ b/pkg/kubectl/cmd/config/rename_context.go @@ -0,0 +1,136 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package config + +import ( + "errors" + "fmt" + "io" + + "github.com/spf13/cobra" + + "k8s.io/client-go/tools/clientcmd" + "k8s.io/kubernetes/pkg/kubectl/cmd/templates" + cmdutil "k8s.io/kubernetes/pkg/kubectl/cmd/util" +) + +// RenameContextOptions contains the options for running the rename-context cli command. +type RenameContextOptions struct { + configAccess clientcmd.ConfigAccess + contextName string + newName string +} + +const ( + renameContextUse = "rename-context CONTEXT_NAME NEW_NAME" + + renameContextShort = "Renames a context from the kubeconfig file." +) + +var ( + renameContextLong = templates.LongDesc(` + Renames a context from the kubeconfig file . + + CONTEXT_NAME is the context name that you wish change. + + NEW_NAME is the new name you wish to set. + + Note: In case the context being renamed is the 'current-context', this field will also be updated.`) + + renameContextExample = templates.Examples(` + # Rename the context 'old-name' to 'new-name' in your kubeconfig file + kubectl config rename-context old-name new-name`) +) + +// NewCmdConfigRenameContext creates a command object for the "rename-context" action +func NewCmdConfigRenameContext(out io.Writer, configAccess clientcmd.ConfigAccess) *cobra.Command { + options := &RenameContextOptions{configAccess: configAccess} + + cmd := &cobra.Command{ + Use: renameContextUse, + Short: renameContextShort, + Long: renameContextLong, + Example: renameContextExample, + Run: func(cmd *cobra.Command, args []string) { + if err := options.Complete(cmd, args, out); err != nil { + cmdutil.CheckErr(err) + } + if err := options.Validate(); err != nil { + cmdutil.UsageError(cmd, err.Error()) + } + if err := options.RunRenameContext(out); err != nil { + cmdutil.CheckErr(err) + } + }, + } + return cmd +} + +// Complete assigns RenameContextOptions from the args. +func (o *RenameContextOptions) Complete(cmd *cobra.Command, args []string, out io.Writer) error { + if len(args) != 2 { + cmd.Help() + return fmt.Errorf("Unexpected args: %v", args) + } + + o.contextName = args[0] + o.newName = args[1] + return nil +} + +func (o RenameContextOptions) Validate() error { + if len(o.newName) == 0 { + return errors.New("You must specify a new non-empty context name") + } + return nil +} + +func (o RenameContextOptions) RunRenameContext(out io.Writer) error { + config, err := o.configAccess.GetStartingConfig() + if err != nil { + return err + } + + configFile := o.configAccess.GetDefaultFilename() + if o.configAccess.IsExplicitFile() { + configFile = o.configAccess.GetExplicitFile() + } + + context, exists := config.Contexts[o.contextName] + if !exists { + return fmt.Errorf("cannot rename the context %q, it's not in %s", o.contextName, configFile) + } + + _, newExists := config.Contexts[o.newName] + if newExists { + return fmt.Errorf("cannot rename the context %q, the context %q already exists in %s", o.contextName, o.newName, configFile) + } + + config.Contexts[o.newName] = context + delete(config.Contexts, o.contextName) + + if config.CurrentContext == o.contextName { + config.CurrentContext = o.newName + } + + if err := clientcmd.ModifyConfig(o.configAccess, *config, true); err != nil { + return err + } + + fmt.Fprintf(out, "Context %q was renamed to %q.\n", o.contextName, o.newName) + return nil +} diff --git a/pkg/kubectl/cmd/config/rename_context_test.go b/pkg/kubectl/cmd/config/rename_context_test.go new file mode 100644 index 0000000000000..4a074a49e8141 --- /dev/null +++ b/pkg/kubectl/cmd/config/rename_context_test.go @@ -0,0 +1,156 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package config + +import ( + "bytes" + "fmt" + "io/ioutil" + "os" + "strings" + "testing" + + "k8s.io/client-go/tools/clientcmd" + clientcmdapi "k8s.io/client-go/tools/clientcmd/api" +) + +const ( + currentContext = "current-context" + newContext = "new-context" + nonexistentCurrentContext = "nonexistent-current-context" + existentNewContext = "existent-new-context" +) + +var ( + contextData *clientcmdapi.Context = clientcmdapi.NewContext() +) + +type renameContextTest struct { + description string + initialConfig clientcmdapi.Config // initial config + expectedConfig clientcmdapi.Config // expected config + args []string // kubectl rename-context args + expectedOut string // expected out message + expectedErr string // expected error message +} + +func TestRenameContext(t *testing.T) { + initialConfig := clientcmdapi.Config{ + CurrentContext: currentContext, + Contexts: map[string]*clientcmdapi.Context{currentContext: contextData}} + + expectedConfig := clientcmdapi.Config{ + CurrentContext: newContext, + Contexts: map[string]*clientcmdapi.Context{newContext: contextData}} + + test := renameContextTest{ + description: "Testing for kubectl config rename-context whose context to be renamed is the CurrentContext", + initialConfig: initialConfig, + expectedConfig: expectedConfig, + args: []string{currentContext, newContext}, + expectedOut: fmt.Sprintf("Context %q was renamed to %q.\n", currentContext, newContext), + expectedErr: "", + } + test.run(t) +} + +func TestRenameNonexistentContext(t *testing.T) { + initialConfig := clientcmdapi.Config{ + CurrentContext: currentContext, + Contexts: map[string]*clientcmdapi.Context{currentContext: contextData}} + + test := renameContextTest{ + description: "Testing for kubectl config rename-context whose context to be renamed no exists", + initialConfig: initialConfig, + expectedConfig: initialConfig, + args: []string{nonexistentCurrentContext, newContext}, + expectedOut: "", + expectedErr: fmt.Sprintf("cannot rename the context %q, it's not in", nonexistentCurrentContext), + } + test.run(t) +} + +func TestRenameToAlreadyExistingContext(t *testing.T) { + initialConfig := clientcmdapi.Config{ + CurrentContext: currentContext, + Contexts: map[string]*clientcmdapi.Context{ + currentContext: contextData, + existentNewContext: contextData}} + + test := renameContextTest{ + description: "Testing for kubectl config rename-context whose the new name is already in another context.", + initialConfig: initialConfig, + expectedConfig: initialConfig, + args: []string{currentContext, existentNewContext}, + expectedOut: "", + expectedErr: fmt.Sprintf("cannot rename the context %q, the context %q already exists", currentContext, existentNewContext), + } + test.run(t) +} + +func (test renameContextTest) run(t *testing.T) { + fakeKubeFile, _ := ioutil.TempFile("", "") + defer os.Remove(fakeKubeFile.Name()) + err := clientcmd.WriteToFile(test.initialConfig, fakeKubeFile.Name()) + if err != nil { + t.Fatalf("unexpected error: %v", err) + } + + pathOptions := clientcmd.NewDefaultPathOptions() + pathOptions.GlobalFile = fakeKubeFile.Name() + pathOptions.EnvVar = "" + options := RenameContextOptions{ + configAccess: pathOptions, + contextName: test.args[0], + newName: test.args[1], + } + buf := bytes.NewBuffer([]byte{}) + cmd := NewCmdConfigRenameContext(buf, options.configAccess) + + options.Complete(cmd, test.args, buf) + options.Validate() + err = options.RunRenameContext(buf) + + if len(test.expectedErr) != 0 { + if err == nil { + t.Errorf("Did not get %v", test.expectedErr) + } else { + if !strings.Contains(err.Error(), test.expectedErr) { + t.Errorf("Expected error %v, but got %v", test.expectedErr, err) + } + } + return + } + + config, err := clientcmd.LoadFromFile(fakeKubeFile.Name()) + if err != nil { + t.Fatalf("unexpected error loading kubeconfig file: %v", err) + } + + _, oldExists := config.Contexts[currentContext] + _, newExists := config.Contexts[newContext] + + if (!newExists) || (oldExists) || (config.CurrentContext != newContext) { + t.Errorf("Failed in: %q\n expected %v\n but got %v", test.description, test.expectedConfig, *config) + } + + if len(test.expectedOut) != 0 { + if buf.String() != test.expectedOut { + t.Errorf("Failed in:%q\n expected out %v\n but got %v", test.description, test.expectedOut, buf.String()) + } + } +} diff --git a/pkg/kubectl/cmd/create_clusterrole.go b/pkg/kubectl/cmd/create_clusterrole.go index a4b27cd4a8851..9ab572871b729 100644 --- a/pkg/kubectl/cmd/create_clusterrole.go +++ b/pkg/kubectl/cmd/create_clusterrole.go @@ -17,6 +17,7 @@ limitations under the License. package cmd import ( + "fmt" "io" "github.com/spf13/cobra" @@ -42,11 +43,18 @@ var ( kubectl create clusterrole foo --verb=get,list,watch --resource=rs.extensions # Create a ClusterRole named "foo" with SubResource specified - kubectl create clusterrole foo --verb=get,list,watch --resource=pods,pods/status`)) + kubectl create clusterrole foo --verb=get,list,watch --resource=pods,pods/status + + # Create a ClusterRole name "foo" with NonResourceURL specified + kubectl create clusterrole "foo" --verb=get --non-resource-url=/logs/*`)) + + // Valid nonResource verb list for validation. + validNonResourceVerbs = []string{"*", "get", "post", "put", "delete", "patch", "head", "options"} ) type CreateClusterRoleOptions struct { *CreateRoleOptions + NonResourceURLs []string } // ClusterRole is a command to ease creating ClusterRoles. @@ -72,16 +80,69 @@ func NewCmdCreateClusterRole(f cmdutil.Factory, cmdOut io.Writer) *cobra.Command cmdutil.AddPrinterFlags(cmd) cmdutil.AddDryRunFlag(cmd) cmd.Flags().StringSliceVar(&c.Verbs, "verb", []string{}, "verb that applies to the resources contained in the rule") + cmd.Flags().StringSliceVar(&c.NonResourceURLs, "non-resource-url", []string{}, "a partial url that user should have access to.") cmd.Flags().StringSlice("resource", []string{}, "resource that the rule applies to") cmd.Flags().StringArrayVar(&c.ResourceNames, "resource-name", []string{}, "resource in the white list that the rule applies to, repeat this flag for multiple items") return cmd } +func (c *CreateClusterRoleOptions) Complete(f cmdutil.Factory, cmd *cobra.Command, args []string) error { + // Remove duplicate nonResourceURLs + nonResourceURLs := []string{} + for _, n := range c.NonResourceURLs { + if !arrayContains(nonResourceURLs, n) { + nonResourceURLs = append(nonResourceURLs, n) + } + } + c.NonResourceURLs = nonResourceURLs + + return c.CreateRoleOptions.Complete(f, cmd, args) +} + +func (c *CreateClusterRoleOptions) Validate() error { + if c.Name == "" { + return fmt.Errorf("name must be specified") + } + + // validate verbs. + if len(c.Verbs) == 0 { + return fmt.Errorf("at least one verb must be specified") + } + + if len(c.Resources) == 0 && len(c.NonResourceURLs) == 0 { + return fmt.Errorf("one of resource or nonResourceURL must be specified") + } + + // validate resources + if len(c.Resources) > 0 { + for _, v := range c.Verbs { + if !arrayContains(validResourceVerbs, v) { + return fmt.Errorf("invalid verb: '%s'", v) + } + } + if err := c.validateResource(); err != nil { + return err + } + } + + //validate non-resource-url + if len(c.NonResourceURLs) > 0 { + for _, v := range c.Verbs { + if !arrayContains(validNonResourceVerbs, v) { + return fmt.Errorf("invalid verb: '%s' for nonResourceURL", v) + } + } + } + + return nil + +} + func (c *CreateClusterRoleOptions) RunCreateRole() error { clusterRole := &rbac.ClusterRole{} clusterRole.Name = c.Name - rules, err := generateResourcePolicyRules(c.Mapper, c.Verbs, c.Resources, c.ResourceNames) + rules, err := generateResourcePolicyRules(c.Mapper, c.Verbs, c.Resources, c.ResourceNames, c.NonResourceURLs) if err != nil { return err } diff --git a/pkg/kubectl/cmd/create_quota_test.go b/pkg/kubectl/cmd/create_quota_test.go index a4c0df1b79ab6..659530cb7f76a 100644 --- a/pkg/kubectl/cmd/create_quota_test.go +++ b/pkg/kubectl/cmd/create_quota_test.go @@ -47,30 +47,30 @@ func TestCreateQuota(t *testing.T) { tf.Namespace = "test" tests := map[string]struct { - flags map[string]string + flags []string expectedOutput string }{ "single resource": { - flags: map[string]string{"hard": "cpu=1", "output": "name"}, + flags: []string{"--hard=cpu=1"}, expectedOutput: "resourcequota/" + resourceQuotaObject.Name + "\n", }, "single resource with a scope": { - flags: map[string]string{"hard": "cpu=1", "output": "name", "scopes": "BestEffort"}, + flags: []string{"--hard=cpu=1", "--scopes=BestEffort"}, expectedOutput: "resourcequota/" + resourceQuotaObject.Name + "\n", }, "multiple resources": { - flags: map[string]string{"hard": "cpu=1,pods=42", "output": "name", "scopes": "BestEffort"}, + flags: []string{"--hard=cpu=1,pods=42", "--scopes=BestEffort"}, expectedOutput: "resourcequota/" + resourceQuotaObject.Name + "\n", }, "single resource with multiple scopes": { - flags: map[string]string{"hard": "cpu=1", "output": "name", "scopes": "BestEffort,NotTerminating"}, + flags: []string{"--hard=cpu=1", "--scopes=BestEffort,NotTerminating"}, expectedOutput: "resourcequota/" + resourceQuotaObject.Name + "\n", }, } for name, test := range tests { buf := bytes.NewBuffer([]byte{}) cmd := NewCmdCreateQuota(f, buf) - cmd.Flags().Set("hard", "cpu=1") + cmd.Flags().Parse(test.flags) cmd.Flags().Set("output", "name") cmd.Run(cmd, []string{resourceQuotaObject.Name}) diff --git a/pkg/kubectl/cmd/create_role.go b/pkg/kubectl/cmd/create_role.go index 4a2408696b674..0baf88ee9bca5 100644 --- a/pkg/kubectl/cmd/create_role.go +++ b/pkg/kubectl/cmd/create_role.go @@ -232,6 +232,10 @@ func (c *CreateRoleOptions) Validate() error { return fmt.Errorf("at least one resource must be specified") } + return c.validateResource() +} + +func (c *CreateRoleOptions) validateResource() error { for _, r := range c.Resources { if len(r.Resource) == 0 { return fmt.Errorf("resource must be specified if apiGroup/subresource specified") @@ -263,14 +267,13 @@ func (c *CreateRoleOptions) Validate() error { return err } } - return nil } func (c *CreateRoleOptions) RunCreateRole() error { role := &rbac.Role{} role.Name = c.Name - rules, err := generateResourcePolicyRules(c.Mapper, c.Verbs, c.Resources, c.ResourceNames) + rules, err := generateResourcePolicyRules(c.Mapper, c.Verbs, c.Resources, c.ResourceNames, []string{}) if err != nil { return err } @@ -301,7 +304,7 @@ func arrayContains(s []string, e string) bool { return false } -func generateResourcePolicyRules(mapper meta.RESTMapper, verbs []string, resources []ResourceOptions, resourceNames []string) ([]rbac.PolicyRule, error) { +func generateResourcePolicyRules(mapper meta.RESTMapper, verbs []string, resources []ResourceOptions, resourceNames []string, nonResourceURLs []string) ([]rbac.PolicyRule, error) { // groupResourceMapping is a apigroup-resource map. The key of this map is api group, while the value // is a string array of resources under this api group. // E.g. groupResourceMapping = {"extensions": ["replicasets", "deployments"], "batch":["jobs"]} @@ -337,5 +340,12 @@ func generateResourcePolicyRules(mapper meta.RESTMapper, verbs []string, resourc rules = append(rules, rule) } + if len(nonResourceURLs) > 0 { + rule := rbac.PolicyRule{} + rule.Verbs = verbs + rule.NonResourceURLs = nonResourceURLs + rules = append(rules, rule) + } + return rules, nil } diff --git a/pkg/kubectl/cmd/edit_test.go b/pkg/kubectl/cmd/edit_test.go index dd5c7b217b0ee..55516bb0bebfd 100644 --- a/pkg/kubectl/cmd/edit_test.go +++ b/pkg/kubectl/cmd/edit_test.go @@ -238,6 +238,8 @@ func TestEdit(t *testing.T) { case "create": cmd = NewCmdCreate(f, buf, errBuf) cmd.Flags().Set("edit", "true") + case "edit-last-applied": + cmd = NewCmdApplyEditLastApplied(f, buf, errBuf) default: t.Errorf("%s: unexpected mode %s", name, testcase.Mode) continue diff --git a/pkg/kubectl/cmd/exec_test.go b/pkg/kubectl/cmd/exec_test.go index 9b50f9c6dc554..8d72c724bc490 100644 --- a/pkg/kubectl/cmd/exec_test.go +++ b/pkg/kubectl/cmd/exec_test.go @@ -141,22 +141,22 @@ func TestPodAndContainer(t *testing.T) { options := test.p err := options.Complete(f, cmd, test.args, test.argsLenAtDash) if test.expectError && err == nil { - t.Errorf("unexpected non-error (%s)", test.name) + t.Errorf("%s: unexpected non-error", test.name) } if !test.expectError && err != nil { - t.Errorf("unexpected error: %v (%s)", err, test.name) + t.Errorf("%s: unexpected error: %v", test.name, err) } if err != nil { continue } if options.PodName != test.expectedPod { - t.Errorf("expected: %s, got: %s (%s)", test.expectedPod, options.PodName, test.name) + t.Errorf("%s: expected: %s, got: %s", test.name, test.expectedPod, options.PodName) } if options.ContainerName != test.expectedContainer { - t.Errorf("expected: %s, got: %s (%s)", test.expectedContainer, options.ContainerName, test.name) + t.Errorf("%s: expected: %s, got: %s", test.name, test.expectedContainer, options.ContainerName) } if !reflect.DeepEqual(test.expectedArgs, options.Command) { - t.Errorf("expected: %v, got %v (%s)", test.expectedArgs, options.Command, test.name) + t.Errorf("%s: expected: %v, got %v", test.name, test.expectedArgs, options.Command) } } } diff --git a/pkg/kubectl/cmd/options.go b/pkg/kubectl/cmd/options.go index 0512789999d04..945e83ded905f 100644 --- a/pkg/kubectl/cmd/options.go +++ b/pkg/kubectl/cmd/options.go @@ -17,6 +17,8 @@ limitations under the License. package cmd import ( + "io" + "k8s.io/kubernetes/pkg/kubectl/cmd/templates" "k8s.io/kubernetes/pkg/util/i18n" @@ -30,7 +32,7 @@ var ( ) // NewCmdOptions implements the options command -func NewCmdOptions() *cobra.Command { +func NewCmdOptions(out io.Writer) *cobra.Command { cmd := &cobra.Command{ Use: "options", Short: i18n.T("Print the list of flags inherited by all commands"), @@ -41,7 +43,13 @@ func NewCmdOptions() *cobra.Command { }, } - templates.UseOptionsTemplates(cmd) + // The `options` command needs write its output to the `out` stream + // (typically stdout). Without calling SetOutput here, the Usage() + // function call will fall back to stderr. + // + // See https://github.com/kubernetes/kubernetes/pull/46394 for details. + cmd.SetOutput(out) + templates.UseOptionsTemplates(cmd) return cmd } diff --git a/pkg/kubectl/cmd/set/BUILD b/pkg/kubectl/cmd/set/BUILD index b1e9d7b690402..5712cff968d48 100644 --- a/pkg/kubectl/cmd/set/BUILD +++ b/pkg/kubectl/cmd/set/BUILD @@ -43,6 +43,7 @@ go_test( name = "go_default_test", srcs = [ "set_image_test.go", + "set_resources_test.go", "set_selector_test.go", "set_subject_test.go", "set_test.go", diff --git a/pkg/kubectl/cmd/set/set_image_test.go b/pkg/kubectl/cmd/set/set_image_test.go index 45ab8d3c76f56..0faf88eb63490 100644 --- a/pkg/kubectl/cmd/set/set_image_test.go +++ b/pkg/kubectl/cmd/set/set_image_test.go @@ -70,3 +70,66 @@ func TestImageLocal(t *testing.T) { t.Errorf("did not set image: %s", buf.String()) } } + +func TestSetImageValidation(t *testing.T) { + testCases := []struct { + name string + imageOptions *ImageOptions + expectErr string + }{ + { + name: "test resource < 1 and filenames empty", + imageOptions: &ImageOptions{}, + expectErr: "[one or more resources must be specified as or /, at least one image update is required]", + }, + { + name: "test containerImages < 1", + imageOptions: &ImageOptions{ + Resources: []string{"a", "b", "c"}, + + FilenameOptions: resource.FilenameOptions{ + Filenames: []string{"testFile"}, + }, + }, + expectErr: "at least one image update is required", + }, + { + name: "test containerImages > 1 and all containers are already specified by *", + imageOptions: &ImageOptions{ + Resources: []string{"a", "b", "c"}, + FilenameOptions: resource.FilenameOptions{ + Filenames: []string{"testFile"}, + }, + ContainerImages: map[string]string{ + "test": "test", + "*": "test", + }, + }, + expectErr: "all containers are already specified by *, but saw more than one container_name=container_image pairs", + }, + { + name: "sucess case", + imageOptions: &ImageOptions{ + Resources: []string{"a", "b", "c"}, + FilenameOptions: resource.FilenameOptions{ + Filenames: []string{"testFile"}, + }, + ContainerImages: map[string]string{ + "test": "test", + }, + }, + expectErr: "", + }, + } + for _, testCase := range testCases { + err := testCase.imageOptions.Validate() + if err != nil { + if err.Error() != testCase.expectErr { + t.Errorf("[%s]:expect err:%s got err:%s", testCase.name, testCase.expectErr, err.Error()) + } + } + if err == nil && (testCase.expectErr != "") { + t.Errorf("[%s]:expect err:%s got err:%v", testCase.name, testCase.expectErr, err) + } + } +} diff --git a/pkg/kubectl/cmd/set/set_resources_test.go b/pkg/kubectl/cmd/set/set_resources_test.go new file mode 100644 index 0000000000000..204322c885430 --- /dev/null +++ b/pkg/kubectl/cmd/set/set_resources_test.go @@ -0,0 +1,76 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package set + +import ( + "bytes" + "net/http" + "strings" + "testing" + + "k8s.io/apimachinery/pkg/runtime" + restclient "k8s.io/client-go/rest" + "k8s.io/client-go/rest/fake" + "k8s.io/kubernetes/pkg/api" + cmdtesting "k8s.io/kubernetes/pkg/kubectl/cmd/testing" + "k8s.io/kubernetes/pkg/kubectl/resource" + "k8s.io/kubernetes/pkg/printers" +) + +func TestResourcesLocal(t *testing.T) { + f, tf, codec, ns := cmdtesting.NewAPIFactory() + tf.Client = &fake.RESTClient{ + APIRegistry: api.Registry, + NegotiatedSerializer: ns, + Client: fake.CreateHTTPClient(func(req *http.Request) (*http.Response, error) { + t.Fatalf("unexpected request: %s %#v\n%#v", req.Method, req.URL, req) + return nil, nil + }), + } + tf.Namespace = "test" + tf.ClientConfig = &restclient.Config{ContentConfig: restclient.ContentConfig{GroupVersion: &api.Registry.GroupOrDie(api.GroupName).GroupVersion}} + + buf := bytes.NewBuffer([]byte{}) + cmd := NewCmdResources(f, buf, buf) + cmd.SetOutput(buf) + cmd.Flags().Set("output", "name") + cmd.Flags().Set("local", "true") + mapper, typer := f.Object() + tf.Printer = &printers.NamePrinter{Decoders: []runtime.Decoder{codec}, Typer: typer, Mapper: mapper} + + opts := ResourcesOptions{FilenameOptions: resource.FilenameOptions{ + Filenames: []string{"../../../../examples/storage/cassandra/cassandra-controller.yaml"}}, + Out: buf, + Local: true, + Limits: "cpu=200m,memory=512Mi", + Requests: "cpu=200m,memory=512Mi", + ContainerSelector: "*"} + + err := opts.Complete(f, cmd, []string{""}) + if err == nil { + err = opts.Validate() + } + if err == nil { + err = opts.Run() + } + if err != nil { + t.Fatalf("unexpected error: %v", err) + } + if !strings.Contains(buf.String(), "replicationcontrollers/cassandra") { + t.Errorf("did not set resources: %s", buf.String()) + } +} diff --git a/pkg/kubectl/cmd/set/set_selector.go b/pkg/kubectl/cmd/set/set_selector.go index e8f395d054561..4f7c2b5acff63 100644 --- a/pkg/kubectl/cmd/set/set_selector.go +++ b/pkg/kubectl/cmd/set/set_selector.go @@ -172,7 +172,6 @@ func (o *SelectorOptions) RunSelector() error { return patch.Err } if o.local || o.dryrun { - fmt.Fprintln(o.out, "running in local/dry-run mode...") o.PrintObject(info.Object) return nil } diff --git a/pkg/kubectl/cmd/set/set_selector_test.go b/pkg/kubectl/cmd/set/set_selector_test.go index db8b0c07b1157..425f29c38192e 100644 --- a/pkg/kubectl/cmd/set/set_selector_test.go +++ b/pkg/kubectl/cmd/set/set_selector_test.go @@ -17,16 +17,22 @@ limitations under the License. package set import ( + "bytes" + "net/http" "reflect" + "strings" "testing" "github.com/stretchr/testify/assert" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" + restclient "k8s.io/client-go/rest" + "k8s.io/client-go/rest/fake" "k8s.io/kubernetes/pkg/api" "k8s.io/kubernetes/pkg/apis/batch" "k8s.io/kubernetes/pkg/apis/extensions" + cmdtesting "k8s.io/kubernetes/pkg/kubectl/cmd/testing" + "k8s.io/kubernetes/pkg/printers" ) func TestUpdateSelectorForObjectTypes(t *testing.T) { @@ -307,3 +313,32 @@ func TestGetResourcesAndSelector(t *testing.T) { } } } + +func TestSelectorTest(t *testing.T) { + f, tf, codec, ns := cmdtesting.NewAPIFactory() + tf.Client = &fake.RESTClient{ + APIRegistry: api.Registry, + NegotiatedSerializer: ns, + Client: fake.CreateHTTPClient(func(req *http.Request) (*http.Response, error) { + t.Fatalf("unexpected request: %s %#v\n%#v", req.Method, req.URL, req) + return nil, nil + }), + } + tf.Namespace = "test" + tf.ClientConfig = &restclient.Config{ContentConfig: restclient.ContentConfig{GroupVersion: &api.Registry.GroupOrDie(api.GroupName).GroupVersion}} + + buf := bytes.NewBuffer([]byte{}) + cmd := NewCmdSelector(f, buf) + cmd.SetOutput(buf) + cmd.Flags().Set("output", "name") + cmd.Flags().Set("local", "true") + cmd.Flags().Set("filename", "../../../../examples/storage/cassandra/cassandra-service.yaml") + + mapper, typer := f.Object() + tf.Printer = &printers.NamePrinter{Decoders: []runtime.Decoder{codec}, Typer: typer, Mapper: mapper} + cmd.Run(cmd, []string{"environment=qa"}) + + if !strings.Contains(buf.String(), "services/cassandra") { + t.Errorf("did not set selector: %s", buf.String()) + } +} diff --git a/pkg/kubectl/cmd/set/set_subject.go b/pkg/kubectl/cmd/set/set_subject.go index 0cd1d16ac199d..2ab3fc11c27fa 100644 --- a/pkg/kubectl/cmd/set/set_subject.go +++ b/pkg/kubectl/cmd/set/set_subject.go @@ -224,7 +224,6 @@ func (o *SubjectOptions) Run(f cmdutil.Factory, fn updateSubjects) error { } if o.Local || o.DryRun { - fmt.Fprintln(o.Out, "running in local/dry-run mode...") return o.PrintObject(o.Mapper, info.Object, o.Out) } diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/0.request b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/0.request new file mode 100755 index 0000000000000..e69de29bb2d1d diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/0.response b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/0.response new file mode 100755 index 0000000000000..75d223aadcc0a --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/0.response @@ -0,0 +1,21 @@ +{ + "kind": "ConfigMap", + "apiVersion": "v1", + "metadata": { + "name": "cm1", + "namespace": "myproject", + "selfLink": "/api/v1/namespaces/myproject/configmaps/cm1", + "uid": "cc08a131-3d6f-11e7-8ef0-c85b76034b7b", + "resourceVersion": "3518", + "creationTimestamp": "2017-05-20T15:20:03Z", + "annotations": { + "kubectl.kubernetes.io/last-applied-configuration": "{\"apiVersion\":\"v1\",\"data\":{\"baz\":\"qux\",\"foo\":\"changed-value\",\"new-data\":\"new-value\",\"new-data2\":\"new-value\"},\"kind\":\"ConfigMap\",\"metadata\":{\"annotations\":{},\"name\":\"cm1\",\"namespace\":\"myproject\"}}\n" + } + }, + "data": { + "baz": "qux", + "foo": "changed-value", + "new-data": "new-value", + "new-data2": "new-value" + } +} \ No newline at end of file diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/1.request b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/1.request new file mode 100755 index 0000000000000..e69de29bb2d1d diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/1.response b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/1.response new file mode 100755 index 0000000000000..9703a466ab867 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/1.response @@ -0,0 +1,35 @@ +{ + "kind": "Service", + "apiVersion": "v1", + "metadata": { + "name": "svc1", + "namespace": "myproject", + "selfLink": "/api/v1/namespaces/myproject/services/svc1", + "uid": "d8b96f0b-3d6f-11e7-8ef0-c85b76034b7b", + "resourceVersion": "3525", + "creationTimestamp": "2017-05-20T15:20:24Z", + "labels": { + "app": "svc1", + "new-label": "foo" + }, + "annotations": { + "kubectl.kubernetes.io/last-applied-configuration": "{\"kind\":\"Service\",\"metadata\":{\"annotations\":{},\"labels\":{\"app\":\"svc1\",\"new-label\":\"foo\"},\"name\":\"svc1\",\"namespace\":\"myproject\"},\"spec\":{\"ports\":[{\"name\":\"80\",\"port\":81,\"protocol\":\"TCP\",\"targetPort\":81}],\"sessionAffinity\":\"None\",\"type\":\"ClusterIP\"},\"status\":{\"loadBalancer\":{}}}\n" + } + }, + "spec": { + "ports": [ + { + "name": "80", + "protocol": "TCP", + "port": 81, + "targetPort": 81 + } + ], + "clusterIP": "172.30.32.183", + "type": "ClusterIP", + "sessionAffinity": "None" + }, + "status": { + "loadBalancer": {} + } +} \ No newline at end of file diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/2.edited b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/2.edited new file mode 100755 index 0000000000000..1769ec8faedeb --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/2.edited @@ -0,0 +1,38 @@ +# Please edit the 'last-applied-configuration' annotations below. +# Lines beginning with a '#' will be ignored, and an empty file will abort the edit. +# +apiVersion: v1 +items: +- apiVersion: v1 + data: + baz: qux + foo: changed-value + new-data: new-value + new-data2: new-value + new-data3: newivalue + kind: ConfigMap + metadata: + annotations: {} + name: cm1 + namespace: myproject +- kind: Service + metadata: + annotations: {} + labels: + app: svc1 + new-label: foo + new-label2: foo2 + name: svc1 + namespace: myproject + spec: + ports: + - name: "80" + port: 82 + protocol: TCP + targetPort: 81 + sessionAffinity: None + type: ClusterIP + status: + loadBalancer: {} +kind: List +metadata: {} diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/2.original b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/2.original new file mode 100755 index 0000000000000..82770327ca117 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/2.original @@ -0,0 +1,36 @@ +# Please edit the 'last-applied-configuration' annotations below. +# Lines beginning with a '#' will be ignored, and an empty file will abort the edit. +# +apiVersion: v1 +items: +- apiVersion: v1 + data: + baz: qux + foo: changed-value + new-data: new-value + new-data2: new-value + kind: ConfigMap + metadata: + annotations: {} + name: cm1 + namespace: myproject +- kind: Service + metadata: + annotations: {} + labels: + app: svc1 + new-label: foo + name: svc1 + namespace: myproject + spec: + ports: + - name: "80" + port: 81 + protocol: TCP + targetPort: 81 + sessionAffinity: None + type: ClusterIP + status: + loadBalancer: {} +kind: List +metadata: {} diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/3.request b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/3.request new file mode 100755 index 0000000000000..4998c9e8686a6 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/3.request @@ -0,0 +1,7 @@ +{ + "metadata": { + "annotations": { + "kubectl.kubernetes.io~1last-applied-configuration": "{\"apiVersion\":\"v1\",\"data\":{\"baz\":\"qux\",\"foo\":\"changed-value\",\"new-data\":\"new-value\",\"new-data2\":\"new-value\",\"new-data3\":\"newivalue\"},\"kind\":\"ConfigMap\",\"metadata\":{\"annotations\":{},\"name\":\"cm1\",\"namespace\":\"myproject\"}}\n" + } + } +} \ No newline at end of file diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/3.response b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/3.response new file mode 100755 index 0000000000000..e2115785efbc5 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/3.response @@ -0,0 +1,21 @@ +{ + "kind": "ConfigMap", + "apiVersion": "v1", + "metadata": { + "name": "cm1", + "namespace": "myproject", + "selfLink": "/api/v1/namespaces/myproject/configmaps/cm1", + "uid": "cc08a131-3d6f-11e7-8ef0-c85b76034b7b", + "resourceVersion": "3554", + "creationTimestamp": "2017-05-20T15:20:03Z", + "annotations": { + "kubectl.kubernetes.io/last-applied-configuration": "{\"apiVersion\":\"v1\",\"data\":{\"baz\":\"qux\",\"foo\":\"changed-value\",\"new-data\":\"new-value\",\"new-data2\":\"new-value\",\"new-data3\":\"newivalue\"},\"kind\":\"ConfigMap\",\"metadata\":{\"annotations\":{},\"name\":\"cm1\",\"namespace\":\"myproject\"}}\n" + } + }, + "data": { + "baz": "qux", + "foo": "changed-value", + "new-data": "new-value", + "new-data2": "new-value" + } +} \ No newline at end of file diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/4.request b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/4.request new file mode 100755 index 0000000000000..a9f7bce400e25 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/4.request @@ -0,0 +1,7 @@ +{ + "metadata": { + "annotations": { + "kubectl.kubernetes.io~1last-applied-configuration": "{\"kind\":\"Service\",\"metadata\":{\"annotations\":{},\"labels\":{\"app\":\"svc1\",\"new-label\":\"foo\",\"new-label2\":\"foo2\"},\"name\":\"svc1\",\"namespace\":\"myproject\"},\"spec\":{\"ports\":[{\"name\":\"80\",\"port\":82,\"protocol\":\"TCP\",\"targetPort\":81}],\"sessionAffinity\":\"None\",\"type\":\"ClusterIP\"},\"status\":{\"loadBalancer\":{}}}\n" + } + } +} \ No newline at end of file diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/4.response b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/4.response new file mode 100755 index 0000000000000..dcf030403c1e5 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/4.response @@ -0,0 +1,35 @@ +{ + "kind": "Service", + "apiVersion": "v1", + "metadata": { + "name": "svc1", + "namespace": "myproject", + "selfLink": "/api/v1/namespaces/myproject/services/svc1", + "uid": "d8b96f0b-3d6f-11e7-8ef0-c85b76034b7b", + "resourceVersion": "3555", + "creationTimestamp": "2017-05-20T15:20:24Z", + "labels": { + "app": "svc1", + "new-label": "foo" + }, + "annotations": { + "kubectl.kubernetes.io/last-applied-configuration": "{\"kind\":\"Service\",\"metadata\":{\"annotations\":{},\"labels\":{\"app\":\"svc1\",\"new-label\":\"foo\",\"new-label2\":\"foo2\"},\"name\":\"svc1\",\"namespace\":\"myproject\"},\"spec\":{\"ports\":[{\"name\":\"80\",\"port\":82,\"protocol\":\"TCP\",\"targetPort\":81}],\"sessionAffinity\":\"None\",\"type\":\"ClusterIP\"},\"status\":{\"loadBalancer\":{}}}\n" + } + }, + "spec": { + "ports": [ + { + "name": "80", + "protocol": "TCP", + "port": 81, + "targetPort": 81 + } + ], + "clusterIP": "172.30.32.183", + "type": "ClusterIP", + "sessionAffinity": "None" + }, + "status": { + "loadBalancer": {} + } +} \ No newline at end of file diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/test.yaml b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/test.yaml new file mode 100755 index 0000000000000..ef9f5588de131 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-list/test.yaml @@ -0,0 +1,40 @@ +description: add a testcase description +mode: edit-last-applied +args: +- configmaps/cm1 +- service/svc1 +namespace: "myproject" +expectedStdout: +- configmap "cm1" edited +- service "svc1" edited +expectedExitCode: 0 +steps: +- type: request + expectedMethod: GET + expectedPath: /api/v1/namespaces/myproject/configmaps/cm1 + expectedInput: 0.request + resultingStatusCode: 200 + resultingOutput: 0.response +- type: request + expectedMethod: GET + expectedPath: /api/v1/namespaces/myproject/services/svc1 + expectedInput: 1.request + resultingStatusCode: 200 + resultingOutput: 1.response +- type: edit + expectedInput: 2.original + resultingOutput: 2.edited +- type: request + expectedMethod: PATCH + expectedPath: /api/v1/namespaces/myproject/configmaps/cm1 + expectedContentType: application/merge-patch+json + expectedInput: 3.request + resultingStatusCode: 200 + resultingOutput: 3.response +- type: request + expectedMethod: PATCH + expectedPath: /api/v1/namespaces/myproject/services/svc1 + expectedContentType: application/merge-patch+json + expectedInput: 4.request + resultingStatusCode: 200 + resultingOutput: 4.response diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/0.request b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/0.request new file mode 100755 index 0000000000000..e69de29bb2d1d diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/0.response b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/0.response new file mode 100755 index 0000000000000..23ee361bca80f --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/0.response @@ -0,0 +1,35 @@ +{ + "kind": "Service", + "apiVersion": "v1", + "metadata": { + "name": "svc1", + "namespace": "myproject", + "selfLink": "/api/v1/namespaces/myproject/services/svc1", + "uid": "1e16d988-3d72-11e7-8ef0-c85b76034b7b", + "resourceVersion": "3731", + "creationTimestamp": "2017-05-20T15:36:39Z", + "labels": { + "app": "svc1", + "new-label": "foo" + }, + "annotations": { + "kubectl.kubernetes.io/last-applied-configuration": "{\"kind\":\"Service\",\"metadata\":{\"annotations\":{},\"labels\":{\"app\":\"svc1\",\"new-label\":\"foo\"},\"name\":\"svc1\",\"namespace\":\"myproject\"},\"spec\":{\"ports\":[{\"name\":\"80\",\"port\":81,\"protocol\":\"TCP\",\"targetPort\":81}],\"sessionAffinity\":\"None\",\"type\":\"ClusterIP\"},\"status\":{\"loadBalancer\":{}}}\n" + } + }, + "spec": { + "ports": [ + { + "name": "80", + "protocol": "TCP", + "port": 81, + "targetPort": 81 + } + ], + "clusterIP": "172.30.105.209", + "type": "ClusterIP", + "sessionAffinity": "None" + }, + "status": { + "loadBalancer": {} + } +} \ No newline at end of file diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/1.edited b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/1.edited new file mode 100755 index 0000000000000..4f5e571f46812 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/1.edited @@ -0,0 +1,21 @@ +# Please edit the 'last-applied-configuration' annotations below. +# Lines beginning with a '#' will be ignored, and an empty file will abort the edit. +# +kind: Service +metadata: + annotations: {} + labels: + app: svc1 + new-label: foo + name: svc1 + namespace: myproject +spec + ports: + name: "80" + port: 81 + protocol: TCP + targetPort: 81 + sessionAffinity: None + type: ClusterIP +status: + loadBalancer: { diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/1.original b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/1.original new file mode 100755 index 0000000000000..8a290b4b12d04 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/1.original @@ -0,0 +1,21 @@ +# Please edit the 'last-applied-configuration' annotations below. +# Lines beginning with a '#' will be ignored, and an empty file will abort the edit. +# +kind: Service +metadata: + annotations: {} + labels: + app: svc1 + new-label: foo + name: svc1 + namespace: myproject +spec: + ports: + - name: "80" + port: 81 + protocol: TCP + targetPort: 81 + sessionAffinity: None + type: ClusterIP +status: + loadBalancer: {} diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/2.edited b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/2.edited new file mode 100755 index 0000000000000..e7759c9c22436 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/2.edited @@ -0,0 +1,24 @@ +# Please edit the 'last-applied-configuration' annotations below. +# Lines beginning with a '#' will be ignored, and an empty file will abort the edit. +# +# The edited file had a syntax error: error converting YAML to JSON: yaml: line 12: could not find expected ':' +# +kind: Service +metadata: + annotations: {} + labels: + app: svc1 + new-label: foo + new-label1: foo1 + name: svc1 + namespace: myproject +spec: + ports: + - name: "80" + port: 81 + protocol: TCP + targetPort: 81 + sessionAffinity: None + type: ClusterIP +status: + loadBalancer: {} diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/2.original b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/2.original new file mode 100755 index 0000000000000..d17734396ffdf --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/2.original @@ -0,0 +1,23 @@ +# Please edit the 'last-applied-configuration' annotations below. +# Lines beginning with a '#' will be ignored, and an empty file will abort the edit. +# +# The edited file had a syntax error: error converting YAML to JSON: yaml: line 12: could not find expected ':' +# +kind: Service +metadata: + annotations: {} + labels: + app: svc1 + new-label: foo + name: svc1 + namespace: myproject +spec + ports: + name: "80" + port: 81 + protocol: TCP + targetPort: 81 + sessionAffinity: None + type: ClusterIP +status: + loadBalancer: { diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/3.request b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/3.request new file mode 100755 index 0000000000000..c511d3965f83a --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/3.request @@ -0,0 +1,7 @@ +{ + "metadata": { + "annotations": { + "kubectl.kubernetes.io~1last-applied-configuration": "{\"kind\":\"Service\",\"metadata\":{\"annotations\":{},\"labels\":{\"app\":\"svc1\",\"new-label\":\"foo\",\"new-label1\":\"foo1\"},\"name\":\"svc1\",\"namespace\":\"myproject\"},\"spec\":{\"ports\":[{\"name\":\"80\",\"port\":81,\"protocol\":\"TCP\",\"targetPort\":81}],\"sessionAffinity\":\"None\",\"type\":\"ClusterIP\"},\"status\":{\"loadBalancer\":{}}}\n" + } + } +} \ No newline at end of file diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/3.response b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/3.response new file mode 100755 index 0000000000000..ca945db3ec1d7 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/3.response @@ -0,0 +1,35 @@ +{ + "kind": "Service", + "apiVersion": "v1", + "metadata": { + "name": "svc1", + "namespace": "myproject", + "selfLink": "/api/v1/namespaces/myproject/services/svc1", + "uid": "1e16d988-3d72-11e7-8ef0-c85b76034b7b", + "resourceVersion": "3857", + "creationTimestamp": "2017-05-20T15:36:39Z", + "labels": { + "app": "svc1", + "new-label": "foo" + }, + "annotations": { + "kubectl.kubernetes.io/last-applied-configuration": "{\"kind\":\"Service\",\"metadata\":{\"annotations\":{},\"labels\":{\"app\":\"svc1\",\"new-label\":\"foo\",\"new-label1\":\"foo1\"},\"name\":\"svc1\",\"namespace\":\"myproject\"},\"spec\":{\"ports\":[{\"name\":\"80\",\"port\":81,\"protocol\":\"TCP\",\"targetPort\":81}],\"sessionAffinity\":\"None\",\"type\":\"ClusterIP\"},\"status\":{\"loadBalancer\":{}}}\n" + } + }, + "spec": { + "ports": [ + { + "name": "80", + "protocol": "TCP", + "port": 81, + "targetPort": 81 + } + ], + "clusterIP": "172.30.105.209", + "type": "ClusterIP", + "sessionAffinity": "None" + }, + "status": { + "loadBalancer": {} + } +} \ No newline at end of file diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/test.yaml b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/test.yaml new file mode 100755 index 0000000000000..f500dc65eddf2 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied-syntax-error/test.yaml @@ -0,0 +1,28 @@ +description: edit with a syntax error, then re-edit and save +mode: edit-last-applied +args: +- service/svc1 +namespace: myproject +expectedStdout: +- "service \"svc1\" edited" +expectedExitCode: 0 +steps: +- type: request + expectedMethod: GET + expectedPath: /api/v1/namespaces/myproject/services/svc1 + expectedInput: 0.request + resultingStatusCode: 200 + resultingOutput: 0.response +- type: edit + expectedInput: 1.original + resultingOutput: 1.edited +- type: edit + expectedInput: 2.original + resultingOutput: 2.edited +- type: request + expectedMethod: PATCH + expectedPath: /api/v1/namespaces/myproject/services/svc1 + expectedContentType: application/merge-patch+json + expectedInput: 3.request + resultingStatusCode: 200 + resultingOutput: 3.response diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/0.request b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/0.request new file mode 100755 index 0000000000000..e69de29bb2d1d diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/0.response b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/0.response new file mode 100755 index 0000000000000..7bb8832afbc81 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/0.response @@ -0,0 +1,38 @@ +{ + "kind": "Service", + "apiVersion": "v1", + "metadata": { + "name": "svc1", + "namespace": "myproject", + "selfLink": "/api/v1/namespaces/myproject/services/svc1", + "uid": "bc66b442-3d6a-11e7-8ef0-c85b76034b7b", + "resourceVersion": "3036", + "creationTimestamp": "2017-05-20T14:43:49Z", + "labels": { + "app": "svc1", + "new-label": "new-value" + }, + "annotations": { + "kubectl.kubernetes.io/last-applied-configuration": "{\"apiVersion\":\"v1\",\"kind\":\"Service\",\"metadata\":{\"annotations\":{},\"creationTimestamp\":\"2017-02-01T21:14:09Z\",\"labels\":{\"app\":\"svc1\",\"new-label\":\"new-value\"},\"name\":\"svc1\",\"namespace\":\"myproject\",\"resourceVersion\":\"20820\"},\"spec\":{\"ports\":[{\"name\":\"80\",\"port\":81,\"protocol\":\"TCP\",\"targetPort\":80}],\"selector\":{\"app\":\"svc1\"},\"sessionAffinity\":\"None\",\"type\":\"ClusterIP\"},\"status\":{\"loadBalancer\":{}}}\n" + } + }, + "spec": { + "ports": [ + { + "name": "80", + "protocol": "TCP", + "port": 81, + "targetPort": 80 + } + ], + "selector": { + "app": "svc1" + }, + "clusterIP": "172.30.136.24", + "type": "ClusterIP", + "sessionAffinity": "None" + }, + "status": { + "loadBalancer": {} + } +} \ No newline at end of file diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/1.edited b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/1.edited new file mode 100755 index 0000000000000..22e33fb814b6b --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/1.edited @@ -0,0 +1,26 @@ +# Please edit the 'last-applied-configuration' annotations below. +# Lines beginning with a '#' will be ignored, and an empty file will abort the edit. +# +apiVersion: v1 +kind: Service +metadata: + annotations: {} + creationTimestamp: 2017-02-01T21:14:09Z + labels: + app: svc1 + new-label: new-value + name: svc1 + namespace: myproject + resourceVersion: "20820" +spec: + ports: + - name: "80" + port: 81 + protocol: TCP + targetPort: 92 + selector: + app: svc1 + sessionAffinity: None + type: ClusterIP +status: + loadBalancer: {} diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/1.original b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/1.original new file mode 100755 index 0000000000000..e863ac7098cf7 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/1.original @@ -0,0 +1,26 @@ +# Please edit the 'last-applied-configuration' annotations below. +# Lines beginning with a '#' will be ignored, and an empty file will abort the edit. +# +apiVersion: v1 +kind: Service +metadata: + annotations: {} + creationTimestamp: 2017-02-01T21:14:09Z + labels: + app: svc1 + new-label: new-value + name: svc1 + namespace: myproject + resourceVersion: "20820" +spec: + ports: + - name: "80" + port: 81 + protocol: TCP + targetPort: 80 + selector: + app: svc1 + sessionAffinity: None + type: ClusterIP +status: + loadBalancer: {} diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/2.request b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/2.request new file mode 100755 index 0000000000000..448ebbba2b395 --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/2.request @@ -0,0 +1,7 @@ +{ + "metadata": { + "annotations": { + "kubectl.kubernetes.io~1last-applied-configuration": "{\"apiVersion\":\"v1\",\"kind\":\"Service\",\"metadata\":{\"annotations\":{},\"creationTimestamp\":\"2017-02-01T21:14:09Z\",\"labels\":{\"app\":\"svc1\",\"new-label\":\"new-value\"},\"name\":\"svc1\",\"namespace\":\"myproject\",\"resourceVersion\":\"20820\"},\"spec\":{\"ports\":[{\"name\":\"80\",\"port\":81,\"protocol\":\"TCP\",\"targetPort\":92}],\"selector\":{\"app\":\"svc1\"},\"sessionAffinity\":\"None\",\"type\":\"ClusterIP\"},\"status\":{\"loadBalancer\":{}}}\n" + } + } +} \ No newline at end of file diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/2.response b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/2.response new file mode 100755 index 0000000000000..d5b2b9b89883e --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/2.response @@ -0,0 +1,38 @@ +{ + "kind": "Service", + "apiVersion": "v1", + "metadata": { + "name": "svc1", + "namespace": "myproject", + "selfLink": "/api/v1/namespaces/myproject/services/svc1", + "uid": "bc66b442-3d6a-11e7-8ef0-c85b76034b7b", + "resourceVersion": "3093", + "creationTimestamp": "2017-05-20T14:43:49Z", + "labels": { + "app": "svc1", + "new-label": "new-value" + }, + "annotations": { + "kubectl.kubernetes.io/last-applied-configuration": "{\"apiVersion\":\"v1\",\"kind\":\"Service\",\"metadata\":{\"annotations\":{},\"creationTimestamp\":\"2017-02-01T21:14:09Z\",\"labels\":{\"app\":\"svc1\",\"new-label\":\"new-value\"},\"name\":\"svc1\",\"namespace\":\"myproject\",\"resourceVersion\":\"20820\"},\"spec\":{\"ports\":[{\"name\":\"80\",\"port\":81,\"protocol\":\"TCP\",\"targetPort\":92}],\"selector\":{\"app\":\"svc1\"},\"sessionAffinity\":\"None\",\"type\":\"ClusterIP\"},\"status\":{\"loadBalancer\":{}}}\n" + } + }, + "spec": { + "ports": [ + { + "name": "80", + "protocol": "TCP", + "port": 81, + "targetPort": 80 + } + ], + "selector": { + "app": "svc1" + }, + "clusterIP": "172.30.136.24", + "type": "ClusterIP", + "sessionAffinity": "None" + }, + "status": { + "loadBalancer": {} + } +} \ No newline at end of file diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/test.yaml b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/test.yaml new file mode 100755 index 0000000000000..a284da093f2bc --- /dev/null +++ b/pkg/kubectl/cmd/testdata/edit/testcase-apply-edit-last-applied/test.yaml @@ -0,0 +1,27 @@ +description: add a testcase description +mode: edit-last-applied +args: +- service +- svc1 +outputFormat: yaml +namespace: myproject +expectedStdout: +- service "svc1" edited +expectedExitCode: 0 +steps: +- type: request + expectedMethod: GET + expectedPath: /api/v1/namespaces/myproject/services/svc1 + expectedInput: 0.request + resultingStatusCode: 200 + resultingOutput: 0.response +- type: edit + expectedInput: 1.original + resultingOutput: 1.edited +- type: request + expectedMethod: PATCH + expectedPath: /api/v1/namespaces/myproject/services/svc1 + expectedContentType: application/merge-patch+json + expectedInput: 2.request + resultingStatusCode: 200 + resultingOutput: 2.response diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-edit-error-reedit/4.request b/pkg/kubectl/cmd/testdata/edit/testcase-edit-error-reedit/4.request index f6ff34a556d2a..c9c4f60ab1588 100755 --- a/pkg/kubectl/cmd/testdata/edit/testcase-edit-error-reedit/4.request +++ b/pkg/kubectl/cmd/testdata/edit/testcase-edit-error-reedit/4.request @@ -1,15 +1,20 @@ { "spec": { - "ports": [ + "$setElementOrder/ports": [ { - "$patch": "delete", - "port": 81 - }, + "port": 82 + } + ], + "ports": [ { "name": "80", "port": 82, "protocol": "TCP", "targetPort": 80 + }, + { + "$patch": "delete", + "port": 81 } ] } diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-list-errors/3.request b/pkg/kubectl/cmd/testdata/edit/testcase-list-errors/3.request index a5d17bf7e0b0b..cbf369bb0cc6c 100755 --- a/pkg/kubectl/cmd/testdata/edit/testcase-list-errors/3.request +++ b/pkg/kubectl/cmd/testdata/edit/testcase-list-errors/3.request @@ -1,5 +1,10 @@ { "spec": { + "$setElementOrder/ports": [ + { + "port": 82 + } + ], "clusterIP": "10.0.0.10", "ports": [ { diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-list-errors/6.request b/pkg/kubectl/cmd/testdata/edit/testcase-list-errors/6.request index 3dd3605fad0e7..90841f3415905 100755 --- a/pkg/kubectl/cmd/testdata/edit/testcase-list-errors/6.request +++ b/pkg/kubectl/cmd/testdata/edit/testcase-list-errors/6.request @@ -5,16 +5,21 @@ } }, "spec": { - "ports": [ + "$setElementOrder/ports": [ { - "$patch": "delete", - "port": 82 - }, + "port": 83 + } + ], + "ports": [ { "name": "80", "port": 83, "protocol": "VHF", "targetPort": 81 + }, + { + "$patch": "delete", + "port": 82 } ] } diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-list-errors/9.request b/pkg/kubectl/cmd/testdata/edit/testcase-list-errors/9.request index 2fe0faa445d09..794280402561e 100755 --- a/pkg/kubectl/cmd/testdata/edit/testcase-list-errors/9.request +++ b/pkg/kubectl/cmd/testdata/edit/testcase-list-errors/9.request @@ -5,16 +5,21 @@ } }, "spec": { - "ports": [ + "$setElementOrder/ports": [ { - "$patch": "delete", - "port": 82 - }, + "port": 83 + } + ], + "ports": [ { "name": "80", "port": 83, "protocol": "TCP", "targetPort": 81 + }, + { + "$patch": "delete", + "port": 82 } ] } diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-list-record/4.request b/pkg/kubectl/cmd/testdata/edit/testcase-list-record/4.request index dad8e1fd0d3df..3520e4699fc11 100755 --- a/pkg/kubectl/cmd/testdata/edit/testcase-list-record/4.request +++ b/pkg/kubectl/cmd/testdata/edit/testcase-list-record/4.request @@ -8,16 +8,21 @@ } }, "spec": { - "ports": [ + "$setElementOrder/ports": [ { - "$patch": "delete", - "port": 81 - }, + "port": 82 + } + ], + "ports": [ { "name": "80", "port": 82, "protocol": "TCP", "targetPort": 81 + }, + { + "$patch": "delete", + "port": 81 } ] } diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-list/4.request b/pkg/kubectl/cmd/testdata/edit/testcase-list/4.request index f1274be09abc9..572a71819219b 100755 --- a/pkg/kubectl/cmd/testdata/edit/testcase-list/4.request +++ b/pkg/kubectl/cmd/testdata/edit/testcase-list/4.request @@ -5,16 +5,21 @@ } }, "spec": { - "ports": [ + "$setElementOrder/ports": [ { - "$patch": "delete", - "port": 81 - }, + "port": 82 + } + ], + "ports": [ { "name": "80", "port": 82, "protocol": "TCP", "targetPort": 81 + }, + { + "$patch": "delete", + "port": 81 } ] } diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-not-update-annotation/2.request b/pkg/kubectl/cmd/testdata/edit/testcase-not-update-annotation/2.request index 9560f5bb88ba9..bd858120ddf12 100755 --- a/pkg/kubectl/cmd/testdata/edit/testcase-not-update-annotation/2.request +++ b/pkg/kubectl/cmd/testdata/edit/testcase-not-update-annotation/2.request @@ -1,7 +1,7 @@ { - "metadata": { - "labels": { - "new-label": "new-value" - } - } + "metadata": { + "labels": { + "new-label": "new-value" + } + } } \ No newline at end of file diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-single-service/2.request b/pkg/kubectl/cmd/testdata/edit/testcase-single-service/2.request index 4a32ac7519dee..a69f19ac2a761 100755 --- a/pkg/kubectl/cmd/testdata/edit/testcase-single-service/2.request +++ b/pkg/kubectl/cmd/testdata/edit/testcase-single-service/2.request @@ -5,16 +5,21 @@ } }, "spec": { - "ports": [ + "$setElementOrder/ports": [ { - "$patch": "delete", - "port": 80 - }, + "port": 81 + } + ], + "ports": [ { "name": "80", "port": 81, "protocol": "TCP", "targetPort": 80 + }, + { + "$patch": "delete", + "port": 80 } ] } diff --git a/pkg/kubectl/cmd/testdata/edit/testcase-update-annotation/2.request b/pkg/kubectl/cmd/testdata/edit/testcase-update-annotation/2.request index b26622634f668..74d44f61ed3e7 100755 --- a/pkg/kubectl/cmd/testdata/edit/testcase-update-annotation/2.request +++ b/pkg/kubectl/cmd/testdata/edit/testcase-update-annotation/2.request @@ -1,10 +1,10 @@ { - "metadata": { - "annotations": { - "kubectl.kubernetes.io/last-applied-configuration": "{\"apiVersion\":\"v1\",\"kind\":\"Service\",\"metadata\":{\"annotations\":{},\"creationTimestamp\":\"2017-02-27T19:40:53Z\",\"labels\":{\"app\":\"svc1\",\"new-label\":\"new-value\"},\"name\":\"svc1\",\"namespace\":\"edit-test\",\"resourceVersion\":\"670\",\"selfLink\":\"/api/v1/namespaces/edit-test/services/svc1\",\"uid\":\"a6c11186-fd24-11e6-b53c-480fcf4a5275\"},\"spec\":{\"clusterIP\":\"10.0.0.204\",\"ports\":[{\"name\":\"80\",\"port\":80,\"protocol\":\"TCP\",\"targetPort\":80}],\"selector\":{\"app\":\"svc1\"},\"sessionAffinity\":\"None\",\"type\":\"ClusterIP\"},\"status\":{\"loadBalancer\":{}}}\n" - }, - "labels": { - "new-label": "new-value" - } - } + "metadata": { + "annotations": { + "kubectl.kubernetes.io/last-applied-configuration": "{\"apiVersion\":\"v1\",\"kind\":\"Service\",\"metadata\":{\"annotations\":{},\"creationTimestamp\":\"2017-02-27T19:40:53Z\",\"labels\":{\"app\":\"svc1\",\"new-label\":\"new-value\"},\"name\":\"svc1\",\"namespace\":\"edit-test\",\"resourceVersion\":\"670\",\"selfLink\":\"/api/v1/namespaces/edit-test/services/svc1\",\"uid\":\"a6c11186-fd24-11e6-b53c-480fcf4a5275\"},\"spec\":{\"clusterIP\":\"10.0.0.204\",\"ports\":[{\"name\":\"80\",\"port\":80,\"protocol\":\"TCP\",\"targetPort\":80}],\"selector\":{\"app\":\"svc1\"},\"sessionAffinity\":\"None\",\"type\":\"ClusterIP\"},\"status\":{\"loadBalancer\":{}}}\n" + }, + "labels": { + "new-label": "new-value" + } + } } \ No newline at end of file diff --git a/pkg/kubectl/cmd/util/cached_discovery.go b/pkg/kubectl/cmd/util/cached_discovery.go index 13633262d844e..5b13e22f525b1 100644 --- a/pkg/kubectl/cmd/util/cached_discovery.go +++ b/pkg/kubectl/cmd/util/cached_discovery.go @@ -196,7 +196,7 @@ func (d *CachedDiscoveryClient) writeCachedFile(filename string, obj runtime.Obj return err } - err = f.Chmod(0755) + err = os.Chmod(f.Name(), 0755) if err != nil { return err } diff --git a/pkg/kubectl/cmd/util/editor/editoptions.go b/pkg/kubectl/cmd/util/editor/editoptions.go index 3a5e649bcde12..96a0bca9dfd41 100644 --- a/pkg/kubectl/cmd/util/editor/editoptions.go +++ b/pkg/kubectl/cmd/util/editor/editoptions.go @@ -19,6 +19,7 @@ package editor import ( "bufio" "bytes" + "errors" "fmt" "io" "os" @@ -29,7 +30,7 @@ import ( "github.com/evanphx/json-patch" "github.com/golang/glog" - "k8s.io/apimachinery/pkg/api/errors" + apierrors "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/api/meta" "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" "k8s.io/apimachinery/pkg/runtime" @@ -85,7 +86,7 @@ type editPrinterOptions struct { // Complete completes all the required options func (o *EditOptions) Complete(f cmdutil.Factory, out, errOut io.Writer, args []string) error { - if o.EditMode != NormalEditMode && o.EditMode != EditBeforeCreateMode { + if o.EditMode != NormalEditMode && o.EditMode != EditBeforeCreateMode && o.EditMode != ApplyEditMode { return fmt.Errorf("unsupported edit mode %q", o.EditMode) } if o.Output != "" { @@ -104,8 +105,8 @@ func (o *EditOptions) Complete(f cmdutil.Factory, out, errOut io.Writer, args [] return err } b := resource.NewBuilder(mapper, f.CategoryExpander(), typer, resource.ClientMapperFunc(f.UnstructuredClientForMapping), unstructured.UnstructuredJSONScheme) - if o.EditMode == NormalEditMode { - // when do normal edit we need to always retrieve the latest resource from server + if o.EditMode == NormalEditMode || o.EditMode == ApplyEditMode { + // when do normal edit or apply edit we need to always retrieve the latest resource from server b = b.ResourceTypeOrNameArgs(true, args...).Latest() } r := b.NamespaceParam(cmdNamespace).DefaultNamespace(). @@ -158,7 +159,6 @@ func (o *EditOptions) Run() error { ) containsError := false - // loop until we succeed or cancel editing for { // get the object we're going to serialize as input to the editor @@ -188,7 +188,7 @@ func (o *EditOptions) Run() error { } if o.editPrinterOptions.addHeader { - results.header.writeTo(w) + results.header.writeTo(w, o.EditMode) } if !containsError { @@ -230,7 +230,7 @@ func (o *EditOptions) Run() error { file: file, } containsError = true - fmt.Fprintln(o.ErrOut, results.addError(errors.NewInvalid(api.Kind(""), "", field.ErrorList{field.Invalid(nil, "The edited file failed validation", fmt.Sprintf("%v", err))}), infos[0])) + fmt.Fprintln(o.ErrOut, results.addError(apierrors.NewInvalid(api.Kind(""), "", field.ErrorList{field.Invalid(nil, "The edited file failed validation", fmt.Sprintf("%v", err))}), infos[0])) continue } @@ -280,6 +280,8 @@ func (o *EditOptions) Run() error { switch o.EditMode { case NormalEditMode: err = o.visitToPatch(infos, updatedVisitor, &results) + case ApplyEditMode: + err = o.visitToApplyEditPatch(infos, updatedVisitor) case EditBeforeCreateMode: err = o.visitToCreate(updatedVisitor) default: @@ -326,6 +328,31 @@ func (o *EditOptions) Run() error { return err } return editFn(infos) + case ApplyEditMode: + infos, err := o.OriginalResult.Infos() + if err != nil { + return err + } + var annotationInfos []*resource.Info + for i := range infos { + data, err := kubectl.GetOriginalConfiguration(infos[i].Mapping, infos[i].Object) + if err != nil { + return err + } + if data == nil { + continue + } + + tempInfos, err := o.updatedResultGetter(data).Infos() + if err != nil { + return err + } + annotationInfos = append(annotationInfos, tempInfos[0]) + } + if len(annotationInfos) == 0 { + return errors.New("no last-applied-configuration annotation found on resources, to create the annotation, use command `kubectl apply set-last-applied --create-annotation`") + } + return editFn(annotationInfos) // If doing an edit before created, we don't want a list and instead want the normal behavior as kubectl create. case EditBeforeCreateMode: return o.OriginalResult.Visit(func(info *resource.Info, err error) error { @@ -336,6 +363,110 @@ func (o *EditOptions) Run() error { } } +func (o *EditOptions) visitToApplyEditPatch(originalInfos []*resource.Info, patchVisitor resource.Visitor) error { + err := patchVisitor.Visit(func(info *resource.Info, incomingErr error) error { + editObjUID, err := meta.NewAccessor().UID(info.Object) + if err != nil { + return err + } + + var originalInfo *resource.Info + for _, i := range originalInfos { + originalObjUID, err := meta.NewAccessor().UID(i.Object) + if err != nil { + return err + } + if editObjUID == originalObjUID { + originalInfo = i + break + } + } + if originalInfo == nil { + return fmt.Errorf("no original object found for %#v", info.Object) + } + + originalJS, err := encodeToJson(o.Encoder, originalInfo.Object) + if err != nil { + return err + } + + editedJS, err := encodeToJson(o.Encoder, info.Object) + if err != nil { + return err + } + + if reflect.DeepEqual(originalJS, editedJS) { + cmdutil.PrintSuccess(o.Mapper, false, o.Out, info.Mapping.Resource, info.Name, false, "skipped") + return nil + } else { + err := o.annotationPatch(info) + if err != nil { + return err + } + cmdutil.PrintSuccess(o.Mapper, false, o.Out, info.Mapping.Resource, info.Name, false, "edited") + return nil + } + }) + return err +} + +func (o *EditOptions) annotationPatch(update *resource.Info) error { + patch, _, patchType, err := GetApplyPatch(update.Object, o.Encoder) + if err != nil { + return err + } + mapping := update.ResourceMapping() + client, err := o.f.UnstructuredClientForMapping(mapping) + if err != nil { + return err + } + helper := resource.NewHelper(client, mapping) + _, err = helper.Patch(o.CmdNamespace, update.Name, patchType, patch) + if err != nil { + return err + } + return nil +} + +func GetApplyPatch(obj runtime.Object, codec runtime.Encoder) ([]byte, []byte, types.PatchType, error) { + beforeJSON, err := encodeToJson(codec, obj) + if err != nil { + return nil, []byte(""), types.MergePatchType, err + } + objCopy, err := api.Scheme.Copy(obj) + if err != nil { + return nil, beforeJSON, types.MergePatchType, err + } + accessor := meta.NewAccessor() + annotations, err := accessor.Annotations(objCopy) + if err != nil { + return nil, beforeJSON, types.MergePatchType, err + } + if annotations == nil { + annotations = map[string]string{} + } + annotations[api.LastAppliedConfigAnnotation] = string(beforeJSON) + accessor.SetAnnotations(objCopy, annotations) + afterJSON, err := encodeToJson(codec, objCopy) + if err != nil { + return nil, beforeJSON, types.MergePatchType, err + } + patch, err := jsonpatch.CreateMergePatch(beforeJSON, afterJSON) + return patch, beforeJSON, types.MergePatchType, err +} + +func encodeToJson(codec runtime.Encoder, obj runtime.Object) ([]byte, error) { + serialization, err := runtime.Encode(codec, obj) + if err != nil { + return nil, err + } + js, err := yaml.ToJSON(serialization) + if err != nil { + return nil, err + } + return js, nil +} + func getPrinter(format string) *editPrinterOptions { switch format { case "json": @@ -386,22 +517,12 @@ func (o *EditOptions) visitToPatch( return fmt.Errorf("no original object found for %#v", info.Object) } - originalSerialization, err := runtime.Encode(o.Encoder, originalInfo.Object) - if err != nil { - return err - } - editedSerialization, err := runtime.Encode(o.Encoder, info.Object) + originalJS, err := encodeToJson(o.Encoder, originalInfo.Object) if err != nil { return err } - // compute the patch on a per-item basis - // use strategic merge to create a patch - originalJS, err := yaml.ToJSON(originalSerialization) - if err != nil { - return err - } - editedJS, err := yaml.ToJSON(editedSerialization) + editedJS, err := encodeToJson(o.Encoder, info.Object) if err != nil { return err } @@ -501,6 +622,7 @@ type EditMode string const ( NormalEditMode EditMode = "normal_mode" EditBeforeCreateMode EditMode = "edit_before_create_mode" + ApplyEditMode EditMode = "edit_last_applied_mode" ) // editReason preserves a message about the reason this file must be edited again @@ -515,12 +637,20 @@ type editHeader struct { } // writeTo outputs the current header information into a stream -func (h *editHeader) writeTo(w io.Writer) error { - fmt.Fprint(w, `# Please edit the object below. Lines beginning with a '#' will be ignored, +func (h *editHeader) writeTo(w io.Writer, editMode EditMode) error { + if editMode == ApplyEditMode { + fmt.Fprint(w, `# Please edit the 'last-applied-configuration' annotations below. +# Lines beginning with a '#' will be ignored, and an empty file will abort the edit. +# +`) + } else { + fmt.Fprint(w, `# Please edit the object below. Lines beginning with a '#' will be ignored, # and an empty file will abort the edit. If an error occurs while saving this file will be # reopened with the relevant failures. # `) + } + for _, r := range h.reasons { if len(r.other) > 0 { fmt.Fprintf(w, "# %s:\n", r.head) @@ -552,12 +682,12 @@ type editResults struct { func (r *editResults) addError(err error, info *resource.Info) string { switch { - case errors.IsInvalid(err): + case apierrors.IsInvalid(err): r.edit = append(r.edit, info) reason := editReason{ head: fmt.Sprintf("%s %q was not valid", info.Mapping.Resource, info.Name), } - if err, ok := err.(errors.APIStatus); ok { + if err, ok := err.(apierrors.APIStatus); ok { if details := err.Status().Details; details != nil { for _, cause := range details.Causes { reason.other = append(reason.other, fmt.Sprintf("%s: %s", cause.Field, cause.Message)) @@ -566,7 +696,7 @@ func (r *editResults) addError(err error, info *resource.Info) string { } r.header.reasons = append(r.header.reasons, reason) return fmt.Sprintf("error: %s %q is invalid", info.Mapping.Resource, info.Name) - case errors.IsNotFound(err): + case apierrors.IsNotFound(err): r.notfound++ return fmt.Sprintf("error: %s %q could not be found on the server", info.Mapping.Resource, info.Name) default: diff --git a/pkg/kubectl/cmd/util/helpers.go b/pkg/kubectl/cmd/util/helpers.go index fc7e2b5f1e93c..867d5c55cea36 100644 --- a/pkg/kubectl/cmd/util/helpers.go +++ b/pkg/kubectl/cmd/util/helpers.go @@ -436,7 +436,7 @@ func AddApplyAnnotationFlags(cmd *cobra.Command) { } func AddApplyAnnotationVarFlags(cmd *cobra.Command, applyAnnotation *bool) { - cmd.Flags().BoolVar(applyAnnotation, ApplyAnnotationsFlag, false, "If true, the configuration of current object will be saved in its annotation. This is useful when you want to perform kubectl apply on this object in the future.") + cmd.Flags().BoolVar(applyAnnotation, ApplyAnnotationsFlag, false, "If true, the configuration of current object will be saved in its annotation. Otherwise, the annotation will be unchanged. This flag is useful when you want to perform kubectl apply on this object in the future.") } // AddGeneratorFlags adds flags common to resource generation commands diff --git a/pkg/kubectl/cmd/util/openapi/openapi.go b/pkg/kubectl/cmd/util/openapi/openapi.go index 1ab98ee9e014d..7ee40945c2a09 100644 --- a/pkg/kubectl/cmd/util/openapi/openapi.go +++ b/pkg/kubectl/cmd/util/openapi/openapi.go @@ -370,15 +370,15 @@ func (o *Resources) getGroupVersionKind(s spec.Schema) (schema.GroupVersionKind, if !ok { return empty, fmt.Errorf("%s extension has unexpected type %T in %s", groupVersionKindExtensionKey, gvk, s.Extensions) } - group, ok := gvkMap["Group"].(string) + group, ok := gvkMap["group"].(string) if !ok { return empty, fmt.Errorf("%s extension missing Group: %v", groupVersionKindExtensionKey, gvkMap) } - version, ok := gvkMap["Version"].(string) + version, ok := gvkMap["version"].(string) if !ok { return empty, fmt.Errorf("%s extension missing Version: %v", groupVersionKindExtensionKey, gvkMap) } - kind, ok := gvkMap["Kind"].(string) + kind, ok := gvkMap["kind"].(string) if !ok { return empty, fmt.Errorf("%s extension missing Kind: %v", groupVersionKindExtensionKey, gvkMap) } diff --git a/pkg/kubectl/rolling_updater.go b/pkg/kubectl/rolling_updater.go index bea9b96ee503a..c323f96585e27 100644 --- a/pkg/kubectl/rolling_updater.go +++ b/pkg/kubectl/rolling_updater.go @@ -17,7 +17,6 @@ limitations under the License. package kubectl import ( - goerrors "errors" "fmt" "io" "strconv" @@ -616,11 +615,11 @@ func CreateNewControllerFromCurrentController(rcClient coreclient.ReplicationCon } if len(newRc.Spec.Template.Spec.Containers) > 1 && len(cfg.Container) == 0 { - return nil, goerrors.New("Must specify container to update when updating a multi-container pod") + return nil, fmt.Errorf("must specify container to update when updating a multi-container pod") } if len(newRc.Spec.Template.Spec.Containers) == 0 { - return nil, goerrors.New(fmt.Sprintf("Pod has no containers! (%v)", newRc)) + return nil, fmt.Errorf("pod has no containers! (%v)", newRc) } newRc.Spec.Template.Spec.Containers[containerIndex].Image = cfg.Image if len(cfg.PullPolicy) != 0 { diff --git a/pkg/kubelet/BUILD b/pkg/kubelet/BUILD index 4853e7fcb1d45..1c732d19e0983 100644 --- a/pkg/kubelet/BUILD +++ b/pkg/kubelet/BUILD @@ -42,18 +42,22 @@ go_library( "//pkg/api/v1/pod:go_default_library", "//pkg/api/v1/resource:go_default_library", "//pkg/api/v1/validation:go_default_library", + "//pkg/apis/certificates/v1beta1:go_default_library", "//pkg/apis/componentconfig:go_default_library", "//pkg/apis/componentconfig/v1alpha1:go_default_library", "//pkg/capabilities:go_default_library", "//pkg/client/clientset_generated/clientset:go_default_library", + "//pkg/client/clientset_generated/clientset/typed/certificates/v1beta1:go_default_library", "//pkg/client/listers/core/v1:go_default_library", "//pkg/cloudprovider:go_default_library", "//pkg/features:go_default_library", "//pkg/fieldpath:go_default_library", "//pkg/kubelet/apis/cri:go_default_library", "//pkg/kubelet/cadvisor:go_default_library", + "//pkg/kubelet/certificate:go_default_library", "//pkg/kubelet/cm:go_default_library", "//pkg/kubelet/config:go_default_library", + "//pkg/kubelet/configmap:go_default_library", "//pkg/kubelet/container:go_default_library", "//pkg/kubelet/dockershim:go_default_library", "//pkg/kubelet/dockershim/libdocker:go_default_library", @@ -171,6 +175,7 @@ go_test( "//pkg/kubelet/cadvisor/testing:go_default_library", "//pkg/kubelet/cm:go_default_library", "//pkg/kubelet/config:go_default_library", + "//pkg/kubelet/configmap:go_default_library", "//pkg/kubelet/container:go_default_library", "//pkg/kubelet/container/testing:go_default_library", "//pkg/kubelet/eviction:go_default_library", @@ -246,6 +251,7 @@ filegroup( "//pkg/kubelet/client:all-srcs", "//pkg/kubelet/cm:all-srcs", "//pkg/kubelet/config:all-srcs", + "//pkg/kubelet/configmap:all-srcs", "//pkg/kubelet/container:all-srcs", "//pkg/kubelet/custommetrics:all-srcs", "//pkg/kubelet/dockershim:all-srcs", diff --git a/pkg/kubelet/apis/cri/services.go b/pkg/kubelet/apis/cri/services.go index c4c91d6cde03a..11ee088dbf8dd 100644 --- a/pkg/kubelet/apis/cri/services.go +++ b/pkg/kubelet/apis/cri/services.go @@ -72,12 +72,23 @@ type PodSandboxManager interface { PortForward(*runtimeapi.PortForwardRequest) (*runtimeapi.PortForwardResponse, error) } +// ContainerStatsManager contains methods for retriving the container +// statistics. +type ContainerStatsManager interface { + // ContainerStats returns stats of the container. If the container does not + // exist, the call returns an error. + ContainerStats(req *runtimeapi.ContainerStatsRequest) (*runtimeapi.ContainerStatsResponse, error) + // ListContainerStats returns stats of all running containers. + ListContainerStats(req *runtimeapi.ListContainerStatsRequest) (*runtimeapi.ListContainerStatsResponse, error) +} + // RuntimeService interface should be implemented by a container runtime. // The methods should be thread-safe. type RuntimeService interface { RuntimeVersioner ContainerManager PodSandboxManager + ContainerStatsManager // UpdateRuntimeConfig updates runtime configuration if specified UpdateRuntimeConfig(runtimeConfig *runtimeapi.RuntimeConfig) error @@ -98,5 +109,5 @@ type ImageManagerService interface { // RemoveImage removes the image. RemoveImage(image *runtimeapi.ImageSpec) error // ImageFsInfo returns information of the filesystem that is used to store images. - ImageFsInfo() (*runtimeapi.FsInfo, error) + ImageFsInfo(req *runtimeapi.ImageFsInfoRequest) (*runtimeapi.ImageFsInfoResponse, error) } diff --git a/pkg/kubelet/apis/cri/testing/fake_image_service.go b/pkg/kubelet/apis/cri/testing/fake_image_service.go index a751ccdb5c500..6f18cb5490dc6 100644 --- a/pkg/kubelet/apis/cri/testing/fake_image_service.go +++ b/pkg/kubelet/apis/cri/testing/fake_image_service.go @@ -126,7 +126,7 @@ func (r *FakeImageService) RemoveImage(image *runtimeapi.ImageSpec) error { } // ImageFsInfo returns information of the filesystem that is used to store images. -func (r *FakeImageService) ImageFsInfo() (*runtimeapi.FsInfo, error) { +func (r *FakeImageService) ImageFsInfo(req *runtimeapi.ImageFsInfoRequest) (*runtimeapi.ImageFsInfoResponse, error) { r.Lock() defer r.Unlock() diff --git a/pkg/kubelet/apis/cri/testing/fake_runtime_service.go b/pkg/kubelet/apis/cri/testing/fake_runtime_service.go index 12fac28bd0977..37cb26ecb6fa8 100644 --- a/pkg/kubelet/apis/cri/testing/fake_runtime_service.go +++ b/pkg/kubelet/apis/cri/testing/fake_runtime_service.go @@ -389,3 +389,11 @@ func (r *FakeRuntimeService) Attach(req *runtimeapi.AttachRequest) (*runtimeapi. func (r *FakeRuntimeService) UpdateRuntimeConfig(runtimeCOnfig *runtimeapi.RuntimeConfig) error { return nil } + +func (r *FakeRuntimeService) ContainerStats(req *runtimeapi.ContainerStatsRequest) (*runtimeapi.ContainerStatsResponse, error) { + return nil, fmt.Errorf("Not implemented") +} + +func (r *FakeRuntimeService) ListContainerStats(req *runtimeapi.ListContainerStatsRequest) (*runtimeapi.ListContainerStatsResponse, error) { + return nil, fmt.Errorf("Not implemented") +} diff --git a/pkg/kubelet/apis/cri/v1alpha1/api.pb.go b/pkg/kubelet/apis/cri/v1alpha1/api.pb.go index 0e9f0866def43..a8e85effba114 100644 --- a/pkg/kubelet/apis/cri/v1alpha1/api.pb.go +++ b/pkg/kubelet/apis/cri/v1alpha1/api.pb.go @@ -108,8 +108,18 @@ limitations under the License. StatusResponse ImageFsInfoRequest UInt64Value - FsInfo + StorageIdentifier + FilesystemUsage ImageFsInfoResponse + ContainerStatsRequest + ContainerStatsResponse + ListContainerStatsRequest + ContainerStatsFilter + ListContainerStatsResponse + ContainerAttributes + ContainerStats + CpuUsage + MemoryUsage */ package v1alpha1 @@ -2849,104 +2859,328 @@ func (m *UInt64Value) GetValue() uint64 { return 0 } -// FsInfo contains data about filesystem usage. -type FsInfo struct { - // The block device name associated with the filesystem. - Device string `protobuf:"bytes,1,opt,name=device,proto3" json:"device,omitempty"` - // The root directory for the images. - Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` - // CapacityBytes represents the total capacity (bytes) of the filesystems - // underlying storage. - CapacityBytes *UInt64Value `protobuf:"bytes,3,opt,name=capacity_bytes,json=capacityBytes" json:"capacity_bytes,omitempty"` - // AvailableBytes represents the storage space available (bytes) for the - // filesystem. - AvailableBytes *UInt64Value `protobuf:"bytes,4,opt,name=available_bytes,json=availableBytes" json:"available_bytes,omitempty"` +// StorageIdentifier uniquely identify the storage.. +type StorageIdentifier struct { + // UUID of the device. + Uuid string `protobuf:"bytes,1,opt,name=uuid,proto3" json:"uuid,omitempty"` +} + +func (m *StorageIdentifier) Reset() { *m = StorageIdentifier{} } +func (*StorageIdentifier) ProtoMessage() {} +func (*StorageIdentifier) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{83} } + +func (m *StorageIdentifier) GetUuid() string { + if m != nil { + return m.Uuid + } + return "" +} + +// FilesystemUsage provides the filesystem usage information. +type FilesystemUsage struct { + // Timestamp in nanoseconds at which the information were collected. Must be > 0. + Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` + // The underlying storage of the filesystem. + StorageId *StorageIdentifier `protobuf:"bytes,2,opt,name=storage_id,json=storageId" json:"storage_id,omitempty"` // UsedBytes represents the bytes used for images on the filesystem. // This may differ from the total bytes used on the filesystem and may not // equal CapacityBytes - AvailableBytes. - UsedBytes *UInt64Value `protobuf:"bytes,5,opt,name=used_bytes,json=usedBytes" json:"used_bytes,omitempty"` - // InodesCapacity represents the total inodes in the filesystem. - InodesCapacity *UInt64Value `protobuf:"bytes,6,opt,name=inodes_capacity,json=inodesCapacity" json:"inodes_capacity,omitempty"` - // InodesAvailable represents the free inodes in the filesystem. - InodesAvailable *UInt64Value `protobuf:"bytes,7,opt,name=inodes_available,json=inodesAvailable" json:"inodes_available,omitempty"` + UsedBytes *UInt64Value `protobuf:"bytes,3,opt,name=used_bytes,json=usedBytes" json:"used_bytes,omitempty"` // InodesUsed represents the inodes used by the images. // This may not equal InodesCapacity - InodesAvailable because the underlying // filesystem may also be used for purposes other than storing images. - InodesUsed *UInt64Value `protobuf:"bytes,8,opt,name=inodes_used,json=inodesUsed" json:"inodes_used,omitempty"` + InodesUsed *UInt64Value `protobuf:"bytes,4,opt,name=inodes_used,json=inodesUsed" json:"inodes_used,omitempty"` +} + +func (m *FilesystemUsage) Reset() { *m = FilesystemUsage{} } +func (*FilesystemUsage) ProtoMessage() {} +func (*FilesystemUsage) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{84} } + +func (m *FilesystemUsage) GetTimestamp() int64 { + if m != nil { + return m.Timestamp + } + return 0 +} + +func (m *FilesystemUsage) GetStorageId() *StorageIdentifier { + if m != nil { + return m.StorageId + } + return nil +} + +func (m *FilesystemUsage) GetUsedBytes() *UInt64Value { + if m != nil { + return m.UsedBytes + } + return nil +} + +func (m *FilesystemUsage) GetInodesUsed() *UInt64Value { + if m != nil { + return m.InodesUsed + } + return nil +} + +type ImageFsInfoResponse struct { + // Information of image filesystem(s). + ImageFilesystems []*FilesystemUsage `protobuf:"bytes,1,rep,name=image_filesystems,json=imageFilesystems" json:"image_filesystems,omitempty"` +} + +func (m *ImageFsInfoResponse) Reset() { *m = ImageFsInfoResponse{} } +func (*ImageFsInfoResponse) ProtoMessage() {} +func (*ImageFsInfoResponse) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{85} } + +func (m *ImageFsInfoResponse) GetImageFilesystems() []*FilesystemUsage { + if m != nil { + return m.ImageFilesystems + } + return nil +} + +type ContainerStatsRequest struct { + // ID of the container for which to retrieve stats. + ContainerId string `protobuf:"bytes,1,opt,name=container_id,json=containerId,proto3" json:"container_id,omitempty"` +} + +func (m *ContainerStatsRequest) Reset() { *m = ContainerStatsRequest{} } +func (*ContainerStatsRequest) ProtoMessage() {} +func (*ContainerStatsRequest) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{86} } + +func (m *ContainerStatsRequest) GetContainerId() string { + if m != nil { + return m.ContainerId + } + return "" +} + +type ContainerStatsResponse struct { + // Stats of the container. + Stats *ContainerStats `protobuf:"bytes,1,opt,name=stats" json:"stats,omitempty"` +} + +func (m *ContainerStatsResponse) Reset() { *m = ContainerStatsResponse{} } +func (*ContainerStatsResponse) ProtoMessage() {} +func (*ContainerStatsResponse) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{87} } + +func (m *ContainerStatsResponse) GetStats() *ContainerStats { + if m != nil { + return m.Stats + } + return nil +} + +type ListContainerStatsRequest struct { + // Filter for the list request. + Filter *ContainerStatsFilter `protobuf:"bytes,1,opt,name=filter" json:"filter,omitempty"` +} + +func (m *ListContainerStatsRequest) Reset() { *m = ListContainerStatsRequest{} } +func (*ListContainerStatsRequest) ProtoMessage() {} +func (*ListContainerStatsRequest) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{88} } + +func (m *ListContainerStatsRequest) GetFilter() *ContainerStatsFilter { + if m != nil { + return m.Filter + } + return nil +} + +// ContainerStatsFilter is used to filter containers. +// All those fields are combined with 'AND' +type ContainerStatsFilter struct { + // ID of the container. + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` + // ID of the PodSandbox. + PodSandboxId string `protobuf:"bytes,2,opt,name=pod_sandbox_id,json=podSandboxId,proto3" json:"pod_sandbox_id,omitempty"` + // LabelSelector to select matches. + // Only api.MatchLabels is supported for now and the requirements + // are ANDed. MatchExpressions is not supported yet. + LabelSelector map[string]string `protobuf:"bytes,3,rep,name=label_selector,json=labelSelector" json:"label_selector,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` } -func (m *FsInfo) Reset() { *m = FsInfo{} } -func (*FsInfo) ProtoMessage() {} -func (*FsInfo) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{83} } +func (m *ContainerStatsFilter) Reset() { *m = ContainerStatsFilter{} } +func (*ContainerStatsFilter) ProtoMessage() {} +func (*ContainerStatsFilter) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{89} } -func (m *FsInfo) GetDevice() string { +func (m *ContainerStatsFilter) GetId() string { if m != nil { - return m.Device + return m.Id + } + return "" +} + +func (m *ContainerStatsFilter) GetPodSandboxId() string { + if m != nil { + return m.PodSandboxId } return "" } -func (m *FsInfo) GetPath() string { +func (m *ContainerStatsFilter) GetLabelSelector() map[string]string { + if m != nil { + return m.LabelSelector + } + return nil +} + +type ListContainerStatsResponse struct { + // Stats of the container. + Stats []*ContainerStats `protobuf:"bytes,1,rep,name=stats" json:"stats,omitempty"` +} + +func (m *ListContainerStatsResponse) Reset() { *m = ListContainerStatsResponse{} } +func (*ListContainerStatsResponse) ProtoMessage() {} +func (*ListContainerStatsResponse) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{90} } + +func (m *ListContainerStatsResponse) GetStats() []*ContainerStats { + if m != nil { + return m.Stats + } + return nil +} + +// ContainerAttributes provides basic information of the container. +type ContainerAttributes struct { + // ID of the container. + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` + // Metadata of the container. + Metadata *ContainerMetadata `protobuf:"bytes,2,opt,name=metadata" json:"metadata,omitempty"` + // Key-value pairs that may be used to scope and select individual resources. + Labels map[string]string `protobuf:"bytes,3,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` + // Unstructured key-value map holding arbitrary metadata. + // Annotations MUST NOT be altered by the runtime; the value of this field + // MUST be identical to that of the corresponding ContainerConfig used to + // instantiate the Container this status represents. + Annotations map[string]string `protobuf:"bytes,4,rep,name=annotations" json:"annotations,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` +} + +func (m *ContainerAttributes) Reset() { *m = ContainerAttributes{} } +func (*ContainerAttributes) ProtoMessage() {} +func (*ContainerAttributes) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{91} } + +func (m *ContainerAttributes) GetId() string { if m != nil { - return m.Path + return m.Id } return "" } -func (m *FsInfo) GetCapacityBytes() *UInt64Value { +func (m *ContainerAttributes) GetMetadata() *ContainerMetadata { if m != nil { - return m.CapacityBytes + return m.Metadata } return nil } -func (m *FsInfo) GetAvailableBytes() *UInt64Value { +func (m *ContainerAttributes) GetLabels() map[string]string { if m != nil { - return m.AvailableBytes + return m.Labels } return nil } -func (m *FsInfo) GetUsedBytes() *UInt64Value { +func (m *ContainerAttributes) GetAnnotations() map[string]string { if m != nil { - return m.UsedBytes + return m.Annotations } return nil } -func (m *FsInfo) GetInodesCapacity() *UInt64Value { +// ContainerStats provides the resource usage statistics for a container. +type ContainerStats struct { + // Information of the container. + Attributes *ContainerAttributes `protobuf:"bytes,1,opt,name=attributes" json:"attributes,omitempty"` + // CPU usage gathered from the container. + Cpu *CpuUsage `protobuf:"bytes,2,opt,name=cpu" json:"cpu,omitempty"` + // Memory usage gathered from the container. + Memory *MemoryUsage `protobuf:"bytes,3,opt,name=memory" json:"memory,omitempty"` + // Usage of the writeable layer. + WritableLayer *FilesystemUsage `protobuf:"bytes,4,opt,name=writable_layer,json=writableLayer" json:"writable_layer,omitempty"` +} + +func (m *ContainerStats) Reset() { *m = ContainerStats{} } +func (*ContainerStats) ProtoMessage() {} +func (*ContainerStats) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{92} } + +func (m *ContainerStats) GetAttributes() *ContainerAttributes { if m != nil { - return m.InodesCapacity + return m.Attributes } return nil } -func (m *FsInfo) GetInodesAvailable() *UInt64Value { +func (m *ContainerStats) GetCpu() *CpuUsage { if m != nil { - return m.InodesAvailable + return m.Cpu } return nil } -func (m *FsInfo) GetInodesUsed() *UInt64Value { +func (m *ContainerStats) GetMemory() *MemoryUsage { if m != nil { - return m.InodesUsed + return m.Memory } return nil } -type ImageFsInfoResponse struct { - // filesystem information of images. - FsInfo *FsInfo `protobuf:"bytes,1,opt,name=fs_info,json=fsInfo" json:"fs_info,omitempty"` +func (m *ContainerStats) GetWritableLayer() *FilesystemUsage { + if m != nil { + return m.WritableLayer + } + return nil } -func (m *ImageFsInfoResponse) Reset() { *m = ImageFsInfoResponse{} } -func (*ImageFsInfoResponse) ProtoMessage() {} -func (*ImageFsInfoResponse) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{84} } +// CpuUsage provides the CPU usage information. +type CpuUsage struct { + // Timestamp in nanoseconds at which the information were collected. Must be > 0. + Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` + // Cumulative CPU usage (sum across all cores) since object creation. + UsageCoreNanoSeconds *UInt64Value `protobuf:"bytes,2,opt,name=usage_core_nano_seconds,json=usageCoreNanoSeconds" json:"usage_core_nano_seconds,omitempty"` +} + +func (m *CpuUsage) Reset() { *m = CpuUsage{} } +func (*CpuUsage) ProtoMessage() {} +func (*CpuUsage) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{93} } + +func (m *CpuUsage) GetTimestamp() int64 { + if m != nil { + return m.Timestamp + } + return 0 +} + +func (m *CpuUsage) GetUsageCoreNanoSeconds() *UInt64Value { + if m != nil { + return m.UsageCoreNanoSeconds + } + return nil +} + +// MemoryUsage provides the memory usage information. +type MemoryUsage struct { + // Timestamp in nanoseconds at which the information were collected. Must be > 0. + Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` + // The amount of working set memory in bytes. + WorkingSetBytes *UInt64Value `protobuf:"bytes,2,opt,name=working_set_bytes,json=workingSetBytes" json:"working_set_bytes,omitempty"` +} + +func (m *MemoryUsage) Reset() { *m = MemoryUsage{} } +func (*MemoryUsage) ProtoMessage() {} +func (*MemoryUsage) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{94} } + +func (m *MemoryUsage) GetTimestamp() int64 { + if m != nil { + return m.Timestamp + } + return 0 +} -func (m *ImageFsInfoResponse) GetFsInfo() *FsInfo { +func (m *MemoryUsage) GetWorkingSetBytes() *UInt64Value { if m != nil { - return m.FsInfo + return m.WorkingSetBytes } return nil } @@ -3035,8 +3269,18 @@ func init() { proto.RegisterType((*StatusResponse)(nil), "v1alpha1.StatusResponse") proto.RegisterType((*ImageFsInfoRequest)(nil), "v1alpha1.ImageFsInfoRequest") proto.RegisterType((*UInt64Value)(nil), "v1alpha1.UInt64Value") - proto.RegisterType((*FsInfo)(nil), "v1alpha1.FsInfo") + proto.RegisterType((*StorageIdentifier)(nil), "v1alpha1.StorageIdentifier") + proto.RegisterType((*FilesystemUsage)(nil), "v1alpha1.FilesystemUsage") proto.RegisterType((*ImageFsInfoResponse)(nil), "v1alpha1.ImageFsInfoResponse") + proto.RegisterType((*ContainerStatsRequest)(nil), "v1alpha1.ContainerStatsRequest") + proto.RegisterType((*ContainerStatsResponse)(nil), "v1alpha1.ContainerStatsResponse") + proto.RegisterType((*ListContainerStatsRequest)(nil), "v1alpha1.ListContainerStatsRequest") + proto.RegisterType((*ContainerStatsFilter)(nil), "v1alpha1.ContainerStatsFilter") + proto.RegisterType((*ListContainerStatsResponse)(nil), "v1alpha1.ListContainerStatsResponse") + proto.RegisterType((*ContainerAttributes)(nil), "v1alpha1.ContainerAttributes") + proto.RegisterType((*ContainerStats)(nil), "v1alpha1.ContainerStats") + proto.RegisterType((*CpuUsage)(nil), "v1alpha1.CpuUsage") + proto.RegisterType((*MemoryUsage)(nil), "v1alpha1.MemoryUsage") proto.RegisterEnum("v1alpha1.Protocol", Protocol_name, Protocol_value) proto.RegisterEnum("v1alpha1.PodSandboxState", PodSandboxState_name, PodSandboxState_value) proto.RegisterEnum("v1alpha1.ContainerState", ContainerState_name, ContainerState_value) @@ -3105,6 +3349,11 @@ type RuntimeServiceClient interface { Attach(ctx context.Context, in *AttachRequest, opts ...grpc.CallOption) (*AttachResponse, error) // PortForward prepares a streaming endpoint to forward ports from a PodSandbox. PortForward(ctx context.Context, in *PortForwardRequest, opts ...grpc.CallOption) (*PortForwardResponse, error) + // ContainerStats returns stats of the container. If the container does not + // exist, the call returns an error. + ContainerStats(ctx context.Context, in *ContainerStatsRequest, opts ...grpc.CallOption) (*ContainerStatsResponse, error) + // ListContainerStats returns stats of all running containers. + ListContainerStats(ctx context.Context, in *ListContainerStatsRequest, opts ...grpc.CallOption) (*ListContainerStatsResponse, error) // UpdateRuntimeConfig updates the runtime configuration based on the given request. UpdateRuntimeConfig(ctx context.Context, in *UpdateRuntimeConfigRequest, opts ...grpc.CallOption) (*UpdateRuntimeConfigResponse, error) // Status returns the status of the runtime. @@ -3263,6 +3512,24 @@ func (c *runtimeServiceClient) PortForward(ctx context.Context, in *PortForwardR return out, nil } +func (c *runtimeServiceClient) ContainerStats(ctx context.Context, in *ContainerStatsRequest, opts ...grpc.CallOption) (*ContainerStatsResponse, error) { + out := new(ContainerStatsResponse) + err := grpc.Invoke(ctx, "/v1alpha1.RuntimeService/ContainerStats", in, out, c.cc, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *runtimeServiceClient) ListContainerStats(ctx context.Context, in *ListContainerStatsRequest, opts ...grpc.CallOption) (*ListContainerStatsResponse, error) { + out := new(ListContainerStatsResponse) + err := grpc.Invoke(ctx, "/v1alpha1.RuntimeService/ListContainerStats", in, out, c.cc, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *runtimeServiceClient) UpdateRuntimeConfig(ctx context.Context, in *UpdateRuntimeConfigRequest, opts ...grpc.CallOption) (*UpdateRuntimeConfigResponse, error) { out := new(UpdateRuntimeConfigResponse) err := grpc.Invoke(ctx, "/v1alpha1.RuntimeService/UpdateRuntimeConfig", in, out, c.cc, opts...) @@ -3336,6 +3603,11 @@ type RuntimeServiceServer interface { Attach(context.Context, *AttachRequest) (*AttachResponse, error) // PortForward prepares a streaming endpoint to forward ports from a PodSandbox. PortForward(context.Context, *PortForwardRequest) (*PortForwardResponse, error) + // ContainerStats returns stats of the container. If the container does not + // exist, the call returns an error. + ContainerStats(context.Context, *ContainerStatsRequest) (*ContainerStatsResponse, error) + // ListContainerStats returns stats of all running containers. + ListContainerStats(context.Context, *ListContainerStatsRequest) (*ListContainerStatsResponse, error) // UpdateRuntimeConfig updates the runtime configuration based on the given request. UpdateRuntimeConfig(context.Context, *UpdateRuntimeConfigRequest) (*UpdateRuntimeConfigResponse, error) // Status returns the status of the runtime. @@ -3634,6 +3906,42 @@ func _RuntimeService_PortForward_Handler(srv interface{}, ctx context.Context, d return interceptor(ctx, in, info, handler) } +func _RuntimeService_ContainerStats_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(ContainerStatsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(RuntimeServiceServer).ContainerStats(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/v1alpha1.RuntimeService/ContainerStats", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(RuntimeServiceServer).ContainerStats(ctx, req.(*ContainerStatsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _RuntimeService_ListContainerStats_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(ListContainerStatsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(RuntimeServiceServer).ListContainerStats(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/v1alpha1.RuntimeService/ListContainerStats", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(RuntimeServiceServer).ListContainerStats(ctx, req.(*ListContainerStatsRequest)) + } + return interceptor(ctx, in, info, handler) +} + func _RuntimeService_UpdateRuntimeConfig_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(UpdateRuntimeConfigRequest) if err := dec(in); err != nil { @@ -3738,6 +4046,14 @@ var _RuntimeService_serviceDesc = grpc.ServiceDesc{ MethodName: "PortForward", Handler: _RuntimeService_PortForward_Handler, }, + { + MethodName: "ContainerStats", + Handler: _RuntimeService_ContainerStats_Handler, + }, + { + MethodName: "ListContainerStats", + Handler: _RuntimeService_ListContainerStats_Handler, + }, { MethodName: "UpdateRuntimeConfig", Handler: _RuntimeService_UpdateRuntimeConfig_Handler, @@ -7276,7 +7592,7 @@ func (m *UInt64Value) MarshalTo(dAtA []byte) (int, error) { return i, nil } -func (m *FsInfo) Marshal() (dAtA []byte, err error) { +func (m *StorageIdentifier) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalTo(dAtA) @@ -7286,82 +7602,69 @@ func (m *FsInfo) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *FsInfo) MarshalTo(dAtA []byte) (int, error) { +func (m *StorageIdentifier) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - if len(m.Device) > 0 { + if len(m.Uuid) > 0 { dAtA[i] = 0xa i++ - i = encodeVarintApi(dAtA, i, uint64(len(m.Device))) - i += copy(dAtA[i:], m.Device) + i = encodeVarintApi(dAtA, i, uint64(len(m.Uuid))) + i += copy(dAtA[i:], m.Uuid) } - if len(m.Path) > 0 { - dAtA[i] = 0x12 - i++ - i = encodeVarintApi(dAtA, i, uint64(len(m.Path))) - i += copy(dAtA[i:], m.Path) + return i, nil +} + +func (m *FilesystemUsage) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - if m.CapacityBytes != nil { - dAtA[i] = 0x1a + return dAtA[:n], nil +} + +func (m *FilesystemUsage) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.Timestamp != 0 { + dAtA[i] = 0x8 i++ - i = encodeVarintApi(dAtA, i, uint64(m.CapacityBytes.Size())) - n54, err := m.CapacityBytes.MarshalTo(dAtA[i:]) - if err != nil { - return 0, err - } - i += n54 + i = encodeVarintApi(dAtA, i, uint64(m.Timestamp)) } - if m.AvailableBytes != nil { - dAtA[i] = 0x22 + if m.StorageId != nil { + dAtA[i] = 0x12 i++ - i = encodeVarintApi(dAtA, i, uint64(m.AvailableBytes.Size())) - n55, err := m.AvailableBytes.MarshalTo(dAtA[i:]) + i = encodeVarintApi(dAtA, i, uint64(m.StorageId.Size())) + n54, err := m.StorageId.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n55 + i += n54 } if m.UsedBytes != nil { - dAtA[i] = 0x2a + dAtA[i] = 0x1a i++ i = encodeVarintApi(dAtA, i, uint64(m.UsedBytes.Size())) - n56, err := m.UsedBytes.MarshalTo(dAtA[i:]) - if err != nil { - return 0, err - } - i += n56 - } - if m.InodesCapacity != nil { - dAtA[i] = 0x32 - i++ - i = encodeVarintApi(dAtA, i, uint64(m.InodesCapacity.Size())) - n57, err := m.InodesCapacity.MarshalTo(dAtA[i:]) - if err != nil { - return 0, err - } - i += n57 - } - if m.InodesAvailable != nil { - dAtA[i] = 0x3a - i++ - i = encodeVarintApi(dAtA, i, uint64(m.InodesAvailable.Size())) - n58, err := m.InodesAvailable.MarshalTo(dAtA[i:]) + n55, err := m.UsedBytes.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n58 + i += n55 } if m.InodesUsed != nil { - dAtA[i] = 0x42 + dAtA[i] = 0x22 i++ i = encodeVarintApi(dAtA, i, uint64(m.InodesUsed.Size())) - n59, err := m.InodesUsed.MarshalTo(dAtA[i:]) + n56, err := m.InodesUsed.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n59 + i += n56 } return i, nil } @@ -7381,455 +7684,560 @@ func (m *ImageFsInfoResponse) MarshalTo(dAtA []byte) (int, error) { _ = i var l int _ = l - if m.FsInfo != nil { - dAtA[i] = 0xa - i++ - i = encodeVarintApi(dAtA, i, uint64(m.FsInfo.Size())) - n60, err := m.FsInfo.MarshalTo(dAtA[i:]) - if err != nil { - return 0, err + if len(m.ImageFilesystems) > 0 { + for _, msg := range m.ImageFilesystems { + dAtA[i] = 0xa + i++ + i = encodeVarintApi(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n } - i += n60 } return i, nil } -func encodeFixed64Api(dAtA []byte, offset int, v uint64) int { - dAtA[offset] = uint8(v) - dAtA[offset+1] = uint8(v >> 8) - dAtA[offset+2] = uint8(v >> 16) - dAtA[offset+3] = uint8(v >> 24) - dAtA[offset+4] = uint8(v >> 32) - dAtA[offset+5] = uint8(v >> 40) - dAtA[offset+6] = uint8(v >> 48) - dAtA[offset+7] = uint8(v >> 56) - return offset + 8 -} -func encodeFixed32Api(dAtA []byte, offset int, v uint32) int { - dAtA[offset] = uint8(v) - dAtA[offset+1] = uint8(v >> 8) - dAtA[offset+2] = uint8(v >> 16) - dAtA[offset+3] = uint8(v >> 24) - return offset + 4 -} -func encodeVarintApi(dAtA []byte, offset int, v uint64) int { - for v >= 1<<7 { - dAtA[offset] = uint8(v&0x7f | 0x80) - v >>= 7 - offset++ +func (m *ContainerStatsRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - dAtA[offset] = uint8(v) - return offset + 1 + return dAtA[:n], nil } -func (m *VersionRequest) Size() (n int) { + +func (m *ContainerStatsRequest) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i var l int _ = l - l = len(m.Version) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) + if len(m.ContainerId) > 0 { + dAtA[i] = 0xa + i++ + i = encodeVarintApi(dAtA, i, uint64(len(m.ContainerId))) + i += copy(dAtA[i:], m.ContainerId) } - return n + return i, nil } -func (m *VersionResponse) Size() (n int) { - var l int - _ = l - l = len(m.Version) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) - } - l = len(m.RuntimeName) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) - } - l = len(m.RuntimeVersion) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) - } - l = len(m.RuntimeApiVersion) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) +func (m *ContainerStatsResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - return n + return dAtA[:n], nil } -func (m *DNSConfig) Size() (n int) { +func (m *ContainerStatsResponse) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i var l int _ = l - if len(m.Servers) > 0 { - for _, s := range m.Servers { - l = len(s) - n += 1 + l + sovApi(uint64(l)) - } - } - if len(m.Searches) > 0 { - for _, s := range m.Searches { - l = len(s) - n += 1 + l + sovApi(uint64(l)) - } - } - if len(m.Options) > 0 { - for _, s := range m.Options { - l = len(s) - n += 1 + l + sovApi(uint64(l)) + if m.Stats != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintApi(dAtA, i, uint64(m.Stats.Size())) + n57, err := m.Stats.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err } + i += n57 } - return n + return i, nil } -func (m *PortMapping) Size() (n int) { - var l int - _ = l - if m.Protocol != 0 { - n += 1 + sovApi(uint64(m.Protocol)) - } - if m.ContainerPort != 0 { - n += 1 + sovApi(uint64(m.ContainerPort)) - } - if m.HostPort != 0 { - n += 1 + sovApi(uint64(m.HostPort)) - } - l = len(m.HostIp) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) +func (m *ListContainerStatsRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - return n + return dAtA[:n], nil } -func (m *Mount) Size() (n int) { +func (m *ListContainerStatsRequest) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i var l int _ = l - l = len(m.ContainerPath) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) - } - l = len(m.HostPath) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) - } - if m.Readonly { - n += 2 + if m.Filter != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintApi(dAtA, i, uint64(m.Filter.Size())) + n58, err := m.Filter.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n58 } - if m.SelinuxRelabel { - n += 2 + return i, nil +} + +func (m *ContainerStatsFilter) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - return n + return dAtA[:n], nil } -func (m *NamespaceOption) Size() (n int) { +func (m *ContainerStatsFilter) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i var l int _ = l - if m.HostNetwork { - n += 2 + if len(m.Id) > 0 { + dAtA[i] = 0xa + i++ + i = encodeVarintApi(dAtA, i, uint64(len(m.Id))) + i += copy(dAtA[i:], m.Id) } - if m.HostPid { - n += 2 + if len(m.PodSandboxId) > 0 { + dAtA[i] = 0x12 + i++ + i = encodeVarintApi(dAtA, i, uint64(len(m.PodSandboxId))) + i += copy(dAtA[i:], m.PodSandboxId) } - if m.HostIpc { - n += 2 + if len(m.LabelSelector) > 0 { + for k := range m.LabelSelector { + dAtA[i] = 0x1a + i++ + v := m.LabelSelector[k] + mapSize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) + i = encodeVarintApi(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa + i++ + i = encodeVarintApi(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 + i++ + i = encodeVarintApi(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) + } } - return n + return i, nil } -func (m *Int64Value) Size() (n int) { - var l int - _ = l - if m.Value != 0 { - n += 1 + sovApi(uint64(m.Value)) +func (m *ListContainerStatsResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - return n + return dAtA[:n], nil } -func (m *LinuxSandboxSecurityContext) Size() (n int) { +func (m *ListContainerStatsResponse) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i var l int _ = l - if m.NamespaceOptions != nil { - l = m.NamespaceOptions.Size() - n += 1 + l + sovApi(uint64(l)) - } - if m.SelinuxOptions != nil { - l = m.SelinuxOptions.Size() - n += 1 + l + sovApi(uint64(l)) - } - if m.RunAsUser != nil { - l = m.RunAsUser.Size() - n += 1 + l + sovApi(uint64(l)) - } - if m.ReadonlyRootfs { - n += 2 - } - if len(m.SupplementalGroups) > 0 { - l = 0 - for _, e := range m.SupplementalGroups { - l += sovApi(uint64(e)) + if len(m.Stats) > 0 { + for _, msg := range m.Stats { + dAtA[i] = 0xa + i++ + i = encodeVarintApi(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n } - n += 1 + sovApi(uint64(l)) + l } - if m.Privileged { - n += 2 + return i, nil +} + +func (m *ContainerAttributes) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - return n + return dAtA[:n], nil } -func (m *LinuxPodSandboxConfig) Size() (n int) { +func (m *ContainerAttributes) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i var l int _ = l - l = len(m.CgroupParent) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) - } - if m.SecurityContext != nil { - l = m.SecurityContext.Size() - n += 1 + l + sovApi(uint64(l)) + if len(m.Id) > 0 { + dAtA[i] = 0xa + i++ + i = encodeVarintApi(dAtA, i, uint64(len(m.Id))) + i += copy(dAtA[i:], m.Id) } - if len(m.Sysctls) > 0 { - for k, v := range m.Sysctls { - _ = k - _ = v - mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) - n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) + if m.Metadata != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintApi(dAtA, i, uint64(m.Metadata.Size())) + n59, err := m.Metadata.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err } + i += n59 } - return n -} - -func (m *PodSandboxMetadata) Size() (n int) { - var l int - _ = l - l = len(m.Name) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) - } - l = len(m.Uid) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) + if len(m.Labels) > 0 { + for k := range m.Labels { + dAtA[i] = 0x1a + i++ + v := m.Labels[k] + mapSize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) + i = encodeVarintApi(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa + i++ + i = encodeVarintApi(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 + i++ + i = encodeVarintApi(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) + } } - l = len(m.Namespace) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) + if len(m.Annotations) > 0 { + for k := range m.Annotations { + dAtA[i] = 0x22 + i++ + v := m.Annotations[k] + mapSize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) + i = encodeVarintApi(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa + i++ + i = encodeVarintApi(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 + i++ + i = encodeVarintApi(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) + } } - if m.Attempt != 0 { - n += 1 + sovApi(uint64(m.Attempt)) + return i, nil +} + +func (m *ContainerStats) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - return n + return dAtA[:n], nil } -func (m *PodSandboxConfig) Size() (n int) { +func (m *ContainerStats) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i var l int _ = l - if m.Metadata != nil { - l = m.Metadata.Size() - n += 1 + l + sovApi(uint64(l)) - } - l = len(m.Hostname) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) - } - l = len(m.LogDirectory) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) - } - if m.DnsConfig != nil { - l = m.DnsConfig.Size() - n += 1 + l + sovApi(uint64(l)) - } - if len(m.PortMappings) > 0 { - for _, e := range m.PortMappings { - l = e.Size() - n += 1 + l + sovApi(uint64(l)) + if m.Attributes != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintApi(dAtA, i, uint64(m.Attributes.Size())) + n60, err := m.Attributes.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err } + i += n60 } - if len(m.Labels) > 0 { - for k, v := range m.Labels { - _ = k - _ = v - mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) - n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) + if m.Cpu != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintApi(dAtA, i, uint64(m.Cpu.Size())) + n61, err := m.Cpu.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err } + i += n61 } - if len(m.Annotations) > 0 { - for k, v := range m.Annotations { - _ = k - _ = v - mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) - n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) + if m.Memory != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintApi(dAtA, i, uint64(m.Memory.Size())) + n62, err := m.Memory.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err } + i += n62 } - if m.Linux != nil { - l = m.Linux.Size() - n += 1 + l + sovApi(uint64(l)) + if m.WritableLayer != nil { + dAtA[i] = 0x22 + i++ + i = encodeVarintApi(dAtA, i, uint64(m.WritableLayer.Size())) + n63, err := m.WritableLayer.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n63 } - return n + return i, nil } -func (m *RunPodSandboxRequest) Size() (n int) { - var l int - _ = l - if m.Config != nil { - l = m.Config.Size() - n += 1 + l + sovApi(uint64(l)) +func (m *CpuUsage) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - return n + return dAtA[:n], nil } -func (m *RunPodSandboxResponse) Size() (n int) { +func (m *CpuUsage) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i var l int _ = l - l = len(m.PodSandboxId) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) + if m.Timestamp != 0 { + dAtA[i] = 0x8 + i++ + i = encodeVarintApi(dAtA, i, uint64(m.Timestamp)) } - return n + if m.UsageCoreNanoSeconds != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintApi(dAtA, i, uint64(m.UsageCoreNanoSeconds.Size())) + n64, err := m.UsageCoreNanoSeconds.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n64 + } + return i, nil } -func (m *StopPodSandboxRequest) Size() (n int) { - var l int - _ = l - l = len(m.PodSandboxId) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) +func (m *MemoryUsage) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - return n + return dAtA[:n], nil } -func (m *StopPodSandboxResponse) Size() (n int) { +func (m *MemoryUsage) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i var l int _ = l - return n + if m.Timestamp != 0 { + dAtA[i] = 0x8 + i++ + i = encodeVarintApi(dAtA, i, uint64(m.Timestamp)) + } + if m.WorkingSetBytes != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintApi(dAtA, i, uint64(m.WorkingSetBytes.Size())) + n65, err := m.WorkingSetBytes.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n65 + } + return i, nil } -func (m *RemovePodSandboxRequest) Size() (n int) { +func encodeFixed64Api(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Api(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintApi(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *VersionRequest) Size() (n int) { var l int _ = l - l = len(m.PodSandboxId) + l = len(m.Version) if l > 0 { n += 1 + l + sovApi(uint64(l)) } return n } -func (m *RemovePodSandboxResponse) Size() (n int) { - var l int - _ = l - return n -} - -func (m *PodSandboxStatusRequest) Size() (n int) { +func (m *VersionResponse) Size() (n int) { var l int _ = l - l = len(m.PodSandboxId) + l = len(m.Version) if l > 0 { n += 1 + l + sovApi(uint64(l)) } - return n -} - -func (m *PodSandboxNetworkStatus) Size() (n int) { - var l int - _ = l - l = len(m.Ip) + l = len(m.RuntimeName) if l > 0 { n += 1 + l + sovApi(uint64(l)) } - return n -} - -func (m *Namespace) Size() (n int) { - var l int - _ = l - if m.Options != nil { - l = m.Options.Size() + l = len(m.RuntimeVersion) + if l > 0 { n += 1 + l + sovApi(uint64(l)) } - return n -} - -func (m *LinuxPodSandboxStatus) Size() (n int) { - var l int - _ = l - if m.Namespaces != nil { - l = m.Namespaces.Size() + l = len(m.RuntimeApiVersion) + if l > 0 { n += 1 + l + sovApi(uint64(l)) } return n } -func (m *PodSandboxStatus) Size() (n int) { +func (m *DNSConfig) Size() (n int) { var l int _ = l - l = len(m.Id) + if len(m.Servers) > 0 { + for _, s := range m.Servers { + l = len(s) + n += 1 + l + sovApi(uint64(l)) + } + } + if len(m.Searches) > 0 { + for _, s := range m.Searches { + l = len(s) + n += 1 + l + sovApi(uint64(l)) + } + } + if len(m.Options) > 0 { + for _, s := range m.Options { + l = len(s) + n += 1 + l + sovApi(uint64(l)) + } + } + return n +} + +func (m *PortMapping) Size() (n int) { + var l int + _ = l + if m.Protocol != 0 { + n += 1 + sovApi(uint64(m.Protocol)) + } + if m.ContainerPort != 0 { + n += 1 + sovApi(uint64(m.ContainerPort)) + } + if m.HostPort != 0 { + n += 1 + sovApi(uint64(m.HostPort)) + } + l = len(m.HostIp) if l > 0 { n += 1 + l + sovApi(uint64(l)) } - if m.Metadata != nil { - l = m.Metadata.Size() + return n +} + +func (m *Mount) Size() (n int) { + var l int + _ = l + l = len(m.ContainerPath) + if l > 0 { n += 1 + l + sovApi(uint64(l)) } - if m.State != 0 { - n += 1 + sovApi(uint64(m.State)) + l = len(m.HostPath) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) } - if m.CreatedAt != 0 { - n += 1 + sovApi(uint64(m.CreatedAt)) + if m.Readonly { + n += 2 } - if m.Network != nil { - l = m.Network.Size() - n += 1 + l + sovApi(uint64(l)) + if m.SelinuxRelabel { + n += 2 } - if m.Linux != nil { - l = m.Linux.Size() - n += 1 + l + sovApi(uint64(l)) + return n +} + +func (m *NamespaceOption) Size() (n int) { + var l int + _ = l + if m.HostNetwork { + n += 2 } - if len(m.Labels) > 0 { - for k, v := range m.Labels { - _ = k - _ = v - mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) - n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) - } + if m.HostPid { + n += 2 } - if len(m.Annotations) > 0 { - for k, v := range m.Annotations { - _ = k - _ = v - mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) - n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) - } + if m.HostIpc { + n += 2 } return n } -func (m *PodSandboxStatusResponse) Size() (n int) { +func (m *Int64Value) Size() (n int) { var l int _ = l - if m.Status != nil { - l = m.Status.Size() - n += 1 + l + sovApi(uint64(l)) + if m.Value != 0 { + n += 1 + sovApi(uint64(m.Value)) } return n } -func (m *PodSandboxStateValue) Size() (n int) { +func (m *LinuxSandboxSecurityContext) Size() (n int) { var l int _ = l - if m.State != 0 { - n += 1 + sovApi(uint64(m.State)) + if m.NamespaceOptions != nil { + l = m.NamespaceOptions.Size() + n += 1 + l + sovApi(uint64(l)) + } + if m.SelinuxOptions != nil { + l = m.SelinuxOptions.Size() + n += 1 + l + sovApi(uint64(l)) + } + if m.RunAsUser != nil { + l = m.RunAsUser.Size() + n += 1 + l + sovApi(uint64(l)) + } + if m.ReadonlyRootfs { + n += 2 + } + if len(m.SupplementalGroups) > 0 { + l = 0 + for _, e := range m.SupplementalGroups { + l += sovApi(uint64(e)) + } + n += 1 + sovApi(uint64(l)) + l + } + if m.Privileged { + n += 2 } return n } -func (m *PodSandboxFilter) Size() (n int) { +func (m *LinuxPodSandboxConfig) Size() (n int) { var l int _ = l - l = len(m.Id) + l = len(m.CgroupParent) if l > 0 { n += 1 + l + sovApi(uint64(l)) } - if m.State != nil { - l = m.State.Size() + if m.SecurityContext != nil { + l = m.SecurityContext.Size() n += 1 + l + sovApi(uint64(l)) } - if len(m.LabelSelector) > 0 { - for k, v := range m.LabelSelector { + if len(m.Sysctls) > 0 { + for k, v := range m.Sysctls { _ = k _ = v mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) @@ -7839,32 +8247,51 @@ func (m *PodSandboxFilter) Size() (n int) { return n } -func (m *ListPodSandboxRequest) Size() (n int) { +func (m *PodSandboxMetadata) Size() (n int) { var l int _ = l - if m.Filter != nil { - l = m.Filter.Size() + l = len(m.Name) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + l = len(m.Uid) + if l > 0 { n += 1 + l + sovApi(uint64(l)) } + l = len(m.Namespace) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + if m.Attempt != 0 { + n += 1 + sovApi(uint64(m.Attempt)) + } return n } -func (m *PodSandbox) Size() (n int) { +func (m *PodSandboxConfig) Size() (n int) { var l int _ = l - l = len(m.Id) + if m.Metadata != nil { + l = m.Metadata.Size() + n += 1 + l + sovApi(uint64(l)) + } + l = len(m.Hostname) if l > 0 { n += 1 + l + sovApi(uint64(l)) } - if m.Metadata != nil { - l = m.Metadata.Size() + l = len(m.LogDirectory) + if l > 0 { n += 1 + l + sovApi(uint64(l)) } - if m.State != 0 { - n += 1 + sovApi(uint64(m.State)) + if m.DnsConfig != nil { + l = m.DnsConfig.Size() + n += 1 + l + sovApi(uint64(l)) } - if m.CreatedAt != 0 { - n += 1 + sovApi(uint64(m.CreatedAt)) + if len(m.PortMappings) > 0 { + for _, e := range m.PortMappings { + l = e.Size() + n += 1 + l + sovApi(uint64(l)) + } } if len(m.Labels) > 0 { for k, v := range m.Labels { @@ -7882,89 +8309,316 @@ func (m *PodSandbox) Size() (n int) { n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) } } + if m.Linux != nil { + l = m.Linux.Size() + n += 1 + l + sovApi(uint64(l)) + } return n } -func (m *ListPodSandboxResponse) Size() (n int) { +func (m *RunPodSandboxRequest) Size() (n int) { var l int _ = l - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovApi(uint64(l)) - } + if m.Config != nil { + l = m.Config.Size() + n += 1 + l + sovApi(uint64(l)) } return n } -func (m *ImageSpec) Size() (n int) { +func (m *RunPodSandboxResponse) Size() (n int) { var l int _ = l - l = len(m.Image) + l = len(m.PodSandboxId) if l > 0 { n += 1 + l + sovApi(uint64(l)) } return n } -func (m *KeyValue) Size() (n int) { +func (m *StopPodSandboxRequest) Size() (n int) { var l int _ = l - l = len(m.Key) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) - } - l = len(m.Value) + l = len(m.PodSandboxId) if l > 0 { n += 1 + l + sovApi(uint64(l)) } return n } -func (m *LinuxContainerResources) Size() (n int) { +func (m *StopPodSandboxResponse) Size() (n int) { var l int _ = l - if m.CpuPeriod != 0 { - n += 1 + sovApi(uint64(m.CpuPeriod)) - } - if m.CpuQuota != 0 { - n += 1 + sovApi(uint64(m.CpuQuota)) - } - if m.CpuShares != 0 { - n += 1 + sovApi(uint64(m.CpuShares)) - } - if m.MemoryLimitInBytes != 0 { - n += 1 + sovApi(uint64(m.MemoryLimitInBytes)) - } - if m.OomScoreAdj != 0 { - n += 1 + sovApi(uint64(m.OomScoreAdj)) - } return n } -func (m *SELinuxOption) Size() (n int) { +func (m *RemovePodSandboxRequest) Size() (n int) { var l int _ = l - l = len(m.User) + l = len(m.PodSandboxId) if l > 0 { n += 1 + l + sovApi(uint64(l)) } - l = len(m.Role) + return n +} + +func (m *RemovePodSandboxResponse) Size() (n int) { + var l int + _ = l + return n +} + +func (m *PodSandboxStatusRequest) Size() (n int) { + var l int + _ = l + l = len(m.PodSandboxId) if l > 0 { n += 1 + l + sovApi(uint64(l)) } - l = len(m.Type) + return n +} + +func (m *PodSandboxNetworkStatus) Size() (n int) { + var l int + _ = l + l = len(m.Ip) if l > 0 { n += 1 + l + sovApi(uint64(l)) } - l = len(m.Level) - if l > 0 { + return n +} + +func (m *Namespace) Size() (n int) { + var l int + _ = l + if m.Options != nil { + l = m.Options.Size() n += 1 + l + sovApi(uint64(l)) } return n } -func (m *Capability) Size() (n int) { +func (m *LinuxPodSandboxStatus) Size() (n int) { + var l int + _ = l + if m.Namespaces != nil { + l = m.Namespaces.Size() + n += 1 + l + sovApi(uint64(l)) + } + return n +} + +func (m *PodSandboxStatus) Size() (n int) { + var l int + _ = l + l = len(m.Id) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + if m.Metadata != nil { + l = m.Metadata.Size() + n += 1 + l + sovApi(uint64(l)) + } + if m.State != 0 { + n += 1 + sovApi(uint64(m.State)) + } + if m.CreatedAt != 0 { + n += 1 + sovApi(uint64(m.CreatedAt)) + } + if m.Network != nil { + l = m.Network.Size() + n += 1 + l + sovApi(uint64(l)) + } + if m.Linux != nil { + l = m.Linux.Size() + n += 1 + l + sovApi(uint64(l)) + } + if len(m.Labels) > 0 { + for k, v := range m.Labels { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) + n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) + } + } + if len(m.Annotations) > 0 { + for k, v := range m.Annotations { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) + n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) + } + } + return n +} + +func (m *PodSandboxStatusResponse) Size() (n int) { + var l int + _ = l + if m.Status != nil { + l = m.Status.Size() + n += 1 + l + sovApi(uint64(l)) + } + return n +} + +func (m *PodSandboxStateValue) Size() (n int) { + var l int + _ = l + if m.State != 0 { + n += 1 + sovApi(uint64(m.State)) + } + return n +} + +func (m *PodSandboxFilter) Size() (n int) { + var l int + _ = l + l = len(m.Id) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + if m.State != nil { + l = m.State.Size() + n += 1 + l + sovApi(uint64(l)) + } + if len(m.LabelSelector) > 0 { + for k, v := range m.LabelSelector { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) + n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) + } + } + return n +} + +func (m *ListPodSandboxRequest) Size() (n int) { + var l int + _ = l + if m.Filter != nil { + l = m.Filter.Size() + n += 1 + l + sovApi(uint64(l)) + } + return n +} + +func (m *PodSandbox) Size() (n int) { + var l int + _ = l + l = len(m.Id) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + if m.Metadata != nil { + l = m.Metadata.Size() + n += 1 + l + sovApi(uint64(l)) + } + if m.State != 0 { + n += 1 + sovApi(uint64(m.State)) + } + if m.CreatedAt != 0 { + n += 1 + sovApi(uint64(m.CreatedAt)) + } + if len(m.Labels) > 0 { + for k, v := range m.Labels { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) + n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) + } + } + if len(m.Annotations) > 0 { + for k, v := range m.Annotations { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) + n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) + } + } + return n +} + +func (m *ListPodSandboxResponse) Size() (n int) { + var l int + _ = l + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovApi(uint64(l)) + } + } + return n +} + +func (m *ImageSpec) Size() (n int) { + var l int + _ = l + l = len(m.Image) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + return n +} + +func (m *KeyValue) Size() (n int) { + var l int + _ = l + l = len(m.Key) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + l = len(m.Value) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + return n +} + +func (m *LinuxContainerResources) Size() (n int) { + var l int + _ = l + if m.CpuPeriod != 0 { + n += 1 + sovApi(uint64(m.CpuPeriod)) + } + if m.CpuQuota != 0 { + n += 1 + sovApi(uint64(m.CpuQuota)) + } + if m.CpuShares != 0 { + n += 1 + sovApi(uint64(m.CpuShares)) + } + if m.MemoryLimitInBytes != 0 { + n += 1 + sovApi(uint64(m.MemoryLimitInBytes)) + } + if m.OomScoreAdj != 0 { + n += 1 + sovApi(uint64(m.OomScoreAdj)) + } + return n +} + +func (m *SELinuxOption) Size() (n int) { + var l int + _ = l + l = len(m.User) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + l = len(m.Role) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + l = len(m.Type) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + l = len(m.Level) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + return n +} + +func (m *Capability) Size() (n int) { var l int _ = l if len(m.AddCapabilities) > 0 { @@ -8806,37 +9460,30 @@ func (m *UInt64Value) Size() (n int) { return n } -func (m *FsInfo) Size() (n int) { +func (m *StorageIdentifier) Size() (n int) { var l int _ = l - l = len(m.Device) + l = len(m.Uuid) if l > 0 { n += 1 + l + sovApi(uint64(l)) } - l = len(m.Path) - if l > 0 { - n += 1 + l + sovApi(uint64(l)) - } - if m.CapacityBytes != nil { - l = m.CapacityBytes.Size() - n += 1 + l + sovApi(uint64(l)) + return n +} + +func (m *FilesystemUsage) Size() (n int) { + var l int + _ = l + if m.Timestamp != 0 { + n += 1 + sovApi(uint64(m.Timestamp)) } - if m.AvailableBytes != nil { - l = m.AvailableBytes.Size() + if m.StorageId != nil { + l = m.StorageId.Size() n += 1 + l + sovApi(uint64(l)) } if m.UsedBytes != nil { l = m.UsedBytes.Size() n += 1 + l + sovApi(uint64(l)) } - if m.InodesCapacity != nil { - l = m.InodesCapacity.Size() - n += 1 + l + sovApi(uint64(l)) - } - if m.InodesAvailable != nil { - l = m.InodesAvailable.Size() - n += 1 + l + sovApi(uint64(l)) - } if m.InodesUsed != nil { l = m.InodesUsed.Size() n += 1 + l + sovApi(uint64(l)) @@ -8847,25 +9494,169 @@ func (m *FsInfo) Size() (n int) { func (m *ImageFsInfoResponse) Size() (n int) { var l int _ = l - if m.FsInfo != nil { - l = m.FsInfo.Size() + if len(m.ImageFilesystems) > 0 { + for _, e := range m.ImageFilesystems { + l = e.Size() + n += 1 + l + sovApi(uint64(l)) + } + } + return n +} + +func (m *ContainerStatsRequest) Size() (n int) { + var l int + _ = l + l = len(m.ContainerId) + if l > 0 { n += 1 + l + sovApi(uint64(l)) } return n } -func sovApi(x uint64) (n int) { - for { - n++ - x >>= 7 - if x == 0 { - break - } +func (m *ContainerStatsResponse) Size() (n int) { + var l int + _ = l + if m.Stats != nil { + l = m.Stats.Size() + n += 1 + l + sovApi(uint64(l)) } return n } -func sozApi(x uint64) (n int) { - return sovApi(uint64((x << 1) ^ uint64((int64(x) >> 63)))) + +func (m *ListContainerStatsRequest) Size() (n int) { + var l int + _ = l + if m.Filter != nil { + l = m.Filter.Size() + n += 1 + l + sovApi(uint64(l)) + } + return n +} + +func (m *ContainerStatsFilter) Size() (n int) { + var l int + _ = l + l = len(m.Id) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + l = len(m.PodSandboxId) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + if len(m.LabelSelector) > 0 { + for k, v := range m.LabelSelector { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) + n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) + } + } + return n +} + +func (m *ListContainerStatsResponse) Size() (n int) { + var l int + _ = l + if len(m.Stats) > 0 { + for _, e := range m.Stats { + l = e.Size() + n += 1 + l + sovApi(uint64(l)) + } + } + return n +} + +func (m *ContainerAttributes) Size() (n int) { + var l int + _ = l + l = len(m.Id) + if l > 0 { + n += 1 + l + sovApi(uint64(l)) + } + if m.Metadata != nil { + l = m.Metadata.Size() + n += 1 + l + sovApi(uint64(l)) + } + if len(m.Labels) > 0 { + for k, v := range m.Labels { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) + n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) + } + } + if len(m.Annotations) > 0 { + for k, v := range m.Annotations { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovApi(uint64(len(k))) + 1 + len(v) + sovApi(uint64(len(v))) + n += mapEntrySize + 1 + sovApi(uint64(mapEntrySize)) + } + } + return n +} + +func (m *ContainerStats) Size() (n int) { + var l int + _ = l + if m.Attributes != nil { + l = m.Attributes.Size() + n += 1 + l + sovApi(uint64(l)) + } + if m.Cpu != nil { + l = m.Cpu.Size() + n += 1 + l + sovApi(uint64(l)) + } + if m.Memory != nil { + l = m.Memory.Size() + n += 1 + l + sovApi(uint64(l)) + } + if m.WritableLayer != nil { + l = m.WritableLayer.Size() + n += 1 + l + sovApi(uint64(l)) + } + return n +} + +func (m *CpuUsage) Size() (n int) { + var l int + _ = l + if m.Timestamp != 0 { + n += 1 + sovApi(uint64(m.Timestamp)) + } + if m.UsageCoreNanoSeconds != nil { + l = m.UsageCoreNanoSeconds.Size() + n += 1 + l + sovApi(uint64(l)) + } + return n +} + +func (m *MemoryUsage) Size() (n int) { + var l int + _ = l + if m.Timestamp != 0 { + n += 1 + sovApi(uint64(m.Timestamp)) + } + if m.WorkingSetBytes != nil { + l = m.WorkingSetBytes.Size() + n += 1 + l + sovApi(uint64(l)) + } + return n +} + +func sovApi(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozApi(x uint64) (n int) { + return sovApi(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (this *VersionRequest) String() string { if this == nil { @@ -9970,18 +10761,24 @@ func (this *UInt64Value) String() string { }, "") return s } -func (this *FsInfo) String() string { +func (this *StorageIdentifier) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&StorageIdentifier{`, + `Uuid:` + fmt.Sprintf("%v", this.Uuid) + `,`, + `}`, + }, "") + return s +} +func (this *FilesystemUsage) String() string { if this == nil { return "nil" } - s := strings.Join([]string{`&FsInfo{`, - `Device:` + fmt.Sprintf("%v", this.Device) + `,`, - `Path:` + fmt.Sprintf("%v", this.Path) + `,`, - `CapacityBytes:` + strings.Replace(fmt.Sprintf("%v", this.CapacityBytes), "UInt64Value", "UInt64Value", 1) + `,`, - `AvailableBytes:` + strings.Replace(fmt.Sprintf("%v", this.AvailableBytes), "UInt64Value", "UInt64Value", 1) + `,`, + s := strings.Join([]string{`&FilesystemUsage{`, + `Timestamp:` + fmt.Sprintf("%v", this.Timestamp) + `,`, + `StorageId:` + strings.Replace(fmt.Sprintf("%v", this.StorageId), "StorageIdentifier", "StorageIdentifier", 1) + `,`, `UsedBytes:` + strings.Replace(fmt.Sprintf("%v", this.UsedBytes), "UInt64Value", "UInt64Value", 1) + `,`, - `InodesCapacity:` + strings.Replace(fmt.Sprintf("%v", this.InodesCapacity), "UInt64Value", "UInt64Value", 1) + `,`, - `InodesAvailable:` + strings.Replace(fmt.Sprintf("%v", this.InodesAvailable), "UInt64Value", "UInt64Value", 1) + `,`, `InodesUsed:` + strings.Replace(fmt.Sprintf("%v", this.InodesUsed), "UInt64Value", "UInt64Value", 1) + `,`, `}`, }, "") @@ -9991,21 +10788,996 @@ func (this *ImageFsInfoResponse) String() string { if this == nil { return "nil" } - s := strings.Join([]string{`&ImageFsInfoResponse{`, - `FsInfo:` + strings.Replace(fmt.Sprintf("%v", this.FsInfo), "FsInfo", "FsInfo", 1) + `,`, - `}`, - }, "") - return s -} -func valueToStringApi(v interface{}) string { - rv := reflect.ValueOf(v) - if rv.IsNil() { - return "nil" + s := strings.Join([]string{`&ImageFsInfoResponse{`, + `ImageFilesystems:` + strings.Replace(fmt.Sprintf("%v", this.ImageFilesystems), "FilesystemUsage", "FilesystemUsage", 1) + `,`, + `}`, + }, "") + return s +} +func (this *ContainerStatsRequest) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ContainerStatsRequest{`, + `ContainerId:` + fmt.Sprintf("%v", this.ContainerId) + `,`, + `}`, + }, "") + return s +} +func (this *ContainerStatsResponse) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ContainerStatsResponse{`, + `Stats:` + strings.Replace(fmt.Sprintf("%v", this.Stats), "ContainerStats", "ContainerStats", 1) + `,`, + `}`, + }, "") + return s +} +func (this *ListContainerStatsRequest) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ListContainerStatsRequest{`, + `Filter:` + strings.Replace(fmt.Sprintf("%v", this.Filter), "ContainerStatsFilter", "ContainerStatsFilter", 1) + `,`, + `}`, + }, "") + return s +} +func (this *ContainerStatsFilter) String() string { + if this == nil { + return "nil" + } + keysForLabelSelector := make([]string, 0, len(this.LabelSelector)) + for k := range this.LabelSelector { + keysForLabelSelector = append(keysForLabelSelector, k) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForLabelSelector) + mapStringForLabelSelector := "map[string]string{" + for _, k := range keysForLabelSelector { + mapStringForLabelSelector += fmt.Sprintf("%v: %v,", k, this.LabelSelector[k]) + } + mapStringForLabelSelector += "}" + s := strings.Join([]string{`&ContainerStatsFilter{`, + `Id:` + fmt.Sprintf("%v", this.Id) + `,`, + `PodSandboxId:` + fmt.Sprintf("%v", this.PodSandboxId) + `,`, + `LabelSelector:` + mapStringForLabelSelector + `,`, + `}`, + }, "") + return s +} +func (this *ListContainerStatsResponse) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ListContainerStatsResponse{`, + `Stats:` + strings.Replace(fmt.Sprintf("%v", this.Stats), "ContainerStats", "ContainerStats", 1) + `,`, + `}`, + }, "") + return s +} +func (this *ContainerAttributes) String() string { + if this == nil { + return "nil" + } + keysForLabels := make([]string, 0, len(this.Labels)) + for k := range this.Labels { + keysForLabels = append(keysForLabels, k) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForLabels) + mapStringForLabels := "map[string]string{" + for _, k := range keysForLabels { + mapStringForLabels += fmt.Sprintf("%v: %v,", k, this.Labels[k]) + } + mapStringForLabels += "}" + keysForAnnotations := make([]string, 0, len(this.Annotations)) + for k := range this.Annotations { + keysForAnnotations = append(keysForAnnotations, k) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForAnnotations) + mapStringForAnnotations := "map[string]string{" + for _, k := range keysForAnnotations { + mapStringForAnnotations += fmt.Sprintf("%v: %v,", k, this.Annotations[k]) + } + mapStringForAnnotations += "}" + s := strings.Join([]string{`&ContainerAttributes{`, + `Id:` + fmt.Sprintf("%v", this.Id) + `,`, + `Metadata:` + strings.Replace(fmt.Sprintf("%v", this.Metadata), "ContainerMetadata", "ContainerMetadata", 1) + `,`, + `Labels:` + mapStringForLabels + `,`, + `Annotations:` + mapStringForAnnotations + `,`, + `}`, + }, "") + return s +} +func (this *ContainerStats) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ContainerStats{`, + `Attributes:` + strings.Replace(fmt.Sprintf("%v", this.Attributes), "ContainerAttributes", "ContainerAttributes", 1) + `,`, + `Cpu:` + strings.Replace(fmt.Sprintf("%v", this.Cpu), "CpuUsage", "CpuUsage", 1) + `,`, + `Memory:` + strings.Replace(fmt.Sprintf("%v", this.Memory), "MemoryUsage", "MemoryUsage", 1) + `,`, + `WritableLayer:` + strings.Replace(fmt.Sprintf("%v", this.WritableLayer), "FilesystemUsage", "FilesystemUsage", 1) + `,`, + `}`, + }, "") + return s +} +func (this *CpuUsage) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&CpuUsage{`, + `Timestamp:` + fmt.Sprintf("%v", this.Timestamp) + `,`, + `UsageCoreNanoSeconds:` + strings.Replace(fmt.Sprintf("%v", this.UsageCoreNanoSeconds), "UInt64Value", "UInt64Value", 1) + `,`, + `}`, + }, "") + return s +} +func (this *MemoryUsage) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&MemoryUsage{`, + `Timestamp:` + fmt.Sprintf("%v", this.Timestamp) + `,`, + `WorkingSetBytes:` + strings.Replace(fmt.Sprintf("%v", this.WorkingSetBytes), "UInt64Value", "UInt64Value", 1) + `,`, + `}`, + }, "") + return s +} +func valueToStringApi(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *VersionRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: VersionRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: VersionRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Version = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *VersionResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: VersionResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: VersionResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Version = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RuntimeName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.RuntimeName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RuntimeVersion", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.RuntimeVersion = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RuntimeApiVersion", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.RuntimeApiVersion = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DNSConfig) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DNSConfig: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DNSConfig: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Servers", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Servers = append(m.Servers, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Searches", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Searches = append(m.Searches, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Options", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Options = append(m.Options, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PortMapping) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PortMapping: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PortMapping: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Protocol", wireType) + } + m.Protocol = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Protocol |= (Protocol(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ContainerPort", wireType) + } + m.ContainerPort = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.ContainerPort |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field HostPort", wireType) + } + m.HostPort = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.HostPort |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field HostIp", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.HostIp = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Mount) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Mount: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Mount: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ContainerPath", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ContainerPath = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field HostPath", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.HostPath = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Readonly", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Readonly = bool(v != 0) + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field SelinuxRelabel", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.SelinuxRelabel = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NamespaceOption) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NamespaceOption: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NamespaceOption: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field HostNetwork", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.HostNetwork = bool(v != 0) + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field HostPid", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.HostPid = bool(v != 0) + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field HostIpc", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.HostIpc = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Int64Value) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Int64Value: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Int64Value: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + } + m.Value = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Value |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF } - pv := reflect.Indirect(rv).Interface() - return fmt.Sprintf("*%v", pv) + return nil } -func (m *VersionRequest) Unmarshal(dAtA []byte) error { +func (m *LinuxSandboxSecurityContext) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -10028,17 +11800,17 @@ func (m *VersionRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: VersionRequest: wiretype end group for non-group") + return fmt.Errorf("proto: LinuxSandboxSecurityContext: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: VersionRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: LinuxSandboxSecurityContext: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field NamespaceOptions", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10048,21 +11820,193 @@ func (m *VersionRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Version = string(dAtA[iNdEx:postIndex]) + if m.NamespaceOptions == nil { + m.NamespaceOptions = &NamespaceOption{} + } + if err := m.NamespaceOptions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SelinuxOptions", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.SelinuxOptions == nil { + m.SelinuxOptions = &SELinuxOption{} + } + if err := m.SelinuxOptions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RunAsUser", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.RunAsUser == nil { + m.RunAsUser = &Int64Value{} + } + if err := m.RunAsUser.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ReadonlyRootfs", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.ReadonlyRootfs = bool(v != 0) + case 5: + if wireType == 0 { + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.SupplementalGroups = append(m.SupplementalGroups, v) + } else if wireType == 2 { + var packedLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + packedLen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if packedLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + packedLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + for iNdEx < postIndex { + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.SupplementalGroups = append(m.SupplementalGroups, v) + } + } else { + return fmt.Errorf("proto: wrong wireType = %d for field SupplementalGroups", wireType) + } + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Privileged", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Privileged = bool(v != 0) default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -10084,7 +12028,7 @@ func (m *VersionRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *VersionResponse) Unmarshal(dAtA []byte) error { +func (m *LinuxPodSandboxConfig) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -10107,15 +12051,15 @@ func (m *VersionResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: VersionResponse: wiretype end group for non-group") + return fmt.Errorf("proto: LinuxPodSandboxConfig: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: VersionResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: LinuxPodSandboxConfig: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field CgroupParent", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -10140,13 +12084,46 @@ func (m *VersionResponse) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Version = string(dAtA[iNdEx:postIndex]) + m.CgroupParent = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SecurityContext", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.SecurityContext == nil { + m.SecurityContext = &LinuxSandboxSecurityContext{} + } + if err := m.SecurityContext.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 2: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field RuntimeName", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Sysctls", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10156,26 +12133,19 @@ func (m *VersionResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.RuntimeName = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field RuntimeVersion", wireType) - } - var stringLen uint64 + var keykey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10185,26 +12155,12 @@ func (m *VersionResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.RuntimeVersion = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field RuntimeApiVersion", wireType) - } - var stringLen uint64 + var stringLenmapkey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10214,20 +12170,70 @@ func (m *VersionResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen - if postIndex > l { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - m.RuntimeApiVersion = string(dAtA[iNdEx:postIndex]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Sysctls == nil { + m.Sysctls = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Sysctls[mapkey] = mapvalue + } else { + var mapvalue string + m.Sysctls[mapkey] = mapvalue + } iNdEx = postIndex default: iNdEx = preIndex @@ -10250,7 +12256,7 @@ func (m *VersionResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *DNSConfig) Unmarshal(dAtA []byte) error { +func (m *PodSandboxMetadata) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -10273,15 +12279,15 @@ func (m *DNSConfig) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: DNSConfig: wiretype end group for non-group") + return fmt.Errorf("proto: PodSandboxMetadata: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: DNSConfig: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodSandboxMetadata: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Servers", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -10306,11 +12312,11 @@ func (m *DNSConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Servers = append(m.Servers, string(dAtA[iNdEx:postIndex])) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Searches", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -10335,11 +12341,11 @@ func (m *DNSConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Searches = append(m.Searches, string(dAtA[iNdEx:postIndex])) + m.Uid = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Options", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Namespace", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -10364,8 +12370,27 @@ func (m *DNSConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Options = append(m.Options, string(dAtA[iNdEx:postIndex])) + m.Namespace = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Attempt", wireType) + } + m.Attempt = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Attempt |= (uint32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -10387,7 +12412,7 @@ func (m *DNSConfig) Unmarshal(dAtA []byte) error { } return nil } -func (m *PortMapping) Unmarshal(dAtA []byte) error { +func (m *PodSandboxConfig) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -10410,17 +12435,17 @@ func (m *PortMapping) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PortMapping: wiretype end group for non-group") + return fmt.Errorf("proto: PodSandboxConfig: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PortMapping: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodSandboxConfig: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Protocol", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) } - m.Protocol = 0 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10430,16 +12455,30 @@ func (m *PortMapping) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.Protocol |= (Protocol(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Metadata == nil { + m.Metadata = &PodSandboxMetadata{} + } + if err := m.Metadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ContainerPort", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Hostname", wireType) } - m.ContainerPort = 0 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10449,16 +12488,26 @@ func (m *PortMapping) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.ContainerPort |= (int32(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Hostname = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field HostPort", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LogDirectory", wireType) } - m.HostPort = 0 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10468,16 +12517,26 @@ func (m *PortMapping) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.HostPort |= (int32(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.LogDirectory = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field HostIp", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field DnsConfig", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10487,76 +12546,30 @@ func (m *PortMapping) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.HostIp = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthApi - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *Mount) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if m.DnsConfig == nil { + m.DnsConfig = &DNSConfig{} } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: Mount: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Mount: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + if err := m.DnsConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ContainerPath", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PortMappings", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10566,26 +12579,28 @@ func (m *Mount) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.ContainerPath = string(dAtA[iNdEx:postIndex]) + m.PortMappings = append(m.PortMappings, &PortMapping{}) + if err := m.PortMappings[len(m.PortMappings)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 2: + case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field HostPath", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10595,26 +12610,19 @@ func (m *Mount) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.HostPath = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Readonly", wireType) - } - var v int + var keykey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10624,17 +12632,12 @@ func (m *Mount) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.Readonly = bool(v != 0) - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field SelinuxRelabel", wireType) - } - var v int + var stringLenmapkey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10644,67 +12647,76 @@ func (m *Mount) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.SelinuxRelabel = bool(v != 0) - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthApi } - if (iNdEx + skippy) > l { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *NamespaceOption) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Labels == nil { + m.Labels = make(map[string]string) } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Labels[mapkey] = mapvalue + } else { + var mapvalue string + m.Labels[mapkey] = mapvalue } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: NamespaceOption: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: NamespaceOption: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field HostNetwork", wireType) + iNdEx = postIndex + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) } - var v int + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10714,17 +12726,19 @@ func (m *NamespaceOption) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.HostNetwork = bool(v != 0) - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field HostPid", wireType) + if msglen < 0 { + return ErrInvalidLengthApi } - var v int + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10734,17 +12748,91 @@ func (m *NamespaceOption) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.HostPid = bool(v != 0) - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field HostIpc", wireType) + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Annotations == nil { + m.Annotations = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Annotations[mapkey] = mapvalue + } else { + var mapvalue string + m.Annotations[mapkey] = mapvalue + } + iNdEx = postIndex + case 8: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Linux", wireType) } - var v int + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10754,12 +12842,25 @@ func (m *NamespaceOption) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.HostIpc = bool(v != 0) + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Linux == nil { + m.Linux = &LinuxPodSandboxConfig{} + } + if err := m.Linux.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -10781,7 +12882,7 @@ func (m *NamespaceOption) Unmarshal(dAtA []byte) error { } return nil } -func (m *Int64Value) Unmarshal(dAtA []byte) error { +func (m *RunPodSandboxRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -10804,17 +12905,17 @@ func (m *Int64Value) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Int64Value: wiretype end group for non-group") + return fmt.Errorf("proto: RunPodSandboxRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Int64Value: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RunPodSandboxRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Config", wireType) } - m.Value = 0 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -10824,11 +12925,25 @@ func (m *Int64Value) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.Value |= (int64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Config == nil { + m.Config = &PodSandboxConfig{} + } + if err := m.Config.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -10850,7 +12965,7 @@ func (m *Int64Value) Unmarshal(dAtA []byte) error { } return nil } -func (m *LinuxSandboxSecurityContext) Unmarshal(dAtA []byte) error { +func (m *RunPodSandboxResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -10866,205 +12981,24 @@ func (m *LinuxSandboxSecurityContext) Unmarshal(dAtA []byte) error { b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: LinuxSandboxSecurityContext: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: LinuxSandboxSecurityContext: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field NamespaceOptions", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.NamespaceOptions == nil { - m.NamespaceOptions = &NamespaceOption{} - } - if err := m.NamespaceOptions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SelinuxOptions", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.SelinuxOptions == nil { - m.SelinuxOptions = &SELinuxOption{} - } - if err := m.SelinuxOptions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field RunAsUser", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.RunAsUser == nil { - m.RunAsUser = &Int64Value{} - } - if err := m.RunAsUser.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ReadonlyRootfs", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.ReadonlyRootfs = bool(v != 0) - case 5: - if wireType == 0 { - var v int64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.SupplementalGroups = append(m.SupplementalGroups, v) - } else if wireType == 2 { - var packedLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - packedLen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if packedLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + packedLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - for iNdEx < postIndex { - var v int64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.SupplementalGroups = append(m.SupplementalGroups, v) - } - } else { - return fmt.Errorf("proto: wrong wireType = %d for field SupplementalGroups", wireType) + if b < 0x80 { + break } - case 6: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Privileged", wireType) + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RunPodSandboxResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RunPodSandboxResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) } - var v int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -11074,12 +13008,21 @@ func (m *LinuxSandboxSecurityContext) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.Privileged = bool(v != 0) + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.PodSandboxId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -11101,7 +13044,7 @@ func (m *LinuxSandboxSecurityContext) Unmarshal(dAtA []byte) error { } return nil } -func (m *LinuxPodSandboxConfig) Unmarshal(dAtA []byte) error { +func (m *StopPodSandboxRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -11124,15 +13067,15 @@ func (m *LinuxPodSandboxConfig) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: LinuxPodSandboxConfig: wiretype end group for non-group") + return fmt.Errorf("proto: StopPodSandboxRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: LinuxPodSandboxConfig: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: StopPodSandboxRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field CgroupParent", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -11157,156 +13100,136 @@ func (m *LinuxPodSandboxConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.CgroupParent = string(dAtA[iNdEx:postIndex]) + m.PodSandboxId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SecurityContext", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err } - if msglen < 0 { + if skippy < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - if m.SecurityContext == nil { - m.SecurityContext = &LinuxSandboxSecurityContext{} + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *StopPodSandboxResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi } - if err := m.SecurityContext.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + if iNdEx >= l { + return io.ErrUnexpectedEOF } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Sysctls", wireType) + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: StopPodSandboxResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: StopPodSandboxResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err } - if msglen < 0 { + if skippy < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - var keykey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapkey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { - return ErrInvalidLengthApi + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RemovePodSandboxRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { + if iNdEx >= l { return io.ErrUnexpectedEOF } - mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - if m.Sysctls == nil { - m.Sysctls = make(map[string]string) + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break } - if iNdEx < postIndex { - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthApi - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RemovePodSandboxRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RemovePodSandboxRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { return io.ErrUnexpectedEOF } - mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - m.Sysctls[mapkey] = mapvalue - } else { - var mapvalue string - m.Sysctls[mapkey] = mapvalue + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF } + m.PodSandboxId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -11329,7 +13252,7 @@ func (m *LinuxPodSandboxConfig) Unmarshal(dAtA []byte) error { } return nil } -func (m *PodSandboxMetadata) Unmarshal(dAtA []byte) error { +func (m *RemovePodSandboxResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -11352,15 +13275,65 @@ func (m *PodSandboxMetadata) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodSandboxMetadata: wiretype end group for non-group") + return fmt.Errorf("proto: RemovePodSandboxResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodSandboxMetadata: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RemovePodSandboxResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PodSandboxStatusRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PodSandboxStatusRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PodSandboxStatusRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -11385,11 +13358,61 @@ func (m *PodSandboxMetadata) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(dAtA[iNdEx:postIndex]) + m.PodSandboxId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PodSandboxNetworkStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PodSandboxNetworkStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PodSandboxNetworkStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Ip", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -11414,13 +13437,63 @@ func (m *PodSandboxMetadata) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Uid = string(dAtA[iNdEx:postIndex]) + m.Ip = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 3: + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Namespace) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Namespace: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Namespace: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Namespace", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Options", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -11430,26 +13503,80 @@ func (m *PodSandboxMetadata) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Namespace = string(dAtA[iNdEx:postIndex]) + if m.Options == nil { + m.Options = &NamespaceOption{} + } + if err := m.Options.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Attempt", wireType) + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *LinuxPodSandboxStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: LinuxPodSandboxStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: LinuxPodSandboxStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Namespaces", wireType) } - m.Attempt = 0 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -11459,11 +13586,25 @@ func (m *PodSandboxMetadata) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.Attempt |= (uint32(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Namespaces == nil { + m.Namespaces = &Namespace{} + } + if err := m.Namespaces.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -11485,7 +13626,7 @@ func (m *PodSandboxMetadata) Unmarshal(dAtA []byte) error { } return nil } -func (m *PodSandboxConfig) Unmarshal(dAtA []byte) error { +func (m *PodSandboxStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -11508,17 +13649,17 @@ func (m *PodSandboxConfig) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodSandboxConfig: wiretype end group for non-group") + return fmt.Errorf("proto: PodSandboxStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodSandboxConfig: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodSandboxStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -11528,30 +13669,26 @@ func (m *PodSandboxConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if m.Metadata == nil { - m.Metadata = &PodSandboxMetadata{} - } - if err := m.Metadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Id = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Hostname", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -11561,26 +13698,30 @@ func (m *PodSandboxConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Hostname = string(dAtA[iNdEx:postIndex]) + if m.Metadata == nil { + m.Metadata = &PodSandboxMetadata{} + } + if err := m.Metadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LogDirectory", wireType) + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) } - var stringLen uint64 + m.State = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -11590,26 +13731,16 @@ func (m *PodSandboxConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + m.State |= (PodSandboxState(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.LogDirectory = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field DnsConfig", wireType) + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CreatedAt", wireType) } - var msglen int + m.CreatedAt = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -11619,28 +13750,14 @@ func (m *PodSandboxConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + m.CreatedAt |= (int64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.DnsConfig == nil { - m.DnsConfig = &DNSConfig{} - } - if err := m.DnsConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PortMappings", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Network", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -11664,14 +13781,16 @@ func (m *PodSandboxConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.PortMappings = append(m.PortMappings, &PortMapping{}) - if err := m.PortMappings[len(m.PortMappings)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.Network == nil { + m.Network = &PodSandboxNetworkStatus{} + } + if err := m.Network.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Linux", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -11695,99 +13814,16 @@ func (m *PodSandboxConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - var keykey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapkey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { - return ErrInvalidLengthApi - } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { - return io.ErrUnexpectedEOF - } - mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - if m.Labels == nil { - m.Labels = make(map[string]string) + if m.Linux == nil { + m.Linux = &LinuxPodSandboxStatus{} } - if iNdEx < postIndex { - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthApi - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - m.Labels[mapkey] = mapvalue - } else { - var mapvalue string - m.Labels[mapkey] = mapvalue + if err := m.Linux.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } iNdEx = postIndex case 7: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -11851,8 +13887,8 @@ func (m *PodSandboxConfig) Unmarshal(dAtA []byte) error { } mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - if m.Annotations == nil { - m.Annotations = make(map[string]string) + if m.Labels == nil { + m.Labels = make(map[string]string) } if iNdEx < postIndex { var valuekey uint64 @@ -11892,101 +13928,18 @@ func (m *PodSandboxConfig) Unmarshal(dAtA []byte) error { postStringIndexmapvalue := iNdEx + intStringLenmapvalue if postStringIndexmapvalue > l { return io.ErrUnexpectedEOF - } - mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - m.Annotations[mapkey] = mapvalue - } else { - var mapvalue string - m.Annotations[mapkey] = mapvalue - } - iNdEx = postIndex - case 8: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Linux", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Linux == nil { - m.Linux = &LinuxPodSandboxConfig{} - } - if err := m.Linux.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Labels[mapkey] = mapvalue + } else { + var mapvalue string + m.Labels[mapkey] = mapvalue } iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthApi - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *RunPodSandboxRequest) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: RunPodSandboxRequest: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: RunPodSandboxRequest: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + case 8: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Config", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -12010,68 +13963,7 @@ func (m *RunPodSandboxRequest) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Config == nil { - m.Config = &PodSandboxConfig{} - } - if err := m.Config.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthApi - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *RunPodSandboxResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: RunPodSandboxResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: RunPodSandboxResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) - } - var stringLen uint64 + var keykey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -12081,76 +13973,12 @@ func (m *RunPodSandboxResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.PodSandboxId = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthApi - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *StopPodSandboxRequest) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: StopPodSandboxRequest: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: StopPodSandboxRequest: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) - } - var stringLen uint64 + var stringLenmapkey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -12160,71 +13988,71 @@ func (m *StopPodSandboxRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.PodSandboxId = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthApi } - if (iNdEx + skippy) > l { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *StopPodSandboxResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Annotations == nil { + m.Annotations = make(map[string]string) } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Annotations[mapkey] = mapvalue + } else { + var mapvalue string + m.Annotations[mapkey] = mapvalue } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: StopPodSandboxResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: StopPodSandboxResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -12246,7 +14074,7 @@ func (m *StopPodSandboxResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *RemovePodSandboxRequest) Unmarshal(dAtA []byte) error { +func (m *PodSandboxStatusResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -12269,17 +14097,17 @@ func (m *RemovePodSandboxRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RemovePodSandboxRequest: wiretype end group for non-group") + return fmt.Errorf("proto: PodSandboxStatusResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RemovePodSandboxRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodSandboxStatusResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -12289,20 +14117,24 @@ func (m *RemovePodSandboxRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.PodSandboxId = string(dAtA[iNdEx:postIndex]) + if m.Status == nil { + m.Status = &PodSandboxStatus{} + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex @@ -12325,7 +14157,7 @@ func (m *RemovePodSandboxRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *RemovePodSandboxResponse) Unmarshal(dAtA []byte) error { +func (m *PodSandboxStateValue) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -12348,12 +14180,31 @@ func (m *RemovePodSandboxResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RemovePodSandboxResponse: wiretype end group for non-group") + return fmt.Errorf("proto: PodSandboxStateValue: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RemovePodSandboxResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodSandboxStateValue: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) + } + m.State = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.State |= (PodSandboxState(b) & 0x7F) << shift + if b < 0x80 { + break + } + } default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -12375,7 +14226,7 @@ func (m *RemovePodSandboxResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *PodSandboxStatusRequest) Unmarshal(dAtA []byte) error { +func (m *PodSandboxFilter) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -12398,15 +14249,15 @@ func (m *PodSandboxStatusRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodSandboxStatusRequest: wiretype end group for non-group") + return fmt.Errorf("proto: PodSandboxFilter: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodSandboxStatusRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodSandboxFilter: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -12431,63 +14282,13 @@ func (m *PodSandboxStatusRequest) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.PodSandboxId = string(dAtA[iNdEx:postIndex]) + m.Id = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthApi - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *PodSandboxNetworkStatus) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: PodSandboxNetworkStatus: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: PodSandboxNetworkStatus: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Ip", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -12497,76 +14298,67 @@ func (m *PodSandboxNetworkStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Ip = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { + if m.State == nil { + m.State = &PodSandboxStateValue{} + } + if err := m.State.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } - if skippy < 0 { - return ErrInvalidLengthApi + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LabelSelector", wireType) } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *Namespace) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi + if msglen < 0 { + return ErrInvalidLengthApi } - if iNdEx >= l { + postIndex := iNdEx + msglen + if postIndex > l { return io.ErrUnexpectedEOF } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: Namespace: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Namespace: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Options", wireType) + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - var msglen int + var stringLenmapkey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -12576,23 +14368,69 @@ func (m *Namespace) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen - if postIndex > l { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - if m.Options == nil { - m.Options = &NamespaceOption{} + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.LabelSelector == nil { + m.LabelSelector = make(map[string]string) } - if err := m.Options.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.LabelSelector[mapkey] = mapvalue + } else { + var mapvalue string + m.LabelSelector[mapkey] = mapvalue } iNdEx = postIndex default: @@ -12616,7 +14454,7 @@ func (m *Namespace) Unmarshal(dAtA []byte) error { } return nil } -func (m *LinuxPodSandboxStatus) Unmarshal(dAtA []byte) error { +func (m *ListPodSandboxRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -12639,15 +14477,15 @@ func (m *LinuxPodSandboxStatus) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: LinuxPodSandboxStatus: wiretype end group for non-group") + return fmt.Errorf("proto: ListPodSandboxRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: LinuxPodSandboxStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ListPodSandboxRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Namespaces", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Filter", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -12671,10 +14509,10 @@ func (m *LinuxPodSandboxStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Namespaces == nil { - m.Namespaces = &Namespace{} + if m.Filter == nil { + m.Filter = &PodSandboxFilter{} } - if err := m.Namespaces.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Filter.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -12699,7 +14537,7 @@ func (m *LinuxPodSandboxStatus) Unmarshal(dAtA []byte) error { } return nil } -func (m *PodSandboxStatus) Unmarshal(dAtA []byte) error { +func (m *PodSandbox) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -12722,10 +14560,10 @@ func (m *PodSandboxStatus) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodSandboxStatus: wiretype end group for non-group") + return fmt.Errorf("proto: PodSandbox: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodSandboxStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodSandbox: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -12830,7 +14668,7 @@ func (m *PodSandboxStatus) Unmarshal(dAtA []byte) error { } case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Network", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -12854,18 +14692,22 @@ func (m *PodSandboxStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Network == nil { - m.Network = &PodSandboxNetworkStatus{} - } - if err := m.Network.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 6: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Linux", wireType) + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - var msglen int + var stringLenmapkey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -12875,28 +14717,74 @@ func (m *PodSandboxStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen - if postIndex > l { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - if m.Linux == nil { - m.Linux = &LinuxPodSandboxStatus{} + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Labels == nil { + m.Labels = make(map[string]string) } - if err := m.Linux.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Labels[mapkey] = mapvalue + } else { + var mapvalue string + m.Labels[mapkey] = mapvalue } iNdEx = postIndex - case 7: + case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -12960,8 +14848,8 @@ func (m *PodSandboxStatus) Unmarshal(dAtA []byte) error { } mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - if m.Labels == nil { - m.Labels = make(map[string]string) + if m.Annotations == nil { + m.Annotations = make(map[string]string) } if iNdEx < postIndex { var valuekey uint64 @@ -13004,39 +14892,67 @@ func (m *PodSandboxStatus) Unmarshal(dAtA []byte) error { } mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) iNdEx = postStringIndexmapvalue - m.Labels[mapkey] = mapvalue + m.Annotations[mapkey] = mapvalue } else { var mapvalue string - m.Labels[mapkey] = mapvalue + m.Annotations[mapkey] = mapvalue } iNdEx = postIndex - case 8: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err } - if msglen < 0 { + if skippy < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen - if postIndex > l { + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ListPodSandboxResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { return io.ErrUnexpectedEOF } - var keykey uint64 + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ListPodSandboxResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ListPodSandboxResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13046,12 +14962,78 @@ func (m *PodSandboxStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - var stringLenmapkey uint64 + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, &PodSandbox{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ImageSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ImageSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ImageSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) + } + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13061,70 +15043,20 @@ func (m *PodSandboxStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { + postIndex := iNdEx + intStringLen + if postIndex > l { return io.ErrUnexpectedEOF } - mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - if m.Annotations == nil { - m.Annotations = make(map[string]string) - } - if iNdEx < postIndex { - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthApi - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - m.Annotations[mapkey] = mapvalue - } else { - var mapvalue string - m.Annotations[mapkey] = mapvalue - } + m.Image = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -13147,7 +15079,7 @@ func (m *PodSandboxStatus) Unmarshal(dAtA []byte) error { } return nil } -func (m *PodSandboxStatusResponse) Unmarshal(dAtA []byte) error { +func (m *KeyValue) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -13170,17 +15102,17 @@ func (m *PodSandboxStatusResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodSandboxStatusResponse: wiretype end group for non-group") + return fmt.Errorf("proto: KeyValue: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodSandboxStatusResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: KeyValue: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13190,24 +15122,49 @@ func (m *PodSandboxStatusResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if m.Status == nil { - m.Status = &PodSandboxStatus{} + m.Key = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) } - if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF } + m.Value = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -13230,7 +15187,7 @@ func (m *PodSandboxStatusResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *PodSandboxStateValue) Unmarshal(dAtA []byte) error { +func (m *LinuxContainerResources) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -13240,30 +15197,106 @@ func (m *PodSandboxStateValue) Unmarshal(dAtA []byte) error { if shift >= 64 { return ErrIntOverflowApi } - if iNdEx >= l { - return io.ErrUnexpectedEOF + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: LinuxContainerResources: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: LinuxContainerResources: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CpuPeriod", wireType) + } + m.CpuPeriod = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.CpuPeriod |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CpuQuota", wireType) + } + m.CpuQuota = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.CpuQuota |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CpuShares", wireType) + } + m.CpuShares = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.CpuShares |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field MemoryLimitInBytes", wireType) } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + m.MemoryLimitInBytes = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.MemoryLimitInBytes |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: PodSandboxStateValue: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: PodSandboxStateValue: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + case 5: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field OomScoreAdj", wireType) } - m.State = 0 + m.OomScoreAdj = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13273,7 +15306,7 @@ func (m *PodSandboxStateValue) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.State |= (PodSandboxState(b) & 0x7F) << shift + m.OomScoreAdj |= (int64(b) & 0x7F) << shift if b < 0x80 { break } @@ -13299,7 +15332,7 @@ func (m *PodSandboxStateValue) Unmarshal(dAtA []byte) error { } return nil } -func (m *PodSandboxFilter) Unmarshal(dAtA []byte) error { +func (m *SELinuxOption) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -13322,15 +15355,15 @@ func (m *PodSandboxFilter) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodSandboxFilter: wiretype end group for non-group") + return fmt.Errorf("proto: SELinuxOption: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodSandboxFilter: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SELinuxOption: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field User", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -13355,13 +15388,13 @@ func (m *PodSandboxFilter) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Id = string(dAtA[iNdEx:postIndex]) + m.User = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Role", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13371,30 +15404,26 @@ func (m *PodSandboxFilter) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if m.State == nil { - m.State = &PodSandboxStateValue{} - } - if err := m.State.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Role = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LabelSelector", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13404,34 +15433,26 @@ func (m *PodSandboxFilter) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - var keykey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } + m.Type = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Level", wireType) } - var stringLenmapkey uint64 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13441,70 +15462,20 @@ func (m *PodSandboxFilter) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { + postIndex := iNdEx + intStringLen + if postIndex > l { return io.ErrUnexpectedEOF } - mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - if m.LabelSelector == nil { - m.LabelSelector = make(map[string]string) - } - if iNdEx < postIndex { - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthApi - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - m.LabelSelector[mapkey] = mapvalue - } else { - var mapvalue string - m.LabelSelector[mapkey] = mapvalue - } + m.Level = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -13527,7 +15498,7 @@ func (m *PodSandboxFilter) Unmarshal(dAtA []byte) error { } return nil } -func (m *ListPodSandboxRequest) Unmarshal(dAtA []byte) error { +func (m *Capability) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -13550,17 +15521,17 @@ func (m *ListPodSandboxRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ListPodSandboxRequest: wiretype end group for non-group") + return fmt.Errorf("proto: Capability: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ListPodSandboxRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Capability: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Filter", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field AddCapabilities", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13570,24 +15541,49 @@ func (m *ListPodSandboxRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if m.Filter == nil { - m.Filter = &PodSandboxFilter{} + m.AddCapabilities = append(m.AddCapabilities, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field DropCapabilities", wireType) } - if err := m.Filter.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF } + m.DropCapabilities = append(m.DropCapabilities, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex @@ -13610,7 +15606,7 @@ func (m *ListPodSandboxRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *PodSandbox) Unmarshal(dAtA []byte) error { +func (m *LinuxContainerSecurityContext) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -13633,44 +15629,15 @@ func (m *PodSandbox) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodSandbox: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: PodSandbox: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: LinuxContainerSecurityContext: wiretype end group for non-group") } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Id = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: + if fieldNum <= 0 { + return fmt.Errorf("proto: LinuxContainerSecurityContext: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Capabilities", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -13694,37 +15661,18 @@ func (m *PodSandbox) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Metadata == nil { - m.Metadata = &PodSandboxMetadata{} + if m.Capabilities == nil { + m.Capabilities = &Capability{} } - if err := m.Metadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Capabilities.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) - } - m.State = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.State |= (PodSandboxState(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 4: + case 2: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field CreatedAt", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Privileged", wireType) } - m.CreatedAt = 0 + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13734,14 +15682,15 @@ func (m *PodSandbox) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.CreatedAt |= (int64(b) & 0x7F) << shift + v |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - case 5: + m.Privileged = bool(v != 0) + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field NamespaceOptions", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -13765,22 +15714,18 @@ func (m *PodSandbox) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - var keykey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } + if m.NamespaceOptions == nil { + m.NamespaceOptions = &NamespaceOption{} } - var stringLenmapkey uint64 + if err := m.NamespaceOptions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SelinuxOptions", wireType) + } + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13790,74 +15735,28 @@ func (m *PodSandbox) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { + postIndex := iNdEx + msglen + if postIndex > l { return io.ErrUnexpectedEOF } - mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - if m.Labels == nil { - m.Labels = make(map[string]string) + if m.SelinuxOptions == nil { + m.SelinuxOptions = &SELinuxOption{} } - if iNdEx < postIndex { - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthApi - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - m.Labels[mapkey] = mapvalue - } else { - var mapvalue string - m.Labels[mapkey] = mapvalue + if err := m.SelinuxOptions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } iNdEx = postIndex - case 6: + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field RunAsUser", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -13881,7 +15780,18 @@ func (m *PodSandbox) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - var keykey uint64 + if m.RunAsUser == nil { + m.RunAsUser = &Int64Value{} + } + if err := m.RunAsUser.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RunAsUsername", wireType) + } + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13891,12 +15801,26 @@ func (m *PodSandbox) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - var stringLenmapkey uint64 + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.RunAsUsername = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 7: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ReadonlyRootfs", wireType) + } + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13906,26 +15830,15 @@ func (m *PodSandbox) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift + v |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { - return ErrInvalidLengthApi - } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { - return io.ErrUnexpectedEOF - } - mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - if m.Annotations == nil { - m.Annotations = make(map[string]string) - } - if iNdEx < postIndex { - var valuekey uint64 + m.ReadonlyRootfs = bool(v != 0) + case 8: + if wireType == 0 { + var v int64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13935,12 +15848,14 @@ func (m *PodSandbox) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift + v |= (int64(b) & 0x7F) << shift if b < 0x80 { break } } - var stringLenmapvalue uint64 + m.SupplementalGroups = append(m.SupplementalGroups, v) + } else if wireType == 2 { + var packedLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -13950,26 +15865,67 @@ func (m *PodSandbox) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift + packedLen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { + if packedLen < 0 { return ErrInvalidLengthApi } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { + postIndex := iNdEx + packedLen + if postIndex > l { return io.ErrUnexpectedEOF } - mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - m.Annotations[mapkey] = mapvalue + for iNdEx < postIndex { + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.SupplementalGroups = append(m.SupplementalGroups, v) + } } else { - var mapvalue string - m.Annotations[mapkey] = mapvalue + return fmt.Errorf("proto: wrong wireType = %d for field SupplementalGroups", wireType) + } + case 9: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ApparmorProfile", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF } + m.ApparmorProfile = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -13992,7 +15948,7 @@ func (m *PodSandbox) Unmarshal(dAtA []byte) error { } return nil } -func (m *ListPodSandboxResponse) Unmarshal(dAtA []byte) error { +func (m *LinuxContainerConfig) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -14015,15 +15971,15 @@ func (m *ListPodSandboxResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ListPodSandboxResponse: wiretype end group for non-group") + return fmt.Errorf("proto: LinuxContainerConfig: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ListPodSandboxResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: LinuxContainerConfig: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Resources", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -14047,8 +16003,43 @@ func (m *ListPodSandboxResponse) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, &PodSandbox{}) - if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.Resources == nil { + m.Resources = &LinuxContainerResources{} + } + if err := m.Resources.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SecurityContext", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.SecurityContext == nil { + m.SecurityContext = &LinuxContainerSecurityContext{} + } + if err := m.SecurityContext.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -14073,7 +16064,7 @@ func (m *ListPodSandboxResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *ImageSpec) Unmarshal(dAtA []byte) error { +func (m *ContainerMetadata) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -14096,15 +16087,15 @@ func (m *ImageSpec) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ImageSpec: wiretype end group for non-group") + return fmt.Errorf("proto: ContainerMetadata: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ImageSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ContainerMetadata: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -14129,8 +16120,27 @@ func (m *ImageSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Image = string(dAtA[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Attempt", wireType) + } + m.Attempt = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Attempt |= (uint32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -14152,7 +16162,7 @@ func (m *ImageSpec) Unmarshal(dAtA []byte) error { } return nil } -func (m *KeyValue) Unmarshal(dAtA []byte) error { +func (m *Device) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -14175,15 +16185,15 @@ func (m *KeyValue) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: KeyValue: wiretype end group for non-group") + return fmt.Errorf("proto: Device: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: KeyValue: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Device: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ContainerPath", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -14208,11 +16218,11 @@ func (m *KeyValue) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Key = string(dAtA[iNdEx:postIndex]) + m.ContainerPath = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field HostPath", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -14237,7 +16247,36 @@ func (m *KeyValue) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Value = string(dAtA[iNdEx:postIndex]) + m.HostPath = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Permissions", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Permissions = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -14260,7 +16299,7 @@ func (m *KeyValue) Unmarshal(dAtA []byte) error { } return nil } -func (m *LinuxContainerResources) Unmarshal(dAtA []byte) error { +func (m *ContainerConfig) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -14283,36 +16322,17 @@ func (m *LinuxContainerResources) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: LinuxContainerResources: wiretype end group for non-group") + return fmt.Errorf("proto: ContainerConfig: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: LinuxContainerResources: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ContainerConfig: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field CpuPeriod", wireType) - } - m.CpuPeriod = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.CpuPeriod |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field CpuQuota", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) } - m.CpuQuota = 0 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -14322,54 +16342,30 @@ func (m *LinuxContainerResources) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.CpuQuota |= (int64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field CpuShares", wireType) + if msglen < 0 { + return ErrInvalidLengthApi } - m.CpuShares = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.CpuShares |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF } - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field MemoryLimitInBytes", wireType) + if m.Metadata == nil { + m.Metadata = &ContainerMetadata{} } - m.MemoryLimitInBytes = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.MemoryLimitInBytes |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } + if err := m.Metadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - case 5: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field OomScoreAdj", wireType) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) } - m.OomScoreAdj = 0 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -14379,64 +16375,28 @@ func (m *LinuxContainerResources) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.OomScoreAdj |= (int64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *SELinuxOption) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { + postIndex := iNdEx + msglen + if postIndex > l { return io.ErrUnexpectedEOF } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: SELinuxOption: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: SELinuxOption: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + if m.Image == nil { + m.Image = &ImageSpec{} + } + if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field User", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Command", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -14461,11 +16421,11 @@ func (m *SELinuxOption) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.User = string(dAtA[iNdEx:postIndex]) + m.Command = append(m.Command, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex - case 2: + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Role", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Args", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -14490,11 +16450,11 @@ func (m *SELinuxOption) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Role = string(dAtA[iNdEx:postIndex]) + m.Args = append(m.Args, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex - case 3: + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field WorkingDir", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -14519,13 +16479,13 @@ func (m *SELinuxOption) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = string(dAtA[iNdEx:postIndex]) + m.WorkingDir = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 4: + case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Level", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Envs", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -14535,76 +16495,59 @@ func (m *SELinuxOption) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Level = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { + m.Envs = append(m.Envs, &KeyValue{}) + if err := m.Envs[len(m.Envs)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } - if skippy < 0 { - return ErrInvalidLengthApi + iNdEx = postIndex + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Mounts", wireType) } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *Capability) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi + if msglen < 0 { + return ErrInvalidLengthApi } - if iNdEx >= l { + postIndex := iNdEx + msglen + if postIndex > l { return io.ErrUnexpectedEOF } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + m.Mounts = append(m.Mounts, &Mount{}) + if err := m.Mounts[len(m.Mounts)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: Capability: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Capability: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + iNdEx = postIndex + case 8: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field AddCapabilities", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Devices", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -14614,26 +16557,28 @@ func (m *Capability) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.AddCapabilities = append(m.AddCapabilities, string(dAtA[iNdEx:postIndex])) + m.Devices = append(m.Devices, &Device{}) + if err := m.Devices[len(m.Devices)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 2: + case 9: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field DropCapabilities", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -14643,74 +16588,111 @@ func (m *Capability) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.DropCapabilities = append(m.DropCapabilities, string(dAtA[iNdEx:postIndex])) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if skippy < 0 { + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthApi } - if (iNdEx + skippy) > l { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *LinuxContainerSecurityContext) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Labels == nil { + m.Labels = make(map[string]string) } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Labels[mapkey] = mapvalue + } else { + var mapvalue string + m.Labels[mapkey] = mapvalue } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: LinuxContainerSecurityContext: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: LinuxContainerSecurityContext: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + iNdEx = postIndex + case 10: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Capabilities", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -14734,18 +16716,7 @@ func (m *LinuxContainerSecurityContext) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Capabilities == nil { - m.Capabilities = &Capability{} - } - if err := m.Capabilities.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Privileged", wireType) - } - var v int + var keykey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -14755,17 +16726,12 @@ func (m *LinuxContainerSecurityContext) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.Privileged = bool(v != 0) - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field NamespaceOptions", wireType) - } - var msglen int + var stringLenmapkey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -14775,30 +16741,76 @@ func (m *LinuxContainerSecurityContext) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen - if postIndex > l { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - if m.NamespaceOptions == nil { - m.NamespaceOptions = &NamespaceOption{} + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Annotations == nil { + m.Annotations = make(map[string]string) } - if err := m.NamespaceOptions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Annotations[mapkey] = mapvalue + } else { + var mapvalue string + m.Annotations[mapkey] = mapvalue } iNdEx = postIndex - case 4: + case 11: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SelinuxOptions", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field LogPath", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -14808,30 +16820,26 @@ func (m *LinuxContainerSecurityContext) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if m.SelinuxOptions == nil { - m.SelinuxOptions = &SELinuxOption{} - } - if err := m.SelinuxOptions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.LogPath = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field RunAsUser", wireType) + case 12: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Stdin", wireType) } - var msglen int + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -14841,30 +16849,17 @@ func (m *LinuxContainerSecurityContext) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + v |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.RunAsUser == nil { - m.RunAsUser = &Int64Value{} - } - if err := m.RunAsUser.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 6: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field RunAsUsername", wireType) + m.Stdin = bool(v != 0) + case 13: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field StdinOnce", wireType) } - var stringLen uint64 + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -14874,24 +16869,15 @@ func (m *LinuxContainerSecurityContext) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + v |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.RunAsUsername = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 7: + m.StdinOnce = bool(v != 0) + case 14: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ReadonlyRootfs", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Tty", wireType) } var v int for shift := uint(0); ; shift += 7 { @@ -14908,74 +16894,12 @@ func (m *LinuxContainerSecurityContext) Unmarshal(dAtA []byte) error { break } } - m.ReadonlyRootfs = bool(v != 0) - case 8: - if wireType == 0 { - var v int64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.SupplementalGroups = append(m.SupplementalGroups, v) - } else if wireType == 2 { - var packedLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - packedLen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if packedLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + packedLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - for iNdEx < postIndex { - var v int64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.SupplementalGroups = append(m.SupplementalGroups, v) - } - } else { - return fmt.Errorf("proto: wrong wireType = %d for field SupplementalGroups", wireType) - } - case 9: + m.Tty = bool(v != 0) + case 15: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ApparmorProfile", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Linux", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -14985,20 +16909,24 @@ func (m *LinuxContainerSecurityContext) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.ApparmorProfile = string(dAtA[iNdEx:postIndex]) + if m.Linux == nil { + m.Linux = &LinuxContainerConfig{} + } + if err := m.Linux.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex @@ -15021,7 +16949,7 @@ func (m *LinuxContainerSecurityContext) Unmarshal(dAtA []byte) error { } return nil } -func (m *LinuxContainerConfig) Unmarshal(dAtA []byte) error { +func (m *CreateContainerRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -15044,15 +16972,44 @@ func (m *LinuxContainerConfig) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: LinuxContainerConfig: wiretype end group for non-group") + return fmt.Errorf("proto: CreateContainerRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: LinuxContainerConfig: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: CreateContainerRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Resources", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.PodSandboxId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Config", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -15076,16 +17033,16 @@ func (m *LinuxContainerConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Resources == nil { - m.Resources = &LinuxContainerResources{} + if m.Config == nil { + m.Config = &ContainerConfig{} } - if err := m.Resources.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Config.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 2: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SecurityContext", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field SandboxConfig", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -15109,10 +17066,10 @@ func (m *LinuxContainerConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.SecurityContext == nil { - m.SecurityContext = &LinuxContainerSecurityContext{} + if m.SandboxConfig == nil { + m.SandboxConfig = &PodSandboxConfig{} } - if err := m.SecurityContext.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.SandboxConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -15137,7 +17094,7 @@ func (m *LinuxContainerConfig) Unmarshal(dAtA []byte) error { } return nil } -func (m *ContainerMetadata) Unmarshal(dAtA []byte) error { +func (m *CreateContainerResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -15160,15 +17117,15 @@ func (m *ContainerMetadata) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ContainerMetadata: wiretype end group for non-group") + return fmt.Errorf("proto: CreateContainerResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ContainerMetadata: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: CreateContainerResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ContainerId", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -15193,13 +17150,63 @@ func (m *ContainerMetadata) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(dAtA[iNdEx:postIndex]) + m.ContainerId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Attempt", wireType) + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err } - m.Attempt = 0 + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *StartContainerRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: StartContainerRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: StartContainerRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ContainerId", wireType) + } + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -15209,11 +17216,21 @@ func (m *ContainerMetadata) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.Attempt |= (uint32(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ContainerId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -15235,7 +17252,7 @@ func (m *ContainerMetadata) Unmarshal(dAtA []byte) error { } return nil } -func (m *Device) Unmarshal(dAtA []byte) error { +func (m *StartContainerResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -15258,15 +17275,65 @@ func (m *Device) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Device: wiretype end group for non-group") + return fmt.Errorf("proto: StartContainerResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Device: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: StartContainerResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *StopContainerRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: StopContainerRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: StopContainerRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ContainerPath", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ContainerId", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -15291,13 +17358,13 @@ func (m *Device) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ContainerPath = string(dAtA[iNdEx:postIndex]) + m.ContainerId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field HostPath", wireType) + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Timeout", wireType) } - var stringLen uint64 + m.Timeout = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -15307,24 +17374,114 @@ func (m *Device) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + m.Timeout |= (int64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *StopContainerResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: StopContainerResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: StopContainerResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - m.HostPath = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 3: + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RemoveContainerRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RemoveContainerRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RemoveContainerRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Permissions", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ContainerId", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -15349,7 +17506,7 @@ func (m *Device) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Permissions = string(dAtA[iNdEx:postIndex]) + m.ContainerId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -15372,7 +17529,7 @@ func (m *Device) Unmarshal(dAtA []byte) error { } return nil } -func (m *ContainerConfig) Unmarshal(dAtA []byte) error { +func (m *RemoveContainerResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -15395,83 +17552,67 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ContainerConfig: wiretype end group for non-group") + return fmt.Errorf("proto: RemoveContainerResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ContainerConfig: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RemoveContainerResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err } - if msglen < 0 { + if skippy < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - if m.Metadata == nil { - m.Metadata = &ContainerMetadata{} - } - if err := m.Metadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthApi + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ContainerStateValue) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi } - postIndex := iNdEx + msglen - if postIndex > l { + if iNdEx >= l { return io.ErrUnexpectedEOF } - if m.Image == nil { - m.Image = &ImageSpec{} - } - if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Command", wireType) + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ContainerStateValue: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ContainerStateValue: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) } - var stringLen uint64 + m.State = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -15481,84 +17622,66 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + m.State |= (ContainerState(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Command = append(m.Command, string(dAtA[iNdEx:postIndex])) - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Args", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err } - intStringLen := int(stringLen) - if intStringLen < 0 { + if skippy < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - m.Args = append(m.Args, string(dAtA[iNdEx:postIndex])) - iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field WorkingDir", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ContainerFilter) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi } - postIndex := iNdEx + intStringLen - if postIndex > l { + if iNdEx >= l { return io.ErrUnexpectedEOF } - m.WorkingDir = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 6: + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ContainerFilter: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ContainerFilter: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Envs", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -15568,26 +17691,24 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - m.Envs = append(m.Envs, &KeyValue{}) - if err := m.Envs[len(m.Envs)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Id = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 7: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Mounts", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -15611,16 +17732,18 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Mounts = append(m.Mounts, &Mount{}) - if err := m.Mounts[len(m.Mounts)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.State == nil { + m.State = &ContainerStateValue{} + } + if err := m.State.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 8: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Devices", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -15630,26 +17753,24 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - m.Devices = append(m.Devices, &Device{}) - if err := m.Devices[len(m.Devices)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.PodSandboxId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 9: + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field LabelSelector", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -15713,8 +17834,8 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { } mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - if m.Labels == nil { - m.Labels = make(map[string]string) + if m.LabelSelector == nil { + m.LabelSelector = make(map[string]string) } if iNdEx < postIndex { var valuekey uint64 @@ -15757,15 +17878,206 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { } mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) iNdEx = postStringIndexmapvalue - m.Labels[mapkey] = mapvalue + m.LabelSelector[mapkey] = mapvalue } else { var mapvalue string - m.Labels[mapkey] = mapvalue + m.LabelSelector[mapkey] = mapvalue + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ListContainersRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ListContainersRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ListContainersRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Filter", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Filter == nil { + m.Filter = &ContainerFilter{} + } + if err := m.Filter.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Container) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Container: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Container: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Id = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF } + m.PodSandboxId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 10: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -15789,22 +18101,18 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - var keykey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } + if m.Metadata == nil { + m.Metadata = &ContainerMetadata{} } - var stringLenmapkey uint64 + if err := m.Metadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) + } + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -15814,74 +18122,28 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { + postIndex := iNdEx + msglen + if postIndex > l { return io.ErrUnexpectedEOF } - mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - if m.Annotations == nil { - m.Annotations = make(map[string]string) + if m.Image == nil { + m.Image = &ImageSpec{} } - if iNdEx < postIndex { - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthApi - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - m.Annotations[mapkey] = mapvalue - } else { - var mapvalue string - m.Annotations[mapkey] = mapvalue + if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } iNdEx = postIndex - case 11: + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LogPath", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ImageRef", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -15906,13 +18168,13 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.LogPath = string(dAtA[iNdEx:postIndex]) + m.ImageRef = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 12: + case 6: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Stdin", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) } - var v int + m.State = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -15922,17 +18184,16 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + m.State |= (ContainerState(b) & 0x7F) << shift if b < 0x80 { break } } - m.Stdin = bool(v != 0) - case 13: + case 7: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field StdinOnce", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field CreatedAt", wireType) } - var v int + m.CreatedAt = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -15942,17 +18203,16 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + m.CreatedAt |= (int64(b) & 0x7F) << shift if b < 0x80 { break } } - m.StdinOnce = bool(v != 0) - case 14: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Tty", wireType) + case 8: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) } - var v int + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -15962,17 +18222,19 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.Tty = bool(v != 0) - case 15: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Linux", wireType) + if msglen < 0 { + return ErrInvalidLengthApi } - var msglen int + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -15982,107 +18244,89 @@ func (m *ContainerConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Linux == nil { - m.Linux = &LinuxContainerConfig{} - } - if err := m.Linux.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if skippy < 0 { + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthApi } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *CreateContainerRequest) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: CreateContainerRequest: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: CreateContainerRequest: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Labels == nil { + m.Labels = make(map[string]string) } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Labels[mapkey] = mapvalue + } else { + var mapvalue string + m.Labels[mapkey] = mapvalue } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.PodSandboxId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 9: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Config", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -16106,18 +18350,7 @@ func (m *CreateContainerRequest) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Config == nil { - m.Config = &ContainerConfig{} - } - if err := m.Config.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SandboxConfig", wireType) - } - var msglen int + var keykey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -16127,80 +18360,12 @@ func (m *CreateContainerRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.SandboxConfig == nil { - m.SandboxConfig = &PodSandboxConfig{} - } - if err := m.SandboxConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthApi - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *CreateContainerResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: CreateContainerResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: CreateContainerResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ContainerId", wireType) - } - var stringLen uint64 + var stringLenmapkey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -16210,20 +18375,70 @@ func (m *CreateContainerResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen - if postIndex > l { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - m.ContainerId = string(dAtA[iNdEx:postIndex]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Annotations == nil { + m.Annotations = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Annotations[mapkey] = mapvalue + } else { + var mapvalue string + m.Annotations[mapkey] = mapvalue + } iNdEx = postIndex default: iNdEx = preIndex @@ -16246,7 +18461,7 @@ func (m *CreateContainerResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *StartContainerRequest) Unmarshal(dAtA []byte) error { +func (m *ListContainersResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -16269,17 +18484,17 @@ func (m *StartContainerRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: StartContainerRequest: wiretype end group for non-group") + return fmt.Errorf("proto: ListContainersResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: StartContainerRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ListContainersResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ContainerId", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Containers", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -16289,71 +18504,23 @@ func (m *StartContainerRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ContainerId = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthApi - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *StartContainerResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: StartContainerResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: StartContainerResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { + return io.ErrUnexpectedEOF + } + m.Containers = append(m.Containers, &Container{}) + if err := m.Containers[len(m.Containers)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -16375,7 +18542,7 @@ func (m *StartContainerResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *StopContainerRequest) Unmarshal(dAtA []byte) error { +func (m *ContainerStatusRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -16398,10 +18565,10 @@ func (m *StopContainerRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: StopContainerRequest: wiretype end group for non-group") + return fmt.Errorf("proto: ContainerStatusRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: StopContainerRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ContainerStatusRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -16433,25 +18600,6 @@ func (m *StopContainerRequest) Unmarshal(dAtA []byte) error { } m.ContainerId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Timeout", wireType) - } - m.Timeout = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Timeout |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -16473,7 +18621,7 @@ func (m *StopContainerRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *StopContainerResponse) Unmarshal(dAtA []byte) error { +func (m *ContainerStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -16496,65 +18644,205 @@ func (m *StopContainerResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: StopContainerResponse: wiretype end group for non-group") + return fmt.Errorf("proto: ContainerStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: StopContainerResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ContainerStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) } - if skippy < 0 { + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - if (iNdEx + skippy) > l { + postIndex := iNdEx + intStringLen + if postIndex > l { return io.ErrUnexpectedEOF } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *RemoveContainerRequest) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi + m.Id = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) } - if iNdEx >= l { + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { return io.ErrUnexpectedEOF } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if m.Metadata == nil { + m.Metadata = &ContainerMetadata{} } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: RemoveContainerRequest: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: RemoveContainerRequest: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + if err := m.Metadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) + } + m.State = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.State |= (ContainerState(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CreatedAt", wireType) + } + m.CreatedAt = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.CreatedAt |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field StartedAt", wireType) + } + m.StartedAt = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.StartedAt |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field FinishedAt", wireType) + } + m.FinishedAt = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.FinishedAt |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 7: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ExitCode", wireType) + } + m.ExitCode = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.ExitCode |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 8: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Image == nil { + m.Image = &ImageSpec{} + } + if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 9: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ContainerId", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ImageRef", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -16579,113 +18867,13 @@ func (m *RemoveContainerRequest) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ContainerId = string(dAtA[iNdEx:postIndex]) + m.ImageRef = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthApi - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *RemoveContainerResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: RemoveContainerResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: RemoveContainerResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthApi - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ContainerStateValue) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ContainerStateValue: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ContainerStateValue: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) + case 10: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) } - m.State = 0 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -16695,64 +18883,24 @@ func (m *ContainerStateValue) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.State |= (ContainerState(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ContainerFilter) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { + postIndex := iNdEx + intStringLen + if postIndex > l { return io.ErrUnexpectedEOF } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ContainerFilter: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ContainerFilter: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + m.Reason = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 11: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -16777,11 +18925,11 @@ func (m *ContainerFilter) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Id = string(dAtA[iNdEx:postIndex]) + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 12: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -16805,45 +18953,99 @@ func (m *ContainerFilter) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.State == nil { - m.State = &ContainerStateValue{} - } - if err := m.State.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - var stringLen uint64 + var stringLenmapkey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi } - if iNdEx >= l { - return io.ErrUnexpectedEOF + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Labels == nil { + m.Labels = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Labels[mapkey] = mapvalue + } else { + var mapvalue string + m.Labels[mapkey] = mapvalue } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.PodSandboxId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 4: + case 13: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LabelSelector", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -16907,8 +19109,8 @@ func (m *ContainerFilter) Unmarshal(dAtA []byte) error { } mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - if m.LabelSelector == nil { - m.LabelSelector = make(map[string]string) + if m.Annotations == nil { + m.Annotations = make(map[string]string) } if iNdEx < postIndex { var valuekey uint64 @@ -16951,11 +19153,71 @@ func (m *ContainerFilter) Unmarshal(dAtA []byte) error { } mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) iNdEx = postStringIndexmapvalue - m.LabelSelector[mapkey] = mapvalue + m.Annotations[mapkey] = mapvalue } else { var mapvalue string - m.LabelSelector[mapkey] = mapvalue + m.Annotations[mapkey] = mapvalue + } + iNdEx = postIndex + case 14: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Mounts", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Mounts = append(m.Mounts, &Mount{}) + if err := m.Mounts[len(m.Mounts)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 15: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LogPath", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF } + m.LogPath = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -16978,7 +19240,7 @@ func (m *ContainerFilter) Unmarshal(dAtA []byte) error { } return nil } -func (m *ListContainersRequest) Unmarshal(dAtA []byte) error { +func (m *ContainerStatusResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -17001,15 +19263,15 @@ func (m *ListContainersRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ListContainersRequest: wiretype end group for non-group") + return fmt.Errorf("proto: ContainerStatusResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ListContainersRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ContainerStatusResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Filter", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -17033,10 +19295,10 @@ func (m *ListContainersRequest) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Filter == nil { - m.Filter = &ContainerFilter{} + if m.Status == nil { + m.Status = &ContainerStatus{} } - if err := m.Filter.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -17061,7 +19323,7 @@ func (m *ListContainersRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *Container) Unmarshal(dAtA []byte) error { +func (m *ExecSyncRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -17084,15 +19346,15 @@ func (m *Container) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Container: wiretype end group for non-group") + return fmt.Errorf("proto: ExecSyncRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Container: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ExecSyncRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ContainerId", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -17117,11 +19379,11 @@ func (m *Container) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Id = string(dAtA[iNdEx:postIndex]) + m.ContainerId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Cmd", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -17146,13 +19408,13 @@ func (m *Container) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.PodSandboxId = string(dAtA[iNdEx:postIndex]) + m.Cmd = append(m.Cmd, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Timeout", wireType) } - var msglen int + m.Timeout = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -17162,92 +19424,66 @@ func (m *Container) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + m.Timeout |= (int64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Metadata == nil { - m.Metadata = &ContainerMetadata{} - } - if err := m.Metadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { return err } - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { + if skippy < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - if m.Image == nil { - m.Image = &ImageSpec{} - } - if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ImageRef", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ExecSyncResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi } - postIndex := iNdEx + intStringLen - if postIndex > l { + if iNdEx >= l { return io.ErrUnexpectedEOF } - m.ImageRef = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 6: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExecSyncResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExecSyncResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Stdout", wireType) } - m.State = 0 + var byteLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -17257,35 +19493,28 @@ func (m *Container) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.State |= (ContainerState(b) & 0x7F) << shift + byteLen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - case 7: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field CreatedAt", wireType) + if byteLen < 0 { + return ErrInvalidLengthApi } - m.CreatedAt = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.CreatedAt |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } + postIndex := iNdEx + byteLen + if postIndex > l { + return io.ErrUnexpectedEOF } - case 8: + m.Stdout = append(m.Stdout[:0], dAtA[iNdEx:postIndex]...) + if m.Stdout == nil { + m.Stdout = []byte{} + } + iNdEx = postIndex + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Stderr", wireType) } - var msglen int + var byteLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -17295,34 +19524,28 @@ func (m *Container) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + byteLen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + if byteLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + byteLen if postIndex > l { return io.ErrUnexpectedEOF } - var keykey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } + m.Stderr = append(m.Stderr[:0], dAtA[iNdEx:postIndex]...) + if m.Stderr == nil { + m.Stderr = []byte{} } - var stringLenmapkey uint64 + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ExitCode", wireType) + } + m.ExitCode = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -17332,76 +19555,66 @@ func (m *Container) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift + m.ExitCode |= (int32(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { return ErrInvalidLengthApi } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - if m.Labels == nil { - m.Labels = make(map[string]string) + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ExecRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi } - if iNdEx < postIndex { - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthApi - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - m.Labels[mapkey] = mapvalue - } else { - var mapvalue string - m.Labels[mapkey] = mapvalue + if iNdEx >= l { + return io.ErrUnexpectedEOF } - iNdEx = postIndex - case 9: + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExecRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExecRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ContainerId", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -17411,19 +19624,26 @@ func (m *Container) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - var keykey uint64 + m.ContainerId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Cmd", wireType) + } + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -17433,12 +19653,26 @@ func (m *Container) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - var stringLenmapkey uint64 + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Cmd = append(m.Cmd, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Tty", wireType) + } + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -17448,71 +19682,32 @@ func (m *Container) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift + v |= (int(b) & 0x7F) << shift if b < 0x80 { break } - } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { - return ErrInvalidLengthApi - } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { - return io.ErrUnexpectedEOF - } - mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - if m.Annotations == nil { - m.Annotations = make(map[string]string) - } - if iNdEx < postIndex { - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthApi + } + m.Tty = bool(v != 0) + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Stdin", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { + if iNdEx >= l { return io.ErrUnexpectedEOF } - mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - m.Annotations[mapkey] = mapvalue - } else { - var mapvalue string - m.Annotations[mapkey] = mapvalue + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - iNdEx = postIndex + m.Stdin = bool(v != 0) default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -17534,7 +19729,7 @@ func (m *Container) Unmarshal(dAtA []byte) error { } return nil } -func (m *ListContainersResponse) Unmarshal(dAtA []byte) error { +func (m *ExecResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -17557,17 +19752,17 @@ func (m *ListContainersResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ListContainersResponse: wiretype end group for non-group") + return fmt.Errorf("proto: ExecResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ListContainersResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ExecResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Containers", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Url", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -17577,22 +19772,20 @@ func (m *ListContainersResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - m.Containers = append(m.Containers, &Container{}) - if err := m.Containers[len(m.Containers)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Url = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -17615,7 +19808,7 @@ func (m *ListContainersResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *ContainerStatusRequest) Unmarshal(dAtA []byte) error { +func (m *AttachRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -17638,10 +19831,10 @@ func (m *ContainerStatusRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ContainerStatusRequest: wiretype end group for non-group") + return fmt.Errorf("proto: AttachRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ContainerStatusRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: AttachRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -17673,6 +19866,46 @@ func (m *ContainerStatusRequest) Unmarshal(dAtA []byte) error { } m.ContainerId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Stdin", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Stdin = bool(v != 0) + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Tty", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Tty = bool(v != 0) default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -17694,7 +19927,7 @@ func (m *ContainerStatusRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *ContainerStatus) Unmarshal(dAtA []byte) error { +func (m *AttachResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -17717,15 +19950,15 @@ func (m *ContainerStatus) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ContainerStatus: wiretype end group for non-group") + return fmt.Errorf("proto: AttachResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ContainerStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: AttachResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Url", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -17750,122 +19983,63 @@ func (m *ContainerStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Id = string(dAtA[iNdEx:postIndex]) + m.Url = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err } - if msglen < 0 { + if skippy < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - if m.Metadata == nil { - m.Metadata = &ContainerMetadata{} - } - if err := m.Metadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field State", wireType) - } - m.State = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.State |= (ContainerState(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field CreatedAt", wireType) - } - m.CreatedAt = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.CreatedAt |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 5: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field StartedAt", wireType) - } - m.StartedAt = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.StartedAt |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PortForwardRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi } - case 6: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field FinishedAt", wireType) + if iNdEx >= l { + return io.ErrUnexpectedEOF } - m.FinishedAt = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.FinishedAt |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break } - case 7: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ExitCode", wireType) + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PortForwardRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PortForwardRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) } - m.ExitCode = 0 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -17875,47 +20049,136 @@ func (m *ContainerStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.ExitCode |= (int32(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - case 8: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.PodSandboxId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType == 0 { + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { + m.Port = append(m.Port, v) + } else if wireType == 2 { + var packedLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + packedLen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if packedLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + packedLen + if postIndex > l { return io.ErrUnexpectedEOF } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + for iNdEx < postIndex { + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Port = append(m.Port, v) } + } else { + return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType) } - if msglen < 0 { + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - if m.Image == nil { - m.Image = &ImageSpec{} + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PortForwardResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi } - if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + if iNdEx >= l { + return io.ErrUnexpectedEOF } - iNdEx = postIndex - case 9: + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PortForwardResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PortForwardResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ImageRef", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Url", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -17940,13 +20203,63 @@ func (m *ContainerStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ImageRef = string(dAtA[iNdEx:postIndex]) + m.Url = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 10: + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ImageFilter) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ImageFilter: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ImageFilter: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -17956,53 +20269,78 @@ func (m *ContainerStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 11: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) + if m.Image == nil { + m.Image = &ImageSpec{} } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } + if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - intStringLen := int(stringLen) - if intStringLen < 0 { + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen - if postIndex > l { + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ListImagesRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { return io.ErrUnexpectedEOF } - m.Message = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 12: + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ListImagesRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ListImagesRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Filter", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -18026,101 +20364,68 @@ func (m *ContainerStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - var keykey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } + if m.Filter == nil { + m.Filter = &ImageFilter{} } - var stringLenmapkey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } + if err := m.Filter.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { return ErrInvalidLengthApi } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - if m.Labels == nil { - m.Labels = make(map[string]string) + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Image) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi } - if iNdEx < postIndex { - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthApi - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - m.Labels[mapkey] = mapvalue - } else { - var mapvalue string - m.Labels[mapkey] = mapvalue + if iNdEx >= l { + return io.ErrUnexpectedEOF } - iNdEx = postIndex - case 13: + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Image: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Image: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -18130,19 +20435,26 @@ func (m *ContainerStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - var keykey uint64 + m.Id = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RepoTags", wireType) + } + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -18152,12 +20464,26 @@ func (m *ContainerStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - var stringLenmapkey uint64 + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.RepoTags = append(m.RepoTags, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RepoDigests", wireType) + } + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -18167,74 +20493,43 @@ func (m *ContainerStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { + postIndex := iNdEx + intStringLen + if postIndex > l { return io.ErrUnexpectedEOF } - mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - if m.Annotations == nil { - m.Annotations = make(map[string]string) + m.RepoDigests = append(m.RepoDigests, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Size_", wireType) } - if iNdEx < postIndex { - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthApi + m.Size_ = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { + if iNdEx >= l { return io.ErrUnexpectedEOF } - mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - m.Annotations[mapkey] = mapvalue - } else { - var mapvalue string - m.Annotations[mapkey] = mapvalue + b := dAtA[iNdEx] + iNdEx++ + m.Size_ |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - iNdEx = postIndex - case 14: + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Mounts", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -18258,14 +20553,16 @@ func (m *ContainerStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Mounts = append(m.Mounts, &Mount{}) - if err := m.Mounts[len(m.Mounts)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.Uid == nil { + m.Uid = &Int64Value{} + } + if err := m.Uid.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 15: + case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LogPath", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Username", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -18290,7 +20587,7 @@ func (m *ContainerStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.LogPath = string(dAtA[iNdEx:postIndex]) + m.Username = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -18313,7 +20610,7 @@ func (m *ContainerStatus) Unmarshal(dAtA []byte) error { } return nil } -func (m *ContainerStatusResponse) Unmarshal(dAtA []byte) error { +func (m *ListImagesResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -18336,15 +20633,15 @@ func (m *ContainerStatusResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ContainerStatusResponse: wiretype end group for non-group") + return fmt.Errorf("proto: ListImagesResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ContainerStatusResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ListImagesResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Images", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -18368,10 +20665,8 @@ func (m *ContainerStatusResponse) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Status == nil { - m.Status = &ContainerStatus{} - } - if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Images = append(m.Images, &Image{}) + if err := m.Images[len(m.Images)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -18396,7 +20691,7 @@ func (m *ContainerStatusResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *ExecSyncRequest) Unmarshal(dAtA []byte) error { +func (m *ImageStatusRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -18419,17 +20714,17 @@ func (m *ExecSyncRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ExecSyncRequest: wiretype end group for non-group") + return fmt.Errorf("proto: ImageStatusRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ExecSyncRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ImageStatusRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ContainerId", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -18439,69 +20734,25 @@ func (m *ExecSyncRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.ContainerId = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Cmd", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi + if m.Image == nil { + m.Image = &ImageSpec{} } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF + if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - m.Cmd = append(m.Cmd, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Timeout", wireType) - } - m.Timeout = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Timeout |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -18523,7 +20774,7 @@ func (m *ExecSyncRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *ExecSyncResponse) Unmarshal(dAtA []byte) error { +func (m *ImageStatusResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -18546,17 +20797,17 @@ func (m *ExecSyncResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ExecSyncResponse: wiretype end group for non-group") + return fmt.Errorf("proto: ImageStatusResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ExecSyncResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ImageStatusResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Stdout", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) } - var byteLen int + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -18566,73 +20817,25 @@ func (m *ExecSyncResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - byteLen |= (int(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - if byteLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + byteLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Stdout = append(m.Stdout[:0], dAtA[iNdEx:postIndex]...) - if m.Stdout == nil { - m.Stdout = []byte{} - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Stderr", wireType) - } - var byteLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - byteLen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if byteLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + byteLen - if postIndex > l { - return io.ErrUnexpectedEOF + if m.Image == nil { + m.Image = &Image{} } - m.Stderr = append(m.Stderr[:0], dAtA[iNdEx:postIndex]...) - if m.Stderr == nil { - m.Stderr = []byte{} + if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ExitCode", wireType) - } - m.ExitCode = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.ExitCode |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -18654,7 +20857,7 @@ func (m *ExecSyncResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *ExecRequest) Unmarshal(dAtA []byte) error { +func (m *AuthConfig) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -18677,15 +20880,15 @@ func (m *ExecRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ExecRequest: wiretype end group for non-group") + return fmt.Errorf("proto: AuthConfig: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ExecRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: AuthConfig: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ContainerId", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Username", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -18710,11 +20913,11 @@ func (m *ExecRequest) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ContainerId = string(dAtA[iNdEx:postIndex]) + m.Username = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Cmd", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Password", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -18739,13 +20942,13 @@ func (m *ExecRequest) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Cmd = append(m.Cmd, string(dAtA[iNdEx:postIndex])) + m.Password = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Tty", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Auth", wireType) } - var v int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -18755,17 +20958,26 @@ func (m *ExecRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.Tty = bool(v != 0) + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Auth = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Stdin", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ServerAddress", wireType) } - var v int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -18775,65 +20987,53 @@ func (m *ExecRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.Stdin = bool(v != 0) - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ServerAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field IdentityToken", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if skippy < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ExecResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { + postIndex := iNdEx + intStringLen + if postIndex > l { return io.ErrUnexpectedEOF } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ExecResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ExecResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + m.IdentityToken = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Url", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field RegistryToken", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -18858,7 +21058,7 @@ func (m *ExecResponse) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Url = string(dAtA[iNdEx:postIndex]) + m.RegistryToken = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -18881,7 +21081,7 @@ func (m *ExecResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *AttachRequest) Unmarshal(dAtA []byte) error { +func (m *PullImageRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -18904,17 +21104,17 @@ func (m *AttachRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: AttachRequest: wiretype end group for non-group") + return fmt.Errorf("proto: PullImageRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: AttachRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PullImageRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ContainerId", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -18924,26 +21124,30 @@ func (m *AttachRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.ContainerId = string(dAtA[iNdEx:postIndex]) + if m.Image == nil { + m.Image = &ImageSpec{} + } + if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Stdin", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Auth", wireType) } - var v int + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -18953,17 +21157,30 @@ func (m *AttachRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.Stdin = bool(v != 0) + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Auth == nil { + m.Auth = &AuthConfig{} + } + if err := m.Auth.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Tty", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SandboxConfig", wireType) } - var v int + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -18973,12 +21190,25 @@ func (m *AttachRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.Tty = bool(v != 0) + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.SandboxConfig == nil { + m.SandboxConfig = &PodSandboxConfig{} + } + if err := m.SandboxConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -19000,7 +21230,7 @@ func (m *AttachRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *AttachResponse) Unmarshal(dAtA []byte) error { +func (m *PullImageResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -19023,15 +21253,15 @@ func (m *AttachResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: AttachResponse: wiretype end group for non-group") + return fmt.Errorf("proto: PullImageResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: AttachResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PullImageResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Url", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ImageRef", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -19056,7 +21286,7 @@ func (m *AttachResponse) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Url = string(dAtA[iNdEx:postIndex]) + m.ImageRef = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -19079,7 +21309,7 @@ func (m *AttachResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *PortForwardRequest) Unmarshal(dAtA []byte) error { +func (m *RemoveImageRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -19102,17 +21332,17 @@ func (m *PortForwardRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PortForwardRequest: wiretype end group for non-group") + return fmt.Errorf("proto: RemoveImageRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PortForwardRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RemoveImageRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -19122,83 +21352,75 @@ func (m *PortForwardRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.PodSandboxId = string(dAtA[iNdEx:postIndex]) + if m.Image == nil { + m.Image = &ImageSpec{} + } + if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 2: - if wireType == 0 { - var v int32 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.Port = append(m.Port, v) - } else if wireType == 2 { - var packedLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - packedLen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if packedLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + packedLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - for iNdEx < postIndex { - var v int32 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.Port = append(m.Port, v) - } - } else { - return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType) + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthApi + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RemoveImageResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RemoveImageResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RemoveImageResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -19220,7 +21442,7 @@ func (m *PortForwardRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *PortForwardResponse) Unmarshal(dAtA []byte) error { +func (m *NetworkConfig) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -19243,15 +21465,15 @@ func (m *PortForwardResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PortForwardResponse: wiretype end group for non-group") + return fmt.Errorf("proto: NetworkConfig: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PortForwardResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: NetworkConfig: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Url", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PodCidr", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -19276,7 +21498,7 @@ func (m *PortForwardResponse) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Url = string(dAtA[iNdEx:postIndex]) + m.PodCidr = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -19299,7 +21521,7 @@ func (m *PortForwardResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *ImageFilter) Unmarshal(dAtA []byte) error { +func (m *RuntimeConfig) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -19322,15 +21544,15 @@ func (m *ImageFilter) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ImageFilter: wiretype end group for non-group") + return fmt.Errorf("proto: RuntimeConfig: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ImageFilter: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RuntimeConfig: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field NetworkConfig", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -19354,10 +21576,10 @@ func (m *ImageFilter) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Image == nil { - m.Image = &ImageSpec{} + if m.NetworkConfig == nil { + m.NetworkConfig = &NetworkConfig{} } - if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.NetworkConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -19382,7 +21604,7 @@ func (m *ImageFilter) Unmarshal(dAtA []byte) error { } return nil } -func (m *ListImagesRequest) Unmarshal(dAtA []byte) error { +func (m *UpdateRuntimeConfigRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -19405,15 +21627,15 @@ func (m *ListImagesRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ListImagesRequest: wiretype end group for non-group") + return fmt.Errorf("proto: UpdateRuntimeConfigRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ListImagesRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: UpdateRuntimeConfigRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Filter", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field RuntimeConfig", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -19437,10 +21659,10 @@ func (m *ListImagesRequest) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Filter == nil { - m.Filter = &ImageFilter{} + if m.RuntimeConfig == nil { + m.RuntimeConfig = &RuntimeConfig{} } - if err := m.Filter.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.RuntimeConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -19465,7 +21687,7 @@ func (m *ListImagesRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *Image) Unmarshal(dAtA []byte) error { +func (m *UpdateRuntimeConfigResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -19488,73 +21710,65 @@ func (m *Image) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Image: wiretype end group for non-group") + return fmt.Errorf("proto: UpdateRuntimeConfigResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Image: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: UpdateRuntimeConfigResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err } - intStringLen := int(stringLen) - if intStringLen < 0 { + if skippy < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - m.Id = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field RepoTags", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RuntimeCondition) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi } - postIndex := iNdEx + intStringLen - if postIndex > l { + if iNdEx >= l { return io.ErrUnexpectedEOF } - m.RepoTags = append(m.RepoTags, string(dAtA[iNdEx:postIndex])) - iNdEx = postIndex - case 3: + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RuntimeCondition: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RuntimeCondition: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field RepoDigests", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -19579,32 +21793,13 @@ func (m *Image) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.RepoDigests = append(m.RepoDigests, string(dAtA[iNdEx:postIndex])) + m.Type = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 4: + case 2: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Size_", wireType) - } - m.Size_ = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Size_ |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) } - var msglen int + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -19614,28 +21809,15 @@ func (m *Image) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + v |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Uid == nil { - m.Uid = &Int64Value{} - } - if err := m.Uid.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 6: + m.Status = bool(v != 0) + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Username", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -19657,66 +21839,16 @@ func (m *Image) Unmarshal(dAtA []byte) error { return ErrInvalidLengthApi } postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Username = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthApi - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ListImagesResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ListImagesResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ListImagesResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Reason = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Images", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -19726,22 +21858,20 @@ func (m *ListImagesResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - m.Images = append(m.Images, &Image{}) - if err := m.Images[len(m.Images)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -19764,7 +21894,7 @@ func (m *ListImagesResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *ImageStatusRequest) Unmarshal(dAtA []byte) error { +func (m *RuntimeStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -19787,15 +21917,15 @@ func (m *ImageStatusRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ImageStatusRequest: wiretype end group for non-group") + return fmt.Errorf("proto: RuntimeStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ImageStatusRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RuntimeStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Conditions", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -19819,10 +21949,8 @@ func (m *ImageStatusRequest) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Image == nil { - m.Image = &ImageSpec{} - } - if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Conditions = append(m.Conditions, &RuntimeCondition{}) + if err := m.Conditions[len(m.Conditions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -19847,7 +21975,7 @@ func (m *ImageStatusRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *ImageStatusResponse) Unmarshal(dAtA []byte) error { +func (m *StatusRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -19870,45 +21998,12 @@ func (m *ImageStatusResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ImageStatusResponse: wiretype end group for non-group") + return fmt.Errorf("proto: StatusRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ImageStatusResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: StatusRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Image == nil { - m.Image = &Image{} - } - if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -19930,7 +22025,7 @@ func (m *ImageStatusResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *AuthConfig) Unmarshal(dAtA []byte) error { +func (m *StatusResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -19953,75 +22048,17 @@ func (m *AuthConfig) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: AuthConfig: wiretype end group for non-group") + return fmt.Errorf("proto: StatusResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: AuthConfig: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: StatusResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Username", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Username = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Password", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Password = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Auth", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -20031,108 +22068,75 @@ func (m *AuthConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Auth = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ServerAddress", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi + if m.Status == nil { + m.Status = &RuntimeStatus{} } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - m.ServerAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field IdentityToken", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err } - intStringLen := int(stringLen) - if intStringLen < 0 { + if skippy < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - m.IdentityToken = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 6: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field RegistryToken", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + intStringLen - if postIndex > l { + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ImageFsInfoRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { return io.ErrUnexpectedEOF } - m.RegistryToken = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ImageFsInfoRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ImageFsInfoRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -20154,7 +22158,7 @@ func (m *AuthConfig) Unmarshal(dAtA []byte) error { } return nil } -func (m *PullImageRequest) Unmarshal(dAtA []byte) error { +func (m *UInt64Value) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -20177,83 +22181,17 @@ func (m *PullImageRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PullImageRequest: wiretype end group for non-group") + return fmt.Errorf("proto: UInt64Value: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PullImageRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: UInt64Value: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Image == nil { - m.Image = &ImageSpec{} - } - if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Auth", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Auth == nil { - m.Auth = &AuthConfig{} - } - if err := m.Auth.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SandboxConfig", wireType) + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) } - var msglen int + m.Value = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -20263,25 +22201,11 @@ func (m *PullImageRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + m.Value |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.SandboxConfig == nil { - m.SandboxConfig = &PodSandboxConfig{} - } - if err := m.SandboxConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -20303,7 +22227,7 @@ func (m *PullImageRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *PullImageResponse) Unmarshal(dAtA []byte) error { +func (m *StorageIdentifier) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -20326,15 +22250,15 @@ func (m *PullImageResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PullImageResponse: wiretype end group for non-group") + return fmt.Errorf("proto: StorageIdentifier: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PullImageResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: StorageIdentifier: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ImageRef", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Uuid", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -20359,7 +22283,7 @@ func (m *PullImageResponse) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ImageRef = string(dAtA[iNdEx:postIndex]) + m.Uuid = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -20382,7 +22306,7 @@ func (m *PullImageResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *RemoveImageRequest) Unmarshal(dAtA []byte) error { +func (m *FilesystemUsage) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -20405,15 +22329,34 @@ func (m *RemoveImageRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RemoveImageRequest: wiretype end group for non-group") + return fmt.Errorf("proto: FilesystemUsage: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RemoveImageRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: FilesystemUsage: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Timestamp", wireType) + } + m.Timestamp = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Timestamp |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field StorageId", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -20437,63 +22380,79 @@ func (m *RemoveImageRequest) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Image == nil { - m.Image = &ImageSpec{} + if m.StorageId == nil { + m.StorageId = &StorageIdentifier{} } - if err := m.Image.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.StorageId.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field UsedBytes", wireType) } - if skippy < 0 { + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { return ErrInvalidLengthApi } - if (iNdEx + skippy) > l { + postIndex := iNdEx + msglen + if postIndex > l { return io.ErrUnexpectedEOF } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *RemoveImageResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi + if m.UsedBytes == nil { + m.UsedBytes = &UInt64Value{} } - if iNdEx >= l { + if err := m.UsedBytes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field InodesUsed", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { return io.ErrUnexpectedEOF } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if m.InodesUsed == nil { + m.InodesUsed = &UInt64Value{} } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: RemoveImageResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: RemoveImageResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { + if err := m.InodesUsed.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -20515,7 +22474,7 @@ func (m *RemoveImageResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *NetworkConfig) Unmarshal(dAtA []byte) error { +func (m *ImageFsInfoResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -20538,17 +22497,17 @@ func (m *NetworkConfig) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: NetworkConfig: wiretype end group for non-group") + return fmt.Errorf("proto: ImageFsInfoResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: NetworkConfig: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ImageFsInfoResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PodCidr", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ImageFilesystems", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -20558,20 +22517,22 @@ func (m *NetworkConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.PodCidr = string(dAtA[iNdEx:postIndex]) + m.ImageFilesystems = append(m.ImageFilesystems, &FilesystemUsage{}) + if err := m.ImageFilesystems[len(m.ImageFilesystems)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex @@ -20594,7 +22555,7 @@ func (m *NetworkConfig) Unmarshal(dAtA []byte) error { } return nil } -func (m *RuntimeConfig) Unmarshal(dAtA []byte) error { +func (m *ContainerStatsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -20617,17 +22578,17 @@ func (m *RuntimeConfig) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RuntimeConfig: wiretype end group for non-group") + return fmt.Errorf("proto: ContainerStatsRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RuntimeConfig: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ContainerStatsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field NetworkConfig", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ContainerId", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -20637,24 +22598,20 @@ func (m *RuntimeConfig) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if m.NetworkConfig == nil { - m.NetworkConfig = &NetworkConfig{} - } - if err := m.NetworkConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.ContainerId = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -20677,7 +22634,7 @@ func (m *RuntimeConfig) Unmarshal(dAtA []byte) error { } return nil } -func (m *UpdateRuntimeConfigRequest) Unmarshal(dAtA []byte) error { +func (m *ContainerStatsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -20700,15 +22657,15 @@ func (m *UpdateRuntimeConfigRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: UpdateRuntimeConfigRequest: wiretype end group for non-group") + return fmt.Errorf("proto: ContainerStatsResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: UpdateRuntimeConfigRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ContainerStatsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field RuntimeConfig", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Stats", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -20732,10 +22689,10 @@ func (m *UpdateRuntimeConfigRequest) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.RuntimeConfig == nil { - m.RuntimeConfig = &RuntimeConfig{} + if m.Stats == nil { + m.Stats = &ContainerStats{} } - if err := m.RuntimeConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Stats.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -20760,7 +22717,7 @@ func (m *UpdateRuntimeConfigRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *UpdateRuntimeConfigResponse) Unmarshal(dAtA []byte) error { +func (m *ListContainerStatsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -20783,12 +22740,45 @@ func (m *UpdateRuntimeConfigResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: UpdateRuntimeConfigResponse: wiretype end group for non-group") + return fmt.Errorf("proto: ListContainerStatsRequest: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: UpdateRuntimeConfigResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ListContainerStatsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Filter", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Filter == nil { + m.Filter = &ContainerStatsFilter{} + } + if err := m.Filter.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -20810,7 +22800,7 @@ func (m *UpdateRuntimeConfigResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *RuntimeCondition) Unmarshal(dAtA []byte) error { +func (m *ContainerStatsFilter) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -20833,15 +22823,15 @@ func (m *RuntimeCondition) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RuntimeCondition: wiretype end group for non-group") + return fmt.Errorf("proto: ContainerStatsFilter: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RuntimeCondition: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ContainerStatsFilter: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -20866,13 +22856,13 @@ func (m *RuntimeCondition) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = string(dAtA[iNdEx:postIndex]) + m.Id = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PodSandboxId", wireType) } - var v int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -20882,17 +22872,26 @@ func (m *RuntimeCondition) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.Status = bool(v != 0) + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.PodSandboxId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field LabelSelector", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -20902,26 +22901,19 @@ func (m *RuntimeCondition) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) - } - var stringLen uint64 + var keykey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -20931,76 +22923,12 @@ func (m *RuntimeCondition) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Message = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthApi - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *RuntimeStatus) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: RuntimeStatus: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: RuntimeStatus: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Conditions", wireType) - } - var msglen int + var stringLenmapkey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -21010,73 +22938,71 @@ func (m *RuntimeStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Conditions = append(m.Conditions, &RuntimeCondition{}) - if err := m.Conditions[len(m.Conditions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthApi } - if (iNdEx + skippy) > l { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *StatusRequest) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.LabelSelector == nil { + m.LabelSelector = make(map[string]string) } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.LabelSelector[mapkey] = mapvalue + } else { + var mapvalue string + m.LabelSelector[mapkey] = mapvalue } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: StatusRequest: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: StatusRequest: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -21098,7 +23024,7 @@ func (m *StatusRequest) Unmarshal(dAtA []byte) error { } return nil } -func (m *StatusResponse) Unmarshal(dAtA []byte) error { +func (m *ListContainerStatsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -21121,15 +23047,15 @@ func (m *StatusResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: StatusResponse: wiretype end group for non-group") + return fmt.Errorf("proto: ListContainerStatsResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: StatusResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ListContainerStatsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Stats", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -21153,10 +23079,8 @@ func (m *StatusResponse) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Status == nil { - m.Status = &RuntimeStatus{} - } - if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Stats = append(m.Stats, &ContainerStats{}) + if err := m.Stats[len(m.Stats)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -21181,7 +23105,7 @@ func (m *StatusResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *ImageFsInfoRequest) Unmarshal(dAtA []byte) error { +func (m *ContainerAttributes) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -21204,67 +23128,232 @@ func (m *ImageFsInfoRequest) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ImageFsInfoRequest: wiretype end group for non-group") + return fmt.Errorf("proto: ContainerAttributes: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ImageFsInfoRequest: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ContainerAttributes: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { - default: - iNdEx = preIndex - skippy, err := skipApi(dAtA[iNdEx:]) - if err != nil { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Id = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthApi + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Metadata == nil { + m.Metadata = &ContainerMetadata{} + } + if err := m.Metadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } - if skippy < 0 { + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { return ErrInvalidLengthApi } - if (iNdEx + skippy) > l { + postIndex := iNdEx + msglen + if postIndex > l { return io.ErrUnexpectedEOF } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *UInt64Value) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Labels == nil { + m.Labels = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Labels[mapkey] = mapvalue + } else { + var mapvalue string + m.Labels[mapkey] = mapvalue + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + if msglen < 0 { + return ErrInvalidLengthApi } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: UInt64Value: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: UInt64Value: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - m.Value = 0 + var stringLenmapkey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -21274,11 +23363,71 @@ func (m *UInt64Value) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.Value |= (uint64(b) & 0x7F) << shift + stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Annotations == nil { + m.Annotations = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthApi + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Annotations[mapkey] = mapvalue + } else { + var mapvalue string + m.Annotations[mapkey] = mapvalue + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipApi(dAtA[iNdEx:]) @@ -21300,7 +23449,7 @@ func (m *UInt64Value) Unmarshal(dAtA []byte) error { } return nil } -func (m *FsInfo) Unmarshal(dAtA []byte) error { +func (m *ContainerStats) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -21323,17 +23472,17 @@ func (m *FsInfo) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: FsInfo: wiretype end group for non-group") + return fmt.Errorf("proto: ContainerStats: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: FsInfo: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ContainerStats: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Device", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Attributes", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -21343,53 +23492,28 @@ func (m *FsInfo) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Device = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthApi + if m.Attributes == nil { + m.Attributes = &ContainerAttributes{} } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF + if err := m.Attributes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 3: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field CapacityBytes", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Cpu", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -21413,16 +23537,16 @@ func (m *FsInfo) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.CapacityBytes == nil { - m.CapacityBytes = &UInt64Value{} + if m.Cpu == nil { + m.Cpu = &CpuUsage{} } - if err := m.CapacityBytes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Cpu.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 4: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field AvailableBytes", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Memory", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -21446,16 +23570,16 @@ func (m *FsInfo) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.AvailableBytes == nil { - m.AvailableBytes = &UInt64Value{} + if m.Memory == nil { + m.Memory = &MemoryUsage{} } - if err := m.AvailableBytes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Memory.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 5: + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field UsedBytes", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field WritableLayer", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -21479,51 +23603,68 @@ func (m *FsInfo) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.UsedBytes == nil { - m.UsedBytes = &UInt64Value{} + if m.WritableLayer == nil { + m.WritableLayer = &FilesystemUsage{} } - if err := m.UsedBytes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.WritableLayer.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 6: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field InodesCapacity", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowApi - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } + default: + iNdEx = preIndex + skippy, err := skipApi(dAtA[iNdEx:]) + if err != nil { + return err } - if msglen < 0 { + if skippy < 0 { return ErrInvalidLengthApi } - postIndex := iNdEx + msglen - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - if m.InodesCapacity == nil { - m.InodesCapacity = &UInt64Value{} + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *CpuUsage) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF } - if err := m.InodesCapacity.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break } - iNdEx = postIndex - case 7: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field InodesAvailable", wireType) + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: CpuUsage: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: CpuUsage: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Timestamp", wireType) } - var msglen int + m.Timestamp = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowApi @@ -21533,28 +23674,14 @@ func (m *FsInfo) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + m.Timestamp |= (int64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthApi - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.InodesAvailable == nil { - m.InodesAvailable = &UInt64Value{} - } - if err := m.InodesAvailable.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 8: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field InodesUsed", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field UsageCoreNanoSeconds", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -21578,10 +23705,10 @@ func (m *FsInfo) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.InodesUsed == nil { - m.InodesUsed = &UInt64Value{} + if m.UsageCoreNanoSeconds == nil { + m.UsageCoreNanoSeconds = &UInt64Value{} } - if err := m.InodesUsed.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.UsageCoreNanoSeconds.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -21606,7 +23733,7 @@ func (m *FsInfo) Unmarshal(dAtA []byte) error { } return nil } -func (m *ImageFsInfoResponse) Unmarshal(dAtA []byte) error { +func (m *MemoryUsage) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -21629,15 +23756,34 @@ func (m *ImageFsInfoResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ImageFsInfoResponse: wiretype end group for non-group") + return fmt.Errorf("proto: MemoryUsage: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ImageFsInfoResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: MemoryUsage: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Timestamp", wireType) + } + m.Timestamp = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowApi + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Timestamp |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field FsInfo", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field WorkingSetBytes", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -21661,10 +23807,10 @@ func (m *ImageFsInfoResponse) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.FsInfo == nil { - m.FsInfo = &FsInfo{} + if m.WorkingSetBytes == nil { + m.WorkingSetBytes = &UInt64Value{} } - if err := m.FsInfo.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.WorkingSetBytes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -21797,242 +23943,259 @@ var ( func init() { proto.RegisterFile("api.proto", fileDescriptorApi) } var fileDescriptorApi = []byte{ - // 3782 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x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0xd3, 0x36, 0x70, 0x78, 0x4e, 0x4a, 0x67, 0x3b, 0x27, - 0xe5, 0xd8, 0x39, 0x99, 0x87, 0xa2, 0x8b, 0x75, 0xcf, 0xb6, 0x9a, 0xc0, 0x7e, 0x51, 0x66, 0x23, - 0x72, 0x71, 0x0c, 0xb0, 0xe7, 0x91, 0x15, 0x78, 0x42, 0xc3, 0x87, 0x52, 0xe2, 0x35, 0x95, 0x99, - 0x78, 0x8d, 0xe8, 0x61, 0xc6, 0x12, 0xaf, 0x6a, 0x66, 0xe2, 0x75, 0x9a, 0x16, 0xa6, 0x94, 0x5a, - 0xd6, 0x46, 0xa7, 0x96, 0x72, 0x86, 0x56, 0x8f, 0x64, 0x68, 0x3f, 0xe6, 0xd1, 0x7a, 0x0c, 0x0b, - 0x89, 0xb3, 0xc0, 0xcf, 0xd6, 0xb5, 0x58, 0x17, 0x74, 0x31, 0x53, 0x45, 0x41, 0x13, 0xf4, 0xdf, - 0xa1, 0xbe, 0xfd, 0x12, 0x77, 0x3b, 0x27, 0x56, 0xf7, 0x0c, 0x29, 0x42, 0x03, 0x0a, 0xdd, 0x81, - 0xc1, 0xab, 0x7e, 0xf2, 0x29, 0x27, 0x0d, 0x85, 0x68, 0xd2, 0xa0, 0x41, 0x23, 0x5c, 0x81, 0x0b, - 0x3a, 0x4f, 0x04, 0x35, 0x08, 0x32, 0x61, 0x3e, 0xa5, 0xf2, 0x11, 0x87, 0x63, 0xd7, 0xa5, 0xdb, - 0x66, 0x70, 0xec, 0xba, 0x51, 0xb7, 0x2e, 0x44, 0xdd, 0x5a, 0x79, 0x0e, 0x15, 0xb2, 0xc0, 0xf7, - 0x12, 0x9f, 0x27, 0xcf, 0x85, 0x30, 0x79, 0x0e, 0x72, 0xf0, 0x71, 0x29, 0x07, 0x57, 0x56, 0x60, - 0x8a, 0xad, 0xc5, 0x37, 0xd2, 0x80, 0xc2, 0xd0, 0xed, 0x0b, 0xc3, 0x0d, 0xdd, 0xbe, 0xf2, 0xa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c, 0x9c, 0xef, 0x00, 0x84, 0xc5, 0x19, 0x5a, 0x8a, 0x3a, 0x53, 0xa4, 0x50, 0x6d, - 0x9d, 0x4b, 0x9f, 0x94, 0xd5, 0x29, 0xd5, 0x59, 0xb2, 0x3a, 0x93, 0xf5, 0x9b, 0xac, 0xce, 0x94, - 0xe2, 0x4c, 0x19, 0x43, 0x0f, 0xa0, 0x1c, 0xa4, 0xfe, 0x48, 0x2e, 0x19, 0x62, 0xb5, 0x4b, 0x6b, - 0x29, 0x75, 0x4e, 0x96, 0x4a, 0xca, 0xe7, 0x65, 0xa9, 0x92, 0x75, 0x82, 0x2c, 0x55, 0x5a, 0x11, - 0x10, 0xee, 0x91, 0xa7, 0x70, 0xf1, 0x3d, 0x46, 0x12, 0xc2, 0xc4, 0x1e, 0xa3, 0xe9, 0x84, 0x32, - 0x76, 0xff, 0xdc, 0xb7, 0xdf, 0x2d, 0xe7, 0xfe, 0xf0, 0xdd, 0xf2, 0xd8, 0x7f, 0xbe, 0x5a, 0xce, - 0x7d, 0xfb, 0x6a, 0x39, 0xf7, 0xbb, 0x57, 0xcb, 0xb9, 0x3f, 0xbe, 0x5a, 0xce, 0x7d, 0xfd, 0xa7, - 0xe5, 0xb1, 0x83, 0x22, 0xfd, 0xf7, 0x98, 0xeb, 0x7f, 0x0d, 0x00, 0x00, 0xff, 0xff, 0x1f, 0x28, - 0x3f, 0xad, 0xd4, 0x34, 0x00, 0x00, + // 4063 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x3b, 0x4d, 0x6f, 0x1c, 0x47, + 0x76, 0x9c, 0x19, 0x7e, 0xcc, 0xbc, 0xe1, 0x7c, 0xb0, 0x48, 0x8a, 0xc3, 0x91, 0x44, 0x49, 0x6d, + 0xcb, 0xb2, 0xb4, 0x31, 0x15, 0x51, 0x8e, 0xad, 0x68, 0x57, 0xb6, 0xc6, 0x24, 0xe5, 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e, 0x23, 0x98, 0x15, 0xaf, 0x4c, 0x2a, 0xef, 0xcf, + 0xe9, 0xec, 0x5b, 0xbb, 0x03, 0xcb, 0x09, 0x7e, 0x85, 0x03, 0x3f, 0x82, 0x3a, 0x73, 0x23, 0x22, + 0xbe, 0xba, 0xab, 0x96, 0xf6, 0xa6, 0x3a, 0x1b, 0xed, 0x33, 0x58, 0xa2, 0x87, 0x05, 0x83, 0x47, + 0x8e, 0xfd, 0x83, 0x54, 0x10, 0xb2, 0x9a, 0x62, 0x90, 0x0a, 0x40, 0xfe, 0xb1, 0x04, 0x73, 0x0c, + 0x9e, 0x71, 0xed, 0x57, 0xa1, 0xe6, 0x63, 0xcf, 0x35, 0x88, 0x39, 0x8c, 0xde, 0xee, 0x50, 0xc0, + 0x4b, 0x73, 0x18, 0xb0, 0xa7, 0x47, 0xb4, 0xd3, 0xb2, 0x87, 0x38, 0x20, 0xf2, 0x01, 0x4f, 0x9d, + 0xc2, 0x76, 0x38, 0x88, 0x2e, 0x4a, 0x60, 0xff, 0x19, 0x0f, 0x2e, 0x66, 0x75, 0xf6, 0x8d, 0xde, + 0xe3, 0xf7, 0xef, 0xd3, 0x0a, 0x39, 0xec, 0x56, 0xbe, 0x0b, 0xd5, 0x54, 0xed, 0x26, 0x6a, 0x6b, + 0x4f, 0x00, 0xa9, 0xb3, 0x16, 0xeb, 0x7a, 0x07, 0xe6, 0xd9, 0xa2, 0xc8, 0xa3, 0xb1, 0x95, 0x9a, + 0xb6, 0x2e, 0xba, 0xb5, 0x4f, 0x01, 0xf1, 0x85, 0x4c, 0x1c, 0x87, 0x97, 0x58, 0xf5, 0x1f, 0xc0, + 0x72, 0x82, 0x81, 0x10, 0xe0, 0x76, 0x92, 0x43, 0x66, 0x7c, 0x41, 0xfd, 0x6f, 0x25, 0x80, 0x5e, + 0x48, 0x4e, 0x45, 0x25, 0x42, 0x9d, 0x68, 0x29, 0x39, 0x51, 0xda, 0xe7, 0x99, 0x41, 0xf0, 0x8d, + 0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xd2, + 0x52, 0x17, 0x24, 0xff, 0x45, 0x8f, 0x36, 0x83, 0xbe, 0x84, 0x56, 0xea, 0x52, 0x0b, 0x29, 0x64, + 0xf9, 0xb7, 0x74, 0xdd, 0x5b, 0x53, 0x30, 0x92, 0x1a, 0x54, 0x2f, 0xad, 0x92, 0x1a, 0xcc, 0xb9, + 0x0a, 0x4b, 0x6a, 0x30, 0xf7, 0xbe, 0x8b, 0x19, 0x5b, 0xe2, 0x72, 0x4a, 0x35, 0xb6, 0xbc, 0xab, + 0xb0, 0xee, 0x8d, 0xc2, 0x7e, 0x75, 0x11, 0x52, 0x57, 0x53, 0xea, 0x22, 0xe4, 0x5f, 0x79, 0x75, + 0x6f, 0x4d, 0xc1, 0x48, 0x6b, 0x2d, 0x2e, 0x90, 0xa7, 0xb5, 0x96, 0xb9, 0x96, 0x49, 0x6b, 0x2d, + 0x5b, 0x5b, 0x17, 0x5a, 0x4b, 0x95, 0xba, 0x6f, 0x16, 0x17, 0x01, 0x73, 0xb4, 0x96, 0x5f, 0x59, + 0xd4, 0x66, 0xd0, 0x36, 0x54, 0x65, 0x19, 0x0f, 0x29, 0x9b, 0x3e, 0x55, 0x3c, 0xec, 0x76, 0xf3, + 0xba, 0x22, 0x26, 0x1f, 0xc3, 0x2c, 0x85, 0xa2, 0xd5, 0x24, 0x96, 0x24, 0xbe, 0x92, 0x06, 0x47, + 0x84, 0x4f, 0x60, 0x9e, 0x57, 0xbe, 0x90, 0x92, 0x85, 0x24, 0xea, 0x6c, 0xdd, 0x4e, 0xb6, 0x23, + 0x22, 0xdf, 0xe7, 0xff, 0x61, 0x89, 0x22, 0x16, 0xba, 0x96, 0xfc, 0x33, 0x20, 0x59, 0x2b, 0xeb, + 0x5e, 0x2f, 0xe8, 0x55, 0x75, 0x97, 0x3a, 0xc2, 0x6f, 0x14, 0xc6, 0x59, 0x59, 0xdd, 0xe5, 0x47, + 0x6e, 0xda, 0x0c, 0x32, 0x79, 0x41, 0x28, 0xc5, 0xf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} diff --git a/pkg/kubelet/apis/cri/v1alpha1/api.proto b/pkg/kubelet/apis/cri/v1alpha1/api.proto index c663ef8340941..cdd551d512136 100644 --- a/pkg/kubelet/apis/cri/v1alpha1/api.proto +++ b/pkg/kubelet/apis/cri/v1alpha1/api.proto @@ -71,6 +71,12 @@ service RuntimeService { // PortForward prepares a streaming endpoint to forward ports from a PodSandbox. rpc PortForward(PortForwardRequest) returns (PortForwardResponse) {} + // ContainerStats returns stats of the container. If the container does not + // exist, the call returns an error. + rpc ContainerStats(ContainerStatsRequest) returns (ContainerStatsResponse) {} + // ListContainerStats returns stats of all running containers. + rpc ListContainerStats(ListContainerStatsRequest) returns (ListContainerStatsResponse) {} + // UpdateRuntimeConfig updates the runtime configuration based on the given request. rpc UpdateRuntimeConfig(UpdateRuntimeConfigRequest) returns (UpdateRuntimeConfigResponse) {} @@ -971,33 +977,105 @@ message UInt64Value { uint64 value = 1; } -// FsInfo contains data about filesystem usage. -message FsInfo { - // The block device name associated with the filesystem. - string device = 1; - // The root directory for the images. - string path = 2; - // CapacityBytes represents the total capacity (bytes) of the filesystems - // underlying storage. - UInt64Value capacity_bytes = 3; - // AvailableBytes represents the storage space available (bytes) for the - // filesystem. - UInt64Value available_bytes = 4; +// StorageIdentifier uniquely identify the storage.. +message StorageIdentifier{ + // UUID of the device. + string uuid = 1; +} + +// FilesystemUsage provides the filesystem usage information. +message FilesystemUsage { + // Timestamp in nanoseconds at which the information were collected. Must be > 0. + int64 timestamp = 1; + // The underlying storage of the filesystem. + StorageIdentifier storage_id = 2; // UsedBytes represents the bytes used for images on the filesystem. // This may differ from the total bytes used on the filesystem and may not // equal CapacityBytes - AvailableBytes. - UInt64Value used_bytes = 5; - // InodesCapacity represents the total inodes in the filesystem. - UInt64Value inodes_capacity = 6; - // InodesAvailable represents the free inodes in the filesystem. - UInt64Value inodes_available = 7; + UInt64Value used_bytes = 3; // InodesUsed represents the inodes used by the images. // This may not equal InodesCapacity - InodesAvailable because the underlying // filesystem may also be used for purposes other than storing images. - UInt64Value inodes_used = 8; + UInt64Value inodes_used = 4; } message ImageFsInfoResponse { - // filesystem information of images. - FsInfo fs_info = 1; + // Information of image filesystem(s). + repeated FilesystemUsage image_filesystems = 1; +} + +message ContainerStatsRequest{ + // ID of the container for which to retrieve stats. + string container_id = 1; +} + +message ContainerStatsResponse { + // Stats of the container. + ContainerStats stats = 1; +} + +message ListContainerStatsRequest{ + // Filter for the list request. + ContainerStatsFilter filter = 1; +} + +// ContainerStatsFilter is used to filter containers. +// All those fields are combined with 'AND' +message ContainerStatsFilter { + // ID of the container. + string id = 1; + // ID of the PodSandbox. + string pod_sandbox_id = 2; + // LabelSelector to select matches. + // Only api.MatchLabels is supported for now and the requirements + // are ANDed. MatchExpressions is not supported yet. + map label_selector = 3; +} + +message ListContainerStatsResponse { + // Stats of the container. + repeated ContainerStats stats = 1; +} + +// ContainerAttributes provides basic information of the container. +message ContainerAttributes { + // ID of the container. + string id = 1; + // Metadata of the container. + ContainerMetadata metadata = 2; + // Key-value pairs that may be used to scope and select individual resources. + map labels = 3; + // Unstructured key-value map holding arbitrary metadata. + // Annotations MUST NOT be altered by the runtime; the value of this field + // MUST be identical to that of the corresponding ContainerConfig used to + // instantiate the Container this status represents. + map annotations = 4; +} + +// ContainerStats provides the resource usage statistics for a container. +message ContainerStats { + // Information of the container. + ContainerAttributes attributes = 1; + // CPU usage gathered from the container. + CpuUsage cpu = 2; + // Memory usage gathered from the container. + MemoryUsage memory = 3; + // Usage of the writeable layer. + FilesystemUsage writable_layer = 4; +} + +// CpuUsage provides the CPU usage information. +message CpuUsage { + // Timestamp in nanoseconds at which the information were collected. Must be > 0. + int64 timestamp = 1; + // Cumulative CPU usage (sum across all cores) since object creation. + UInt64Value usage_core_nano_seconds = 2; +} + +// MemoryUsage provides the memory usage information. +message MemoryUsage { + // Timestamp in nanoseconds at which the information were collected. Must be > 0. + int64 timestamp = 1; + // The amount of working set memory in bytes. + UInt64Value working_set_bytes = 2; } diff --git a/pkg/kubelet/certificate/OWNER b/pkg/kubelet/certificate/OWNER new file mode 100644 index 0000000000000..f1008c19efaab --- /dev/null +++ b/pkg/kubelet/certificate/OWNER @@ -0,0 +1,6 @@ +reviewers: +- mikedanese +- liggit +approvers: +- mikedanese +- liggit diff --git a/pkg/kubelet/certificate/certificate_manager.go b/pkg/kubelet/certificate/certificate_manager.go index ada732e9be2d0..d02ef4f346860 100644 --- a/pkg/kubelet/certificate/certificate_manager.go +++ b/pkg/kubelet/certificate/certificate_manager.go @@ -122,6 +122,7 @@ type manager struct { certStore Store certAccessLock sync.RWMutex cert *tls.Certificate + rotationDeadline time.Time forceRotation bool } @@ -186,16 +187,28 @@ func (m *manager) Start() { glog.V(2).Infof("Certificate rotation is enabled.") - err := m.rotateCerts() - if err != nil { - glog.Errorf("Could not rotate certificates: %v", err) + m.setRotationDeadline() + + // Synchronously request a certificate before entering the background + // loop to allow bootstrap scenarios, where the certificate manager + // doesn't have a certificate at all yet. + if m.shouldRotate() { + _, err := m.rotateCerts() + if err != nil { + glog.Errorf("Could not rotate certificates: %v", err) + } + } + backoff := wait.Backoff{ + Duration: 2 * time.Second, + Factor: 2, + Jitter: 0.1, + Steps: 7, } go wait.Forever(func() { - for range time.Tick(syncPeriod) { - err := m.rotateCerts() - if err != nil { - glog.Errorf("Could not rotate certificates: %v", err) - } + time.Sleep(m.rotationDeadline.Sub(time.Now())) + if err := wait.ExponentialBackoff(backoff, m.rotateCerts); err != nil { + glog.Errorf("Reached backoff limit, still unable to rotate certs: %v", err) + wait.PollInfinite(128*time.Second, m.rotateCerts) } }, 0) } @@ -242,47 +255,61 @@ func (m *manager) shouldRotate() bool { if m.cert == nil { return true } - - notAfter := m.cert.Leaf.NotAfter - totalDuration := float64(notAfter.Sub(m.cert.Leaf.NotBefore)) - - // Use some jitter to set the rotation threshold so each node will rotate - // at approximately 70-90% of the total lifetime of the certificate. With - // jitter, if a number of nodes are added to a cluster at approximately the - // same time (such as cluster creation time), they won't all try to rotate - // certificates at the same time for the rest of the life of the cluster. - jitteryDuration := wait.Jitter(time.Duration(totalDuration), 0.2) - time.Duration(totalDuration*0.3) - - rotationThreshold := m.cert.Leaf.NotBefore.Add(jitteryDuration) - passedThreshold := time.Now().After(rotationThreshold) - return m.forceRotation || passedThreshold -} - -func (m *manager) rotateCerts() error { - if !m.shouldRotate() { - return nil + if m.forceRotation { + return true } + return time.Now().After(m.rotationDeadline) +} +func (m *manager) rotateCerts() (bool, error) { csrPEM, keyPEM, err := m.generateCSR() if err != nil { - return err + glog.Errorf("Unable to generate a certificate signing request: %v", err) + return false, nil } // Call the Certificate Signing Request API to get a certificate for the // new private key. crtPEM, err := requestCertificate(m.certSigningRequestClient, csrPEM, m.usages) if err != nil { - return fmt.Errorf("unable to get a new key signed: %v", err) + glog.Errorf("Failed while requesting a signed certificate from the master: %v", err) + return false, nil } cert, err := m.certStore.Update(crtPEM, keyPEM) if err != nil { - return fmt.Errorf("unable to store the new cert/key pair: %v", err) + glog.Errorf("Unable to store the new cert/key pair: %v", err) + return false, nil } m.updateCached(cert) + m.setRotationDeadline() m.forceRotation = false - return nil + return true, nil +} + +// setRotationDeadline sets a cached value for the threshold at which the +// current certificate should be rotated, 80%+/-10% of the expiration of the +// certificate. +func (m *manager) setRotationDeadline() { + m.certAccessLock.RLock() + defer m.certAccessLock.RUnlock() + if m.cert == nil { + m.rotationDeadline = time.Now() + return + } + + notAfter := m.cert.Leaf.NotAfter + totalDuration := float64(notAfter.Sub(m.cert.Leaf.NotBefore)) + + // Use some jitter to set the rotation threshold so each node will rotate + // at approximately 70-90% of the total lifetime of the certificate. With + // jitter, if a number of nodes are added to a cluster at approximately the + // same time (such as cluster creation time), they won't all try to rotate + // certificates at the same time for the rest of the life of the cluster. + jitteryDuration := wait.Jitter(time.Duration(totalDuration), 0.2) - time.Duration(totalDuration*0.3) + + m.rotationDeadline = m.cert.Leaf.NotBefore.Add(jitteryDuration) } func (m *manager) updateCached(cert *tls.Certificate) { diff --git a/pkg/kubelet/certificate/certificate_manager_test.go b/pkg/kubelet/certificate/certificate_manager_test.go index f3980ccab296f..a9fcf7b2dcc05 100644 --- a/pkg/kubelet/certificate/certificate_manager_test.go +++ b/pkg/kubelet/certificate/certificate_manager_test.go @@ -164,13 +164,14 @@ func TestShouldRotate(t *testing.T) { m := manager{ cert: &tls.Certificate{ Leaf: &x509.Certificate{ - NotAfter: test.notAfter, NotBefore: test.notBefore, + NotAfter: test.notAfter, }, }, template: &x509.CertificateRequest{}, usages: []certificates.KeyUsage{}, } + m.setRotationDeadline() if m.shouldRotate() != test.shouldRotate { t.Errorf("For time %v, a certificate issued for (%v, %v) should rotate should be %t.", now, @@ -182,6 +183,53 @@ func TestShouldRotate(t *testing.T) { } } +func TestSetRotationDeadline(t *testing.T) { + now := time.Now() + testCases := []struct { + name string + notBefore time.Time + notAfter time.Time + shouldRotate bool + }{ + {"just issued, still good", now.Add(-1 * time.Hour), now.Add(99 * time.Hour), false}, + {"half way expired, still good", now.Add(-24 * time.Hour), now.Add(24 * time.Hour), false}, + {"mostly expired, still good", now.Add(-69 * time.Hour), now.Add(31 * time.Hour), false}, + {"just about expired, should rotate", now.Add(-91 * time.Hour), now.Add(9 * time.Hour), true}, + {"nearly expired, should rotate", now.Add(-99 * time.Hour), now.Add(1 * time.Hour), true}, + {"already expired, should rotate", now.Add(-10 * time.Hour), now.Add(-1 * time.Hour), true}, + {"long duration", now.Add(-6 * 30 * 24 * time.Hour), now.Add(6 * 30 * 24 * time.Hour), true}, + {"short duration", now.Add(-30 * time.Second), now.Add(30 * time.Second), true}, + } + + for _, tc := range testCases { + for i := 0; i < 1000; i++ { + t.Run(tc.name, func(t *testing.T) { + m := manager{ + cert: &tls.Certificate{ + Leaf: &x509.Certificate{ + NotBefore: tc.notBefore, + NotAfter: tc.notAfter, + }, + }, + template: &x509.CertificateRequest{}, + usages: []certificates.KeyUsage{}, + } + m.setRotationDeadline() + lowerBound := tc.notBefore.Add(time.Duration(float64(tc.notAfter.Sub(tc.notBefore)) * 0.7)) + upperBound := tc.notBefore.Add(time.Duration(float64(tc.notAfter.Sub(tc.notBefore)) * 0.9)) + if m.rotationDeadline.Before(lowerBound) || m.rotationDeadline.After(upperBound) { + t.Errorf("For notBefore %v, notAfter %v, the rotationDeadline %v should be between %v and %v.", + tc.notBefore, + tc.notAfter, + m.rotationDeadline, + lowerBound, + upperBound) + } + }) + } + } +} + func TestRotateCertCreateCSRError(t *testing.T) { now := time.Now() m := manager{ @@ -198,8 +246,10 @@ func TestRotateCertCreateCSRError(t *testing.T) { }, } - if err := m.rotateCerts(); err == nil { - t.Errorf("Expected an error from 'rotateCerts'.") + if success, err := m.rotateCerts(); success { + t.Errorf("Got success from 'rotateCerts', wanted failure") + } else if err != nil { + t.Errorf("Got error %v from 'rotateCerts', wanted no error.", err) } } @@ -219,8 +269,10 @@ func TestRotateCertWaitingForResultError(t *testing.T) { }, } - if err := m.rotateCerts(); err == nil { - t.Errorf("Expected an error receiving results from the CSR request but nothing was received.") + if success, err := m.rotateCerts(); success { + t.Errorf("Got success from 'rotateCerts', wanted failure.") + } else if err != nil { + t.Errorf("Got error %v from 'rotateCerts', wanted no error.", err) } } @@ -286,8 +338,11 @@ func TestNewManagerNoBootstrap(t *testing.T) { if m, ok := cm.(*manager); !ok { t.Errorf("Expected a '*manager' from 'NewManager'") - } else if m.shouldRotate() { - t.Errorf("Expected rotation should happen during bootstrap, but it won't.") + } else { + m.setRotationDeadline() + if m.shouldRotate() { + t.Errorf("Expected rotation should happen during bootstrap, but it won't.") + } } } @@ -436,8 +491,17 @@ func TestInitializeCertificateSigningRequestClient(t *testing.T) { t.Errorf("Got error %v, expected none.", err) } - if err := certificateManager.(*manager).rotateCerts(); err != nil { - t.Errorf("Got error %v, expected none.", err) + if m, ok := certificateManager.(*manager); !ok { + t.Errorf("Expected a '*manager' from 'NewManager'") + } else { + m.setRotationDeadline() + if m.shouldRotate() { + if success, err := m.rotateCerts(); !success { + t.Errorf("Got failure from 'rotateCerts', wanted success.") + } else if err != nil { + t.Errorf("Got error %v, expected none.", err) + } + } } certificate = certificateManager.Current() @@ -526,8 +590,17 @@ func TestInitializeOtherRESTClients(t *testing.T) { t.Errorf("Got %v, wanted %v", certificateString(certificate), certificateString(tc.expectedCertBeforeStart.certificate)) } - if err := certificateManager.(*manager).rotateCerts(); err != nil { - t.Errorf("Got error %v, expected none.", err) + if m, ok := certificateManager.(*manager); !ok { + t.Errorf("Expected a '*manager' from 'NewManager'") + } else { + m.setRotationDeadline() + if m.shouldRotate() { + if success, err := certificateManager.(*manager).rotateCerts(); !success { + t.Errorf("Got failure from 'rotateCerts', expected success") + } else if err != nil { + t.Errorf("Got error %v, expected none.", err) + } + } } certificate = certificateManager.Current() diff --git a/pkg/kubelet/certificate/certificate_store.go b/pkg/kubelet/certificate/certificate_store.go index 890961d83f2f7..53f4d98a4a4fb 100644 --- a/pkg/kubelet/certificate/certificate_store.go +++ b/pkg/kubelet/certificate/certificate_store.go @@ -195,6 +195,9 @@ func (s *fileStore) Update(certData, keyData []byte) (*tls.Certificate, error) { ts := time.Now().Format("2006-01-02-15-04-05") pemFilename := s.filename(ts) + if err := os.MkdirAll(s.certDirectory, 0755); err != nil { + return nil, fmt.Errorf("could not create directory %q to store certificates: %v", s.certDirectory, err) + } certPath := filepath.Join(s.certDirectory, pemFilename) f, err := os.OpenFile(certPath, os.O_CREATE|os.O_TRUNC|os.O_RDWR, 0600) diff --git a/pkg/kubelet/cm/cgroup_manager_linux.go b/pkg/kubelet/cm/cgroup_manager_linux.go index e30d73bac764d..d4b9d60a92944 100644 --- a/pkg/kubelet/cm/cgroup_manager_linux.go +++ b/pkg/kubelet/cm/cgroup_manager_linux.go @@ -164,7 +164,7 @@ func (l *libcontainerAdapter) adaptName(cgroupName CgroupName, outputToCgroupFs return ConvertCgroupNameToSystemd(cgroupName, outputToCgroupFs) } -// CgroupSubsystems holds information about the mounted cgroup subsytems +// CgroupSubsystems holds information about the mounted cgroup subsystems type CgroupSubsystems struct { // Cgroup subsystem mounts. // e.g.: "/sys/fs/cgroup/cpu" -> ["cpu", "cpuacct"] @@ -181,7 +181,7 @@ type CgroupSubsystems struct { // It uses the Libcontainer raw fs cgroup manager for cgroup management. type cgroupManagerImpl struct { // subsystems holds information about all the - // mounted cgroup subsytems on the node + // mounted cgroup subsystems on the node subsystems *CgroupSubsystems // simplifies interaction with libcontainer and its cgroup managers adapter *libcontainerAdapter @@ -305,8 +305,8 @@ var supportedSubsystems = []subsystem{ &cgroupfs.CpuGroup{}, } -// setSupportedSubsytems sets cgroup resource limits only on the supported -// subsytems. ie. cpu and memory. We don't use libcontainer's cgroup/fs/Set() +// setSupportedSubsystems sets cgroup resource limits only on the supported +// subsystems. ie. cpu and memory. We don't use libcontainer's cgroup/fs/Set() // method as it doesn't allow us to skip updates on the devices cgroup // Allowing or denying all devices by writing 'a' to devices.allow or devices.deny is // not possible once the device cgroups has children. Once the pod level cgroup are @@ -314,10 +314,10 @@ var supportedSubsystems = []subsystem{ // We would like to skip setting any values on the device cgroup in this case // but this is not possible with libcontainers Set() method // See https://github.com/opencontainers/runc/issues/932 -func setSupportedSubsytems(cgroupConfig *libcontainerconfigs.Cgroup) error { +func setSupportedSubsystems(cgroupConfig *libcontainerconfigs.Cgroup) error { for _, sys := range supportedSubsystems { if _, ok := cgroupConfig.Paths[sys.Name()]; !ok { - return fmt.Errorf("Failed to find subsytem mount for subsytem: %v", sys.Name()) + return fmt.Errorf("Failed to find subsystem mount for subsystem: %v", sys.Name()) } if err := sys.Set(cgroupConfig.Paths[sys.Name()], cgroupConfig); err != nil { return fmt.Errorf("Failed to set config for supported subsystems : %v", err) @@ -380,7 +380,7 @@ func (m *cgroupManagerImpl) Update(cgroupConfig *CgroupConfig) error { Paths: cgroupPaths, } - if err := setSupportedSubsytems(libcontainerCgroupConfig); err != nil { + if err := setSupportedSubsystems(libcontainerCgroupConfig); err != nil { return fmt.Errorf("failed to set supported cgroup subsystems for cgroup %v: %v", cgroupConfig.Name, err) } return nil @@ -422,7 +422,7 @@ func (m *cgroupManagerImpl) Create(cgroupConfig *CgroupConfig) error { // Apply(-1) is a hack to create the cgroup directories for each resource // subsystem. The function [cgroups.Manager.apply()] applies cgroup // configuration to the process with the specified pid. - // It creates cgroup files for each subsytems and writes the pid + // It creates cgroup files for each subsystems and writes the pid // in the tasks file. We use the function to create all the required // cgroup files but not attach any "real" pid to the cgroup. if err := manager.Apply(-1); err != nil { @@ -436,7 +436,7 @@ func (m *cgroupManagerImpl) Create(cgroupConfig *CgroupConfig) error { return nil } -// Scans through all subsytems to find pids associated with specified cgroup. +// Scans through all subsystems to find pids associated with specified cgroup. func (m *cgroupManagerImpl) Pids(name CgroupName) []int { // we need the driver specific name cgroupFsName := m.Name(name) @@ -500,11 +500,11 @@ func (m *cgroupManagerImpl) ReduceCPULimits(cgroupName CgroupName) error { return m.Update(containerConfig) } -func getStatsSupportedSubsytems(cgroupPaths map[string]string) (*libcontainercgroups.Stats, error) { +func getStatsSupportedSubsystems(cgroupPaths map[string]string) (*libcontainercgroups.Stats, error) { stats := libcontainercgroups.NewStats() for _, sys := range supportedSubsystems { if _, ok := cgroupPaths[sys.Name()]; !ok { - return nil, fmt.Errorf("Failed to find subsytem mount for subsytem: %v", sys.Name()) + return nil, fmt.Errorf("Failed to find subsystem mount for subsystem: %v", sys.Name()) } if err := sys.GetStats(cgroupPaths[sys.Name()], stats); err != nil { return nil, fmt.Errorf("Failed to get stats for supported subsystems : %v", err) @@ -524,7 +524,7 @@ func toResourceStats(stats *libcontainercgroups.Stats) *ResourceStats { // Get sets the ResourceParameters of the specified cgroup as read from the cgroup fs func (m *cgroupManagerImpl) GetResourceStats(name CgroupName) (*ResourceStats, error) { cgroupPaths := m.buildCgroupPaths(name) - stats, err := getStatsSupportedSubsytems(cgroupPaths) + stats, err := getStatsSupportedSubsystems(cgroupPaths) if err != nil { return nil, fmt.Errorf("failed to get stats supported cgroup subsystems for cgroup %v: %v", name, err) } diff --git a/pkg/kubelet/cm/container_manager.go b/pkg/kubelet/cm/container_manager.go index 89d99e73c51cb..627236aebd7b7 100644 --- a/pkg/kubelet/cm/container_manager.go +++ b/pkg/kubelet/cm/container_manager.go @@ -51,7 +51,7 @@ type ContainerManager interface { // Returns a noop implementation if qos cgroup hierarchy is not enabled NewPodContainerManager() PodContainerManager - // GetMountedSubsystems returns the mounted cgroup subsytems on the node + // GetMountedSubsystems returns the mounted cgroup subsystems on the node GetMountedSubsystems() *CgroupSubsystems // GetQOSContainersInfo returns the names of top level QoS containers diff --git a/pkg/kubelet/cm/container_manager_linux_test.go b/pkg/kubelet/cm/container_manager_linux_test.go index 31e8c5356c96e..12219d0b9b9c3 100644 --- a/pkg/kubelet/cm/container_manager_linux_test.go +++ b/pkg/kubelet/cm/container_manager_linux_test.go @@ -124,7 +124,7 @@ func TestCgroupMountValidationMemoryMissing(t *testing.T) { assert.Error(t, err) } -func TestCgroupMountValidationMultipleSubsytem(t *testing.T) { +func TestCgroupMountValidationMultipleSubsystem(t *testing.T) { mountInt := &fakeMountInterface{ []mount.MountPoint{ { diff --git a/pkg/kubelet/cm/pod_container_manager_linux.go b/pkg/kubelet/cm/pod_container_manager_linux.go index d45ab29e792da..02405b6e55f41 100644 --- a/pkg/kubelet/cm/pod_container_manager_linux.go +++ b/pkg/kubelet/cm/pod_container_manager_linux.go @@ -175,7 +175,7 @@ func (m *podContainerManagerImpl) ReduceCPULimits(podCgroup CgroupName) error { return m.cgroupManager.ReduceCPULimits(podCgroup) } -// GetAllPodsFromCgroups scans through all the subsytems of pod cgroups +// GetAllPodsFromCgroups scans through all the subsystems of pod cgroups // Get list of pods whose cgroup still exist on the cgroup mounts func (m *podContainerManagerImpl) GetAllPodsFromCgroups() (map[types.UID]CgroupName, error) { // Map for storing all the found pods on the disk diff --git a/pkg/kubelet/cm/types.go b/pkg/kubelet/cm/types.go index a2dd30b7b36d1..66c926a61c98b 100644 --- a/pkg/kubelet/cm/types.go +++ b/pkg/kubelet/cm/types.go @@ -80,7 +80,7 @@ type CgroupManager interface { Name(name CgroupName) string // CgroupName converts the literal cgroupfs name on the host to an internal identifier. CgroupName(name string) CgroupName - // Pids scans through all subsytems to find pids associated with specified cgroup. + // Pids scans through all subsystems to find pids associated with specified cgroup. Pids(name CgroupName) []int // ReduceCPULimits reduces the CPU CFS values to the minimum amount of shares. ReduceCPULimits(cgroupName CgroupName) error diff --git a/pkg/kubelet/configmap/BUILD b/pkg/kubelet/configmap/BUILD new file mode 100644 index 0000000000000..df03366e2ae88 --- /dev/null +++ b/pkg/kubelet/configmap/BUILD @@ -0,0 +1,59 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_library( + name = "go_default_library", + srcs = [ + "configmap_manager.go", + "fake_manager.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/api/v1:go_default_library", + "//pkg/api/v1/pod:go_default_library", + "//pkg/client/clientset_generated/clientset:go_default_library", + "//pkg/kubelet/util:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/clock:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage/etcd:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) + +go_test( + name = "go_default_test", + srcs = ["configmap_manager_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//pkg/api/v1:go_default_library", + "//pkg/client/clientset_generated/clientset/fake:go_default_library", + "//vendor/github.com/stretchr/testify/assert:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/clock:go_default_library", + "//vendor/k8s.io/client-go/testing:go_default_library", + ], +) diff --git a/pkg/kubelet/configmap/configmap_manager.go b/pkg/kubelet/configmap/configmap_manager.go new file mode 100644 index 0000000000000..88ac32624e8ee --- /dev/null +++ b/pkg/kubelet/configmap/configmap_manager.go @@ -0,0 +1,302 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package configmap + +import ( + "fmt" + "strconv" + "sync" + "time" + + storageetcd "k8s.io/apiserver/pkg/storage/etcd" + "k8s.io/kubernetes/pkg/api/v1" + podutil "k8s.io/kubernetes/pkg/api/v1/pod" + clientset "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" + "k8s.io/kubernetes/pkg/kubelet/util" + + apierrors "k8s.io/apimachinery/pkg/api/errors" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/clock" + "k8s.io/apimachinery/pkg/util/sets" +) + +const ( + defaultTTL = time.Minute +) + +type Manager interface { + // Get configmap by configmap namespace and name. + GetConfigMap(namespace, name string) (*v1.ConfigMap, error) + + // WARNING: Register/UnregisterPod functions should be efficient, + // i.e. should not block on network operations. + + // RegisterPod registers all configmaps from a given pod. + RegisterPod(pod *v1.Pod) + + // UnregisterPod unregisters configmaps from a given pod that are not + // used by any other registered pod. + UnregisterPod(pod *v1.Pod) +} + +// simpleConfigMapManager implements ConfigMap Manager interface with +// simple operations to apiserver. +type simpleConfigMapManager struct { + kubeClient clientset.Interface +} + +func NewSimpleConfigMapManager(kubeClient clientset.Interface) Manager { + return &simpleConfigMapManager{kubeClient: kubeClient} +} + +func (s *simpleConfigMapManager) GetConfigMap(namespace, name string) (*v1.ConfigMap, error) { + return s.kubeClient.Core().ConfigMaps(namespace).Get(name, metav1.GetOptions{}) +} + +func (s *simpleConfigMapManager) RegisterPod(pod *v1.Pod) { +} + +func (s *simpleConfigMapManager) UnregisterPod(pod *v1.Pod) { +} + +type GetObjectTTLFunc func() (time.Duration, bool) + +type objectKey struct { + namespace string + name string +} + +// configMapStoreItems is a single item stored in configMapStore. +type configMapStoreItem struct { + refCount int + configMap *configMapData +} + +type configMapData struct { + sync.Mutex + + configMap *v1.ConfigMap + err error + lastUpdateTime time.Time +} + +// configMapStore is a local cache of configmaps. +type configMapStore struct { + kubeClient clientset.Interface + clock clock.Clock + + lock sync.Mutex + items map[objectKey]*configMapStoreItem + + defaultTTL time.Duration + getTTL GetObjectTTLFunc +} + +func newConfigMapStore(kubeClient clientset.Interface, clock clock.Clock, getTTL GetObjectTTLFunc, ttl time.Duration) *configMapStore { + return &configMapStore{ + kubeClient: kubeClient, + clock: clock, + items: make(map[objectKey]*configMapStoreItem), + defaultTTL: ttl, + getTTL: getTTL, + } +} + +func isConfigMapOlder(newConfigMap, oldConfigMap *v1.ConfigMap) bool { + if newConfigMap == nil || oldConfigMap == nil { + return false + } + newVersion, _ := storageetcd.Versioner.ObjectResourceVersion(newConfigMap) + oldVersion, _ := storageetcd.Versioner.ObjectResourceVersion(oldConfigMap) + return newVersion < oldVersion +} + +func (s *configMapStore) Add(namespace, name string) { + key := objectKey{namespace: namespace, name: name} + + // Add is called from RegisterPod, thus it needs to be efficient. + // Thus Add() is only increasing refCount and generation of a given configmap. + // Then Get() is responsible for fetching if needed. + s.lock.Lock() + defer s.lock.Unlock() + item, exists := s.items[key] + if !exists { + item = &configMapStoreItem{ + refCount: 0, + configMap: &configMapData{}, + } + s.items[key] = item + } + + item.refCount++ + // This will trigger fetch on the next Get() operation. + item.configMap = nil +} + +func (s *configMapStore) Delete(namespace, name string) { + key := objectKey{namespace: namespace, name: name} + + s.lock.Lock() + defer s.lock.Unlock() + if item, ok := s.items[key]; ok { + item.refCount-- + if item.refCount == 0 { + delete(s.items, key) + } + } +} + +func GetObjectTTLFromNodeFunc(getNode func() (*v1.Node, error)) GetObjectTTLFunc { + return func() (time.Duration, bool) { + node, err := getNode() + if err != nil { + return time.Duration(0), false + } + if node != nil && node.Annotations != nil { + if value, ok := node.Annotations[v1.ObjectTTLAnnotationKey]; ok { + if intValue, err := strconv.Atoi(value); err == nil { + return time.Duration(intValue) * time.Second, true + } + } + } + return time.Duration(0), false + } +} + +func (s *configMapStore) isConfigMapFresh(data *configMapData) bool { + configMapTTL := s.defaultTTL + if ttl, ok := s.getTTL(); ok { + configMapTTL = ttl + } + return s.clock.Now().Before(data.lastUpdateTime.Add(configMapTTL)) +} + +func (s *configMapStore) Get(namespace, name string) (*v1.ConfigMap, error) { + key := objectKey{namespace: namespace, name: name} + + data := func() *configMapData { + s.lock.Lock() + defer s.lock.Unlock() + item, exists := s.items[key] + if !exists { + return nil + } + if item.configMap == nil { + item.configMap = &configMapData{} + } + return item.configMap + }() + if data == nil { + return nil, fmt.Errorf("configmap %q/%q not registered", namespace, name) + } + + // After updating data in configMapStore, lock the data, fetch configMap if + // needed and return data. + data.Lock() + defer data.Unlock() + if data.err != nil || !s.isConfigMapFresh(data) { + opts := metav1.GetOptions{} + if data.configMap != nil && data.err == nil { + // This is just a periodic refresh of a configmap we successfully fetched previously. + // In this case, server data from apiserver cache to reduce the load on both + // etcd and apiserver (the cache is eventually consistent). + util.FromApiserverCache(&opts) + } + configMap, err := s.kubeClient.Core().ConfigMaps(namespace).Get(name, opts) + if err != nil && !apierrors.IsNotFound(err) && data.configMap == nil && data.err == nil { + // Couldn't fetch the latest configmap, but there is no cached data to return. + // Return the fetch result instead. + return configMap, err + } + if (err == nil && !isConfigMapOlder(configMap, data.configMap)) || apierrors.IsNotFound(err) { + // If the fetch succeeded with a newer version of the configmap, or if the + // configmap could not be found in the apiserver, update the cached data to + // reflect the current status. + data.configMap = configMap + data.err = err + data.lastUpdateTime = s.clock.Now() + } + } + return data.configMap, data.err +} + +// cachingConfigMapManager keeps a cache of all configmaps necessary for registered pods. +// It implements the following logic: +// - whenever a pod is created or updated, the cached versions of all its configmaps +// are invalidated +// - every GetConfigMap() call tries to fetch the value from local cache; if it is +// not there, invalidated or too old, we fetch it from apiserver and refresh the +// value in cache; otherwise it is just fetched from cache +type cachingConfigMapManager struct { + configMapStore *configMapStore + + lock sync.Mutex + registeredPods map[objectKey]*v1.Pod +} + +func NewCachingConfigMapManager(kubeClient clientset.Interface, getTTL GetObjectTTLFunc) Manager { + csm := &cachingConfigMapManager{ + configMapStore: newConfigMapStore(kubeClient, clock.RealClock{}, getTTL, defaultTTL), + registeredPods: make(map[objectKey]*v1.Pod), + } + return csm +} + +func (c *cachingConfigMapManager) GetConfigMap(namespace, name string) (*v1.ConfigMap, error) { + return c.configMapStore.Get(namespace, name) +} + +func getConfigMapNames(pod *v1.Pod) sets.String { + result := sets.NewString() + podutil.VisitPodConfigmapNames(pod, func(name string) bool { + result.Insert(name) + return true + }) + return result +} + +func (c *cachingConfigMapManager) RegisterPod(pod *v1.Pod) { + names := getConfigMapNames(pod) + c.lock.Lock() + defer c.lock.Unlock() + for name := range names { + c.configMapStore.Add(pod.Namespace, name) + } + var prev *v1.Pod + key := objectKey{namespace: pod.Namespace, name: pod.Name} + prev = c.registeredPods[key] + c.registeredPods[key] = pod + if prev != nil { + for name := range getConfigMapNames(prev) { + c.configMapStore.Delete(prev.Namespace, name) + } + } +} + +func (c *cachingConfigMapManager) UnregisterPod(pod *v1.Pod) { + var prev *v1.Pod + key := objectKey{namespace: pod.Namespace, name: pod.Name} + c.lock.Lock() + defer c.lock.Unlock() + prev = c.registeredPods[key] + delete(c.registeredPods, key) + if prev != nil { + for name := range getConfigMapNames(prev) { + c.configMapStore.Delete(prev.Namespace, name) + } + } +} diff --git a/pkg/kubelet/configmap/configmap_manager_test.go b/pkg/kubelet/configmap/configmap_manager_test.go new file mode 100644 index 0000000000000..b2a36c516efe0 --- /dev/null +++ b/pkg/kubelet/configmap/configmap_manager_test.go @@ -0,0 +1,537 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package configmap + +import ( + "fmt" + "reflect" + "strings" + "sync" + "testing" + "time" + + "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/fake" + + apierrors "k8s.io/apimachinery/pkg/api/errors" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/clock" + core "k8s.io/client-go/testing" + + "github.com/stretchr/testify/assert" +) + +func checkConfigMap(t *testing.T, store *configMapStore, ns, name string, shouldExist bool) { + _, err := store.Get(ns, name) + if shouldExist && err != nil { + t.Errorf("unexpected actions: %#v", err) + } + if !shouldExist && (err == nil || !strings.Contains(err.Error(), fmt.Sprintf("configmap %q/%q not registered", ns, name))) { + t.Errorf("unexpected actions: %#v", err) + } +} + +func noObjectTTL() (time.Duration, bool) { + return time.Duration(0), false +} + +func TestConfigMapStore(t *testing.T) { + fakeClient := &fake.Clientset{} + store := newConfigMapStore(fakeClient, clock.RealClock{}, noObjectTTL, 0) + store.Add("ns1", "name1") + store.Add("ns2", "name2") + store.Add("ns1", "name1") + store.Add("ns1", "name1") + store.Delete("ns1", "name1") + store.Delete("ns2", "name2") + store.Add("ns3", "name3") + + // Adds don't issue Get requests. + actions := fakeClient.Actions() + assert.Equal(t, 0, len(actions), "unexpected actions: %#v", actions) + // Should issue Get request + store.Get("ns1", "name1") + // Shouldn't issue Get request, as configMap is not registered + store.Get("ns2", "name2") + // Should issue Get request + store.Get("ns3", "name3") + + actions = fakeClient.Actions() + assert.Equal(t, 2, len(actions), "unexpected actions: %#v", actions) + + for _, a := range actions { + assert.True(t, a.Matches("get", "configmaps"), "unexpected actions: %#v", a) + } + + checkConfigMap(t, store, "ns1", "name1", true) + checkConfigMap(t, store, "ns2", "name2", false) + checkConfigMap(t, store, "ns3", "name3", true) + checkConfigMap(t, store, "ns4", "name4", false) +} + +func TestConfigMapStoreDeletingConfigMap(t *testing.T) { + fakeClient := &fake.Clientset{} + store := newConfigMapStore(fakeClient, clock.RealClock{}, noObjectTTL, 0) + store.Add("ns", "name") + + result := &v1.ConfigMap{ObjectMeta: metav1.ObjectMeta{Namespace: "ns", Name: "name", ResourceVersion: "10"}} + fakeClient.AddReactor("get", "configmaps", func(action core.Action) (bool, runtime.Object, error) { + return true, result, nil + }) + configMap, err := store.Get("ns", "name") + if err != nil { + t.Errorf("Unexpected error: %v", err) + } + if !reflect.DeepEqual(configMap, result) { + t.Errorf("Unexpected configMap: %v", configMap) + } + + fakeClient.PrependReactor("get", "configmaps", func(action core.Action) (bool, runtime.Object, error) { + return true, &v1.ConfigMap{}, apierrors.NewNotFound(v1.Resource("configMap"), "name") + }) + configMap, err = store.Get("ns", "name") + if err == nil || !apierrors.IsNotFound(err) { + t.Errorf("Unexpected error: %v", err) + } + if !reflect.DeepEqual(configMap, &v1.ConfigMap{}) { + t.Errorf("Unexpected configMap: %v", configMap) + } +} + +func TestConfigMapStoreGetAlwaysRefresh(t *testing.T) { + fakeClient := &fake.Clientset{} + fakeClock := clock.NewFakeClock(time.Now()) + store := newConfigMapStore(fakeClient, fakeClock, noObjectTTL, 0) + + for i := 0; i < 10; i++ { + store.Add(fmt.Sprintf("ns-%d", i), fmt.Sprintf("name-%d", i)) + } + fakeClient.ClearActions() + + wg := sync.WaitGroup{} + wg.Add(100) + for i := 0; i < 100; i++ { + go func(i int) { + store.Get(fmt.Sprintf("ns-%d", i%10), fmt.Sprintf("name-%d", i%10)) + wg.Done() + }(i) + } + wg.Wait() + actions := fakeClient.Actions() + assert.Equal(t, 100, len(actions), "unexpected actions: %#v", actions) + + for _, a := range actions { + assert.True(t, a.Matches("get", "configmaps"), "unexpected actions: %#v", a) + } +} + +func TestConfigMapStoreGetNeverRefresh(t *testing.T) { + fakeClient := &fake.Clientset{} + fakeClock := clock.NewFakeClock(time.Now()) + store := newConfigMapStore(fakeClient, fakeClock, noObjectTTL, time.Minute) + + for i := 0; i < 10; i++ { + store.Add(fmt.Sprintf("ns-%d", i), fmt.Sprintf("name-%d", i)) + } + fakeClient.ClearActions() + + wg := sync.WaitGroup{} + wg.Add(100) + for i := 0; i < 100; i++ { + go func(i int) { + store.Get(fmt.Sprintf("ns-%d", i%10), fmt.Sprintf("name-%d", i%10)) + wg.Done() + }(i) + } + wg.Wait() + actions := fakeClient.Actions() + // Only first Get, should forward the Get request. + assert.Equal(t, 10, len(actions), "unexpected actions: %#v", actions) +} + +func TestCustomTTL(t *testing.T) { + ttl := time.Duration(0) + ttlExists := false + customTTL := func() (time.Duration, bool) { + return ttl, ttlExists + } + + fakeClient := &fake.Clientset{} + fakeClock := clock.NewFakeClock(time.Time{}) + store := newConfigMapStore(fakeClient, fakeClock, customTTL, time.Minute) + + store.Add("ns", "name") + store.Get("ns", "name") + fakeClient.ClearActions() + + // Set 0-ttl and see if that works. + ttl = time.Duration(0) + ttlExists = true + store.Get("ns", "name") + actions := fakeClient.Actions() + assert.Equal(t, 1, len(actions), "unexpected actions: %#v", actions) + fakeClient.ClearActions() + + // Set 5-minute ttl and see if this works. + ttl = time.Duration(5) * time.Minute + store.Get("ns", "name") + actions = fakeClient.Actions() + assert.Equal(t, 0, len(actions), "unexpected actions: %#v", actions) + // Still no effect after 4 minutes. + fakeClock.Step(4 * time.Minute) + store.Get("ns", "name") + actions = fakeClient.Actions() + assert.Equal(t, 0, len(actions), "unexpected actions: %#v", actions) + // Now it should have an effect. + fakeClock.Step(time.Minute) + store.Get("ns", "name") + actions = fakeClient.Actions() + assert.Equal(t, 1, len(actions), "unexpected actions: %#v", actions) + fakeClient.ClearActions() + + // Now remove the custom ttl and see if that works. + ttlExists = false + fakeClock.Step(55 * time.Second) + store.Get("ns", "name") + actions = fakeClient.Actions() + assert.Equal(t, 0, len(actions), "unexpected actions: %#v", actions) + // Pass the minute and it should be triggered now. + fakeClock.Step(5 * time.Second) + store.Get("ns", "name") + actions = fakeClient.Actions() + assert.Equal(t, 1, len(actions), "unexpected actions: %#v", actions) +} + +func TestParseNodeAnnotation(t *testing.T) { + testCases := []struct { + node *v1.Node + err error + exists bool + ttl time.Duration + }{ + { + node: nil, + err: fmt.Errorf("error"), + exists: false, + }, + { + node: &v1.Node{ + ObjectMeta: metav1.ObjectMeta{ + Name: "node", + }, + }, + exists: false, + }, + { + node: &v1.Node{ + ObjectMeta: metav1.ObjectMeta{ + Name: "node", + Annotations: map[string]string{}, + }, + }, + exists: false, + }, + { + node: &v1.Node{ + ObjectMeta: metav1.ObjectMeta{ + Name: "node", + Annotations: map[string]string{v1.ObjectTTLAnnotationKey: "bad"}, + }, + }, + exists: false, + }, + { + node: &v1.Node{ + ObjectMeta: metav1.ObjectMeta{ + Name: "node", + Annotations: map[string]string{v1.ObjectTTLAnnotationKey: "0"}, + }, + }, + exists: true, + ttl: time.Duration(0), + }, + { + node: &v1.Node{ + ObjectMeta: metav1.ObjectMeta{ + Name: "node", + Annotations: map[string]string{v1.ObjectTTLAnnotationKey: "60"}, + }, + }, + exists: true, + ttl: time.Minute, + }, + } + for i, testCase := range testCases { + getNode := func() (*v1.Node, error) { return testCase.node, testCase.err } + ttl, exists := GetObjectTTLFromNodeFunc(getNode)() + if exists != testCase.exists { + t.Errorf("%d: incorrect parsing: %t", i, exists) + continue + } + if exists && ttl != testCase.ttl { + t.Errorf("%d: incorrect ttl: %v", i, ttl) + } + } +} + +type envConfigMaps struct { + envVarNames []string + envFromNames []string +} + +type configMapsToAttach struct { + containerEnvConfigMaps []envConfigMaps + volumes []string +} + +func podWithConfigMaps(ns, name string, toAttach configMapsToAttach) *v1.Pod { + pod := &v1.Pod{ + ObjectMeta: metav1.ObjectMeta{ + Namespace: ns, + Name: name, + }, + Spec: v1.PodSpec{}, + } + for i, configMaps := range toAttach.containerEnvConfigMaps { + container := v1.Container{ + Name: fmt.Sprintf("container-%d", i), + } + for _, name := range configMaps.envFromNames { + envFrom := v1.EnvFromSource{ + ConfigMapRef: &v1.ConfigMapEnvSource{ + LocalObjectReference: v1.LocalObjectReference{ + Name: name, + }, + }, + } + container.EnvFrom = append(container.EnvFrom, envFrom) + } + + for _, name := range configMaps.envVarNames { + envSource := &v1.EnvVarSource{ + ConfigMapKeyRef: &v1.ConfigMapKeySelector{ + LocalObjectReference: v1.LocalObjectReference{ + Name: name, + }, + }, + } + container.Env = append(container.Env, v1.EnvVar{ValueFrom: envSource}) + } + pod.Spec.Containers = append(pod.Spec.Containers, container) + } + for _, configMap := range toAttach.volumes { + volume := &v1.ConfigMapVolumeSource{ + LocalObjectReference: v1.LocalObjectReference{Name: configMap}, + } + pod.Spec.Volumes = append(pod.Spec.Volumes, v1.Volume{ + Name: configMap, + VolumeSource: v1.VolumeSource{ + ConfigMap: volume, + }, + }) + } + return pod +} + +func TestCacheInvalidation(t *testing.T) { + fakeClient := &fake.Clientset{} + fakeClock := clock.NewFakeClock(time.Now()) + store := newConfigMapStore(fakeClient, fakeClock, noObjectTTL, time.Minute) + manager := &cachingConfigMapManager{ + configMapStore: store, + registeredPods: make(map[objectKey]*v1.Pod), + } + + // Create a pod with some configMaps. + s1 := configMapsToAttach{ + containerEnvConfigMaps: []envConfigMaps{ + {envVarNames: []string{"s1"}, envFromNames: []string{"s10"}}, + {envVarNames: []string{"s2"}}, + }, + } + manager.RegisterPod(podWithConfigMaps("ns1", "name1", s1)) + // Fetch both configMaps - this should triggger get operations. + store.Get("ns1", "s1") + store.Get("ns1", "s10") + store.Get("ns1", "s2") + actions := fakeClient.Actions() + assert.Equal(t, 3, len(actions), "unexpected actions: %#v", actions) + fakeClient.ClearActions() + + // Update a pod with a new configMap. + s2 := configMapsToAttach{ + containerEnvConfigMaps: []envConfigMaps{ + {envVarNames: []string{"s1"}}, + {envVarNames: []string{"s2"}, envFromNames: []string{"s20"}}, + }, + volumes: []string{"s3"}, + } + manager.RegisterPod(podWithConfigMaps("ns1", "name1", s2)) + // All configMaps should be invalidated - this should trigger get operations. + store.Get("ns1", "s1") + store.Get("ns1", "s2") + store.Get("ns1", "s20") + store.Get("ns1", "s3") + actions = fakeClient.Actions() + assert.Equal(t, 4, len(actions), "unexpected actions: %#v", actions) + fakeClient.ClearActions() + + // Create a new pod that is refencing the first three configMaps - those should + // be invalidated. + manager.RegisterPod(podWithConfigMaps("ns1", "name2", s1)) + store.Get("ns1", "s1") + store.Get("ns1", "s10") + store.Get("ns1", "s2") + store.Get("ns1", "s20") + store.Get("ns1", "s3") + actions = fakeClient.Actions() + assert.Equal(t, 3, len(actions), "unexpected actions: %#v", actions) + fakeClient.ClearActions() +} + +func TestCacheRefcounts(t *testing.T) { + fakeClient := &fake.Clientset{} + fakeClock := clock.NewFakeClock(time.Now()) + store := newConfigMapStore(fakeClient, fakeClock, noObjectTTL, time.Minute) + manager := &cachingConfigMapManager{ + configMapStore: store, + registeredPods: make(map[objectKey]*v1.Pod), + } + + s1 := configMapsToAttach{ + containerEnvConfigMaps: []envConfigMaps{ + {envVarNames: []string{"s1"}, envFromNames: []string{"s10"}}, + {envVarNames: []string{"s2"}}, + }, + volumes: []string{"s3"}, + } + manager.RegisterPod(podWithConfigMaps("ns1", "name1", s1)) + manager.RegisterPod(podWithConfigMaps("ns1", "name2", s1)) + s2 := configMapsToAttach{ + containerEnvConfigMaps: []envConfigMaps{ + {envVarNames: []string{"s4"}}, + {envVarNames: []string{"s5"}, envFromNames: []string{"s50"}}, + }, + } + manager.RegisterPod(podWithConfigMaps("ns1", "name2", s2)) + manager.RegisterPod(podWithConfigMaps("ns1", "name3", s2)) + manager.RegisterPod(podWithConfigMaps("ns1", "name4", s2)) + manager.UnregisterPod(podWithConfigMaps("ns1", "name3", s2)) + s3 := configMapsToAttach{ + containerEnvConfigMaps: []envConfigMaps{ + {envVarNames: []string{"s3"}, envFromNames: []string{"s30"}}, + {envVarNames: []string{"s5"}}, + }, + } + manager.RegisterPod(podWithConfigMaps("ns1", "name5", s3)) + manager.RegisterPod(podWithConfigMaps("ns1", "name6", s3)) + s4 := configMapsToAttach{ + containerEnvConfigMaps: []envConfigMaps{ + {envVarNames: []string{"s6"}}, + {envFromNames: []string{"s60"}}, + }, + } + manager.RegisterPod(podWithConfigMaps("ns1", "name7", s4)) + manager.UnregisterPod(podWithConfigMaps("ns1", "name7", s4)) + + // Also check the Add + Update + Remove scenario. + manager.RegisterPod(podWithConfigMaps("ns1", "other-name", s1)) + manager.RegisterPod(podWithConfigMaps("ns1", "other-name", s2)) + manager.UnregisterPod(podWithConfigMaps("ns1", "other-name", s2)) + + refs := func(ns, name string) int { + store.lock.Lock() + defer store.lock.Unlock() + item, ok := store.items[objectKey{ns, name}] + if !ok { + return 0 + } + return item.refCount + } + assert.Equal(t, refs("ns1", "s1"), 1) + assert.Equal(t, refs("ns1", "s10"), 1) + assert.Equal(t, refs("ns1", "s2"), 1) + assert.Equal(t, refs("ns1", "s3"), 3) + assert.Equal(t, refs("ns1", "s30"), 2) + assert.Equal(t, refs("ns1", "s4"), 2) + assert.Equal(t, refs("ns1", "s5"), 4) + assert.Equal(t, refs("ns1", "s50"), 2) + assert.Equal(t, refs("ns1", "s6"), 0) + assert.Equal(t, refs("ns1", "s60"), 0) + assert.Equal(t, refs("ns1", "s7"), 0) +} + +func TestCachingConfigMapManager(t *testing.T) { + fakeClient := &fake.Clientset{} + configMapStore := newConfigMapStore(fakeClient, clock.RealClock{}, noObjectTTL, 0) + manager := &cachingConfigMapManager{ + configMapStore: configMapStore, + registeredPods: make(map[objectKey]*v1.Pod), + } + + // Create a pod with some configMaps. + s1 := configMapsToAttach{ + containerEnvConfigMaps: []envConfigMaps{ + {envVarNames: []string{"s1"}}, + {envFromNames: []string{"s20"}}, + }, + volumes: []string{"s2"}, + } + manager.RegisterPod(podWithConfigMaps("ns1", "name1", s1)) + manager.RegisterPod(podWithConfigMaps("ns2", "name2", s1)) + // Update the pod with a different configMaps. + s2 := configMapsToAttach{ + containerEnvConfigMaps: []envConfigMaps{ + {envVarNames: []string{"s3"}}, + {envVarNames: []string{"s4"}}, + {envFromNames: []string{"s40"}}, + }, + } + // Create another pod, but with same configMaps in different namespace. + manager.RegisterPod(podWithConfigMaps("ns2", "name2", s2)) + // Create and delete a pod with some other configMaps. + s3 := configMapsToAttach{ + containerEnvConfigMaps: []envConfigMaps{ + {envVarNames: []string{"s6"}}, + {envFromNames: []string{"s60"}}, + }, + } + manager.RegisterPod(podWithConfigMaps("ns3", "name", s3)) + manager.UnregisterPod(podWithConfigMaps("ns3", "name", s3)) + + existingMaps := map[string][]string{ + "ns1": {"s1", "s2", "s20"}, + "ns2": {"s3", "s4", "s40"}, + } + shouldExist := func(ns, configMap string) bool { + if cmaps, ok := existingMaps[ns]; ok { + for _, cm := range cmaps { + if cm == configMap { + return true + } + } + } + return false + } + + for _, ns := range []string{"ns1", "ns2", "ns3"} { + for _, configMap := range []string{"s1", "s2", "s3", "s4", "s5", "s6", "s20", "s40", "s50"} { + checkConfigMap(t, configMapStore, ns, configMap, shouldExist(ns, configMap)) + } + } +} diff --git a/pkg/kubelet/configmap/fake_manager.go b/pkg/kubelet/configmap/fake_manager.go new file mode 100644 index 0000000000000..d1a4b85a6f90a --- /dev/null +++ b/pkg/kubelet/configmap/fake_manager.go @@ -0,0 +1,40 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package configmap + +import ( + "k8s.io/kubernetes/pkg/api/v1" +) + +// fakeManager implements Manager interface for testing purposes. +// simple operations to apiserver. +type fakeManager struct { +} + +func NewFakeManager() Manager { + return &fakeManager{} +} + +func (s *fakeManager) GetConfigMap(namespace, name string) (*v1.ConfigMap, error) { + return nil, nil +} + +func (s *fakeManager) RegisterPod(pod *v1.Pod) { +} + +func (s *fakeManager) UnregisterPod(pod *v1.Pod) { +} diff --git a/pkg/kubelet/dockershim/BUILD b/pkg/kubelet/dockershim/BUILD index fcc0f9ae3e29a..17ea565014728 100644 --- a/pkg/kubelet/dockershim/BUILD +++ b/pkg/kubelet/dockershim/BUILD @@ -20,6 +20,7 @@ go_library( "docker_legacy.go", "docker_sandbox.go", "docker_service.go", + "docker_stats.go", "docker_streaming.go", "exec.go", "helpers.go", @@ -31,6 +32,7 @@ go_library( deps = [ "//pkg/api/v1:go_default_library", "//pkg/apis/componentconfig:go_default_library", + "//pkg/credentialprovider:go_default_library", "//pkg/kubelet/apis/cri:go_default_library", "//pkg/kubelet/apis/cri/v1alpha1:go_default_library", "//pkg/kubelet/cm:go_default_library", diff --git a/pkg/kubelet/dockershim/cm/container_manager_unsupported.go b/pkg/kubelet/dockershim/cm/container_manager_unsupported.go index bab0d9884f704..7b35c5fa9a1e3 100644 --- a/pkg/kubelet/dockershim/cm/container_manager_unsupported.go +++ b/pkg/kubelet/dockershim/cm/container_manager_unsupported.go @@ -1,4 +1,4 @@ -// +build !linux +// +build !linux,!windows /* Copyright 2016 The Kubernetes Authors. diff --git a/pkg/kubelet/dockershim/cm/container_manager_windows.go b/pkg/kubelet/dockershim/cm/container_manager_windows.go new file mode 100644 index 0000000000000..500630e1abcb9 --- /dev/null +++ b/pkg/kubelet/dockershim/cm/container_manager_windows.go @@ -0,0 +1,35 @@ +// +build windows + +/* +Copyright 2017 The Kubernetes 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. +*/ + +package cm + +import ( + "k8s.io/kubernetes/pkg/kubelet/dockershim/libdocker" +) + +// no-op +type containerManager struct { +} + +func NewContainerManager(_ string, _ libdocker.Interface) ContainerManager { + return &containerManager{} +} + +func (m *containerManager) Start() error { + return nil +} diff --git a/pkg/kubelet/dockershim/docker_container.go b/pkg/kubelet/dockershim/docker_container.go index ab1ab5cb6fa89..2c63cc78e2739 100644 --- a/pkg/kubelet/dockershim/docker_container.go +++ b/pkg/kubelet/dockershim/docker_container.go @@ -342,7 +342,7 @@ func (ds *dockerService) ContainerStatus(containerID string) (*runtimeapi.Contai imageID := toPullableImageID(r.Image, ir) // Convert the mounts. - mounts := []*runtimeapi.Mount{} + mounts := make([]*runtimeapi.Mount, 0, len(r.Mounts)) for i := range r.Mounts { m := r.Mounts[i] readonly := !m.RW diff --git a/pkg/kubelet/dockershim/docker_image.go b/pkg/kubelet/dockershim/docker_image.go index 92cc2285bba8a..b374c3d7fc7ed 100644 --- a/pkg/kubelet/dockershim/docker_image.go +++ b/pkg/kubelet/dockershim/docker_image.go @@ -43,7 +43,7 @@ func (ds *dockerService) ListImages(filter *runtimeapi.ImageFilter) ([]*runtimea return nil, err } - result := []*runtimeapi.Image{} + result := make([]*runtimeapi.Image, 0, len(images)) for _, i := range images { apiImage, err := imageToRuntimeAPIImage(&i) if err != nil { @@ -134,7 +134,7 @@ func getImageRef(client libdocker.Interface, image string) (string, error) { } // ImageFsInfo returns information of the filesystem that is used to store images. -func (ds *dockerService) ImageFsInfo() (*runtimeapi.FsInfo, error) { +func (ds *dockerService) ImageFsInfo(req *runtimeapi.ImageFsInfoRequest) (*runtimeapi.ImageFsInfoResponse, error) { return nil, fmt.Errorf("not implemented") } diff --git a/pkg/kubelet/dockershim/docker_legacy.go b/pkg/kubelet/dockershim/docker_legacy.go index 21b91af0e06b5..9aa64729a2125 100644 --- a/pkg/kubelet/dockershim/docker_legacy.go +++ b/pkg/kubelet/dockershim/docker_legacy.go @@ -187,7 +187,7 @@ func (ds *dockerService) ListLegacyPodSandbox(filter *runtimeapi.PodSandboxFilte } // Convert docker containers to runtime api sandboxes. - result := []*runtimeapi.PodSandbox{} + result := make([]*runtimeapi.PodSandbox, 0, len(containers)) for i := range containers { c := containers[i] // Skip new containers with containerTypeLabelKey label. @@ -242,7 +242,7 @@ func (ds *dockerService) ListLegacyContainers(filter *runtimeapi.ContainerFilter } // Convert docker to runtime api containers. - result := []*runtimeapi.Container{} + result := make([]*runtimeapi.Container, 0, len(containers)) for i := range containers { c := containers[i] // Skip new containers with containerTypeLabelKey label. diff --git a/pkg/kubelet/dockershim/docker_service.go b/pkg/kubelet/dockershim/docker_service.go index 8e3043b85160a..e7fe8d4c197ed 100644 --- a/pkg/kubelet/dockershim/docker_service.go +++ b/pkg/kubelet/dockershim/docker_service.go @@ -332,7 +332,7 @@ func (ds *dockerService) GetPodPortMappings(podSandboxID string) ([]*hostport.Po } } - portMappings := []*hostport.PortMapping{} + portMappings := make([]*hostport.PortMapping, 0, len(checkpoint.Data.PortMappings)) for _, pm := range checkpoint.Data.PortMappings { proto := toAPIProtocol(*pm.Protocol) portMappings = append(portMappings, &hostport.PortMapping{ diff --git a/pkg/kubelet/dockershim/docker_stats.go b/pkg/kubelet/dockershim/docker_stats.go new file mode 100644 index 0000000000000..997cc8f167369 --- /dev/null +++ b/pkg/kubelet/dockershim/docker_stats.go @@ -0,0 +1,32 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package dockershim + +import ( + "fmt" + + runtimeapi "k8s.io/kubernetes/pkg/kubelet/apis/cri/v1alpha1" +) + +// DockerService does not implement container stats. +func (ds *dockerService) ContainerStats(*runtimeapi.ContainerStatsRequest) (*runtimeapi.ContainerStatsResponse, error) { + return nil, fmt.Errorf("Not implemented") +} + +func (ds *dockerService) ListContainerStats(*runtimeapi.ListContainerStatsRequest) (*runtimeapi.ListContainerStatsResponse, error) { + return nil, fmt.Errorf("Not implemented") +} diff --git a/pkg/kubelet/dockershim/helpers.go b/pkg/kubelet/dockershim/helpers.go index bb4acd53cbc0c..26e0b4491a32b 100644 --- a/pkg/kubelet/dockershim/helpers.go +++ b/pkg/kubelet/dockershim/helpers.go @@ -22,6 +22,7 @@ import ( "encoding/json" "fmt" "io/ioutil" + "os" "path/filepath" "regexp" "strconv" @@ -34,6 +35,7 @@ import ( "github.com/golang/glog" "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/pkg/credentialprovider" runtimeapi "k8s.io/kubernetes/pkg/kubelet/apis/cri/v1alpha1" "k8s.io/kubernetes/pkg/kubelet/types" "k8s.io/kubernetes/pkg/security/apparmor" @@ -127,7 +129,8 @@ func extractLabels(input map[string]string) (map[string]string, map[string]strin // '::ro', if the path is read only, or // '::Z', if the volume requires SELinux // relabeling and the pod provides an SELinux label -func generateMountBindings(mounts []*runtimeapi.Mount) (result []string) { +func generateMountBindings(mounts []*runtimeapi.Mount) []string { + result := make([]string, 0, len(mounts)) for _, m := range mounts { bind := fmt.Sprintf("%s:%s", m.HostPath, m.ContainerPath) readOnly := m.Readonly @@ -147,7 +150,7 @@ func generateMountBindings(mounts []*runtimeapi.Mount) (result []string) { } result = append(result, bind) } - return + return result } func makePortsAndBindings(pm []*runtimeapi.PortMapping) (map[dockernat.Port]struct{}, map[dockernat.Port][]dockernat.PortBinding) { @@ -375,6 +378,11 @@ func getSecurityOptSeparator(v *semver.Version) rune { // ensureSandboxImageExists pulls the sandbox image when it's not present. func ensureSandboxImageExists(client libdocker.Interface, image string) error { + dockerCfgSearchPath := []string{"/.docker", filepath.Join(os.Getenv("HOME"), ".docker")} + return ensureSandboxImageExistsDockerCfg(client, image, dockerCfgSearchPath) +} + +func ensureSandboxImageExistsDockerCfg(client libdocker.Interface, image string, dockerCfgSearchPath []string) error { _, err := client.InspectImageByRef(image) if err == nil { return nil @@ -382,8 +390,32 @@ func ensureSandboxImageExists(client libdocker.Interface, image string) error { if !libdocker.IsImageNotFoundError(err) { return fmt.Errorf("failed to inspect sandbox image %q: %v", image, err) } - err = client.PullImage(image, dockertypes.AuthConfig{}, dockertypes.ImagePullOptions{}) + + // To support images in private registries, try to read docker config + authConfig := dockertypes.AuthConfig{} + keyring := &credentialprovider.BasicDockerKeyring{} + var cfgLoadErr error + if cfg, err := credentialprovider.ReadDockerConfigJSONFile(dockerCfgSearchPath); err == nil { + keyring.Add(cfg) + } else if cfg, err := credentialprovider.ReadDockercfgFile(dockerCfgSearchPath); err == nil { + keyring.Add(cfg) + } else { + cfgLoadErr = err + } + if creds, withCredentials := keyring.Lookup(image); withCredentials { + // Use the first one that matched our image + for _, cred := range creds { + authConfig.Username = cred.Username + authConfig.Password = cred.Password + break + } + } + + err = client.PullImage(image, authConfig, dockertypes.ImagePullOptions{}) if err != nil { + if cfgLoadErr != nil { + glog.Warningf("Couldn't load Docker cofig. If sandbox image %q is in a private registry, this will cause further errors. Error: %v", image, cfgLoadErr) + } return fmt.Errorf("unable to pull sandbox image %q: %v", image, err) } return nil diff --git a/pkg/kubelet/dockershim/helpers_test.go b/pkg/kubelet/dockershim/helpers_test.go index 19ca1c48a9566..8138228e2da86 100644 --- a/pkg/kubelet/dockershim/helpers_test.go +++ b/pkg/kubelet/dockershim/helpers_test.go @@ -17,8 +17,12 @@ limitations under the License. package dockershim import ( + "encoding/base64" "fmt" + "io/ioutil" + "os" "path" + "path/filepath" "testing" "github.com/blang/semver" @@ -247,13 +251,33 @@ func TestGetSecurityOptSeparator(t *testing.T) { } } +// writeDockerConfig will write a config file into a temporary dir, and return that dir. +// Caller is responsible for deleting the dir and its contents. +func writeDockerConfig(cfg string) (string, error) { + tmpdir, err := ioutil.TempDir("", "dockershim=helpers_test.go=") + if err != nil { + return "", err + } + dir := filepath.Join(tmpdir, ".docker") + if err := os.Mkdir(dir, 0755); err != nil { + return "", err + } + return tmpdir, ioutil.WriteFile(filepath.Join(dir, "config.json"), []byte(cfg), 0644) +} + func TestEnsureSandboxImageExists(t *testing.T) { sandboxImage := "gcr.io/test/image" + registryHost := "https://gcr.io/" + authConfig := dockertypes.AuthConfig{Username: "user", Password: "pass"} + authB64 := base64.StdEncoding.EncodeToString([]byte(fmt.Sprintf("%s:%s", authConfig.Username, authConfig.Password))) + authJSON := fmt.Sprintf("{\"auths\": {\"%s\": {\"auth\": \"%s\"} } }", registryHost, authB64) for desc, test := range map[string]struct { - injectImage bool - injectErr error - calls []string - err bool + injectImage bool + imgNeedsAuth bool + injectErr error + calls []string + err bool + configJSON string }{ "should not pull image when it already exists": { injectImage: true, @@ -271,14 +295,42 @@ func TestEnsureSandboxImageExists(t *testing.T) { calls: []string{"inspect_image"}, err: true, }, + "should return error when image pull needs private auth, but none provided": { + injectImage: true, + imgNeedsAuth: true, + injectErr: libdocker.ImageNotFoundError{ID: "image_id"}, + calls: []string{"inspect_image", "pull"}, + err: true, + }, + "should pull private image using dockerauth if image doesn't exist": { + injectImage: true, + imgNeedsAuth: true, + injectErr: libdocker.ImageNotFoundError{ID: "image_id"}, + calls: []string{"inspect_image", "pull"}, + configJSON: authJSON, + err: false, + }, } { t.Logf("TestCase: %q", desc) _, fakeDocker, _ := newTestDockerService() if test.injectImage { - fakeDocker.InjectImages([]dockertypes.Image{{ID: sandboxImage}}) + images := []dockertypes.Image{{ID: sandboxImage}} + fakeDocker.InjectImages(images) + if test.imgNeedsAuth { + fakeDocker.MakeImagesPrivate(images, authConfig) + } } fakeDocker.InjectError("inspect_image", test.injectErr) - err := ensureSandboxImageExists(fakeDocker, sandboxImage) + + var dockerCfgSearchPath []string + if test.configJSON != "" { + tmpdir, err := writeDockerConfig(test.configJSON) + require.NoError(t, err, "could not create a temp docker config file") + dockerCfgSearchPath = append(dockerCfgSearchPath, filepath.Join(tmpdir, ".docker")) + defer os.RemoveAll(tmpdir) + } + + err := ensureSandboxImageExistsDockerCfg(fakeDocker, sandboxImage, dockerCfgSearchPath) assert.NoError(t, fakeDocker.AssertCalls(test.calls)) assert.Equal(t, test.err, err != nil) } diff --git a/pkg/kubelet/dockershim/libdocker/fake_client.go b/pkg/kubelet/dockershim/libdocker/fake_client.go index 1eac1684f287e..6884f5e155621 100644 --- a/pkg/kubelet/dockershim/libdocker/fake_client.go +++ b/pkg/kubelet/dockershim/libdocker/fake_client.go @@ -55,6 +55,7 @@ type FakeDockerClient struct { ContainerMap map[string]*dockertypes.ContainerJSON ImageInspects map[string]*dockertypes.ImageInspect Images []dockertypes.Image + ImageIDsNeedingAuth map[string]dockertypes.AuthConfig Errors map[string]error called []calledDetail pulled []string @@ -91,8 +92,9 @@ func NewFakeDockerClient() *FakeDockerClient { ContainerMap: make(map[string]*dockertypes.ContainerJSON), Clock: clock.RealClock{}, // default this to true, so that we trace calls, image pulls and container lifecycle - EnableTrace: true, - ImageInspects: make(map[string]*dockertypes.ImageInspect), + EnableTrace: true, + ImageInspects: make(map[string]*dockertypes.ImageInspect), + ImageIDsNeedingAuth: make(map[string]dockertypes.AuthConfig), } } @@ -632,6 +634,14 @@ func (f *FakeDockerClient) Logs(id string, opts dockertypes.ContainerLogsOptions return f.popError("logs") } +func (f *FakeDockerClient) isAuthorizedForImage(image string, auth dockertypes.AuthConfig) bool { + if reqd, exists := f.ImageIDsNeedingAuth[image]; !exists { + return true // no auth needed + } else { + return auth.Username == reqd.Username && auth.Password == reqd.Password + } +} + // PullImage is a test-spy implementation of Interface.PullImage. // It adds an entry "pull" to the internal method call record. func (f *FakeDockerClient) PullImage(image string, auth dockertypes.AuthConfig, opts dockertypes.ImagePullOptions) error { @@ -640,6 +650,10 @@ func (f *FakeDockerClient) PullImage(image string, auth dockertypes.AuthConfig, f.appendCalled(calledDetail{name: "pull"}) err := f.popError("pull") if err == nil { + if !f.isAuthorizedForImage(image, auth) { + return ImageNotFoundError{ID: image} + } + authJson, _ := json.Marshal(auth) inspect := createImageInspectFromRef(image) f.ImageInspects[image] = inspect @@ -720,11 +734,20 @@ func (f *FakeDockerClient) InjectImages(images []dockertypes.Image) { } } +func (f *FakeDockerClient) MakeImagesPrivate(images []dockertypes.Image, auth dockertypes.AuthConfig) { + f.Lock() + defer f.Unlock() + for _, i := range images { + f.ImageIDsNeedingAuth[i.ID] = auth + } +} + func (f *FakeDockerClient) ResetImages() { f.Lock() defer f.Unlock() f.Images = []dockertypes.Image{} f.ImageInspects = make(map[string]*dockertypes.ImageInspect) + f.ImageIDsNeedingAuth = make(map[string]dockertypes.AuthConfig) } func (f *FakeDockerClient) InjectImageInspects(inspects []dockertypes.ImageInspect) { diff --git a/pkg/kubelet/dockershim/libdocker/helpers.go b/pkg/kubelet/dockershim/libdocker/helpers.go index 5dd59557e9f72..5957ff5e2ea11 100644 --- a/pkg/kubelet/dockershim/libdocker/helpers.go +++ b/pkg/kubelet/dockershim/libdocker/helpers.go @@ -112,7 +112,7 @@ func matchImageIDOnly(inspected dockertypes.ImageInspect, image string) bool { digest, isDigested := ref.(dockerref.Digested) if !isDigested { - glog.V(4).Infof("the image reference %q was not a digest reference") + glog.V(4).Infof("the image reference %q was not a digest reference", image) return false } diff --git a/pkg/kubelet/dockershim/remote/BUILD b/pkg/kubelet/dockershim/remote/BUILD index cd014e4eefca3..9256e2fc699de 100644 --- a/pkg/kubelet/dockershim/remote/BUILD +++ b/pkg/kubelet/dockershim/remote/BUILD @@ -18,6 +18,7 @@ go_library( "//pkg/kubelet/apis/cri:go_default_library", "//pkg/kubelet/apis/cri/v1alpha1:go_default_library", "//pkg/kubelet/dockershim:go_default_library", + "//pkg/kubelet/util:go_default_library", "//pkg/util/exec:go_default_library", "//pkg/util/interrupt:go_default_library", "//vendor/github.com/golang/glog:go_default_library", diff --git a/pkg/kubelet/dockershim/remote/docker_server.go b/pkg/kubelet/dockershim/remote/docker_server.go index 15452b22cb2f0..c0828fca81b40 100644 --- a/pkg/kubelet/dockershim/remote/docker_server.go +++ b/pkg/kubelet/dockershim/remote/docker_server.go @@ -18,29 +18,20 @@ package remote import ( "fmt" - "net" - "os" - "syscall" "github.com/golang/glog" "google.golang.org/grpc" runtimeapi "k8s.io/kubernetes/pkg/kubelet/apis/cri/v1alpha1" "k8s.io/kubernetes/pkg/kubelet/dockershim" + "k8s.io/kubernetes/pkg/kubelet/util" "k8s.io/kubernetes/pkg/util/interrupt" ) -const ( - // defaultEndpoint is the default address of dockershim grpc server socket. - defaultAddress = "/var/run/dockershim.sock" - // unixProtocol is the network protocol of unix socket. - unixProtocol = "unix" -) - // DockerServer is the grpc server of dockershim. type DockerServer struct { - // addr is the address to serve on. - addr string + // endpoint is the endpoint to serve on. + endpoint string // service is the docker service which implements runtime and image services. service DockerService // server is the grpc server. @@ -48,24 +39,19 @@ type DockerServer struct { } // NewDockerServer creates the dockershim grpc server. -func NewDockerServer(addr string, s dockershim.DockerService) *DockerServer { +func NewDockerServer(endpoint string, s dockershim.DockerService) *DockerServer { return &DockerServer{ - addr: addr, - service: NewDockerService(s), + endpoint: endpoint, + service: NewDockerService(s), } } // Start starts the dockershim grpc server. func (s *DockerServer) Start() error { glog.V(2).Infof("Start dockershim grpc server") - // Unlink to cleanup the previous socket file. - err := syscall.Unlink(s.addr) - if err != nil && !os.IsNotExist(err) { - return fmt.Errorf("failed to unlink socket file %q: %v", s.addr, err) - } - l, err := net.Listen(unixProtocol, s.addr) + l, err := util.CreateListener(s.endpoint) if err != nil { - return fmt.Errorf("failed to listen on %q: %v", s.addr, err) + return fmt.Errorf("failed to listen on %q: %v", s.endpoint, err) } // Create the grpc server and register runtime and image services. s.server = grpc.NewServer() diff --git a/pkg/kubelet/dockershim/remote/docker_service.go b/pkg/kubelet/dockershim/remote/docker_service.go index 1f83465427a05..4fb0fee41c62f 100644 --- a/pkg/kubelet/dockershim/remote/docker_service.go +++ b/pkg/kubelet/dockershim/remote/docker_service.go @@ -220,3 +220,11 @@ func (d *dockerService) RemoveImage(ctx context.Context, r *runtimeapi.RemoveIma func (d *dockerService) ImageFsInfo(ctx context.Context, r *runtimeapi.ImageFsInfoRequest) (*runtimeapi.ImageFsInfoResponse, error) { return nil, fmt.Errorf("not implemented") } + +func (d *dockerService) ContainerStats(ctx context.Context, r *runtimeapi.ContainerStatsRequest) (*runtimeapi.ContainerStatsResponse, error) { + return nil, fmt.Errorf("not implemented") +} + +func (d *dockerService) ListContainerStats(ctx context.Context, r *runtimeapi.ListContainerStatsRequest) (*runtimeapi.ListContainerStatsResponse, error) { + return nil, fmt.Errorf("not implemented") +} diff --git a/pkg/kubelet/eviction/eviction_manager.go b/pkg/kubelet/eviction/eviction_manager.go index 68a0e3e23fe24..6431a4f23d59c 100644 --- a/pkg/kubelet/eviction/eviction_manager.go +++ b/pkg/kubelet/eviction/eviction_manager.go @@ -131,7 +131,7 @@ func (m *managerImpl) Admit(attrs *lifecycle.PodAdmitAttributes) lifecycle.PodAd } // reject pods when under memory pressure (if pod is best effort), or if under disk pressure. - glog.Warningf("Failed to admit pod %v - %s", format.Pod(attrs.Pod), "node has conditions: %v", m.nodeConditions) + glog.Warningf("Failed to admit pod %s - node has conditions: %v", format.Pod(attrs.Pod), m.nodeConditions) return lifecycle.PodAdmitResult{ Admit: false, Reason: reason, diff --git a/pkg/kubelet/eviction/helpers.go b/pkg/kubelet/eviction/helpers.go index 2f37b19cd08b7..518853dd7674a 100644 --- a/pkg/kubelet/eviction/helpers.go +++ b/pkg/kubelet/eviction/helpers.go @@ -932,7 +932,7 @@ func isSoftEvictionThresholds(thresholds []evictionapi.Threshold, starvedResourc return true } -// isSoftEviction returns true if the thresholds met for the starved resource are only soft thresholds +// isHardEvictionThreshold returns true if eviction should immediately occur func isHardEvictionThreshold(threshold evictionapi.Threshold) bool { return threshold.GracePeriod == time.Duration(0) } diff --git a/pkg/kubelet/images/image_gc_manager.go b/pkg/kubelet/images/image_gc_manager.go index 9ce4d6b8120df..2f15e8b7ea08e 100644 --- a/pkg/kubelet/images/image_gc_manager.go +++ b/pkg/kubelet/images/image_gc_manager.go @@ -274,7 +274,7 @@ func (im *realImageGCManager) GarbageCollect() error { } if freed < amountToFree { - err := fmt.Errorf("failed to garbage collect required amount of images. Wanted to free %d, but freed %d", amountToFree, freed) + err := fmt.Errorf("failed to garbage collect required amount of images. Wanted to free %d bytes, but freed %d bytes", amountToFree, freed) im.recorder.Eventf(im.nodeRef, v1.EventTypeWarning, events.FreeDiskSpaceFailed, err.Error()) return err } @@ -347,7 +347,7 @@ func (im *realImageGCManager) freeSpace(bytesToFree int64, freeTime time.Time) ( } if len(deletionErrors) > 0 { - return spaceFreed, fmt.Errorf("wanted to free %d, but freed %d space with errors in image deletion: %v", bytesToFree, spaceFreed, errors.NewAggregate(deletionErrors)) + return spaceFreed, fmt.Errorf("wanted to free %d bytes, but freed %d bytes space with errors in image deletion: %v", bytesToFree, spaceFreed, errors.NewAggregate(deletionErrors)) } return spaceFreed, nil } diff --git a/pkg/kubelet/kubelet.go b/pkg/kubelet/kubelet.go index f9e5a2b2d00dd..12143e46d4b8c 100644 --- a/pkg/kubelet/kubelet.go +++ b/pkg/kubelet/kubelet.go @@ -17,6 +17,9 @@ limitations under the License. package kubelet import ( + "crypto/tls" + "crypto/x509" + "crypto/x509/pkix" "fmt" "net" "net/http" @@ -49,18 +52,23 @@ import ( "k8s.io/client-go/tools/record" "k8s.io/client-go/util/flowcontrol" "k8s.io/client-go/util/integer" + "k8s.io/kubernetes/cmd/kubelet/app/options" "k8s.io/kubernetes/pkg/api" "k8s.io/kubernetes/pkg/api/v1" + certificates "k8s.io/kubernetes/pkg/apis/certificates/v1beta1" "k8s.io/kubernetes/pkg/apis/componentconfig" componentconfigv1alpha1 "k8s.io/kubernetes/pkg/apis/componentconfig/v1alpha1" "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" + clientcertificates "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/certificates/v1beta1" corelisters "k8s.io/kubernetes/pkg/client/listers/core/v1" "k8s.io/kubernetes/pkg/cloudprovider" "k8s.io/kubernetes/pkg/features" internalapi "k8s.io/kubernetes/pkg/kubelet/apis/cri" "k8s.io/kubernetes/pkg/kubelet/cadvisor" + "k8s.io/kubernetes/pkg/kubelet/certificate" "k8s.io/kubernetes/pkg/kubelet/cm" "k8s.io/kubernetes/pkg/kubelet/config" + "k8s.io/kubernetes/pkg/kubelet/configmap" kubecontainer "k8s.io/kubernetes/pkg/kubelet/container" "k8s.io/kubernetes/pkg/kubelet/dockershim" "k8s.io/kubernetes/pkg/kubelet/dockershim/libdocker" @@ -186,7 +194,7 @@ type KubeletBootstrap interface { } // create and initialize a Kubelet instance -type KubeletBuilder func(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *KubeletDeps, standaloneMode bool, hostnameOverride, nodeIP, dockershimRootDir, providerID string) (KubeletBootstrap, error) +type KubeletBuilder func(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *KubeletDeps, crOptions *options.ContainerRuntimeOptions, standaloneMode bool, hostnameOverride, nodeIP, providerID string) (KubeletBootstrap, error) // KubeletDeps is a bin for things we might consider "injected dependencies" -- objects constructed // at runtime that are necessary for running the Kubelet. This is a temporary solution for grouping @@ -281,7 +289,7 @@ func getRuntimeAndImageServices(config *componentconfig.KubeletConfiguration) (i // NewMainKubelet instantiates a new Kubelet object along with all the required internal modules. // No initialization of Kubelet and its modules should happen here. -func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *KubeletDeps, standaloneMode bool, hostnameOverride, nodeIP, dockershimRootDir, providerID string) (*Kubelet, error) { +func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *KubeletDeps, crOptions *options.ContainerRuntimeOptions, standaloneMode bool, hostnameOverride, nodeIP, providerID string) (*Kubelet, error) { if kubeCfg.RootDirectory == "" { return nil, fmt.Errorf("invalid root directory %q", kubeCfg.RootDirectory) } @@ -304,6 +312,8 @@ func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *Kub hostname := nodeutil.GetHostname(hostnameOverride) // Query the cloud provider for our node name, default to hostname nodeName := types.NodeName(hostname) + cloudIPs := []net.IP{} + cloudNames := []string{} if kubeDeps.Cloud != nil { var err error instances, ok := kubeDeps.Cloud.Instances() @@ -317,6 +327,25 @@ func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *Kub } glog.V(2).Infof("cloud provider determined current node name to be %s", nodeName) + + if utilfeature.DefaultFeatureGate.Enabled(features.RotateKubeletServerCertificate) { + nodeAddresses, err := instances.NodeAddresses(nodeName) + if err != nil { + return nil, fmt.Errorf("failed to get the addresses of the current instance from the cloud provider: %v", err) + } + for _, nodeAddress := range nodeAddresses { + switch nodeAddress.Type { + case v1.NodeExternalIP, v1.NodeInternalIP: + ip := net.ParseIP(nodeAddress.Address) + if ip != nil && !ip.IsLoopback() { + cloudIPs = append(cloudIPs, ip) + } + case v1.NodeExternalDNS, v1.NodeInternalDNS, v1.NodeHostName: + cloudNames = append(cloudNames, nodeAddress.Address) + } + } + } + } if kubeDeps.PodConfig == nil { @@ -459,14 +488,17 @@ func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *Kub secretManager := secret.NewCachingSecretManager( kubeDeps.KubeClient, secret.GetObjectTTLFromNodeFunc(klet.GetNode)) - klet.secretManager = secretManager + configMapManager := configmap.NewCachingConfigMapManager( + kubeDeps.KubeClient, configmap.GetObjectTTLFromNodeFunc(klet.GetNode)) + klet.configMapManager = configMapManager + if klet.experimentalHostUserNamespaceDefaulting { glog.Infof("Experimental host user namespace defaulting is enabled.") } - hairpinMode, err := effectiveHairpinMode(componentconfig.HairpinMode(kubeCfg.HairpinMode), kubeCfg.ContainerRuntime, kubeCfg.NetworkPluginName) + hairpinMode, err := effectiveHairpinMode(componentconfig.HairpinMode(kubeCfg.HairpinMode), kubeCfg.ContainerRuntime, crOptions.NetworkPluginName) if err != nil { // This is a non-recoverable error. Returning it up the callstack will just // lead to retries of the same failure, so just fail hard. @@ -474,7 +506,7 @@ func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *Kub } glog.Infof("Hairpin mode set to %q", hairpinMode) - if plug, err := network.InitNetworkPlugin(kubeDeps.NetworkPlugins, kubeCfg.NetworkPluginName, &criNetworkHost{&networkHost{klet}, &network.NoopPortMappingGetter{}}, hairpinMode, kubeCfg.NonMasqueradeCIDR, int(kubeCfg.NetworkPluginMTU)); err != nil { + if plug, err := network.InitNetworkPlugin(kubeDeps.NetworkPlugins, crOptions.NetworkPluginName, &criNetworkHost{&networkHost{klet}, &network.NoopPortMappingGetter{}}, hairpinMode, kubeCfg.NonMasqueradeCIDR, int(crOptions.NetworkPluginMTU)); err != nil { return nil, err } else { klet.networkPlugin = plug @@ -490,8 +522,8 @@ func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *Kub klet.livenessManager = proberesults.NewManager() klet.podCache = kubecontainer.NewCache() - // podManager is also responsible for keeping secretManager contents up-to-date. - klet.podManager = kubepod.NewBasicPodManager(kubepod.NewBasicMirrorClient(klet.kubeClient), secretManager) + // podManager is also responsible for keeping secretManager and configMapManager contents up-to-date. + klet.podManager = kubepod.NewBasicPodManager(kubepod.NewBasicMirrorClient(klet.kubeClient), secretManager, configMapManager) if kubeCfg.RemoteRuntimeEndpoint != "" { // kubeCfg.RemoteImageEndpoint is same as kubeCfg.RemoteRuntimeEndpoint if not explicitly specified @@ -501,17 +533,17 @@ func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *Kub } // TODO: These need to become arguments to a standalone docker shim. - binDir := kubeCfg.CNIBinDir + binDir := crOptions.CNIBinDir if binDir == "" { - binDir = kubeCfg.NetworkPluginDir + binDir = crOptions.NetworkPluginDir } pluginSettings := dockershim.NetworkPluginSettings{ HairpinMode: hairpinMode, NonMasqueradeCIDR: kubeCfg.NonMasqueradeCIDR, - PluginName: kubeCfg.NetworkPluginName, - PluginConfDir: kubeCfg.CNIConfDir, + PluginName: crOptions.NetworkPluginName, + PluginConfDir: crOptions.CNIConfDir, PluginBinDir: binDir, - MTU: int(kubeCfg.NetworkPluginMTU), + MTU: int(crOptions.NetworkPluginMTU), } // Remote runtime shim just cannot talk back to kubelet, so it doesn't @@ -532,9 +564,9 @@ func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *Kub case "docker": // Create and start the CRI shim running as a grpc server. streamingConfig := getStreamingConfig(kubeCfg, kubeDeps) - ds, err := dockershim.NewDockerService(kubeDeps.DockerClient, kubeCfg.SeccompProfileRoot, kubeCfg.PodInfraContainerImage, - streamingConfig, &pluginSettings, kubeCfg.RuntimeCgroups, kubeCfg.CgroupDriver, kubeCfg.DockerExecHandlerName, dockershimRootDir, - kubeCfg.DockerDisableSharedPID) + ds, err := dockershim.NewDockerService(kubeDeps.DockerClient, kubeCfg.SeccompProfileRoot, crOptions.PodSandboxImage, + streamingConfig, &pluginSettings, kubeCfg.RuntimeCgroups, kubeCfg.CgroupDriver, crOptions.DockerExecHandlerName, + crOptions.DockershimRootDirectory, crOptions.DockerDisableSharedPID) if err != nil { return nil, err } @@ -545,17 +577,10 @@ func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *Kub // kubelet, which handles the requests using DockerService.. klet.criHandler = ds - const ( - // The unix socket for kubelet <-> dockershim communication. - ep = "/var/run/dockershim.sock" - ) - if len(kubeCfg.RemoteRuntimeEndpoint) == 0 { - kubeCfg.RemoteRuntimeEndpoint = ep - } - if len(kubeCfg.RemoteImageEndpoint) == 0 { - kubeCfg.RemoteImageEndpoint = ep - } - + // The unix socket for kubelet <-> dockershim communication. + glog.V(5).Infof("RemoteRuntimeEndpoint: %q, RemoteImageEndpoint: %q", + kubeCfg.RemoteRuntimeEndpoint, + kubeCfg.RemoteImageEndpoint) glog.V(2).Infof("Starting the GRPC server for the docker CRI shim.") server := dockerremote.NewDockerServer(kubeCfg.RemoteRuntimeEndpoint, ds) if err := server.Start(); err != nil { @@ -577,6 +602,9 @@ func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *Kub return nil, fmt.Errorf("unsupported CRI runtime: %q", kubeCfg.ContainerRuntime) } runtimeService, imageService, err := getRuntimeAndImageServices(kubeCfg) + if err != nil { + return nil, err + } runtime, err := kuberuntime.NewKubeGenericRuntimeManager( kubecontainer.FilterEventRecorder(kubeDeps.Recorder), klet.livenessManager, @@ -603,12 +631,12 @@ func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *Kub // rkt uses the legacy, non-CRI, integration. Configure it the old way. // TODO: Include hairpin mode settings in rkt? conf := &rkt.Config{ - Path: kubeCfg.RktPath, - Stage1Image: kubeCfg.RktStage1Image, + Path: crOptions.RktPath, + Stage1Image: crOptions.RktStage1Image, InsecureOptions: "image,ondisk", } runtime, err := rkt.New( - kubeCfg.RktAPIEndpoint, + crOptions.RktAPIEndpoint, conf, klet, kubeDeps.Recorder, @@ -658,6 +686,33 @@ func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *Kub klet.statusManager = status.NewManager(klet.kubeClient, klet.podManager, klet) + if utilfeature.DefaultFeatureGate.Enabled(features.RotateKubeletServerCertificate) && kubeDeps.TLSOptions != nil { + var ips []net.IP + cfgAddress := net.ParseIP(kubeCfg.Address) + if cfgAddress == nil || cfgAddress.IsUnspecified() { + if localIPs, err := allLocalIPsWithoutLoopback(); err != nil { + return nil, err + } else { + ips = localIPs + } + } else { + ips = []net.IP{cfgAddress} + } + ips = append(ips, cloudIPs...) + names := append([]string{klet.GetHostname(), hostnameOverride}, cloudNames...) + klet.serverCertificateManager, err = initializeServerCertificateManager(klet.kubeClient, kubeCfg, klet.nodeName, ips, names) + if err != nil { + return nil, fmt.Errorf("failed to initialize certificate manager: %v", err) + } + kubeDeps.TLSOptions.Config.GetCertificate = func(*tls.ClientHelloInfo) (*tls.Certificate, error) { + cert := klet.serverCertificateManager.Current() + if cert == nil { + return nil, fmt.Errorf("no certificate available") + } + return cert, nil + } + } + klet.probeManager = prober.NewManager( klet.statusManager, klet.livenessManager, @@ -666,7 +721,7 @@ func NewMainKubelet(kubeCfg *componentconfig.KubeletConfiguration, kubeDeps *Kub kubeDeps.Recorder) klet.volumePluginMgr, err = - NewInitializedVolumePluginMgr(klet, secretManager, kubeDeps.VolumePlugins) + NewInitializedVolumePluginMgr(klet, secretManager, configMapManager, kubeDeps.VolumePlugins) if err != nil { return nil, err } @@ -866,9 +921,15 @@ type Kubelet struct { // Secret manager. secretManager secret.Manager + // ConfigMap manager. + configMapManager configmap.Manager + // Cached MachineInfo returned by cadvisor. machineInfo *cadvisorapi.MachineInfo + // Handles certificate rotations. + serverCertificateManager certificate.Manager + // Syncs pods statuses with apiserver; also used as a cache of statuses. statusManager status.Manager @@ -1041,6 +1102,62 @@ type Kubelet struct { dockerLegacyService dockershim.DockerLegacyService } +func initializeServerCertificateManager(kubeClient clientset.Interface, kubeCfg *componentconfig.KubeletConfiguration, nodeName types.NodeName, ips []net.IP, hostnames []string) (certificate.Manager, error) { + var certSigningRequestClient clientcertificates.CertificateSigningRequestInterface + if kubeClient != nil && kubeClient.Certificates() != nil { + certSigningRequestClient = kubeClient.Certificates().CertificateSigningRequests() + } + certificateStore, err := certificate.NewFileStore( + "kubelet-server", + kubeCfg.CertDirectory, + kubeCfg.CertDirectory, + kubeCfg.TLSCertFile, + kubeCfg.TLSPrivateKeyFile) + if err != nil { + return nil, fmt.Errorf("failed to initialize certificate store: %v", err) + } + return certificate.NewManager(&certificate.Config{ + CertificateSigningRequestClient: certSigningRequestClient, + Template: &x509.CertificateRequest{ + Subject: pkix.Name{ + CommonName: string(nodeName), + Organization: []string{"system:nodes"}, + }, + DNSNames: hostnames, + IPAddresses: ips, + }, + Usages: []certificates.KeyUsage{ + certificates.UsageKeyEncipherment, + certificates.UsageServerAuth, + certificates.UsageSigning, + }, + CertificateStore: certificateStore, + }) +} + +func allLocalIPsWithoutLoopback() ([]net.IP, error) { + interfaces, err := net.Interfaces() + if err != nil { + return nil, fmt.Errorf("could not list network interfaces: %v", err) + } + var ips []net.IP + for _, i := range interfaces { + addresses, err := i.Addrs() + if err != nil { + return nil, fmt.Errorf("could not list the addresses for network interface %v: %v\n", i, err) + } + for _, address := range addresses { + switch v := address.(type) { + case *net.IPNet: + if !v.IP.IsLoopback() { + ips = append(ips, v.IP) + } + } + } + } + return ips, nil +} + // setupDataDirs creates: // 1. the root directory // 2. the pods directory @@ -1104,25 +1221,30 @@ func (kl *Kubelet) StartGarbageCollection() { // initializeModules will initialize internal modules that do not require the container runtime to be up. // Note that the modules here must not depend on modules that are not initialized here. func (kl *Kubelet) initializeModules() error { - // Step 1: Prometheus metrics. + // Prometheus metrics. metrics.Register(kl.runtimeCache) - // Step 2: Setup filesystem directories. + // Setup filesystem directories. if err := kl.setupDataDirs(); err != nil { return err } - // Step 3: If the container logs directory does not exist, create it. + // If the container logs directory does not exist, create it. if _, err := os.Stat(ContainerLogsDir); err != nil { if err := kl.os.MkdirAll(ContainerLogsDir, 0755); err != nil { glog.Errorf("Failed to create directory %q: %v", ContainerLogsDir, err) } } - // Step 4: Start the image manager. + // Start the image manager. kl.imageManager.Start() - // Step 5: Start container manager. + // Start the certificate manager. + if utilfeature.DefaultFeatureGate.Enabled(features.RotateKubeletServerCertificate) { + kl.serverCertificateManager.Start() + } + + // Start container manager. node, err := kl.getNodeAnyWay() if err != nil { return fmt.Errorf("Kubelet failed to get node info: %v", err) @@ -1132,17 +1254,17 @@ func (kl *Kubelet) initializeModules() error { return fmt.Errorf("Failed to start ContainerManager %v", err) } - // Step 6: Start out of memory watcher. + // Start out of memory watcher. if err := kl.oomWatcher.Start(kl.nodeRef); err != nil { return fmt.Errorf("Failed to start OOM watcher %v", err) } - // Step 7: Initialize GPUs + // Initialize GPUs if err := kl.gpuManager.Start(); err != nil { glog.Errorf("Failed to start gpuManager %v", err) } - // Step 8: Start resource analyzer + // Start resource analyzer kl.resourceAnalyzer.Start() return nil diff --git a/pkg/kubelet/kubelet_network.go b/pkg/kubelet/kubelet_network.go index 57b5e5846158c..9dc5b956513fc 100644 --- a/pkg/kubelet/kubelet_network.go +++ b/pkg/kubelet/kubelet_network.go @@ -229,8 +229,8 @@ func (kl *Kubelet) parseResolvConf(reader io.Reader) (nameservers []string, sear if len(fields) == 0 { continue } - if fields[0] == "nameserver" { - nameservers = append(nameservers, fields[1:]...) + if fields[0] == "nameserver" && len(fields) >= 2 { + nameservers = append(nameservers, fields[1]) } if fields[0] == "search" { searches = fields[1:] diff --git a/pkg/kubelet/kubelet_network_test.go b/pkg/kubelet/kubelet_network_test.go index 35788008652b9..43fb3c0441101 100644 --- a/pkg/kubelet/kubelet_network_test.go +++ b/pkg/kubelet/kubelet_network_test.go @@ -91,6 +91,7 @@ func TestParseResolvConf(t *testing.T) { {"nameserver\t1.2.3.4", []string{"1.2.3.4"}, []string{}}, {"nameserver \t 1.2.3.4", []string{"1.2.3.4"}, []string{}}, {"nameserver 1.2.3.4\nnameserver 5.6.7.8", []string{"1.2.3.4", "5.6.7.8"}, []string{}}, + {"nameserver 1.2.3.4 #comment", []string{"1.2.3.4"}, []string{}}, {"search foo", []string{}, []string{"foo"}}, {"search foo bar", []string{}, []string{"foo", "bar"}}, {"search foo bar bat\n", []string{}, []string{"foo", "bar", "bat"}}, @@ -112,6 +113,7 @@ func TestParseResolvConf(t *testing.T) { func TestComposeDNSSearch(t *testing.T) { testKubelet := newTestKubelet(t, false /* controllerAttachDetachEnabled */) + defer testKubelet.Cleanup() kubelet := testKubelet.kubelet recorder := record.NewFakeRecorder(20) diff --git a/pkg/kubelet/kubelet_node_status.go b/pkg/kubelet/kubelet_node_status.go index 212577e539141..34e393bb326ae 100644 --- a/pkg/kubelet/kubelet_node_status.go +++ b/pkg/kubelet/kubelet_node_status.go @@ -569,6 +569,10 @@ func (kl *Kubelet) setNodeStatusMachineInfo(node *v1.Node) { if res, exists := allocatableReservation[k]; exists { value.Sub(res) } + if value.Sign() < 0 { + // Negative Allocatable resources don't make sense. + value.Set(0) + } node.Status.Allocatable[k] = value } } diff --git a/pkg/kubelet/kubelet_node_status_test.go b/pkg/kubelet/kubelet_node_status_test.go index 6d57dba0ce26a..96161b5de5941 100644 --- a/pkg/kubelet/kubelet_node_status_test.go +++ b/pkg/kubelet/kubelet_node_status_test.go @@ -1100,3 +1100,67 @@ func TestTryRegisterWithApiServer(t *testing.T) { } } } + +func TestUpdateNewNodeStatusTooLargeReservation(t *testing.T) { + // generate one more than maxImagesInNodeStatus in inputImageList + inputImageList, _ := generateTestingImageList(maxImagesInNodeStatus + 1) + testKubelet := newTestKubeletWithImageList( + t, inputImageList, false /* controllerAttachDetachEnabled */) + defer testKubelet.Cleanup() + kubelet := testKubelet.kubelet + kubelet.containerManager = &localCM{ + ContainerManager: cm.NewStubContainerManager(), + allocatable: v1.ResourceList{ + v1.ResourceCPU: *resource.NewMilliQuantity(40000, resource.DecimalSI), + }, + } + kubeClient := testKubelet.fakeKubeClient + existingNode := v1.Node{ObjectMeta: metav1.ObjectMeta{Name: testKubeletHostname}} + kubeClient.ReactionChain = fake.NewSimpleClientset(&v1.NodeList{Items: []v1.Node{existingNode}}).ReactionChain + machineInfo := &cadvisorapi.MachineInfo{ + MachineID: "123", + SystemUUID: "abc", + BootID: "1b3", + NumCores: 2, + MemoryCapacity: 10E9, // 10G + } + mockCadvisor := testKubelet.fakeCadvisor + mockCadvisor.On("Start").Return(nil) + mockCadvisor.On("MachineInfo").Return(machineInfo, nil) + versionInfo := &cadvisorapi.VersionInfo{ + KernelVersion: "3.16.0-0.bpo.4-amd64", + ContainerOsVersion: "Debian GNU/Linux 7 (wheezy)", + } + mockCadvisor.On("VersionInfo").Return(versionInfo, nil) + + // Make kubelet report that it has sufficient disk space. + require.NoError(t, updateDiskSpacePolicy(kubelet, mockCadvisor, 500, 500, 200, 200, 100, 100)) + + expectedNode := &v1.Node{ + ObjectMeta: metav1.ObjectMeta{Name: testKubeletHostname}, + Spec: v1.NodeSpec{}, + Status: v1.NodeStatus{ + Capacity: v1.ResourceList{ + v1.ResourceCPU: *resource.NewMilliQuantity(2000, resource.DecimalSI), + v1.ResourceMemory: *resource.NewQuantity(10E9, resource.BinarySI), + v1.ResourcePods: *resource.NewQuantity(0, resource.DecimalSI), + }, + Allocatable: v1.ResourceList{ + v1.ResourceCPU: *resource.NewMilliQuantity(0, resource.DecimalSI), + v1.ResourceMemory: *resource.NewQuantity(10E9, resource.BinarySI), + v1.ResourcePods: *resource.NewQuantity(0, resource.DecimalSI), + }, + }, + } + + kubelet.updateRuntimeUp() + assert.NoError(t, kubelet.updateNodeStatus()) + actions := kubeClient.Actions() + require.Len(t, actions, 2) + require.True(t, actions[1].Matches("patch", "nodes")) + require.Equal(t, actions[1].GetSubresource(), "status") + + updatedNode, err := applyNodeStatusPatch(&existingNode, actions[1].(core.PatchActionImpl).GetPatch()) + assert.NoError(t, err) + assert.True(t, apiequality.Semantic.DeepEqual(expectedNode.Status.Allocatable, updatedNode.Status.Allocatable), "%s", diff.ObjectDiff(expectedNode.Status.Allocatable, updatedNode.Status.Allocatable)) +} diff --git a/pkg/kubelet/kubelet_pods.go b/pkg/kubelet/kubelet_pods.go index 245a8b5bec266..e4c1aa57380d8 100644 --- a/pkg/kubelet/kubelet_pods.go +++ b/pkg/kubelet/kubelet_pods.go @@ -114,7 +114,7 @@ func makeMounts(pod *v1.Pod, podDir string, container *v1.Container, hostName, h // - container is not already mounting on /etc/hosts // When the pause container is being created, its IP is still unknown. Hence, PodIP will not have been set. // OS is not Windows - mountEtcHostsFile := (pod.Spec.SecurityContext == nil || !pod.Spec.HostNetwork) && len(podIP) > 0 && runtime.GOOS != "windows" + mountEtcHostsFile := !pod.Spec.HostNetwork && len(podIP) > 0 && runtime.GOOS != "windows" glog.V(3).Infof("container: %v/%v/%v podIP: %q creating hosts mount: %v", pod.Namespace, pod.Name, container.Name, podIP, mountEtcHostsFile) mounts := []kubecontainer.Mount{} for _, mount := range container.VolumeMounts { @@ -446,7 +446,7 @@ func (kl *Kubelet) makeEnvironmentVariables(pod *v1.Pod, container *v1.Container return result, fmt.Errorf("Couldn't get configMap %v/%v, no kubeClient defined", pod.Namespace, name) } optional := cm.Optional != nil && *cm.Optional - configMap, err = kl.kubeClient.Core().ConfigMaps(pod.Namespace).Get(name, metav1.GetOptions{}) + configMap, err = kl.configMapManager.GetConfigMap(pod.Namespace, name) if err != nil { if errors.IsNotFound(err) && optional { // ignore error when marked optional @@ -554,7 +554,7 @@ func (kl *Kubelet) makeEnvironmentVariables(pod *v1.Pod, container *v1.Container if kl.kubeClient == nil { return result, fmt.Errorf("Couldn't get configMap %v/%v, no kubeClient defined", pod.Namespace, name) } - configMap, err = kl.kubeClient.Core().ConfigMaps(pod.Namespace).Get(name, metav1.GetOptions{}) + configMap, err = kl.configMapManager.GetConfigMap(pod.Namespace, name) if err != nil { if errors.IsNotFound(err) && optional { // ignore error when marked optional diff --git a/pkg/kubelet/kubelet_test.go b/pkg/kubelet/kubelet_test.go index 00e3a9340ca9b..a2c63c30d8a66 100644 --- a/pkg/kubelet/kubelet_test.go +++ b/pkg/kubelet/kubelet_test.go @@ -46,6 +46,7 @@ import ( cadvisortest "k8s.io/kubernetes/pkg/kubelet/cadvisor/testing" "k8s.io/kubernetes/pkg/kubelet/cm" "k8s.io/kubernetes/pkg/kubelet/config" + "k8s.io/kubernetes/pkg/kubelet/configmap" kubecontainer "k8s.io/kubernetes/pkg/kubelet/container" containertest "k8s.io/kubernetes/pkg/kubelet/container/testing" "k8s.io/kubernetes/pkg/kubelet/eviction" @@ -208,7 +209,9 @@ func newTestKubeletWithImageList( fakeMirrorClient := podtest.NewFakeMirrorClient() secretManager := secret.NewSimpleSecretManager(kubelet.kubeClient) kubelet.secretManager = secretManager - kubelet.podManager = kubepod.NewBasicPodManager(fakeMirrorClient, kubelet.secretManager) + configMapManager := configmap.NewSimpleConfigMapManager(kubelet.kubeClient) + kubelet.configMapManager = configMapManager + kubelet.podManager = kubepod.NewBasicPodManager(fakeMirrorClient, kubelet.secretManager, kubelet.configMapManager) kubelet.statusManager = status.NewManager(fakeKubeClient, kubelet.podManager, &statustest.FakePodDeletionSafetyProvider{}) diskSpaceManager, err := newDiskSpaceManager(mockCadvisor, DiskSpacePolicy{}) if err != nil { @@ -276,7 +279,7 @@ func newTestKubeletWithImageList( plug := &volumetest.FakeVolumePlugin{PluginName: "fake", Host: nil} kubelet.volumePluginMgr, err = - NewInitializedVolumePluginMgr(kubelet, kubelet.secretManager, []volume.VolumePlugin{plug}) + NewInitializedVolumePluginMgr(kubelet, kubelet.secretManager, kubelet.configMapManager, []volume.VolumePlugin{plug}) require.NoError(t, err, "Failed to initialize VolumePluginMgr") kubelet.mounter = &mount.FakeMounter{} diff --git a/pkg/kubelet/kubelet_volumes.go b/pkg/kubelet/kubelet_volumes.go index 32b952b0364df..66e8d2649b60d 100644 --- a/pkg/kubelet/kubelet_volumes.go +++ b/pkg/kubelet/kubelet_volumes.go @@ -63,7 +63,7 @@ func (kl *Kubelet) podVolumesExist(podUID types.UID) bool { // newVolumeMounterFromPlugins attempts to find a plugin by volume spec, pod // and volume options and then creates a Mounter. -// Returns a valid Unmounter or an error. +// Returns a valid mounter or an error. func (kl *Kubelet) newVolumeMounterFromPlugins(spec *volume.Spec, pod *v1.Pod, opts volume.VolumeOptions) (volume.Mounter, error) { plugin, err := kl.volumePluginMgr.FindPluginBySpec(spec) if err != nil { @@ -79,8 +79,7 @@ func (kl *Kubelet) newVolumeMounterFromPlugins(spec *volume.Spec, pod *v1.Pod, o // cleanupOrphanedPodDirs removes the volumes of pods that should not be // running and that have no containers running. Note that we roll up logs here since it runs in the main loop. -func (kl *Kubelet) cleanupOrphanedPodDirs( - pods []*v1.Pod, runningPods []*kubecontainer.Pod) error { +func (kl *Kubelet) cleanupOrphanedPodDirs(pods []*v1.Pod, runningPods []*kubecontainer.Pod) error { allPods := sets.NewString() for _, pod := range pods { allPods.Insert(string(pod.UID)) diff --git a/pkg/kubelet/kubelet_volumes_test.go b/pkg/kubelet/kubelet_volumes_test.go index 54eb794e341dc..739bdbe0645fd 100644 --- a/pkg/kubelet/kubelet_volumes_test.go +++ b/pkg/kubelet/kubelet_volumes_test.go @@ -33,6 +33,7 @@ import ( func TestListVolumesForPod(t *testing.T) { testKubelet := newTestKubelet(t, false /* controllerAttachDetachEnabled */) + defer testKubelet.Cleanup() kubelet := testKubelet.kubelet pod := podWithUidNameNsSpec("12345678", "foo", "test", v1.PodSpec{ diff --git a/pkg/kubelet/kuberuntime/instrumented_services.go b/pkg/kubelet/kuberuntime/instrumented_services.go index 6897ca7f7ff07..6379576b34d65 100644 --- a/pkg/kubelet/kuberuntime/instrumented_services.go +++ b/pkg/kubelet/kuberuntime/instrumented_services.go @@ -203,6 +203,24 @@ func (in instrumentedRuntimeService) ListPodSandbox(filter *runtimeapi.PodSandbo return out, err } +func (in instrumentedRuntimeService) ContainerStats(req *runtimeapi.ContainerStatsRequest) (*runtimeapi.ContainerStatsResponse, error) { + const operation = "container_stats" + defer recordOperation(operation, time.Now()) + + out, err := in.service.ContainerStats(req) + recordError(operation, err) + return out, err +} + +func (in instrumentedRuntimeService) ListContainerStats(req *runtimeapi.ListContainerStatsRequest) (*runtimeapi.ListContainerStatsResponse, error) { + const operation = "list_container_stats" + defer recordOperation(operation, time.Now()) + + out, err := in.service.ListContainerStats(req) + recordError(operation, err) + return out, err +} + func (in instrumentedRuntimeService) PortForward(req *runtimeapi.PortForwardRequest) (*runtimeapi.PortForwardResponse, error) { const operation = "port_forward" defer recordOperation(operation, time.Now()) @@ -257,11 +275,11 @@ func (in instrumentedImageManagerService) RemoveImage(image *runtimeapi.ImageSpe return err } -func (in instrumentedImageManagerService) ImageFsInfo() (*runtimeapi.FsInfo, error) { +func (in instrumentedImageManagerService) ImageFsInfo(req *runtimeapi.ImageFsInfoRequest) (*runtimeapi.ImageFsInfoResponse, error) { const operation = "image_fs_info" defer recordOperation(operation, time.Now()) - fsInfo, err := in.service.ImageFsInfo() + fsInfo, err := in.service.ImageFsInfo(req) recordError(operation, err) return fsInfo, nil } diff --git a/pkg/kubelet/metrics/metrics.go b/pkg/kubelet/metrics/metrics.go index a006dc497a1c0..1b73082c09829 100644 --- a/pkg/kubelet/metrics/metrics.go +++ b/pkg/kubelet/metrics/metrics.go @@ -26,21 +26,18 @@ import ( ) const ( - KubeletSubsystem = "kubelet" - PodWorkerLatencyKey = "pod_worker_latency_microseconds" - SyncPodsLatencyKey = "sync_pods_latency_microseconds" - PodStartLatencyKey = "pod_start_latency_microseconds" - PodStatusLatencyKey = "generate_pod_status_latency_microseconds" - ContainerManagerOperationsKey = "container_manager_latency_microseconds" - CgroupManagerOperationsKey = "cgroup_manager_latency_microseconds" - DockerOperationsLatencyKey = "docker_operations_latency_microseconds" - DockerOperationsKey = "docker_operations" - DockerOperationsErrorsKey = "docker_operations_errors" - DockerOperationsTimeoutKey = "docker_operations_timeout" - PodWorkerStartLatencyKey = "pod_worker_start_latency_microseconds" - PLEGRelistLatencyKey = "pleg_relist_latency_microseconds" - PLEGRelistIntervalKey = "pleg_relist_interval_microseconds" - EvictionStatsAgeKey = "eviction_stats_age_microseconds" + KubeletSubsystem = "kubelet" + PodWorkerLatencyKey = "pod_worker_latency_microseconds" + PodStartLatencyKey = "pod_start_latency_microseconds" + CgroupManagerOperationsKey = "cgroup_manager_latency_microseconds" + DockerOperationsLatencyKey = "docker_operations_latency_microseconds" + DockerOperationsKey = "docker_operations" + DockerOperationsErrorsKey = "docker_operations_errors" + DockerOperationsTimeoutKey = "docker_operations_timeout" + PodWorkerStartLatencyKey = "pod_worker_start_latency_microseconds" + PLEGRelistLatencyKey = "pleg_relist_latency_microseconds" + PLEGRelistIntervalKey = "pleg_relist_interval_microseconds" + EvictionStatsAgeKey = "eviction_stats_age_microseconds" // Metrics keys of remote runtime operations RuntimeOperationsKey = "runtime_operations" RuntimeOperationsLatencyKey = "runtime_operations_latency_microseconds" @@ -63,13 +60,6 @@ var ( }, []string{"operation_type"}, ) - SyncPodsLatency = prometheus.NewSummary( - prometheus.SummaryOpts{ - Subsystem: KubeletSubsystem, - Name: SyncPodsLatencyKey, - Help: "Latency in microseconds to sync all pods.", - }, - ) PodStartLatency = prometheus.NewSummary( prometheus.SummaryOpts{ Subsystem: KubeletSubsystem, @@ -77,21 +67,6 @@ var ( Help: "Latency in microseconds for a single pod to go from pending to running. Broken down by podname.", }, ) - PodStatusLatency = prometheus.NewSummary( - prometheus.SummaryOpts{ - Subsystem: KubeletSubsystem, - Name: PodStatusLatencyKey, - Help: "Latency in microseconds to generate status for a single pod.", - }, - ) - ContainerManagerLatency = prometheus.NewSummaryVec( - prometheus.SummaryOpts{ - Subsystem: KubeletSubsystem, - Name: ContainerManagerOperationsKey, - Help: "Latency in microseconds for container manager operations. Broken down by method.", - }, - []string{"operation_type"}, - ) CgroupManagerLatency = prometheus.NewSummaryVec( prometheus.SummaryOpts{ Subsystem: KubeletSubsystem, @@ -197,11 +172,8 @@ func Register(containerCache kubecontainer.RuntimeCache) { registerMetrics.Do(func() { prometheus.MustRegister(PodWorkerLatency) prometheus.MustRegister(PodStartLatency) - prometheus.MustRegister(PodStatusLatency) prometheus.MustRegister(DockerOperationsLatency) - prometheus.MustRegister(ContainerManagerLatency) prometheus.MustRegister(CgroupManagerLatency) - prometheus.MustRegister(SyncPodsLatency) prometheus.MustRegister(PodWorkerStartLatency) prometheus.MustRegister(ContainersPerPodCount) prometheus.MustRegister(DockerOperations) diff --git a/pkg/kubelet/network/kubenet/kubenet_linux.go b/pkg/kubelet/network/kubenet/kubenet_linux.go index 86224c3e46e2c..2b9ab97bb0111 100644 --- a/pkg/kubelet/network/kubenet/kubenet_linux.go +++ b/pkg/kubelet/network/kubenet/kubenet_linux.go @@ -179,12 +179,14 @@ func (plugin *kubenetNetworkPlugin) Init(host network.Host, hairpinMode componen // TODO: move thic logic into cni bridge plugin and remove this from kubenet func (plugin *kubenetNetworkPlugin) ensureMasqRule() error { - if _, err := plugin.iptables.EnsureRule(utiliptables.Append, utiliptables.TableNAT, utiliptables.ChainPostrouting, - "-m", "comment", "--comment", "kubenet: SNAT for outbound traffic from cluster", - "-m", "addrtype", "!", "--dst-type", "LOCAL", - "!", "-d", plugin.nonMasqueradeCIDR, - "-j", "MASQUERADE"); err != nil { - return fmt.Errorf("Failed to ensure that %s chain %s jumps to MASQUERADE: %v", utiliptables.TableNAT, utiliptables.ChainPostrouting, err) + if plugin.nonMasqueradeCIDR != "0.0.0.0/0" { + if _, err := plugin.iptables.EnsureRule(utiliptables.Append, utiliptables.TableNAT, utiliptables.ChainPostrouting, + "-m", "comment", "--comment", "kubenet: SNAT for outbound traffic from cluster", + "-m", "addrtype", "!", "--dst-type", "LOCAL", + "!", "-d", plugin.nonMasqueradeCIDR, + "-j", "MASQUERADE"); err != nil { + return fmt.Errorf("Failed to ensure that %s chain %s jumps to MASQUERADE: %v", utiliptables.TableNAT, utiliptables.ChainPostrouting, err) + } } return nil } diff --git a/pkg/kubelet/pod/BUILD b/pkg/kubelet/pod/BUILD index 999d6dfeadac4..48e9e30b82750 100644 --- a/pkg/kubelet/pod/BUILD +++ b/pkg/kubelet/pod/BUILD @@ -18,6 +18,7 @@ go_library( deps = [ "//pkg/api/v1:go_default_library", "//pkg/client/clientset_generated/clientset:go_default_library", + "//pkg/kubelet/configmap:go_default_library", "//pkg/kubelet/container:go_default_library", "//pkg/kubelet/secret:go_default_library", "//pkg/kubelet/types:go_default_library", @@ -38,6 +39,7 @@ go_test( tags = ["automanaged"], deps = [ "//pkg/api/v1:go_default_library", + "//pkg/kubelet/configmap:go_default_library", "//pkg/kubelet/container:go_default_library", "//pkg/kubelet/pod/testing:go_default_library", "//pkg/kubelet/secret:go_default_library", diff --git a/pkg/kubelet/pod/pod_manager.go b/pkg/kubelet/pod/pod_manager.go index dd069b0fa3ee3..f2a3f94470bc1 100644 --- a/pkg/kubelet/pod/pod_manager.go +++ b/pkg/kubelet/pod/pod_manager.go @@ -21,6 +21,7 @@ import ( "k8s.io/apimachinery/pkg/types" "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/pkg/kubelet/configmap" kubecontainer "k8s.io/kubernetes/pkg/kubelet/container" "k8s.io/kubernetes/pkg/kubelet/secret" ) @@ -113,17 +114,19 @@ type basicManager struct { // Mirror pod UID to pod UID map. translationByUID map[types.UID]types.UID - // basicManager is keeping secretManager up-to-date. - secretManager secret.Manager + // basicManager is keeping secretManager and configMapManager up-to-date. + secretManager secret.Manager + configMapManager configmap.Manager // A mirror pod client to create/delete mirror pods. MirrorClient } // NewBasicPodManager returns a functional Manager. -func NewBasicPodManager(client MirrorClient, secretManager secret.Manager) Manager { +func NewBasicPodManager(client MirrorClient, secretManager secret.Manager, configMapManager configmap.Manager) Manager { pm := &basicManager{} pm.secretManager = secretManager + pm.configMapManager = configMapManager pm.MirrorClient = client pm.SetPods(nil) return pm @@ -163,6 +166,11 @@ func (pm *basicManager) updatePodsInternal(pods ...*v1.Pod) { // not register pod, as it doesn't really matter. pm.secretManager.RegisterPod(pod) } + if pm.configMapManager != nil { + // TODO: Consider detecting only status update and in such case do + // not register pod, as it doesn't really matter. + pm.configMapManager.RegisterPod(pod) + } podFullName := kubecontainer.GetPodFullName(pod) if IsMirrorPod(pod) { pm.mirrorPodByUID[pod.UID] = pod @@ -186,6 +194,9 @@ func (pm *basicManager) DeletePod(pod *v1.Pod) { if pm.secretManager != nil { pm.secretManager.UnregisterPod(pod) } + if pm.configMapManager != nil { + pm.configMapManager.UnregisterPod(pod) + } podFullName := kubecontainer.GetPodFullName(pod) if IsMirrorPod(pod) { delete(pm.mirrorPodByUID, pod.UID) diff --git a/pkg/kubelet/pod/pod_manager_test.go b/pkg/kubelet/pod/pod_manager_test.go index 06dab024b5dcc..cb17725d52823 100644 --- a/pkg/kubelet/pod/pod_manager_test.go +++ b/pkg/kubelet/pod/pod_manager_test.go @@ -23,6 +23,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/types" "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/pkg/kubelet/configmap" podtest "k8s.io/kubernetes/pkg/kubelet/pod/testing" "k8s.io/kubernetes/pkg/kubelet/secret" kubetypes "k8s.io/kubernetes/pkg/kubelet/types" @@ -32,7 +33,8 @@ import ( func newTestManager() (*basicManager, *podtest.FakeMirrorClient) { fakeMirrorClient := podtest.NewFakeMirrorClient() secretManager := secret.NewFakeManager() - manager := NewBasicPodManager(fakeMirrorClient, secretManager).(*basicManager) + configMapManager := configmap.NewFakeManager() + manager := NewBasicPodManager(fakeMirrorClient, secretManager, configMapManager).(*basicManager) return manager, fakeMirrorClient } diff --git a/pkg/kubelet/prober/common_test.go b/pkg/kubelet/prober/common_test.go index 409dbdf4236ae..0dc4e70bf0585 100644 --- a/pkg/kubelet/prober/common_test.go +++ b/pkg/kubelet/prober/common_test.go @@ -99,7 +99,7 @@ func setTestProbe(pod *v1.Pod, probeType probeType, probeSpec v1.Probe) { func newTestManager() *manager { refManager := kubecontainer.NewRefManager() refManager.SetRef(testContainerID, &v1.ObjectReference{}) // Suppress prober warnings. - podManager := kubepod.NewBasicPodManager(nil, nil) + podManager := kubepod.NewBasicPodManager(nil, nil, nil) // Add test pod to pod manager, so that status manager can get the pod from pod manager if needed. podManager.AddPod(getTestPod()) m := NewManager( diff --git a/pkg/kubelet/prober/worker_test.go b/pkg/kubelet/prober/worker_test.go index da4a523a1dc0a..ccb21556fab99 100644 --- a/pkg/kubelet/prober/worker_test.go +++ b/pkg/kubelet/prober/worker_test.go @@ -118,7 +118,7 @@ func TestDoProbe(t *testing.T) { } // Clean up. - m.statusManager = status.NewManager(&fake.Clientset{}, kubepod.NewBasicPodManager(nil, nil), &statustest.FakePodDeletionSafetyProvider{}) + m.statusManager = status.NewManager(&fake.Clientset{}, kubepod.NewBasicPodManager(nil, nil, nil), &statustest.FakePodDeletionSafetyProvider{}) resultsManager(m, probeType).Remove(testContainerID) } } diff --git a/pkg/kubelet/remote/BUILD b/pkg/kubelet/remote/BUILD index 65b6fe98b93a4..fabc990175cd3 100644 --- a/pkg/kubelet/remote/BUILD +++ b/pkg/kubelet/remote/BUILD @@ -19,6 +19,7 @@ go_library( deps = [ "//pkg/kubelet/apis/cri:go_default_library", "//pkg/kubelet/apis/cri/v1alpha1:go_default_library", + "//pkg/kubelet/util:go_default_library", "//pkg/util/exec:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/golang.org/x/net/context:go_default_library", diff --git a/pkg/kubelet/remote/remote_image.go b/pkg/kubelet/remote/remote_image.go index f6ea37594abc5..3ad26db52e4ac 100644 --- a/pkg/kubelet/remote/remote_image.go +++ b/pkg/kubelet/remote/remote_image.go @@ -26,6 +26,7 @@ import ( internalapi "k8s.io/kubernetes/pkg/kubelet/apis/cri" runtimeapi "k8s.io/kubernetes/pkg/kubelet/apis/cri/v1alpha1" + "k8s.io/kubernetes/pkg/kubelet/util" ) // RemoteImageService is a gRPC implementation of internalapi.ImageManagerService. @@ -35,9 +36,14 @@ type RemoteImageService struct { } // NewRemoteImageService creates a new internalapi.ImageManagerService. -func NewRemoteImageService(addr string, connectionTimeout time.Duration) (internalapi.ImageManagerService, error) { - glog.V(3).Infof("Connecting to image service %s", addr) - conn, err := grpc.Dial(addr, grpc.WithInsecure(), grpc.WithTimeout(connectionTimeout), grpc.WithDialer(dial)) +func NewRemoteImageService(endpoint string, connectionTimeout time.Duration) (internalapi.ImageManagerService, error) { + glog.V(3).Infof("Connecting to image service %s", endpoint) + addr, dailer, err := util.GetAddressAndDialer(endpoint) + if err != nil { + return nil, err + } + + conn, err := grpc.Dial(addr, grpc.WithInsecure(), grpc.WithTimeout(connectionTimeout), grpc.WithDialer(dailer)) if err != nil { glog.Errorf("Connect remote image service %s failed: %v", addr, err) return nil, err @@ -129,6 +135,6 @@ func (r *RemoteImageService) RemoveImage(image *runtimeapi.ImageSpec) error { } // ImageFsInfo returns information of the filesystem that is used to store images. -func (r *RemoteImageService) ImageFsInfo() (*runtimeapi.FsInfo, error) { +func (r *RemoteImageService) ImageFsInfo(req *runtimeapi.ImageFsInfoRequest) (*runtimeapi.ImageFsInfoResponse, error) { return nil, fmt.Errorf("not implemented") } diff --git a/pkg/kubelet/remote/remote_runtime.go b/pkg/kubelet/remote/remote_runtime.go index f1f7bf25935d4..e7f57bca4e99f 100644 --- a/pkg/kubelet/remote/remote_runtime.go +++ b/pkg/kubelet/remote/remote_runtime.go @@ -27,6 +27,7 @@ import ( internalapi "k8s.io/kubernetes/pkg/kubelet/apis/cri" runtimeapi "k8s.io/kubernetes/pkg/kubelet/apis/cri/v1alpha1" + "k8s.io/kubernetes/pkg/kubelet/util" utilexec "k8s.io/kubernetes/pkg/util/exec" ) @@ -37,9 +38,13 @@ type RemoteRuntimeService struct { } // NewRemoteRuntimeService creates a new internalapi.RuntimeService. -func NewRemoteRuntimeService(addr string, connectionTimout time.Duration) (internalapi.RuntimeService, error) { - glog.Infof("Connecting to runtime service %s", addr) - conn, err := grpc.Dial(addr, grpc.WithInsecure(), grpc.WithTimeout(connectionTimout), grpc.WithDialer(dial)) +func NewRemoteRuntimeService(endpoint string, connectionTimout time.Duration) (internalapi.RuntimeService, error) { + glog.Infof("Connecting to runtime service %s", endpoint) + addr, dailer, err := util.GetAddressAndDialer(endpoint) + if err != nil { + return nil, err + } + conn, err := grpc.Dial(addr, grpc.WithInsecure(), grpc.WithTimeout(connectionTimout), grpc.WithDialer(dailer)) if err != nil { glog.Errorf("Connect remote runtime %s failed: %v", addr, err) return nil, err @@ -415,3 +420,11 @@ func (r *RemoteRuntimeService) Status() (*runtimeapi.RuntimeStatus, error) { return resp.Status, nil } + +func (r *RemoteRuntimeService) ContainerStats(req *runtimeapi.ContainerStatsRequest) (*runtimeapi.ContainerStatsResponse, error) { + return nil, fmt.Errorf("Not implemented") +} + +func (r *RemoteRuntimeService) ListContainerStats(req *runtimeapi.ListContainerStatsRequest) (*runtimeapi.ListContainerStatsResponse, error) { + return nil, fmt.Errorf("Not implemented") +} diff --git a/pkg/kubelet/remote/utils.go b/pkg/kubelet/remote/utils.go index 51e45f3714b47..05362bd3d4218 100644 --- a/pkg/kubelet/remote/utils.go +++ b/pkg/kubelet/remote/utils.go @@ -18,7 +18,6 @@ package remote import ( "fmt" - "net" "time" "golang.org/x/net/context" @@ -26,11 +25,6 @@ import ( runtimeapi "k8s.io/kubernetes/pkg/kubelet/apis/cri/v1alpha1" ) -// dial creates a net.Conn by unix socket addr. -func dial(addr string, timeout time.Duration) (net.Conn, error) { - return net.DialTimeout("unix", addr, timeout) -} - // getContextWithTimeout returns a context with timeout. func getContextWithTimeout(timeout time.Duration) (context.Context, context.CancelFunc) { return context.WithTimeout(context.Background(), timeout) diff --git a/pkg/kubelet/runonce_test.go b/pkg/kubelet/runonce_test.go index 99d932b7ac8d1..d23a79f3a7adc 100644 --- a/pkg/kubelet/runonce_test.go +++ b/pkg/kubelet/runonce_test.go @@ -34,6 +34,7 @@ import ( "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/fake" cadvisortest "k8s.io/kubernetes/pkg/kubelet/cadvisor/testing" "k8s.io/kubernetes/pkg/kubelet/cm" + "k8s.io/kubernetes/pkg/kubelet/configmap" kubecontainer "k8s.io/kubernetes/pkg/kubelet/container" containertest "k8s.io/kubernetes/pkg/kubelet/container/testing" "k8s.io/kubernetes/pkg/kubelet/eviction" @@ -63,8 +64,9 @@ func TestRunOnce(t *testing.T) { Capacity: 10 * mb, }, nil) fakeSecretManager := secret.NewFakeManager() + fakeConfigMapManager := configmap.NewFakeManager() podManager := kubepod.NewBasicPodManager( - podtest.NewFakeMirrorClient(), fakeSecretManager) + podtest.NewFakeMirrorClient(), fakeSecretManager, fakeConfigMapManager) diskSpaceManager, _ := newDiskSpaceManager(cadvisor, DiskSpacePolicy{}) fakeRuntime := &containertest.FakeRuntime{} basePath, err := utiltesting.MkTmpdir("kubelet") @@ -93,7 +95,7 @@ func TestRunOnce(t *testing.T) { plug := &volumetest.FakeVolumePlugin{PluginName: "fake", Host: nil} kb.volumePluginMgr, err = - NewInitializedVolumePluginMgr(kb, fakeSecretManager, []volume.VolumePlugin{plug}) + NewInitializedVolumePluginMgr(kb, fakeSecretManager, fakeConfigMapManager, []volume.VolumePlugin{plug}) if err != nil { t.Fatalf("failed to initialize VolumePluginMgr: %v", err) } diff --git a/pkg/kubelet/server/server.go b/pkg/kubelet/server/server.go index bbb04dc2fb94c..a633d3fefda4e 100644 --- a/pkg/kubelet/server/server.go +++ b/pkg/kubelet/server/server.go @@ -134,6 +134,9 @@ func ListenAndServeKubeletServer( } if tlsOptions != nil { s.TLSConfig = tlsOptions.Config + // Passing empty strings as the cert and key files means no + // cert/keys are specified and GetCertificate in the TLSConfig + // should be called instead. glog.Fatal(s.ListenAndServeTLS(tlsOptions.CertFile, tlsOptions.KeyFile)) } else { glog.Fatal(s.ListenAndServe()) diff --git a/pkg/kubelet/status/BUILD b/pkg/kubelet/status/BUILD index 20ef87777a12f..0c2a9a0173481 100644 --- a/pkg/kubelet/status/BUILD +++ b/pkg/kubelet/status/BUILD @@ -48,6 +48,7 @@ go_test( "//pkg/api/v1/pod:go_default_library", "//pkg/client/clientset_generated/clientset:go_default_library", "//pkg/client/clientset_generated/clientset/fake:go_default_library", + "//pkg/kubelet/configmap:go_default_library", "//pkg/kubelet/container:go_default_library", "//pkg/kubelet/pod:go_default_library", "//pkg/kubelet/pod/testing:go_default_library", diff --git a/pkg/kubelet/status/status_manager.go b/pkg/kubelet/status/status_manager.go index 03cdbf3524599..a2047a8b544ea 100644 --- a/pkg/kubelet/status/status_manager.go +++ b/pkg/kubelet/status/status_manager.go @@ -483,7 +483,10 @@ func (m *manager) needsUpdate(uid types.UID, status versionedPodStatus) bool { } func (m *manager) canBeDeleted(pod *v1.Pod, status v1.PodStatus) bool { - return !kubepod.IsMirrorPod(pod) && m.podDeletionSafety.PodResourcesAreReclaimed(pod, status) && pod.DeletionTimestamp != nil + if pod.DeletionTimestamp == nil || kubepod.IsMirrorPod(pod) { + return false + } + return m.podDeletionSafety.PodResourcesAreReclaimed(pod, status) } // needsReconcile compares the given status with the status in the pod manager (which diff --git a/pkg/kubelet/status/status_manager_test.go b/pkg/kubelet/status/status_manager_test.go index b51d1ced28d4f..3c1bc7f91d373 100644 --- a/pkg/kubelet/status/status_manager_test.go +++ b/pkg/kubelet/status/status_manager_test.go @@ -36,6 +36,7 @@ import ( podutil "k8s.io/kubernetes/pkg/api/v1/pod" "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/fake" + kubeconfigmap "k8s.io/kubernetes/pkg/kubelet/configmap" kubecontainer "k8s.io/kubernetes/pkg/kubelet/container" kubepod "k8s.io/kubernetes/pkg/kubelet/pod" podtest "k8s.io/kubernetes/pkg/kubelet/pod/testing" @@ -74,7 +75,7 @@ func (m *manager) testSyncBatch() { } func newTestManager(kubeClient clientset.Interface) *manager { - podManager := kubepod.NewBasicPodManager(podtest.NewFakeMirrorClient(), kubesecret.NewFakeManager()) + podManager := kubepod.NewBasicPodManager(podtest.NewFakeMirrorClient(), kubesecret.NewFakeManager(), kubeconfigmap.NewFakeManager()) podManager.AddPod(getTestPod()) return NewManager(kubeClient, podManager, &statustest.FakePodDeletionSafetyProvider{}).(*manager) } diff --git a/pkg/kubelet/util/BUILD b/pkg/kubelet/util/BUILD index 2d90897d819e8..876754545ffb1 100644 --- a/pkg/kubelet/util/BUILD +++ b/pkg/kubelet/util/BUILD @@ -5,6 +5,7 @@ licenses(["notice"]) load( "@io_bazel_rules_go//go:def.bzl", "go_library", + "go_test", ) go_library( @@ -12,9 +13,21 @@ go_library( srcs = [ "doc.go", "util.go", + "util_linux.go", ], tags = ["automanaged"], - deps = ["//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + ], +) + +go_test( + name = "go_default_test", + srcs = ["util_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = ["//vendor/github.com/stretchr/testify/assert:go_default_library"], ) filegroup( diff --git a/pkg/kubelet/util/util.go b/pkg/kubelet/util/util.go index ba52058a10bab..911e99538f3be 100644 --- a/pkg/kubelet/util/util.go +++ b/pkg/kubelet/util/util.go @@ -17,6 +17,9 @@ limitations under the License. package util import ( + "fmt" + "net/url" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) @@ -25,3 +28,18 @@ import ( func FromApiserverCache(opts *metav1.GetOptions) { opts.ResourceVersion = "0" } + +func parseEndpoint(endpoint string) (string, string, error) { + u, err := url.Parse(endpoint) + if err != nil { + return "", "", err + } + + if u.Scheme == "tcp" { + return "tcp", u.Host, nil + } else if u.Scheme == "unix" { + return "unix", u.Path, nil + } else { + return "", "", fmt.Errorf("protocol %q not supported", u.Scheme) + } +} diff --git a/pkg/kubelet/util/util_linux.go b/pkg/kubelet/util/util_linux.go new file mode 100644 index 0000000000000..1d780b24f939c --- /dev/null +++ b/pkg/kubelet/util/util_linux.go @@ -0,0 +1,79 @@ +// +build linux + +/* +Copyright 2017 The Kubernetes 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. +*/ + +package util + +import ( + "fmt" + "net" + "os" + "syscall" + "time" + + "github.com/golang/glog" +) + +const ( + // unixProtocol is the network protocol of unix socket. + unixProtocol = "unix" +) + +func CreateListener(endpoint string) (net.Listener, error) { + protocol, addr, err := parseEndpointWithFallbackProtocol(endpoint, unixProtocol) + if err != nil { + return nil, err + } + if protocol != unixProtocol { + return nil, fmt.Errorf("only support unix socket endpoint") + } + + // Unlink to cleanup the previous socket file. + err = syscall.Unlink(addr) + if err != nil && !os.IsNotExist(err) { + return nil, fmt.Errorf("failed to unlink socket file %q: %v", addr, err) + } + + return net.Listen(protocol, addr) +} + +func GetAddressAndDialer(endpoint string) (string, func(addr string, timeout time.Duration) (net.Conn, error), error) { + protocol, addr, err := parseEndpointWithFallbackProtocol(endpoint, unixProtocol) + if err != nil { + return "", nil, err + } + if protocol != unixProtocol { + return "", nil, fmt.Errorf("only support unix socket endpoint") + } + + return addr, dial, nil +} + +func dial(addr string, timeout time.Duration) (net.Conn, error) { + return net.DialTimeout(unixProtocol, addr, timeout) +} + +func parseEndpointWithFallbackProtocol(endpoint string, fallbackProtocol string) (protocol string, addr string, err error) { + if protocol, addr, err = parseEndpoint(endpoint); err != nil { + fallbackEndpoint := fallbackProtocol + "://" + endpoint + protocol, addr, err = parseEndpoint(fallbackEndpoint) + if err == nil { + glog.Warningf("Using %q as endpoint is depercated, please consider using full url format %q.", endpoint, fallbackEndpoint) + } + } + return +} diff --git a/pkg/kubelet/util/util_test.go b/pkg/kubelet/util/util_test.go new file mode 100644 index 0000000000000..ad9f0e7970339 --- /dev/null +++ b/pkg/kubelet/util/util_test.go @@ -0,0 +1,63 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package util + +import ( + "testing" + + "github.com/stretchr/testify/assert" +) + +func TestParseEndpoint(t *testing.T) { + tests := []struct { + endpoint string + expectError bool + expectedProtocol string + expectedAddr string + }{ + { + endpoint: "unix:///tmp/s1.sock", + expectedProtocol: "unix", + expectedAddr: "/tmp/s1.sock", + }, + { + endpoint: "tcp://localhost:15880", + expectedProtocol: "tcp", + expectedAddr: "localhost:15880", + }, + { + endpoint: "tcp1://abc", + expectError: true, + }, + { + endpoint: "a b c", + expectError: true, + }, + } + + for _, test := range tests { + protocol, addr, err := parseEndpoint(test.endpoint) + if test.expectError { + assert.NotNil(t, err, "Expect error during parsing %q", test.endpoint) + continue + } + assert.Nil(t, err, "Expect no error during parsing %q", test.endpoint) + assert.Equal(t, test.expectedProtocol, protocol) + assert.Equal(t, test.expectedAddr, addr) + } + +} diff --git a/pkg/kubelet/util/util_unsupported.go b/pkg/kubelet/util/util_unsupported.go new file mode 100644 index 0000000000000..616aabfe3b3bf --- /dev/null +++ b/pkg/kubelet/util/util_unsupported.go @@ -0,0 +1,33 @@ +// +build !linux,!windows + +/* +Copyright 2017 The Kubernetes 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. +*/ + +package util + +import ( + "fmt" + "net" + "time" +) + +func CreateListener(endpoint string) (net.Listener, error) { + return nil, fmt.Errorf("CreateListener is unsupported in this build") +} + +func GetAddressAndDialer(endpoint string) (string, func(addr string, timeout time.Duration) (net.Conn, error), error) { + return "", nil, fmt.Errorf("GetAddressAndDialer is unsupported in this build") +} diff --git a/pkg/kubelet/util/util_windows.go b/pkg/kubelet/util/util_windows.go new file mode 100644 index 0000000000000..108f4eb914f04 --- /dev/null +++ b/pkg/kubelet/util/util_windows.go @@ -0,0 +1,57 @@ +// +build windows + +/* +Copyright 2017 The Kubernetes 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. +*/ + +package util + +import ( + "fmt" + "net" + "time" +) + +const ( + tcpProtocol = "tcp" +) + +func CreateListener(endpoint string) (net.Listener, error) { + protocol, addr, err := parseEndpoint(endpoint) + if err != nil { + return nil, err + } + if protocol != tcpProtocol { + return nil, fmt.Errorf("only support tcp endpoint") + } + + return net.Listen(protocol, addr) +} + +func GetAddressAndDialer(endpoint string) (string, func(addr string, timeout time.Duration) (net.Conn, error), error) { + protocol, addr, err := parseEndpoint(endpoint) + if err != nil { + return "", nil, err + } + if protocol != tcpProtocol { + return "", nil, fmt.Errorf("only support tcp endpoint") + } + + return addr, dial, nil +} + +func dial(addr string, timeout time.Duration) (net.Conn, error) { + return net.DialTimeout(tcpProtocol, addr, timeout) +} diff --git a/pkg/kubelet/volume_host.go b/pkg/kubelet/volume_host.go index 547bf9b0cce01..24f3acf85134a 100644 --- a/pkg/kubelet/volume_host.go +++ b/pkg/kubelet/volume_host.go @@ -24,6 +24,7 @@ import ( "k8s.io/kubernetes/pkg/api/v1" "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" "k8s.io/kubernetes/pkg/cloudprovider" + "k8s.io/kubernetes/pkg/kubelet/configmap" "k8s.io/kubernetes/pkg/kubelet/secret" "k8s.io/kubernetes/pkg/util/io" "k8s.io/kubernetes/pkg/util/mount" @@ -39,11 +40,13 @@ import ( func NewInitializedVolumePluginMgr( kubelet *Kubelet, secretManager secret.Manager, + configMapManager configmap.Manager, plugins []volume.VolumePlugin) (*volume.VolumePluginMgr, error) { kvh := &kubeletVolumeHost{ - kubelet: kubelet, - volumePluginMgr: volume.VolumePluginMgr{}, - secretManager: secretManager, + kubelet: kubelet, + volumePluginMgr: volume.VolumePluginMgr{}, + secretManager: secretManager, + configMapManager: configMapManager, } if err := kvh.volumePluginMgr.InitPlugins(plugins, kvh); err != nil { @@ -63,9 +66,10 @@ func (kvh *kubeletVolumeHost) GetPluginDir(pluginName string) string { } type kubeletVolumeHost struct { - kubelet *Kubelet - volumePluginMgr volume.VolumePluginMgr - secretManager secret.Manager + kubelet *Kubelet + volumePluginMgr volume.VolumePluginMgr + secretManager secret.Manager + configMapManager configmap.Manager } func (kvh *kubeletVolumeHost) GetPodVolumeDir(podUID types.UID, pluginName string, volumeName string) string { @@ -140,3 +144,15 @@ func (kvh *kubeletVolumeHost) GetNodeAllocatable() (v1.ResourceList, error) { func (kvh *kubeletVolumeHost) GetSecretFunc() func(namespace, name string) (*v1.Secret, error) { return kvh.secretManager.GetSecret } + +func (kvh *kubeletVolumeHost) GetConfigMapFunc() func(namespace, name string) (*v1.ConfigMap, error) { + return kvh.configMapManager.GetConfigMap +} + +func (kvh *kubeletVolumeHost) GetNodeLabels() (map[string]string, error) { + node, err := kvh.kubelet.GetNode() + if err != nil { + return nil, fmt.Errorf("error retrieving node: %v", err) + } + return node.Labels, nil +} diff --git a/pkg/kubelet/volumemanager/BUILD b/pkg/kubelet/volumemanager/BUILD index 855089f3a876c..46ee7c04cce5e 100644 --- a/pkg/kubelet/volumemanager/BUILD +++ b/pkg/kubelet/volumemanager/BUILD @@ -47,6 +47,7 @@ go_test( "//pkg/client/clientset_generated/clientset:go_default_library", "//pkg/client/clientset_generated/clientset/fake:go_default_library", "//pkg/kubelet/config:go_default_library", + "//pkg/kubelet/configmap:go_default_library", "//pkg/kubelet/container/testing:go_default_library", "//pkg/kubelet/pod:go_default_library", "//pkg/kubelet/pod/testing:go_default_library", diff --git a/pkg/kubelet/volumemanager/populator/BUILD b/pkg/kubelet/volumemanager/populator/BUILD index e4596291bd88d..b1b85188e053b 100644 --- a/pkg/kubelet/volumemanager/populator/BUILD +++ b/pkg/kubelet/volumemanager/populator/BUILD @@ -53,6 +53,7 @@ go_test( deps = [ "//pkg/api/v1:go_default_library", "//pkg/client/clientset_generated/clientset/fake:go_default_library", + "//pkg/kubelet/configmap:go_default_library", "//pkg/kubelet/container/testing:go_default_library", "//pkg/kubelet/pod:go_default_library", "//pkg/kubelet/pod/testing:go_default_library", diff --git a/pkg/kubelet/volumemanager/populator/desired_state_of_world_populator_test.go b/pkg/kubelet/volumemanager/populator/desired_state_of_world_populator_test.go index 66d74ed0e719c..79d6da5ae760a 100644 --- a/pkg/kubelet/volumemanager/populator/desired_state_of_world_populator_test.go +++ b/pkg/kubelet/volumemanager/populator/desired_state_of_world_populator_test.go @@ -23,6 +23,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/kubernetes/pkg/api/v1" "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/fake" + "k8s.io/kubernetes/pkg/kubelet/configmap" containertest "k8s.io/kubernetes/pkg/kubelet/container/testing" kubepod "k8s.io/kubernetes/pkg/kubelet/pod" podtest "k8s.io/kubernetes/pkg/kubelet/pod/testing" @@ -40,8 +41,9 @@ func TestFindAndAddNewPods_FindAndRemoveDeletedPods(t *testing.T) { fakeClient := &fake.Clientset{} fakeSecretManager := secret.NewFakeManager() + fakeConfigMapManager := configmap.NewFakeManager() fakePodManager := kubepod.NewBasicPodManager( - podtest.NewFakeMirrorClient(), fakeSecretManager) + podtest.NewFakeMirrorClient(), fakeSecretManager, fakeConfigMapManager) fakesDSW := cache.NewDesiredStateOfWorld(fakeVolumePluginMgr) fakeRuntime := &containertest.FakeRuntime{} diff --git a/pkg/kubelet/volumemanager/reconciler/reconciler.go b/pkg/kubelet/volumemanager/reconciler/reconciler.go index 0bbee6ef26357..b2c2ea3fcdd18 100644 --- a/pkg/kubelet/volumemanager/reconciler/reconciler.go +++ b/pkg/kubelet/volumemanager/reconciler/reconciler.go @@ -235,14 +235,16 @@ func (rc *reconciler) reconcile() { } else if !volMounted || cache.IsRemountRequiredError(err) { // Volume is not mounted, or is already mounted, but requires remounting remountingLogStr := "" - if cache.IsRemountRequiredError(err) { + isRemount := cache.IsRemountRequiredError(err) + if isRemount { remountingLogStr = "Volume is already mounted to pod, but remount was requested." } glog.V(12).Infof(volumeToMount.GenerateMsgDetailed("Starting operationExecutor.MountVolume", remountingLogStr)) err := rc.operationExecutor.MountVolume( rc.waitForAttachTimeout, volumeToMount.VolumeToMount, - rc.actualStateOfWorld) + rc.actualStateOfWorld, + isRemount) if err != nil && !nestedpendingoperations.IsAlreadyExists(err) && !exponentialbackoff.IsExponentialBackoff(err) { diff --git a/pkg/kubelet/volumemanager/volume_manager.go b/pkg/kubelet/volumemanager/volume_manager.go index fe39f897610d7..f2af6b216b8dc 100644 --- a/pkg/kubelet/volumemanager/volume_manager.go +++ b/pkg/kubelet/volumemanager/volume_manager.go @@ -249,8 +249,7 @@ func (vm *volumeManager) Run(sourcesReady config.SourcesReady, stopCh <-chan str glog.Infof("Shutting down Kubelet Volume Manager") } -func (vm *volumeManager) GetMountedVolumesForPod( - podName types.UniquePodName) container.VolumeMap { +func (vm *volumeManager) GetMountedVolumesForPod(podName types.UniquePodName) container.VolumeMap { podVolumes := make(container.VolumeMap) for _, mountedVolume := range vm.actualStateOfWorld.GetMountedVolumesForPod(podName) { podVolumes[mountedVolume.OuterVolumeSpecName] = container.VolumeInfo{Mounter: mountedVolume.Mounter} @@ -373,8 +372,7 @@ func (vm *volumeManager) WaitForAttachAndMount(pod *v1.Pod) error { // verifyVolumesMountedFunc returns a method that returns true when all expected // volumes are mounted. -func (vm *volumeManager) verifyVolumesMountedFunc( - podName types.UniquePodName, expectedVolumes []string) wait.ConditionFunc { +func (vm *volumeManager) verifyVolumesMountedFunc(podName types.UniquePodName, expectedVolumes []string) wait.ConditionFunc { return func() (done bool, err error) { return len(vm.getUnmountedVolumes(podName, expectedVolumes)) == 0, nil } @@ -383,8 +381,7 @@ func (vm *volumeManager) verifyVolumesMountedFunc( // getUnmountedVolumes fetches the current list of mounted volumes from // the actual state of the world, and uses it to process the list of // expectedVolumes. It returns a list of unmounted volumes. -func (vm *volumeManager) getUnmountedVolumes( - podName types.UniquePodName, expectedVolumes []string) []string { +func (vm *volumeManager) getUnmountedVolumes(podName types.UniquePodName, expectedVolumes []string) []string { mountedVolumes := sets.NewString() for _, mountedVolume := range vm.actualStateOfWorld.GetMountedVolumesForPod(podName) { mountedVolumes.Insert(mountedVolume.OuterVolumeSpecName) @@ -394,8 +391,7 @@ func (vm *volumeManager) getUnmountedVolumes( // filterUnmountedVolumes adds each element of expectedVolumes that is not in // mountedVolumes to a list of unmountedVolumes and returns it. -func filterUnmountedVolumes( - mountedVolumes sets.String, expectedVolumes []string) []string { +func filterUnmountedVolumes(mountedVolumes sets.String, expectedVolumes []string) []string { unmountedVolumes := []string{} for _, expectedVolume := range expectedVolumes { if !mountedVolumes.Has(expectedVolume) { diff --git a/pkg/kubelet/volumemanager/volume_manager_test.go b/pkg/kubelet/volumemanager/volume_manager_test.go index 290e212abba5e..4794ceaa7d4c8 100644 --- a/pkg/kubelet/volumemanager/volume_manager_test.go +++ b/pkg/kubelet/volumemanager/volume_manager_test.go @@ -32,6 +32,7 @@ import ( "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/fake" "k8s.io/kubernetes/pkg/kubelet/config" + "k8s.io/kubernetes/pkg/kubelet/configmap" containertest "k8s.io/kubernetes/pkg/kubelet/container/testing" "k8s.io/kubernetes/pkg/kubelet/pod" kubepod "k8s.io/kubernetes/pkg/kubelet/pod" @@ -56,7 +57,7 @@ func TestGetMountedVolumesForPodAndGetVolumesInUse(t *testing.T) { t.Fatalf("can't make a temp dir: %v", err) } defer os.RemoveAll(tmpDir) - podManager := kubepod.NewBasicPodManager(podtest.NewFakeMirrorClient(), secret.NewFakeManager()) + podManager := kubepod.NewBasicPodManager(podtest.NewFakeMirrorClient(), secret.NewFakeManager(), configmap.NewFakeManager()) node, pod, pv, claim := createObjects() kubeClient := fake.NewSimpleClientset(node, pod, pv, claim) @@ -101,7 +102,7 @@ func TestGetExtraSupplementalGroupsForPod(t *testing.T) { t.Fatalf("can't make a temp dir: %v", err) } defer os.RemoveAll(tmpDir) - podManager := kubepod.NewBasicPodManager(podtest.NewFakeMirrorClient(), secret.NewFakeManager()) + podManager := kubepod.NewBasicPodManager(podtest.NewFakeMirrorClient(), secret.NewFakeManager(), configmap.NewFakeManager()) node, pod, _, claim := createObjects() @@ -182,10 +183,7 @@ func TestGetExtraSupplementalGroupsForPod(t *testing.T) { } } -func newTestVolumeManager( - tmpDir string, - podManager pod.Manager, - kubeClient clientset.Interface) (VolumeManager, error) { +func newTestVolumeManager(tmpDir string, podManager pod.Manager, kubeClient clientset.Interface) (VolumeManager, error) { plug := &volumetest.FakeVolumePlugin{PluginName: "fake", Host: nil} fakeRecorder := &record.FakeRecorder{} plugMgr := &volume.VolumePluginMgr{} @@ -275,10 +273,7 @@ func createObjects() (*v1.Node, *v1.Pod, *v1.PersistentVolume, *v1.PersistentVol return node, pod, pv, claim } -func simulateVolumeInUseUpdate( - volumeName v1.UniqueVolumeName, - stopCh <-chan struct{}, - volumeManager VolumeManager) { +func simulateVolumeInUseUpdate(volumeName v1.UniqueVolumeName, stopCh <-chan struct{}, volumeManager VolumeManager) { ticker := time.NewTicker(100 * time.Millisecond) defer ticker.Stop() for { diff --git a/pkg/kubemark/hollow_kubelet.go b/pkg/kubemark/hollow_kubelet.go index c0bbeb87e0542..88da1ffcf6b1c 100644 --- a/pkg/kubemark/hollow_kubelet.go +++ b/pkg/kubemark/hollow_kubelet.go @@ -89,7 +89,9 @@ func NewHollowKubelet( // Starts this HollowKubelet and blocks. func (hk *HollowKubelet) Run() { - kubeletapp.RunKubelet(hk.KubeletFlags, hk.KubeletConfiguration, hk.KubeletDeps, false, false) + if err := kubeletapp.RunKubelet(hk.KubeletFlags, hk.KubeletConfiguration, hk.KubeletDeps, false, false); err != nil { + glog.Fatalf("Failed to run HollowKubelet: %v. Exiting.", err) + } select {} } @@ -109,6 +111,8 @@ func GetHollowKubeletConfig( // Flags struct f := &options.KubeletFlags{ HostnameOverride: nodeName, + // Use the default runtime options. + ContainerRuntimeOptions: *options.NewContainerRuntimeOptions(), } // Config struct @@ -135,7 +139,6 @@ func GetHollowKubeletConfig( c.MaxPods = int32(maxPods) c.PodsPerCore = int32(podsPerCore) c.ClusterDNS = []string{} - c.DockerExecHandlerName = "native" c.ImageGCHighThresholdPercent = 90 c.ImageGCLowThresholdPercent = 80 c.LowDiskSpaceThresholdMB = 256 @@ -166,12 +169,5 @@ func GetHollowKubeletConfig( c.SystemCgroups = "" c.ProtectKernelDefaults = false - // TODO(mtaufen): Note that PodInfraContainerImage was being set to the empty value before, - // but this may not have been intentional. (previous code (SimpleKubelet) - // was peeling it off of a componentconfig.KubeletConfiguration{}, but may - // have actually wanted the default). - // The default will be present in the KubeletConfiguration contstructed above. - return f, c - } diff --git a/pkg/master/BUILD b/pkg/master/BUILD index a4f460e81148d..c8e62335dee8c 100644 --- a/pkg/master/BUILD +++ b/pkg/master/BUILD @@ -25,6 +25,8 @@ go_library( "//pkg/api/endpoints:go_default_library", "//pkg/api/install:go_default_library", "//pkg/api/v1:go_default_library", + "//pkg/apis/admissionregistration/install:go_default_library", + "//pkg/apis/admissionregistration/v1alpha1:go_default_library", "//pkg/apis/apps/install:go_default_library", "//pkg/apis/apps/v1beta1:go_default_library", "//pkg/apis/authentication/install:go_default_library", @@ -43,6 +45,8 @@ go_library( "//pkg/apis/extensions/install:go_default_library", "//pkg/apis/extensions/v1beta1:go_default_library", "//pkg/apis/imagepolicy/install:go_default_library", + "//pkg/apis/networking/install:go_default_library", + "//pkg/apis/networking/v1:go_default_library", "//pkg/apis/policy/install:go_default_library", "//pkg/apis/policy/v1beta1:go_default_library", "//pkg/apis/rbac/install:go_default_library", @@ -58,6 +62,7 @@ go_library( "//pkg/kubelet/client:go_default_library", "//pkg/master/thirdparty:go_default_library", "//pkg/master/tunneler:go_default_library", + "//pkg/registry/admissionregistration/rest:go_default_library", "//pkg/registry/apps/rest:go_default_library", "//pkg/registry/authentication/rest:go_default_library", "//pkg/registry/authorization/rest:go_default_library", @@ -70,6 +75,7 @@ go_library( "//pkg/registry/core/service/ipallocator/controller:go_default_library", "//pkg/registry/core/service/portallocator/controller:go_default_library", "//pkg/registry/extensions/rest:go_default_library", + "//pkg/registry/networking/rest:go_default_library", "//pkg/registry/policy/rest:go_default_library", "//pkg/registry/rbac/rest:go_default_library", "//pkg/registry/settings/rest:go_default_library", diff --git a/pkg/master/import_known_versions.go b/pkg/master/import_known_versions.go index 30a4420b9663f..076b9889372aa 100644 --- a/pkg/master/import_known_versions.go +++ b/pkg/master/import_known_versions.go @@ -22,6 +22,7 @@ import ( "k8s.io/kubernetes/pkg/api" _ "k8s.io/kubernetes/pkg/api/install" + _ "k8s.io/kubernetes/pkg/apis/admissionregistration/install" _ "k8s.io/kubernetes/pkg/apis/apps/install" _ "k8s.io/kubernetes/pkg/apis/authentication/install" _ "k8s.io/kubernetes/pkg/apis/authorization/install" @@ -31,6 +32,7 @@ import ( _ "k8s.io/kubernetes/pkg/apis/componentconfig/install" _ "k8s.io/kubernetes/pkg/apis/extensions/install" _ "k8s.io/kubernetes/pkg/apis/imagepolicy/install" + _ "k8s.io/kubernetes/pkg/apis/networking/install" _ "k8s.io/kubernetes/pkg/apis/policy/install" _ "k8s.io/kubernetes/pkg/apis/rbac/install" _ "k8s.io/kubernetes/pkg/apis/settings/install" diff --git a/pkg/master/master.go b/pkg/master/master.go index 26d114ca29f7d..7574a657df0c3 100644 --- a/pkg/master/master.go +++ b/pkg/master/master.go @@ -28,12 +28,14 @@ import ( utilnet "k8s.io/apimachinery/pkg/util/net" "k8s.io/apiserver/pkg/endpoints/discovery" "k8s.io/apiserver/pkg/registry/generic" + genericregistry "k8s.io/apiserver/pkg/registry/generic" genericapiserver "k8s.io/apiserver/pkg/server" "k8s.io/apiserver/pkg/server/healthz" serverstorage "k8s.io/apiserver/pkg/server/storage" "k8s.io/kubernetes/cmd/kube-apiserver/app/options" "k8s.io/kubernetes/pkg/api" apiv1 "k8s.io/kubernetes/pkg/api/v1" + admissionregistrationv1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" appsv1beta1 "k8s.io/kubernetes/pkg/apis/apps/v1beta1" authenticationv1 "k8s.io/kubernetes/pkg/apis/authentication/v1" authenticationv1beta1 "k8s.io/kubernetes/pkg/apis/authentication/v1beta1" @@ -43,10 +45,11 @@ import ( batchapiv1 "k8s.io/kubernetes/pkg/apis/batch/v1" certificatesapiv1beta1 "k8s.io/kubernetes/pkg/apis/certificates/v1beta1" extensionsapiv1beta1 "k8s.io/kubernetes/pkg/apis/extensions/v1beta1" + networkingapiv1 "k8s.io/kubernetes/pkg/apis/networking/v1" policyapiv1beta1 "k8s.io/kubernetes/pkg/apis/policy/v1beta1" - rbacapi "k8s.io/kubernetes/pkg/apis/rbac/v1alpha1" + rbacv1alpha1 "k8s.io/kubernetes/pkg/apis/rbac/v1alpha1" rbacv1beta1 "k8s.io/kubernetes/pkg/apis/rbac/v1beta1" - settingsapi "k8s.io/kubernetes/pkg/apis/settings/v1alpha1" + settingv1alpha1 "k8s.io/kubernetes/pkg/apis/settings/v1alpha1" storageapiv1 "k8s.io/kubernetes/pkg/apis/storage/v1" storageapiv1beta1 "k8s.io/kubernetes/pkg/apis/storage/v1beta1" corev1client "k8s.io/kubernetes/pkg/client/clientset_generated/clientset/typed/core/v1" @@ -61,6 +64,7 @@ import ( "github.com/prometheus/client_golang/prometheus" // RESTStorage installers + admissionregistrationrest "k8s.io/kubernetes/pkg/registry/admissionregistration/rest" appsrest "k8s.io/kubernetes/pkg/registry/apps/rest" authenticationrest "k8s.io/kubernetes/pkg/registry/authentication/rest" authorizationrest "k8s.io/kubernetes/pkg/registry/authorization/rest" @@ -69,6 +73,7 @@ import ( certificatesrest "k8s.io/kubernetes/pkg/registry/certificates/rest" corerest "k8s.io/kubernetes/pkg/registry/core/rest" extensionsrest "k8s.io/kubernetes/pkg/registry/extensions/rest" + networkingrest "k8s.io/kubernetes/pkg/registry/networking/rest" policyrest "k8s.io/kubernetes/pkg/registry/policy/rest" rbacrest "k8s.io/kubernetes/pkg/registry/rbac/rest" settingsrest "k8s.io/kubernetes/pkg/registry/settings/rest" @@ -206,18 +211,18 @@ func (c *Config) SkipComplete() completedConfig { // Certain config fields will be set to a default value if unset. // Certain config fields must be specified, including: // KubeletClientConfig -func (c completedConfig) New(delegationTarget genericapiserver.DelegationTarget) (*Master, error) { +func (c completedConfig) New(delegationTarget genericapiserver.DelegationTarget, crdRESTOptionsGetter genericregistry.RESTOptionsGetter) (*Master, error) { if reflect.DeepEqual(c.KubeletClientConfig, kubeletclient.KubeletClientConfig{}) { return nil, fmt.Errorf("Master.New() called with empty config.KubeletClientConfig") } - s, err := c.Config.GenericConfig.SkipComplete().New(delegationTarget) // completion is done in Complete, no need for a second time + s, err := c.Config.GenericConfig.SkipComplete().New("kube-apiserver", delegationTarget) // completion is done in Complete, no need for a second time if err != nil { return nil, err } if c.EnableUISupport { - routes.UIRedirect{}.Install(s.Handler.PostGoRestfulMux) + routes.UIRedirect{}.Install(s.Handler.NonGoRestfulMux) } if c.EnableLogsSupport { routes.Logs{}.Install(s.Handler.GoRestfulContainer) @@ -250,7 +255,9 @@ func (c completedConfig) New(delegationTarget genericapiserver.DelegationTarget) autoscalingrest.RESTStorageProvider{}, batchrest.RESTStorageProvider{}, certificatesrest.RESTStorageProvider{}, - extensionsrest.RESTStorageProvider{ResourceInterface: thirdparty.NewThirdPartyResourceServer(s, s.DiscoveryGroupManager, c.StorageFactory)}, + // TODO(enisoc): Remove crdRESTOptionsGetter input argument when TPR code is removed. + extensionsrest.RESTStorageProvider{ResourceInterface: thirdparty.NewThirdPartyResourceServer(s, s.DiscoveryGroupManager, c.StorageFactory, crdRESTOptionsGetter)}, + networkingrest.RESTStorageProvider{}, policyrest.RESTStorageProvider{}, rbacrest.RESTStorageProvider{Authorizer: c.GenericConfig.Authorizer}, settingsrest.RESTStorageProvider{}, @@ -258,6 +265,7 @@ func (c completedConfig) New(delegationTarget genericapiserver.DelegationTarget) // keep apps after extensions so legacy clients resolve the extensions versions of shared resource names. // See https://github.com/kubernetes/kubernetes/issues/42392 appsrest.RESTStorageProvider{}, + admissionregistrationrest.RESTStorageProvider{}, } m.InstallAPIs(c.Config.APIResourceConfigSource, c.Config.GenericConfig.RESTOptionsGetter, restStorageProviders...) @@ -371,6 +379,7 @@ func DefaultAPIResourceConfigSource() *serverstorage.ResourceConfig { ret := serverstorage.NewResourceConfig() ret.EnableVersions( apiv1.SchemeGroupVersion, + admissionregistrationv1alpha1.SchemeGroupVersion, extensionsapiv1beta1.SchemeGroupVersion, batchapiv1.SchemeGroupVersion, authenticationv1.SchemeGroupVersion, @@ -379,13 +388,14 @@ func DefaultAPIResourceConfigSource() *serverstorage.ResourceConfig { appsv1beta1.SchemeGroupVersion, policyapiv1beta1.SchemeGroupVersion, rbacv1beta1.SchemeGroupVersion, - rbacapi.SchemeGroupVersion, - settingsapi.SchemeGroupVersion, + rbacv1alpha1.SchemeGroupVersion, + settingv1alpha1.SchemeGroupVersion, storageapiv1.SchemeGroupVersion, storageapiv1beta1.SchemeGroupVersion, certificatesapiv1beta1.SchemeGroupVersion, authorizationapiv1.SchemeGroupVersion, authorizationapiv1beta1.SchemeGroupVersion, + networkingapiv1.SchemeGroupVersion, ) // all extensions resources except these are disabled by default diff --git a/pkg/master/master_openapi_test.go b/pkg/master/master_openapi_test.go index 39ddb686c5385..7e9f0c786358c 100644 --- a/pkg/master/master_openapi_test.go +++ b/pkg/master/master_openapi_test.go @@ -54,13 +54,13 @@ func TestValidOpenAPISpec(t *testing.T) { } config.GenericConfig.SwaggerConfig = genericapiserver.DefaultSwaggerConfig() - master, err := config.Complete().New(genericapiserver.EmptyDelegate) + master, err := config.Complete().New(genericapiserver.EmptyDelegate, nil) if err != nil { t.Fatalf("Error in bringing up the master: %v", err) } // make sure swagger.json is not registered before calling PrepareRun. - server := httptest.NewServer(apirequest.WithRequestContext(master.GenericAPIServer.Handler.GoRestfulContainer.ServeMux, master.GenericAPIServer.RequestContextMapper())) + server := httptest.NewServer(apirequest.WithRequestContext(master.GenericAPIServer.Handler.Director, master.GenericAPIServer.RequestContextMapper())) defer server.Close() resp, err := http.Get(server.URL + "/swagger.json") if !assert.NoError(err) { diff --git a/pkg/master/master_test.go b/pkg/master/master_test.go index 25d7ba010b2d1..b6bf30b1803c0 100644 --- a/pkg/master/master_test.go +++ b/pkg/master/master_test.go @@ -115,7 +115,7 @@ func setUp(t *testing.T) (*etcdtesting.EtcdTestServer, Config, *assert.Assertion func newMaster(t *testing.T) (*Master, *etcdtesting.EtcdTestServer, Config, *assert.Assertions) { etcdserver, config, assert := setUp(t) - master, err := config.Complete().New(genericapiserver.EmptyDelegate) + master, err := config.Complete().New(genericapiserver.EmptyDelegate, nil) if err != nil { t.Fatalf("Error in bringing up the master: %v", err) } @@ -141,7 +141,7 @@ func limitedAPIResourceConfigSource() *serverstorage.ResourceConfig { func newLimitedMaster(t *testing.T) (*Master, *etcdtesting.EtcdTestServer, Config, *assert.Assertions) { etcdserver, config, assert := setUp(t) config.APIResourceConfigSource = limitedAPIResourceConfigSource() - master, err := config.Complete().New(genericapiserver.EmptyDelegate) + master, err := config.Complete().New(genericapiserver.EmptyDelegate, nil) if err != nil { t.Fatalf("Error in bringing up the master: %v", err) } diff --git a/pkg/master/thirdparty/BUILD b/pkg/master/thirdparty/BUILD index 80d93b2121c89..c32b4824273e3 100644 --- a/pkg/master/thirdparty/BUILD +++ b/pkg/master/thirdparty/BUILD @@ -27,9 +27,12 @@ go_library( "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/meta:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1/unstructured:go_default_library", "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/json:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", "//vendor/k8s.io/apiserver/pkg/endpoints:go_default_library", @@ -40,12 +43,16 @@ go_library( "//vendor/k8s.io/apiserver/pkg/server:go_default_library", "//vendor/k8s.io/apiserver/pkg/server/storage:go_default_library", "//vendor/k8s.io/apiserver/pkg/storage/storagebackend:go_default_library", + "//vendor/k8s.io/client-go/discovery:go_default_library", "//vendor/k8s.io/client-go/tools/cache:go_default_library", "//vendor/k8s.io/client-go/util/workqueue:go_default_library", "//vendor/k8s.io/kube-aggregator/pkg/apis/apiregistration:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/apiserver:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/internalclientset/typed/apiextensions/internalversion:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/informers/internalversion/apiextensions/internalversion:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/internalversion:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/registry/customresource:go_default_library", ], ) diff --git a/pkg/master/thirdparty/thirdparty.go b/pkg/master/thirdparty/thirdparty.go index 9a70bf815415b..50df6f763c825 100644 --- a/pkg/master/thirdparty/thirdparty.go +++ b/pkg/master/thirdparty/thirdparty.go @@ -25,16 +25,26 @@ import ( "k8s.io/apimachinery/pkg/api/meta" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" + utilerrors "k8s.io/apimachinery/pkg/util/errors" + "k8s.io/apimachinery/pkg/util/json" + utilruntime "k8s.io/apimachinery/pkg/util/runtime" genericapi "k8s.io/apiserver/pkg/endpoints" "k8s.io/apiserver/pkg/endpoints/discovery" + "k8s.io/apiserver/pkg/endpoints/request" genericapirequest "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/apiserver/pkg/registry/generic" "k8s.io/apiserver/pkg/registry/rest" genericapiserver "k8s.io/apiserver/pkg/server" serverstorgage "k8s.io/apiserver/pkg/server/storage" "k8s.io/apiserver/pkg/storage/storagebackend" + discoveryclient "k8s.io/client-go/discovery" + "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions" + apiextensionsserver "k8s.io/kube-apiextensions-server/pkg/apiserver" + apiextensionsclient "k8s.io/kube-apiextensions-server/pkg/client/clientset/internalclientset/typed/apiextensions/internalversion" + "k8s.io/kube-apiextensions-server/pkg/registry/customresource" "k8s.io/kubernetes/pkg/api" "k8s.io/kubernetes/pkg/apis/extensions" extensionsrest "k8s.io/kubernetes/pkg/registry/extensions/rest" @@ -71,13 +81,16 @@ type ThirdPartyResourceServer struct { // Useful for reliable testing. Shouldn't be used otherwise. disableThirdPartyControllerForTesting bool + + crdRESTOptionsGetter generic.RESTOptionsGetter } -func NewThirdPartyResourceServer(genericAPIServer *genericapiserver.GenericAPIServer, availableGroupManager discovery.GroupManager, storageFactory serverstorgage.StorageFactory) *ThirdPartyResourceServer { +func NewThirdPartyResourceServer(genericAPIServer *genericapiserver.GenericAPIServer, availableGroupManager discovery.GroupManager, storageFactory serverstorgage.StorageFactory, crdRESTOptionsGetter generic.RESTOptionsGetter) *ThirdPartyResourceServer { ret := &ThirdPartyResourceServer{ genericAPIServer: genericAPIServer, thirdPartyResources: map[string]*thirdPartyEntry{}, availableGroupManager: availableGroupManager, + crdRESTOptionsGetter: crdRESTOptionsGetter, } var err error @@ -130,7 +143,7 @@ func (m *ThirdPartyResourceServer) removeThirdPartyStorage(path, resource string if !found { return nil } - if err := m.removeAllThirdPartyResources(storage); err != nil { + if err := m.removeThirdPartyResourceData(&entry.group, resource, storage); err != nil { return err } delete(entry.storage, resource) @@ -166,25 +179,132 @@ func (m *ThirdPartyResourceServer) RemoveThirdPartyResource(path string) error { return nil } -func (m *ThirdPartyResourceServer) removeAllThirdPartyResources(registry *thirdpartyresourcedatastore.REST) error { - ctx := genericapirequest.NewDefaultContext() +func (m *ThirdPartyResourceServer) removeThirdPartyResourceData(group *metav1.APIGroup, resource string, registry *thirdpartyresourcedatastore.REST) error { + // Freeze TPR data to prevent new writes via this apiserver process. + // Other apiservers can still write. This is best-effort because there + // are worse problems with TPR data than the possibility of going back + // in time when migrating to CRD [citation needed]. + registry.Freeze() + + ctx := genericapirequest.NewContext() existingData, err := registry.List(ctx, nil) if err != nil { return err } list, ok := existingData.(*extensions.ThirdPartyResourceDataList) if !ok { - return fmt.Errorf("expected a *ThirdPartyResourceDataList, got %#v", list) + return fmt.Errorf("expected a *ThirdPartyResourceDataList, got %T", existingData) + } + + // Migrate TPR data to CRD if requested. + gvk := schema.GroupVersionKind{Group: group.Name, Version: group.PreferredVersion.Version, Kind: registry.Kind()} + migrationRequested, err := m.migrateThirdPartyResourceData(gvk, resource, list) + if err != nil { + // Migration is best-effort. Log and continue. + utilruntime.HandleError(fmt.Errorf("failed to migrate TPR data: %v", err)) } - for ix := range list.Items { - item := &list.Items[ix] - if _, _, err := registry.Delete(ctx, item.Name, nil); err != nil { + + // Skip deletion of TPR data if migration was requested (whether or not it succeeded). + // This leaves the etcd data around for rollback, and to avoid sending DELETE watch events. + if migrationRequested { + return nil + } + + for i := range list.Items { + item := &list.Items[i] + + // Use registry.Store.Delete() to bypass the frozen registry.Delete(). + if _, _, err := registry.Store.Delete(genericapirequest.WithNamespace(ctx, item.Namespace), item.Name, nil); err != nil { return err } } return nil } +func (m *ThirdPartyResourceServer) findMatchingCRD(gvk schema.GroupVersionKind, resource string) (*apiextensions.CustomResourceDefinition, error) { + // CustomResourceDefinitionList does not implement the protobuf marshalling interface. + config := *m.genericAPIServer.LoopbackClientConfig + config.ContentType = "application/json" + crdClient, err := apiextensionsclient.NewForConfig(&config) + if err != nil { + return nil, fmt.Errorf("can't create apiextensions client: %v", err) + } + crdList, err := crdClient.CustomResourceDefinitions().List(metav1.ListOptions{}) + if err != nil { + return nil, fmt.Errorf("can't list CustomResourceDefinitions: %v", err) + } + for i := range crdList.Items { + item := &crdList.Items[i] + if item.Spec.Scope == apiextensions.NamespaceScoped && + item.Spec.Group == gvk.Group && item.Spec.Version == gvk.Version && + item.Status.AcceptedNames.Kind == gvk.Kind && item.Status.AcceptedNames.Plural == resource { + return item, nil + } + } + return nil, nil +} + +func (m *ThirdPartyResourceServer) migrateThirdPartyResourceData(gvk schema.GroupVersionKind, resource string, dataList *extensions.ThirdPartyResourceDataList) (bool, error) { + // A matching CustomResourceDefinition implies migration is requested. + crd, err := m.findMatchingCRD(gvk, resource) + if err != nil { + return false, fmt.Errorf("can't determine if TPR should migrate: %v", err) + } + if crd == nil { + // No migration requested. + return false, nil + } + + // Talk directly to CustomResource storage. + // We have to bypass the API server because TPR is shadowing CRD at this point. + storage := customresource.NewREST( + schema.GroupResource{Group: crd.Spec.Group, Resource: crd.Spec.Names.Plural}, + schema.GroupVersionKind{Group: crd.Spec.Group, Version: crd.Spec.Version, Kind: crd.Spec.Names.ListKind}, + apiextensionsserver.UnstructuredCopier{}, + customresource.NewStrategy(discoveryclient.NewUnstructuredObjectTyper(nil), true), + m.crdRESTOptionsGetter, + ) + + // Copy TPR data to CustomResource. + var errs []error + ctx := request.NewContext() + for i := range dataList.Items { + item := &dataList.Items[i] + + // Convert TPR data to Unstructured. + objMap := make(map[string]interface{}) + if err := json.Unmarshal(item.Data, &objMap); err != nil { + errs = append(errs, fmt.Errorf("can't unmarshal TPR data %q: %v", item.Name, err)) + continue + } + + // Convert metadata to Unstructured and merge with data. + // cf. thirdpartyresourcedata.encodeToJSON() + metaMap := make(map[string]interface{}) + buf, err := json.Marshal(&item.ObjectMeta) + if err != nil { + errs = append(errs, fmt.Errorf("can't marshal metadata for TPR data %q: %v", item.Name, err)) + continue + } + if err := json.Unmarshal(buf, &metaMap); err != nil { + errs = append(errs, fmt.Errorf("can't unmarshal TPR data %q: %v", item.Name, err)) + continue + } + // resourceVersion cannot be set when creating objects. + delete(metaMap, "resourceVersion") + objMap["metadata"] = metaMap + + // Store CustomResource. + obj := &unstructured.Unstructured{Object: objMap} + createCtx := request.WithNamespace(ctx, obj.GetNamespace()) + if _, err := storage.Create(createCtx, obj); err != nil { + errs = append(errs, fmt.Errorf("can't create CustomResource for TPR data %q: %v", item.Name, err)) + continue + } + } + return true, utilerrors.NewAggregate(errs) +} + // ListThirdPartyResources lists all currently installed third party resources // The format is / func (m *ThirdPartyResourceServer) ListThirdPartyResources() []string { diff --git a/pkg/printers/internalversion/BUILD b/pkg/printers/internalversion/BUILD index 05b07b4660163..d736500ec2ddc 100644 --- a/pkg/printers/internalversion/BUILD +++ b/pkg/printers/internalversion/BUILD @@ -23,6 +23,7 @@ go_test( "//pkg/api:go_default_library", "//pkg/api/testapi:go_default_library", "//pkg/api/v1:go_default_library", + "//pkg/apis/apps:go_default_library", "//pkg/apis/autoscaling:go_default_library", "//pkg/apis/batch:go_default_library", "//pkg/apis/extensions:go_default_library", @@ -71,6 +72,7 @@ go_library( "//pkg/apis/certificates:go_default_library", "//pkg/apis/extensions:go_default_library", "//pkg/apis/extensions/v1beta1:go_default_library", + "//pkg/apis/networking:go_default_library", "//pkg/apis/policy:go_default_library", "//pkg/apis/rbac:go_default_library", "//pkg/apis/settings:go_default_library", diff --git a/pkg/printers/internalversion/describe.go b/pkg/printers/internalversion/describe.go index 5135b231dae53..5fad424f90e04 100644 --- a/pkg/printers/internalversion/describe.go +++ b/pkg/printers/internalversion/describe.go @@ -58,6 +58,7 @@ import ( "k8s.io/kubernetes/pkg/apis/certificates" "k8s.io/kubernetes/pkg/apis/extensions" versionedextension "k8s.io/kubernetes/pkg/apis/extensions/v1beta1" + "k8s.io/kubernetes/pkg/apis/networking" "k8s.io/kubernetes/pkg/apis/policy" "k8s.io/kubernetes/pkg/apis/rbac" "k8s.io/kubernetes/pkg/apis/storage" @@ -132,7 +133,7 @@ func describerMap(c clientset.Interface) map[schema.GroupKind]printers.Describer api.Kind("ConfigMap"): &ConfigMapDescriber{c}, extensions.Kind("ReplicaSet"): &ReplicaSetDescriber{c}, - extensions.Kind("NetworkPolicy"): &NetworkPolicyDescriber{c}, + extensions.Kind("NetworkPolicy"): &ExtensionsNetworkPolicyDescriber{c}, autoscaling.Kind("HorizontalPodAutoscaler"): &HorizontalPodAutoscalerDescriber{c}, extensions.Kind("DaemonSet"): &DaemonSetDescriber{c}, extensions.Kind("Deployment"): &DeploymentDescriber{c, versionedClientsetForDeployment(c)}, @@ -146,6 +147,7 @@ func describerMap(c clientset.Interface) map[schema.GroupKind]printers.Describer policy.Kind("PodDisruptionBudget"): &PodDisruptionBudgetDescriber{c}, rbac.Kind("RoleBinding"): &RoleBindingDescriber{c}, rbac.Kind("ClusterRoleBinding"): &ClusterRoleBindingDescriber{c}, + networking.Kind("NetworkPolicy"): &NetworkPolicyDescriber{c}, } return m @@ -735,6 +737,8 @@ func describeVolumes(volumes []api.Volume, w PrefixWriter, space string) { printPortworxVolumeSource(volume.VolumeSource.PortworxVolume, w) case volume.VolumeSource.ScaleIO != nil: printScaleIOVolumeSource(volume.VolumeSource.ScaleIO, w) + case volume.VolumeSource.CephFS != nil: + printCephFSVolumeSource(volume.VolumeSource.CephFS, w) default: w.Write(LEVEL_1, "\n") } @@ -922,6 +926,17 @@ func printLocalVolumeSource(ls *api.LocalVolumeSource, w PrefixWriter) { ls.Path) } +func printCephFSVolumeSource(cephfs *api.CephFSVolumeSource, w PrefixWriter) { + w.Write(LEVEL_2, "Type:\tCephFS (a CephFS mount on the host that shares a pod's lifetime)\n"+ + " Monitors:\t%v\n"+ + " Path:\t%v\n"+ + " User:\t%v\n"+ + " SecretFile:\t%v\n"+ + " SecretRef:\t%v\n"+ + " ReadOnly:\t%v\n", + cephfs.Monitors, cephfs.Path, cephfs.User, cephfs.SecretFile, cephfs.SecretRef, cephfs.ReadOnly) +} + type PersistentVolumeDescriber struct { clientset.Interface } @@ -993,6 +1008,8 @@ func describePersistentVolume(pv *api.PersistentVolume, events *api.EventList) ( printScaleIOVolumeSource(pv.Spec.ScaleIO, w) case pv.Spec.Local != nil: printLocalVolumeSource(pv.Spec.Local, w) + case pv.Spec.CephFS != nil: + printCephFSVolumeSource(pv.Spec.CephFS, w) } if events != nil { @@ -2797,13 +2814,41 @@ func describeCluster(cluster *federation.Cluster) (string, error) { }) } -// NetworkPolicyDescriber generates information about a NetworkPolicy +// ExtensionsNetworkPolicyDescriber generates information about an extensions.NetworkPolicy +type ExtensionsNetworkPolicyDescriber struct { + clientset.Interface +} + +func (d *ExtensionsNetworkPolicyDescriber) Describe(namespace, name string, describerSettings printers.DescriberSettings) (string, error) { + c := d.Extensions().NetworkPolicies(namespace) + + networkPolicy, err := c.Get(name, metav1.GetOptions{}) + if err != nil { + return "", err + } + + return describeExtensionsNetworkPolicy(networkPolicy) +} + +func describeExtensionsNetworkPolicy(networkPolicy *extensions.NetworkPolicy) (string, error) { + return tabbedString(func(out io.Writer) error { + w := NewPrefixWriter(out) + w.Write(LEVEL_0, "Name:\t%s\n", networkPolicy.Name) + w.Write(LEVEL_0, "Namespace:\t%s\n", networkPolicy.Namespace) + printLabelsMultiline(w, "Labels", networkPolicy.Labels) + printAnnotationsMultiline(w, "Annotations", networkPolicy.Annotations) + + return nil + }) +} + +// NetworkPolicyDescriber generates information about a networking.NetworkPolicy type NetworkPolicyDescriber struct { clientset.Interface } func (d *NetworkPolicyDescriber) Describe(namespace, name string, describerSettings printers.DescriberSettings) (string, error) { - c := d.Extensions().NetworkPolicies(namespace) + c := d.Networking().NetworkPolicies(namespace) networkPolicy, err := c.Get(name, metav1.GetOptions{}) if err != nil { @@ -2813,7 +2858,7 @@ func (d *NetworkPolicyDescriber) Describe(namespace, name string, describerSetti return describeNetworkPolicy(networkPolicy) } -func describeNetworkPolicy(networkPolicy *extensions.NetworkPolicy) (string, error) { +func describeNetworkPolicy(networkPolicy *networking.NetworkPolicy) (string, error) { return tabbedString(func(out io.Writer) error { w := NewPrefixWriter(out) w.Write(LEVEL_0, "Name:\t%s\n", networkPolicy.Name) diff --git a/pkg/printers/internalversion/describe_test.go b/pkg/printers/internalversion/describe_test.go index f9202866a58c9..5199cbbc29623 100644 --- a/pkg/printers/internalversion/describe_test.go +++ b/pkg/printers/internalversion/describe_test.go @@ -135,6 +135,28 @@ func TestDescribeNamespace(t *testing.T) { } } +func TestDescribeConfigMap(t *testing.T) { + fake := fake.NewSimpleClientset(&api.ConfigMap{ + ObjectMeta: metav1.ObjectMeta{ + Name: "mycm", + Namespace: "foo", + }, + Data: map[string]string{ + "key1": "value1", + "key2": "value2", + }, + }) + c := &describeClient{T: t, Namespace: "foo", Interface: fake} + d := ConfigMapDescriber{c} + out, err := d.Describe("foo", "mycm", printers.DescriberSettings{ShowEvents: true}) + if err != nil { + t.Errorf("unexpected error: %v", err) + } + if !strings.Contains(out, "foo") || !strings.Contains(out, "mycm") || !strings.Contains(out, "key1") || !strings.Contains(out, "value1") || !strings.Contains(out, "key2") || !strings.Contains(out, "value2") { + t.Errorf("unexpected out: %s", out) + } +} + func TestDescribeService(t *testing.T) { fake := fake.NewSimpleClientset(&api.Service{ ObjectMeta: metav1.ObjectMeta{ @@ -1423,3 +1445,42 @@ URL: http://localhost } } } + +func TestDescribeResourceQuota(t *testing.T) { + fake := fake.NewSimpleClientset(&api.ResourceQuota{ + ObjectMeta: metav1.ObjectMeta{ + Name: "bar", + Namespace: "foo", + }, + Status: api.ResourceQuotaStatus{ + Hard: api.ResourceList{ + api.ResourceName(api.ResourceCPU): resource.MustParse("1"), + api.ResourceName(api.ResourceLimitsCPU): resource.MustParse("2"), + api.ResourceName(api.ResourceLimitsMemory): resource.MustParse("2G"), + api.ResourceName(api.ResourceMemory): resource.MustParse("1G"), + api.ResourceName(api.ResourceRequestsCPU): resource.MustParse("1"), + api.ResourceName(api.ResourceRequestsMemory): resource.MustParse("1G"), + }, + Used: api.ResourceList{ + api.ResourceName(api.ResourceCPU): resource.MustParse("0"), + api.ResourceName(api.ResourceLimitsCPU): resource.MustParse("0"), + api.ResourceName(api.ResourceLimitsMemory): resource.MustParse("0G"), + api.ResourceName(api.ResourceMemory): resource.MustParse("0G"), + api.ResourceName(api.ResourceRequestsCPU): resource.MustParse("0"), + api.ResourceName(api.ResourceRequestsMemory): resource.MustParse("0G"), + }, + }, + }) + c := &describeClient{T: t, Namespace: "foo", Interface: fake} + d := ResourceQuotaDescriber{c} + out, err := d.Describe("foo", "bar", printers.DescriberSettings{ShowEvents: true}) + if err != nil { + t.Errorf("unexpected error: %v", err) + } + expectedOut := []string{"bar", "foo", "limits.cpu", "2", "limits.memory", "2G", "requests.cpu", "1", "requests.memory", "1G"} + for _, expected := range expectedOut { + if !strings.Contains(out, expected) { + t.Errorf("expected to find %q in output: %q", expected, out) + } + } +} diff --git a/pkg/printers/internalversion/printers.go b/pkg/printers/internalversion/printers.go index 2f5228bda30bc..682ab2b872501 100644 --- a/pkg/printers/internalversion/printers.go +++ b/pkg/printers/internalversion/printers.go @@ -38,11 +38,13 @@ import ( "k8s.io/kubernetes/pkg/apis/batch" "k8s.io/kubernetes/pkg/apis/certificates" "k8s.io/kubernetes/pkg/apis/extensions" + "k8s.io/kubernetes/pkg/apis/networking" "k8s.io/kubernetes/pkg/apis/policy" "k8s.io/kubernetes/pkg/apis/rbac" "k8s.io/kubernetes/pkg/apis/settings" "k8s.io/kubernetes/pkg/apis/storage" storageutil "k8s.io/kubernetes/pkg/apis/storage/util" + "k8s.io/kubernetes/pkg/controller" "k8s.io/kubernetes/pkg/printers" "k8s.io/kubernetes/pkg/util/node" ) @@ -102,6 +104,7 @@ var ( networkPolicyColumns = []string{"NAME", "POD-SELECTOR", "AGE"} certificateSigningRequestColumns = []string{"NAME", "AGE", "REQUESTOR", "CONDITION"} podPresetColumns = []string{"NAME", "AGE"} + controllerRevisionColumns = []string{"NAME", "CONTROLLER", "REVISION", "AGE"} ) func printPod(pod *api.Pod, w io.Writer, options printers.PrintOptions) error { @@ -181,6 +184,8 @@ func AddHandlers(h *printers.HumanReadablePrinter) { h.Handler(thirdPartyResourceDataColumns, nil, printThirdPartyResourceDataList) h.Handler(clusterColumns, nil, printCluster) h.Handler(clusterColumns, nil, printClusterList) + h.Handler(networkPolicyColumns, nil, printExtensionsNetworkPolicy) + h.Handler(networkPolicyColumns, nil, printExtensionsNetworkPolicyList) h.Handler(networkPolicyColumns, nil, printNetworkPolicy) h.Handler(networkPolicyColumns, nil, printNetworkPolicyList) h.Handler(roleColumns, nil, printRole) @@ -198,6 +203,8 @@ func AddHandlers(h *printers.HumanReadablePrinter) { h.Handler(podPresetColumns, nil, printPodPreset) h.Handler(podPresetColumns, nil, printPodPresetList) h.Handler(statusColumns, nil, printStatus) + h.Handler(controllerRevisionColumns, nil, printControllerRevision) + h.Handler(controllerRevisionColumns, nil, printControllerRevisionList) } // Pass ports=nil for all ports. @@ -1856,7 +1863,7 @@ func printPodSecurityPolicyList(list *extensions.PodSecurityPolicyList, w io.Wri return nil } -func printNetworkPolicy(networkPolicy *extensions.NetworkPolicy, w io.Writer, options printers.PrintOptions) error { +func printExtensionsNetworkPolicy(networkPolicy *extensions.NetworkPolicy, w io.Writer, options printers.PrintOptions) error { name := printers.FormatResourceName(options.Kind, networkPolicy.Name, options.WithKind) namespace := networkPolicy.Namespace @@ -1876,7 +1883,36 @@ func printNetworkPolicy(networkPolicy *extensions.NetworkPolicy, w io.Writer, op return err } -func printNetworkPolicyList(list *extensions.NetworkPolicyList, w io.Writer, options printers.PrintOptions) error { +func printExtensionsNetworkPolicyList(list *extensions.NetworkPolicyList, w io.Writer, options printers.PrintOptions) error { + for i := range list.Items { + if err := printExtensionsNetworkPolicy(&list.Items[i], w, options); err != nil { + return err + } + } + return nil +} + +func printNetworkPolicy(networkPolicy *networking.NetworkPolicy, w io.Writer, options printers.PrintOptions) error { + name := printers.FormatResourceName(options.Kind, networkPolicy.Name, options.WithKind) + + namespace := networkPolicy.Namespace + + if options.WithNamespace { + if _, err := fmt.Fprintf(w, "%s\t", namespace); err != nil { + return err + } + } + if _, err := fmt.Fprintf(w, "%s\t%v\t%s", name, metav1.FormatLabelSelector(&networkPolicy.Spec.PodSelector), translateTimestamp(networkPolicy.CreationTimestamp)); err != nil { + return err + } + if _, err := fmt.Fprint(w, printers.AppendLabels(networkPolicy.Labels, options.ColumnLabels)); err != nil { + return err + } + _, err := fmt.Fprint(w, printers.AppendAllLabels(options.ShowLabels, networkPolicy.Labels)) + return err +} + +func printNetworkPolicyList(list *networking.NetworkPolicyList, w io.Writer, options printers.PrintOptions) error { for i := range list.Items { if err := printNetworkPolicy(&list.Items[i], w, options); err != nil { return err @@ -1968,3 +2004,39 @@ func formatEventSource(es api.EventSource) string { } return strings.Join(EventSourceString, ", ") } + +func printControllerRevision(history *apps.ControllerRevision, w io.Writer, options printers.PrintOptions) error { + name := printers.FormatResourceName(options.Kind, history.Name, options.WithKind) + + if options.WithNamespace { + if _, err := fmt.Fprintf(w, "%s\t", history.Namespace); err != nil { + return err + } + } + + controllerRef := controller.GetControllerOf(history) + controllerName := "" + if controllerRef != nil { + withKind := true + controllerName = printers.FormatResourceName(controllerRef.Kind, controllerRef.Name, withKind) + } + revision := history.Revision + age := translateTimestamp(history.CreationTimestamp) + if _, err := fmt.Fprintf(w, "%s\t%s\t%d\t%s", name, controllerName, revision, age); err != nil { + return err + } + if _, err := fmt.Fprint(w, printers.AppendLabels(history.Labels, options.ColumnLabels)); err != nil { + return err + } + _, err := fmt.Fprint(w, printers.AppendAllLabels(options.ShowLabels, history.Labels)) + return err +} + +func printControllerRevisionList(list *apps.ControllerRevisionList, w io.Writer, options printers.PrintOptions) error { + for _, item := range list.Items { + if err := printControllerRevision(&item, w, options); err != nil { + return err + } + } + return nil +} diff --git a/pkg/printers/internalversion/printers_test.go b/pkg/printers/internalversion/printers_test.go index ff940fb278e2f..e55071b947e7b 100644 --- a/pkg/printers/internalversion/printers_test.go +++ b/pkg/printers/internalversion/printers_test.go @@ -40,6 +40,7 @@ import ( "k8s.io/kubernetes/pkg/api" "k8s.io/kubernetes/pkg/api/testapi" "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/pkg/apis/apps" "k8s.io/kubernetes/pkg/apis/autoscaling" "k8s.io/kubernetes/pkg/apis/batch" "k8s.io/kubernetes/pkg/apis/extensions" @@ -2257,3 +2258,80 @@ func TestAllowMissingKeys(t *testing.T) { } } } + +func TestPrintControllerRevision(t *testing.T) { + tests := []struct { + history apps.ControllerRevision + expect string + }{ + { + apps.ControllerRevision{ + ObjectMeta: metav1.ObjectMeta{ + Name: "test1", + CreationTimestamp: metav1.Time{Time: time.Now().Add(1.9e9)}, + OwnerReferences: []metav1.OwnerReference{ + { + Controller: boolP(true), + Kind: "DaemonSet", + Name: "foo", + }, + }, + }, + Revision: 1, + }, + "test1\tDaemonSet/foo\t1\t0s\n", + }, + { + apps.ControllerRevision{ + ObjectMeta: metav1.ObjectMeta{ + Name: "test2", + CreationTimestamp: metav1.Time{Time: time.Now().Add(1.9e9)}, + OwnerReferences: []metav1.OwnerReference{ + { + Controller: boolP(false), + Kind: "ABC", + Name: "foo", + }, + }, + }, + Revision: 2, + }, + "test2\t\t2\t0s\n", + }, + { + apps.ControllerRevision{ + ObjectMeta: metav1.ObjectMeta{ + Name: "test3", + CreationTimestamp: metav1.Time{Time: time.Now().Add(1.9e9)}, + OwnerReferences: []metav1.OwnerReference{}, + }, + Revision: 3, + }, + "test3\t\t3\t0s\n", + }, + { + apps.ControllerRevision{ + ObjectMeta: metav1.ObjectMeta{ + Name: "test4", + CreationTimestamp: metav1.Time{Time: time.Now().Add(1.9e9)}, + OwnerReferences: nil, + }, + Revision: 4, + }, + "test4\t\t4\t0s\n", + }, + } + + buf := bytes.NewBuffer([]byte{}) + for _, test := range tests { + printControllerRevision(&test.history, buf, printers.PrintOptions{}) + if buf.String() != test.expect { + t.Fatalf("Expected: %s, but got: %s", test.expect, buf.String()) + } + buf.Reset() + } +} + +func boolP(b bool) *bool { + return &b +} diff --git a/pkg/proxy/healthcheck/healthcheck.go b/pkg/proxy/healthcheck/healthcheck.go index c7187a6908fd5..39f10f71a266d 100644 --- a/pkg/proxy/healthcheck/healthcheck.go +++ b/pkg/proxy/healthcheck/healthcheck.go @@ -197,7 +197,13 @@ var _ http.Handler = hcHandler{} func (h hcHandler) ServeHTTP(resp http.ResponseWriter, req *http.Request) { h.hcs.lock.Lock() - count := h.hcs.services[h.name].endpoints + svc, ok := h.hcs.services[h.name] + if !ok || svc == nil { + h.hcs.lock.Unlock() + glog.Errorf("Received request for closed healthcheck %q", h.name.String()) + return + } + count := svc.endpoints h.hcs.lock.Unlock() resp.Header().Set("Content-Type", "application/json") diff --git a/pkg/proxy/iptables/proxier.go b/pkg/proxy/iptables/proxier.go index 1677697338654..6f2f71e5fe6b3 100644 --- a/pkg/proxy/iptables/proxier.go +++ b/pkg/proxy/iptables/proxier.go @@ -148,12 +148,39 @@ type serviceInfo struct { loadBalancerSourceRanges []string onlyNodeLocalEndpoints bool healthCheckNodePort int + // The following fields are computed and stored for performance reasons. + serviceNameString string + servicePortChainName utiliptables.Chain + serviceFirewallChainName utiliptables.Chain + serviceLBChainName utiliptables.Chain } // internal struct for endpoints information type endpointsInfo struct { endpoint string // TODO: should be an endpointString type isLocal bool + // The following fields we lazily compute and store here for performance + // reasons. If the protocol is the same as you expect it to be, then the + // chainName can be reused, otherwise it should be recomputed. + protocol string + chainName utiliptables.Chain +} + +// Returns just the IP part of the endpoint. +func (e *endpointsInfo) IPPart() string { + if index := strings.Index(e.endpoint, ":"); index != -1 { + return e.endpoint[0:index] + } + return e.endpoint +} + +// Returns the endpoint chain name for a given endpointsInfo. +func (e *endpointsInfo) endpointChain(svcNameString, protocol string) utiliptables.Chain { + if e.protocol != protocol { + e.protocol = protocol + e.chainName = servicePortEndpointChainName(svcNameString, protocol, e.endpoint) + } + return e.chainName } func (e *endpointsInfo) String() string { @@ -192,6 +219,13 @@ func newServiceInfo(svcPortName proxy.ServicePortName, port *api.ServicePort, se } } + // Store the following for performance reasons. + protocol := strings.ToLower(string(info.protocol)) + info.serviceNameString = svcPortName.String() + info.servicePortChainName = servicePortChainName(info.serviceNameString, protocol) + info.serviceFirewallChainName = serviceFirewallChainName(info.serviceNameString, protocol) + info.serviceLBChainName = serviceLBChainName(info.serviceNameString, protocol) + return info } @@ -346,6 +380,11 @@ type Proxier struct { healthChecker healthcheck.Server healthzServer healthcheck.HealthzUpdater + // Since converting probabilities (floats) to strings is expensive + // and we are using only probabilities in the format of 1/n, we are + // precomputing some number of those and cache for future reuse. + precomputedProbabilities []string + // The following buffers are used to reuse memory and avoid allocations // that are significantly impacting performance. iptablesData *bytes.Buffer @@ -441,27 +480,28 @@ func NewProxier(ipt utiliptables.Interface, healthChecker := healthcheck.NewServer(hostname, recorder, nil, nil) // use default implementations of deps proxier := &Proxier{ - portsMap: make(map[localPort]closeable), - serviceMap: make(proxyServiceMap), - serviceChanges: newServiceChangeMap(), - endpointsMap: make(proxyEndpointsMap), - endpointsChanges: newEndpointsChangeMap(hostname), - iptables: ipt, - masqueradeAll: masqueradeAll, - masqueradeMark: masqueradeMark, - exec: exec, - clusterCIDR: clusterCIDR, - hostname: hostname, - nodeIP: nodeIP, - portMapper: &listenPortOpener{}, - recorder: recorder, - healthChecker: healthChecker, - healthzServer: healthzServer, - iptablesData: bytes.NewBuffer(nil), - filterChains: bytes.NewBuffer(nil), - filterRules: bytes.NewBuffer(nil), - natChains: bytes.NewBuffer(nil), - natRules: bytes.NewBuffer(nil), + portsMap: make(map[localPort]closeable), + serviceMap: make(proxyServiceMap), + serviceChanges: newServiceChangeMap(), + endpointsMap: make(proxyEndpointsMap), + endpointsChanges: newEndpointsChangeMap(hostname), + iptables: ipt, + masqueradeAll: masqueradeAll, + masqueradeMark: masqueradeMark, + exec: exec, + clusterCIDR: clusterCIDR, + hostname: hostname, + nodeIP: nodeIP, + portMapper: &listenPortOpener{}, + recorder: recorder, + healthChecker: healthChecker, + healthzServer: healthzServer, + precomputedProbabilities: make([]string, 0, 1001), + iptablesData: bytes.NewBuffer(nil), + filterChains: bytes.NewBuffer(nil), + filterRules: bytes.NewBuffer(nil), + natChains: bytes.NewBuffer(nil), + natRules: bytes.NewBuffer(nil), } burstSyncs := 2 glog.V(3).Infof("minSyncPeriod: %v, syncPeriod: %v, burstSyncs: %d", minSyncPeriod, syncPeriod, burstSyncs) @@ -557,6 +597,28 @@ func CleanupLeftovers(ipt utiliptables.Interface) (encounteredError bool) { return encounteredError } +func computeProbability(n int) string { + return fmt.Sprintf("%0.5f", 1.0/float64(n)) +} + +// This assumes proxier.mu is held +func (proxier *Proxier) precomputeProbabilities(numberOfPrecomputed int) { + if len(proxier.precomputedProbabilities) == 0 { + proxier.precomputedProbabilities = append(proxier.precomputedProbabilities, "") + } + for i := len(proxier.precomputedProbabilities); i <= numberOfPrecomputed; i++ { + proxier.precomputedProbabilities = append(proxier.precomputedProbabilities, computeProbability(i)) + } +} + +// This assumes proxier.mu is held +func (proxier *Proxier) probability(n int) string { + if n >= len(proxier.precomputedProbabilities) { + proxier.precomputeProbabilities(n) + } + return proxier.precomputedProbabilities[n] +} + // Sync is called to synchronize the proxier state to iptables as soon as possible. func (proxier *Proxier) Sync() { proxier.syncRunner.Run() @@ -751,8 +813,7 @@ func getLocalIPs(endpointsMap proxyEndpointsMap) map[types.NamespacedName]sets.S if localIPs[nsn] == nil { localIPs[nsn] = sets.NewString() } - ip := strings.Split(ep.endpoint, ":")[0] // just the IP part - localIPs[nsn].Insert(ip) + localIPs[nsn].Insert(ep.IPPart()) // just the IP part } } } @@ -873,6 +934,13 @@ type endpointServicePair struct { servicePortName proxy.ServicePortName } +func (esp *endpointServicePair) IPPart() string { + if index := strings.Index(esp.endpoint, ":"); index != -1 { + return esp.endpoint[0:index] + } + return esp.endpoint +} + const noConnectionToDelete = "0 flow entries have been deleted" // After a UDP endpoint has been removed, we must flush any pending conntrack entries to it, or else we @@ -881,7 +949,7 @@ const noConnectionToDelete = "0 flow entries have been deleted" func (proxier *Proxier) deleteEndpointConnections(connectionMap map[endpointServicePair]bool) { for epSvcPair := range connectionMap { if svcInfo, ok := proxier.serviceMap[epSvcPair.servicePortName]; ok && svcInfo.protocol == api.ProtocolUDP { - endpointIP := strings.Split(epSvcPair.endpoint, ":")[0] + endpointIP := epSvcPair.endpoint[0:strings.Index(epSvcPair.endpoint, ":")] glog.V(2).Infof("Deleting connection tracking state for service IP %s, endpoint IP %s", svcInfo.clusterIP.String(), endpointIP) err := utilproxy.ExecConntrackTool(proxier.exec, "-D", "--orig-dst", svcInfo.clusterIP.String(), "--dst-nat", endpointIP, "-p", "udp") if err != nil && !strings.Contains(err.Error(), noConnectionToDelete) { @@ -1053,15 +1121,28 @@ func (proxier *Proxier) syncProxyRules() { // Accumulate the set of local ports that we will be holding open once this update is complete replacementPortsMap := map[localPort]closeable{} + // We are creating those slices ones here to avoid memory reallocations + // in every loop. Note that reuse the memory, instead of doing: + // slice = + // you should always do one of the below: + // slice = slice[:0] // and then append to it + // slice = append(slice[:0], ...) + endpoints := make([]*endpointsInfo, 0) + endpointChains := make([]utiliptables.Chain, 0) + // To avoid growing this slice, we arbitrarily set its size to 64, + // there is never more than that many arguments for a single line. + // Note that even if we go over 64, it will still be correct - it + // is just for efficiency, not correctness. + args := make([]string, 64) + // Build rules for each service. + var svcNameString string for svcName, svcInfo := range proxier.serviceMap { protocol := strings.ToLower(string(svcInfo.protocol)) - // Precompute svcNameString; with many services the many calls - // to ServicePortName.String() show up in CPU profiles. - svcNameString := svcName.String() + svcNameString = svcInfo.serviceNameString // Create the per-service chain, retaining counters if possible. - svcChain := servicePortChainName(svcNameString, protocol) + svcChain := svcInfo.servicePortChainName if chain, ok := existingNATChains[svcChain]; ok { writeLine(proxier.natChains, chain) } else { @@ -1069,7 +1150,7 @@ func (proxier *Proxier) syncProxyRules() { } activeNATChains[svcChain] = true - svcXlbChain := serviceLBChainName(svcNameString, protocol) + svcXlbChain := svcInfo.serviceLBChainName if svcInfo.onlyNodeLocalEndpoints { // Only for services request OnlyLocal traffic // create the per-service LB chain, retaining counters if possible. @@ -1085,13 +1166,13 @@ func (proxier *Proxier) syncProxyRules() { } // Capture the clusterIP. - args := []string{ + args = append(args[:0], "-A", string(kubeServicesChain), "-m", "comment", "--comment", fmt.Sprintf(`"%s cluster IP"`, svcNameString), "-m", protocol, "-p", protocol, "-d", fmt.Sprintf("%s/32", svcInfo.clusterIP.String()), - "--dport", fmt.Sprintf("%d", svcInfo.port), - } + "--dport", strconv.Itoa(svcInfo.port), + ) if proxier.masqueradeAll { writeLine(proxier.natRules, append(args, "-j", string(KubeMarkMasqChain))...) } @@ -1135,13 +1216,13 @@ func (proxier *Proxier) syncProxyRules() { replacementPortsMap[lp] = socket } } // We're holding the port, so it's OK to install iptables rules. - args := []string{ + args = append(args[:0], "-A", string(kubeServicesChain), "-m", "comment", "--comment", fmt.Sprintf(`"%s external IP"`, svcNameString), "-m", protocol, "-p", protocol, "-d", fmt.Sprintf("%s/32", externalIP), - "--dport", fmt.Sprintf("%d", svcInfo.port), - } + "--dport", strconv.Itoa(svcInfo.port), + ) // We have to SNAT packets to external IPs. writeLine(proxier.natRules, append(args, "-j", string(KubeMarkMasqChain))...) @@ -1166,17 +1247,17 @@ func (proxier *Proxier) syncProxyRules() { "-m", "comment", "--comment", fmt.Sprintf(`"%s has no endpoints"`, svcNameString), "-m", protocol, "-p", protocol, "-d", fmt.Sprintf("%s/32", externalIP), - "--dport", fmt.Sprintf("%d", svcInfo.port), + "--dport", strconv.Itoa(svcInfo.port), "-j", "REJECT", ) } } // Capture load-balancer ingress. + fwChain := svcInfo.serviceFirewallChainName for _, ingress := range svcInfo.loadBalancerStatus.Ingress { if ingress.IP != "" { // create service firewall chain - fwChain := serviceFirewallChainName(svcNameString, protocol) if chain, ok := existingNATChains[fwChain]; ok { writeLine(proxier.natChains, chain) } else { @@ -1187,20 +1268,20 @@ func (proxier *Proxier) syncProxyRules() { // This currently works for loadbalancers that preserves source ips. // For loadbalancers which direct traffic to service NodePort, the firewall rules will not apply. - args := []string{ + args = append(args[:0], "-A", string(kubeServicesChain), "-m", "comment", "--comment", fmt.Sprintf(`"%s loadbalancer IP"`, svcNameString), "-m", protocol, "-p", protocol, "-d", fmt.Sprintf("%s/32", ingress.IP), - "--dport", fmt.Sprintf("%d", svcInfo.port), - } + "--dport", strconv.Itoa(svcInfo.port), + ) // jump to service firewall chain writeLine(proxier.natRules, append(args, "-j", string(fwChain))...) - args = []string{ + args = append(args[:0], "-A", string(fwChain), "-m", "comment", "--comment", fmt.Sprintf(`"%s loadbalancer IP"`, svcNameString), - } + ) // Each source match rule in the FW chain may jump to either the SVC or the XLB chain chosenChain := svcXlbChain @@ -1266,12 +1347,12 @@ func (proxier *Proxier) syncProxyRules() { replacementPortsMap[lp] = socket } // We're holding the port, so it's OK to install iptables rules. - args := []string{ + args = append(args[:0], "-A", string(kubeNodePortsChain), "-m", "comment", "--comment", svcNameString, "-m", protocol, "-p", protocol, - "--dport", fmt.Sprintf("%d", svcInfo.nodePort), - } + "--dport", strconv.Itoa(svcInfo.nodePort), + ) if !svcInfo.onlyNodeLocalEndpoints { // Nodeports need SNAT, unless they're local. writeLine(proxier.natRules, append(args, "-j", string(KubeMarkMasqChain))...) @@ -1293,7 +1374,7 @@ func (proxier *Proxier) syncProxyRules() { "-m", "comment", "--comment", fmt.Sprintf(`"%s has no endpoints"`, svcNameString), "-m", "addrtype", "--dst-type", "LOCAL", "-m", protocol, "-p", protocol, - "--dport", fmt.Sprintf("%d", svcInfo.nodePort), + "--dport", strconv.Itoa(svcInfo.nodePort), "-j", "REJECT", ) } @@ -1306,7 +1387,7 @@ func (proxier *Proxier) syncProxyRules() { "-m", "comment", "--comment", fmt.Sprintf(`"%s has no endpoints"`, svcNameString), "-m", protocol, "-p", protocol, "-d", fmt.Sprintf("%s/32", svcInfo.clusterIP.String()), - "--dport", fmt.Sprintf("%d", svcInfo.port), + "--dport", strconv.Itoa(svcInfo.port), "-j", "REJECT", ) continue @@ -1317,11 +1398,12 @@ func (proxier *Proxier) syncProxyRules() { // Generate the per-endpoint chains. We do this in multiple passes so we // can group rules together. // These two slices parallel each other - keep in sync - endpoints := make([]*endpointsInfo, 0) - endpointChains := make([]utiliptables.Chain, 0) + endpoints = endpoints[:0] + endpointChains = endpointChains[:0] + var endpointChain utiliptables.Chain for _, ep := range proxier.endpointsMap[svcName] { endpoints = append(endpoints, ep) - endpointChain := servicePortEndpointChainName(svcNameString, protocol, ep.endpoint) + endpointChain = ep.endpointChain(svcNameString, protocol) endpointChains = append(endpointChains, endpointChain) // Create the endpoint chain, retaining counters if possible. @@ -1340,7 +1422,7 @@ func (proxier *Proxier) syncProxyRules() { "-A", string(svcChain), "-m", "comment", "--comment", svcNameString, "-m", "recent", "--name", string(endpointChain), - "--rcheck", "--seconds", fmt.Sprintf("%d", svcInfo.stickyMaxAgeMinutes*60), "--reap", + "--rcheck", "--seconds", strconv.Itoa(svcInfo.stickyMaxAgeMinutes*60), "--reap", "-j", string(endpointChain)) } } @@ -1349,29 +1431,29 @@ func (proxier *Proxier) syncProxyRules() { n := len(endpointChains) for i, endpointChain := range endpointChains { // Balancing rules in the per-service chain. - args := []string{ + args = append(args[:0], []string{ "-A", string(svcChain), "-m", "comment", "--comment", svcNameString, - } + }...) if i < (n - 1) { // Each rule is a probabilistic match. args = append(args, "-m", "statistic", "--mode", "random", - "--probability", fmt.Sprintf("%0.5f", 1.0/float64(n-i))) + "--probability", proxier.probability(n-i)) } // The final (or only if n == 1) rule is a guaranteed match. args = append(args, "-j", string(endpointChain)) writeLine(proxier.natRules, args...) // Rules in the per-endpoint chain. - args = []string{ + args = append(args[:0], "-A", string(endpointChain), "-m", "comment", "--comment", svcNameString, - } + ) // Handle traffic that loops back to the originator with SNAT. writeLine(proxier.natRules, append(args, - "-s", fmt.Sprintf("%s/32", strings.Split(endpoints[i].endpoint, ":")[0]), + "-s", fmt.Sprintf("%s/32", endpoints[i].IPPart()), "-j", string(KubeMarkMasqChain))...) // Update client-affinity lists. if svcInfo.sessionAffinityType == api.ServiceAffinityClientIP { @@ -1402,42 +1484,42 @@ func (proxier *Proxier) syncProxyRules() { // Service's ClusterIP instead. This happens whether or not we have local // endpoints; only if clusterCIDR is specified if len(proxier.clusterCIDR) > 0 { - args = []string{ + args = append(args[:0], "-A", string(svcXlbChain), "-m", "comment", "--comment", - fmt.Sprintf(`"Redirect pods trying to reach external loadbalancer VIP to clusterIP"`), + `"Redirect pods trying to reach external loadbalancer VIP to clusterIP"`, "-s", proxier.clusterCIDR, "-j", string(svcChain), - } + ) writeLine(proxier.natRules, args...) } numLocalEndpoints := len(localEndpointChains) if numLocalEndpoints == 0 { // Blackhole all traffic since there are no local endpoints - args := []string{ + args = append(args[:0], "-A", string(svcXlbChain), "-m", "comment", "--comment", fmt.Sprintf(`"%s has no local endpoints"`, svcNameString), "-j", string(KubeMarkDropChain), - } + ) writeLine(proxier.natRules, args...) } else { // Setup probability filter rules only over local endpoints for i, endpointChain := range localEndpointChains { // Balancing rules in the per-service chain. - args := []string{ + args = append(args[:0], "-A", string(svcXlbChain), "-m", "comment", "--comment", fmt.Sprintf(`"Balancing rule %d for %s"`, i, svcNameString), - } + ) if i < (numLocalEndpoints - 1) { // Each rule is a probabilistic match. args = append(args, "-m", "statistic", "--mode", "random", - "--probability", fmt.Sprintf("%0.5f", 1.0/float64(numLocalEndpoints-i))) + "--probability", proxier.probability(numLocalEndpoints-i)) } // The final (or only if n == 1) rule is a guaranteed match. args = append(args, "-j", string(endpointChain)) diff --git a/pkg/proxy/iptables/proxier_test.go b/pkg/proxy/iptables/proxier_test.go index 33f2386c4678c..989c244776e20 100644 --- a/pkg/proxy/iptables/proxier_test.go +++ b/pkg/proxy/iptables/proxier_test.go @@ -386,22 +386,23 @@ func NewFakeProxier(ipt utiliptables.Interface) *Proxier { // TODO: Call NewProxier after refactoring out the goroutine // invocation into a Run() method. p := &Proxier{ - exec: &exec.FakeExec{}, - serviceMap: make(proxyServiceMap), - serviceChanges: newServiceChangeMap(), - endpointsMap: make(proxyEndpointsMap), - endpointsChanges: newEndpointsChangeMap(testHostname), - iptables: ipt, - clusterCIDR: "10.0.0.0/24", - hostname: testHostname, - portsMap: make(map[localPort]closeable), - portMapper: &fakePortOpener{[]*localPort{}}, - healthChecker: newFakeHealthChecker(), - iptablesData: bytes.NewBuffer(nil), - filterChains: bytes.NewBuffer(nil), - filterRules: bytes.NewBuffer(nil), - natChains: bytes.NewBuffer(nil), - natRules: bytes.NewBuffer(nil), + exec: &exec.FakeExec{}, + serviceMap: make(proxyServiceMap), + serviceChanges: newServiceChangeMap(), + endpointsMap: make(proxyEndpointsMap), + endpointsChanges: newEndpointsChangeMap(testHostname), + iptables: ipt, + clusterCIDR: "10.0.0.0/24", + hostname: testHostname, + portsMap: make(map[localPort]closeable), + portMapper: &fakePortOpener{[]*localPort{}}, + healthChecker: newFakeHealthChecker(), + precomputedProbabilities: make([]string, 0, 1001), + iptablesData: bytes.NewBuffer(nil), + filterChains: bytes.NewBuffer(nil), + filterRules: bytes.NewBuffer(nil), + natChains: bytes.NewBuffer(nil), + natRules: bytes.NewBuffer(nil), } p.syncRunner = async.NewBoundedFrequencyRunner("test-sync-runner", p.syncProxyRules, 0, time.Minute, 1) return p @@ -1292,7 +1293,7 @@ func Test_getLocalIPs(t *testing.T) { // Case[1]: unnamed port endpointsMap: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", ""): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, expected: map[types.NamespacedName]sets.String{}, @@ -1300,7 +1301,7 @@ func Test_getLocalIPs(t *testing.T) { // Case[2]: unnamed port local endpointsMap: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", ""): { - {"1.1.1.1:11", true}, + {endpoint: "1.1.1.1:11", isLocal: true}, }, }, expected: map[types.NamespacedName]sets.String{ @@ -1310,12 +1311,12 @@ func Test_getLocalIPs(t *testing.T) { // Case[3]: named local and non-local ports for the same IP. endpointsMap: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, - {"1.1.1.2:11", true}, + {endpoint: "1.1.1.1:11", isLocal: false}, + {endpoint: "1.1.1.2:11", isLocal: true}, }, makeServicePortName("ns1", "ep1", "p12"): { - {"1.1.1.1:12", false}, - {"1.1.1.2:12", true}, + {endpoint: "1.1.1.1:12", isLocal: false}, + {endpoint: "1.1.1.2:12", isLocal: true}, }, }, expected: map[types.NamespacedName]sets.String{ @@ -1325,21 +1326,21 @@ func Test_getLocalIPs(t *testing.T) { // Case[4]: named local and non-local ports for different IPs. endpointsMap: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, makeServicePortName("ns2", "ep2", "p22"): { - {"2.2.2.2:22", true}, - {"2.2.2.22:22", true}, + {endpoint: "2.2.2.2:22", isLocal: true}, + {endpoint: "2.2.2.22:22", isLocal: true}, }, makeServicePortName("ns2", "ep2", "p23"): { - {"2.2.2.3:23", true}, + {endpoint: "2.2.2.3:23", isLocal: true}, }, makeServicePortName("ns4", "ep4", "p44"): { - {"4.4.4.4:44", true}, - {"4.4.4.5:44", false}, + {endpoint: "4.4.4.4:44", isLocal: true}, + {endpoint: "4.4.4.5:44", isLocal: false}, }, makeServicePortName("ns4", "ep4", "p45"): { - {"4.4.4.6:45", true}, + {endpoint: "4.4.4.6:45", isLocal: true}, }, }, expected: map[types.NamespacedName]sets.String{ @@ -1384,7 +1385,7 @@ func Test_endpointsToEndpointsMap(t *testing.T) { }), expected: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", ""): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, }, { @@ -1404,7 +1405,7 @@ func Test_endpointsToEndpointsMap(t *testing.T) { }), expected: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "port"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, }, { @@ -1423,7 +1424,7 @@ func Test_endpointsToEndpointsMap(t *testing.T) { }), expected: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", ""): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, }, { @@ -1452,12 +1453,12 @@ func Test_endpointsToEndpointsMap(t *testing.T) { }), expected: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p1"): { - {"1.1.1.1:11", false}, - {"2.2.2.2:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, + {endpoint: "2.2.2.2:11", isLocal: false}, }, makeServicePortName("ns1", "ep1", "p2"): { - {"1.1.1.1:22", false}, - {"2.2.2.2:22", false}, + {endpoint: "1.1.1.1:22", isLocal: false}, + {endpoint: "2.2.2.2:22", isLocal: false}, }, }, }, { @@ -1477,7 +1478,7 @@ func Test_endpointsToEndpointsMap(t *testing.T) { }), expected: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p1"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, }, { @@ -1497,7 +1498,7 @@ func Test_endpointsToEndpointsMap(t *testing.T) { }), expected: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p2"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, }, { @@ -1517,7 +1518,7 @@ func Test_endpointsToEndpointsMap(t *testing.T) { }), expected: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p1"): { - {"1.1.1.1:22", false}, + {endpoint: "1.1.1.1:22", isLocal: false}, }, }, }} @@ -1931,12 +1932,12 @@ func Test_updateEndpointsMap(t *testing.T) { }, oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", ""): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", ""): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, expectedStale: []endpointServicePair{}, @@ -1951,12 +1952,12 @@ func Test_updateEndpointsMap(t *testing.T) { }, oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", true}, + {endpoint: "1.1.1.1:11", isLocal: true}, }, }, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", true}, + {endpoint: "1.1.1.1:11", isLocal: true}, }, }, expectedStale: []endpointServicePair{}, @@ -1973,18 +1974,18 @@ func Test_updateEndpointsMap(t *testing.T) { }, oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, makeServicePortName("ns1", "ep1", "p12"): { - {"1.1.1.2:12", false}, + {endpoint: "1.1.1.2:12", isLocal: false}, }, }, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, makeServicePortName("ns1", "ep1", "p12"): { - {"1.1.1.2:12", false}, + {endpoint: "1.1.1.2:12", isLocal: false}, }, }, expectedStale: []endpointServicePair{}, @@ -1999,24 +2000,24 @@ func Test_updateEndpointsMap(t *testing.T) { }, oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", true}, + {endpoint: "1.1.1.1:11", isLocal: true}, }, makeServicePortName("ns1", "ep1", "p12"): { - {"1.1.1.1:12", true}, + {endpoint: "1.1.1.1:12", isLocal: true}, }, makeServicePortName("ns1", "ep1", "p13"): { - {"1.1.1.3:13", false}, + {endpoint: "1.1.1.3:13", isLocal: false}, }, }, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", true}, + {endpoint: "1.1.1.1:11", isLocal: true}, }, makeServicePortName("ns1", "ep1", "p12"): { - {"1.1.1.1:12", true}, + {endpoint: "1.1.1.1:12", isLocal: true}, }, makeServicePortName("ns1", "ep1", "p13"): { - {"1.1.1.3:13", false}, + {endpoint: "1.1.1.3:13", isLocal: false}, }, }, expectedStale: []endpointServicePair{}, @@ -2035,54 +2036,54 @@ func Test_updateEndpointsMap(t *testing.T) { }, oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, - {"1.1.1.2:11", true}, + {endpoint: "1.1.1.1:11", isLocal: false}, + {endpoint: "1.1.1.2:11", isLocal: true}, }, makeServicePortName("ns1", "ep1", "p12"): { - {"1.1.1.1:12", false}, - {"1.1.1.2:12", true}, + {endpoint: "1.1.1.1:12", isLocal: false}, + {endpoint: "1.1.1.2:12", isLocal: true}, }, makeServicePortName("ns1", "ep1", "p13"): { - {"1.1.1.3:13", false}, - {"1.1.1.4:13", true}, + {endpoint: "1.1.1.3:13", isLocal: false}, + {endpoint: "1.1.1.4:13", isLocal: true}, }, makeServicePortName("ns1", "ep1", "p14"): { - {"1.1.1.3:14", false}, - {"1.1.1.4:14", true}, + {endpoint: "1.1.1.3:14", isLocal: false}, + {endpoint: "1.1.1.4:14", isLocal: true}, }, makeServicePortName("ns2", "ep2", "p21"): { - {"2.2.2.1:21", false}, - {"2.2.2.2:21", true}, + {endpoint: "2.2.2.1:21", isLocal: false}, + {endpoint: "2.2.2.2:21", isLocal: true}, }, makeServicePortName("ns2", "ep2", "p22"): { - {"2.2.2.1:22", false}, - {"2.2.2.2:22", true}, + {endpoint: "2.2.2.1:22", isLocal: false}, + {endpoint: "2.2.2.2:22", isLocal: true}, }, }, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, - {"1.1.1.2:11", true}, + {endpoint: "1.1.1.1:11", isLocal: false}, + {endpoint: "1.1.1.2:11", isLocal: true}, }, makeServicePortName("ns1", "ep1", "p12"): { - {"1.1.1.1:12", false}, - {"1.1.1.2:12", true}, + {endpoint: "1.1.1.1:12", isLocal: false}, + {endpoint: "1.1.1.2:12", isLocal: true}, }, makeServicePortName("ns1", "ep1", "p13"): { - {"1.1.1.3:13", false}, - {"1.1.1.4:13", true}, + {endpoint: "1.1.1.3:13", isLocal: false}, + {endpoint: "1.1.1.4:13", isLocal: true}, }, makeServicePortName("ns1", "ep1", "p14"): { - {"1.1.1.3:14", false}, - {"1.1.1.4:14", true}, + {endpoint: "1.1.1.3:14", isLocal: false}, + {endpoint: "1.1.1.4:14", isLocal: true}, }, makeServicePortName("ns2", "ep2", "p21"): { - {"2.2.2.1:21", false}, - {"2.2.2.2:21", true}, + {endpoint: "2.2.2.1:21", isLocal: false}, + {endpoint: "2.2.2.2:21", isLocal: true}, }, makeServicePortName("ns2", "ep2", "p22"): { - {"2.2.2.1:22", false}, - {"2.2.2.2:22", true}, + {endpoint: "2.2.2.1:22", isLocal: false}, + {endpoint: "2.2.2.2:22", isLocal: true}, }, }, expectedStale: []endpointServicePair{}, @@ -2101,7 +2102,7 @@ func Test_updateEndpointsMap(t *testing.T) { oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{}, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", ""): { - {"1.1.1.1:11", true}, + {endpoint: "1.1.1.1:11", isLocal: true}, }, }, expectedStale: []endpointServicePair{}, @@ -2118,7 +2119,7 @@ func Test_updateEndpointsMap(t *testing.T) { }, oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", ""): { - {"1.1.1.1:11", true}, + {endpoint: "1.1.1.1:11", isLocal: true}, }, }, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{}, @@ -2137,17 +2138,17 @@ func Test_updateEndpointsMap(t *testing.T) { }, oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, - {"1.1.1.2:11", true}, + {endpoint: "1.1.1.1:11", isLocal: false}, + {endpoint: "1.1.1.2:11", isLocal: true}, }, makeServicePortName("ns1", "ep1", "p12"): { - {"1.1.1.1:12", false}, - {"1.1.1.2:12", true}, + {endpoint: "1.1.1.1:12", isLocal: false}, + {endpoint: "1.1.1.2:12", isLocal: true}, }, }, expectedStale: []endpointServicePair{}, @@ -2164,17 +2165,17 @@ func Test_updateEndpointsMap(t *testing.T) { }, oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, - {"1.1.1.2:11", true}, + {endpoint: "1.1.1.1:11", isLocal: false}, + {endpoint: "1.1.1.2:11", isLocal: true}, }, makeServicePortName("ns1", "ep1", "p12"): { - {"1.1.1.1:12", false}, - {"1.1.1.2:12", true}, + {endpoint: "1.1.1.1:12", isLocal: false}, + {endpoint: "1.1.1.2:12", isLocal: true}, }, }, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, expectedStale: []endpointServicePair{{ @@ -2198,15 +2199,15 @@ func Test_updateEndpointsMap(t *testing.T) { }, oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, makeServicePortName("ns1", "ep1", "p12"): { - {"1.1.1.2:12", true}, + {endpoint: "1.1.1.2:12", isLocal: true}, }, }, expectedStale: []endpointServicePair{}, @@ -2223,15 +2224,15 @@ func Test_updateEndpointsMap(t *testing.T) { }, oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, makeServicePortName("ns1", "ep1", "p12"): { - {"1.1.1.2:12", false}, + {endpoint: "1.1.1.2:12", isLocal: false}, }, }, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, expectedStale: []endpointServicePair{{ @@ -2249,12 +2250,12 @@ func Test_updateEndpointsMap(t *testing.T) { }, oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11-2"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, expectedStale: []endpointServicePair{{ @@ -2272,12 +2273,12 @@ func Test_updateEndpointsMap(t *testing.T) { }, oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, }, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:22", false}, + {endpoint: "1.1.1.1:22", isLocal: false}, }, }, expectedStale: []endpointServicePair{{ @@ -2301,39 +2302,39 @@ func Test_updateEndpointsMap(t *testing.T) { }, oldEndpoints: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, }, makeServicePortName("ns2", "ep2", "p22"): { - {"2.2.2.2:22", true}, - {"2.2.2.22:22", true}, + {endpoint: "2.2.2.2:22", isLocal: true}, + {endpoint: "2.2.2.22:22", isLocal: true}, }, makeServicePortName("ns2", "ep2", "p23"): { - {"2.2.2.3:23", true}, + {endpoint: "2.2.2.3:23", isLocal: true}, }, makeServicePortName("ns4", "ep4", "p44"): { - {"4.4.4.4:44", true}, - {"4.4.4.5:44", true}, + {endpoint: "4.4.4.4:44", isLocal: true}, + {endpoint: "4.4.4.5:44", isLocal: true}, }, makeServicePortName("ns4", "ep4", "p45"): { - {"4.4.4.6:45", true}, + {endpoint: "4.4.4.6:45", isLocal: true}, }, }, expectedResult: map[proxy.ServicePortName][]*endpointsInfo{ makeServicePortName("ns1", "ep1", "p11"): { - {"1.1.1.1:11", false}, - {"1.1.1.11:11", false}, + {endpoint: "1.1.1.1:11", isLocal: false}, + {endpoint: "1.1.1.11:11", isLocal: false}, }, makeServicePortName("ns1", "ep1", "p12"): { - {"1.1.1.2:12", false}, + {endpoint: "1.1.1.2:12", isLocal: false}, }, makeServicePortName("ns1", "ep1", "p122"): { - {"1.1.1.2:122", false}, + {endpoint: "1.1.1.2:122", isLocal: false}, }, makeServicePortName("ns3", "ep3", "p33"): { - {"3.3.3.3:33", false}, + {endpoint: "3.3.3.3:33", isLocal: false}, }, makeServicePortName("ns4", "ep4", "p44"): { - {"4.4.4.4:44", true}, + {endpoint: "4.4.4.4:44", isLocal: true}, }, }, expectedStale: []endpointServicePair{{ diff --git a/pkg/registry/BUILD b/pkg/registry/BUILD index c54063e90115d..77b76f2c059ad 100644 --- a/pkg/registry/BUILD +++ b/pkg/registry/BUILD @@ -24,6 +24,10 @@ filegroup( name = "all-srcs", srcs = [ ":package-srcs", + "//pkg/registry/admissionregistration/externaladmissionhookconfiguration:all-srcs", + "//pkg/registry/admissionregistration/initializerconfiguration:all-srcs", + "//pkg/registry/admissionregistration/rest:all-srcs", + "//pkg/registry/apps/controllerrevision:all-srcs", "//pkg/registry/apps/rest:all-srcs", "//pkg/registry/apps/statefulset:all-srcs", "//pkg/registry/authentication/rest:all-srcs", @@ -69,6 +73,8 @@ filegroup( "//pkg/registry/extensions/rest:all-srcs", "//pkg/registry/extensions/thirdpartyresource:all-srcs", "//pkg/registry/extensions/thirdpartyresourcedata:all-srcs", + "//pkg/registry/networking/networkpolicy:all-srcs", + "//pkg/registry/networking/rest:all-srcs", "//pkg/registry/policy/poddisruptionbudget:all-srcs", "//pkg/registry/policy/rest:all-srcs", "//pkg/registry/rbac:all-srcs", diff --git a/pkg/registry/admissionregistration/externaladmissionhookconfiguration/BUILD b/pkg/registry/admissionregistration/externaladmissionhookconfiguration/BUILD new file mode 100644 index 0000000000000..a699ba6685f4a --- /dev/null +++ b/pkg/registry/admissionregistration/externaladmissionhookconfiguration/BUILD @@ -0,0 +1,46 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "strategy.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/admissionregistration:go_default_library", + "//pkg/apis/admissionregistration/validation:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation/field:go_default_library", + "//vendor/k8s.io/apiserver/pkg/endpoints/request:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage/names:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/registry/admissionregistration/externaladmissionhookconfiguration/storage:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/registry/admissionregistration/externaladmissionhookconfiguration/doc.go b/pkg/registry/admissionregistration/externaladmissionhookconfiguration/doc.go new file mode 100644 index 0000000000000..dcbd2a048c19d --- /dev/null +++ b/pkg/registry/admissionregistration/externaladmissionhookconfiguration/doc.go @@ -0,0 +1,17 @@ +/* +Copyright 2015 The Kubernetes 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. +*/ + +package externaladmissionhookconfiguration // import "k8s.io/kubernetes/pkg/registry/admissionregistration/externaladmissionhookconfiguration" diff --git a/pkg/registry/admissionregistration/externaladmissionhookconfiguration/storage/BUILD b/pkg/registry/admissionregistration/externaladmissionhookconfiguration/storage/BUILD new file mode 100644 index 0000000000000..849d1cdc40aa5 --- /dev/null +++ b/pkg/registry/admissionregistration/externaladmissionhookconfiguration/storage/BUILD @@ -0,0 +1,36 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["storage.go"], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/admissionregistration:go_default_library", + "//pkg/registry/admissionregistration/externaladmissionhookconfiguration:go_default_library", + "//pkg/registry/cachesize:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic/registry:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/registry/admissionregistration/externaladmissionhookconfiguration/storage/storage.go b/pkg/registry/admissionregistration/externaladmissionhookconfiguration/storage/storage.go new file mode 100644 index 0000000000000..0aefa3b452154 --- /dev/null +++ b/pkg/registry/admissionregistration/externaladmissionhookconfiguration/storage/storage.go @@ -0,0 +1,56 @@ +/* +Copyright 2015 The Kubernetes 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. +*/ + +package storage + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apiserver/pkg/registry/generic" + genericregistry "k8s.io/apiserver/pkg/registry/generic/registry" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/admissionregistration" + "k8s.io/kubernetes/pkg/registry/admissionregistration/externaladmissionhookconfiguration" + "k8s.io/kubernetes/pkg/registry/cachesize" +) + +// rest implements a RESTStorage for pod disruption budgets against etcd +type REST struct { + *genericregistry.Store +} + +// NewREST returns a RESTStorage object that will work against pod disruption budgets. +func NewREST(optsGetter generic.RESTOptionsGetter) *REST { + store := &genericregistry.Store{ + Copier: api.Scheme, + NewFunc: func() runtime.Object { return &admissionregistration.ExternalAdmissionHookConfiguration{} }, + NewListFunc: func() runtime.Object { return &admissionregistration.ExternalAdmissionHookConfigurationList{} }, + ObjectNameFunc: func(obj runtime.Object) (string, error) { + return obj.(*admissionregistration.ExternalAdmissionHookConfiguration).Name, nil + }, + PredicateFunc: externaladmissionhookconfiguration.MatchExternalAdmissionHookConfiguration, + QualifiedResource: admissionregistration.Resource("externaladmissionhookconfigurations"), + WatchCacheSize: cachesize.GetWatchCacheSizeByResource("externaladmissionhookconfigurations"), + + CreateStrategy: externaladmissionhookconfiguration.Strategy, + UpdateStrategy: externaladmissionhookconfiguration.Strategy, + DeleteStrategy: externaladmissionhookconfiguration.Strategy, + } + options := &generic.StoreOptions{RESTOptions: optsGetter, AttrFunc: externaladmissionhookconfiguration.GetAttrs} + if err := store.CompleteWithOptions(options); err != nil { + panic(err) // TODO: Propagate error up + } + return &REST{store} +} diff --git a/pkg/registry/admissionregistration/externaladmissionhookconfiguration/strategy.go b/pkg/registry/admissionregistration/externaladmissionhookconfiguration/strategy.go new file mode 100644 index 0000000000000..eaa997206bd4c --- /dev/null +++ b/pkg/registry/admissionregistration/externaladmissionhookconfiguration/strategy.go @@ -0,0 +1,120 @@ +/* +Copyright 2014 The Kubernetes 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. +*/ + +package externaladmissionhookconfiguration + +import ( + "fmt" + "reflect" + + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/validation/field" + genericapirequest "k8s.io/apiserver/pkg/endpoints/request" + "k8s.io/apiserver/pkg/registry/generic" + apistorage "k8s.io/apiserver/pkg/storage" + "k8s.io/apiserver/pkg/storage/names" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/admissionregistration" + "k8s.io/kubernetes/pkg/apis/admissionregistration/validation" +) + +// externaladmissionhookConfigurationStrategy implements verification logic for ExternalAdmissionHookConfiguration. +type externaladmissionhookConfigurationStrategy struct { + runtime.ObjectTyper + names.NameGenerator +} + +// Strategy is the default logic that applies when creating and updating ExternalAdmissionHookConfiguration objects. +var Strategy = externaladmissionhookConfigurationStrategy{api.Scheme, names.SimpleNameGenerator} + +// NamespaceScoped returns true because all ExternalAdmissionHookConfiguration' need to be within a namespace. +func (externaladmissionhookConfigurationStrategy) NamespaceScoped() bool { + return false +} + +// PrepareForCreate clears the status of an ExternalAdmissionHookConfiguration before creation. +func (externaladmissionhookConfigurationStrategy) PrepareForCreate(ctx genericapirequest.Context, obj runtime.Object) { + ic := obj.(*admissionregistration.ExternalAdmissionHookConfiguration) + ic.Generation = 1 +} + +// PrepareForUpdate clears fields that are not allowed to be set by end users on update. +func (externaladmissionhookConfigurationStrategy) PrepareForUpdate(ctx genericapirequest.Context, obj, old runtime.Object) { + newIC := obj.(*admissionregistration.ExternalAdmissionHookConfiguration) + oldIC := old.(*admissionregistration.ExternalAdmissionHookConfiguration) + + // Any changes to the spec increment the generation number, any changes to the + // status should reflect the generation number of the corresponding object. + // See metav1.ObjectMeta description for more information on Generation. + if !reflect.DeepEqual(oldIC.ExternalAdmissionHooks, newIC.ExternalAdmissionHooks) { + newIC.Generation = oldIC.Generation + 1 + } +} + +// Validate validates a new ExternalAdmissionHookConfiguration. +func (externaladmissionhookConfigurationStrategy) Validate(ctx genericapirequest.Context, obj runtime.Object) field.ErrorList { + ic := obj.(*admissionregistration.ExternalAdmissionHookConfiguration) + return validation.ValidateExternalAdmissionHookConfiguration(ic) +} + +// Canonicalize normalizes the object after validation. +func (externaladmissionhookConfigurationStrategy) Canonicalize(obj runtime.Object) { +} + +// AllowCreateOnUpdate is true for ExternalAdmissionHookConfiguration; this means you may create one with a PUT request. +func (externaladmissionhookConfigurationStrategy) AllowCreateOnUpdate() bool { + return false +} + +// ValidateUpdate is the default update validation for an end user. +func (externaladmissionhookConfigurationStrategy) ValidateUpdate(ctx genericapirequest.Context, obj, old runtime.Object) field.ErrorList { + validationErrorList := validation.ValidateExternalAdmissionHookConfiguration(obj.(*admissionregistration.ExternalAdmissionHookConfiguration)) + updateErrorList := validation.ValidateExternalAdmissionHookConfigurationUpdate(obj.(*admissionregistration.ExternalAdmissionHookConfiguration), old.(*admissionregistration.ExternalAdmissionHookConfiguration)) + return append(validationErrorList, updateErrorList...) +} + +// AllowUnconditionalUpdate is the default update policy for ExternalAdmissionHookConfiguration objects. Status update should +// only be allowed if version match. +func (externaladmissionhookConfigurationStrategy) AllowUnconditionalUpdate() bool { + return false +} + +// MatchReplicaSet is the filter used by the generic etcd backend to route +// watch events from etcd to clients of the apiserver only interested in specific +// labels/fields. +func MatchExternalAdmissionHookConfiguration(label labels.Selector, field fields.Selector) apistorage.SelectionPredicate { + return apistorage.SelectionPredicate{ + Label: label, + Field: field, + GetAttrs: GetAttrs, + } +} + +// GetAttrs returns labels and fields of a given object for filtering purposes. +func GetAttrs(obj runtime.Object) (labels.Set, fields.Set, error) { + ic, ok := obj.(*admissionregistration.ExternalAdmissionHookConfiguration) + if !ok { + return nil, nil, fmt.Errorf("Given object is not a ExternalAdmissionHookConfiguration.") + } + return labels.Set(ic.ObjectMeta.Labels), ExternalAdmissionHookConfigurationToSelectableFields(ic), nil +} + +// ExternalAdmissionHookConfigurationToSelectableFields returns a field set that represents the object. +func ExternalAdmissionHookConfigurationToSelectableFields(ic *admissionregistration.ExternalAdmissionHookConfiguration) fields.Set { + return generic.ObjectMetaFieldsSet(&ic.ObjectMeta, true) +} diff --git a/pkg/registry/admissionregistration/initializerconfiguration/BUILD b/pkg/registry/admissionregistration/initializerconfiguration/BUILD new file mode 100644 index 0000000000000..0d42bfc42e69e --- /dev/null +++ b/pkg/registry/admissionregistration/initializerconfiguration/BUILD @@ -0,0 +1,46 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "strategy.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/admissionregistration:go_default_library", + "//pkg/apis/admissionregistration/validation:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation/field:go_default_library", + "//vendor/k8s.io/apiserver/pkg/endpoints/request:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage/names:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/registry/admissionregistration/initializerconfiguration/storage:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/registry/admissionregistration/initializerconfiguration/doc.go b/pkg/registry/admissionregistration/initializerconfiguration/doc.go new file mode 100644 index 0000000000000..7f4cd229b80bc --- /dev/null +++ b/pkg/registry/admissionregistration/initializerconfiguration/doc.go @@ -0,0 +1,17 @@ +/* +Copyright 2015 The Kubernetes 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. +*/ + +package initializerconfiguration // import "k8s.io/kubernetes/pkg/registry/admissionregistration/initializerconfiguration" diff --git a/pkg/registry/admissionregistration/initializerconfiguration/storage/BUILD b/pkg/registry/admissionregistration/initializerconfiguration/storage/BUILD new file mode 100644 index 0000000000000..62ece05490d8d --- /dev/null +++ b/pkg/registry/admissionregistration/initializerconfiguration/storage/BUILD @@ -0,0 +1,36 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["storage.go"], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/admissionregistration:go_default_library", + "//pkg/registry/admissionregistration/initializerconfiguration:go_default_library", + "//pkg/registry/cachesize:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic/registry:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/registry/admissionregistration/initializerconfiguration/storage/storage.go b/pkg/registry/admissionregistration/initializerconfiguration/storage/storage.go new file mode 100644 index 0000000000000..e7351fc9869ca --- /dev/null +++ b/pkg/registry/admissionregistration/initializerconfiguration/storage/storage.go @@ -0,0 +1,56 @@ +/* +Copyright 2015 The Kubernetes 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. +*/ + +package storage + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apiserver/pkg/registry/generic" + genericregistry "k8s.io/apiserver/pkg/registry/generic/registry" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/admissionregistration" + "k8s.io/kubernetes/pkg/registry/admissionregistration/initializerconfiguration" + "k8s.io/kubernetes/pkg/registry/cachesize" +) + +// rest implements a RESTStorage for pod disruption budgets against etcd +type REST struct { + *genericregistry.Store +} + +// NewREST returns a RESTStorage object that will work against pod disruption budgets. +func NewREST(optsGetter generic.RESTOptionsGetter) *REST { + store := &genericregistry.Store{ + Copier: api.Scheme, + NewFunc: func() runtime.Object { return &admissionregistration.InitializerConfiguration{} }, + NewListFunc: func() runtime.Object { return &admissionregistration.InitializerConfigurationList{} }, + ObjectNameFunc: func(obj runtime.Object) (string, error) { + return obj.(*admissionregistration.InitializerConfiguration).Name, nil + }, + PredicateFunc: initializerconfiguration.MatchInitializerConfiguration, + QualifiedResource: admissionregistration.Resource("initializerconfigurations"), + WatchCacheSize: cachesize.GetWatchCacheSizeByResource("initializerconfigurations"), + + CreateStrategy: initializerconfiguration.Strategy, + UpdateStrategy: initializerconfiguration.Strategy, + DeleteStrategy: initializerconfiguration.Strategy, + } + options := &generic.StoreOptions{RESTOptions: optsGetter, AttrFunc: initializerconfiguration.GetAttrs} + if err := store.CompleteWithOptions(options); err != nil { + panic(err) // TODO: Propagate error up + } + return &REST{store} +} diff --git a/pkg/registry/admissionregistration/initializerconfiguration/strategy.go b/pkg/registry/admissionregistration/initializerconfiguration/strategy.go new file mode 100644 index 0000000000000..c872c13bd99c1 --- /dev/null +++ b/pkg/registry/admissionregistration/initializerconfiguration/strategy.go @@ -0,0 +1,120 @@ +/* +Copyright 2014 The Kubernetes 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. +*/ + +package initializerconfiguration + +import ( + "fmt" + "reflect" + + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/validation/field" + genericapirequest "k8s.io/apiserver/pkg/endpoints/request" + "k8s.io/apiserver/pkg/registry/generic" + apistorage "k8s.io/apiserver/pkg/storage" + "k8s.io/apiserver/pkg/storage/names" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/admissionregistration" + "k8s.io/kubernetes/pkg/apis/admissionregistration/validation" +) + +// initializerConfigurationStrategy implements verification logic for InitializerConfigurations. +type initializerConfigurationStrategy struct { + runtime.ObjectTyper + names.NameGenerator +} + +// Strategy is the default logic that applies when creating and updating InitializerConfiguration objects. +var Strategy = initializerConfigurationStrategy{api.Scheme, names.SimpleNameGenerator} + +// NamespaceScoped returns true because all InitializerConfiguration' need to be within a namespace. +func (initializerConfigurationStrategy) NamespaceScoped() bool { + return false +} + +// PrepareForCreate clears the status of an InitializerConfiguration before creation. +func (initializerConfigurationStrategy) PrepareForCreate(ctx genericapirequest.Context, obj runtime.Object) { + ic := obj.(*admissionregistration.InitializerConfiguration) + ic.Generation = 1 +} + +// PrepareForUpdate clears fields that are not allowed to be set by end users on update. +func (initializerConfigurationStrategy) PrepareForUpdate(ctx genericapirequest.Context, obj, old runtime.Object) { + newIC := obj.(*admissionregistration.InitializerConfiguration) + oldIC := old.(*admissionregistration.InitializerConfiguration) + + // Any changes to the spec increment the generation number, any changes to the + // status should reflect the generation number of the corresponding object. + // See metav1.ObjectMeta description for more information on Generation. + if !reflect.DeepEqual(oldIC.Initializers, newIC.Initializers) { + newIC.Generation = oldIC.Generation + 1 + } +} + +// Validate validates a new InitializerConfiguration. +func (initializerConfigurationStrategy) Validate(ctx genericapirequest.Context, obj runtime.Object) field.ErrorList { + ic := obj.(*admissionregistration.InitializerConfiguration) + return validation.ValidateInitializerConfiguration(ic) +} + +// Canonicalize normalizes the object after validation. +func (initializerConfigurationStrategy) Canonicalize(obj runtime.Object) { +} + +// AllowCreateOnUpdate is true for InitializerConfiguration; this means you may create one with a PUT request. +func (initializerConfigurationStrategy) AllowCreateOnUpdate() bool { + return false +} + +// ValidateUpdate is the default update validation for an end user. +func (initializerConfigurationStrategy) ValidateUpdate(ctx genericapirequest.Context, obj, old runtime.Object) field.ErrorList { + validationErrorList := validation.ValidateInitializerConfiguration(obj.(*admissionregistration.InitializerConfiguration)) + updateErrorList := validation.ValidateInitializerConfigurationUpdate(obj.(*admissionregistration.InitializerConfiguration), old.(*admissionregistration.InitializerConfiguration)) + return append(validationErrorList, updateErrorList...) +} + +// AllowUnconditionalUpdate is the default update policy for InitializerConfiguration objects. Status update should +// only be allowed if version match. +func (initializerConfigurationStrategy) AllowUnconditionalUpdate() bool { + return false +} + +// MatchReplicaSet is the filter used by the generic etcd backend to route +// watch events from etcd to clients of the apiserver only interested in specific +// labels/fields. +func MatchInitializerConfiguration(label labels.Selector, field fields.Selector) apistorage.SelectionPredicate { + return apistorage.SelectionPredicate{ + Label: label, + Field: field, + GetAttrs: GetAttrs, + } +} + +// GetAttrs returns labels and fields of a given object for filtering purposes. +func GetAttrs(obj runtime.Object) (labels.Set, fields.Set, error) { + ic, ok := obj.(*admissionregistration.InitializerConfiguration) + if !ok { + return nil, nil, fmt.Errorf("Given object is not a InitializerConfiguration.") + } + return labels.Set(ic.ObjectMeta.Labels), InitializerConfigurationToSelectableFields(ic), nil +} + +// InitializerConfigurationToSelectableFields returns a field set that represents the object. +func InitializerConfigurationToSelectableFields(ic *admissionregistration.InitializerConfiguration) fields.Set { + return generic.ObjectMetaFieldsSet(&ic.ObjectMeta, true) +} diff --git a/pkg/registry/admissionregistration/rest/BUILD b/pkg/registry/admissionregistration/rest/BUILD new file mode 100644 index 0000000000000..77b4b46241bef --- /dev/null +++ b/pkg/registry/admissionregistration/rest/BUILD @@ -0,0 +1,38 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["storage_apiserver.go"], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/admissionregistration:go_default_library", + "//pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//pkg/registry/admissionregistration/externaladmissionhookconfiguration/storage:go_default_library", + "//pkg/registry/admissionregistration/initializerconfiguration/storage:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/rest:go_default_library", + "//vendor/k8s.io/apiserver/pkg/server:go_default_library", + "//vendor/k8s.io/apiserver/pkg/server/storage:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/registry/admissionregistration/rest/storage_apiserver.go b/pkg/registry/admissionregistration/rest/storage_apiserver.go new file mode 100644 index 0000000000000..a315cabf5d919 --- /dev/null +++ b/pkg/registry/admissionregistration/rest/storage_apiserver.go @@ -0,0 +1,59 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +package rest + +import ( + "k8s.io/apiserver/pkg/registry/generic" + "k8s.io/apiserver/pkg/registry/rest" + genericapiserver "k8s.io/apiserver/pkg/server" + serverstorage "k8s.io/apiserver/pkg/server/storage" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/admissionregistration" + admissionregistrationv1alpha1 "k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1" + externaladmissionhookconfigurationstorage "k8s.io/kubernetes/pkg/registry/admissionregistration/externaladmissionhookconfiguration/storage" + initializerconfigurationstorage "k8s.io/kubernetes/pkg/registry/admissionregistration/initializerconfiguration/storage" +) + +type RESTStorageProvider struct{} + +func (p RESTStorageProvider) NewRESTStorage(apiResourceConfigSource serverstorage.APIResourceConfigSource, restOptionsGetter generic.RESTOptionsGetter) (genericapiserver.APIGroupInfo, bool) { + apiGroupInfo := genericapiserver.NewDefaultAPIGroupInfo(admissionregistration.GroupName, api.Registry, api.Scheme, api.ParameterCodec, api.Codecs) + + if apiResourceConfigSource.AnyResourcesForVersionEnabled(admissionregistrationv1alpha1.SchemeGroupVersion) { + apiGroupInfo.VersionedResourcesStorageMap[admissionregistrationv1alpha1.SchemeGroupVersion.Version] = p.v1alpha1Storage(apiResourceConfigSource, restOptionsGetter) + apiGroupInfo.GroupMeta.GroupVersion = admissionregistrationv1alpha1.SchemeGroupVersion + } + return apiGroupInfo, true +} + +func (p RESTStorageProvider) v1alpha1Storage(apiResourceConfigSource serverstorage.APIResourceConfigSource, restOptionsGetter generic.RESTOptionsGetter) map[string]rest.Storage { + version := admissionregistrationv1alpha1.SchemeGroupVersion + storage := map[string]rest.Storage{} + if apiResourceConfigSource.ResourceEnabled(version.WithResource("initializerconfigurations")) { + s := initializerconfigurationstorage.NewREST(restOptionsGetter) + storage["initializerconfigurations"] = s + } + if apiResourceConfigSource.ResourceEnabled(version.WithResource("externaladmissionhookconfigurations")) { + s := externaladmissionhookconfigurationstorage.NewREST(restOptionsGetter) + storage["externaladmissionhookconfigurations"] = s + } + return storage +} + +func (p RESTStorageProvider) GroupName() string { + return admissionregistration.GroupName +} diff --git a/pkg/registry/apps/controllerrevision/BUILD b/pkg/registry/apps/controllerrevision/BUILD new file mode 100644 index 0000000000000..e656b6cb948f0 --- /dev/null +++ b/pkg/registry/apps/controllerrevision/BUILD @@ -0,0 +1,64 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["strategy_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/apps:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apiserver/pkg/endpoints/request:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "strategy.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/apps:go_default_library", + "//pkg/apis/apps/validation:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation/field:go_default_library", + "//vendor/k8s.io/apiserver/pkg/endpoints/request:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/rest:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage/names:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/registry/apps/controllerrevision/storage:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/registry/apps/controllerrevision/doc.go b/pkg/registry/apps/controllerrevision/doc.go new file mode 100644 index 0000000000000..9c10c8e87c37f --- /dev/null +++ b/pkg/registry/apps/controllerrevision/doc.go @@ -0,0 +1,17 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package controllerrevision // import "k8s.io/kubernetes/pkg/registry/apps/controllerrevision" diff --git a/pkg/registry/apps/controllerrevision/storage/BUILD b/pkg/registry/apps/controllerrevision/storage/BUILD new file mode 100644 index 0000000000000..e892b924e6119 --- /dev/null +++ b/pkg/registry/apps/controllerrevision/storage/BUILD @@ -0,0 +1,55 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["storage_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/apps:go_default_library", + "//pkg/registry/registrytest:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage/etcd/testing:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = ["storage.go"], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/apps:go_default_library", + "//pkg/registry/apps/controllerrevision:go_default_library", + "//pkg/registry/cachesize:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic/registry:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/registry/apps/controllerrevision/storage/storage.go b/pkg/registry/apps/controllerrevision/storage/storage.go new file mode 100644 index 0000000000000..d994c338f2743 --- /dev/null +++ b/pkg/registry/apps/controllerrevision/storage/storage.go @@ -0,0 +1,53 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package storage + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apiserver/pkg/registry/generic" + genericregistry "k8s.io/apiserver/pkg/registry/generic/registry" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/apps" + "k8s.io/kubernetes/pkg/registry/apps/controllerrevision" + "k8s.io/kubernetes/pkg/registry/cachesize" +) + +// REST implements a RESTStorage for ControllerRevision +type REST struct { + *genericregistry.Store +} + +// NewREST returns a RESTStorage object that will work with ControllerRevision objects. +func NewREST(optsGetter generic.RESTOptionsGetter) *REST { + store := &genericregistry.Store{ + Copier: api.Scheme, + NewFunc: func() runtime.Object { return &apps.ControllerRevision{} }, + NewListFunc: func() runtime.Object { return &apps.ControllerRevisionList{} }, + PredicateFunc: controllerrevision.MatchControllerRevision, + QualifiedResource: apps.Resource("controllerrevisions"), + WatchCacheSize: cachesize.GetWatchCacheSizeByResource("controllerrevisions"), + + CreateStrategy: controllerrevision.Strategy, + UpdateStrategy: controllerrevision.Strategy, + DeleteStrategy: controllerrevision.Strategy, + } + options := &generic.StoreOptions{RESTOptions: optsGetter, AttrFunc: controllerrevision.GetAttrs} + if err := store.CompleteWithOptions(options); err != nil { + panic(err) + } + return &REST{store} +} diff --git a/pkg/registry/apps/controllerrevision/storage/storage_test.go b/pkg/registry/apps/controllerrevision/storage/storage_test.go new file mode 100644 index 0000000000000..05abb7a600b12 --- /dev/null +++ b/pkg/registry/apps/controllerrevision/storage/storage_test.go @@ -0,0 +1,182 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package storage + +import ( + "testing" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apiserver/pkg/registry/generic" + etcdtesting "k8s.io/apiserver/pkg/storage/etcd/testing" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/apps" + "k8s.io/kubernetes/pkg/registry/registrytest" +) + +func TestCreate(t *testing.T) { + storage, server := newStorage(t) + defer server.Terminate(t) + defer storage.Store.DestroyFunc() + test := registrytest.New(t, storage.Store) + var ( + valid = stripObjectMeta(newControllerRevision("validname", metav1.NamespaceDefault, newObject(), 0)) + badRevision = stripObjectMeta(newControllerRevision("validname", "validns", newObject(), -1)) + emptyName = stripObjectMeta(newControllerRevision("", "validns", newObject(), 0)) + invalidName = stripObjectMeta(newControllerRevision("NoUppercaseOrSpecialCharsLike=Equals", "validns", newObject(), 0)) + emptyNs = stripObjectMeta(newControllerRevision("validname", "", newObject(), 100)) + invalidNs = stripObjectMeta(newControllerRevision("validname", "NoUppercaseOrSpecialCharsLike=Equals", newObject(), 100)) + nilData = stripObjectMeta(newControllerRevision("validname", "validns", nil, 0)) + ) + test.TestCreate( + valid, + badRevision, + emptyName, + invalidName, + emptyNs, + invalidNs, + nilData) +} + +func TestUpdate(t *testing.T) { + storage, server := newStorage(t) + defer server.Terminate(t) + defer storage.Store.DestroyFunc() + test := registrytest.New(t, storage.Store) + + addLabel := func(obj runtime.Object) runtime.Object { + rev := obj.(*apps.ControllerRevision) + update := &apps.ControllerRevision{ + ObjectMeta: rev.ObjectMeta, + Data: rev.Data, + Revision: rev.Revision, + } + update.ObjectMeta.Labels = map[string]string{"foo": "bar"} + return update + } + + updateData := func(obj runtime.Object) runtime.Object { + rev := obj.(*apps.ControllerRevision) + modified := newObject() + ss := modified.(*apps.StatefulSet) + ss.Name = "cde" + update := &apps.ControllerRevision{ + ObjectMeta: rev.ObjectMeta, + Data: ss, + Revision: rev.Revision + 1, + } + return update + } + + test.TestUpdate(stripObjectMeta(newControllerRevision("validname", metav1.NamespaceDefault, newObject(), 0)), + addLabel, + updateData) +} + +func TestGet(t *testing.T) { + storage, server := newStorage(t) + defer server.Terminate(t) + defer storage.Store.DestroyFunc() + test := registrytest.New(t, storage.Store) + test.TestGet(newControllerRevision("valid", metav1.NamespaceDefault, newObject(), 0)) +} + +func TestList(t *testing.T) { + storage, server := newStorage(t) + defer server.Terminate(t) + defer storage.Store.DestroyFunc() + test := registrytest.New(t, storage.Store) + test.TestList(newControllerRevision("valid", metav1.NamespaceDefault, newObject(), 0)) +} + +func TestDelete(t *testing.T) { + storage, server := newStorage(t) + defer server.Terminate(t) + defer storage.Store.DestroyFunc() + test := registrytest.New(t, storage.Store) + test.TestDelete(newControllerRevision("valid", metav1.NamespaceDefault, newObject(), 0)) +} + +func TestWatch(t *testing.T) { + storage, server := newStorage(t) + defer server.Terminate(t) + defer storage.Store.DestroyFunc() + test := registrytest.New(t, storage.Store) + test.TestWatch( + newControllerRevision("valid", metav1.NamespaceDefault, newObject(), 0), + []labels.Set{ + {"foo": "bar"}, + }, + []labels.Set{ + {"hoo": "baz"}, + }, + []fields.Set{ + {"metadata.name": "valid"}, + }, + []fields.Set{ + {"metadata.name": "nomatch"}, + }, + ) +} + +func newControllerRevision(name, namespace string, data runtime.Object, revision int64) *apps.ControllerRevision { + return &apps.ControllerRevision{ + ObjectMeta: metav1.ObjectMeta{ + Name: name, + Namespace: namespace, + Labels: map[string]string{"foo": "bar"}, + }, + Data: data, + Revision: revision, + } +} + +func stripObjectMeta(revision *apps.ControllerRevision) *apps.ControllerRevision { + revision.ObjectMeta = metav1.ObjectMeta{} + return revision +} + +func newStorage(t *testing.T) (*REST, *etcdtesting.EtcdTestServer) { + etcdStorage, server := registrytest.NewEtcdStorage(t, apps.GroupName) + restOptions := generic.RESTOptions{ + StorageConfig: etcdStorage, + Decorator: generic.UndecoratedStorage, + DeleteCollectionWorkers: 1, + ResourcePrefix: "controllerrevisions"} + storage := NewREST(restOptions) + return storage, server +} + +func newObject() runtime.Object { + return &apps.StatefulSet{ + ObjectMeta: metav1.ObjectMeta{Name: "abc", Namespace: metav1.NamespaceDefault}, + Spec: apps.StatefulSetSpec{ + Selector: &metav1.LabelSelector{MatchLabels: map[string]string{"foo": "bar"}}, + Template: api.PodTemplateSpec{ + Spec: api.PodSpec{ + RestartPolicy: api.RestartPolicyAlways, + DNSPolicy: api.DNSClusterFirst, + }, + ObjectMeta: metav1.ObjectMeta{ + Labels: map[string]string{"foo": "bar"}, + }, + }, + }, + } +} diff --git a/pkg/registry/apps/controllerrevision/strategy.go b/pkg/registry/apps/controllerrevision/strategy.go new file mode 100644 index 0000000000000..86b01fe433936 --- /dev/null +++ b/pkg/registry/apps/controllerrevision/strategy.go @@ -0,0 +1,108 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package controllerrevision + +import ( + "errors" + + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/validation/field" + genericapirequest "k8s.io/apiserver/pkg/endpoints/request" + "k8s.io/apiserver/pkg/registry/generic" + "k8s.io/apiserver/pkg/registry/rest" + apistorage "k8s.io/apiserver/pkg/storage" + "k8s.io/apiserver/pkg/storage/names" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/apps" + "k8s.io/kubernetes/pkg/apis/apps/validation" +) + +// strategy implements behavior for ConfigMap objects +type strategy struct { + runtime.ObjectTyper + names.NameGenerator +} + +// Strategy is the default logic that applies when creating and updating ControllerRevision +// objects via the REST API. +var Strategy = strategy{api.Scheme, names.SimpleNameGenerator} + +// Strategy should implement rest.RESTCreateStrategy +var _ rest.RESTCreateStrategy = Strategy + +// Strategy should implement rest.RESTUpdateStrategy +var _ rest.RESTUpdateStrategy = Strategy + +func (strategy) NamespaceScoped() bool { + return true +} + +func (strategy) Canonicalize(obj runtime.Object) { +} + +func (strategy) AllowCreateOnUpdate() bool { + return false +} + +func (strategy) PrepareForCreate(ctx genericapirequest.Context, obj runtime.Object) { + _ = obj.(*apps.ControllerRevision) +} + +func (strategy) Validate(ctx genericapirequest.Context, obj runtime.Object) field.ErrorList { + revision := obj.(*apps.ControllerRevision) + + return validation.ValidateControllerRevision(revision) +} + +func (strategy) PrepareForUpdate(ctx genericapirequest.Context, newObj, oldObj runtime.Object) { + _ = oldObj.(*apps.ControllerRevision) + _ = newObj.(*apps.ControllerRevision) +} + +func (strategy) AllowUnconditionalUpdate() bool { + return true +} + +func (strategy) ValidateUpdate(ctx genericapirequest.Context, newObj, oldObj runtime.Object) field.ErrorList { + oldRevision, newRevision := oldObj.(*apps.ControllerRevision), newObj.(*apps.ControllerRevision) + return validation.ValidateControllerRevisionUpdate(newRevision, oldRevision) +} + +// ControllerRevisionToSelectableFields returns a field set that represents the object for matching purposes. +func ControllerRevisionToSelectableFields(revision *apps.ControllerRevision) fields.Set { + return generic.ObjectMetaFieldsSet(&revision.ObjectMeta, true) +} + +// GetAttrs returns labels and fields of a given object for filtering purposes. +func GetAttrs(obj runtime.Object) (labels.Set, fields.Set, error) { + history, ok := obj.(*apps.ControllerRevision) + if !ok { + return nil, nil, errors.New("supplied object is not an ControllerRevision") + } + return labels.Set(history.ObjectMeta.Labels), ControllerRevisionToSelectableFields(history), nil +} + +// MatchControllerRevision returns a generic matcher for a given label and field selector. +func MatchControllerRevision(label labels.Selector, field fields.Selector) apistorage.SelectionPredicate { + return apistorage.SelectionPredicate{ + Label: label, + Field: field, + GetAttrs: GetAttrs, + } +} diff --git a/pkg/registry/apps/controllerrevision/strategy_test.go b/pkg/registry/apps/controllerrevision/strategy_test.go new file mode 100644 index 0000000000000..97ce1be419aea --- /dev/null +++ b/pkg/registry/apps/controllerrevision/strategy_test.go @@ -0,0 +1,205 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package controllerrevision + +import ( + "testing" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/apimachinery/pkg/runtime" + genericapirequest "k8s.io/apiserver/pkg/endpoints/request" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/apps" +) + +func TestStrategy_NamespaceScoped(t *testing.T) { + if !Strategy.NamespaceScoped() { + t.Error("ControllerRevision strategy must be namespace scoped") + } +} + +func TestStrategy_AllowCreateOnUpdate(t *testing.T) { + if Strategy.AllowCreateOnUpdate() { + t.Error("ControllerRevision should not be created on update") + } +} + +func TestStrategy_Validate(t *testing.T) { + ctx := genericapirequest.NewDefaultContext() + var ( + valid = newControllerRevision("validname", "validns", newObject(), 0) + badRevision = newControllerRevision("validname", "validns", newObject(), -1) + emptyName = newControllerRevision("", "validns", newObject(), 0) + invalidName = newControllerRevision("NoUppercaseOrSpecialCharsLike=Equals", "validns", newObject(), 0) + emptyNs = newControllerRevision("validname", "", newObject(), 100) + invalidNs = newControllerRevision("validname", "NoUppercaseOrSpecialCharsLike=Equals", newObject(), 100) + nilData = newControllerRevision("validname", "validns", nil, 0) + ) + + tests := map[string]struct { + history *apps.ControllerRevision + isValid bool + }{ + "valid": {valid, true}, + "negative revision": {badRevision, false}, + "empty name": {emptyName, false}, + "invalid name": {invalidName, false}, + "empty namespace": {emptyNs, false}, + "invalid namespace": {invalidNs, false}, + "nil data": {nilData, false}, + } + + for name, tc := range tests { + errs := Strategy.Validate(ctx, tc.history) + if tc.isValid && len(errs) > 0 { + t.Errorf("%v: unexpected error: %v", name, errs) + } + if !tc.isValid && len(errs) == 0 { + t.Errorf("%v: unexpected non-error", name) + } + } +} + +func TestStrategy_ValidateUpdate(t *testing.T) { + ctx := genericapirequest.NewDefaultContext() + var ( + valid = newControllerRevision("validname", "validns", newObject(), 0) + changedData = newControllerRevision("validname", "validns", + func() runtime.Object { + modified := newObject() + ss := modified.(*apps.StatefulSet) + ss.Name = "cde" + return modified + }(), 0) + changedRevision = newControllerRevision("validname", "validns", newObject(), 1) + ) + + cases := []struct { + name string + newHistory *apps.ControllerRevision + oldHistory *apps.ControllerRevision + isValid bool + }{ + { + name: "valid", + newHistory: valid, + oldHistory: valid, + isValid: true, + }, + { + name: "changed data", + newHistory: changedData, + oldHistory: valid, + isValid: false, + }, + { + name: "changed revision", + newHistory: changedRevision, + oldHistory: valid, + isValid: true, + }, + } + + for _, tc := range cases { + errs := Strategy.ValidateUpdate(ctx, tc.newHistory, tc.oldHistory) + if tc.isValid && len(errs) > 0 { + t.Errorf("%v: unexpected error: %v", tc.name, errs) + } + if !tc.isValid && len(errs) == 0 { + t.Errorf("%v: unexpected non-error", tc.name) + } + } +} + +func TestControllerRevisionToSelectableFields(t *testing.T) { + rev := newControllerRevision("validname", "validns", newObject(), 0) + fieldSet := ControllerRevisionToSelectableFields(rev) + if fieldSet.Get("metadata.name") != rev.Name { + t.Errorf("expeted %s found %s", rev.Name, fieldSet.Get("metadata.name")) + } + if fieldSet.Get("metadata.namespace") != rev.Namespace { + t.Errorf("expeted %s found %s", rev.Namespace, fieldSet.Get("metadata.namespace")) + } +} + +func TestGetAttrs(t *testing.T) { + rev := newControllerRevision("validname", "validns", newObject(), 0) + labelSet, fieldSet, err := GetAttrs(rev) + if err != nil { + t.Fatal(err) + } + if fieldSet.Get("metadata.name") != rev.Name { + t.Errorf("expeted %s found %s", rev.Name, fieldSet.Get("metadata.name")) + } + if fieldSet.Get("metadata.namespace") != rev.Namespace { + t.Errorf("expeted %s found %s", rev.Namespace, fieldSet.Get("metadata.namespace")) + } + if labelSet.Get("foo") != rev.Labels["foo"] { + t.Errorf("expected %s found %s", rev.Labels["foo"], labelSet.Get("foo")) + } +} + +func TestMatchControllerRevision(t *testing.T) { + rev := newControllerRevision("validname", "validns", newObject(), 0) + ls := labels.SelectorFromSet(labels.Set(rev.Labels)) + pred := MatchControllerRevision(ls, nil) + if matches, err := pred.Matches(rev); err != nil { + t.Error(err) + } else if !matches { + t.Error("failed to match ControllerRevision by labels") + } + fs := fields.SelectorFromSet(ControllerRevisionToSelectableFields(rev)) + pred = MatchControllerRevision(ls, fs) + if matches, err := pred.Matches(rev); err != nil { + t.Error(err) + } else if !matches { + t.Error("failed to match ControllerRevision by fields") + } +} + +func newControllerRevision(name, namespace string, data runtime.Object, revision int64) *apps.ControllerRevision { + return &apps.ControllerRevision{ + ObjectMeta: metav1.ObjectMeta{ + Name: name, + Namespace: namespace, + ResourceVersion: "1", + Labels: map[string]string{"foo": "bar"}, + }, + Data: data, + Revision: revision, + } +} + +func newObject() runtime.Object { + return &apps.StatefulSet{ + ObjectMeta: metav1.ObjectMeta{Name: "abc", Namespace: metav1.NamespaceDefault}, + Spec: apps.StatefulSetSpec{ + Selector: &metav1.LabelSelector{MatchLabels: map[string]string{"foo": "bar"}}, + Template: api.PodTemplateSpec{ + Spec: api.PodSpec{ + RestartPolicy: api.RestartPolicyAlways, + DNSPolicy: api.DNSClusterFirst, + }, + ObjectMeta: metav1.ObjectMeta{ + Labels: map[string]string{"foo": "bar"}, + }, + }, + }, + } +} diff --git a/pkg/registry/apps/rest/BUILD b/pkg/registry/apps/rest/BUILD index 6fb03c3fe568f..8a38770043523 100644 --- a/pkg/registry/apps/rest/BUILD +++ b/pkg/registry/apps/rest/BUILD @@ -15,6 +15,7 @@ go_library( "//pkg/api:go_default_library", "//pkg/apis/apps:go_default_library", "//pkg/apis/apps/v1beta1:go_default_library", + "//pkg/registry/apps/controllerrevision/storage:go_default_library", "//pkg/registry/apps/statefulset/storage:go_default_library", "//pkg/registry/extensions/deployment/storage:go_default_library", "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", diff --git a/pkg/registry/apps/rest/storage_apps.go b/pkg/registry/apps/rest/storage_apps.go index 0ae81cadb4f5e..56f98143b21d3 100644 --- a/pkg/registry/apps/rest/storage_apps.go +++ b/pkg/registry/apps/rest/storage_apps.go @@ -24,6 +24,7 @@ import ( "k8s.io/kubernetes/pkg/api" "k8s.io/kubernetes/pkg/apis/apps" appsapiv1beta1 "k8s.io/kubernetes/pkg/apis/apps/v1beta1" + controllerrevisionsstore "k8s.io/kubernetes/pkg/registry/apps/controllerrevision/storage" statefulsetstore "k8s.io/kubernetes/pkg/registry/apps/statefulset/storage" deploymentstore "k8s.io/kubernetes/pkg/registry/extensions/deployment/storage" ) @@ -57,6 +58,10 @@ func (p RESTStorageProvider) v1beta1Storage(apiResourceConfigSource serverstorag storage["statefulsets"] = statefulsetStorage storage["statefulsets/status"] = statefulsetStatusStorage } + if apiResourceConfigSource.ResourceEnabled(version.WithResource("controllerrevisions")) { + historyStorage := controllerrevisionsstore.NewREST(restOptionsGetter) + storage["controllerrevisions"] = historyStorage + } return storage } diff --git a/pkg/registry/cachesize/cachesize.go b/pkg/registry/cachesize/cachesize.go index 517e901099cb7..b853cb5e6a8a4 100644 --- a/pkg/registry/cachesize/cachesize.go +++ b/pkg/registry/cachesize/cachesize.go @@ -73,7 +73,7 @@ func InitializeWatchCacheSizes(expectedRAMCapacityMB int) { // This is the heuristics that from memory capacity is trying to infer // the maximum number of nodes in the cluster and set cache sizes based // on that value. - // From our documentation, we officially recomment 120GB machines for + // From our documentation, we officially recommend 120GB machines for // 2000 nodes, and we scale from that point. Thus we assume ~60MB of // capacity per node. // TODO: Revisit this heuristics diff --git a/pkg/registry/core/namespace/storage/BUILD b/pkg/registry/core/namespace/storage/BUILD index 0c0ada0dbce31..55fbc1d478f18 100644 --- a/pkg/registry/core/namespace/storage/BUILD +++ b/pkg/registry/core/namespace/storage/BUILD @@ -34,8 +34,10 @@ go_library( "//pkg/registry/cachesize:go_default_library", "//pkg/registry/core/namespace:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/internalversion:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", "//vendor/k8s.io/apiserver/pkg/endpoints/request:go_default_library", "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", "//vendor/k8s.io/apiserver/pkg/registry/generic/registry:go_default_library", diff --git a/pkg/registry/core/namespace/storage/storage.go b/pkg/registry/core/namespace/storage/storage.go index 51268fdee6bb5..1d41ec1accdb4 100644 --- a/pkg/registry/core/namespace/storage/storage.go +++ b/pkg/registry/core/namespace/storage/storage.go @@ -20,8 +20,10 @@ import ( "fmt" apierrors "k8s.io/apimachinery/pkg/api/errors" + metainternalversion "k8s.io/apimachinery/pkg/apis/meta/internalversion" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/watch" genericapirequest "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/apiserver/pkg/registry/generic" genericregistry "k8s.io/apiserver/pkg/registry/generic/registry" @@ -35,7 +37,7 @@ import ( // rest implements a RESTStorage for namespaces type REST struct { - *genericregistry.Store + store *genericregistry.Store status *genericregistry.Store } @@ -75,7 +77,39 @@ func NewREST(optsGetter generic.RESTOptionsGetter) (*REST, *StatusREST, *Finaliz finalizeStore := *store finalizeStore.UpdateStrategy = namespace.FinalizeStrategy - return &REST{Store: store, status: &statusStore}, &StatusREST{store: &statusStore}, &FinalizeREST{store: &finalizeStore} + return &REST{store: store, status: &statusStore}, &StatusREST{store: &statusStore}, &FinalizeREST{store: &finalizeStore} +} + +func (r *REST) New() runtime.Object { + return r.store.New() +} + +func (r *REST) NewList() runtime.Object { + return r.store.NewList() +} + +func (r *REST) List(ctx genericapirequest.Context, options *metainternalversion.ListOptions) (runtime.Object, error) { + return r.store.List(ctx, options) +} + +func (r *REST) Create(ctx genericapirequest.Context, obj runtime.Object) (runtime.Object, error) { + return r.store.Create(ctx, obj) +} + +func (r *REST) Update(ctx genericapirequest.Context, name string, objInfo rest.UpdatedObjectInfo) (runtime.Object, bool, error) { + return r.store.Update(ctx, name, objInfo) +} + +func (r *REST) Get(ctx genericapirequest.Context, name string, options *metav1.GetOptions) (runtime.Object, error) { + return r.store.Get(ctx, name, options) +} + +func (r *REST) Watch(ctx genericapirequest.Context, options *metainternalversion.ListOptions) (watch.Interface, error) { + return r.store.Watch(ctx, options) +} + +func (r *REST) Export(ctx genericapirequest.Context, name string, opts metav1.ExportOptions) (runtime.Object, error) { + return r.store.Export(ctx, name, opts) } // Delete enforces life-cycle rules for namespace termination @@ -108,15 +142,15 @@ func (r *REST) Delete(ctx genericapirequest.Context, name string, options *metav // upon first request to delete, we switch the phase to start namespace termination // TODO: enhance graceful deletion's calls to DeleteStrategy to allow phase change and finalizer patterns if namespace.DeletionTimestamp.IsZero() { - key, err := r.Store.KeyFunc(ctx, name) + key, err := r.store.KeyFunc(ctx, name) if err != nil { return nil, false, err } preconditions := storage.Preconditions{UID: options.Preconditions.UID} - out := r.Store.NewFunc() - err = r.Store.Storage.GuaranteedUpdate( + out := r.store.NewFunc() + err = r.store.Storage.GuaranteedUpdate( ctx, key, out, false, &preconditions, storage.SimpleUpdate(func(existing runtime.Object) (runtime.Object, error) { existingNamespace, ok := existing.(*api.Namespace) @@ -167,7 +201,7 @@ func (r *REST) Delete(ctx genericapirequest.Context, name string, options *metav err = apierrors.NewConflict(api.Resource("namespaces"), namespace.Name, fmt.Errorf("The system is ensuring all content is removed from this namespace. Upon completion, this namespace will automatically be purged by the system.")) return nil, false, err } - return r.Store.Delete(ctx, name, options) + return r.store.Delete(ctx, name, options) } // Implement ShortNamesProvider diff --git a/pkg/registry/core/namespace/storage/storage_test.go b/pkg/registry/core/namespace/storage/storage_test.go index f91fb03a27638..bae2ca9eaaaa4 100644 --- a/pkg/registry/core/namespace/storage/storage_test.go +++ b/pkg/registry/core/namespace/storage/storage_test.go @@ -47,8 +47,8 @@ func validNewNamespace() *api.Namespace { func TestCreate(t *testing.T) { storage, server := newStorage(t) defer server.Terminate(t) - defer storage.Store.DestroyFunc() - test := registrytest.New(t, storage.Store).ClusterScope() + defer storage.store.DestroyFunc() + test := registrytest.New(t, storage.store).ClusterScope() namespace := validNewNamespace() namespace.ObjectMeta = metav1.ObjectMeta{GenerateName: "foo"} test.TestCreate( @@ -64,7 +64,7 @@ func TestCreate(t *testing.T) { func TestCreateSetsFields(t *testing.T) { storage, server := newStorage(t) defer server.Terminate(t) - defer storage.Store.DestroyFunc() + defer storage.store.DestroyFunc() namespace := validNewNamespace() ctx := genericapirequest.NewContext() _, err := storage.Create(ctx, namespace) @@ -91,32 +91,32 @@ func TestCreateSetsFields(t *testing.T) { func TestDelete(t *testing.T) { storage, server := newStorage(t) defer server.Terminate(t) - defer storage.Store.DestroyFunc() - test := registrytest.New(t, storage.Store).ClusterScope().ReturnDeletedObject() + defer storage.store.DestroyFunc() + test := registrytest.New(t, storage.store).ClusterScope().ReturnDeletedObject() test.TestDelete(validNewNamespace()) } func TestGet(t *testing.T) { storage, server := newStorage(t) defer server.Terminate(t) - defer storage.Store.DestroyFunc() - test := registrytest.New(t, storage.Store).ClusterScope() + defer storage.store.DestroyFunc() + test := registrytest.New(t, storage.store).ClusterScope() test.TestGet(validNewNamespace()) } func TestList(t *testing.T) { storage, server := newStorage(t) defer server.Terminate(t) - defer storage.Store.DestroyFunc() - test := registrytest.New(t, storage.Store).ClusterScope() + defer storage.store.DestroyFunc() + test := registrytest.New(t, storage.store).ClusterScope() test.TestList(validNewNamespace()) } func TestWatch(t *testing.T) { storage, server := newStorage(t) defer server.Terminate(t) - defer storage.Store.DestroyFunc() - test := registrytest.New(t, storage.Store).ClusterScope() + defer storage.store.DestroyFunc() + test := registrytest.New(t, storage.store).ClusterScope() test.TestWatch( validNewNamespace(), // matching labels @@ -140,7 +140,7 @@ func TestWatch(t *testing.T) { func TestDeleteNamespaceWithIncompleteFinalizers(t *testing.T) { storage, server := newStorage(t) defer server.Terminate(t) - defer storage.Store.DestroyFunc() + defer storage.store.DestroyFunc() key := "namespaces/foo" ctx := genericapirequest.NewContext() now := metav1.Now() @@ -154,7 +154,7 @@ func TestDeleteNamespaceWithIncompleteFinalizers(t *testing.T) { }, Status: api.NamespaceStatus{Phase: api.NamespaceActive}, } - if err := storage.Storage.Create(ctx, key, namespace, nil, 0); err != nil { + if err := storage.store.Storage.Create(ctx, key, namespace, nil, 0); err != nil { t.Fatalf("unexpected error: %v", err) } if _, _, err := storage.Delete(ctx, "foo", nil); err == nil { @@ -165,7 +165,7 @@ func TestDeleteNamespaceWithIncompleteFinalizers(t *testing.T) { func TestDeleteNamespaceWithCompleteFinalizers(t *testing.T) { storage, server := newStorage(t) defer server.Terminate(t) - defer storage.Store.DestroyFunc() + defer storage.store.DestroyFunc() key := "namespaces/foo" ctx := genericapirequest.NewContext() now := metav1.Now() @@ -179,7 +179,7 @@ func TestDeleteNamespaceWithCompleteFinalizers(t *testing.T) { }, Status: api.NamespaceStatus{Phase: api.NamespaceActive}, } - if err := storage.Storage.Create(ctx, key, namespace, nil, 0); err != nil { + if err := storage.store.Storage.Create(ctx, key, namespace, nil, 0); err != nil { t.Fatalf("unexpected error: %v", err) } if _, _, err := storage.Delete(ctx, "foo", nil); err != nil { @@ -190,7 +190,7 @@ func TestDeleteNamespaceWithCompleteFinalizers(t *testing.T) { func TestShortNames(t *testing.T) { storage, server := newStorage(t) defer server.Terminate(t) - defer storage.Store.DestroyFunc() + defer storage.store.DestroyFunc() expected := []string{"ns"} registrytest.AssertShortNames(t, storage, expected) } diff --git a/pkg/registry/extensions/thirdpartyresourcedata/storage/BUILD b/pkg/registry/extensions/thirdpartyresourcedata/storage/BUILD index 2b1cf85438812..c1300d6b0a666 100644 --- a/pkg/registry/extensions/thirdpartyresourcedata/storage/BUILD +++ b/pkg/registry/extensions/thirdpartyresourcedata/storage/BUILD @@ -35,9 +35,14 @@ go_library( "//pkg/apis/extensions:go_default_library", "//pkg/registry/cachesize:go_default_library", "//pkg/registry/extensions/thirdpartyresourcedata:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/internalversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apiserver/pkg/endpoints/request:go_default_library", "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", "//vendor/k8s.io/apiserver/pkg/registry/generic/registry:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/rest:go_default_library", ], ) diff --git a/pkg/registry/extensions/thirdpartyresourcedata/storage/storage.go b/pkg/registry/extensions/thirdpartyresourcedata/storage/storage.go index b19fbb5a47ae7..4680e735de94e 100644 --- a/pkg/registry/extensions/thirdpartyresourcedata/storage/storage.go +++ b/pkg/registry/extensions/thirdpartyresourcedata/storage/storage.go @@ -18,20 +18,72 @@ package storage import ( "strings" + "sync/atomic" + "k8s.io/apimachinery/pkg/api/errors" + metainternalversion "k8s.io/apimachinery/pkg/apis/meta/internalversion" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" + genericapirequest "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/apiserver/pkg/registry/generic" genericregistry "k8s.io/apiserver/pkg/registry/generic/registry" + "k8s.io/apiserver/pkg/registry/rest" "k8s.io/kubernetes/pkg/api" "k8s.io/kubernetes/pkg/apis/extensions" "k8s.io/kubernetes/pkg/registry/cachesize" "k8s.io/kubernetes/pkg/registry/extensions/thirdpartyresourcedata" ) -// REST implements a RESTStorage for ThirdPartyResourceData +// errFrozen is a transient error to indicate that clients should retry with backoff. +var errFrozen = errors.NewServiceUnavailable("TPR data is temporarily frozen") + +// REST implements a RESTStorage for ThirdPartyResourceData. type REST struct { *genericregistry.Store - kind string + kind string + frozen atomic.Value +} + +// Freeze causes all future calls to Create/Update/Delete/DeleteCollection to return a transient error. +// This is irreversible and meant for use when the TPR data is being deleted or migrated/abandoned. +func (r *REST) Freeze() { + r.frozen.Store(true) +} + +func (r *REST) isFrozen() bool { + return r.frozen.Load() != nil +} + +// Create is a wrapper to support Freeze. +func (r *REST) Create(ctx genericapirequest.Context, obj runtime.Object) (runtime.Object, error) { + if r.isFrozen() { + return nil, errFrozen + } + return r.Store.Create(ctx, obj) +} + +// Update is a wrapper to support Freeze. +func (r *REST) Update(ctx genericapirequest.Context, name string, objInfo rest.UpdatedObjectInfo) (runtime.Object, bool, error) { + if r.isFrozen() { + return nil, false, errFrozen + } + return r.Store.Update(ctx, name, objInfo) +} + +// Delete is a wrapper to support Freeze. +func (r *REST) Delete(ctx genericapirequest.Context, name string, options *metav1.DeleteOptions) (runtime.Object, bool, error) { + if r.isFrozen() { + return nil, false, errFrozen + } + return r.Store.Delete(ctx, name, options) +} + +// DeleteCollection is a wrapper to support Freeze. +func (r *REST) DeleteCollection(ctx genericapirequest.Context, options *metav1.DeleteOptions, listOptions *metainternalversion.ListOptions) (runtime.Object, error) { + if r.isFrozen() { + return nil, errFrozen + } + return r.Store.DeleteCollection(ctx, options, listOptions) } // NewREST returns a registry which will store ThirdPartyResourceData in the given helper diff --git a/pkg/registry/networking/networkpolicy/BUILD b/pkg/registry/networking/networkpolicy/BUILD new file mode 100644 index 0000000000000..6a09bac280dae --- /dev/null +++ b/pkg/registry/networking/networkpolicy/BUILD @@ -0,0 +1,51 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "registry.go", + "strategy.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/networking:go_default_library", + "//pkg/apis/networking/validation:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/internalversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation/field:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/apiserver/pkg/endpoints/request:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/rest:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage/names:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//pkg/registry/networking/networkpolicy/storage:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/pkg/registry/networking/networkpolicy/doc.go b/pkg/registry/networking/networkpolicy/doc.go new file mode 100644 index 0000000000000..7b338bc5e8971 --- /dev/null +++ b/pkg/registry/networking/networkpolicy/doc.go @@ -0,0 +1,17 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package networkpolicy // import "k8s.io/kubernetes/pkg/registry/networking/networkpolicy" diff --git a/pkg/registry/networking/networkpolicy/registry.go b/pkg/registry/networking/networkpolicy/registry.go new file mode 100644 index 0000000000000..36f1d3d5dbefe --- /dev/null +++ b/pkg/registry/networking/networkpolicy/registry.go @@ -0,0 +1,84 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package networkpolicy + +import ( + metainternalversion "k8s.io/apimachinery/pkg/apis/meta/internalversion" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/watch" + genericapirequest "k8s.io/apiserver/pkg/endpoints/request" + "k8s.io/apiserver/pkg/registry/rest" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/networking" +) + +// Registry is an interface for things that know how to store NetworkPolicies. +type Registry interface { + ListNetworkPolicies(ctx genericapirequest.Context, options *metainternalversion.ListOptions) (*networking.NetworkPolicyList, error) + CreateNetworkPolicy(ctx genericapirequest.Context, np *networking.NetworkPolicy) error + UpdateNetworkPolicy(ctx genericapirequest.Context, np *networking.NetworkPolicy) error + GetNetworkPolicy(ctx genericapirequest.Context, name string, options *metav1.GetOptions) (*networking.NetworkPolicy, error) + DeleteNetworkPolicy(ctx genericapirequest.Context, name string) error + WatchNetworkPolicies(ctx genericapirequest.Context, options *metainternalversion.ListOptions) (watch.Interface, error) +} + +// storage puts strong typing around storage calls +type storage struct { + rest.StandardStorage +} + +// NewRegistry returns a new Registry interface for the given Storage. Any mismatched +// types will panic. +func NewRegistry(s rest.StandardStorage) Registry { + return &storage{s} +} + +func (s *storage) ListNetworkPolicies(ctx genericapirequest.Context, options *metainternalversion.ListOptions) (*networking.NetworkPolicyList, error) { + obj, err := s.List(ctx, options) + if err != nil { + return nil, err + } + + return obj.(*networking.NetworkPolicyList), nil +} + +func (s *storage) CreateNetworkPolicy(ctx genericapirequest.Context, np *networking.NetworkPolicy) error { + _, err := s.Create(ctx, np) + return err +} + +func (s *storage) UpdateNetworkPolicy(ctx genericapirequest.Context, np *networking.NetworkPolicy) error { + _, _, err := s.Update(ctx, np.Name, rest.DefaultUpdatedObjectInfo(np, api.Scheme)) + return err +} + +func (s *storage) WatchNetworkPolicies(ctx genericapirequest.Context, options *metainternalversion.ListOptions) (watch.Interface, error) { + return s.Watch(ctx, options) +} + +func (s *storage) GetNetworkPolicy(ctx genericapirequest.Context, name string, options *metav1.GetOptions) (*networking.NetworkPolicy, error) { + obj, err := s.Get(ctx, name, options) + if err != nil { + return nil, err + } + return obj.(*networking.NetworkPolicy), nil +} + +func (s *storage) DeleteNetworkPolicy(ctx genericapirequest.Context, name string) error { + _, _, err := s.Delete(ctx, name, nil) + return err +} diff --git a/pkg/registry/networking/networkpolicy/storage/BUILD b/pkg/registry/networking/networkpolicy/storage/BUILD new file mode 100644 index 0000000000000..14dcaa60879a1 --- /dev/null +++ b/pkg/registry/networking/networkpolicy/storage/BUILD @@ -0,0 +1,36 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["storage.go"], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/networking:go_default_library", + "//pkg/registry/cachesize:go_default_library", + "//pkg/registry/networking/networkpolicy:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic/registry:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/registry/networking/networkpolicy/storage/storage.go b/pkg/registry/networking/networkpolicy/storage/storage.go new file mode 100644 index 0000000000000..e3693660348bc --- /dev/null +++ b/pkg/registry/networking/networkpolicy/storage/storage.go @@ -0,0 +1,54 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package storage + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apiserver/pkg/registry/generic" + genericregistry "k8s.io/apiserver/pkg/registry/generic/registry" + "k8s.io/kubernetes/pkg/api" + networkingapi "k8s.io/kubernetes/pkg/apis/networking" + "k8s.io/kubernetes/pkg/registry/cachesize" + "k8s.io/kubernetes/pkg/registry/networking/networkpolicy" +) + +// rest implements a RESTStorage for NetworkPolicies against etcd +type REST struct { + *genericregistry.Store +} + +// NewREST returns a RESTStorage object that will work against NetworkPolicies +func NewREST(optsGetter generic.RESTOptionsGetter) *REST { + store := &genericregistry.Store{ + Copier: api.Scheme, + NewFunc: func() runtime.Object { return &networkingapi.NetworkPolicy{} }, + NewListFunc: func() runtime.Object { return &networkingapi.NetworkPolicyList{} }, + PredicateFunc: networkpolicy.Matcher, + QualifiedResource: networkingapi.Resource("networkpolicies"), + WatchCacheSize: cachesize.GetWatchCacheSizeByResource("networkpolicies"), + + CreateStrategy: networkpolicy.Strategy, + UpdateStrategy: networkpolicy.Strategy, + DeleteStrategy: networkpolicy.Strategy, + } + options := &generic.StoreOptions{RESTOptions: optsGetter, AttrFunc: networkpolicy.GetAttrs} + if err := store.CompleteWithOptions(options); err != nil { + panic(err) // TODO: Propagate error up + } + + return &REST{store} +} diff --git a/pkg/registry/networking/networkpolicy/strategy.go b/pkg/registry/networking/networkpolicy/strategy.go new file mode 100644 index 0000000000000..b6b027fb5edd6 --- /dev/null +++ b/pkg/registry/networking/networkpolicy/strategy.go @@ -0,0 +1,117 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package networkpolicy + +import ( + "fmt" + "reflect" + + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/validation/field" + genericapirequest "k8s.io/apiserver/pkg/endpoints/request" + "k8s.io/apiserver/pkg/registry/generic" + apistorage "k8s.io/apiserver/pkg/storage" + "k8s.io/apiserver/pkg/storage/names" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/networking" + "k8s.io/kubernetes/pkg/apis/networking/validation" +) + +// networkPolicyStrategy implements verification logic for NetworkPolicies +type networkPolicyStrategy struct { + runtime.ObjectTyper + names.NameGenerator +} + +// Strategy is the default logic that applies when creating and updating NetworkPolicy objects. +var Strategy = networkPolicyStrategy{api.Scheme, names.SimpleNameGenerator} + +// NamespaceScoped returns true because all NetworkPolicies need to be within a namespace. +func (networkPolicyStrategy) NamespaceScoped() bool { + return true +} + +// PrepareForCreate clears the status of a NetworkPolicy before creation. +func (networkPolicyStrategy) PrepareForCreate(ctx genericapirequest.Context, obj runtime.Object) { + networkPolicy := obj.(*networking.NetworkPolicy) + networkPolicy.Generation = 1 +} + +// PrepareForUpdate clears fields that are not allowed to be set by end users on update. +func (networkPolicyStrategy) PrepareForUpdate(ctx genericapirequest.Context, obj, old runtime.Object) { + newNetworkPolicy := obj.(*networking.NetworkPolicy) + oldNetworkPolicy := old.(*networking.NetworkPolicy) + + // Any changes to the spec increment the generation number, any changes to the + // status should reflect the generation number of the corresponding object. + // See metav1.ObjectMeta description for more information on Generation. + if !reflect.DeepEqual(oldNetworkPolicy.Spec, newNetworkPolicy.Spec) { + newNetworkPolicy.Generation = oldNetworkPolicy.Generation + 1 + } +} + +// Validate validates a new NetworkPolicy. +func (networkPolicyStrategy) Validate(ctx genericapirequest.Context, obj runtime.Object) field.ErrorList { + networkPolicy := obj.(*networking.NetworkPolicy) + return validation.ValidateNetworkPolicy(networkPolicy) +} + +// Canonicalize normalizes the object after validation. +func (networkPolicyStrategy) Canonicalize(obj runtime.Object) {} + +// AllowCreateOnUpdate is false for NetworkPolicy; this means POST is needed to create one. +func (networkPolicyStrategy) AllowCreateOnUpdate() bool { + return false +} + +// ValidateUpdate is the default update validation for an end user. +func (networkPolicyStrategy) ValidateUpdate(ctx genericapirequest.Context, obj, old runtime.Object) field.ErrorList { + validationErrorList := validation.ValidateNetworkPolicy(obj.(*networking.NetworkPolicy)) + updateErrorList := validation.ValidateNetworkPolicyUpdate(obj.(*networking.NetworkPolicy), old.(*networking.NetworkPolicy)) + return append(validationErrorList, updateErrorList...) +} + +// AllowUnconditionalUpdate is the default update policy for NetworkPolicy objects. +func (networkPolicyStrategy) AllowUnconditionalUpdate() bool { + return true +} + +// SelectableFields returns a field set that represents the object. +func SelectableFields(networkPolicy *networking.NetworkPolicy) fields.Set { + return generic.ObjectMetaFieldsSet(&networkPolicy.ObjectMeta, true) +} + +// GetAttrs returns labels and fields of a given object for filtering purposes. +func GetAttrs(obj runtime.Object) (labels.Set, fields.Set, error) { + networkPolicy, ok := obj.(*networking.NetworkPolicy) + if !ok { + return nil, nil, fmt.Errorf("given object is not a NetworkPolicy.") + } + return labels.Set(networkPolicy.ObjectMeta.Labels), SelectableFields(networkPolicy), nil +} + +// Matcher is the filter used by the generic etcd backend to watch events +// from etcd to clients of the apiserver only interested in specific labels/fields. +func Matcher(label labels.Selector, field fields.Selector) apistorage.SelectionPredicate { + return apistorage.SelectionPredicate{ + Label: label, + Field: field, + GetAttrs: GetAttrs, + } +} diff --git a/pkg/registry/networking/rest/BUILD b/pkg/registry/networking/rest/BUILD new file mode 100644 index 0000000000000..266cb442c660c --- /dev/null +++ b/pkg/registry/networking/rest/BUILD @@ -0,0 +1,37 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["storage_settings.go"], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/apis/networking:go_default_library", + "//pkg/apis/networking/v1:go_default_library", + "//pkg/registry/networking/networkpolicy/storage:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", + "//vendor/k8s.io/apiserver/pkg/registry/rest:go_default_library", + "//vendor/k8s.io/apiserver/pkg/server:go_default_library", + "//vendor/k8s.io/apiserver/pkg/server/storage:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/registry/networking/rest/storage_settings.go b/pkg/registry/networking/rest/storage_settings.go new file mode 100644 index 0000000000000..c662025dd2211 --- /dev/null +++ b/pkg/registry/networking/rest/storage_settings.go @@ -0,0 +1,56 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +package rest + +import ( + "k8s.io/apiserver/pkg/registry/generic" + "k8s.io/apiserver/pkg/registry/rest" + genericapiserver "k8s.io/apiserver/pkg/server" + serverstorage "k8s.io/apiserver/pkg/server/storage" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/apis/networking" + networkingapiv1 "k8s.io/kubernetes/pkg/apis/networking/v1" + networkpolicystore "k8s.io/kubernetes/pkg/registry/networking/networkpolicy/storage" +) + +type RESTStorageProvider struct{} + +func (p RESTStorageProvider) NewRESTStorage(apiResourceConfigSource serverstorage.APIResourceConfigSource, restOptionsGetter generic.RESTOptionsGetter) (genericapiserver.APIGroupInfo, bool) { + apiGroupInfo := genericapiserver.NewDefaultAPIGroupInfo(networking.GroupName, api.Registry, api.Scheme, api.ParameterCodec, api.Codecs) + + if apiResourceConfigSource.AnyResourcesForVersionEnabled(networkingapiv1.SchemeGroupVersion) { + apiGroupInfo.VersionedResourcesStorageMap[networkingapiv1.SchemeGroupVersion.Version] = p.v1alpha1Storage(apiResourceConfigSource, restOptionsGetter) + apiGroupInfo.GroupMeta.GroupVersion = networkingapiv1.SchemeGroupVersion + } + + return apiGroupInfo, true +} + +func (p RESTStorageProvider) v1alpha1Storage(apiResourceConfigSource serverstorage.APIResourceConfigSource, restOptionsGetter generic.RESTOptionsGetter) map[string]rest.Storage { + version := networkingapiv1.SchemeGroupVersion + + storage := map[string]rest.Storage{} + if apiResourceConfigSource.ResourceEnabled(version.WithResource("networkpolicies")) { + networkPolicyStorage := networkpolicystore.NewREST(restOptionsGetter) + storage["networkpolicies"] = networkPolicyStorage + } + return storage +} + +func (p RESTStorageProvider) GroupName() string { + return networking.GroupName +} diff --git a/pkg/security/podsecuritypolicy/provider.go b/pkg/security/podsecuritypolicy/provider.go index 0f72f79c11454..e92c6419fc977 100644 --- a/pkg/security/podsecuritypolicy/provider.go +++ b/pkg/security/podsecuritypolicy/provider.go @@ -241,6 +241,15 @@ func (s *simpleProvider) ValidatePodSecurityContext(pod *api.Pod, fldPath *field allErrs = append(allErrs, field.Invalid( field.NewPath("spec", "volumes").Index(i), string(fsType), fmt.Sprintf("%s volumes are not allowed to be used", string(fsType)))) + continue + } + + if fsType == extensions.HostPath { + if !psputil.PSPAllowsHostVolumePath(s.psp, v.HostPath.Path) { + allErrs = append(allErrs, field.Invalid( + field.NewPath("spec", "volumes").Index(i), string(fsType), + fmt.Sprintf("host path %s is not allowed to be used. allowed host paths: %v", v.HostPath.Path, s.psp.Spec.AllowedHostPaths))) + } } } } diff --git a/pkg/security/podsecuritypolicy/provider_test.go b/pkg/security/podsecuritypolicy/provider_test.go index c50ccd99b657e..8cdfd65f07d07 100644 --- a/pkg/security/podsecuritypolicy/provider_test.go +++ b/pkg/security/podsecuritypolicy/provider_test.go @@ -238,6 +238,21 @@ func TestValidatePodSecurityContextFailures(t *testing.T) { }, } + failHostPathDirPod := defaultPod() + failHostPathDirPod.Spec.Volumes = []api.Volume{ + { + Name: "bad volume", + VolumeSource: api.VolumeSource{ + HostPath: &api.HostPathVolumeSource{ + Path: "/fail", + }, + }, + }, + } + failHostPathDirPSP := defaultPSP() + failHostPathDirPSP.Spec.Volumes = []extensions.FSType{extensions.HostPath} + failHostPathDirPSP.Spec.AllowedHostPaths = []string{"/foo/bar"} + failOtherSysctlsAllowedPSP := defaultPSP() failOtherSysctlsAllowedPSP.Annotations[extensions.SysctlsPodSecurityPolicyAnnotationKey] = "bar,abc" @@ -308,6 +323,11 @@ func TestValidatePodSecurityContextFailures(t *testing.T) { psp: defaultPSP(), expectedError: "hostPath volumes are not allowed to be used", }, + "failHostPathDirPSP": { + pod: failHostPathDirPod, + psp: failHostPathDirPSP, + expectedError: "host path /fail is not allowed to be used. allowed host paths: [/foo/bar]", + }, "failSafeSysctlFooPod with failNoSysctlAllowedSCC": { pod: failSafeSysctlFooPod, psp: failNoSysctlAllowedPSP, @@ -706,13 +726,28 @@ func TestValidateContainerSecurityContextSuccess(t *testing.T) { hostDirPod := defaultPod() hostDirPod.Spec.Volumes = []api.Volume{ { - Name: "bad volume", + Name: "good volume", VolumeSource: api.VolumeSource{ HostPath: &api.HostPathVolumeSource{}, }, }, } + hostPathDirPod := defaultPod() + hostPathDirPod.Spec.Volumes = []api.Volume{ + { + Name: "good volume", + VolumeSource: api.VolumeSource{ + HostPath: &api.HostPathVolumeSource{ + Path: "/foo/bar/baz", + }, + }, + }, + } + hostPathDirPSP := defaultPSP() + hostPathDirPSP.Spec.Volumes = []extensions.FSType{extensions.HostPath} + hostPathDirPSP.Spec.AllowedHostPaths = []string{"/foo/bar"} + hostPortPSP := defaultPSP() hostPortPSP.Spec.HostPorts = []extensions.HostPortRange{{Min: 1, Max: 1}} hostPortPod := defaultPod() @@ -773,6 +808,10 @@ func TestValidateContainerSecurityContextSuccess(t *testing.T) { pod: hostDirPod, psp: hostDirPSP, }, + "pass hostDir allowed directory validating PSP": { + pod: hostPathDirPod, + psp: hostPathDirPSP, + }, "pass hostPort validating PSP": { pod: hostPortPod, psp: hostPortPSP, diff --git a/pkg/security/podsecuritypolicy/util/util.go b/pkg/security/podsecuritypolicy/util/util.go index b424846cf81d3..14e397349d7e8 100644 --- a/pkg/security/podsecuritypolicy/util/util.go +++ b/pkg/security/podsecuritypolicy/util/util.go @@ -18,6 +18,7 @@ package util import ( "fmt" + "strings" "k8s.io/apimachinery/pkg/types" "k8s.io/apimachinery/pkg/util/sets" @@ -168,3 +169,52 @@ func UserFallsInRange(id types.UnixUserID, rng extensions.UserIDRange) bool { func GroupFallsInRange(id types.UnixGroupID, rng extensions.GroupIDRange) bool { return id >= rng.Min && id <= rng.Max } + +// PSPAllowsHostVolumePath is a utility for checking if a PSP allows the host volume path. +// This only checks the path. You should still check to make sure the host volume fs type is allowed. +func PSPAllowsHostVolumePath(psp *extensions.PodSecurityPolicy, hostPath string) bool { + if psp == nil { + return false + } + + // If no allowed paths are specified then allow any path + if len(psp.Spec.AllowedHostPaths) == 0 { + return true + } + + for _, allowedPath := range psp.Spec.AllowedHostPaths { + if hasPathPrefix(hostPath, allowedPath) { + return true + } + } + + return false +} + +// hasPathPrefix returns true if the string matches pathPrefix exactly, or if is prefixed with pathPrefix at a path segment boundary +// the string and pathPrefix are both normalized to remove trailing slashes prior to checking. +func hasPathPrefix(s, pathPrefix string) bool { + + s = strings.TrimSuffix(s, "/") + pathPrefix = strings.TrimSuffix(pathPrefix, "/") + + // Short circuit if s doesn't contain the prefix at all + if !strings.HasPrefix(s, pathPrefix) { + return false + } + + pathPrefixLength := len(pathPrefix) + + if len(s) == pathPrefixLength { + // Exact match + return true + } + + if s[pathPrefixLength:pathPrefixLength+1] == "/" { + // The next character in s is a path segment boundary + // Check this instead of normalizing pathPrefix to avoid allocating on every call + return true + } + + return false +} diff --git a/pkg/security/podsecuritypolicy/util/util_test.go b/pkg/security/podsecuritypolicy/util/util_test.go index 63a2dd3de04d7..f230858ef3547 100644 --- a/pkg/security/podsecuritypolicy/util/util_test.go +++ b/pkg/security/podsecuritypolicy/util/util_test.go @@ -103,3 +103,83 @@ func TestPSPAllowsFSType(t *testing.T) { } } } + +func TestPSPAllowsHostVolumePath(t *testing.T) { + tests := map[string]struct { + psp *extensions.PodSecurityPolicy + path string + allows bool + }{ + "nil psp": { + psp: nil, + path: "/test", + allows: false, + }, + "empty allowed paths": { + psp: &extensions.PodSecurityPolicy{}, + path: "/test", + allows: true, + }, + "non-matching": { + psp: &extensions.PodSecurityPolicy{ + Spec: extensions.PodSecurityPolicySpec{ + AllowedHostPaths: []string{"/foo"}, + }, + }, + path: "/foobar", + allows: false, + }, + "match on direct match": { + psp: &extensions.PodSecurityPolicy{ + Spec: extensions.PodSecurityPolicySpec{ + AllowedHostPaths: []string{"/foo"}, + }, + }, + path: "/foo", + allows: true, + }, + "match with trailing slash on host path": { + psp: &extensions.PodSecurityPolicy{ + Spec: extensions.PodSecurityPolicySpec{ + AllowedHostPaths: []string{"/foo"}, + }, + }, + path: "/foo/", + allows: true, + }, + "match with trailing slash on allowed path": { + psp: &extensions.PodSecurityPolicy{ + Spec: extensions.PodSecurityPolicySpec{ + AllowedHostPaths: []string{"/foo/"}, + }, + }, + path: "/foo", + allows: true, + }, + "match child directory": { + psp: &extensions.PodSecurityPolicy{ + Spec: extensions.PodSecurityPolicySpec{ + AllowedHostPaths: []string{"/foo/"}, + }, + }, + path: "/foo/bar", + allows: true, + }, + "non-matching parent directory": { + psp: &extensions.PodSecurityPolicy{ + Spec: extensions.PodSecurityPolicySpec{ + AllowedHostPaths: []string{"/foo/bar"}, + }, + }, + path: "/foo", + allows: false, + }, + } + + for k, v := range tests { + allows := PSPAllowsHostVolumePath(v.psp, v.path) + if v.allows != allows { + t.Errorf("%s expected PSPAllowsHostVolumePath to return %t but got %t", k, v.allows, allows) + } + } +} diff --git a/pkg/util/async/bounded_frequency_runner.go b/pkg/util/async/bounded_frequency_runner.go index 531ac2cfee627..da6fc2a4f8fa3 100644 --- a/pkg/util/async/bounded_frequency_runner.go +++ b/pkg/util/async/bounded_frequency_runner.go @@ -151,7 +151,7 @@ func construct(name string, fn func(), minInterval, maxInterval time.Duration, b fn: fn, minInterval: minInterval, maxInterval: maxInterval, - run: make(chan struct{}, 16), + run: make(chan struct{}, 1), timer: timer, } if minInterval == 0 { @@ -185,8 +185,18 @@ func (bfr *BoundedFrequencyRunner) Loop(stop <-chan struct{}) { // Run the function as soon as possible. If this is called while Loop is not // running, the call may be deferred indefinitely. +// If there is already a queued request to call the underlying function, it +// may be dropped - it is just guaranteed that we will try calling the +// underlying function as soon as possible starting from now. func (bfr *BoundedFrequencyRunner) Run() { - bfr.run <- struct{}{} + // If it takes a lot of time to run the underlying function, noone is really + // processing elements from channel. So to avoid blocking here on the + // putting element to it, we simply skip it if there is already an element + // in it. + select { + case bfr.run <- struct{}{}: + default: + } } // assumes the lock is not held diff --git a/pkg/util/iptables/save_restore.go b/pkg/util/iptables/save_restore.go index 435a54bebd4d5..6f4eacacab0a1 100644 --- a/pkg/util/iptables/save_restore.go +++ b/pkg/util/iptables/save_restore.go @@ -52,7 +52,9 @@ func GetChainLines(table Table, save []byte) map[Chain]string { } else if strings.HasPrefix(line, "#") { continue } else if strings.HasPrefix(line, ":") && len(line) > 1 { - chain := Chain(strings.SplitN(line[1:], " ", 2)[0]) + // We assume that the contains space - chain lines have 3 fields, + // space delimited. If there is no space, this line will panic. + chain := Chain(line[1:strings.Index(line, " ")]) chainsMap[chain] = line } } diff --git a/pkg/util/taints/taints.go b/pkg/util/taints/taints.go index 0f8513f9ff14e..b001433753f82 100644 --- a/pkg/util/taints/taints.go +++ b/pkg/util/taints/taints.go @@ -26,7 +26,7 @@ import ( "k8s.io/kubernetes/pkg/api/v1" ) -// ParseTaint parses a taint from a string. Taint must be off the format '=:'. +// ParseTaint parses a taint from a string. Taint must be of the format '=:'. func ParseTaint(st string) (v1.Taint, error) { var taint v1.Taint parts := strings.Split(st, "=") diff --git a/pkg/volume/BUILD b/pkg/volume/BUILD index 923204d37d41b..5ecc5b254a898 100644 --- a/pkg/volume/BUILD +++ b/pkg/volume/BUILD @@ -106,6 +106,7 @@ filegroup( "//pkg/volume/glusterfs:all-srcs", "//pkg/volume/host_path:all-srcs", "//pkg/volume/iscsi:all-srcs", + "//pkg/volume/local:all-srcs", "//pkg/volume/nfs:all-srcs", "//pkg/volume/photon_pd:all-srcs", "//pkg/volume/portworx:all-srcs", diff --git a/pkg/volume/aws_ebs/BUILD b/pkg/volume/aws_ebs/BUILD index b888ced7f9439..4d3772059206e 100644 --- a/pkg/volume/aws_ebs/BUILD +++ b/pkg/volume/aws_ebs/BUILD @@ -26,6 +26,7 @@ go_library( "//pkg/util/strings:go_default_library", "//pkg/volume:go_default_library", "//pkg/volume/util:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", diff --git a/pkg/volume/aws_ebs/aws_ebs.go b/pkg/volume/aws_ebs/aws_ebs.go index 77dce23966f64..6a046d7654b44 100644 --- a/pkg/volume/aws_ebs/aws_ebs.go +++ b/pkg/volume/aws_ebs/aws_ebs.go @@ -35,6 +35,7 @@ import ( kstrings "k8s.io/kubernetes/pkg/util/strings" "k8s.io/kubernetes/pkg/volume" "k8s.io/kubernetes/pkg/volume/util" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) // This is the primary entrypoint for volume plugins. @@ -440,7 +441,7 @@ func (c *awsElasticBlockStoreProvisioner) Provision() (*v1.PersistentVolume, err Name: c.options.PVName, Labels: map[string]string{}, Annotations: map[string]string{ - "kubernetes.io/createdby": "aws-ebs-dynamic-provisioner", + volumehelper.VolumeDynamicallyCreatedByKey: "aws-ebs-dynamic-provisioner", }, }, Spec: v1.PersistentVolumeSpec{ diff --git a/pkg/volume/azure_dd/BUILD b/pkg/volume/azure_dd/BUILD index e940d4fbf54c9..acc86be97671e 100644 --- a/pkg/volume/azure_dd/BUILD +++ b/pkg/volume/azure_dd/BUILD @@ -27,6 +27,7 @@ go_library( "//pkg/util/strings:go_default_library", "//pkg/volume:go_default_library", "//pkg/volume/util:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/github.com/Azure/azure-sdk-for-go/arm/compute:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", diff --git a/pkg/volume/azure_dd/azure_provision.go b/pkg/volume/azure_dd/azure_provision.go index 2cb7613d6e4d9..71679b5fcf88c 100644 --- a/pkg/volume/azure_dd/azure_provision.go +++ b/pkg/volume/azure_dd/azure_provision.go @@ -26,6 +26,7 @@ import ( "k8s.io/kubernetes/pkg/api/v1" utilstrings "k8s.io/kubernetes/pkg/util/strings" "k8s.io/kubernetes/pkg/volume" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) var _ volume.DeletableVolumePlugin = &azureDataDiskPlugin{} @@ -143,7 +144,7 @@ func (a *azureDiskProvisioner) Provision() (*v1.PersistentVolume, error) { Name: a.options.PVName, Labels: map[string]string{}, Annotations: map[string]string{ - "kubernetes.io/createdby": "azure-disk-dynamic-provisioner", + volumehelper.VolumeDynamicallyCreatedByKey: "azure-disk-dynamic-provisioner", }, }, Spec: v1.PersistentVolumeSpec{ diff --git a/pkg/volume/azure_file/BUILD b/pkg/volume/azure_file/BUILD index a8dae8d50fdfb..577d65b69f2db 100644 --- a/pkg/volume/azure_file/BUILD +++ b/pkg/volume/azure_file/BUILD @@ -25,6 +25,7 @@ go_library( "//pkg/util/strings:go_default_library", "//pkg/volume:go_default_library", "//pkg/volume/util:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", diff --git a/pkg/volume/azure_file/azure_provision.go b/pkg/volume/azure_file/azure_provision.go index 46a483e6b975a..1020b60cc8429 100644 --- a/pkg/volume/azure_file/azure_provision.go +++ b/pkg/volume/azure_file/azure_provision.go @@ -28,6 +28,7 @@ import ( "k8s.io/kubernetes/pkg/cloudprovider/providers/azure" utilstrings "k8s.io/kubernetes/pkg/util/strings" "k8s.io/kubernetes/pkg/volume" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) var _ volume.DeletableVolumePlugin = &azureFilePlugin{} @@ -172,7 +173,7 @@ func (a *azureFileProvisioner) Provision() (*v1.PersistentVolume, error) { Name: a.options.PVName, Labels: map[string]string{}, Annotations: map[string]string{ - "kubernetes.io/createdby": "azure-file-dynamic-provisioner", + volumehelper.VolumeDynamicallyCreatedByKey: "azure-file-dynamic-provisioner", }, }, Spec: v1.PersistentVolumeSpec{ diff --git a/pkg/volume/cinder/BUILD b/pkg/volume/cinder/BUILD index 30e6822573ada..eaa1a4b508d1e 100644 --- a/pkg/volume/cinder/BUILD +++ b/pkg/volume/cinder/BUILD @@ -29,11 +29,13 @@ go_library( "//pkg/util/strings:go_default_library", "//pkg/volume:go_default_library", "//pkg/volume/util:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", ], ) diff --git a/pkg/volume/cinder/attacher.go b/pkg/volume/cinder/attacher.go index ace2100306b50..8d976ca4a1d28 100644 --- a/pkg/volume/cinder/attacher.go +++ b/pkg/volume/cinder/attacher.go @@ -25,6 +25,7 @@ import ( "github.com/golang/glog" "k8s.io/apimachinery/pkg/types" + "k8s.io/apimachinery/pkg/util/wait" "k8s.io/kubernetes/pkg/util/exec" "k8s.io/kubernetes/pkg/util/mount" "k8s.io/kubernetes/pkg/volume" @@ -41,7 +42,13 @@ var _ volume.Attacher = &cinderDiskAttacher{} var _ volume.AttachableVolumePlugin = &cinderPlugin{} const ( - checkSleepDuration = time.Second + checkSleepDuration = 1 * time.Second + operationFinishInitDealy = 1 * time.Second + operationFinishFactor = 1.1 + operationFinishSteps = 10 + diskDetachInitDealy = 1 * time.Second + diskDetachFactor = 1.2 + diskDetachSteps = 13 ) func (plugin *cinderPlugin) NewAttacher() (volume.Attacher, error) { @@ -267,6 +274,63 @@ func (plugin *cinderPlugin) NewDetacher() (volume.Detacher, error) { }, nil } +func (detacher *cinderDiskDetacher) waitOperationFinished(volumeID string) error { + backoff := wait.Backoff{ + Duration: operationFinishInitDealy, + Factor: operationFinishFactor, + Steps: operationFinishSteps, + } + + var volumeStatus string + err := wait.ExponentialBackoff(backoff, func() (bool, error) { + var pending bool + var err error + pending, volumeStatus, err = detacher.cinderProvider.OperationPending(volumeID) + if err == nil { + if pending == false { + return true, nil + } else { + return false, nil + } + } else { + return false, err + } + }) + + if err == wait.ErrWaitTimeout { + err = fmt.Errorf("Volume %q is %s, can't finish within the alloted time", volumeID, volumeStatus) + } + + return err +} + +func (detacher *cinderDiskDetacher) waitDiskDetached(instanceID, volumeID string) error { + backoff := wait.Backoff{ + Duration: diskDetachInitDealy, + Factor: diskDetachFactor, + Steps: diskDetachSteps, + } + + err := wait.ExponentialBackoff(backoff, func() (bool, error) { + attached, err := detacher.cinderProvider.DiskIsAttached(instanceID, volumeID) + if err == nil { + if attached == false { + return true, nil + } else { + return false, nil + } + } else { + return false, err + } + }) + + if err == wait.ErrWaitTimeout { + err = fmt.Errorf("Volume %q failed to detach within the alloted time", volumeID) + } + + return err +} + func (detacher *cinderDiskDetacher) Detach(deviceMountPath string, nodeName types.NodeName) error { volumeID := path.Base(deviceMountPath) instances, res := detacher.cinderProvider.Instances() @@ -278,6 +342,10 @@ func (detacher *cinderDiskDetacher) Detach(deviceMountPath string, nodeName type instanceID = instanceID[(ind + 1):] } + if err := detacher.waitOperationFinished(volumeID); err != nil { + return err + } + attached, err := detacher.cinderProvider.DiskIsAttached(instanceID, volumeID) if err != nil { // Log error and continue with detach @@ -293,10 +361,14 @@ func (detacher *cinderDiskDetacher) Detach(deviceMountPath string, nodeName type } if err = detacher.cinderProvider.DetachDisk(instanceID, volumeID); err != nil { - glog.Errorf("Error detaching volume %q: %v", volumeID, err) + glog.Errorf("Error detaching volume %q from node %q: %v", volumeID, nodeName, err) + return err + } + if err = detacher.waitDiskDetached(instanceID, volumeID); err != nil { + glog.Errorf("Error waiting for volume %q to detach from node %q: %v", volumeID, nodeName, err) return err } - glog.Infof("detached volume %q from instance %q", volumeID, instanceID) + glog.Infof("detached volume %q from node %q", volumeID, nodeName) return nil } diff --git a/pkg/volume/cinder/attacher_test.go b/pkg/volume/cinder/attacher_test.go index 6f13bad32cfba..534ee57c864db 100644 --- a/pkg/volume/cinder/attacher_test.go +++ b/pkg/volume/cinder/attacher_test.go @@ -36,6 +36,8 @@ import ( const VolumeStatusPending = "pending" const VolumeStatusDone = "done" +var VolumeIsNotAttached = true + func TestGetDeviceName_Volume(t *testing.T) { plugin := newPlugin() name := "my-cinder-volume" @@ -96,6 +98,7 @@ type testcase struct { disksAreAttached disksAreAttachedCall diskPath diskPathCall t *testing.T + notAttached *bool instanceID string // Actual test to run @@ -118,6 +121,7 @@ func TestAttachDetach(t *testing.T) { diskCheckError := errors.New("Fake DiskIsAttached error") diskPathError := errors.New("Fake GetAttachmentDiskPath error") disksCheckError := errors.New("Fake DisksAreAttached error") + operationFinishTimeout := errors.New("Fake waitOperationFinished error") tests := []testcase{ // Successful Attach call { @@ -247,10 +251,11 @@ func TestAttachDetach(t *testing.T) { // Detach succeeds { - name: "Detach_Positive", - instanceID: instanceID, - diskIsAttached: diskIsAttachedCall{instanceID, volumeID, true, nil}, - detach: detachCall{instanceID, volumeID, nil}, + name: "Detach_Positive", + instanceID: instanceID, + operationPending: operationPendingCall{volumeID, false, done, nil}, + diskIsAttached: diskIsAttachedCall{instanceID, volumeID, true, nil}, + detach: detachCall{instanceID, volumeID, nil}, test: func(testcase *testcase) (string, error) { detacher := newDetacher(testcase) return "", detacher.Detach(volumeID, nodeName) @@ -259,9 +264,10 @@ func TestAttachDetach(t *testing.T) { // Disk is already detached { - name: "Detach_Positive_AlreadyDetached", - instanceID: instanceID, - diskIsAttached: diskIsAttachedCall{instanceID, volumeID, false, nil}, + name: "Detach_Positive_AlreadyDetached", + instanceID: instanceID, + operationPending: operationPendingCall{volumeID, false, done, nil}, + diskIsAttached: diskIsAttachedCall{instanceID, volumeID, false, nil}, test: func(testcase *testcase) (string, error) { detacher := newDetacher(testcase) return "", detacher.Detach(volumeID, nodeName) @@ -270,10 +276,11 @@ func TestAttachDetach(t *testing.T) { // Detach succeeds when DiskIsAttached fails { - name: "Detach_Positive_CheckFails", - instanceID: instanceID, - diskIsAttached: diskIsAttachedCall{instanceID, volumeID, false, diskCheckError}, - detach: detachCall{instanceID, volumeID, nil}, + name: "Detach_Positive_CheckFails", + instanceID: instanceID, + operationPending: operationPendingCall{volumeID, false, done, nil}, + diskIsAttached: diskIsAttachedCall{instanceID, volumeID, false, diskCheckError}, + detach: detachCall{instanceID, volumeID, nil}, test: func(testcase *testcase) (string, error) { detacher := newDetacher(testcase) return "", detacher.Detach(volumeID, nodeName) @@ -282,20 +289,36 @@ func TestAttachDetach(t *testing.T) { // Detach fails { - name: "Detach_Negative", - instanceID: instanceID, - diskIsAttached: diskIsAttachedCall{instanceID, volumeID, false, diskCheckError}, - detach: detachCall{instanceID, volumeID, detachError}, + name: "Detach_Negative", + instanceID: instanceID, + operationPending: operationPendingCall{volumeID, false, done, nil}, + diskIsAttached: diskIsAttachedCall{instanceID, volumeID, false, diskCheckError}, + detach: detachCall{instanceID, volumeID, detachError}, test: func(testcase *testcase) (string, error) { detacher := newDetacher(testcase) return "", detacher.Detach(volumeID, nodeName) }, expectedError: detachError, }, + + // // Disk is detaching + { + name: "Detach_Is_Detaching", + instanceID: instanceID, + operationPending: operationPendingCall{volumeID, true, pending, operationFinishTimeout}, + test: func(testcase *testcase) (string, error) { + detacher := newDetacher(testcase) + return "", detacher.Detach(volumeID, nodeName) + }, + expectedError: operationFinishTimeout, + }, } for _, testcase := range tests { testcase.t = t + // set VolumeIsNotAttached to test detach case, attach case ignore it + VolumeIsNotAttached = false + testcase.notAttached = &VolumeIsNotAttached result, err := testcase.test(&testcase) if err != testcase.expectedError { t.Errorf("%s failed: expected err=%q, got %q", testcase.name, testcase.expectedError, err) @@ -457,6 +480,8 @@ func (testcase *testcase) AttachDisk(instanceID, volumeID string) (string, error glog.V(4).Infof("AttachDisk call: %s, %s, returning %q, %v", volumeID, instanceID, expected.retDeviceName, expected.ret) + VolumeIsNotAttached = false + testcase.notAttached = &VolumeIsNotAttached return expected.retDeviceName, expected.ret } @@ -482,6 +507,8 @@ func (testcase *testcase) DetachDisk(instanceID, volumeID string) error { glog.V(4).Infof("DetachDisk call: %s, %s, returning %v", volumeID, instanceID, expected.ret) + VolumeIsNotAttached = true + testcase.notAttached = &VolumeIsNotAttached return expected.ret } @@ -500,6 +527,10 @@ func (testcase *testcase) OperationPending(diskName string) (bool, string, error func (testcase *testcase) DiskIsAttached(instanceID, volumeID string) (bool, error) { expected := &testcase.diskIsAttached + // If testcase call DetachDisk*, return false + if *testcase.notAttached == true { + return false, nil + } if expected.volumeID == "" && expected.instanceID == "" { // testcase.diskIsAttached looks uninitialized, test did not expect to diff --git a/pkg/volume/cinder/cinder.go b/pkg/volume/cinder/cinder.go index 10f27e3610038..fc6fbee01a1b8 100644 --- a/pkg/volume/cinder/cinder.go +++ b/pkg/volume/cinder/cinder.go @@ -36,6 +36,7 @@ import ( "k8s.io/kubernetes/pkg/util/strings" "k8s.io/kubernetes/pkg/volume" "k8s.io/kubernetes/pkg/volume/util" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) // This is the primary entrypoint for volume plugins. @@ -491,7 +492,7 @@ func (c *cinderVolumeProvisioner) Provision() (*v1.PersistentVolume, error) { Name: c.options.PVName, Labels: labels, Annotations: map[string]string{ - "kubernetes.io/createdby": "cinder-dynamic-provisioner", + volumehelper.VolumeDynamicallyCreatedByKey: "cinder-dynamic-provisioner", }, }, Spec: v1.PersistentVolumeSpec{ diff --git a/pkg/volume/configmap/configmap.go b/pkg/volume/configmap/configmap.go index 1134a068b6a6a..4e869293bd7cd 100644 --- a/pkg/volume/configmap/configmap.go +++ b/pkg/volume/configmap/configmap.go @@ -42,13 +42,15 @@ const ( // configMapPlugin implements the VolumePlugin interface. type configMapPlugin struct { - host volume.VolumeHost + host volume.VolumeHost + getConfigMap func(namespace, name string) (*v1.ConfigMap, error) } var _ volume.VolumePlugin = &configMapPlugin{} func (plugin *configMapPlugin) Init(host volume.VolumeHost) error { plugin.host = host + plugin.getConfigMap = host.GetConfigMapFunc() return nil } @@ -86,14 +88,32 @@ func (plugin *configMapPlugin) SupportsBulkVolumeVerification() bool { func (plugin *configMapPlugin) NewMounter(spec *volume.Spec, pod *v1.Pod, opts volume.VolumeOptions) (volume.Mounter, error) { return &configMapVolumeMounter{ - configMapVolume: &configMapVolume{spec.Name(), pod.UID, plugin, plugin.host.GetMounter(), plugin.host.GetWriter(), volume.MetricsNil{}}, - source: *spec.Volume.ConfigMap, - pod: *pod, - opts: &opts}, nil + configMapVolume: &configMapVolume{ + spec.Name(), + pod.UID, + plugin, + plugin.host.GetMounter(), + plugin.host.GetWriter(), + volume.MetricsNil{}, + }, + source: *spec.Volume.ConfigMap, + pod: *pod, + opts: &opts, + getConfigMap: plugin.getConfigMap, + }, nil } func (plugin *configMapPlugin) NewUnmounter(volName string, podUID types.UID) (volume.Unmounter, error) { - return &configMapVolumeUnmounter{&configMapVolume{volName, podUID, plugin, plugin.host.GetMounter(), plugin.host.GetWriter(), volume.MetricsNil{}}}, nil + return &configMapVolumeUnmounter{ + &configMapVolume{ + volName, + podUID, + plugin, + plugin.host.GetMounter(), + plugin.host.GetWriter(), + volume.MetricsNil{}, + }, + }, nil } func (plugin *configMapPlugin) ConstructVolumeSpec(volumeName, mountPath string) (*volume.Spec, error) { @@ -126,9 +146,10 @@ func (sv *configMapVolume) GetPath() string { type configMapVolumeMounter struct { *configMapVolume - source v1.ConfigMapVolumeSource - pod v1.Pod - opts *volume.VolumeOptions + source v1.ConfigMapVolumeSource + pod v1.Pod + opts *volume.VolumeOptions + getConfigMap func(namespace, name string) (*v1.ConfigMap, error) } var _ volume.Mounter = &configMapVolumeMounter{} @@ -174,13 +195,8 @@ func (b *configMapVolumeMounter) SetUpAt(dir string, fsGroup *types.UnixGroupID) return err } - kubeClient := b.plugin.host.GetKubeClient() - if kubeClient == nil { - return fmt.Errorf("Cannot setup configMap volume %v because kube client is not configured", b.volName) - } - optional := b.source.Optional != nil && *b.source.Optional - configMap, err := kubeClient.Core().ConfigMaps(b.pod.Namespace).Get(b.source.Name, metav1.GetOptions{}) + configMap, err := b.getConfigMap(b.pod.Namespace, b.source.Name) if err != nil { if !(errors.IsNotFound(err) && optional) { glog.Errorf("Couldn't get configMap %v/%v: %v", b.pod.Namespace, b.source.Name, err) diff --git a/pkg/volume/flocker/BUILD b/pkg/volume/flocker/BUILD index 1765ad2040dfa..a7fa8593ac32b 100644 --- a/pkg/volume/flocker/BUILD +++ b/pkg/volume/flocker/BUILD @@ -24,6 +24,7 @@ go_library( "//pkg/util/strings:go_default_library", "//pkg/volume:go_default_library", "//pkg/volume/util:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/github.com/clusterhq/flocker-go:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", diff --git a/pkg/volume/flocker/flocker_volume.go b/pkg/volume/flocker/flocker_volume.go index 46d01d5b9f60a..703ae6f681560 100644 --- a/pkg/volume/flocker/flocker_volume.go +++ b/pkg/volume/flocker/flocker_volume.go @@ -23,6 +23,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/kubernetes/pkg/api/v1" "k8s.io/kubernetes/pkg/volume" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) type volumeManager interface { @@ -73,7 +74,7 @@ func (c *flockerVolumeProvisioner) Provision() (*v1.PersistentVolume, error) { Name: c.options.PVName, Labels: map[string]string{}, Annotations: map[string]string{ - "kubernetes.io/createdby": "flocker-dynamic-provisioner", + volumehelper.VolumeDynamicallyCreatedByKey: "flocker-dynamic-provisioner", }, }, Spec: v1.PersistentVolumeSpec{ diff --git a/pkg/volume/gce_pd/BUILD b/pkg/volume/gce_pd/BUILD index f52edac1499d4..b1cd654277ecb 100644 --- a/pkg/volume/gce_pd/BUILD +++ b/pkg/volume/gce_pd/BUILD @@ -26,6 +26,7 @@ go_library( "//pkg/util/strings:go_default_library", "//pkg/volume:go_default_library", "//pkg/volume/util:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", diff --git a/pkg/volume/gce_pd/gce_pd.go b/pkg/volume/gce_pd/gce_pd.go index 069a7f20a4030..9abb1982a3d5f 100644 --- a/pkg/volume/gce_pd/gce_pd.go +++ b/pkg/volume/gce_pd/gce_pd.go @@ -31,6 +31,7 @@ import ( "k8s.io/kubernetes/pkg/util/strings" "k8s.io/kubernetes/pkg/volume" "k8s.io/kubernetes/pkg/volume/util" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) // This is the primary entrypoint for volume plugins. @@ -384,7 +385,7 @@ func (c *gcePersistentDiskProvisioner) Provision() (*v1.PersistentVolume, error) Name: c.options.PVName, Labels: map[string]string{}, Annotations: map[string]string{ - "kubernetes.io/createdby": "gce-pd-dynamic-provisioner", + volumehelper.VolumeDynamicallyCreatedByKey: "gce-pd-dynamic-provisioner", }, }, Spec: v1.PersistentVolumeSpec{ diff --git a/pkg/volume/glusterfs/glusterfs.go b/pkg/volume/glusterfs/glusterfs.go index 3fbf293331323..dc790731c8f65 100644 --- a/pkg/volume/glusterfs/glusterfs.go +++ b/pkg/volume/glusterfs/glusterfs.go @@ -155,7 +155,7 @@ func (plugin *glusterfsPlugin) NewMounter(spec *volume.Spec, pod *v1.Pod, _ volu return nil, fmt.Errorf("failed to get endpoint %s, error %v", epName, err) } glog.Errorf("glusterfs: failed to get endpoint %s[%v]", epName, err) - if spec != nil && spec.PersistentVolume.Annotations["kubernetes.io/createdby"] == heketiAnn { + if spec != nil && spec.PersistentVolume.Annotations[volumehelper.VolumeDynamicallyCreatedByKey] == heketiAnn { class, err := volutil.GetClassForVolume(plugin.host.GetKubeClient(), spec.PersistentVolume) if err != nil { return nil, fmt.Errorf("glusterfs: failed to get storageclass, error: %v", err) @@ -381,52 +381,6 @@ func (b *glusterfsMounter) setUpAtInternal(dir string) error { options = append(options, "backup-volfile-servers="+dstrings.Join(addrlist[:], ":")) mountOptions := volume.JoinMountOptions(b.mountOptions, options) - //fetch client version. - mountBinaryVerStr := "" - mountStr := "" - - cmdOut, err := b.exe.Command(linuxGlusterMountBinary, "-V").CombinedOutput() - if err != nil { - glog.Warningf("Failed to get binary %q version", linuxGlusterMountBinary) - } else { - //cmdOut will be filled as shown below. - /* - [root@]# mount.glusterfs -V - glusterfs 3.10.1 - Repository revision: git://git.gluster.org/glusterfs.git - Copyright (c) 2006-2016 Red Hat, Inc. - GlusterFS comes with ABSOLUTELY NO WARRANTY. - ......... - */ - - parseStr := string(cmdOut) - if parseStr != "" { - - //Store the version line from parseStr - mountStrSlice := dstrings.Split(parseStr, "\n") - if len(mountStrSlice) > 0 { - mountStr = mountStrSlice[0] - } - if mountStr != "" { - - // Get the [binary, version] slice. - mountBinaryVerSlice := dstrings.Split(mountStr, " ") - if len(mountBinaryVerSlice) >= 2 { - - // Get the 'version' string in mountBinaryVerStr - mountBinaryVerStr = mountBinaryVerSlice[1] - } - - } - } - - for i := len(mountOptions) - 1; i >= 0; i-- { - if mountOptions[i] == "auto_unmount" && mountBinaryVerStr != "" && mountBinaryVerStr < autoUnmountBinaryVer { - mountOptions = append(mountOptions[:i], mountOptions[i+1:]...) - } - } - } - // Avoid mount storm, pick a host randomly. // Iterate all hosts until mount succeeds. for _, ip := range addrlist { @@ -435,6 +389,25 @@ func (b *glusterfsMounter) setUpAtInternal(dir string) error { glog.Infof("glusterfs: successfully mounted %s", dir) return nil } + + // Give a try without `auto_unmount mount option, because + // it could be that gluster fuse client is older version and + // mount.glusterfs is unaware of `auto_unmount`. + // Use a mount string without `auto_unmount`` + + autoMountOptions := make([]string, len(mountOptions)) + for _, opt := range mountOptions { + if opt != "auto_unmount" { + autoMountOptions = append(autoMountOptions, opt) + } + } + + autoerrs := b.mounter.Mount(ip+":"+b.path, dir, "glusterfs", autoMountOptions) + if autoerrs == nil { + glog.Infof("glusterfs: successfully mounted %s", dir) + return nil + } + } // Failed mount scenario. @@ -446,6 +419,7 @@ func (b *glusterfsMounter) setUpAtInternal(dir string) error { return fmt.Errorf("glusterfs: mount failed: %v the following error information was pulled from the glusterfs log to help diagnose this issue: %v", errs, logerror) } return fmt.Errorf("glusterfs: mount failed: %v", errs) + } func getVolumeSource( @@ -862,11 +836,11 @@ func (p *glusterfsVolumeProvisioner) Provision() (*v1.PersistentVolume, error) { gidStr := strconv.FormatInt(int64(gid), 10) pv.Annotations = map[string]string{ - volumehelper.VolumeGidAnnotationKey: gidStr, - "kubernetes.io/createdby": heketiAnn, - glusterTypeAnn: "file", - "Description": glusterDescAnn, - v1.MountOptionAnnotation: "auto_unmount", + volumehelper.VolumeGidAnnotationKey: gidStr, + volumehelper.VolumeDynamicallyCreatedByKey: heketiAnn, + glusterTypeAnn: "file", + "Description": glusterDescAnn, + v1.MountOptionAnnotation: "auto_unmount", } pv.Spec.Capacity = v1.ResourceList{ diff --git a/pkg/volume/host_path/BUILD b/pkg/volume/host_path/BUILD index 004b988e2676b..0d0776dd567ac 100644 --- a/pkg/volume/host_path/BUILD +++ b/pkg/volume/host_path/BUILD @@ -18,6 +18,7 @@ go_library( deps = [ "//pkg/api/v1:go_default_library", "//pkg/volume:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/uuid:go_default_library", diff --git a/pkg/volume/host_path/host_path.go b/pkg/volume/host_path/host_path.go index df94a9b6a3008..35e88c1753063 100644 --- a/pkg/volume/host_path/host_path.go +++ b/pkg/volume/host_path/host_path.go @@ -26,6 +26,7 @@ import ( "k8s.io/apimachinery/pkg/util/uuid" "k8s.io/kubernetes/pkg/api/v1" "k8s.io/kubernetes/pkg/volume" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) // This is the primary entrypoint for volume plugins. @@ -250,7 +251,7 @@ func (r *hostPathProvisioner) Provision() (*v1.PersistentVolume, error) { ObjectMeta: metav1.ObjectMeta{ Name: r.options.PVName, Annotations: map[string]string{ - "kubernetes.io/createdby": "hostpath-dynamic-provisioner", + volumehelper.VolumeDynamicallyCreatedByKey: "hostpath-dynamic-provisioner", }, }, Spec: v1.PersistentVolumeSpec{ @@ -297,8 +298,7 @@ func (r *hostPathDeleter) Delete() error { return os.RemoveAll(r.GetPath()) } -func getVolumeSource( - spec *volume.Spec) (*v1.HostPathVolumeSource, bool, error) { +func getVolumeSource(spec *volume.Spec) (*v1.HostPathVolumeSource, bool, error) { if spec.Volume != nil && spec.Volume.HostPath != nil { return spec.Volume.HostPath, spec.ReadOnly, nil } else if spec.PersistentVolume != nil && diff --git a/pkg/volume/local/BUILD b/pkg/volume/local/BUILD new file mode 100644 index 0000000000000..e6172e5ce3180 --- /dev/null +++ b/pkg/volume/local/BUILD @@ -0,0 +1,56 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "local.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/api/v1:go_default_library", + "//pkg/util/mount:go_default_library", + "//pkg/util/strings:go_default_library", + "//pkg/volume:go_default_library", + "//pkg/volume/util:go_default_library", + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + ], +) + +go_test( + name = "go_default_test", + srcs = ["local_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//pkg/api/v1:go_default_library", + "//pkg/volume:go_default_library", + "//pkg/volume/testing:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/client-go/util/testing:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/pkg/volume/local/OWNERS b/pkg/volume/local/OWNERS new file mode 100644 index 0000000000000..2737b7296e470 --- /dev/null +++ b/pkg/volume/local/OWNERS @@ -0,0 +1,21 @@ +approvers: +- saad-ali +- thockin +- vishh +- msau42 +- jingxu97 +- jsafrane +reviewers: +- thockin +- smarterclayton +- deads2k +- brendandburns +- derekwaynecarr +- pmorie +- saad-ali +- justinsb +- jsafrane +- rootfs +- jingxu97 +- msau42 +- vishh diff --git a/pkg/volume/local/doc.go b/pkg/volume/local/doc.go new file mode 100644 index 0000000000000..6817475508e1e --- /dev/null +++ b/pkg/volume/local/doc.go @@ -0,0 +1,18 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// Package local contains the internal representation of local volumes +package local // import "k8s.io/kubernetes/pkg/volume/local" diff --git a/pkg/volume/local/local.go b/pkg/volume/local/local.go new file mode 100644 index 0000000000000..9e485c52b3473 --- /dev/null +++ b/pkg/volume/local/local.go @@ -0,0 +1,267 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package local + +import ( + "fmt" + "os" + + "github.com/golang/glog" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/types" + "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/pkg/util/mount" + "k8s.io/kubernetes/pkg/util/strings" + "k8s.io/kubernetes/pkg/volume" + "k8s.io/kubernetes/pkg/volume/util" +) + +// This is the primary entrypoint for volume plugins. +func ProbeVolumePlugins() []volume.VolumePlugin { + return []volume.VolumePlugin{&localVolumePlugin{}} +} + +type localVolumePlugin struct { + host volume.VolumeHost +} + +var _ volume.VolumePlugin = &localVolumePlugin{} +var _ volume.PersistentVolumePlugin = &localVolumePlugin{} + +const ( + localVolumePluginName = "kubernetes.io/local-volume" +) + +func (plugin *localVolumePlugin) Init(host volume.VolumeHost) error { + plugin.host = host + return nil +} + +func (plugin *localVolumePlugin) GetPluginName() string { + return localVolumePluginName +} + +func (plugin *localVolumePlugin) GetVolumeName(spec *volume.Spec) (string, error) { + // This volume is only supported as a PersistentVolumeSource, so the PV name is unique + return spec.Name(), nil +} + +func (plugin *localVolumePlugin) CanSupport(spec *volume.Spec) bool { + // This volume is only supported as a PersistentVolumeSource + return (spec.PersistentVolume != nil && spec.PersistentVolume.Spec.Local != nil) +} + +func (plugin *localVolumePlugin) RequiresRemount() bool { + return false +} + +func (plugin *localVolumePlugin) SupportsMountOption() bool { + return false +} + +func (plugin *localVolumePlugin) SupportsBulkVolumeVerification() bool { + return false +} + +func (plugin *localVolumePlugin) GetAccessModes() []v1.PersistentVolumeAccessMode { + // The current meaning of AccessMode is how many nodes can attach to it, not how many pods can mount it + return []v1.PersistentVolumeAccessMode{ + v1.ReadWriteOnce, + } +} + +func getVolumeSource(spec *volume.Spec) (*v1.LocalVolumeSource, bool, error) { + if spec.PersistentVolume != nil && spec.PersistentVolume.Spec.Local != nil { + return spec.PersistentVolume.Spec.Local, spec.ReadOnly, nil + } + + return nil, false, fmt.Errorf("Spec does not reference a Local volume type") +} + +func (plugin *localVolumePlugin) NewMounter(spec *volume.Spec, pod *v1.Pod, _ volume.VolumeOptions) (volume.Mounter, error) { + volumeSource, readOnly, err := getVolumeSource(spec) + if err != nil { + return nil, err + } + + return &localVolumeMounter{ + localVolume: &localVolume{ + podUID: pod.UID, + volName: spec.Name(), + mounter: plugin.host.GetMounter(), + plugin: plugin, + globalPath: volumeSource.Path, + }, + readOnly: readOnly, + }, nil + +} + +func (plugin *localVolumePlugin) NewUnmounter(volName string, podUID types.UID) (volume.Unmounter, error) { + return &localVolumeUnmounter{ + localVolume: &localVolume{ + podUID: podUID, + volName: volName, + mounter: plugin.host.GetMounter(), + plugin: plugin, + }, + }, nil +} + +// TODO: check if no path and no topology constraints are ok +func (plugin *localVolumePlugin) ConstructVolumeSpec(volumeName, mountPath string) (*volume.Spec, error) { + localVolume := &v1.PersistentVolume{ + ObjectMeta: metav1.ObjectMeta{ + Name: volumeName, + }, + Spec: v1.PersistentVolumeSpec{ + PersistentVolumeSource: v1.PersistentVolumeSource{ + Local: &v1.LocalVolumeSource{ + Path: "", + }, + }, + }, + } + return volume.NewSpecFromPersistentVolume(localVolume, false), nil +} + +// Local volumes represent a local directory on a node. +// The directory at the globalPath will be bind-mounted to the pod's directory +type localVolume struct { + volName string + podUID types.UID + // Global path to the volume + globalPath string + // Mounter interface that provides system calls to mount the global path to the pod local path. + mounter mount.Interface + plugin *localVolumePlugin + // TODO: add metrics + volume.MetricsNil +} + +func (l *localVolume) GetPath() string { + return l.plugin.host.GetPodVolumeDir(l.podUID, strings.EscapeQualifiedNameForDisk(localVolumePluginName), l.volName) +} + +type localVolumeMounter struct { + *localVolume + readOnly bool +} + +var _ volume.Mounter = &localVolumeMounter{} + +func (m *localVolumeMounter) GetAttributes() volume.Attributes { + return volume.Attributes{ + ReadOnly: m.readOnly, + Managed: !m.readOnly, + SupportsSELinux: true, + } +} + +// CanMount checks prior to mount operations to verify that the required components (binaries, etc.) +// to mount the volume are available on the underlying node. +// If not, it returns an error +func (m *localVolumeMounter) CanMount() error { + return nil +} + +// SetUp bind mounts the directory to the volume path +func (m *localVolumeMounter) SetUp(fsGroup *types.UnixGroupID) error { + return m.SetUpAt(m.GetPath(), fsGroup) +} + +// SetUpAt bind mounts the directory to the volume path and sets up volume ownership +func (m *localVolumeMounter) SetUpAt(dir string, fsGroup *types.UnixGroupID) error { + if m.globalPath == "" { + err := fmt.Errorf("LocalVolume volume %q path is empty", m.volName) + return err + } + + notMnt, err := m.mounter.IsLikelyNotMountPoint(dir) + glog.V(4).Infof("LocalVolume mount setup: PodDir(%s) VolDir(%s) Mounted(%t) Error(%v), ReadOnly(%t)", dir, m.globalPath, !notMnt, err, m.readOnly) + if err != nil && !os.IsNotExist(err) { + glog.Errorf("cannot validate mount point: %s %v", dir, err) + return err + } + if !notMnt { + return nil + } + + if err := os.MkdirAll(dir, 0750); err != nil { + glog.Errorf("mkdir failed on disk %s (%v)", dir, err) + return err + } + + // Perform a bind mount to the full path to allow duplicate mounts of the same volume. + options := []string{"bind"} + if m.readOnly { + options = append(options, "ro") + } + + glog.V(4).Infof("attempting to mount %s", dir) + err = m.mounter.Mount(m.globalPath, dir, "", options) + if err != nil { + glog.Errorf("Mount of volume %s failed: %v", dir, err) + notMnt, mntErr := m.mounter.IsLikelyNotMountPoint(dir) + if mntErr != nil { + glog.Errorf("IsLikelyNotMountPoint check failed: %v", mntErr) + return err + } + if !notMnt { + if mntErr = m.mounter.Unmount(dir); mntErr != nil { + glog.Errorf("Failed to unmount: %v", mntErr) + return err + } + notMnt, mntErr = m.mounter.IsLikelyNotMountPoint(dir) + if mntErr != nil { + glog.Errorf("IsLikelyNotMountPoint check failed: %v", mntErr) + return err + } + if !notMnt { + // This is very odd, we don't expect it. We'll try again next sync loop. + glog.Errorf("%s is still mounted, despite call to unmount(). Will try again next sync loop.", dir) + return err + } + } + os.Remove(dir) + return err + } + + if !m.readOnly { + // TODO: how to prevent multiple mounts with conflicting fsGroup? + return volume.SetVolumeOwnership(m, fsGroup) + } + return nil +} + +type localVolumeUnmounter struct { + *localVolume +} + +var _ volume.Unmounter = &localVolumeUnmounter{} + +// TearDown unmounts the bind mount +func (u *localVolumeUnmounter) TearDown() error { + return u.TearDownAt(u.GetPath()) +} + +// TearDownAt unmounts the bind mount +func (u *localVolumeUnmounter) TearDownAt(dir string) error { + glog.V(4).Infof("Unmounting volume %q at path %q\n", u.volName, dir) + return util.UnmountPath(dir, u.mounter) +} diff --git a/pkg/volume/local/local_test.go b/pkg/volume/local/local_test.go new file mode 100644 index 0000000000000..b417eff3ea3b4 --- /dev/null +++ b/pkg/volume/local/local_test.go @@ -0,0 +1,288 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package local + +import ( + "os" + "path" + "testing" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/types" + utiltesting "k8s.io/client-go/util/testing" + "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/pkg/volume" + volumetest "k8s.io/kubernetes/pkg/volume/testing" +) + +const ( + testPVName = "pvA" + testMountPath = "pods/poduid/volumes/kubernetes.io~local-volume/pvA" + testNodeName = "fakeNodeName" +) + +func getPlugin(t *testing.T) (string, volume.VolumePlugin) { + tmpDir, err := utiltesting.MkTmpdir("localVolumeTest") + if err != nil { + t.Fatalf("can't make a temp dir: %v", err) + } + + plugMgr := volume.VolumePluginMgr{} + plugMgr.InitPlugins(ProbeVolumePlugins(), volumetest.NewFakeVolumeHost(tmpDir, nil, nil)) + + plug, err := plugMgr.FindPluginByName(localVolumePluginName) + if err != nil { + os.RemoveAll(tmpDir) + t.Fatalf("Can't find the plugin by name") + } + if plug.GetPluginName() != localVolumePluginName { + t.Errorf("Wrong name: %s", plug.GetPluginName()) + } + return tmpDir, plug +} + +func getPersistentPlugin(t *testing.T) (string, volume.PersistentVolumePlugin) { + tmpDir, err := utiltesting.MkTmpdir("localVolumeTest") + if err != nil { + t.Fatalf("can't make a temp dir: %v", err) + } + + plugMgr := volume.VolumePluginMgr{} + plugMgr.InitPlugins(ProbeVolumePlugins(), volumetest.NewFakeVolumeHost(tmpDir, nil, nil)) + + plug, err := plugMgr.FindPersistentPluginByName(localVolumePluginName) + if err != nil { + os.RemoveAll(tmpDir) + t.Fatalf("Can't find the plugin by name") + } + if plug.GetPluginName() != localVolumePluginName { + t.Errorf("Wrong name: %s", plug.GetPluginName()) + } + return tmpDir, plug +} + +func getTestVolume(readOnly bool) *volume.Spec { + pv := &v1.PersistentVolume{ + ObjectMeta: metav1.ObjectMeta{ + Name: testPVName, + }, + Spec: v1.PersistentVolumeSpec{ + PersistentVolumeSource: v1.PersistentVolumeSource{ + Local: &v1.LocalVolumeSource{ + Path: "/test-vol", + }, + }, + }, + } + return volume.NewSpecFromPersistentVolume(pv, readOnly) +} + +func contains(modes []v1.PersistentVolumeAccessMode, mode v1.PersistentVolumeAccessMode) bool { + for _, m := range modes { + if m == mode { + return true + } + } + return false +} + +func TestCanSupport(t *testing.T) { + tmpDir, plug := getPlugin(t) + defer os.RemoveAll(tmpDir) + + if !plug.CanSupport(getTestVolume(false)) { + t.Errorf("Expected true") + } +} + +func TestGetAccessModes(t *testing.T) { + tmpDir, plug := getPersistentPlugin(t) + defer os.RemoveAll(tmpDir) + + modes := plug.GetAccessModes() + if !contains(modes, v1.ReadWriteOnce) { + t.Errorf("Expected AccessModeType %q", v1.ReadWriteOnce) + } + + if contains(modes, v1.ReadWriteMany) { + t.Errorf("Found AccessModeType %q, expected not", v1.ReadWriteMany) + } + if contains(modes, v1.ReadOnlyMany) { + t.Errorf("Found AccessModeType %q, expected not", v1.ReadOnlyMany) + } +} + +func TestGetVolumeName(t *testing.T) { + tmpDir, plug := getPersistentPlugin(t) + defer os.RemoveAll(tmpDir) + + volName, err := plug.GetVolumeName(getTestVolume(false)) + if err != nil { + t.Errorf("Failed to get volume name: %v", err) + } + if volName != testPVName { + t.Errorf("Expected volume name %q, got %q", testPVName, volName) + } +} + +func TestMountUnmount(t *testing.T) { + tmpDir, plug := getPlugin(t) + defer os.RemoveAll(tmpDir) + + pod := &v1.Pod{ObjectMeta: metav1.ObjectMeta{UID: types.UID("poduid")}} + mounter, err := plug.NewMounter(getTestVolume(false), pod, volume.VolumeOptions{}) + if err != nil { + t.Errorf("Failed to make a new Mounter: %v", err) + } + if mounter == nil { + t.Fatalf("Got a nil Mounter") + } + + volPath := path.Join(tmpDir, testMountPath) + path := mounter.GetPath() + if path != volPath { + t.Errorf("Got unexpected path: %s", path) + } + + if err := mounter.SetUp(nil); err != nil { + t.Errorf("Expected success, got: %v", err) + } + if _, err := os.Stat(path); err != nil { + if os.IsNotExist(err) { + t.Errorf("SetUp() failed, volume path not created: %s", path) + } else { + t.Errorf("SetUp() failed: %v", err) + } + } + + unmounter, err := plug.NewUnmounter(testPVName, pod.UID) + if err != nil { + t.Errorf("Failed to make a new Unmounter: %v", err) + } + if unmounter == nil { + t.Fatalf("Got a nil Unmounter") + } + + if err := unmounter.TearDown(); err != nil { + t.Errorf("Expected success, got: %v", err) + } + if _, err := os.Stat(path); err == nil { + t.Errorf("TearDown() failed, volume path still exists: %s", path) + } else if !os.IsNotExist(err) { + t.Errorf("SetUp() failed: %v", err) + } +} + +func TestConstructVolumeSpec(t *testing.T) { + tmpDir, plug := getPlugin(t) + defer os.RemoveAll(tmpDir) + + volPath := path.Join(tmpDir, testMountPath) + spec, err := plug.ConstructVolumeSpec(testPVName, volPath) + if err != nil { + t.Errorf("ConstructVolumeSpec() failed: %v", err) + } + if spec == nil { + t.Fatalf("ConstructVolumeSpec() returned nil") + } + + volName := spec.Name() + if volName != testPVName { + t.Errorf("Expected volume name %q, got %q", testPVName, volName) + } + + if spec.Volume != nil { + t.Errorf("Volume object returned, expected nil") + } + + pv := spec.PersistentVolume + if pv == nil { + t.Fatalf("PersistentVolume object nil") + } + + ls := pv.Spec.PersistentVolumeSource.Local + if ls == nil { + t.Fatalf("LocalVolumeSource object nil") + } +} + +func TestPersistentClaimReadOnlyFlag(t *testing.T) { + tmpDir, plug := getPlugin(t) + defer os.RemoveAll(tmpDir) + + // Read only == true + pod := &v1.Pod{ObjectMeta: metav1.ObjectMeta{UID: types.UID("poduid")}} + mounter, err := plug.NewMounter(getTestVolume(true), pod, volume.VolumeOptions{}) + if err != nil { + t.Errorf("Failed to make a new Mounter: %v", err) + } + if mounter == nil { + t.Fatalf("Got a nil Mounter") + } + if !mounter.GetAttributes().ReadOnly { + t.Errorf("Expected true for mounter.IsReadOnly") + } + + // Read only == false + mounter, err = plug.NewMounter(getTestVolume(false), pod, volume.VolumeOptions{}) + if err != nil { + t.Errorf("Failed to make a new Mounter: %v", err) + } + if mounter == nil { + t.Fatalf("Got a nil Mounter") + } + if mounter.GetAttributes().ReadOnly { + t.Errorf("Expected false for mounter.IsReadOnly") + } +} + +func TestUnsupportedPlugins(t *testing.T) { + tmpDir, err := utiltesting.MkTmpdir("localVolumeTest") + if err != nil { + t.Fatalf("can't make a temp dir: %v", err) + } + defer os.RemoveAll(tmpDir) + + plugMgr := volume.VolumePluginMgr{} + plugMgr.InitPlugins(ProbeVolumePlugins(), volumetest.NewFakeVolumeHost(tmpDir, nil, nil)) + spec := getTestVolume(false) + + recyclePlug, err := plugMgr.FindRecyclablePluginBySpec(spec) + if err == nil && recyclePlug != nil { + t.Errorf("Recyclable plugin found, expected none") + } + + deletePlug, err := plugMgr.FindDeletablePluginByName(localVolumePluginName) + if err == nil && deletePlug != nil { + t.Errorf("Deletable plugin found, expected none") + } + + attachPlug, err := plugMgr.FindAttachablePluginByName(localVolumePluginName) + if err == nil && attachPlug != nil { + t.Errorf("Attachable plugin found, expected none") + } + + createPlug, err := plugMgr.FindCreatablePluginBySpec(spec) + if err == nil && createPlug != nil { + t.Errorf("Creatable plugin found, expected none") + } + + provisionPlug, err := plugMgr.FindProvisionablePluginByName(localVolumePluginName) + if err == nil && provisionPlug != nil { + t.Errorf("Provisionable plugin found, expected none") + } +} diff --git a/pkg/volume/photon_pd/BUILD b/pkg/volume/photon_pd/BUILD index 6f4dca51f5f14..21daa033fe9db 100644 --- a/pkg/volume/photon_pd/BUILD +++ b/pkg/volume/photon_pd/BUILD @@ -25,6 +25,7 @@ go_library( "//pkg/util/strings:go_default_library", "//pkg/volume:go_default_library", "//pkg/volume/util:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", diff --git a/pkg/volume/photon_pd/photon_pd.go b/pkg/volume/photon_pd/photon_pd.go index 5a1783a78cec7..e5cd8ca09be5b 100644 --- a/pkg/volume/photon_pd/photon_pd.go +++ b/pkg/volume/photon_pd/photon_pd.go @@ -31,6 +31,7 @@ import ( utilstrings "k8s.io/kubernetes/pkg/util/strings" "k8s.io/kubernetes/pkg/volume" "k8s.io/kubernetes/pkg/volume/util" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) // This is the primary entrypoint for volume plugins. @@ -356,7 +357,7 @@ func (p *photonPersistentDiskProvisioner) Provision() (*v1.PersistentVolume, err Name: p.options.PVName, Labels: map[string]string{}, Annotations: map[string]string{ - "kubernetes.io/createdby": "photon-volume-dynamic-provisioner", + volumehelper.VolumeDynamicallyCreatedByKey: "photon-volume-dynamic-provisioner", }, }, Spec: v1.PersistentVolumeSpec{ diff --git a/pkg/volume/plugins.go b/pkg/volume/plugins.go index 23dec32969675..41721d1eeaf03 100644 --- a/pkg/volume/plugins.go +++ b/pkg/volume/plugins.go @@ -232,12 +232,19 @@ type VolumeHost interface { // Returns a function that returns a secret. GetSecretFunc() func(namespace, name string) (*v1.Secret, error) + + // Returns a function that returns a configmap. + GetConfigMapFunc() func(namespace, name string) (*v1.ConfigMap, error) + + // Returns the labels on the node + GetNodeLabels() (map[string]string, error) } // VolumePluginMgr tracks registered plugins. type VolumePluginMgr struct { mutex sync.Mutex plugins map[string]VolumePlugin + Host VolumeHost } // Spec is an internal representation of a volume. All API volume types translate to Spec. @@ -336,6 +343,7 @@ func (pm *VolumePluginMgr) InitPlugins(plugins []VolumePlugin, host VolumeHost) pm.mutex.Lock() defer pm.mutex.Unlock() + pm.Host = host if pm.plugins == nil { pm.plugins = map[string]VolumePlugin{} } diff --git a/pkg/volume/portworx/BUILD b/pkg/volume/portworx/BUILD index 8c6747b53c5d9..68899c1061918 100644 --- a/pkg/volume/portworx/BUILD +++ b/pkg/volume/portworx/BUILD @@ -38,6 +38,7 @@ go_library( "//pkg/util/mount:go_default_library", "//pkg/util/strings:go_default_library", "//pkg/volume:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/github.com/libopenstorage/openstorage/api:go_default_library", "//vendor/github.com/libopenstorage/openstorage/api/client:go_default_library", diff --git a/pkg/volume/portworx/portworx.go b/pkg/volume/portworx/portworx.go index c63a237adb3c7..9d5a6123aa4d2 100644 --- a/pkg/volume/portworx/portworx.go +++ b/pkg/volume/portworx/portworx.go @@ -29,6 +29,7 @@ import ( "k8s.io/kubernetes/pkg/util/mount" kstrings "k8s.io/kubernetes/pkg/util/strings" "k8s.io/kubernetes/pkg/volume" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) // This is the primary entrypoint for volume plugins. @@ -360,7 +361,7 @@ func (c *portworxVolumeProvisioner) Provision() (*v1.PersistentVolume, error) { Name: c.options.PVName, Labels: map[string]string{}, Annotations: map[string]string{ - "kubernetes.io/createdby": "portworx-volume-dynamic-provisioner", + volumehelper.VolumeDynamicallyCreatedByKey: "portworx-volume-dynamic-provisioner", }, }, Spec: v1.PersistentVolumeSpec{ diff --git a/pkg/volume/projected/projected.go b/pkg/volume/projected/projected.go index 310d8674361e5..390e6eea2d3d9 100644 --- a/pkg/volume/projected/projected.go +++ b/pkg/volume/projected/projected.go @@ -45,8 +45,9 @@ const ( ) type projectedPlugin struct { - host volume.VolumeHost - getSecret func(namespace, name string) (*v1.Secret, error) + host volume.VolumeHost + getSecret func(namespace, name string) (*v1.Secret, error) + getConfigMap func(namespace, name string) (*v1.ConfigMap, error) } var _ volume.VolumePlugin = &projectedPlugin{} @@ -68,6 +69,7 @@ func getPath(uid types.UID, volName string, host volume.VolumeHost) string { func (plugin *projectedPlugin) Init(host volume.VolumeHost) error { plugin.host = host plugin.getSecret = host.GetSecretFunc() + plugin.getConfigMap = host.GetConfigMapFunc() return nil } @@ -235,10 +237,10 @@ func (s *projectedVolumeMounter) collectData() (map[string]volumeutil.FileProjec secretapi, err := s.plugin.getSecret(s.pod.Namespace, source.Secret.Name) if err != nil { if !(errors.IsNotFound(err) && optional) { - glog.Errorf("Couldn't get secret %v/%v", s.pod.Namespace, source.Secret.Name) + glog.Errorf("Couldn't get secret %v/%v: %v", s.pod.Namespace, source.Secret.Name, err) errlist = append(errlist, err) + continue } - secretapi = &v1.Secret{ ObjectMeta: metav1.ObjectMeta{ Namespace: s.pod.Namespace, @@ -248,17 +250,16 @@ func (s *projectedVolumeMounter) collectData() (map[string]volumeutil.FileProjec } secretPayload, err := secret.MakePayload(source.Secret.Items, secretapi, s.source.DefaultMode, optional) if err != nil { - glog.Errorf("Couldn't get secret %v/%v: %v", s.pod.Namespace, source.Secret.Name, err) + glog.Errorf("Couldn't get secret payload %v/%v: %v", s.pod.Namespace, source.Secret.Name, err) errlist = append(errlist, err) continue } - for k, v := range secretPayload { payload[k] = v } } else if source.ConfigMap != nil { optional := source.ConfigMap.Optional != nil && *source.ConfigMap.Optional - configMap, err := kubeClient.Core().ConfigMaps(s.pod.Namespace).Get(source.ConfigMap.Name, metav1.GetOptions{}) + configMap, err := s.plugin.getConfigMap(s.pod.Namespace, source.ConfigMap.Name) if err != nil { if !(errors.IsNotFound(err) && optional) { glog.Errorf("Couldn't get configMap %v/%v: %v", s.pod.Namespace, source.ConfigMap.Name, err) @@ -274,6 +275,7 @@ func (s *projectedVolumeMounter) collectData() (map[string]volumeutil.FileProjec } configMapPayload, err := configmap.MakePayload(source.ConfigMap.Items, configMap, s.source.DefaultMode, optional) if err != nil { + glog.Errorf("Couldn't get configMap payload %v/%v: %v", s.pod.Namespace, source.ConfigMap.Name, err) errlist = append(errlist, err) continue } diff --git a/pkg/volume/projected/projected_test.go b/pkg/volume/projected/projected_test.go index a8d1f4a8377ec..131ff90751618 100644 --- a/pkg/volume/projected/projected_test.go +++ b/pkg/volume/projected/projected_test.go @@ -505,7 +505,8 @@ func TestCollectDataWithConfigMap(t *testing.T) { sources: source.Sources, podUID: pod.UID, plugin: &projectedPlugin{ - host: host, + host: host, + getConfigMap: host.GetConfigMapFunc(), }, }, source: *source, diff --git a/pkg/volume/quobyte/BUILD b/pkg/volume/quobyte/BUILD index 15ba87ec8b6d6..fdd3da86c88d9 100644 --- a/pkg/volume/quobyte/BUILD +++ b/pkg/volume/quobyte/BUILD @@ -23,6 +23,7 @@ go_library( "//pkg/util/strings:go_default_library", "//pkg/volume:go_default_library", "//pkg/volume/util:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/github.com/pborman/uuid:go_default_library", "//vendor/github.com/quobyte/api:go_default_library", diff --git a/pkg/volume/quobyte/quobyte.go b/pkg/volume/quobyte/quobyte.go index 7f14568148b37..9afc91903b8a5 100644 --- a/pkg/volume/quobyte/quobyte.go +++ b/pkg/volume/quobyte/quobyte.go @@ -33,6 +33,7 @@ import ( "k8s.io/kubernetes/pkg/util/strings" "k8s.io/kubernetes/pkg/volume" "k8s.io/kubernetes/pkg/volume/util" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) // ProbeVolumePlugins is the primary entrypoint for volume plugins. @@ -402,6 +403,7 @@ func (provisioner *quobyteVolumeProvisioner) Provision() (*v1.PersistentVolume, return nil, err } pv := new(v1.PersistentVolume) + metav1.SetMetaDataAnnotation(&pv.ObjectMeta, volumehelper.VolumeDynamicallyCreatedByKey, "quobyte-dynamic-provisioner") pv.Spec.PersistentVolumeSource.Quobyte = vol pv.Spec.PersistentVolumeReclaimPolicy = provisioner.options.PersistentVolumeReclaimPolicy pv.Spec.AccessModes = provisioner.options.PVC.Spec.AccessModes diff --git a/pkg/volume/rbd/BUILD b/pkg/volume/rbd/BUILD index df8575e0f5aa1..e79c795b5b393 100644 --- a/pkg/volume/rbd/BUILD +++ b/pkg/volume/rbd/BUILD @@ -26,8 +26,10 @@ go_library( "//pkg/util/strings:go_default_library", "//pkg/volume:go_default_library", "//pkg/volume/util:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/uuid:go_default_library", ], diff --git a/pkg/volume/rbd/rbd.go b/pkg/volume/rbd/rbd.go index 240b10773b9de..4532c311b6879 100644 --- a/pkg/volume/rbd/rbd.go +++ b/pkg/volume/rbd/rbd.go @@ -22,6 +22,7 @@ import ( "github.com/golang/glog" "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/types" "k8s.io/apimachinery/pkg/util/uuid" "k8s.io/kubernetes/pkg/api/v1" @@ -31,6 +32,7 @@ import ( "k8s.io/kubernetes/pkg/util/strings" "k8s.io/kubernetes/pkg/volume" volutil "k8s.io/kubernetes/pkg/volume/util" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) // This is the primary entrypoint for volume plugins. @@ -319,6 +321,7 @@ func (r *rbdVolumeProvisioner) Provision() (*v1.PersistentVolume, error) { } glog.Infof("successfully created rbd image %q", image) pv := new(v1.PersistentVolume) + metav1.SetMetaDataAnnotation(&pv.ObjectMeta, volumehelper.VolumeDynamicallyCreatedByKey, "rbd-dynamic-provisioner") rbd.SecretRef = new(v1.LocalObjectReference) rbd.SecretRef.Name = secretName rbd.RadosUser = r.Id diff --git a/pkg/volume/scaleio/BUILD b/pkg/volume/scaleio/BUILD index 380d6f4bba209..99d375f8de3d5 100644 --- a/pkg/volume/scaleio/BUILD +++ b/pkg/volume/scaleio/BUILD @@ -48,6 +48,7 @@ go_library( "//pkg/util/strings:go_default_library", "//pkg/volume:go_default_library", "//pkg/volume/util:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/github.com/codedellemc/goscaleio:go_default_library", "//vendor/github.com/codedellemc/goscaleio/types/v1:go_default_library", "//vendor/github.com/golang/glog:go_default_library", diff --git a/pkg/volume/scaleio/sio_volume.go b/pkg/volume/scaleio/sio_volume.go index 8ff53049d3154..979ca57d843eb 100644 --- a/pkg/volume/scaleio/sio_volume.go +++ b/pkg/volume/scaleio/sio_volume.go @@ -34,6 +34,7 @@ import ( kstrings "k8s.io/kubernetes/pkg/util/strings" "k8s.io/kubernetes/pkg/volume" "k8s.io/kubernetes/pkg/volume/util" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) type sioVolume struct { @@ -274,7 +275,7 @@ func (v *sioVolume) Provision() (*api.PersistentVolume, error) { Namespace: v.options.PVC.Namespace, Labels: map[string]string{}, Annotations: map[string]string{ - "kubernetes.io/createdby": "scaleio-dynamic-provisioner", + volumehelper.VolumeDynamicallyCreatedByKey: "scaleio-dynamic-provisioner", }, }, Spec: api.PersistentVolumeSpec{ diff --git a/pkg/volume/secret/secret.go b/pkg/volume/secret/secret.go index ae638bb4f0885..40af0d2028081 100644 --- a/pkg/volume/secret/secret.go +++ b/pkg/volume/secret/secret.go @@ -198,7 +198,7 @@ func (b *secretVolumeMounter) SetUpAt(dir string, fsGroup *types.UnixGroupID) er secret, err := b.getSecret(b.pod.Namespace, b.source.SecretName) if err != nil { if !(errors.IsNotFound(err) && optional) { - glog.Errorf("Couldn't get secret %v/%v", b.pod.Namespace, b.source.SecretName) + glog.Errorf("Couldn't get secret %v/%v: %v", b.pod.Namespace, b.source.SecretName, err) return err } secret = &v1.Secret{ diff --git a/pkg/volume/testing/BUILD b/pkg/volume/testing/BUILD index 108dc96197a6e..8615e10f87c98 100644 --- a/pkg/volume/testing/BUILD +++ b/pkg/volume/testing/BUILD @@ -22,6 +22,7 @@ go_library( "//pkg/util/mount:go_default_library", "//pkg/util/strings:go_default_library", "//pkg/volume:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/github.com/stretchr/testify/mock:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", diff --git a/pkg/volume/testing/testing.go b/pkg/volume/testing/testing.go index 8eccc091bf41a..e80a8a5271d0e 100644 --- a/pkg/volume/testing/testing.go +++ b/pkg/volume/testing/testing.go @@ -39,6 +39,7 @@ import ( "k8s.io/kubernetes/pkg/util/mount" utilstrings "k8s.io/kubernetes/pkg/util/strings" . "k8s.io/kubernetes/pkg/volume" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) // fakeVolumeHost is useful for testing volume plugins. @@ -133,6 +134,16 @@ func (f *fakeVolumeHost) GetSecretFunc() func(namespace, name string) (*v1.Secre } } +func (f *fakeVolumeHost) GetConfigMapFunc() func(namespace, name string) (*v1.ConfigMap, error) { + return func(namespace, name string) (*v1.ConfigMap, error) { + return f.kubeClient.Core().ConfigMaps(namespace).Get(name, metav1.GetOptions{}) + } +} + +func (f *fakeVolumeHost) GetNodeLabels() (map[string]string, error) { + return map[string]string{"test-label": "test-value"}, nil +} + func ProbeVolumePlugins(config VolumeConfig) []VolumePlugin { if _, ok := config.OtherAttributes["fake-property"]; ok { return []VolumePlugin{ @@ -303,7 +314,11 @@ func (plugin *FakeVolumePlugin) GetAccessModes() []v1.PersistentVolumeAccessMode } func (plugin *FakeVolumePlugin) ConstructVolumeSpec(volumeName, mountPath string) (*Spec, error) { - return nil, nil + return &Spec{ + Volume: &v1.Volume{ + Name: volumeName, + }, + }, nil } func (plugin *FakeVolumePlugin) GetDeviceMountRefs(deviceMountPath string) ([]string, error) { @@ -481,7 +496,7 @@ func (fc *FakeProvisioner) Provision() (*v1.PersistentVolume, error) { ObjectMeta: metav1.ObjectMeta{ Name: fc.Options.PVName, Annotations: map[string]string{ - "kubernetes.io/createdby": "fakeplugin-provisioner", + volumehelper.VolumeDynamicallyCreatedByKey: "fakeplugin-provisioner", }, }, Spec: v1.PersistentVolumeSpec{ diff --git a/pkg/volume/util/BUILD b/pkg/volume/util/BUILD index 30bc0164826ef..c2ff2f56693bf 100644 --- a/pkg/volume/util/BUILD +++ b/pkg/volume/util/BUILD @@ -29,6 +29,7 @@ go_library( "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", ], ) @@ -38,10 +39,14 @@ go_test( srcs = [ "atomic_writer_test.go", "device_util_linux_test.go", + "util_test.go", ], library = ":go_default_library", tags = ["automanaged"], deps = [ + "//pkg/api/v1:go_default_library", + "//pkg/api/v1/helper:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", "//vendor/k8s.io/client-go/util/testing:go_default_library", ], diff --git a/pkg/volume/util/operationexecutor/BUILD b/pkg/volume/util/operationexecutor/BUILD index ec455f186bca2..9817a5f606e83 100644 --- a/pkg/volume/util/operationexecutor/BUILD +++ b/pkg/volume/util/operationexecutor/BUILD @@ -18,9 +18,11 @@ go_library( deps = [ "//pkg/api/v1:go_default_library", "//pkg/client/clientset_generated/clientset:go_default_library", + "//pkg/features:go_default_library", "//pkg/kubelet/events:go_default_library", "//pkg/util/mount:go_default_library", "//pkg/volume:go_default_library", + "//pkg/volume/util:go_default_library", "//pkg/volume/util/nestedpendingoperations:go_default_library", "//pkg/volume/util/types:go_default_library", "//pkg/volume/util/volumehelper:go_default_library", @@ -28,6 +30,7 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apiserver/pkg/util/feature:go_default_library", "//vendor/k8s.io/client-go/tools/record:go_default_library", ], ) diff --git a/pkg/volume/util/operationexecutor/operation_executor.go b/pkg/volume/util/operationexecutor/operation_executor.go index ff914bf19f681..0c1569095f504 100644 --- a/pkg/volume/util/operationexecutor/operation_executor.go +++ b/pkg/volume/util/operationexecutor/operation_executor.go @@ -89,7 +89,10 @@ type OperationExecutor interface { // * Mount the volume to the pod specific path. // * Update actual state of world to reflect volume is mounted to the pod // path. - MountVolume(waitForAttachTimeout time.Duration, volumeToMount VolumeToMount, actualStateOfWorld ActualStateOfWorldMounterUpdater) error + // The parameter "isRemount" is informational and used to adjust logging + // verbosity. An initial mount is more log-worthy than a remount, for + // example. + MountVolume(waitForAttachTimeout time.Duration, volumeToMount VolumeToMount, actualStateOfWorld ActualStateOfWorldMounterUpdater, isRemount bool) error // UnmountVolume unmounts the volume from the pod specified in // volumeToUnmount and updates the actual state of the world to reflect that. @@ -160,11 +163,11 @@ type ActualStateOfWorldAttacherUpdater interface { MarkVolumeAsDetached(volumeName v1.UniqueVolumeName, nodeName types.NodeName) // Marks desire to detach the specified volume (remove the volume from the node's - // volumesToReportedAsAttached list) + // volumesToReportAsAttached list) RemoveVolumeFromReportAsAttached(volumeName v1.UniqueVolumeName, nodeName types.NodeName) error // Unmarks the desire to detach for the specified volume (add the volume back to - // the node's volumesToReportedAsAttached list) + // the node's volumesToReportAsAttached list) AddVolumeToReportAsAttached(volumeName v1.UniqueVolumeName, nodeName types.NodeName) } @@ -652,9 +655,10 @@ func (oe *operationExecutor) VerifyVolumesAreAttachedPerNode( func (oe *operationExecutor) MountVolume( waitForAttachTimeout time.Duration, volumeToMount VolumeToMount, - actualStateOfWorld ActualStateOfWorldMounterUpdater) error { + actualStateOfWorld ActualStateOfWorldMounterUpdater, + isRemount bool) error { mountFunc, err := oe.operationGenerator.GenerateMountVolumeFunc( - waitForAttachTimeout, volumeToMount, actualStateOfWorld) + waitForAttachTimeout, volumeToMount, actualStateOfWorld, isRemount) if err != nil { return err } diff --git a/pkg/volume/util/operationexecutor/operation_executor_test.go b/pkg/volume/util/operationexecutor/operation_executor_test.go index 87400c8766f90..b312b29d451b7 100644 --- a/pkg/volume/util/operationexecutor/operation_executor_test.go +++ b/pkg/volume/util/operationexecutor/operation_executor_test.go @@ -60,7 +60,7 @@ func TestOperationExecutor_MountVolume_ConcurrentMountForNonAttachablePlugins(t PluginIsAttachable: false, // this field determines whether the plugin is attachable ReportedInUse: true, } - oe.MountVolume(0 /* waitForAttachTimeOut */, volumesToMount[i], nil /* actualStateOfWorldMounterUpdater */) + oe.MountVolume(0 /* waitForAttachTimeOut */, volumesToMount[i], nil /* actualStateOfWorldMounterUpdater */, false /* isRemount */) } // Assert @@ -86,7 +86,7 @@ func TestOperationExecutor_MountVolume_ConcurrentMountForAttachablePlugins(t *te PluginIsAttachable: true, // this field determines whether the plugin is attachable ReportedInUse: true, } - oe.MountVolume(0 /* waitForAttachTimeout */, volumesToMount[i], nil /* actualStateOfWorldMounterUpdater */) + oe.MountVolume(0 /* waitForAttachTimeout */, volumesToMount[i], nil /* actualStateOfWorldMounterUpdater */, false /* isRemount */) } // Assert @@ -239,7 +239,7 @@ func newFakeOperationGenerator(ch chan interface{}, quit chan interface{}) Opera } } -func (fopg *fakeOperationGenerator) GenerateMountVolumeFunc(waitForAttachTimeout time.Duration, volumeToMount VolumeToMount, actualStateOfWorldMounterUpdater ActualStateOfWorldMounterUpdater) (func() error, error) { +func (fopg *fakeOperationGenerator) GenerateMountVolumeFunc(waitForAttachTimeout time.Duration, volumeToMount VolumeToMount, actualStateOfWorldMounterUpdater ActualStateOfWorldMounterUpdater, isRemount bool) (func() error, error) { return func() error { startOperationAndBlock(fopg.ch, fopg.quit) return nil diff --git a/pkg/volume/util/operationexecutor/operation_generator.go b/pkg/volume/util/operationexecutor/operation_generator.go index f6ced83200546..52629afd4c036 100644 --- a/pkg/volume/util/operationexecutor/operation_generator.go +++ b/pkg/volume/util/operationexecutor/operation_generator.go @@ -24,12 +24,15 @@ import ( "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/types" + utilfeature "k8s.io/apiserver/pkg/util/feature" "k8s.io/client-go/tools/record" "k8s.io/kubernetes/pkg/api/v1" "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" + "k8s.io/kubernetes/pkg/features" kevents "k8s.io/kubernetes/pkg/kubelet/events" "k8s.io/kubernetes/pkg/util/mount" "k8s.io/kubernetes/pkg/volume" + "k8s.io/kubernetes/pkg/volume/util" "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) @@ -70,7 +73,7 @@ func NewOperationGenerator(kubeClient clientset.Interface, // OperationGenerator interface that extracts out the functions from operation_executor to make it dependency injectable type OperationGenerator interface { // Generates the MountVolume function needed to perform the mount of a volume plugin - GenerateMountVolumeFunc(waitForAttachTimeout time.Duration, volumeToMount VolumeToMount, actualStateOfWorldMounterUpdater ActualStateOfWorldMounterUpdater) (func() error, error) + GenerateMountVolumeFunc(waitForAttachTimeout time.Duration, volumeToMount VolumeToMount, actualStateOfWorldMounterUpdater ActualStateOfWorldMounterUpdater, isRemount bool) (func() error, error) // Generates the UnmountVolume function needed to perform the unmount of a volume plugin GenerateUnmountVolumeFunc(volumeToUnmount MountedVolume, actualStateOfWorld ActualStateOfWorldMounterUpdater) (func() error, error) @@ -354,7 +357,8 @@ func (og *operationGenerator) GenerateDetachVolumeFunc( func (og *operationGenerator) GenerateMountVolumeFunc( waitForAttachTimeout time.Duration, volumeToMount VolumeToMount, - actualStateOfWorld ActualStateOfWorldMounterUpdater) (func() error, error) { + actualStateOfWorld ActualStateOfWorldMounterUpdater, + isRemount bool) (func() error, error) { // Get mounter plugin volumePlugin, err := og.volumePluginMgr.FindPluginBySpec(volumeToMount.VolumeSpec) @@ -362,6 +366,11 @@ func (og *operationGenerator) GenerateMountVolumeFunc( return nil, volumeToMount.GenerateErrorDetailed("MountVolume.FindPluginBySpec failed", err) } + affinityErr := checkNodeAffinity(og, volumeToMount, volumePlugin) + if affinityErr != nil { + return nil, affinityErr + } + volumeMounter, newMounterErr := volumePlugin.NewMounter( volumeToMount.VolumeSpec, volumeToMount.Pod, @@ -456,7 +465,11 @@ func (og *operationGenerator) GenerateMountVolumeFunc( return detailedErr } - glog.Infof(volumeToMount.GenerateMsgDetailed("MountVolume.SetUp succeeded", "")) + verbosity := glog.Level(1) + if isRemount { + verbosity = glog.Level(7) + } + glog.V(verbosity).Infof(volumeToMount.GenerateMsgDetailed("MountVolume.SetUp succeeded", "")) // Update actual state of world markVolMountedErr := actualStateOfWorld.MarkVolumeAsMounted( @@ -708,3 +721,27 @@ func checkMountOptionSupport(og *operationGenerator, volumeToMount VolumeToMount } return nil } + +// checkNodeAffinity looks at the PV node affinity, and checks if the node has the same corresponding labels +// This ensures that we don't mount a volume that doesn't belong to this node +func checkNodeAffinity(og *operationGenerator, volumeToMount VolumeToMount, plugin volume.VolumePlugin) error { + if !utilfeature.DefaultFeatureGate.Enabled(features.PersistentLocalVolumes) { + return nil + } + + pv := volumeToMount.VolumeSpec.PersistentVolume + if pv != nil { + nodeLabels, err := og.volumePluginMgr.Host.GetNodeLabels() + if err != nil { + return volumeToMount.GenerateErrorDetailed("Error getting node labels", err) + } + + err = util.CheckNodeAffinity(pv, nodeLabels) + if err != nil { + eventErr, detailedErr := volumeToMount.GenerateError("Storage node affinity check failed", err) + og.recorder.Eventf(volumeToMount.Pod, v1.EventTypeWarning, kevents.FailedMountVolume, eventErr.Error()) + return detailedErr + } + } + return nil +} diff --git a/pkg/volume/util/util.go b/pkg/volume/util/util.go index 97561e7e6588a..a9ab2845a70e5 100644 --- a/pkg/volume/util/util.go +++ b/pkg/volume/util/util.go @@ -23,6 +23,7 @@ import ( "github.com/golang/glog" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/labels" "k8s.io/kubernetes/pkg/api/v1" v1helper "k8s.io/kubernetes/pkg/api/v1/helper" storage "k8s.io/kubernetes/pkg/apis/storage/v1" @@ -164,3 +165,30 @@ func GetClassForVolume(kubeClient clientset.Interface, pv *v1.PersistentVolume) } return class, nil } + +// CheckNodeAffinity looks at the PV node affinity, and checks if the node has the same corresponding labels +// This ensures that we don't mount a volume that doesn't belong to this node +func CheckNodeAffinity(pv *v1.PersistentVolume, nodeLabels map[string]string) error { + affinity, err := v1helper.GetStorageNodeAffinityFromAnnotation(pv.Annotations) + if err != nil { + return fmt.Errorf("Error getting storage node affinity: %v", err) + } + if affinity == nil { + return nil + } + + if affinity.RequiredDuringSchedulingIgnoredDuringExecution != nil { + terms := affinity.RequiredDuringSchedulingIgnoredDuringExecution.NodeSelectorTerms + glog.V(10).Infof("Match for RequiredDuringSchedulingIgnoredDuringExecution node selector terms %+v", terms) + for _, term := range terms { + selector, err := v1helper.NodeSelectorRequirementsAsSelector(term.MatchExpressions) + if err != nil { + return fmt.Errorf("Failed to parse MatchExpressions: %v", err) + } + if !selector.Matches(labels.Set(nodeLabels)) { + return fmt.Errorf("NodeSelectorTerm %+v does not match node labels", term.MatchExpressions) + } + } + } + return nil +} diff --git a/pkg/volume/util/util_test.go b/pkg/volume/util/util_test.go new file mode 100644 index 0000000000000..f491d45a40404 --- /dev/null +++ b/pkg/volume/util/util_test.go @@ -0,0 +1,142 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package util + +import ( + "testing" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/pkg/api/v1/helper" +) + +var nodeLabels map[string]string = map[string]string{ + "test-key1": "test-value1", + "test-key2": "test-value2", +} + +func TestCheckNodeAffinity(t *testing.T) { + type affinityTest struct { + name string + expectSuccess bool + pv *v1.PersistentVolume + } + + cases := []affinityTest{ + { + name: "valid-no-constraints", + expectSuccess: true, + pv: testVolumeWithNodeAffinity(t, &v1.NodeAffinity{}), + }, + { + name: "valid-constraints", + expectSuccess: true, + pv: testVolumeWithNodeAffinity(t, &v1.NodeAffinity{ + RequiredDuringSchedulingIgnoredDuringExecution: &v1.NodeSelector{ + NodeSelectorTerms: []v1.NodeSelectorTerm{ + { + MatchExpressions: []v1.NodeSelectorRequirement{ + { + Key: "test-key1", + Operator: v1.NodeSelectorOpIn, + Values: []string{"test-value1", "test-value3"}, + }, + { + Key: "test-key2", + Operator: v1.NodeSelectorOpIn, + Values: []string{"test-value0", "test-value2"}, + }, + }, + }, + }, + }, + }), + }, + { + name: "invalid-key", + expectSuccess: false, + pv: testVolumeWithNodeAffinity(t, &v1.NodeAffinity{ + RequiredDuringSchedulingIgnoredDuringExecution: &v1.NodeSelector{ + NodeSelectorTerms: []v1.NodeSelectorTerm{ + { + MatchExpressions: []v1.NodeSelectorRequirement{ + { + Key: "test-key1", + Operator: v1.NodeSelectorOpIn, + Values: []string{"test-value1", "test-value3"}, + }, + { + Key: "test-key3", + Operator: v1.NodeSelectorOpIn, + Values: []string{"test-value0", "test-value2"}, + }, + }, + }, + }, + }, + }), + }, + { + name: "invalid-values", + expectSuccess: false, + pv: testVolumeWithNodeAffinity(t, &v1.NodeAffinity{ + RequiredDuringSchedulingIgnoredDuringExecution: &v1.NodeSelector{ + NodeSelectorTerms: []v1.NodeSelectorTerm{ + { + MatchExpressions: []v1.NodeSelectorRequirement{ + { + Key: "test-key1", + Operator: v1.NodeSelectorOpIn, + Values: []string{"test-value3", "test-value4"}, + }, + { + Key: "test-key2", + Operator: v1.NodeSelectorOpIn, + Values: []string{"test-value0", "test-value2"}, + }, + }, + }, + }, + }, + }), + }, + } + + for _, c := range cases { + err := CheckNodeAffinity(c.pv, nodeLabels) + + if err != nil && c.expectSuccess { + t.Errorf("CheckTopology %v returned error: %v", c.name, err) + } + if err == nil && !c.expectSuccess { + t.Errorf("CheckTopology %v returned success, expected error", c.name) + } + } +} + +func testVolumeWithNodeAffinity(t *testing.T, affinity *v1.NodeAffinity) *v1.PersistentVolume { + objMeta := metav1.ObjectMeta{Name: "test-constraints"} + objMeta.Annotations = map[string]string{} + err := helper.StorageNodeAffinityToAlphaAnnotation(objMeta.Annotations, affinity) + if err != nil { + t.Fatalf("Failed to get node affinity annotation: %v", err) + } + + return &v1.PersistentVolume{ + ObjectMeta: objMeta, + } +} diff --git a/pkg/volume/util/volumehelper/volumehelper.go b/pkg/volume/util/volumehelper/volumehelper.go index f667af25f50ef..afb5bd5b57fda 100644 --- a/pkg/volume/util/volumehelper/volumehelper.go +++ b/pkg/volume/util/volumehelper/volumehelper.go @@ -40,6 +40,10 @@ const ( // VolumeGidAnnotationKey is the of the annotation on the PersistentVolume // object that specifies a supplemental GID. VolumeGidAnnotationKey = "pv.beta.kubernetes.io/gid" + + // VolumeDynamicallyCreatedByKey is the key of the annotation on PersistentVolume + // object created dynamically + VolumeDynamicallyCreatedByKey = "kubernetes.io/createdby" ) // GetUniquePodName returns a unique identifier to reference a pod by diff --git a/pkg/volume/vsphere_volume/BUILD b/pkg/volume/vsphere_volume/BUILD index 681fbc054d73f..aeb826e0c62a2 100644 --- a/pkg/volume/vsphere_volume/BUILD +++ b/pkg/volume/vsphere_volume/BUILD @@ -26,6 +26,7 @@ go_library( "//pkg/util/strings:go_default_library", "//pkg/volume:go_default_library", "//pkg/volume/util:go_default_library", + "//pkg/volume/util/volumehelper:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", diff --git a/pkg/volume/vsphere_volume/vsphere_volume.go b/pkg/volume/vsphere_volume/vsphere_volume.go index e466fc373e198..ce513832cd215 100644 --- a/pkg/volume/vsphere_volume/vsphere_volume.go +++ b/pkg/volume/vsphere_volume/vsphere_volume.go @@ -32,6 +32,7 @@ import ( utilstrings "k8s.io/kubernetes/pkg/util/strings" "k8s.io/kubernetes/pkg/volume" "k8s.io/kubernetes/pkg/volume/util" + "k8s.io/kubernetes/pkg/volume/util/volumehelper" ) // This is the primary entrypoint for volume plugins. @@ -358,7 +359,7 @@ func (v *vsphereVolumeProvisioner) Provision() (*v1.PersistentVolume, error) { Name: v.options.PVName, Labels: map[string]string{}, Annotations: map[string]string{ - "kubernetes.io/createdby": "vsphere-volume-dynamic-provisioner", + volumehelper.VolumeDynamicallyCreatedByKey: "vsphere-volume-dynamic-provisioner", }, }, Spec: v1.PersistentVolumeSpec{ diff --git a/plugin/BUILD b/plugin/BUILD index 9f7368ddf2b53..2af6b49bbcece 100644 --- a/plugin/BUILD +++ b/plugin/BUILD @@ -26,7 +26,6 @@ filegroup( "//plugin/pkg/admission/limitranger:all-srcs", "//plugin/pkg/admission/namespace/autoprovision:all-srcs", "//plugin/pkg/admission/namespace/exists:all-srcs", - "//plugin/pkg/admission/namespace/lifecycle:all-srcs", "//plugin/pkg/admission/noderestriction:all-srcs", "//plugin/pkg/admission/persistentvolume/label:all-srcs", "//plugin/pkg/admission/podnodeselector:all-srcs", diff --git a/plugin/cmd/kube-scheduler/OWNERS b/plugin/cmd/kube-scheduler/OWNERS index 2de3186f01b39..4250993a96a44 100644 --- a/plugin/cmd/kube-scheduler/OWNERS +++ b/plugin/cmd/kube-scheduler/OWNERS @@ -1,10 +1,11 @@ approvers: - davidopp - timothysc +- k82cn reviewers: - davidopp - bsalamat - timothysc - wojtek-t -- k82cn +- k82cn - jayunit100 diff --git a/plugin/cmd/kube-scheduler/app/options/options.go b/plugin/cmd/kube-scheduler/app/options/options.go index 6db57db802b89..1fe236fbc9571 100644 --- a/plugin/cmd/kube-scheduler/app/options/options.go +++ b/plugin/cmd/kube-scheduler/app/options/options.go @@ -87,6 +87,7 @@ func (s *SchedulerServer) AddFlags(fs *pflag.FlagSet) { fs.IntVar(&s.HardPodAffinitySymmetricWeight, "hard-pod-affinity-symmetric-weight", api.DefaultHardPodAffinitySymmetricWeight, "RequiredDuringScheduling affinity is not symmetric, but there is an implicit PreferredDuringScheduling affinity rule corresponding "+ "to every RequiredDuringScheduling affinity rule. --hard-pod-affinity-symmetric-weight represents the weight of implicit PreferredDuringScheduling affinity rule.") + fs.MarkDeprecated("hard-pod-affinity-symmetric-weight", "This option was moved to the policy configuration file") fs.StringVar(&s.FailureDomains, "failure-domains", api.DefaultFailureDomains, "Indicate the \"all topologies\" set for an empty topologyKey when it's used for PreferredDuringScheduling pod anti-affinity.") fs.MarkDeprecated("failure-domains", "Doesn't have any effect. Will be removed in future version.") leaderelection.BindFlags(&s.LeaderElection, fs) diff --git a/plugin/pkg/admission/noderestriction/admission.go b/plugin/pkg/admission/noderestriction/admission.go index 13191b59b109e..9615a871c49a8 100644 --- a/plugin/pkg/admission/noderestriction/admission.go +++ b/plugin/pkg/admission/noderestriction/admission.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package node +package noderestriction import ( "fmt" @@ -37,24 +37,22 @@ const ( // Register registers a plugin func Register(plugins *admission.Plugins) { plugins.Register(PluginName, func(config io.Reader) (admission.Interface, error) { - return NewPlugin(nodeidentifier.NewDefaultNodeIdentifier(), false), nil + return NewPlugin(nodeidentifier.NewDefaultNodeIdentifier()), nil }) } // NewPlugin creates a new NodeRestriction admission plugin. // This plugin identifies requests from nodes -func NewPlugin(nodeIdentifier nodeidentifier.NodeIdentifier, strict bool) *nodePlugin { +func NewPlugin(nodeIdentifier nodeidentifier.NodeIdentifier) *nodePlugin { return &nodePlugin{ Handler: admission.NewHandler(admission.Create, admission.Update, admission.Delete), nodeIdentifier: nodeIdentifier, - strict: strict, } } // nodePlugin holds state for and implements the admission plugin. type nodePlugin struct { *admission.Handler - strict bool nodeIdentifier nodeidentifier.NodeIdentifier podsGetter coreinternalversion.PodsGetter } @@ -92,12 +90,8 @@ func (c *nodePlugin) Admit(a admission.Attributes) error { } if len(nodeName) == 0 { - if c.strict { - // In strict mode, disallow requests from nodes we cannot match to a particular node - return admission.NewForbidden(a, fmt.Errorf("could not determine node identity from user")) - } - // Our job is just to restrict identifiable nodes - return nil + // disallow requests we cannot match to a particular node + return admission.NewForbidden(a, fmt.Errorf("could not determine node from user %s", a.GetUserInfo().GetName())) } switch a.GetResource().GroupResource() { diff --git a/plugin/pkg/admission/noderestriction/admission_test.go b/plugin/pkg/admission/noderestriction/admission_test.go index 71cea49e87074..9dbc8388703dc 100644 --- a/plugin/pkg/admission/noderestriction/admission_test.go +++ b/plugin/pkg/admission/noderestriction/admission_test.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package node +package noderestriction import ( "strings" @@ -82,7 +82,6 @@ func Test_nodePlugin_Admit(t *testing.T) { tests := []struct { name string - strict bool podsGetter coreinternalversion.PodsGetter attributes admission.Attributes err string @@ -473,7 +472,7 @@ func Test_nodePlugin_Admit(t *testing.T) { } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { - c := NewPlugin(nodeidentifier.NewDefaultNodeIdentifier(), tt.strict) + c := NewPlugin(nodeidentifier.NewDefaultNodeIdentifier()) c.podsGetter = tt.podsGetter err := c.Admit(tt.attributes) if (err == nil) != (len(tt.err) == 0) { diff --git a/plugin/pkg/auth/authorizer/BUILD b/plugin/pkg/auth/authorizer/BUILD index 7f64b63a3148b..48e484004c3a8 100644 --- a/plugin/pkg/auth/authorizer/BUILD +++ b/plugin/pkg/auth/authorizer/BUILD @@ -24,6 +24,7 @@ filegroup( name = "all-srcs", srcs = [ ":package-srcs", + "//plugin/pkg/auth/authorizer/node:all-srcs", "//plugin/pkg/auth/authorizer/rbac:all-srcs", ], tags = ["automanaged"], diff --git a/plugin/pkg/auth/authorizer/node/BUILD b/plugin/pkg/auth/authorizer/node/BUILD new file mode 100644 index 0000000000000..8569eb1f87ba7 --- /dev/null +++ b/plugin/pkg/auth/authorizer/node/BUILD @@ -0,0 +1,63 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["node_authorizer_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/auth/nodeidentifier:go_default_library", + "//plugin/pkg/auth/authorizer/rbac/bootstrappolicy:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apiserver/pkg/authentication/user:go_default_library", + "//vendor/k8s.io/apiserver/pkg/authorization/authorizer:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "graph.go", + "graph_populator.go", + "node_authorizer.go", + ], + tags = ["automanaged"], + deps = [ + "//pkg/api:go_default_library", + "//pkg/api/persistentvolume:go_default_library", + "//pkg/api/pod:go_default_library", + "//pkg/apis/rbac:go_default_library", + "//pkg/auth/nodeidentifier:go_default_library", + "//pkg/client/informers/informers_generated/internalversion/core/internalversion:go_default_library", + "//plugin/pkg/auth/authorizer/rbac:go_default_library", + "//third_party/forked/gonum/graph:go_default_library", + "//third_party/forked/gonum/graph/simple:go_default_library", + "//third_party/forked/gonum/graph/traverse:go_default_library", + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apiserver/pkg/authorization/authorizer:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/plugin/pkg/auth/authorizer/node/OWNERS b/plugin/pkg/auth/authorizer/node/OWNERS new file mode 100644 index 0000000000000..a62844dc28478 --- /dev/null +++ b/plugin/pkg/auth/authorizer/node/OWNERS @@ -0,0 +1,9 @@ +approvers: +- timstclair +- liggitt +- deads2k +reviewers: +- timstclair +- liggitt +- deads2k +- ericchiang diff --git a/plugin/pkg/auth/authorizer/node/graph.go b/plugin/pkg/auth/authorizer/node/graph.go new file mode 100644 index 0000000000000..e72091f743309 --- /dev/null +++ b/plugin/pkg/auth/authorizer/node/graph.go @@ -0,0 +1,265 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package node + +import ( + "sync" + + "k8s.io/kubernetes/pkg/api" + pvutil "k8s.io/kubernetes/pkg/api/persistentvolume" + podutil "k8s.io/kubernetes/pkg/api/pod" + "k8s.io/kubernetes/third_party/forked/gonum/graph" + "k8s.io/kubernetes/third_party/forked/gonum/graph/simple" +) + +// namedVertex implements graph.Node and remembers the type, namespace, and name of its related API object +type namedVertex struct { + name string + namespace string + id int + vertexType vertexType +} + +func newNamedVertex(vertexType vertexType, namespace, name string, id int) *namedVertex { + return &namedVertex{ + vertexType: vertexType, + name: name, + namespace: namespace, + id: id, + } +} +func (n *namedVertex) ID() int { + return n.id +} +func (n *namedVertex) String() string { + if len(n.namespace) == 0 { + return vertexTypes[n.vertexType] + ":" + n.name + } + return vertexTypes[n.vertexType] + ":" + n.namespace + "/" + n.name +} + +// destinationEdge is a graph edge that includes a denormalized reference to the final destination vertex. +// This should only be used when there is a single leaf vertex reachable from T. +type destinationEdge struct { + F graph.Node + T graph.Node + Destination graph.Node +} + +func newDestinationEdge(from, to, destination graph.Node) graph.Edge { + return &destinationEdge{F: from, T: to, Destination: destination} +} +func (e *destinationEdge) From() graph.Node { return e.F } +func (e *destinationEdge) To() graph.Node { return e.T } +func (e *destinationEdge) Weight() float64 { return 0 } +func (e *destinationEdge) DestinationID() int { return e.Destination.ID() } + +// Graph holds graph vertices and a way to look up a vertex for a particular API type/namespace/name. +// All edges point toward the vertices representing Kubernetes nodes: +// +// node <- pod +// pod <- secret,configmap,pvc +// pvc <- pv +// pv <- secret +type Graph struct { + lock sync.RWMutex + graph *simple.DirectedAcyclicGraph + // vertices is a map of type -> namespace -> name -> vertex + vertices map[vertexType]namespaceVertexMapping +} + +// namespaceVertexMapping is a map of namespace -> name -> vertex +type namespaceVertexMapping map[string]nameVertexMapping + +// nameVertexMapping is a map of name -> vertex +type nameVertexMapping map[string]*namedVertex + +func NewGraph() *Graph { + return &Graph{ + vertices: map[vertexType]namespaceVertexMapping{}, + graph: simple.NewDirectedAcyclicGraph(0, 0), + } +} + +// vertexType indicates the type of the API object the vertex represents. +// represented as a byte to minimize space used in the vertices. +type vertexType byte + +const ( + configMapVertexType vertexType = iota + nodeVertexType + podVertexType + pvcVertexType + pvVertexType + secretVertexType +) + +var vertexTypes = map[vertexType]string{ + configMapVertexType: "configmap", + nodeVertexType: "node", + podVertexType: "pod", + pvcVertexType: "pvc", + pvVertexType: "pv", + secretVertexType: "secret", +} + +// must be called under a write lock +func (g *Graph) getOrCreateVertex_locked(vertexType vertexType, namespace, name string) *namedVertex { + if vertex, exists := g.getVertex_rlocked(vertexType, namespace, name); exists { + return vertex + } + return g.createVertex_locked(vertexType, namespace, name) +} + +// must be called under a read lock +func (g *Graph) getVertex_rlocked(vertexType vertexType, namespace, name string) (*namedVertex, bool) { + vertex, exists := g.vertices[vertexType][namespace][name] + return vertex, exists +} + +// must be called under a write lock +func (g *Graph) createVertex_locked(vertexType vertexType, namespace, name string) *namedVertex { + typedVertices, exists := g.vertices[vertexType] + if !exists { + typedVertices = namespaceVertexMapping{} + g.vertices[vertexType] = typedVertices + } + + namespacedVertices, exists := typedVertices[namespace] + if !exists { + namespacedVertices = map[string]*namedVertex{} + typedVertices[namespace] = namespacedVertices + } + + vertex := newNamedVertex(vertexType, namespace, name, g.graph.NewNodeID()) + namespacedVertices[name] = vertex + g.graph.AddNode(vertex) + + return vertex +} + +// must be called under write lock +func (g *Graph) deleteVertex_locked(vertexType vertexType, namespace, name string) { + vertex, exists := g.getVertex_rlocked(vertexType, namespace, name) + if !exists { + return + } + + // find existing neighbors with a single edge (meaning we are their only neighbor) + neighborsToRemove := []graph.Node{} + g.graph.VisitFrom(vertex, func(neighbor graph.Node) bool { + // this downstream neighbor has only one edge (which must be from us), so remove them as well + if g.graph.Degree(neighbor) == 1 { + neighborsToRemove = append(neighborsToRemove, neighbor) + } + return true + }) + g.graph.VisitTo(vertex, func(neighbor graph.Node) bool { + // this upstream neighbor has only one edge (which must be to us), so remove them as well + if g.graph.Degree(neighbor) == 1 { + neighborsToRemove = append(neighborsToRemove, neighbor) + } + return true + }) + + // remove the vertex + g.graph.RemoveNode(vertex) + delete(g.vertices[vertexType][namespace], name) + if len(g.vertices[vertexType][namespace]) == 0 { + delete(g.vertices[vertexType], namespace) + } + + // remove neighbors that are now edgeless + for _, neighbor := range neighborsToRemove { + g.graph.RemoveNode(neighbor) + n := neighbor.(*namedVertex) + delete(g.vertices[n.vertexType][n.namespace], n.name) + if len(g.vertices[n.vertexType][n.namespace]) == 0 { + delete(g.vertices[n.vertexType], n.namespace) + } + } +} + +// AddPod should only be called once spec.NodeName is populated. +// It sets up edges for the following relationships (which are immutable for a pod once bound to a node): +// +// pod -> node +// +// secret -> pod +// configmap -> pod +// pvc -> pod +func (g *Graph) AddPod(pod *api.Pod) { + g.lock.Lock() + defer g.lock.Unlock() + + g.deleteVertex_locked(podVertexType, pod.Namespace, pod.Name) + podVertex := g.getOrCreateVertex_locked(podVertexType, pod.Namespace, pod.Name) + nodeVertex := g.getOrCreateVertex_locked(nodeVertexType, "", pod.Spec.NodeName) + g.graph.SetEdge(newDestinationEdge(podVertex, nodeVertex, nodeVertex)) + + podutil.VisitPodSecretNames(pod, func(secret string) bool { + g.graph.SetEdge(newDestinationEdge(g.getOrCreateVertex_locked(secretVertexType, pod.Namespace, secret), podVertex, nodeVertex)) + return true + }) + + podutil.VisitPodConfigmapNames(pod, func(configmap string) bool { + g.graph.SetEdge(newDestinationEdge(g.getOrCreateVertex_locked(configMapVertexType, pod.Namespace, configmap), podVertex, nodeVertex)) + return true + }) + + for _, v := range pod.Spec.Volumes { + if v.PersistentVolumeClaim != nil { + g.graph.SetEdge(newDestinationEdge(g.getOrCreateVertex_locked(pvcVertexType, pod.Namespace, v.PersistentVolumeClaim.ClaimName), podVertex, nodeVertex)) + } + } +} +func (g *Graph) DeletePod(name, namespace string) { + g.lock.Lock() + defer g.lock.Unlock() + g.deleteVertex_locked(podVertexType, namespace, name) +} + +// AddPV sets up edges for the following relationships: +// +// secret -> pv +// +// pv -> pvc +func (g *Graph) AddPV(pv *api.PersistentVolume) { + g.lock.Lock() + defer g.lock.Unlock() + + // clear existing edges + g.deleteVertex_locked(pvVertexType, "", pv.Name) + + // if we have a pvc, establish new edges + if pv.Spec.ClaimRef != nil { + pvVertex := g.getOrCreateVertex_locked(pvVertexType, "", pv.Name) + + // since we don't know the other end of the pvc -> pod -> node chain (or it may not even exist yet), we can't decorate these edges with kubernetes node info + g.graph.SetEdge(simple.Edge{F: pvVertex, T: g.getOrCreateVertex_locked(pvcVertexType, pv.Spec.ClaimRef.Namespace, pv.Spec.ClaimRef.Name)}) + pvutil.VisitPVSecretNames(pv, func(secret string) bool { + // This grants access to the named secret in the same namespace as the bound PVC + g.graph.SetEdge(simple.Edge{F: g.getOrCreateVertex_locked(secretVertexType, pv.Spec.ClaimRef.Namespace, secret), T: pvVertex}) + return true + }) + } +} +func (g *Graph) DeletePV(name string) { + g.lock.Lock() + defer g.lock.Unlock() + g.deleteVertex_locked(pvVertexType, "", name) +} diff --git a/plugin/pkg/auth/authorizer/node/graph_populator.go b/plugin/pkg/auth/authorizer/node/graph_populator.go new file mode 100644 index 0000000000000..ecea060d6ecc9 --- /dev/null +++ b/plugin/pkg/auth/authorizer/node/graph_populator.go @@ -0,0 +1,108 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package node + +import ( + "github.com/golang/glog" + + "k8s.io/client-go/tools/cache" + "k8s.io/kubernetes/pkg/api" + coreinformers "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion/core/internalversion" +) + +type graphPopulator struct { + graph *Graph +} + +func AddGraphEventHandlers(graph *Graph, pods coreinformers.PodInformer, pvs coreinformers.PersistentVolumeInformer) { + g := &graphPopulator{ + graph: graph, + } + + pods.Informer().AddEventHandler(cache.ResourceEventHandlerFuncs{ + AddFunc: g.addPod, + UpdateFunc: g.updatePod, + DeleteFunc: g.deletePod, + }) + + pvs.Informer().AddEventHandler(cache.ResourceEventHandlerFuncs{ + AddFunc: g.addPV, + UpdateFunc: g.updatePV, + DeleteFunc: g.deletePV, + }) +} + +func (g *graphPopulator) addPod(obj interface{}) { + g.updatePod(nil, obj) +} + +func (g *graphPopulator) updatePod(oldObj, obj interface{}) { + pod := obj.(*api.Pod) + if len(pod.Spec.NodeName) == 0 { + // No node assigned + glog.V(5).Infof("updatePod %s/%s, no node", pod.Namespace, pod.Name) + return + } + if oldPod, ok := oldObj.(*api.Pod); ok && oldPod != nil { + if (pod.Spec.NodeName == oldPod.Spec.NodeName) && (pod.UID == oldPod.UID) { + // Node and uid are unchanged, all object references in the pod spec are immutable + glog.V(5).Infof("updatePod %s/%s, node unchanged", pod.Namespace, pod.Name) + return + } + } + glog.V(4).Infof("updatePod %s/%s for node %s", pod.Namespace, pod.Name, pod.Spec.NodeName) + g.graph.AddPod(pod) +} + +func (g *graphPopulator) deletePod(obj interface{}) { + if tombstone, ok := obj.(cache.DeletedFinalStateUnknown); ok { + obj = tombstone.Obj + } + pod, ok := obj.(*api.Pod) + if !ok { + glog.Infof("unexpected type %T", obj) + return + } + if len(pod.Spec.NodeName) == 0 { + glog.V(5).Infof("deletePod %s/%s, no node", pod.Namespace, pod.Name) + return + } + glog.V(4).Infof("deletePod %s/%s for node %s", pod.Namespace, pod.Name, pod.Spec.NodeName) + g.graph.DeletePod(pod.Name, pod.Namespace) +} + +func (g *graphPopulator) addPV(obj interface{}) { + g.updatePV(nil, obj) +} + +func (g *graphPopulator) updatePV(oldObj, obj interface{}) { + pv := obj.(*api.PersistentVolume) + // TODO: skip add if uid, pvc, and secrets are all identical between old and new + g.graph.AddPV(pv) +} + +func (g *graphPopulator) deletePV(obj interface{}) { + if tombstone, ok := obj.(cache.DeletedFinalStateUnknown); ok { + obj = tombstone.Obj + } + pv, ok := obj.(*api.PersistentVolume) + if !ok { + glog.Infof("unexpected type %T", obj) + return + } + g.graph.DeletePV(pv.Name) +} diff --git a/plugin/pkg/auth/authorizer/node/node_authorizer.go b/plugin/pkg/auth/authorizer/node/node_authorizer.go new file mode 100644 index 0000000000000..5e5d7362c656d --- /dev/null +++ b/plugin/pkg/auth/authorizer/node/node_authorizer.go @@ -0,0 +1,164 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package node + +import ( + "fmt" + + "github.com/golang/glog" + + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apiserver/pkg/authorization/authorizer" + "k8s.io/kubernetes/pkg/api" + rbacapi "k8s.io/kubernetes/pkg/apis/rbac" + "k8s.io/kubernetes/pkg/auth/nodeidentifier" + "k8s.io/kubernetes/plugin/pkg/auth/authorizer/rbac" + "k8s.io/kubernetes/third_party/forked/gonum/graph" + "k8s.io/kubernetes/third_party/forked/gonum/graph/traverse" +) + +// NodeAuthorizer authorizes requests from kubelets, with the following logic: +// 1. If a request is not from a node (IdentifyNode() returns isNode=false), reject +// 2. If a specific node cannot be identified (IdentifyNode() returns nodeName=""), reject +// 3. If a request is for a secret, configmap, persistent volume or persistent volume claim, reject unless the verb is get, and the requested object is related to the requesting node: +// node <- pod +// node <- pod <- secret +// node <- pod <- configmap +// node <- pod <- pvc +// node <- pod <- pvc <- pv +// node <- pod <- pvc <- pv <- secret +// 4. For other resources, authorize all nodes uniformly using statically defined rules +type NodeAuthorizer struct { + graph *Graph + identifier nodeidentifier.NodeIdentifier + nodeRules []rbacapi.PolicyRule +} + +// New returns a new node authorizer +func NewAuthorizer(graph *Graph, identifier nodeidentifier.NodeIdentifier, rules []rbacapi.PolicyRule) authorizer.Authorizer { + return &NodeAuthorizer{ + graph: graph, + identifier: identifier, + nodeRules: rules, + } +} + +var ( + configMapResource = api.Resource("configmaps") + secretResource = api.Resource("secrets") + pvcResource = api.Resource("persistentvolumeclaims") + pvResource = api.Resource("persistentvolumes") +) + +func (r *NodeAuthorizer) Authorize(attrs authorizer.Attributes) (bool, string, error) { + nodeName, isNode := r.identifier.NodeIdentity(attrs.GetUser()) + if !isNode { + // reject requests from non-nodes + return false, "", nil + } + if len(nodeName) == 0 { + // reject requests from unidentifiable nodes + glog.V(2).Infof("NODE DENY: unknown node for user %q", attrs.GetUser().GetName()) + return false, fmt.Sprintf("unknown node for user %q", attrs.GetUser().GetName()), nil + } + + // subdivide access to specific resources + if attrs.IsResourceRequest() { + requestResource := schema.GroupResource{Group: attrs.GetAPIGroup(), Resource: attrs.GetResource()} + switch requestResource { + case secretResource: + return r.authorizeGet(nodeName, secretVertexType, attrs) + case configMapResource: + return r.authorizeGet(nodeName, configMapVertexType, attrs) + case pvcResource: + return r.authorizeGet(nodeName, pvcVertexType, attrs) + case pvResource: + return r.authorizeGet(nodeName, pvVertexType, attrs) + } + } + + // Access to other resources is not subdivided, so just evaluate against the statically defined node rules + return rbac.RulesAllow(attrs, r.nodeRules...), "", nil +} + +// authorizeGet authorizes "get" requests to objects of the specified type if they are related to the specified node +func (r *NodeAuthorizer) authorizeGet(nodeName string, startingType vertexType, attrs authorizer.Attributes) (bool, string, error) { + if attrs.GetVerb() != "get" || len(attrs.GetName()) == 0 { + glog.V(2).Infof("NODE DENY: %s %#v", nodeName, attrs) + return false, "can only get individual resources of this type", nil + } + + if len(attrs.GetSubresource()) > 0 { + glog.V(2).Infof("NODE DENY: %s %#v", nodeName, attrs) + return false, "cannot get subresource", nil + } + + ok, err := r.hasPathFrom(nodeName, startingType, attrs.GetNamespace(), attrs.GetName()) + if err != nil { + glog.V(2).Infof("NODE DENY: %v", err) + return false, "no path found to object", nil + } + if !ok { + glog.V(2).Infof("NODE DENY: %s %#v", nodeName, attrs) + return false, "no path found to object", nil + } + return ok, "", nil +} + +// hasPathFrom returns true if there is a directed path from the specified type/namespace/name to the specified Node +func (r *NodeAuthorizer) hasPathFrom(nodeName string, startingType vertexType, startingNamespace, startingName string) (bool, error) { + r.graph.lock.RLock() + defer r.graph.lock.RUnlock() + + nodeVertex, exists := r.graph.getVertex_rlocked(nodeVertexType, "", nodeName) + if !exists { + return false, fmt.Errorf("unknown node %s cannot get %s %s/%s", nodeName, vertexTypes[startingType], startingNamespace, startingName) + } + + startingVertex, exists := r.graph.getVertex_rlocked(startingType, startingNamespace, startingName) + if !exists { + return false, fmt.Errorf("node %s cannot get unknown %s %s/%s", nodeName, vertexTypes[startingType], startingNamespace, startingName) + } + + found := false + traversal := &traverse.VisitingDepthFirst{ + EdgeFilter: func(edge graph.Edge) bool { + if destinationEdge, ok := edge.(*destinationEdge); ok { + if destinationEdge.DestinationID() != nodeVertex.ID() { + // Don't follow edges leading to other nodes + return false + } + // We found an edge leading to the node we want + found = true + } + // Visit this edge + return true + }, + } + traversal.Walk(r.graph.graph, startingVertex, func(n graph.Node) bool { + if n.ID() == nodeVertex.ID() { + // We found the node we want + found = true + } + // Stop visiting if we've found the node we want + return found + }) + if !found { + return false, fmt.Errorf("node %s cannot get %s %s/%s, no path was found", nodeName, vertexTypes[startingType], startingNamespace, startingName) + } + return true, nil +} diff --git a/plugin/pkg/auth/authorizer/node/node_authorizer_test.go b/plugin/pkg/auth/authorizer/node/node_authorizer_test.go new file mode 100644 index 0000000000000..39f10b62ee533 --- /dev/null +++ b/plugin/pkg/auth/authorizer/node/node_authorizer_test.go @@ -0,0 +1,437 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package node + +import ( + "fmt" + "runtime" + "runtime/pprof" + "testing" + + "os" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apiserver/pkg/authentication/user" + "k8s.io/apiserver/pkg/authorization/authorizer" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/auth/nodeidentifier" + "k8s.io/kubernetes/plugin/pkg/auth/authorizer/rbac/bootstrappolicy" +) + +func TestAuthorizer(t *testing.T) { + g := NewGraph() + + opts := sampleDataOpts{ + nodes: 2, + namespaces: 2, + podsPerNode: 2, + sharedConfigMapsPerPod: 0, + uniqueConfigMapsPerPod: 1, + sharedSecretsPerPod: 1, + uniqueSecretsPerPod: 1, + sharedPVCsPerPod: 0, + uniquePVCsPerPod: 1, + } + pods, pvs := generate(opts) + populate(g, pods, pvs) + + identifier := nodeidentifier.NewDefaultNodeIdentifier() + authz := NewAuthorizer(g, identifier, bootstrappolicy.NodeRules()) + + node0 := &user.DefaultInfo{Name: "system:node:node0", Groups: []string{"system:nodes"}} + + tests := []struct { + name string + attrs authorizer.AttributesRecord + expect bool + }{ + { + name: "allowed configmap", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "configmaps", Name: "configmap0-pod0-node0", Namespace: "ns0"}, + expect: true, + }, + { + name: "allowed secret via pod", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "secrets", Name: "secret0-pod0-node0", Namespace: "ns0"}, + expect: true, + }, + { + name: "allowed shared secret via pod", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "secrets", Name: "secret0-shared", Namespace: "ns0"}, + expect: true, + }, + { + name: "allowed shared secret via pvc", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "secrets", Name: "secret-pv0-pod0-node0-ns0", Namespace: "ns0"}, + expect: true, + }, + { + name: "allowed pvc", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "persistentvolumeclaims", Name: "pvc0-pod0-node0", Namespace: "ns0"}, + expect: true, + }, + { + name: "allowed pv", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "persistentvolumes", Name: "pv0-pod0-node0-ns0", Namespace: ""}, + expect: true, + }, + + { + name: "disallowed configmap", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "configmaps", Name: "configmap0-pod0-node1", Namespace: "ns0"}, + expect: false, + }, + { + name: "disallowed secret via pod", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "secrets", Name: "secret0-pod0-node1", Namespace: "ns0"}, + expect: false, + }, + { + name: "disallowed shared secret via pvc", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "secrets", Name: "secret-pv0-pod0-node1-ns0", Namespace: "ns0"}, + expect: false, + }, + { + name: "disallowed pvc", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "persistentvolumeclaims", Name: "pvc0-pod0-node1", Namespace: "ns0"}, + expect: false, + }, + { + name: "disallowed pv", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "persistentvolumes", Name: "pv0-pod0-node1-ns0", Namespace: ""}, + expect: false, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + ok, _, _ := authz.Authorize(tc.attrs) + if ok != tc.expect { + t.Errorf("expected %v, got %v", tc.expect, ok) + } + }) + } +} + +func TestAuthorizerSharedResources(t *testing.T) { + g := NewGraph() + identifier := nodeidentifier.NewDefaultNodeIdentifier() + authz := NewAuthorizer(g, identifier, bootstrappolicy.NodeRules()) + + node1 := &user.DefaultInfo{Name: "system:node:node1", Groups: []string{"system:nodes"}} + node2 := &user.DefaultInfo{Name: "system:node:node2", Groups: []string{"system:nodes"}} + node3 := &user.DefaultInfo{Name: "system:node:node3", Groups: []string{"system:nodes"}} + + g.AddPod(&api.Pod{ + ObjectMeta: metav1.ObjectMeta{Name: "pod1-node1", Namespace: "ns1"}, + Spec: api.PodSpec{ + NodeName: "node1", + Volumes: []api.Volume{ + {VolumeSource: api.VolumeSource{Secret: &api.SecretVolumeSource{SecretName: "node1-only"}}}, + {VolumeSource: api.VolumeSource{Secret: &api.SecretVolumeSource{SecretName: "node1-node2-only"}}}, + {VolumeSource: api.VolumeSource{Secret: &api.SecretVolumeSource{SecretName: "shared-all"}}}, + }, + }, + }) + g.AddPod(&api.Pod{ + ObjectMeta: metav1.ObjectMeta{Name: "pod2-node2", Namespace: "ns1"}, + Spec: api.PodSpec{ + NodeName: "node2", + Volumes: []api.Volume{ + {VolumeSource: api.VolumeSource{Secret: &api.SecretVolumeSource{SecretName: "node1-node2-only"}}}, + {VolumeSource: api.VolumeSource{Secret: &api.SecretVolumeSource{SecretName: "shared-all"}}}, + }, + }, + }) + g.AddPod(&api.Pod{ + ObjectMeta: metav1.ObjectMeta{Name: "pod3-node3", Namespace: "ns1"}, + Spec: api.PodSpec{ + NodeName: "node3", + Volumes: []api.Volume{ + {VolumeSource: api.VolumeSource{Secret: &api.SecretVolumeSource{SecretName: "shared-all"}}}, + }, + }, + }) + + testcases := []struct { + User user.Info + Secret string + ExpectAllowed bool + }{ + {User: node1, ExpectAllowed: true, Secret: "node1-only"}, + {User: node1, ExpectAllowed: true, Secret: "node1-node2-only"}, + {User: node1, ExpectAllowed: true, Secret: "shared-all"}, + + {User: node2, ExpectAllowed: false, Secret: "node1-only"}, + {User: node2, ExpectAllowed: true, Secret: "node1-node2-only"}, + {User: node2, ExpectAllowed: true, Secret: "shared-all"}, + + {User: node3, ExpectAllowed: false, Secret: "node1-only"}, + {User: node3, ExpectAllowed: false, Secret: "node1-node2-only"}, + {User: node3, ExpectAllowed: true, Secret: "shared-all"}, + } + + for i, tc := range testcases { + ok, _, err := authz.Authorize(authorizer.AttributesRecord{User: tc.User, ResourceRequest: true, Verb: "get", Resource: "secrets", Namespace: "ns1", Name: tc.Secret}) + if err != nil { + t.Errorf("%d: unexpected error: %v", i, err) + continue + } + if ok != tc.ExpectAllowed { + t.Errorf("%d: expected %v, got %v", i, tc.ExpectAllowed, ok) + } + } +} + +type sampleDataOpts struct { + nodes int + + namespaces int + + podsPerNode int + + sharedConfigMapsPerPod int + sharedSecretsPerPod int + sharedPVCsPerPod int + + uniqueSecretsPerPod int + uniqueConfigMapsPerPod int + uniquePVCsPerPod int +} + +func BenchmarkPopulationAllocation(b *testing.B) { + opts := sampleDataOpts{ + nodes: 500, + namespaces: 200, + podsPerNode: 200, + sharedConfigMapsPerPod: 0, + uniqueConfigMapsPerPod: 1, + sharedSecretsPerPod: 1, + uniqueSecretsPerPod: 1, + sharedPVCsPerPod: 0, + uniquePVCsPerPod: 1, + } + + pods, pvs := generate(opts) + b.ResetTimer() + + for i := 0; i < b.N; i++ { + g := NewGraph() + populate(g, pods, pvs) + } +} + +func BenchmarkPopulationRetention(b *testing.B) { + + // Run with: + // go test ./plugin/pkg/auth/authorizer/node -benchmem -bench . -run None -v -o node.test -timeout 300m + + // Evaluate retained memory with: + // go tool pprof --inuse_space node.test plugin/pkg/auth/authorizer/node/BenchmarkPopulationRetention.profile + // list populate + + opts := sampleDataOpts{ + nodes: 500, + namespaces: 200, + podsPerNode: 200, + sharedConfigMapsPerPod: 0, + uniqueConfigMapsPerPod: 1, + sharedSecretsPerPod: 1, + uniqueSecretsPerPod: 1, + sharedPVCsPerPod: 0, + uniquePVCsPerPod: 1, + } + + pods, pvs := generate(opts) + // Garbage collect before the first iteration + runtime.GC() + b.ResetTimer() + + for i := 0; i < b.N; i++ { + g := NewGraph() + populate(g, pods, pvs) + + if i == 0 { + f, _ := os.Create("BenchmarkPopulationRetention.profile") + runtime.GC() + pprof.WriteHeapProfile(f) + f.Close() + // reference the graph to keep it from getting garbage collected + _ = fmt.Sprintf("%T\n", g) + } + } +} + +func BenchmarkAuthorization(b *testing.B) { + g := NewGraph() + + opts := sampleDataOpts{ + nodes: 500, + namespaces: 200, + podsPerNode: 200, + sharedConfigMapsPerPod: 0, + uniqueConfigMapsPerPod: 1, + sharedSecretsPerPod: 1, + uniqueSecretsPerPod: 1, + sharedPVCsPerPod: 0, + uniquePVCsPerPod: 1, + } + pods, pvs := generate(opts) + populate(g, pods, pvs) + + identifier := nodeidentifier.NewDefaultNodeIdentifier() + authz := NewAuthorizer(g, identifier, bootstrappolicy.NodeRules()) + + node0 := &user.DefaultInfo{Name: "system:node:node0", Groups: []string{"system:nodes"}} + + tests := []struct { + name string + attrs authorizer.AttributesRecord + expect bool + }{ + { + name: "allowed configmap", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "configmaps", Name: "configmap0-pod0-node0", Namespace: "ns0"}, + expect: true, + }, + { + name: "allowed secret via pod", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "secrets", Name: "secret0-pod0-node0", Namespace: "ns0"}, + expect: true, + }, + { + name: "allowed shared secret via pod", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "secrets", Name: "secret0-shared", Namespace: "ns0"}, + expect: true, + }, + { + name: "disallowed configmap", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "configmaps", Name: "configmap0-pod0-node1", Namespace: "ns0"}, + expect: false, + }, + { + name: "disallowed secret via pod", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "secrets", Name: "secret0-pod0-node1", Namespace: "ns0"}, + expect: false, + }, + { + name: "disallowed shared secret via pvc", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "secrets", Name: "secret-pv0-pod0-node1-ns0", Namespace: "ns0"}, + expect: false, + }, + { + name: "disallowed pvc", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "persistentvolumeclaims", Name: "pvc0-pod0-node1", Namespace: "ns0"}, + expect: false, + }, + { + name: "disallowed pv", + attrs: authorizer.AttributesRecord{User: node0, ResourceRequest: true, Verb: "get", Resource: "persistentvolumes", Name: "pv0-pod0-node1-ns0", Namespace: ""}, + expect: false, + }, + } + + b.ResetTimer() + for _, tc := range tests { + b.Run(tc.name, func(b *testing.B) { + for i := 0; i < b.N; i++ { + ok, _, _ := authz.Authorize(tc.attrs) + if ok != tc.expect { + b.Errorf("expected %v, got %v", tc.expect, ok) + } + } + }) + } +} + +func populate(graph *Graph, pods []*api.Pod, pvs []*api.PersistentVolume) { + p := &graphPopulator{} + p.graph = graph + for _, pod := range pods { + p.addPod(pod) + } + for _, pv := range pvs { + p.addPV(pv) + } +} + +// generate creates sample pods and persistent volumes based on the provided options. +// the secret/configmap/pvc/node references in the pod and pv objects are named to indicate the connections between the objects. +// for example, secret0-pod0-node0 is a secret referenced by pod0 which is bound to node0. +// when populated into the graph, the node authorizer should allow node0 to access that secret, but not node1. +func generate(opts sampleDataOpts) ([]*api.Pod, []*api.PersistentVolume) { + pods := make([]*api.Pod, 0, opts.nodes*opts.podsPerNode) + pvs := make([]*api.PersistentVolume, 0, (opts.nodes*opts.podsPerNode*opts.uniquePVCsPerPod)+(opts.sharedPVCsPerPod*opts.namespaces)) + + for n := 0; n < opts.nodes; n++ { + nodeName := fmt.Sprintf("node%d", n) + for p := 0; p < opts.podsPerNode; p++ { + pod := &api.Pod{} + pod.Namespace = fmt.Sprintf("ns%d", p%opts.namespaces) + pod.Name = fmt.Sprintf("pod%d-%s", p, nodeName) + pod.Spec.NodeName = nodeName + + for i := 0; i < opts.uniqueSecretsPerPod; i++ { + pod.Spec.Volumes = append(pod.Spec.Volumes, api.Volume{VolumeSource: api.VolumeSource{ + Secret: &api.SecretVolumeSource{SecretName: fmt.Sprintf("secret%d-%s", i, pod.Name)}, + }}) + } + for i := 0; i < opts.sharedSecretsPerPod; i++ { + pod.Spec.Volumes = append(pod.Spec.Volumes, api.Volume{VolumeSource: api.VolumeSource{ + Secret: &api.SecretVolumeSource{SecretName: fmt.Sprintf("secret%d-shared", i)}, + }}) + } + + for i := 0; i < opts.uniqueConfigMapsPerPod; i++ { + pod.Spec.Volumes = append(pod.Spec.Volumes, api.Volume{VolumeSource: api.VolumeSource{ + ConfigMap: &api.ConfigMapVolumeSource{LocalObjectReference: api.LocalObjectReference{Name: fmt.Sprintf("configmap%d-%s", i, pod.Name)}}, + }}) + } + for i := 0; i < opts.sharedConfigMapsPerPod; i++ { + pod.Spec.Volumes = append(pod.Spec.Volumes, api.Volume{VolumeSource: api.VolumeSource{ + ConfigMap: &api.ConfigMapVolumeSource{LocalObjectReference: api.LocalObjectReference{Name: fmt.Sprintf("configmap%d-shared", i)}}, + }}) + } + + for i := 0; i < opts.uniquePVCsPerPod; i++ { + pv := &api.PersistentVolume{} + pv.Name = fmt.Sprintf("pv%d-%s-%s", i, pod.Name, pod.Namespace) + pv.Spec.FlexVolume = &api.FlexVolumeSource{SecretRef: &api.LocalObjectReference{Name: fmt.Sprintf("secret-%s", pv.Name)}} + pv.Spec.ClaimRef = &api.ObjectReference{Name: fmt.Sprintf("pvc%d-%s", i, pod.Name), Namespace: pod.Namespace} + pvs = append(pvs, pv) + + pod.Spec.Volumes = append(pod.Spec.Volumes, api.Volume{VolumeSource: api.VolumeSource{ + PersistentVolumeClaim: &api.PersistentVolumeClaimVolumeSource{ClaimName: pv.Spec.ClaimRef.Name}, + }}) + } + for i := 0; i < opts.sharedPVCsPerPod; i++ { + pv := &api.PersistentVolume{} + pv.Name = fmt.Sprintf("pv%d-shared-%s", i, pod.Namespace) + pv.Spec.FlexVolume = &api.FlexVolumeSource{SecretRef: &api.LocalObjectReference{Name: fmt.Sprintf("secret-%s", pv.Name)}} + pv.Spec.ClaimRef = &api.ObjectReference{Name: fmt.Sprintf("pvc%d-shared", i), Namespace: pod.Namespace} + pvs = append(pvs, pv) + + pod.Spec.Volumes = append(pod.Spec.Volumes, api.Volume{VolumeSource: api.VolumeSource{ + PersistentVolumeClaim: &api.PersistentVolumeClaimVolumeSource{ClaimName: pv.Spec.ClaimRef.Name}, + }}) + } + + pods = append(pods, pod) + } + } + return pods, pvs +} diff --git a/plugin/pkg/auth/authorizer/rbac/bootstrappolicy/policy.go b/plugin/pkg/auth/authorizer/rbac/bootstrappolicy/policy.go index 65a568747c48a..1697ad680d962 100644 --- a/plugin/pkg/auth/authorizer/rbac/bootstrappolicy/policy.go +++ b/plugin/pkg/auth/authorizer/rbac/bootstrappolicy/policy.go @@ -86,6 +86,50 @@ func addClusterRoleBindingLabel(rolebindings []rbac.ClusterRoleBinding) { return } +func NodeRules() []rbac.PolicyRule { + return []rbac.PolicyRule{ + // Needed to check API access. These creates are non-mutating + rbac.NewRule("create").Groups(authenticationGroup).Resources("tokenreviews").RuleOrDie(), + rbac.NewRule("create").Groups(authorizationGroup).Resources("subjectaccessreviews", "localsubjectaccessreviews").RuleOrDie(), + + // Needed to build serviceLister, to populate env vars for services + rbac.NewRule(Read...).Groups(legacyGroup).Resources("services").RuleOrDie(), + + // Nodes can register Node API objects and report status. + // Use the NodeRestriction admission plugin to limit a node to creating/updating its own API object. + rbac.NewRule("create", "get", "list", "watch").Groups(legacyGroup).Resources("nodes").RuleOrDie(), + rbac.NewRule("update", "patch").Groups(legacyGroup).Resources("nodes/status").RuleOrDie(), + rbac.NewRule("update", "patch", "delete").Groups(legacyGroup).Resources("nodes").RuleOrDie(), + + // TODO: restrict to the bound node as creator in the NodeRestrictions admission plugin + rbac.NewRule("create", "update", "patch").Groups(legacyGroup).Resources("events").RuleOrDie(), + + // TODO: restrict to pods scheduled on the bound node once field selectors are supported by list/watch authorization + rbac.NewRule(Read...).Groups(legacyGroup).Resources("pods").RuleOrDie(), + + // Needed for the node to create/delete mirror pods. + // Use the NodeRestriction admission plugin to limit a node to creating/deleting mirror pods bound to itself. + rbac.NewRule("create", "delete").Groups(legacyGroup).Resources("pods").RuleOrDie(), + // Needed for the node to report status of pods it is running. + // Use the NodeRestriction admission plugin to limit a node to updating status of pods bound to itself. + rbac.NewRule("update").Groups(legacyGroup).Resources("pods/status").RuleOrDie(), + + // Needed for imagepullsecrets, rbd/ceph and secret volumes, and secrets in envs + // Needed for configmap volume and envs + // Use the NodeRestriction admission plugin to limit a node to get secrets/configmaps referenced by pods bound to itself. + rbac.NewRule("get").Groups(legacyGroup).Resources("secrets", "configmaps").RuleOrDie(), + // Needed for persistent volumes + // Use the NodeRestriction admission plugin to limit a node to get pv/pvc objects referenced by pods bound to itself. + rbac.NewRule("get").Groups(legacyGroup).Resources("persistentvolumeclaims", "persistentvolumes").RuleOrDie(), + // TODO: add to the Node authorizer and restrict to endpoints referenced by pods or PVs bound to the node + // Needed for glusterfs volumes + rbac.NewRule("get").Groups(legacyGroup).Resources("endpoints").RuleOrDie(), + // Used to create a certificatesigningrequest for a node-specific client certificate, and watch + // for it to be signed. This allows the kubelet to rotate it's own certificate. + rbac.NewRule("create", "get", "list", "watch").Groups(certificatesGroup).Resources("certificatesigningrequests").RuleOrDie(), + } +} + // ClusterRoles returns the cluster roles to bootstrap an API server with func ClusterRoles() []rbac.ClusterRole { roles := []rbac.ClusterRole{ @@ -204,47 +248,7 @@ func ClusterRoles() []rbac.ClusterRole { { // a role for nodes to use to have the access they need for running pods ObjectMeta: metav1.ObjectMeta{Name: "system:node"}, - Rules: []rbac.PolicyRule{ - // Needed to check API access. These creates are non-mutating - rbac.NewRule("create").Groups(authenticationGroup).Resources("tokenreviews").RuleOrDie(), - rbac.NewRule("create").Groups(authorizationGroup).Resources("subjectaccessreviews", "localsubjectaccessreviews").RuleOrDie(), - // Needed to build serviceLister, to populate env vars for services - rbac.NewRule(Read...).Groups(legacyGroup).Resources("services").RuleOrDie(), - // Nodes can register themselves - // TODO: restrict to creating a node with the same name they announce - rbac.NewRule("create", "get", "list", "watch").Groups(legacyGroup).Resources("nodes").RuleOrDie(), - // TODO: restrict to the bound node once supported - rbac.NewRule("update", "patch").Groups(legacyGroup).Resources("nodes/status").RuleOrDie(), - rbac.NewRule("update", "patch", "delete").Groups(legacyGroup).Resources("nodes").RuleOrDie(), - - // TODO: restrict to the bound node as creator once supported - rbac.NewRule("create", "update", "patch").Groups(legacyGroup).Resources("events").RuleOrDie(), - - // TODO: restrict to pods scheduled on the bound node once supported - rbac.NewRule(Read...).Groups(legacyGroup).Resources("pods").RuleOrDie(), - - // TODO: remove once mirror pods are removed - // TODO: restrict deletion to mirror pods created by the bound node once supported - // Needed for the node to create/delete mirror pods - rbac.NewRule("get", "create", "delete").Groups(legacyGroup).Resources("pods").RuleOrDie(), - // TODO: restrict to pods scheduled on the bound node once supported - rbac.NewRule("update").Groups(legacyGroup).Resources("pods/status").RuleOrDie(), - - // TODO: restrict to secrets and configmaps used by pods scheduled on bound node once supported - // Needed for imagepullsecrets, rbd/ceph and secret volumes, and secrets in envs - // Needed for configmap volume and envs - rbac.NewRule("get").Groups(legacyGroup).Resources("secrets", "configmaps").RuleOrDie(), - // TODO: restrict to claims/volumes used by pods scheduled on bound node once supported - // Needed for persistent volumes - rbac.NewRule("get").Groups(legacyGroup).Resources("persistentvolumeclaims", "persistentvolumes").RuleOrDie(), - // TODO: restrict to namespaces of pods scheduled on bound node once supported - // TODO: change glusterfs to use DNS lookup so this isn't needed? - // Needed for glusterfs volumes - rbac.NewRule("get").Groups(legacyGroup).Resources("endpoints").RuleOrDie(), - // Used to create a certificatesigningrequest for a node-specific client certificate, and watch - // for it to be signed. This allows the kubelet to rotate it's own certificate. - rbac.NewRule("create", "get", "list", "watch").Groups(certificatesGroup).Resources("certificatesigningrequests").RuleOrDie(), - }, + Rules: NodeRules(), }, { // a role to use for node-problem-detector access. It does not get bound to default location since @@ -358,18 +362,70 @@ func ClusterRoles() []rbac.ClusterRole { return roles } +// ClusterRoleBindingFilter can modify and return or omit (by returning nil) a role binding +type ClusterRoleBindingFilter func(*rbac.ClusterRoleBinding) *rbac.ClusterRoleBinding + +// AddClusterRoleBindingFilter adds the given filter to the list that is invoked when determing bootstrap roles to reconcile. +func AddClusterRoleBindingFilter(filter ClusterRoleBindingFilter) { + clusterRoleBindingFilters = append(clusterRoleBindingFilters, filter) +} + +// ClearClusterRoleBindingFilters removes any filters added using AddClusterRoleBindingFilter +func ClearClusterRoleBindingFilters() { + clusterRoleBindingFilters = nil +} + +const systemNodeRoleName = "system:node" + +var clusterRoleBindingFilters []ClusterRoleBindingFilter + +// OmitNodesGroupBinding is a filter that omits the deprecated binding for the system:nodes group to the system:node role. +var OmitNodesGroupBinding = ClusterRoleBindingFilter(func(binding *rbac.ClusterRoleBinding) *rbac.ClusterRoleBinding { + if binding.RoleRef.Name == systemNodeRoleName { + subjects := []rbac.Subject{} + for _, subject := range binding.Subjects { + if subject.Kind == rbac.GroupKind && subject.Name == user.NodesGroup { + continue + } + subjects = append(subjects, subject) + } + binding.Subjects = subjects + } + return binding +}) + // ClusterRoleBindings return default rolebindings to the default roles func ClusterRoleBindings() []rbac.ClusterRoleBinding { rolebindings := []rbac.ClusterRoleBinding{ rbac.NewClusterBinding("cluster-admin").Groups(user.SystemPrivilegedGroup).BindingOrDie(), rbac.NewClusterBinding("system:discovery").Groups(user.AllAuthenticated, user.AllUnauthenticated).BindingOrDie(), rbac.NewClusterBinding("system:basic-user").Groups(user.AllAuthenticated, user.AllUnauthenticated).BindingOrDie(), - rbac.NewClusterBinding("system:node").Groups(user.NodesGroup).BindingOrDie(), rbac.NewClusterBinding("system:node-proxier").Users(user.KubeProxy).BindingOrDie(), rbac.NewClusterBinding("system:kube-controller-manager").Users(user.KubeControllerManager).BindingOrDie(), rbac.NewClusterBinding("system:kube-dns").SAs("kube-system", "kube-dns").BindingOrDie(), rbac.NewClusterBinding("system:kube-scheduler").Users(user.KubeScheduler).BindingOrDie(), + + // This default system:nodes binding is deprecated in 1.7 with the availability of the Node authorizer. + // If an admin wants to grant the system:node role (which cannot partition Node API access), they will need to create their own clusterrolebinding. + // TODO: Remove the subjects from this binding in 1.8 (leave the empty binding for tightening reconciliation), and remove AddClusterRoleBindingFilter() + rbac.NewClusterBinding(systemNodeRoleName).Groups(user.NodesGroup).BindingOrDie(), } + addClusterRoleBindingLabel(rolebindings) - return rolebindings + + retval := []rbac.ClusterRoleBinding{} + for i := range rolebindings { + binding := &rolebindings[i] + for _, filter := range clusterRoleBindingFilters { + binding = filter(binding) + if binding == nil { + break + } + } + if binding != nil { + retval = append(retval, *binding) + } + } + + return retval } diff --git a/plugin/pkg/auth/authorizer/rbac/bootstrappolicy/testdata/cluster-roles.yaml b/plugin/pkg/auth/authorizer/rbac/bootstrappolicy/testdata/cluster-roles.yaml index 9e785a7d0c506..d5c47f0fa6dcb 100644 --- a/plugin/pkg/auth/authorizer/rbac/bootstrappolicy/testdata/cluster-roles.yaml +++ b/plugin/pkg/auth/authorizer/rbac/bootstrappolicy/testdata/cluster-roles.yaml @@ -672,7 +672,6 @@ items: verbs: - create - delete - - get - apiGroups: - "" resources: diff --git a/plugin/pkg/scheduler/OWNERS b/plugin/pkg/scheduler/OWNERS index 662f00491c76e..7b17cd0f2ee7d 100644 --- a/plugin/pkg/scheduler/OWNERS +++ b/plugin/pkg/scheduler/OWNERS @@ -2,10 +2,11 @@ approvers: - davidopp - timothysc - wojtek-t +- k82cn reviewers: - davidopp - bsalamat - timothysc - wojtek-t -- k82cn +- k82cn - jayunit100 diff --git a/plugin/pkg/scheduler/algorithm/predicates/BUILD b/plugin/pkg/scheduler/algorithm/predicates/BUILD index 77880a331674a..8f586f64b50c5 100644 --- a/plugin/pkg/scheduler/algorithm/predicates/BUILD +++ b/plugin/pkg/scheduler/algorithm/predicates/BUILD @@ -22,6 +22,8 @@ go_library( "//pkg/api/v1/helper:go_default_library", "//pkg/api/v1/helper/qos:go_default_library", "//pkg/client/listers/core/v1:go_default_library", + "//pkg/features:go_default_library", + "//pkg/volume/util:go_default_library", "//plugin/pkg/scheduler/algorithm:go_default_library", "//plugin/pkg/scheduler/algorithm/priorities/util:go_default_library", "//plugin/pkg/scheduler/schedulercache:go_default_library", @@ -30,7 +32,9 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", + "//vendor/k8s.io/apiserver/pkg/util/feature:go_default_library", "//vendor/k8s.io/client-go/util/workqueue:go_default_library", + "//vendor/k8s.io/metrics/pkg/client/clientset_generated/clientset:go_default_library", ], ) diff --git a/plugin/pkg/scheduler/algorithm/predicates/error.go b/plugin/pkg/scheduler/algorithm/predicates/error.go index 36ac5f1deac42..ecedab29cba98 100644 --- a/plugin/pkg/scheduler/algorithm/predicates/error.go +++ b/plugin/pkg/scheduler/algorithm/predicates/error.go @@ -37,6 +37,7 @@ var ( ErrMaxVolumeCountExceeded = newPredicateFailureError("MaxVolumeCount") ErrNodeUnderMemoryPressure = newPredicateFailureError("NodeUnderMemoryPressure") ErrNodeUnderDiskPressure = newPredicateFailureError("NodeUnderDiskPressure") + ErrVolumeNodeConflict = newPredicateFailureError("NoVolumeNodeConflict") // ErrFakePredicate is used for test only. The fake predicates returning false also returns error // as ErrFakePredicate. ErrFakePredicate = newPredicateFailureError("FakePredicateError") diff --git a/plugin/pkg/scheduler/algorithm/predicates/predicates.go b/plugin/pkg/scheduler/algorithm/predicates/predicates.go index 6a86bebaf6a22..10ea3eafea3b8 100644 --- a/plugin/pkg/scheduler/algorithm/predicates/predicates.go +++ b/plugin/pkg/scheduler/algorithm/predicates/predicates.go @@ -29,14 +29,18 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/labels" utilruntime "k8s.io/apimachinery/pkg/util/runtime" + utilfeature "k8s.io/apiserver/pkg/util/feature" "k8s.io/client-go/util/workqueue" "k8s.io/kubernetes/pkg/api/v1" v1helper "k8s.io/kubernetes/pkg/api/v1/helper" v1qos "k8s.io/kubernetes/pkg/api/v1/helper/qos" corelisters "k8s.io/kubernetes/pkg/client/listers/core/v1" + "k8s.io/kubernetes/pkg/features" + volumeutil "k8s.io/kubernetes/pkg/volume/util" "k8s.io/kubernetes/plugin/pkg/scheduler/algorithm" priorityutil "k8s.io/kubernetes/plugin/pkg/scheduler/algorithm/priorities/util" "k8s.io/kubernetes/plugin/pkg/scheduler/schedulercache" + "k8s.io/metrics/pkg/client/clientset_generated/clientset" ) // predicatePrecomputations: Helper types/variables... @@ -1264,3 +1268,81 @@ func CheckNodeDiskPressurePredicate(pod *v1.Pod, meta interface{}, nodeInfo *sch } return true, nil, nil } + +type VolumeNodeChecker struct { + pvInfo PersistentVolumeInfo + pvcInfo PersistentVolumeClaimInfo + client clientset.Interface +} + +// VolumeNodeChecker evaluates if a pod can fit due to the volumes it requests, given +// that some volumes have node topology constraints, particularly when using Local PVs. +// The requirement is that any pod that uses a PVC that is bound to a PV with topology constraints +// must be scheduled to a node that satisfies the PV's topology labels. +func NewVolumeNodePredicate(pvInfo PersistentVolumeInfo, pvcInfo PersistentVolumeClaimInfo, client clientset.Interface) algorithm.FitPredicate { + c := &VolumeNodeChecker{ + pvInfo: pvInfo, + pvcInfo: pvcInfo, + client: client, + } + return c.predicate +} + +func (c *VolumeNodeChecker) predicate(pod *v1.Pod, meta interface{}, nodeInfo *schedulercache.NodeInfo) (bool, []algorithm.PredicateFailureReason, error) { + if !utilfeature.DefaultFeatureGate.Enabled(features.PersistentLocalVolumes) { + return true, nil, nil + } + + // If a pod doesn't have any volume attached to it, the predicate will always be true. + // Thus we make a fast path for it, to avoid unnecessary computations in this case. + if len(pod.Spec.Volumes) == 0 { + return true, nil, nil + } + + node := nodeInfo.Node() + if node == nil { + return false, nil, fmt.Errorf("node not found") + } + + glog.V(2).Infof("Checking for prebound volumes with node affinity") + namespace := pod.Namespace + manifest := &(pod.Spec) + for i := range manifest.Volumes { + volume := &manifest.Volumes[i] + if volume.PersistentVolumeClaim == nil { + continue + } + pvcName := volume.PersistentVolumeClaim.ClaimName + if pvcName == "" { + return false, nil, fmt.Errorf("PersistentVolumeClaim had no name") + } + pvc, err := c.pvcInfo.GetPersistentVolumeClaimInfo(namespace, pvcName) + if err != nil { + return false, nil, err + } + + if pvc == nil { + return false, nil, fmt.Errorf("PersistentVolumeClaim was not found: %q", pvcName) + } + pvName := pvc.Spec.VolumeName + if pvName == "" { + return false, nil, fmt.Errorf("PersistentVolumeClaim is not bound: %q", pvcName) + } + + pv, err := c.pvInfo.GetPersistentVolumeInfo(pvName) + if err != nil { + return false, nil, err + } + if pv == nil { + return false, nil, fmt.Errorf("PersistentVolume not found: %q", pvName) + } + + err = volumeutil.CheckNodeAffinity(pv, node.Labels) + if err != nil { + glog.V(2).Infof("Won't schedule pod %q onto node %q due to volume %q node mismatch: %v", pod.Name, node.Name, pvName, err.Error()) + return false, []algorithm.PredicateFailureReason{ErrVolumeNodeConflict}, nil + } + glog.V(4).Infof("VolumeNode predicate allows node %q for pod %q due to volume %q", node.Name, pod.Name, pvName) + } + return true, nil, nil +} diff --git a/plugin/pkg/scheduler/algorithmprovider/defaults/compatibility_test.go b/plugin/pkg/scheduler/algorithmprovider/defaults/compatibility_test.go index ccc57efc50b10..be4d20cbede59 100644 --- a/plugin/pkg/scheduler/algorithmprovider/defaults/compatibility_test.go +++ b/plugin/pkg/scheduler/algorithmprovider/defaults/compatibility_test.go @@ -313,6 +313,77 @@ func TestCompatibility_v1_Scheduler(t *testing.T) { }, }, }, + // Do not change this JSON after the corresponding release has been tagged. + // A failure indicates backwards compatibility with the specified release was broken. + "1.7": { + JSON: `{ + "kind": "Policy", + "apiVersion": "v1", + "predicates": [ + {"name": "MatchNodeSelector"}, + {"name": "PodFitsResources"}, + {"name": "PodFitsHostPorts"}, + {"name": "HostName"}, + {"name": "NoDiskConflict"}, + {"name": "NoVolumeZoneConflict"}, + {"name": "PodToleratesNodeTaints"}, + {"name": "CheckNodeMemoryPressure"}, + {"name": "CheckNodeDiskPressure"}, + {"name": "MaxEBSVolumeCount"}, + {"name": "MaxGCEPDVolumeCount"}, + {"name": "MaxAzureDiskVolumeCount"}, + {"name": "MatchInterPodAffinity"}, + {"name": "GeneralPredicates"}, + {"name": "TestServiceAffinity", "argument": {"serviceAffinity" : {"labels" : ["region"]}}}, + {"name": "TestLabelsPresence", "argument": {"labelsPresence" : {"labels" : ["foo"], "presence":true}}}, + {"name": "NoVolumeNodeConflict"} + ],"priorities": [ + {"name": "EqualPriority", "weight": 2}, + {"name": "ImageLocalityPriority", "weight": 2}, + {"name": "LeastRequestedPriority", "weight": 2}, + {"name": "BalancedResourceAllocation", "weight": 2}, + {"name": "SelectorSpreadPriority", "weight": 2}, + {"name": "NodePreferAvoidPodsPriority", "weight": 2}, + {"name": "NodeAffinityPriority", "weight": 2}, + {"name": "TaintTolerationPriority", "weight": 2}, + {"name": "InterPodAffinityPriority", "weight": 2}, + {"name": "MostRequestedPriority", "weight": 2} + ] + }`, + ExpectedPolicy: schedulerapi.Policy{ + Predicates: []schedulerapi.PredicatePolicy{ + {Name: "MatchNodeSelector"}, + {Name: "PodFitsResources"}, + {Name: "PodFitsHostPorts"}, + {Name: "HostName"}, + {Name: "NoDiskConflict"}, + {Name: "NoVolumeZoneConflict"}, + {Name: "PodToleratesNodeTaints"}, + {Name: "CheckNodeMemoryPressure"}, + {Name: "CheckNodeDiskPressure"}, + {Name: "MaxEBSVolumeCount"}, + {Name: "MaxGCEPDVolumeCount"}, + {Name: "MaxAzureDiskVolumeCount"}, + {Name: "MatchInterPodAffinity"}, + {Name: "GeneralPredicates"}, + {Name: "TestServiceAffinity", Argument: &schedulerapi.PredicateArgument{ServiceAffinity: &schedulerapi.ServiceAffinity{Labels: []string{"region"}}}}, + {Name: "TestLabelsPresence", Argument: &schedulerapi.PredicateArgument{LabelsPresence: &schedulerapi.LabelsPresence{Labels: []string{"foo"}, Presence: true}}}, + {Name: "NoVolumeNodeConflict"}, + }, + Priorities: []schedulerapi.PriorityPolicy{ + {Name: "EqualPriority", Weight: 2}, + {Name: "ImageLocalityPriority", Weight: 2}, + {Name: "LeastRequestedPriority", Weight: 2}, + {Name: "BalancedResourceAllocation", Weight: 2}, + {Name: "SelectorSpreadPriority", Weight: 2}, + {Name: "NodePreferAvoidPodsPriority", Weight: 2}, + {Name: "NodeAffinityPriority", Weight: 2}, + {Name: "TaintTolerationPriority", Weight: 2}, + {Name: "InterPodAffinityPriority", Weight: 2}, + {Name: "MostRequestedPriority", Weight: 2}, + }, + }, + }, } registeredPredicates := sets.NewString(factory.ListRegisteredFitPredicates()...) diff --git a/plugin/pkg/scheduler/algorithmprovider/defaults/defaults.go b/plugin/pkg/scheduler/algorithmprovider/defaults/defaults.go index d03ca433ff9e3..94447611a138f 100644 --- a/plugin/pkg/scheduler/algorithmprovider/defaults/defaults.go +++ b/plugin/pkg/scheduler/algorithmprovider/defaults/defaults.go @@ -176,6 +176,14 @@ func defaultPredicates() sets.String { // Fit is determined by node disk pressure condition. factory.RegisterFitPredicate("CheckNodeDiskPressure", predicates.CheckNodeDiskPressurePredicate), + + // Fit is determined by volume zone requirements. + factory.RegisterFitPredicateFactory( + "NoVolumeNodeConflict", + func(args factory.PluginFactoryArgs) algorithm.FitPredicate { + return predicates.NewVolumeNodePredicate(args.PVInfo, args.PVCInfo, nil) + }, + ), ) } diff --git a/plugin/pkg/scheduler/api/types.go b/plugin/pkg/scheduler/api/types.go index 2f89d7544cc3b..6498088dd8402 100644 --- a/plugin/pkg/scheduler/api/types.go +++ b/plugin/pkg/scheduler/api/types.go @@ -40,6 +40,10 @@ type Policy struct { Priorities []PriorityPolicy // Holds the information to communicate with the extender(s) ExtenderConfigs []ExtenderConfig + // RequiredDuringScheduling affinity is not symmetric, but there is an implicit PreferredDuringScheduling affinity rule + // corresponding to every RequiredDuringScheduling affinity rule. + // HardPodAffinitySymmetricWeight represents the weight of implicit PreferredDuringScheduling affinity rule, in the range 1-100. + HardPodAffinitySymmetricWeight int } type PredicatePolicy struct { diff --git a/plugin/pkg/scheduler/api/v1/types.go b/plugin/pkg/scheduler/api/v1/types.go index 036b6c5025240..d8c6f50748965 100644 --- a/plugin/pkg/scheduler/api/v1/types.go +++ b/plugin/pkg/scheduler/api/v1/types.go @@ -32,6 +32,10 @@ type Policy struct { Priorities []PriorityPolicy `json:"priorities"` // Holds the information to communicate with the extender(s) ExtenderConfigs []ExtenderConfig `json:"extenders"` + // RequiredDuringScheduling affinity is not symmetric, but there is an implicit PreferredDuringScheduling affinity rule + // corresponding to every RequiredDuringScheduling affinity rule. + // HardPodAffinitySymmetricWeight represents the weight of implicit PreferredDuringScheduling affinity rule, in the range 1-100. + HardPodAffinitySymmetricWeight int `json:"hardPodAffinitySymmetricWeight"` } type PredicatePolicy struct { diff --git a/plugin/pkg/scheduler/factory/factory.go b/plugin/pkg/scheduler/factory/factory.go index b8687b7496c6f..5a540622d84e8 100644 --- a/plugin/pkg/scheduler/factory/factory.go +++ b/plugin/pkg/scheduler/factory/factory.go @@ -378,6 +378,11 @@ func (f *ConfigFactory) CreateFromConfig(policy schedulerapi.Policy) (*scheduler } } } + // Providing HardPodAffinitySymmetricWeight in the policy config is the new and preferred way of providing the value. + // Give it higher precedence than scheduler CLI configuration when it is provided. + if policy.HardPodAffinitySymmetricWeight != 0 { + f.hardPodAffinitySymmetricWeight = policy.HardPodAffinitySymmetricWeight + } return f.CreateFromKeys(predicateKeys, priorityKeys, extenders) } @@ -385,8 +390,8 @@ func (f *ConfigFactory) CreateFromConfig(policy schedulerapi.Policy) (*scheduler func (f *ConfigFactory) CreateFromKeys(predicateKeys, priorityKeys sets.String, extenders []algorithm.SchedulerExtender) (*scheduler.Config, error) { glog.V(2).Infof("Creating scheduler with fit predicates '%v' and priority functions '%v", predicateKeys, priorityKeys) - if f.GetHardPodAffinitySymmetricWeight() < 0 || f.GetHardPodAffinitySymmetricWeight() > 100 { - return nil, fmt.Errorf("invalid hardPodAffinitySymmetricWeight: %d, must be in the range 0-100", f.GetHardPodAffinitySymmetricWeight()) + if f.GetHardPodAffinitySymmetricWeight() < 1 || f.GetHardPodAffinitySymmetricWeight() > 100 { + return nil, fmt.Errorf("invalid hardPodAffinitySymmetricWeight: %d, must be in the range 1-100", f.GetHardPodAffinitySymmetricWeight()) } predicateFuncs, err := f.GetPredicates(predicateKeys) diff --git a/plugin/pkg/scheduler/factory/factory_test.go b/plugin/pkg/scheduler/factory/factory_test.go index d72e873a3c551..72fbf4acf1f4c 100644 --- a/plugin/pkg/scheduler/factory/factory_test.go +++ b/plugin/pkg/scheduler/factory/factory_test.go @@ -121,6 +121,69 @@ func TestCreateFromConfig(t *testing.T) { } factory.CreateFromConfig(policy) + hpa := factory.GetHardPodAffinitySymmetricWeight() + if hpa != v1.DefaultHardPodAffinitySymmetricWeight { + t.Errorf("Wrong hardPodAffinitySymmetricWeight, ecpected: %d, got: %d", v1.DefaultHardPodAffinitySymmetricWeight, hpa) + } +} + +func TestCreateFromConfigWithHardPodAffinitySymmetricWeight(t *testing.T) { + var configData []byte + var policy schedulerapi.Policy + + handler := utiltesting.FakeHandler{ + StatusCode: 500, + ResponseBody: "", + T: t, + } + server := httptest.NewServer(&handler) + defer server.Close() + client := clientset.NewForConfigOrDie(&restclient.Config{Host: server.URL, ContentConfig: restclient.ContentConfig{GroupVersion: &api.Registry.GroupOrDie(v1.GroupName).GroupVersion}}) + informerFactory := informers.NewSharedInformerFactory(client, 0) + factory := NewConfigFactory( + v1.DefaultSchedulerName, + client, + informerFactory.Core().V1().Nodes(), + informerFactory.Core().V1().Pods(), + informerFactory.Core().V1().PersistentVolumes(), + informerFactory.Core().V1().PersistentVolumeClaims(), + informerFactory.Core().V1().ReplicationControllers(), + informerFactory.Extensions().V1beta1().ReplicaSets(), + informerFactory.Apps().V1beta1().StatefulSets(), + informerFactory.Core().V1().Services(), + v1.DefaultHardPodAffinitySymmetricWeight, + ) + + // Pre-register some predicate and priority functions + RegisterFitPredicate("PredicateOne", PredicateOne) + RegisterFitPredicate("PredicateTwo", PredicateTwo) + RegisterPriorityFunction("PriorityOne", PriorityOne, 1) + RegisterPriorityFunction("PriorityTwo", PriorityTwo, 1) + + configData = []byte(`{ + "kind" : "Policy", + "apiVersion" : "v1", + "predicates" : [ + {"name" : "TestZoneAffinity", "argument" : {"serviceAffinity" : {"labels" : ["zone"]}}}, + {"name" : "TestRequireZone", "argument" : {"labelsPresence" : {"labels" : ["zone"], "presence" : true}}}, + {"name" : "PredicateOne"}, + {"name" : "PredicateTwo"} + ], + "priorities" : [ + {"name" : "RackSpread", "weight" : 3, "argument" : {"serviceAntiAffinity" : {"label" : "rack"}}}, + {"name" : "PriorityOne", "weight" : 2}, + {"name" : "PriorityTwo", "weight" : 1} + ], + "hardPodAffinitySymmetricWeight" : 10 + }`) + if err := runtime.DecodeInto(latestschedulerapi.Codec, configData, &policy); err != nil { + t.Errorf("Invalid configuration: %v", err) + } + factory.CreateFromConfig(policy) + hpa := factory.GetHardPodAffinitySymmetricWeight() + if hpa != 10 { + t.Errorf("Wrong hardPodAffinitySymmetricWeight, ecpected: %d, got: %d", 10, hpa) + } } func TestCreateFromEmptyConfig(t *testing.T) { diff --git a/staging/copy.sh b/staging/copy.sh index a41ce4c2c12e4..d6f75f71987ac 100755 --- a/staging/copy.sh +++ b/staging/copy.sh @@ -161,6 +161,9 @@ grep -Rl "\"${MAIN_REPO_FROM_SRC}" "${CLIENT_REPO_TEMP}" | \ echo "rewrite proto names in proto.RegisterType" find "${CLIENT_REPO_TEMP}" -type f -name "generated.pb.go" -print0 | xargs -0 ${SED} -i "s/k8s\.io\.kubernetes/k8s.io.client-go/g" +echo "rewrite proto IDL package names" +find "${CLIENT_REPO_TEMP}" -type f -name "generated.proto" -print0 | xargs -0 ${SED} -i "s/k8s\.io\.kubernetes/k8s.io.client_go/g" + # strip all generator tags from client-go find "${CLIENT_REPO_TEMP}" -type f -name "*.go" -print0 | xargs -0 ${SED} -i '/^\/\/ +k8s:openapi-gen=true/d' find "${CLIENT_REPO_TEMP}" -type f -name "*.go" -print0 | xargs -0 ${SED} -i '/^\/\/ +k8s:defaulter-gen=/d' diff --git a/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/BUILD b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/BUILD index b639f24c45ac9..639e25a501b29 100644 --- a/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/BUILD +++ b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/BUILD @@ -15,6 +15,7 @@ go_test( "group_version_test.go", "helpers_test.go", "labels_test.go", + "micro_time_test.go", "time_test.go", "types_test.go", ], @@ -38,6 +39,8 @@ go_library( "helpers.go", "labels.go", "meta.go", + "micro_time.go", + "micro_time_proto.go", "register.go", "time.go", "time_proto.go", diff --git a/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/generated.pb.go b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/generated.pb.go index 4904fd063dc27..dac6d84f3ceb1 100644 --- a/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/generated.pb.go +++ b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/generated.pb.go @@ -46,6 +46,7 @@ limitations under the License. LabelSelectorRequirement ListMeta ListOptions + MicroTime ObjectMeta OwnerReference Preconditions @@ -175,59 +176,63 @@ func (m *ListOptions) Reset() { *m = ListOptions{} } func (*ListOptions) ProtoMessage() {} func (*ListOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{20} } +func (m *MicroTime) Reset() { *m = MicroTime{} } +func (*MicroTime) ProtoMessage() {} +func (*MicroTime) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{21} } + func (m *ObjectMeta) Reset() { *m = ObjectMeta{} } func (*ObjectMeta) ProtoMessage() {} -func (*ObjectMeta) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{21} } +func (*ObjectMeta) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{22} } func (m *OwnerReference) Reset() { *m = OwnerReference{} } func (*OwnerReference) ProtoMessage() {} -func (*OwnerReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{22} } +func (*OwnerReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{23} } func (m *Preconditions) Reset() { *m = Preconditions{} } func (*Preconditions) ProtoMessage() {} -func (*Preconditions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{23} } +func (*Preconditions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{24} } func (m *RootPaths) Reset() { *m = RootPaths{} } func (*RootPaths) ProtoMessage() {} -func (*RootPaths) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{24} } +func (*RootPaths) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{25} } func (m *ServerAddressByClientCIDR) Reset() { *m = ServerAddressByClientCIDR{} } func (*ServerAddressByClientCIDR) ProtoMessage() {} func (*ServerAddressByClientCIDR) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{25} + return fileDescriptorGenerated, []int{26} } func (m *Status) Reset() { *m = Status{} } func (*Status) ProtoMessage() {} -func (*Status) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{26} } +func (*Status) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{27} } func (m *StatusCause) Reset() { *m = StatusCause{} } func (*StatusCause) ProtoMessage() {} -func (*StatusCause) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{27} } +func (*StatusCause) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{28} } func (m *StatusDetails) Reset() { *m = StatusDetails{} } func (*StatusDetails) ProtoMessage() {} -func (*StatusDetails) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{28} } +func (*StatusDetails) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{29} } func (m *Time) Reset() { *m = Time{} } func (*Time) ProtoMessage() {} -func (*Time) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{29} } +func (*Time) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{30} } func (m *Timestamp) Reset() { *m = Timestamp{} } func (*Timestamp) ProtoMessage() {} -func (*Timestamp) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{30} } +func (*Timestamp) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{31} } func (m *TypeMeta) Reset() { *m = TypeMeta{} } func (*TypeMeta) ProtoMessage() {} -func (*TypeMeta) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{31} } +func (*TypeMeta) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{32} } func (m *Verbs) Reset() { *m = Verbs{} } func (*Verbs) ProtoMessage() {} -func (*Verbs) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{32} } +func (*Verbs) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{33} } func (m *WatchEvent) Reset() { *m = WatchEvent{} } func (*WatchEvent) ProtoMessage() {} -func (*WatchEvent) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{33} } +func (*WatchEvent) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{34} } func init() { proto.RegisterType((*APIGroup)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.APIGroup") @@ -251,6 +256,7 @@ func init() { proto.RegisterType((*LabelSelectorRequirement)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelectorRequirement") proto.RegisterType((*ListMeta)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta") proto.RegisterType((*ListOptions)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.ListOptions") + proto.RegisterType((*MicroTime)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime") proto.RegisterType((*ObjectMeta)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta") proto.RegisterType((*OwnerReference)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.OwnerReference") proto.RegisterType((*Preconditions)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.Preconditions") @@ -7292,151 +7298,151 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 2322 bytes of a gzipped FileDescriptorProto + // 2330 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x59, 0xcd, 0x6f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e, 0x2f, 0xc5, 0xc3, 0x19, 0x49, 0xfd, 0x4f, 0x1a, 0x2c, 0xa6, 0xf6, 0x4f, 0xc6, 0xea, 0x1a, - 0xcc, 0x77, 0x53, 0x99, 0xaa, 0xf6, 0x32, 0x46, 0x4b, 0x67, 0x31, 0xce, 0x48, 0x22, 0x02, 0x15, - 0xaa, 0x90, 0xa2, 0x13, 0xb9, 0x91, 0x3b, 0xd0, 0x91, 0x0f, 0x89, 0xa5, 0x14, 0x91, 0xe1, 0x04, - 0x59, 0xff, 0x97, 0x26, 0x83, 0x1e, 0x9d, 0x51, 0x74, 0x25, 0x55, 0x07, 0x34, 0xb9, 0x59, 0xf3, - 0x13, 0xce, 0xf0, 0x05, 0x87, 0xa7, 0xf0, 0x7f, 0x71, 0x78, 0xae, 0x97, 0x3f, 0x7a, 0xda, 0x98, - 0xf9, 0xf0, 0x9f, 0xeb, 0x33, 0xfa, 0xa7, 0x05, 0xa8, 0xb5, 0x89, 0x4b, 0x38, 0xb9, 0x17, 0x70, - 0xb9, 0x82, 0x9b, 0x80, 0xba, 0xd4, 0xb4, 0x48, 0x87, 0x50, 0xc7, 0xb7, 0xf7, 0x88, 0xe5, 0x7b, - 0x36, 0x93, 0x21, 0x9a, 0x35, 0xbe, 0x34, 0x1c, 0x34, 0xd0, 0xad, 0x31, 0x2e, 0x3e, 0x47, 0x03, - 0xb9, 0x50, 0x0b, 0xa8, 0xfc, 0xed, 0x70, 0x55, 0x40, 0x45, 0xe2, 0xbe, 0x93, 0x6f, 0xed, 0x9d, - 0xb4, 0xaa, 0xb1, 0x3c, 0x1c, 0x34, 0x6a, 0x19, 0x12, 0xce, 0x82, 0xa3, 0x1f, 0xc0, 0x92, 0x4f, - 0x83, 0x43, 0xd3, 0x6b, 0x93, 0x80, 0x78, 0x36, 0xf1, 0x38, 0x93, 0x87, 0xa9, 0x6c, 0xac, 0x88, - 0xb2, 0x77, 0x6f, 0x84, 0x87, 0xc7, 0xa4, 0xd1, 0x43, 0x58, 0x0e, 0xa8, 0x1f, 0x98, 0x5d, 0x53, - 0x20, 0x76, 0x7c, 0xd7, 0xb1, 0x4e, 0xe5, 0x61, 0xab, 0x18, 0x57, 0x87, 0x83, 0xc6, 0x72, 0x67, - 0x94, 0x79, 0x36, 0x68, 0xbc, 0x22, 0xb7, 0x4e, 0x50, 0x12, 0x26, 0x1e, 0x87, 0xd1, 0x77, 0xa1, - 0xdc, 0xee, 0x53, 0x49, 0x41, 0xdf, 0x83, 0xb2, 0xad, 0x7e, 0xab, 0x5d, 0x7d, 0x2d, 0xea, 0x09, - 0x91, 0xcc, 0xd9, 0xa0, 0x51, 0x13, 0xad, 0xaf, 0x19, 0x11, 0x70, 0xac, 0xa2, 0x3f, 0x82, 0xda, - 0xce, 0x49, 0xe0, 0x53, 0x1e, 0xc5, 0xeb, 0x4d, 0x28, 0x11, 0x49, 0x90, 0x68, 0xe5, 0xa4, 0x90, - 0x85, 0x62, 0x58, 0x71, 0xd1, 0xeb, 0x50, 0x24, 0x27, 0xa6, 0xc5, 0x55, 0x45, 0xaa, 0x29, 0xb1, - 0xe2, 0x8e, 0x20, 0xe2, 0x90, 0xa7, 0x3f, 0xd3, 0x00, 0x6e, 0x91, 0x18, 0x7b, 0x0b, 0x16, 0xa3, - 0x43, 0x91, 0x3d, 0xab, 0x5f, 0x56, 0xda, 0x8b, 0x38, 0xcb, 0xc6, 0xa3, 0xf2, 0xa8, 0x03, 0x2b, - 0x8e, 0x67, 0xb9, 0x7d, 0x9b, 0xdc, 0xf7, 0x1c, 0xcf, 0xe1, 0x8e, 0xe9, 0x3a, 0xbf, 0x88, 0xeb, - 0xe2, 0x57, 0x14, 0xce, 0xca, 0xee, 0x39, 0x32, 0xf8, 0x5c, 0x4d, 0xfd, 0x11, 0x54, 0x64, 0x85, - 0x10, 0xc5, 0x51, 0xac, 0x4a, 0x16, 0x08, 0xe5, 0x57, 0xbc, 0x2a, 0x29, 0x81, 0x43, 0x5e, 0x5c, - 0x5d, 0x0b, 0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0x5e, 0xa6, 0x9a, - 0xee, 0x0a, 0x02, 0x0e, 0xe9, 0xa9, 0x97, 0x97, 0x5f, 0x6b, 0x00, 0xf2, 0xbe, 0xb5, 0x73, 0x2c, - 0xee, 0xc8, 0xeb, 0x30, 0x27, 0x22, 0x30, 0xea, 0x98, 0x3c, 0x46, 0x92, 0x83, 0xee, 0x43, 0xc9, - 0x97, 0x43, 0x95, 0x7a, 0x0a, 0x79, 0x7b, 0x62, 0xe6, 0xa9, 0xff, 0x6a, 0x36, 0xb1, 0xf9, 0x78, - 0xe7, 0x84, 0x13, 0x4f, 0xf8, 0x98, 0x64, 0x5d, 0x38, 0x99, 0x61, 0x05, 0x66, 0xbc, 0xf1, 0xfc, - 0xc5, 0xda, 0xcc, 0xc7, 0x2f, 0xd6, 0x66, 0xfe, 0xf1, 0x62, 0x6d, 0xe6, 0xc3, 0xe1, 0x9a, 0xf6, - 0x7c, 0xb8, 0xa6, 0x7d, 0x3c, 0x5c, 0xd3, 0x3e, 0x19, 0xae, 0x69, 0x4f, 0x3e, 0x5d, 0x9b, 0x79, - 0x58, 0x38, 0xde, 0xf8, 0x5f, 0x00, 0x00, 0x00, 0xff, 0xff, 0xf6, 0x0e, 0xfb, 0x43, 0x17, 0x1e, - 0x00, 0x00, + 0xb5, 0x9a, 0x85, 0x59, 0x9b, 0x64, 0x61, 0x35, 0x0c, 0x30, 0x90, 0x8e, 0x33, 0xa3, 0x68, 0x27, + 0x33, 0x56, 0x65, 0x67, 0x10, 0xc3, 0x08, 0xd1, 0xe9, 0xae, 0x38, 0x4d, 0xda, 0xdd, 0xbd, 0x55, + 0xe5, 0xcc, 0x84, 0x3d, 0xb0, 0x07, 0x90, 0x38, 0x20, 0x34, 0x47, 0x4e, 0x68, 0x47, 0xf0, 0x17, + 0x70, 0x87, 0x13, 0x12, 0x73, 0x5c, 0x89, 0x0b, 0x07, 0x64, 0xed, 0x78, 0x0f, 0x9c, 0x10, 0xf7, + 0x48, 0x48, 0xa8, 0xaa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, + 0x1f, 0xcf, 0xd7, 0x66, 0x3e, 0x18, 0xae, 0x69, 0xcf, 0x86, 0x6b, 0xda, 0x47, 0xc3, 0x35, 0xed, + 0xe3, 0xe1, 0x9a, 0xf6, 0xe4, 0x93, 0xb5, 0x99, 0x07, 0x85, 0x93, 0x8d, 0xff, 0x05, 0x00, 0x00, + 0xff, 0xff, 0x03, 0x37, 0xed, 0x6d, 0x8a, 0x1e, 0x00, 0x00, } diff --git a/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto index e73ebce9a94fe..65bf340a8b90c 100644 --- a/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto +++ b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto @@ -342,6 +342,24 @@ message ListOptions { optional int64 timeoutSeconds = 5; } +// MicroTime is version of Time with microsecond level precision. +// +// +protobuf.options.marshal=false +// +protobuf.as=Timestamp +// +protobuf.options.(gogoproto.goproto_stringer)=false +message MicroTime { + // Represents seconds of UTC time since Unix epoch + // 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to + // 9999-12-31T23:59:59Z inclusive. + optional int64 seconds = 1; + + // Non-negative fractions of a second at nanosecond resolution. Negative + // second values with fractions must still have non-negative nanos values + // that count forward in time. Must be from 0 to 999,999,999 + // inclusive. This field may be limited in precision depending on context. + optional int32 nanos = 2; +} + // ObjectMeta is metadata that all persisted resources must have, which includes all objects // users must create. message ObjectMeta { diff --git a/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/group_version.go b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/group_version.go index 8b6fdef5a4032..bd0e9612a64e7 100644 --- a/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/group_version.go +++ b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/group_version.go @@ -75,9 +75,9 @@ func (gk *GroupKind) String() string { // // +protobuf.options.(gogoproto.goproto_stringer)=false type GroupVersionKind struct { - Group string `protobuf:"bytes,1,opt,name=group"` - Version string `protobuf:"bytes,2,opt,name=version"` - Kind string `protobuf:"bytes,3,opt,name=kind"` + Group string `json:"group" protobuf:"bytes,1,opt,name=group"` + Version string `json:"version" protobuf:"bytes,2,opt,name=version"` + Kind string `json:"kind" protobuf:"bytes,3,opt,name=kind"` } func (gvk GroupVersionKind) String() string { diff --git a/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time.go b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time.go new file mode 100644 index 0000000000000..d55f446b0d3c2 --- /dev/null +++ b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time.go @@ -0,0 +1,184 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +package v1 + +import ( + "encoding/json" + "time" + + "k8s.io/apimachinery/pkg/openapi" + + "github.com/go-openapi/spec" + "github.com/google/gofuzz" +) + +const RFC3339Micro = "2006-01-02T15:04:05.000000Z07:00" + +// MicroTime is version of Time with microsecond level precision. +// +// +protobuf.options.marshal=false +// +protobuf.as=Timestamp +// +protobuf.options.(gogoproto.goproto_stringer)=false +type MicroTime struct { + time.Time `protobuf:"-"` +} + +// DeepCopy returns a deep-copy of the MicroTime value. The underlying time.Time +// type is effectively immutable in the time API, so it is safe to +// copy-by-assign, despite the presence of (unexported) Pointer fields. +func (t MicroTime) DeepCopy() MicroTime { + return t +} + +// String returns the representation of the time. +func (t MicroTime) String() string { + return t.Time.String() +} + +// NewMicroTime returns a wrapped instance of the provided time +func NewMicroTime(time time.Time) MicroTime { + return MicroTime{time} +} + +// DateMicro returns the MicroTime corresponding to the supplied parameters +// by wrapping time.Date. +func DateMicro(year int, month time.Month, day, hour, min, sec, nsec int, loc *time.Location) MicroTime { + return MicroTime{time.Date(year, month, day, hour, min, sec, nsec, loc)} +} + +// NowMicro returns the current local time. +func NowMicro() MicroTime { + return MicroTime{time.Now()} +} + +// IsZero returns true if the value is nil or time is zero. +func (t *MicroTime) IsZero() bool { + if t == nil { + return true + } + return t.Time.IsZero() +} + +// Before reports whether the time instant t is before u. +func (t MicroTime) Before(u MicroTime) bool { + return t.Time.Before(u.Time) +} + +// Equal reports whether the time instant t is equal to u. +func (t MicroTime) Equal(u MicroTime) bool { + return t.Time.Equal(u.Time) +} + +// BeforeTime reports whether the time instant t is before second-lever precision u. +func (t MicroTime) BeforeTime(u Time) bool { + return t.Time.Before(u.Time) +} + +// EqualTime reports whether the time instant t is equal to second-lever precision u. +func (t MicroTime) EqualTime(u Time) bool { + return t.Time.Equal(u.Time) +} + +// UnixMicro returns the local time corresponding to the given Unix time +// by wrapping time.Unix. +func UnixMicro(sec int64, nsec int64) MicroTime { + return MicroTime{time.Unix(sec, nsec)} +} + +// UnmarshalJSON implements the json.Unmarshaller interface. +func (t *MicroTime) UnmarshalJSON(b []byte) error { + if len(b) == 4 && string(b) == "null" { + t.Time = time.Time{} + return nil + } + + var str string + json.Unmarshal(b, &str) + + pt, err := time.Parse(RFC3339Micro, str) + if err != nil { + return err + } + + t.Time = pt.Local() + return nil +} + +// UnmarshalQueryParameter converts from a URL query parameter value to an object +func (t *MicroTime) UnmarshalQueryParameter(str string) error { + if len(str) == 0 { + t.Time = time.Time{} + return nil + } + // Tolerate requests from older clients that used JSON serialization to build query params + if len(str) == 4 && str == "null" { + t.Time = time.Time{} + return nil + } + + pt, err := time.Parse(RFC3339Micro, str) + if err != nil { + return err + } + + t.Time = pt.Local() + return nil +} + +// MarshalJSON implements the json.Marshaler interface. +func (t MicroTime) MarshalJSON() ([]byte, error) { + if t.IsZero() { + // Encode unset/nil objects as JSON's "null". + return []byte("null"), nil + } + + return json.Marshal(t.UTC().Format(RFC3339Micro)) +} + +func (_ MicroTime) OpenAPIDefinition() openapi.OpenAPIDefinition { + return openapi.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "date-time", + }, + }, + } +} + +// MarshalQueryParameter converts to a URL query parameter value +func (t MicroTime) MarshalQueryParameter() (string, error) { + if t.IsZero() { + // Encode unset/nil objects as an empty string + return "", nil + } + + return t.UTC().Format(RFC3339Micro), nil +} + +// Fuzz satisfies fuzz.Interface. +func (t *MicroTime) Fuzz(c fuzz.Continue) { + if t == nil { + return + } + // Allow for about 1000 years of randomness. Leave off nanoseconds + // because JSON doesn't represent them so they can't round-trip + // properly. + t.Time = time.Unix(c.Rand.Int63n(1000*365*24*60*60*1000*1000), 0) +} + +var _ fuzz.Interface = &MicroTime{} diff --git a/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time_proto.go b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time_proto.go new file mode 100644 index 0000000000000..14841be512ae5 --- /dev/null +++ b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time_proto.go @@ -0,0 +1,72 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +package v1 + +import ( + "time" +) + +// Timestamp is declared in time_proto.go + +// Timestamp returns the Time as a new Timestamp value. +func (m *MicroTime) ProtoMicroTime() *Timestamp { + if m == nil { + return &Timestamp{} + } + return &Timestamp{ + Seconds: m.Time.Unix(), + Nanos: int32(m.Time.Nanosecond()), + } +} + +// Size implements the protobuf marshalling interface. +func (m *MicroTime) Size() (n int) { + if m == nil || m.Time.IsZero() { + return 0 + } + return m.ProtoMicroTime().Size() +} + +// Reset implements the protobuf marshalling interface. +func (m *MicroTime) Unmarshal(data []byte) error { + if len(data) == 0 { + m.Time = time.Time{} + return nil + } + p := Timestamp{} + if err := p.Unmarshal(data); err != nil { + return err + } + m.Time = time.Unix(p.Seconds, int64(p.Nanos)).Local() + return nil +} + +// Marshal implements the protobuf marshalling interface. +func (m *MicroTime) Marshal() (data []byte, err error) { + if m == nil || m.Time.IsZero() { + return nil, nil + } + return m.ProtoMicroTime().Marshal() +} + +// MarshalTo implements the protobuf marshalling interface. +func (m *MicroTime) MarshalTo(data []byte) (int, error) { + if m == nil || m.Time.IsZero() { + return 0, nil + } + return m.ProtoMicroTime().MarshalTo(data) +} diff --git a/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time_test.go b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time_test.go new file mode 100644 index 0000000000000..339610aebadd4 --- /dev/null +++ b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time_test.go @@ -0,0 +1,139 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +package v1 + +import ( + "encoding/json" + "reflect" + "testing" + "time" + + "github.com/ghodss/yaml" +) + +type MicroTimeHolder struct { + T MicroTime `json:"t"` +} + +func TestMicroTimeMarshalYAML(t *testing.T) { + cases := []struct { + input MicroTime + result string + }{ + {MicroTime{}, "t: null\n"}, + {DateMicro(1998, time.May, 5, 1, 5, 5, 50, time.FixedZone("test", -4*60*60)), "t: 1998-05-05T05:05:05.000000Z\n"}, + {DateMicro(1998, time.May, 5, 5, 5, 5, 0, time.UTC), "t: 1998-05-05T05:05:05.000000Z\n"}, + } + + for _, c := range cases { + input := MicroTimeHolder{c.input} + result, err := yaml.Marshal(&input) + if err != nil { + t.Errorf("Failed to marshal input: '%v': %v", input, err) + } + if string(result) != c.result { + t.Errorf("Failed to marshal input: '%v': expected %+v, got %q", input, c.result, string(result)) + } + } +} + +func TestMicroTimeUnmarshalYAML(t *testing.T) { + cases := []struct { + input string + result MicroTime + }{ + {"t: null\n", MicroTime{}}, + {"t: 1998-05-05T05:05:05.000000Z\n", MicroTime{Date(1998, time.May, 5, 5, 5, 5, 0, time.UTC).Local()}}, + } + + for _, c := range cases { + var result MicroTimeHolder + if err := yaml.Unmarshal([]byte(c.input), &result); err != nil { + t.Errorf("Failed to unmarshal input '%v': %v", c.input, err) + } + if result.T != c.result { + t.Errorf("Failed to unmarshal input '%v': expected %+v, got %+v", c.input, c.result, result) + } + } +} + +func TestMicroTimeMarshalJSON(t *testing.T) { + cases := []struct { + input MicroTime + result string + }{ + {MicroTime{}, "{\"t\":null}"}, + {DateMicro(1998, time.May, 5, 5, 5, 5, 50, time.UTC), "{\"t\":\"1998-05-05T05:05:05.000000Z\"}"}, + {DateMicro(1998, time.May, 5, 5, 5, 5, 0, time.UTC), "{\"t\":\"1998-05-05T05:05:05.000000Z\"}"}, + } + + for _, c := range cases { + input := MicroTimeHolder{c.input} + result, err := json.Marshal(&input) + if err != nil { + t.Errorf("Failed to marshal input: '%v': %v", input, err) + } + if string(result) != c.result { + t.Errorf("Failed to marshal input: '%v': expected %+v, got %q", input, c.result, string(result)) + } + } +} + +func TestMicroTimeUnmarshalJSON(t *testing.T) { + cases := []struct { + input string + result MicroTime + }{ + {"{\"t\":null}", MicroTime{}}, + {"{\"t\":\"1998-05-05T05:05:05.000000Z\"}", MicroTime{Date(1998, time.May, 5, 5, 5, 5, 0, time.UTC).Local()}}, + } + + for _, c := range cases { + var result MicroTimeHolder + if err := json.Unmarshal([]byte(c.input), &result); err != nil { + t.Errorf("Failed to unmarshal input '%v': %v", c.input, err) + } + if result.T != c.result { + t.Errorf("Failed to unmarshal input '%v': expected %+v, got %+v", c.input, c.result, result) + } + } +} + +func TestMicroTimeProto(t *testing.T) { + cases := []struct { + input MicroTime + }{ + {MicroTime{}}, + {DateMicro(1998, time.May, 5, 1, 5, 5, 50, time.Local)}, + {DateMicro(1998, time.May, 5, 5, 5, 5, 0, time.Local)}, + } + + for _, c := range cases { + input := c.input + data, err := input.Marshal() + if err != nil { + t.Fatalf("Failed to marshal input: '%v': %v", input, err) + } + time := MicroTime{} + if err := time.Unmarshal(data); err != nil { + t.Fatalf("Failed to unmarshal output: '%v': %v", input, err) + } + if !reflect.DeepEqual(input, time) { + t.Errorf("Marshal->Unmarshal is not idempotent: '%v' vs '%v'", input, time) + } + } +} diff --git a/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.deepcopy.go b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.deepcopy.go index 55293e03672a8..47e5b1da70d80 100644 --- a/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.deepcopy.go +++ b/staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.deepcopy.go @@ -52,6 +52,7 @@ func GetGeneratedDeepCopyFuncs() []conversion.GeneratedDeepCopyFunc { {Fn: DeepCopy_v1_LabelSelectorRequirement, InType: reflect.TypeOf(&LabelSelectorRequirement{})}, {Fn: DeepCopy_v1_ListMeta, InType: reflect.TypeOf(&ListMeta{})}, {Fn: DeepCopy_v1_ListOptions, InType: reflect.TypeOf(&ListOptions{})}, + {Fn: DeepCopy_v1_MicroTime, InType: reflect.TypeOf(&MicroTime{})}, {Fn: DeepCopy_v1_ObjectMeta, InType: reflect.TypeOf(&ObjectMeta{})}, {Fn: DeepCopy_v1_OwnerReference, InType: reflect.TypeOf(&OwnerReference{})}, {Fn: DeepCopy_v1_Patch, InType: reflect.TypeOf(&Patch{})}, @@ -412,6 +413,16 @@ func DeepCopy_v1_ListOptions(in interface{}, out interface{}, c *conversion.Clon } } +// DeepCopy_v1_MicroTime is an autogenerated deepcopy function. +func DeepCopy_v1_MicroTime(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*MicroTime) + out := out.(*MicroTime) + *out = in.DeepCopy() + return nil + } +} + // DeepCopy_v1_ObjectMeta is an autogenerated deepcopy function. func DeepCopy_v1_ObjectMeta(in interface{}, out interface{}, c *conversion.Cloner) error { { diff --git a/staging/src/k8s.io/apimachinery/pkg/fields/selector.go b/staging/src/k8s.io/apimachinery/pkg/fields/selector.go index bb156b4cba065..1305dde086cec 100644 --- a/staging/src/k8s.io/apimachinery/pkg/fields/selector.go +++ b/staging/src/k8s.io/apimachinery/pkg/fields/selector.go @@ -40,6 +40,8 @@ type Selector interface { // Transform returns a new copy of the selector after TransformFunc has been // applied to the entire selector, or an error if fn returns an error. + // If for a given requirement both field and value are transformed to empty + // string, the requirement is skipped. Transform(fn TransformFunc) (Selector, error) // Requirements converts this interface to Requirements to expose @@ -79,6 +81,9 @@ func (t *hasTerm) Transform(fn TransformFunc) (Selector, error) { if err != nil { return nil, err } + if len(field) == 0 && len(value) == 0 { + return Everything(), nil + } return &hasTerm{field, value}, nil } @@ -115,6 +120,9 @@ func (t *notHasTerm) Transform(fn TransformFunc) (Selector, error) { if err != nil { return nil, err } + if len(field) == 0 && len(value) == 0 { + return Everything(), nil + } return ¬HasTerm{field, value}, nil } @@ -169,13 +177,15 @@ func (t andTerm) RequiresExactMatch(field string) (string, bool) { } func (t andTerm) Transform(fn TransformFunc) (Selector, error) { - next := make([]Selector, len([]Selector(t))) - for i, s := range []Selector(t) { + next := make([]Selector, 0, len([]Selector(t))) + for _, s := range []Selector(t) { n, err := s.Transform(fn) if err != nil { return nil, err } - next[i] = n + if !n.Empty() { + next = append(next, n) + } } return andTerm(next), nil } @@ -222,7 +232,7 @@ var valueEscaper = strings.NewReplacer( `=`, `\=`, ) -// Escapes an arbitrary literal string for use as a fieldSelector value +// EscapeValue escapes an arbitrary literal string for use as a fieldSelector value func EscapeValue(s string) string { return valueEscaper.Replace(s) } @@ -245,7 +255,7 @@ func (i UnescapedRune) Error() string { return fmt.Sprintf("invalid field selector: unescaped character in value: %v", i.r) } -// Unescapes a fieldSelector value and returns the original literal value. +// UnescapeValue unescapes a fieldSelector value and returns the original literal value. // May return the original string if it contains no escaped or special characters. func UnescapeValue(s string) (string, error) { // if there's no escaping or special characters, just return to avoid allocation @@ -307,12 +317,12 @@ func ParseSelector(selector string) (Selector, error) { }) } -// Parses the selector and runs them through the given TransformFunc. +// ParseAndTransformSelector parses the selector and runs them through the given TransformFunc. func ParseAndTransformSelector(selector string, fn TransformFunc) (Selector, error) { return parseSelector(selector, fn) } -// Function to transform selectors. +// TransformFunc transforms selectors. type TransformFunc func(field, value string) (newField, newValue string, err error) // splitTerms returns the comma-separated terms contained in the given fieldSelector. diff --git a/staging/src/k8s.io/apimachinery/pkg/fields/selector_test.go b/staging/src/k8s.io/apimachinery/pkg/fields/selector_test.go index 458d1574a53e5..ff6245ca9e1c3 100644 --- a/staging/src/k8s.io/apimachinery/pkg/fields/selector_test.go +++ b/staging/src/k8s.io/apimachinery/pkg/fields/selector_test.go @@ -325,3 +325,73 @@ func TestRequiresExactMatch(t *testing.T) { } } } + +func TestTransform(t *testing.T) { + testCases := []struct { + name string + selector string + transform func(field, value string) (string, string, error) + result string + isEmpty bool + }{ + { + name: "empty selector", + selector: "", + transform: func(field, value string) (string, string, error) { return field, value, nil }, + result: "", + isEmpty: true, + }, + { + name: "no-op transform", + selector: "a=b,c=d", + transform: func(field, value string) (string, string, error) { return field, value, nil }, + result: "a=b,c=d", + isEmpty: false, + }, + { + name: "transform one field", + selector: "a=b,c=d", + transform: func(field, value string) (string, string, error) { + if field == "a" { + return "e", "f", nil + } + return field, value, nil + }, + result: "e=f,c=d", + isEmpty: false, + }, + { + name: "remove field to make empty", + selector: "a=b", + transform: func(field, value string) (string, string, error) { return "", "", nil }, + result: "", + isEmpty: true, + }, + { + name: "remove only one field", + selector: "a=b,c=d,e=f", + transform: func(field, value string) (string, string, error) { + if field == "c" { + return "", "", nil + } + return field, value, nil + }, + result: "a=b,e=f", + isEmpty: false, + }, + } + + for i, tc := range testCases { + result, err := ParseAndTransformSelector(tc.selector, tc.transform) + if err != nil { + t.Errorf("[%d] unexpected error during Transform: %v", i, err) + } + if result.Empty() != tc.isEmpty { + t.Errorf("[%d] expected empty: %t, got: %t", i, tc.isEmpty, result.Empty) + } + if result.String() != tc.result { + t.Errorf("[%d] unexpected result: %s", i, result.String()) + } + } + +} diff --git a/staging/src/k8s.io/apimachinery/pkg/labels/selector.go b/staging/src/k8s.io/apimachinery/pkg/labels/selector.go index 9bddc35a60a42..50b41f99d2890 100644 --- a/staging/src/k8s.io/apimachinery/pkg/labels/selector.go +++ b/staging/src/k8s.io/apimachinery/pkg/labels/selector.go @@ -71,13 +71,14 @@ func Nothing() Selector { return nothingSelector{} } +// NewSelector returns a nil selector func NewSelector() Selector { return internalSelector(nil) } type internalSelector []Requirement -// Sort by key to obtain determisitic parser +// ByKey sorts requirements by key to obtain deterministic parser type ByKey []Requirement func (a ByKey) Len() int { return len(a) } @@ -215,12 +216,17 @@ func (r *Requirement) Matches(ls Labels) bool { } } +// Key returns requirement key func (r *Requirement) Key() string { return r.key } + +// Operator returns requirement operator func (r *Requirement) Operator() selection.Operator { return r.operator } + +// Values returns requirement values func (r *Requirement) Values() sets.String { ret := sets.String{} for i := range r.strValues { @@ -229,7 +235,7 @@ func (r *Requirement) Values() sets.String { return ret } -// Return true if the internalSelector doesn't restrict selection space +// Empty returns true if the internalSelector doesn't restrict selection space func (lsel internalSelector) Empty() bool { if lsel == nil { return true @@ -320,23 +326,37 @@ func (lsel internalSelector) String() string { return strings.Join(reqs, ",") } -// constants definition for lexer token +// Token represents constant definition for lexer token type Token int const ( + // ErrorToken represents scan error ErrorToken Token = iota + // EndOfStringToken represents end of string EndOfStringToken + // ClosedParToken represents close parenthesis ClosedParToken + // CommaToken represents the comma CommaToken + // DoesNotExistToken represents logic not DoesNotExistToken + // DoubleEqualsToken represents double equals DoubleEqualsToken + // EqualsToken represents equal EqualsToken + // GreaterThanToken represents greater than GreaterThanToken - IdentifierToken // to represent keys and values + // IdentifierToken represents identifier, e.g. keys and values + IdentifierToken + // InToken represents in InToken + // LessThanToken represents less than LessThanToken + // NotEqualsToken represents not equal NotEqualsToken + // NotInToken represents not in NotInToken + // OpenParToken represents open parenthesis OpenParToken ) @@ -356,7 +376,7 @@ var string2token = map[string]Token{ "(": OpenParToken, } -// The item produced by the lexer. It contains the Token and the literal. +// ScannedItem contains the Token and the literal produced by the lexer. type ScannedItem struct { tok Token literal string @@ -401,8 +421,8 @@ func (l *Lexer) unread() { l.pos-- } -// scanIdOrKeyword scans string to recognize literal token (for example 'in') or an identifier. -func (l *Lexer) scanIdOrKeyword() (tok Token, lit string) { +// scanIDOrKeyword scans string to recognize literal token (for example 'in') or an identifier. +func (l *Lexer) scanIDOrKeyword() (tok Token, lit string) { var buffer []byte IdentifierLoop: for { @@ -474,7 +494,7 @@ func (l *Lexer) Lex() (tok Token, lit string) { return l.scanSpecialSymbol() default: l.unread() - return l.scanIdOrKeyword() + return l.scanIDOrKeyword() } } @@ -485,14 +505,16 @@ type Parser struct { position int } -// Parser context represents context during parsing: +// ParserContext represents context during parsing: // some literal for example 'in' and 'notin' can be // recognized as operator for example 'x in (a)' but // it can be recognized as value for example 'value in (in)' type ParserContext int const ( + // KeyAndOperator represents key and operator KeyAndOperator ParserContext = iota + // Values represents values Values ) @@ -798,11 +820,12 @@ func SelectorFromSet(ls Set) Selector { } var requirements internalSelector for label, value := range ls { - if r, err := NewRequirement(label, selection.Equals, []string{value}); err != nil { + r, err := NewRequirement(label, selection.Equals, []string{value}) + if err == nil { + requirements = append(requirements, *r) + } else { //TODO: double check errors when input comes from serialization? return internalSelector{} - } else { - requirements = append(requirements, *r) } } // sort to have deterministic string representation diff --git a/staging/src/k8s.io/apimachinery/pkg/runtime/codec_check.go b/staging/src/k8s.io/apimachinery/pkg/runtime/codec_check.go index 1d34ec1a85679..510444a4dec27 100644 --- a/staging/src/k8s.io/apimachinery/pkg/runtime/codec_check.go +++ b/staging/src/k8s.io/apimachinery/pkg/runtime/codec_check.go @@ -28,8 +28,7 @@ import ( // object. (Will modify internalObject.) (Assumes JSON serialization.) // TODO: verify that the correct external version is chosen on encode... func CheckCodec(c Codec, internalType Object, externalTypes ...schema.GroupVersionKind) error { - _, err := Encode(c, internalType) - if err != nil { + if _, err := Encode(c, internalType); err != nil { return fmt.Errorf("Internal type not encodable: %v", err) } for _, et := range externalTypes { @@ -41,9 +40,8 @@ func CheckCodec(c Codec, internalType Object, externalTypes ...schema.GroupVersi if reflect.TypeOf(obj) != reflect.TypeOf(internalType) { return fmt.Errorf("decode of external type %s produced: %#v", et, obj) } - err = DecodeInto(c, exBytes, internalType) - if err != nil { - return fmt.Errorf("external type %s not convertable to internal type: %v", et, err) + if err = DecodeInto(c, exBytes, internalType); err != nil { + return fmt.Errorf("external type %s not convertible to internal type: %v", et, err) } } return nil diff --git a/staging/src/k8s.io/apimachinery/pkg/util/mergepatch/OWNERS b/staging/src/k8s.io/apimachinery/pkg/util/mergepatch/OWNERS new file mode 100644 index 0000000000000..8e8d9fce8efa8 --- /dev/null +++ b/staging/src/k8s.io/apimachinery/pkg/util/mergepatch/OWNERS @@ -0,0 +1,5 @@ +approvers: +- pwittrock +reviewers: +- mengqiy +- apelisse diff --git a/staging/src/k8s.io/apimachinery/pkg/util/mergepatch/errors.go b/staging/src/k8s.io/apimachinery/pkg/util/mergepatch/errors.go index ef87f24cea625..ac3c1e8cfcf53 100644 --- a/staging/src/k8s.io/apimachinery/pkg/util/mergepatch/errors.go +++ b/staging/src/k8s.io/apimachinery/pkg/util/mergepatch/errors.go @@ -23,9 +23,12 @@ import ( ) var ( - ErrBadJSONDoc = errors.New("Invalid JSON document") - ErrNoListOfLists = errors.New("Lists of lists are not supported") - ErrBadPatchFormatForPrimitiveList = errors.New("Invalid patch format of primitive list") + ErrBadJSONDoc = errors.New("invalid JSON document") + ErrNoListOfLists = errors.New("lists of lists are not supported") + ErrBadPatchFormatForPrimitiveList = errors.New("invalid patch format of primitive list") + ErrBadPatchFormatForRetainKeys = errors.New("invalid patch format of retainKeys") + ErrBadPatchFormatForSetElementOrderList = errors.New("invalid patch format of setElementOrder list") + ErrPatchContentNotMatchRetainKeys = errors.New("patch content doesn't match retainKeys list") ) func ErrNoMergeKey(m map[string]interface{}, k string) error { diff --git a/staging/src/k8s.io/apimachinery/pkg/util/strategicpatch/OWNERS b/staging/src/k8s.io/apimachinery/pkg/util/strategicpatch/OWNERS new file mode 100644 index 0000000000000..8e8d9fce8efa8 --- /dev/null +++ b/staging/src/k8s.io/apimachinery/pkg/util/strategicpatch/OWNERS @@ -0,0 +1,5 @@ +approvers: +- pwittrock +reviewers: +- mengqiy +- apelisse diff --git a/staging/src/k8s.io/apimachinery/pkg/util/strategicpatch/patch.go b/staging/src/k8s.io/apimachinery/pkg/util/strategicpatch/patch.go index 610739c30b3d0..4f12421f84959 100644 --- a/staging/src/k8s.io/apimachinery/pkg/util/strategicpatch/patch.go +++ b/staging/src/k8s.io/apimachinery/pkg/util/strategicpatch/patch.go @@ -43,7 +43,11 @@ const ( replaceDirective = "replace" mergeDirective = "merge" + retainKeysStrategy = "retainKeys" + deleteFromPrimitiveListDirectivePrefix = "$deleteFromPrimitiveList" + retainKeysDirective = "$" + retainKeysStrategy + setElementOrderDirectivePrefix = "$setElementOrder" ) // JSONMap is a representations of JSON object encoded as map[string]interface{} @@ -54,15 +58,27 @@ const ( type JSONMap map[string]interface{} type DiffOptions struct { + // SetElementOrder determines whether we generate the $setElementOrder parallel list. + SetElementOrder bool // IgnoreChangesAndAdditions indicates if we keep the changes and additions in the patch. IgnoreChangesAndAdditions bool // IgnoreDeletions indicates if we keep the deletions in the patch. IgnoreDeletions bool + // We introduce a new value retainKeys for patchStrategy. + // It indicates that all fields needing to be preserved must be + // present in the `retainKeys` list. + // And the fields that are present will be merged with live object. + // All the missing fields will be cleared when patching. + BuildRetainKeysDirective bool } type MergeOptions struct { - // MergeDeleteList indicates if we are merging the delete parallel list. - MergeDeleteList bool + // MergeParallelList indicates if we are merging the parallel list. + // We don't merge parallel list when calling mergeMap() in CreateThreeWayMergePatch() + // which is called client-side. + // We merge parallel list iff when calling mergeMap() in StrategicMergeMapPatch() + // which is called server-side + MergeParallelList bool // IgnoreUnmatchedNulls indicates if we should process the unmatched nulls. IgnoreUnmatchedNulls bool } @@ -108,8 +124,7 @@ func CreateTwoWayMergeMapPatch(original, modified JSONMap, dataStruct interface{ } diffOptions := DiffOptions{ - IgnoreChangesAndAdditions: false, - IgnoreDeletions: false, + SetElementOrder: true, } patchMap, err := diffMaps(original, modified, t, diffOptions) if err != nil { @@ -127,13 +142,31 @@ func CreateTwoWayMergeMapPatch(original, modified JSONMap, dataStruct interface{ } // Returns a (recursive) strategic merge patch that yields modified when applied to original. +// Including: +// - Adding fields to the patch present in modified, missing from original +// - Setting fields to the patch present in modified and original with different values +// - Delete fields present in original, missing from modified through +// - IFF map field - set to nil in patch +// - IFF list of maps && merge strategy - use deleteDirective for the elements +// - IFF list of primitives && merge strategy - use parallel deletion list +// - IFF list of maps or primitives with replace strategy (default) - set patch value to the value in modified +// - Build $retainKeys directive for fields with retainKeys patch strategy func diffMaps(original, modified map[string]interface{}, t reflect.Type, diffOptions DiffOptions) (map[string]interface{}, error) { patch := map[string]interface{}{} + // Get the underlying type for pointers if t.Kind() == reflect.Ptr { t = t.Elem() } + // This will be used to build the $retainKeys directive sent in the patch + retainKeysList := make([]interface{}, 0, len(modified)) + // Compare each value in the modified map against the value in the original map for key, modifiedValue := range modified { + // Get the underlying type for pointers + if diffOptions.BuildRetainKeysDirective && modifiedValue != nil { + retainKeysList = append(retainKeysList, key) + } + originalValue, ok := original[key] if !ok { // Key was added, so add to patch @@ -144,6 +177,7 @@ func diffMaps(original, modified map[string]interface{}, t reflect.Type, diffOpt } // The patch may have a patch directive + // TODO: figure out if we need this. This shouldn't be needed by apply. When would the original map have patch directives in it? foundDirectiveMarker, err := handleDirectiveMarker(key, originalValue, modifiedValue, patch) if err != nil { return nil, err @@ -177,6 +211,14 @@ func diffMaps(original, modified map[string]interface{}, t reflect.Type, diffOpt } updatePatchIfMissing(original, modified, patch, diffOptions) + // Insert the retainKeysList iff there are values present in the retainKeysList and + // either of the following is true: + // - the patch is not empty + // - there are additional field in original that need to be cleared + if len(retainKeysList) > 0 && + (len(patch) > 0 || hasAdditionalNewField(original, modified)) { + patch[retainKeysDirective] = sortScalars(retainKeysList) + } return patch, nil } @@ -207,7 +249,7 @@ func handleDirectiveMarker(key string, originalValue, modifiedValue interface{}, // diffOptions contains multiple options to control how we do the diff. func handleMapDiff(key string, originalValue, modifiedValue, patch map[string]interface{}, t reflect.Type, diffOptions DiffOptions) error { - fieldType, fieldPatchStrategy, _, err := forkedjson.LookupPatchMetadata(t, key) + fieldType, fieldPatchStrategies, _, err := forkedjson.LookupPatchMetadata(t, key) if err != nil { // We couldn't look up metadata for the field // If the values are identical, this doesn't matter, no patch is needed @@ -217,7 +259,12 @@ func handleMapDiff(key string, originalValue, modifiedValue, patch map[string]in // Otherwise, return the error return err } - switch fieldPatchStrategy { + retainKeys, patchStrategy, err := extractRetainKeysPatchStrategy(fieldPatchStrategies) + if err != nil { + return err + } + diffOptions.BuildRetainKeysDirective = retainKeys + switch patchStrategy { // The patch strategic from metadata tells us to replace the entire object instead of diffing it case replaceDirective: if !diffOptions.IgnoreChangesAndAdditions { @@ -244,7 +291,7 @@ func handleMapDiff(key string, originalValue, modifiedValue, patch map[string]in // diffOptions contains multiple options to control how we do the diff. func handleSliceDiff(key string, originalValue, modifiedValue []interface{}, patch map[string]interface{}, t reflect.Type, diffOptions DiffOptions) error { - fieldType, fieldPatchStrategy, fieldPatchMergeKey, err := forkedjson.LookupPatchMetadata(t, key) + fieldType, fieldPatchStrategies, fieldPatchMergeKey, err := forkedjson.LookupPatchMetadata(t, key) if err != nil { // We couldn't look up metadata for the field // If the values are identical, this doesn't matter, no patch is needed @@ -254,11 +301,15 @@ func handleSliceDiff(key string, originalValue, modifiedValue []interface{}, pat // Otherwise, return the error return err } - - switch fieldPatchStrategy { + retainKeys, patchStrategy, err := extractRetainKeysPatchStrategy(fieldPatchStrategies) + if err != nil { + return err + } + switch patchStrategy { // Merge the 2 slices using mergePatchKey case mergeDirective: - addList, deletionList, err := diffLists(originalValue, modifiedValue, fieldType.Elem(), fieldPatchMergeKey, diffOptions) + diffOptions.BuildRetainKeysDirective = retainKeys + addList, deletionList, setOrderList, err := diffLists(originalValue, modifiedValue, fieldType.Elem(), fieldPatchMergeKey, diffOptions) if err != nil { return err } @@ -270,6 +321,10 @@ func handleSliceDiff(key string, originalValue, modifiedValue []interface{}, pat parallelDeletionListKey := fmt.Sprintf("%s/%s", deleteFromPrimitiveListDirectivePrefix, key) patch[parallelDeletionListKey] = deletionList } + if len(setOrderList) > 0 { + parallelSetOrderListKey := fmt.Sprintf("%s/%s", setElementOrderDirectivePrefix, key) + patch[parallelSetOrderListKey] = setOrderList + } default: replacePatchFieldIfNotEqual(key, originalValue, modifiedValue, patch, diffOptions) } @@ -311,44 +366,254 @@ func updatePatchIfMissing(original, modified, patch map[string]interface{}, diff } } -// Returns a (recursive) strategic merge patch and a parallel deletion list if necessary. +// validateMergeKeyInLists checks if each map in the list has the mentryerge key. +func validateMergeKeyInLists(mergeKey string, lists ...[]interface{}) error { + for _, list := range lists { + for _, item := range list { + m, ok := item.(map[string]interface{}) + if !ok { + return mergepatch.ErrBadArgType(m, item) + } + if _, ok = m[mergeKey]; !ok { + return mergepatch.ErrNoMergeKey(m, mergeKey) + } + } + } + return nil +} + +// normalizeElementOrder sort `patch` list by `patchOrder` and sort `serverOnly` list by `serverOrder`. +// Then it merges the 2 sorted lists. +// It guarantee the relative order in the patch list and in the serverOnly list is kept. +// `patch` is a list of items in the patch, and `serverOnly` is a list of items in the live object. +// `patchOrder` is the order we want `patch` list to have and +// `serverOrder` is the order we want `serverOnly` list to have. +// kind is the kind of each item in the lists `patch` and `serverOnly`. +func normalizeElementOrder(patch, serverOnly, patchOrder, serverOrder []interface{}, mergeKey string, kind reflect.Kind) ([]interface{}, error) { + patch, err := normalizeSliceOrder(patch, patchOrder, mergeKey, kind) + if err != nil { + return nil, err + } + serverOnly, err = normalizeSliceOrder(serverOnly, serverOrder, mergeKey, kind) + if err != nil { + return nil, err + } + all := mergeSortedSlice(serverOnly, patch, serverOrder, mergeKey, kind) + + return all, nil +} + +// mergeSortedSlice merges the 2 sorted lists by serverOrder with best effort. +// It will insert each item in `left` list to `right` list. In most cases, the 2 lists will be interleaved. +// The relative order of left and right are guaranteed to be kept. +// They have higher precedence than the order in the live list. +// The place for a item in `left` is found by: +// scan from the place of last insertion in `right` to the end of `right`, +// the place is before the first item that is greater than the item we want to insert. +// example usage: using server-only items as left and patch items as right. We insert server-only items +// to patch list. We use the order of live object as record for comparision. +func mergeSortedSlice(left, right, serverOrder []interface{}, mergeKey string, kind reflect.Kind) []interface{} { + // Returns if l is less than r, and if both have been found. + // If l and r both present and l is in front of r, l is less than r. + less := func(l, r interface{}) (bool, bool) { + li := index(serverOrder, l, mergeKey, kind) + ri := index(serverOrder, r, mergeKey, kind) + if li >= 0 && ri >= 0 { + return li < ri, true + } else { + return false, false + } + } + + // left and right should be non-overlapping. + size := len(left) + len(right) + i, j := 0, 0 + s := make([]interface{}, size, size) + + for k := 0; k < size; k++ { + if i >= len(left) && j < len(right) { + // have items left in `right` list + s[k] = right[j] + j++ + } else if j >= len(right) && i < len(left) { + // have items left in `left` list + s[k] = left[i] + i++ + } else { + // compare them if i and j are both in bound + less, foundBoth := less(left[i], right[j]) + if foundBoth && less { + s[k] = left[i] + i++ + } else { + s[k] = right[j] + j++ + } + } + } + return s +} + +// index returns the index of the item in the given items, or -1 if it doesn't exist +// l must NOT be a slice of slices, this should be checked before calling. +func index(l []interface{}, valToLookUp interface{}, mergeKey string, kind reflect.Kind) int { + var getValFn func(interface{}) interface{} + // Get the correct `getValFn` based on item `kind`. + // It should return the value of merge key for maps and + // return the item for other kinds. + switch kind { + case reflect.Map: + getValFn = func(item interface{}) interface{} { + typedItem, ok := item.(map[string]interface{}) + if !ok { + return nil + } + val := typedItem[mergeKey] + return val + } + default: + getValFn = func(item interface{}) interface{} { + return item + } + } + + for i, v := range l { + if getValFn(valToLookUp) == getValFn(v) { + return i + } + } + return -1 +} + +// extractToDeleteItems takes a list and +// returns 2 lists: one contains items that should be kept and the other contains items to be deleted. +func extractToDeleteItems(l []interface{}) ([]interface{}, []interface{}, error) { + var nonDelete, toDelete []interface{} + for _, v := range l { + m, ok := v.(map[string]interface{}) + if !ok { + return nil, nil, mergepatch.ErrBadArgType(m, v) + } + + directive, foundDirective := m[directiveMarker] + if foundDirective && directive == deleteDirective { + toDelete = append(toDelete, v) + } else { + nonDelete = append(nonDelete, v) + } + } + return nonDelete, toDelete, nil +} + +// normalizeSliceOrder sort `toSort` list by `order` +func normalizeSliceOrder(toSort, order []interface{}, mergeKey string, kind reflect.Kind) ([]interface{}, error) { + var toDelete []interface{} + if kind == reflect.Map { + // make sure each item in toSort, order has merge key + err := validateMergeKeyInLists(mergeKey, toSort, order) + if err != nil { + return nil, err + } + toSort, toDelete, err = extractToDeleteItems(toSort) + } + + sort.SliceStable(toSort, func(i, j int) bool { + if ii := index(order, toSort[i], mergeKey, kind); ii >= 0 { + if ij := index(order, toSort[j], mergeKey, kind); ij >= 0 { + return ii < ij + } + } + return true + }) + toSort = append(toSort, toDelete...) + return toSort, nil +} + +// Returns a (recursive) strategic merge patch, a parallel deletion list if necessary and +// another list to set the order of the list // Only list of primitives with merge strategy will generate a parallel deletion list. // These two lists should yield modified when applied to original, for lists with merge semantics. -func diffLists(original, modified []interface{}, t reflect.Type, mergeKey string, diffOptions DiffOptions) ([]interface{}, []interface{}, error) { +func diffLists(original, modified []interface{}, t reflect.Type, mergeKey string, diffOptions DiffOptions) ([]interface{}, []interface{}, []interface{}, error) { if len(original) == 0 { // Both slices are empty - do nothing if len(modified) == 0 || diffOptions.IgnoreChangesAndAdditions { - return nil, nil, nil + return nil, nil, nil, nil } // Old slice was empty - add all elements from the new slice - return modified, nil, nil + return modified, nil, nil, nil } elementType, err := sliceElementType(original, modified) if err != nil { - return nil, nil, err + return nil, nil, nil, err } - switch elementType.Kind() { + var patchList, deleteList, setOrderList []interface{} + kind := elementType.Kind() + switch kind { case reflect.Map: - patchList, err := diffListsOfMaps(original, modified, t, mergeKey, diffOptions) - return patchList, nil, err + patchList, deleteList, err = diffListsOfMaps(original, modified, t, mergeKey, diffOptions) + patchList, err = normalizeSliceOrder(patchList, modified, mergeKey, kind) + orderSame, err := isOrderSame(original, modified, mergeKey) + if err != nil { + return nil, nil, nil, err + } + // append the deletions to the end of the patch list. + patchList = append(patchList, deleteList...) + deleteList = nil + // generate the setElementOrder list when there are content changes or order changes + if diffOptions.SetElementOrder && + ((!diffOptions.IgnoreChangesAndAdditions && (len(patchList) > 0 || !orderSame)) || + (!diffOptions.IgnoreDeletions && len(patchList) > 0)) { + // Generate a list of maps that each item contains only the merge key. + setOrderList = make([]interface{}, len(modified)) + for i, v := range modified { + typedV := v.(map[string]interface{}) + setOrderList[i] = map[string]interface{}{ + mergeKey: typedV[mergeKey], + } + } + } case reflect.Slice: // Lists of Lists are not permitted by the api - return nil, nil, mergepatch.ErrNoListOfLists + return nil, nil, nil, mergepatch.ErrNoListOfLists default: - return diffListsOfScalars(original, modified, diffOptions) + patchList, deleteList, err = diffListsOfScalars(original, modified, diffOptions) + patchList, err = normalizeSliceOrder(patchList, modified, mergeKey, kind) + // generate the setElementOrder list when there are content changes or order changes + if diffOptions.SetElementOrder && ((!diffOptions.IgnoreDeletions && len(deleteList) > 0) || + (!diffOptions.IgnoreChangesAndAdditions && !reflect.DeepEqual(original, modified))) { + setOrderList = modified + } + } + return patchList, deleteList, setOrderList, err +} + +// isOrderSame checks if the order in a list has changed +func isOrderSame(original, modified []interface{}, mergeKey string) (bool, error) { + if len(original) != len(modified) { + return false, nil + } + for i, modifiedItem := range modified { + equal, err := mergeKeyValueEqual(original[i], modifiedItem, mergeKey) + if err != nil || !equal { + return equal, err + } } + return true, nil } // diffListsOfScalars returns 2 lists, the first one is addList and the second one is deletionList. // Argument diffOptions.IgnoreChangesAndAdditions controls if calculate addList. true means not calculate. // Argument diffOptions.IgnoreDeletions controls if calculate deletionList. true means not calculate. +// original may be changed, but modified is guaranteed to not be changed func diffListsOfScalars(original, modified []interface{}, diffOptions DiffOptions) ([]interface{}, []interface{}, error) { + modifiedCopy := make([]interface{}, len(modified)) + copy(modifiedCopy, modified) // Sort the scalars for easier calculating the diff originalScalars := sortScalars(original) - modifiedScalars := sortScalars(modified) + modifiedScalars := sortScalars(modifiedCopy) originalIndex, modifiedIndex := 0, 0 addList := []interface{}{} @@ -394,7 +659,7 @@ func diffListsOfScalars(original, modified []interface{}, diffOptions DiffOption } } - return addList, deletionList, nil + return addList, deduplicateScalars(deletionList), nil } // If first return value is non-nil, list1 contains an element not present in list2 @@ -422,18 +687,20 @@ func compareListValuesAtIndex(list1Inbounds, list2Inbounds bool, list1Value, lis } } -// Returns a (recursive) strategic merge patch that yields modified when applied to original, -// for a pair of lists of maps with merge semantics. -func diffListsOfMaps(original, modified []interface{}, t reflect.Type, mergeKey string, diffOptions DiffOptions) ([]interface{}, error) { - patch := make([]interface{}, 0) +// diffListsOfMaps takes a pair of lists and +// returns a (recursive) strategic merge patch list contains additions and changes and +// a deletion list contains deletions +func diffListsOfMaps(original, modified []interface{}, t reflect.Type, mergeKey string, diffOptions DiffOptions) ([]interface{}, []interface{}, error) { + patch := make([]interface{}, 0, len(modified)) + deletionList := make([]interface{}, 0, len(original)) originalSorted, err := sortMergeListsByNameArray(original, t, mergeKey, false) if err != nil { - return nil, err + return nil, nil, err } modifiedSorted, err := sortMergeListsByNameArray(modified, t, mergeKey, false) if err != nil { - return nil, err + return nil, nil, err } originalIndex, modifiedIndex := 0, 0 @@ -451,14 +718,14 @@ func diffListsOfMaps(original, modified []interface{}, t reflect.Type, mergeKey if originalInBounds { originalElement, originalElementMergeKeyValue, err = getMapAndMergeKeyValueByIndex(originalIndex, mergeKey, originalSorted) if err != nil { - return nil, err + return nil, nil, err } originalElementMergeKeyValueString = fmt.Sprintf("%v", originalElementMergeKeyValue) } if modifiedInBounds { modifiedElement, modifiedElementMergeKeyValue, err = getMapAndMergeKeyValueByIndex(modifiedIndex, mergeKey, modifiedSorted) if err != nil { - return nil, err + return nil, nil, err } modifiedElementMergeKeyValueString = fmt.Sprintf("%v", modifiedElementMergeKeyValue) } @@ -468,7 +735,7 @@ func diffListsOfMaps(original, modified []interface{}, t reflect.Type, mergeKey // Merge key values are equal, so recurse patchValue, err := diffMaps(originalElement, modifiedElement, t, diffOptions) if err != nil { - return nil, err + return nil, nil, err } if len(patchValue) > 0 { patchValue[mergeKey] = modifiedElementMergeKeyValue @@ -492,13 +759,13 @@ func diffListsOfMaps(original, modified []interface{}, t reflect.Type, mergeKey case bothInBounds && ItemRemovedFromModifiedSlice(originalElementMergeKeyValueString, modifiedElementMergeKeyValueString): if !diffOptions.IgnoreDeletions { // Item was deleted, so add delete directive - patch = append(patch, CreateDeleteDirective(mergeKey, originalElementMergeKeyValue)) + deletionList = append(deletionList, CreateDeleteDirective(mergeKey, originalElementMergeKeyValue)) } originalIndex++ } } - return patch, nil + return patch, deletionList, nil } // getMapAndMergeKeyValueByIndex return a map in the list and its merge key value given the index of the map. @@ -559,7 +826,7 @@ func StrategicMergeMapPatch(original, patch JSONMap, dataStruct interface{}) (JS return nil, err } mergeOptions := MergeOptions{ - MergeDeleteList: true, + MergeParallelList: true, IgnoreUnmatchedNulls: true, } return mergeMap(original, patch, t, mergeOptions) @@ -571,6 +838,7 @@ func getTagStructType(dataStruct interface{}) (reflect.Type, error) { } t := reflect.TypeOf(dataStruct) + // Get the underlying type for pointers if t.Kind() == reflect.Ptr { t = t.Elem() } @@ -601,6 +869,106 @@ func handleDirectiveInMergeMap(directive interface{}, patch map[string]interface return nil, mergepatch.ErrBadPatchType(directive, patch) } +func containsDirectiveMarker(item interface{}) bool { + m, ok := item.(map[string]interface{}) + if ok { + if _, foundDirectiveMarker := m[directiveMarker]; foundDirectiveMarker { + return true + } + } + return false +} + +func mergeKeyValueEqual(left, right interface{}, mergeKey string) (bool, error) { + if len(mergeKey) == 0 { + return left == right, nil + } + typedLeft, ok := left.(map[string]interface{}) + if !ok { + return false, mergepatch.ErrBadArgType(typedLeft, left) + } + typedRight, ok := right.(map[string]interface{}) + if !ok { + return false, mergepatch.ErrBadArgType(typedRight, right) + } + mergeKeyLeft, ok := typedLeft[mergeKey] + if !ok { + return false, mergepatch.ErrNoMergeKey(typedLeft, mergeKey) + } + mergeKeyRight, ok := typedRight[mergeKey] + if !ok { + return false, mergepatch.ErrNoMergeKey(typedRight, mergeKey) + } + return mergeKeyLeft == mergeKeyRight, nil +} + +// extractKey trims the prefix and return the original key +func extractKey(s, prefix string) (string, error) { + substrings := strings.SplitN(s, "/", 2) + if len(substrings) <= 1 || substrings[0] != prefix { + switch prefix { + case deleteFromPrimitiveListDirectivePrefix: + return "", mergepatch.ErrBadPatchFormatForPrimitiveList + case setElementOrderDirectivePrefix: + return "", mergepatch.ErrBadPatchFormatForSetElementOrderList + default: + return "", fmt.Errorf("fail to find unknown prefix %q in %s\n", prefix, s) + } + } + return substrings[1], nil +} + +// validatePatchUsingSetOrderList verifies: +// the relative order of any two items in the setOrderList list matches that in the patch list. +// the items in the patch list must be a subset or the same as the $setElementOrder list (deletions are ignored). +func validatePatchWithSetOrderList(patchList, setOrderList interface{}, mergeKey string) error { + typedSetOrderList, ok := setOrderList.([]interface{}) + if !ok { + return mergepatch.ErrBadPatchFormatForSetElementOrderList + } + typedPatchList, ok := patchList.([]interface{}) + if !ok { + return mergepatch.ErrBadPatchFormatForSetElementOrderList + } + if len(typedSetOrderList) == 0 || len(typedPatchList) == 0 { + return nil + } + + var nonDeleteList, toDeleteList []interface{} + var err error + if len(mergeKey) > 0 { + nonDeleteList, toDeleteList, err = extractToDeleteItems(typedPatchList) + if err != nil { + return err + } + } else { + nonDeleteList = typedPatchList + } + + patchIndex, setOrderIndex := 0, 0 + for patchIndex < len(nonDeleteList) && setOrderIndex < len(typedSetOrderList) { + if containsDirectiveMarker(nonDeleteList[patchIndex]) { + patchIndex++ + continue + } + mergeKeyEqual, err := mergeKeyValueEqual(nonDeleteList[patchIndex], typedSetOrderList[setOrderIndex], mergeKey) + if err != nil { + return err + } + if mergeKeyEqual { + patchIndex++ + } + setOrderIndex++ + } + // If patchIndex is inbound but setOrderIndex if out of bound mean there are items mismatching between the patch list and setElementOrder list. + // the second check is is a sanity check, and should always be true if the first is true. + if patchIndex < len(nonDeleteList) && setOrderIndex >= len(typedSetOrderList) { + return fmt.Errorf("The order in patch list:\n%v\n doesn't match %s list:\n%v\n", typedPatchList, setElementOrderDirectivePrefix, setOrderList) + } + typedPatchList = append(nonDeleteList, toDeleteList...) + return nil +} + // preprocessDeletionListForMerging preprocesses the deletion list. // it returns shouldContinue, isDeletionList, noPrefixKey func preprocessDeletionListForMerging(key string, original map[string]interface{}, @@ -613,19 +981,247 @@ func preprocessDeletionListForMerging(key string, original map[string]interface{ original[key] = patchVal return true, false, "", nil } - substrings := strings.SplitN(key, "/", 2) - if len(substrings) <= 1 { - return false, false, "", mergepatch.ErrBadPatchFormatForPrimitiveList - } - return false, true, substrings[1], nil + originalKey, err := extractKey(key, deleteFromPrimitiveListDirectivePrefix) + return false, true, originalKey, err } return false, false, "", nil } +// applyRetainKeysDirective looks for a retainKeys directive and applies to original +// - if no directive exists do nothing +// - if directive is found, clear keys in original missing from the directive list +// - validate that all keys present in the patch are present in the retainKeys directive +// note: original may be another patch request, e.g. applying the add+modified patch to the deletions patch. In this case it may have directives +func applyRetainKeysDirective(original, patch map[string]interface{}, options MergeOptions) error { + retainKeysInPatch, foundInPatch := patch[retainKeysDirective] + if !foundInPatch { + return nil + } + // cleanup the directive + delete(patch, retainKeysDirective) + + if !options.MergeParallelList { + // If original is actually a patch, make sure the retainKeys directives are the same in both patches if present in both. + // If not present in the original patch, copy from the modified patch. + retainKeysInOriginal, foundInOriginal := original[retainKeysDirective] + if foundInOriginal { + if !reflect.DeepEqual(retainKeysInOriginal, retainKeysInPatch) { + // This error actually should never happen. + return fmt.Errorf("%v and %v are not deep equal: this may happen when calculating the 3-way diff patch", retainKeysInOriginal, retainKeysInPatch) + } + } else { + original[retainKeysDirective] = retainKeysInPatch + } + return nil + } + + retainKeysList, ok := retainKeysInPatch.([]interface{}) + if !ok { + return mergepatch.ErrBadPatchFormatForRetainKeys + } + + // validate patch to make sure all fields in the patch are present in the retainKeysList. + // The map is used only as a set, the value is never referenced + m := map[interface{}]struct{}{} + for _, v := range retainKeysList { + m[v] = struct{}{} + } + for k, v := range patch { + if v == nil || strings.HasPrefix(k, deleteFromPrimitiveListDirectivePrefix) || + strings.HasPrefix(k, setElementOrderDirectivePrefix) { + continue + } + // If there is an item present in the patch but not in the retainKeys list, + // the patch is invalid. + if _, found := m[k]; !found { + return mergepatch.ErrBadPatchFormatForRetainKeys + } + } + + // clear not present fields + for k := range original { + if _, found := m[k]; !found { + delete(original, k) + } + } + return nil +} + +// mergePatchIntoOriginal processes $setElementOrder list. +// When not merging the directive, it will make sure $setElementOrder list exist only in original. +// When merging the directive, it will try to find the $setElementOrder list and +// its corresponding patch list, validate it and merge it. +// Then, sort them by the relative order in setElementOrder, patch list and live list. +// The precedence is $setElementOrder > order in patch list > order in live list. +// This function will delete the item after merging it to prevent process it again in the future. +// Ref: https://github.com/kubernetes/community/blob/master/contributors/design-proposals/preserve-order-in-strategic-merge-patch.md +func mergePatchIntoOriginal(original, patch map[string]interface{}, t reflect.Type, mergeOptions MergeOptions) error { + for key, patchV := range patch { + // Do nothing if there is no ordering directive + if !strings.HasPrefix(key, setElementOrderDirectivePrefix) { + continue + } + + setElementOrderInPatch := patchV + // Copies directive from the second patch (`patch`) to the first patch (`original`) + // and checks they are equal and delete the directive in the second patch + if !mergeOptions.MergeParallelList { + setElementOrderListInOriginal, ok := original[key] + if ok { + // check if the setElementOrder list in original and the one in patch matches + if !reflect.DeepEqual(setElementOrderListInOriginal, setElementOrderInPatch) { + return mergepatch.ErrBadPatchFormatForSetElementOrderList + } + } else { + // move the setElementOrder list from patch to original + original[key] = setElementOrderInPatch + } + } + delete(patch, key) + + var ( + ok bool + originalFieldValue, patchFieldValue, merged []interface{} + patchStrategy, mergeKey string + patchStrategies []string + fieldType reflect.Type + ) + typedSetElementOrderList, ok := setElementOrderInPatch.([]interface{}) + if !ok { + return mergepatch.ErrBadArgType(typedSetElementOrderList, setElementOrderInPatch) + } + // Trim the setElementOrderDirectivePrefix to get the key of the list field in original. + originalKey, err := extractKey(key, setElementOrderDirectivePrefix) + if err != nil { + return err + } + // try to find the list with `originalKey` in `original` and `modified` and merge them. + originalList, foundOriginal := original[originalKey] + patchList, foundPatch := patch[originalKey] + if foundOriginal { + originalFieldValue, ok = originalList.([]interface{}) + if !ok { + return mergepatch.ErrBadArgType(originalFieldValue, originalList) + } + } + if foundPatch { + patchFieldValue, ok = patchList.([]interface{}) + if !ok { + return mergepatch.ErrBadArgType(patchFieldValue, patchList) + } + } + fieldType, patchStrategies, mergeKey, err = forkedjson.LookupPatchMetadata(t, originalKey) + if err != nil { + return err + } + _, patchStrategy, err = extractRetainKeysPatchStrategy(patchStrategies) + if err != nil { + return err + } + // Check for consistency between the element order list and the field it applies to + err = validatePatchWithSetOrderList(patchFieldValue, typedSetElementOrderList, mergeKey) + if err != nil { + return err + } + + switch { + case foundOriginal && !foundPatch: + // no change to list contents + merged = originalFieldValue + case !foundOriginal && foundPatch: + // list was added + merged = patchFieldValue + case foundOriginal && foundPatch: + merged, err = mergeSliceHandler(originalList, patchList, fieldType, + patchStrategy, mergeKey, false, mergeOptions) + if err != nil { + return err + } + case !foundOriginal && !foundPatch: + return nil + } + + // Split all items into patch items and server-only items and then enforce the order. + var patchItems, serverOnlyItems []interface{} + if len(mergeKey) == 0 { + // Primitives doesn't need merge key to do partitioning. + patchItems, serverOnlyItems = partitionPrimitivesByPresentInList(merged, typedSetElementOrderList) + + } else { + // Maps need merge key to do partitioning. + patchItems, serverOnlyItems, err = partitionMapsByPresentInList(merged, typedSetElementOrderList, mergeKey) + if err != nil { + return err + } + } + + elementType, err := sliceElementType(originalFieldValue, patchFieldValue) + if err != nil { + return err + } + kind := elementType.Kind() + // normalize merged list + // typedSetElementOrderList contains all the relative order in typedPatchList, + // so don't need to use typedPatchList + both, err := normalizeElementOrder(patchItems, serverOnlyItems, typedSetElementOrderList, originalFieldValue, mergeKey, kind) + if err != nil { + return err + } + original[originalKey] = both + // delete patch list from patch to prevent process again in the future + delete(patch, originalKey) + } + return nil +} + +// partitionPrimitivesByPresentInList partitions elements into 2 slices, the first containing items present in partitionBy, the other not. +func partitionPrimitivesByPresentInList(original, partitionBy []interface{}) ([]interface{}, []interface{}) { + patch := make([]interface{}, 0, len(original)) + serverOnly := make([]interface{}, 0, len(original)) + inPatch := map[interface{}]bool{} + for _, v := range partitionBy { + inPatch[v] = true + } + for _, v := range original { + if !inPatch[v] { + serverOnly = append(serverOnly, v) + } else { + patch = append(patch, v) + } + } + return patch, serverOnly +} + +// partitionMapsByPresentInList partitions elements into 2 slices, the first containing items present in partitionBy, the other not. +func partitionMapsByPresentInList(original, partitionBy []interface{}, mergeKey string) ([]interface{}, []interface{}, error) { + patch := make([]interface{}, 0, len(original)) + serverOnly := make([]interface{}, 0, len(original)) + for _, v := range original { + typedV, ok := v.(map[string]interface{}) + if !ok { + return nil, nil, mergepatch.ErrBadArgType(typedV, v) + } + mergeKeyValue, foundMergeKey := typedV[mergeKey] + if !foundMergeKey { + return nil, nil, mergepatch.ErrNoMergeKey(typedV, mergeKey) + } + _, _, found, err := findMapInSliceBasedOnKeyValue(partitionBy, mergeKey, mergeKeyValue) + if err != nil { + return nil, nil, err + } + if !found { + serverOnly = append(serverOnly, v) + } else { + patch = append(patch, v) + } + } + return patch, serverOnly, nil +} + // Merge fields from a patch map into the original map. Note: This may modify // both the original map and the patch because getting a deep copy of a map in // golang is highly non-trivial. -// flag mergeOptions.MergeDeleteList controls if using the parallel list to delete or keeping the list. +// flag mergeOptions.MergeParallelList controls if using the parallel list to delete or keeping the list. // If patch contains any null field (e.g. field_1: null) that is not // present in original, then to propagate it to the end result use // mergeOptions.IgnoreUnmatchedNulls == false. @@ -640,9 +1236,23 @@ func mergeMap(original, patch map[string]interface{}, t reflect.Type, mergeOptio original = map[string]interface{}{} } + err := applyRetainKeysDirective(original, patch, mergeOptions) + if err != nil { + return nil, err + } + + // Process $setElementOrder list and other lists sharing the same key. + // When not merging the directive, it will make sure $setElementOrder list exist only in original. + // When merging the directive, it will process $setElementOrder and its patch list together. + // This function will delete the merged elements from patch so they will not be reprocessed + err = mergePatchIntoOriginal(original, patch, t, mergeOptions) + if err != nil { + return nil, err + } + // Start merging the patch into the original. for k, patchV := range patch { - skipProcessing, isDeleteList, noPrefixKey, err := preprocessDeletionListForMerging(k, original, patchV, mergeOptions.MergeDeleteList) + skipProcessing, isDeleteList, noPrefixKey, err := preprocessDeletionListForMerging(k, original, patchV, mergeOptions.MergeParallelList) if err != nil { return nil, err } @@ -686,16 +1296,21 @@ func mergeMap(original, patch map[string]interface{}, t reflect.Type, mergeOptio } // If they're both maps or lists, recurse into the value. // First find the fieldPatchStrategy and fieldPatchMergeKey. - fieldType, fieldPatchStrategy, fieldPatchMergeKey, err := forkedjson.LookupPatchMetadata(t, k) + fieldType, fieldPatchStrategies, fieldPatchMergeKey, err := forkedjson.LookupPatchMetadata(t, k) if err != nil { return nil, err } + _, patchStrategy, err := extractRetainKeysPatchStrategy(fieldPatchStrategies) + if err != nil { + return nil, err + } + switch originalType.Kind() { case reflect.Map: - original[k], err = mergeMapHandler(original[k], patchV, fieldType, fieldPatchStrategy, mergeOptions) + original[k], err = mergeMapHandler(original[k], patchV, fieldType, patchStrategy, mergeOptions) case reflect.Slice: - original[k], err = mergeSliceHandler(original[k], patchV, fieldType, fieldPatchStrategy, fieldPatchMergeKey, isDeleteList, mergeOptions) + original[k], err = mergeSliceHandler(original[k], patchV, fieldType, patchStrategy, fieldPatchMergeKey, isDeleteList, mergeOptions) default: original[k] = patchV } @@ -753,27 +1368,45 @@ func mergeSlice(original, patch []interface{}, elemType reflect.Type, mergeKey s return nil, err } + var merged []interface{} + kind := t.Kind() // If the elements are not maps, merge the slices of scalars. - if t.Kind() != reflect.Map { - if mergeOptions.MergeDeleteList && isDeleteList { + if kind != reflect.Map { + if mergeOptions.MergeParallelList && isDeleteList { return deleteFromSlice(original, patch), nil } // Maybe in the future add a "concat" mode that doesn't - // uniqify. + // deduplicate. both := append(original, patch...) - return uniqifyScalars(both), nil - } + merged = deduplicateScalars(both) - if mergeKey == "" { - return nil, fmt.Errorf("cannot merge lists without merge key for type %s", elemType.Kind().String()) - } + } else { + if mergeKey == "" { + return nil, fmt.Errorf("cannot merge lists without merge key for type %s", elemType.Kind().String()) + } - original, patch, err = mergeSliceWithSpecialElements(original, patch, mergeKey) - if err != nil { - return nil, err + original, patch, err = mergeSliceWithSpecialElements(original, patch, mergeKey) + if err != nil { + return nil, err + } + + merged, err = mergeSliceWithoutSpecialElements(original, patch, mergeKey, elemType, mergeOptions) + if err != nil { + return nil, err + } } - return mergeSliceWithoutSpecialElements(original, patch, mergeKey, elemType, mergeOptions) + // enforce the order + var patchItems, serverOnlyItems []interface{} + if len(mergeKey) == 0 { + patchItems, serverOnlyItems = partitionPrimitivesByPresentInList(merged, patch) + } else { + patchItems, serverOnlyItems, err = partitionMapsByPresentInList(merged, patch, mergeKey) + if err != nil { + return nil, err + } + } + return normalizeElementOrder(patchItems, serverOnlyItems, patch, original, mergeKey, kind) } // mergeSliceWithSpecialElements handles special elements with directiveMarker @@ -798,7 +1431,7 @@ func mergeSliceWithSpecialElements(original, patch []interface{}, mergeKey strin return nil, nil, err } } else { - return nil, nil, fmt.Errorf("delete patch type with no merge key defined") + return nil, nil, mergepatch.ErrNoMergeKey(typedV, mergeKey) } case replaceDirective: replace = true @@ -869,30 +1502,17 @@ func mergeSliceWithoutSpecialElements(original, patch []interface{}, mergeKey st // deleteFromSlice uses the parallel list to delete the items in a list of scalars func deleteFromSlice(current, toDelete []interface{}) []interface{} { - currentScalars := uniqifyAndSortScalars(current) - toDeleteScalars := uniqifyAndSortScalars(toDelete) - - currentIndex, toDeleteIndex := 0, 0 - mergedList := []interface{}{} - - for currentIndex < len(currentScalars) && toDeleteIndex < len(toDeleteScalars) { - originalString := fmt.Sprintf("%v", currentScalars[currentIndex]) - modifiedString := fmt.Sprintf("%v", toDeleteScalars[toDeleteIndex]) - - switch { - // found an item to delete - case originalString == modifiedString: - currentIndex++ - // Request to delete an item that was not found in the current list - case originalString > modifiedString: - toDeleteIndex++ - // Found an item that was not part of the deletion list, keep it - case originalString < modifiedString: - mergedList = append(mergedList, currentScalars[currentIndex]) - currentIndex++ + toDeleteMap := map[interface{}]interface{}{} + processed := make([]interface{}, 0, len(current)) + for _, v := range toDelete { + toDeleteMap[v] = true + } + for _, v := range current { + if _, found := toDeleteMap[v]; !found { + processed = append(processed, v) } } - return append(mergedList, currentScalars[currentIndex:]...) + return processed } // This method no longer panics if any element of the slice is not a map. @@ -935,14 +1555,29 @@ func sortMergeListsByName(mapJSON []byte, dataStruct interface{}) ([]byte, error func sortMergeListsByNameMap(s map[string]interface{}, t reflect.Type) (map[string]interface{}, error) { newS := map[string]interface{}{} for k, v := range s { - if strings.HasPrefix(k, deleteFromPrimitiveListDirectivePrefix) { + if k == retainKeysDirective { + typedV, ok := v.([]interface{}) + if !ok { + return nil, mergepatch.ErrBadPatchFormatForRetainKeys + } + v = sortScalars(typedV) + } else if strings.HasPrefix(k, deleteFromPrimitiveListDirectivePrefix) { typedV, ok := v.([]interface{}) if !ok { return nil, mergepatch.ErrBadPatchFormatForPrimitiveList } - v = uniqifyAndSortScalars(typedV) + v = sortScalars(typedV) + } else if strings.HasPrefix(k, setElementOrderDirectivePrefix) { + _, ok := v.([]interface{}) + if !ok { + return nil, mergepatch.ErrBadPatchFormatForSetElementOrderList + } } else if k != directiveMarker { - fieldType, fieldPatchStrategy, fieldPatchMergeKey, err := forkedjson.LookupPatchMetadata(t, k) + fieldType, fieldPatchStrategies, fieldPatchMergeKey, err := forkedjson.LookupPatchMetadata(t, k) + if err != nil { + return nil, err + } + _, patchStrategy, err := extractRetainKeysPatchStrategy(fieldPatchStrategies) if err != nil { return nil, err } @@ -955,7 +1590,7 @@ func sortMergeListsByNameMap(s map[string]interface{}, t reflect.Type) (map[stri return nil, err } } else if typedV, ok := v.([]interface{}); ok { - if fieldPatchStrategy == mergeDirective { + if patchStrategy == mergeDirective { var err error v, err = sortMergeListsByNameArray(typedV, fieldType.Elem(), fieldPatchMergeKey, true) if err != nil { @@ -986,7 +1621,7 @@ func sortMergeListsByNameArray(s []interface{}, elemType reflect.Type, mergeKey // If the elements are not maps... if t.Kind() != reflect.Map { // Sort the elements, because they may have been merged out of order. - return uniqifyAndSortScalars(s), nil + return deduplicateAndSortScalars(s), nil } // Elements are maps - if one of the keys of the map is a map or a @@ -1059,8 +1694,8 @@ func (ss SortableSliceOfMaps) Swap(i, j int) { ss.s[j] = tmp } -func uniqifyAndSortScalars(s []interface{}) []interface{} { - s = uniqifyScalars(s) +func deduplicateAndSortScalars(s []interface{}) []interface{} { + s = deduplicateScalars(s) return sortScalars(s) } @@ -1070,8 +1705,8 @@ func sortScalars(s []interface{}) []interface{} { return ss.s } -func uniqifyScalars(s []interface{}) []interface{} { - // Clever algorithm to uniqify. +func deduplicateScalars(s []interface{}) []interface{} { + // Clever algorithm to deduplicate. length := len(s) - 1 for i := 0; i < length; i++ { for j := i + 1; j <= length; j++ { @@ -1201,15 +1836,19 @@ func mergingMapFieldsHaveConflicts( func mapsHaveConflicts(typedLeft, typedRight map[string]interface{}, structType reflect.Type) (bool, error) { for key, leftValue := range typedLeft { - if key != directiveMarker { + if key != directiveMarker && key != retainKeysDirective { if rightValue, ok := typedRight[key]; ok { - fieldType, fieldPatchStrategy, fieldPatchMergeKey, err := forkedjson.LookupPatchMetadata(structType, key) + fieldType, fieldPatchStrategies, fieldPatchMergeKey, err := forkedjson.LookupPatchMetadata(structType, key) + if err != nil { + return true, err + } + _, patchStrategy, err := extractRetainKeysPatchStrategy(fieldPatchStrategies) if err != nil { return true, err } if hasConflicts, err := mergingMapFieldsHaveConflicts(leftValue, rightValue, - fieldType, fieldPatchStrategy, fieldPatchMergeKey); hasConflicts { + fieldType, patchStrategy, fieldPatchMergeKey); hasConflicts { return true, err } } @@ -1259,8 +1898,8 @@ func slicesHaveConflicts( // Sort scalar slices to prevent ordering issues // We have no way to sort non-merging lists of maps if elementType.Kind() != reflect.Map { - typedLeft = uniqifyAndSortScalars(typedLeft) - typedRight = uniqifyAndSortScalars(typedRight) + typedLeft = deduplicateAndSortScalars(typedLeft) + typedRight = deduplicateAndSortScalars(typedRight) } // Compare the slices element by element in order @@ -1348,26 +1987,23 @@ func CreateThreeWayMergePatch(original, modified, current []byte, dataStruct int // original to modified, and delta, which is the difference from current to modified without // deletions, and then apply delta to deletions as a patch, which should be strictly additive. deltaMapDiffOptions := DiffOptions{ - IgnoreChangesAndAdditions: false, - IgnoreDeletions: true, + IgnoreDeletions: true, + SetElementOrder: true, } deltaMap, err := diffMaps(currentMap, modifiedMap, t, deltaMapDiffOptions) if err != nil { return nil, err } deletionsMapDiffOptions := DiffOptions{ + SetElementOrder: true, IgnoreChangesAndAdditions: true, - IgnoreDeletions: false, } deletionsMap, err := diffMaps(originalMap, modifiedMap, t, deletionsMapDiffOptions) if err != nil { return nil, err } - mergeOptions := MergeOptions{ - MergeDeleteList: false, - IgnoreUnmatchedNulls: false, - } + mergeOptions := MergeOptions{} patchMap, err := mergeMap(deletionsMap, deltaMap, t, mergeOptions) if err != nil { return nil, err @@ -1383,10 +2019,7 @@ func CreateThreeWayMergePatch(original, modified, current []byte, dataStruct int // If overwrite is false, and the patch contains any keys that were changed differently, // then return a conflict error. if !overwrite { - changeMapDiffOptions := DiffOptions{ - IgnoreChangesAndAdditions: false, - IgnoreDeletions: false, - } + changeMapDiffOptions := DiffOptions{} changedMap, err := diffMaps(originalMap, currentMap, t, changeMapDiffOptions) if err != nil { return nil, err @@ -1438,3 +2071,45 @@ func sliceTypeAssertion(original, patch interface{}) ([]interface{}, []interface } return typedOriginal, typedPatch, nil } + +// extractRetainKeysPatchStrategy process patch strategy, which is a string may contains multiple +// patch strategies seperated by ",". It returns a boolean var indicating if it has +// retainKeys strategies and a string for the other strategy. +func extractRetainKeysPatchStrategy(strategies []string) (bool, string, error) { + switch len(strategies) { + case 0: + return false, "", nil + case 1: + singleStrategy := strategies[0] + switch singleStrategy { + case retainKeysStrategy: + return true, "", nil + default: + return false, singleStrategy, nil + } + case 2: + switch { + case strategies[0] == retainKeysStrategy: + return true, strategies[1], nil + case strategies[1] == retainKeysStrategy: + return true, strategies[0], nil + default: + return false, "", fmt.Errorf("unexpected patch strategy: %v", strategies) + } + default: + return false, "", fmt.Errorf("unexpected patch strategy: %v", strategies) + } +} + +// hasAdditionalNewField returns if original map has additional key with non-nil value than modified. +func hasAdditionalNewField(original, modified map[string]interface{}) bool { + for k, v := range original { + if v == nil { + continue + } + if _, found := modified[k]; !found { + return true + } + } + return false +} diff --git a/staging/src/k8s.io/apimachinery/pkg/util/strategicpatch/patch_test.go b/staging/src/k8s.io/apimachinery/pkg/util/strategicpatch/patch_test.go index 04066a48b90d2..507c8cffa17ef 100644 --- a/staging/src/k8s.io/apimachinery/pkg/util/strategicpatch/patch_test.go +++ b/staging/src/k8s.io/apimachinery/pkg/util/strategicpatch/patch_test.go @@ -75,26 +75,39 @@ type StrategicMergePatchTestCaseData struct { // The meaning of each field is the same as StrategicMergePatchTestCaseData's. // The difference is that all the fields in StrategicMergePatchRawTestCaseData are json-encoded data. type StrategicMergePatchRawTestCaseData struct { - Original []byte - Modified []byte - Current []byte - TwoWay []byte - ThreeWay []byte - Result []byte - TwoWayResult []byte + Original []byte + Modified []byte + Current []byte + TwoWay []byte + ThreeWay []byte + Result []byte + TwoWayResult []byte + ExpectedError string } type MergeItem struct { - Name string - Value string - Other string - MergingList []MergeItem `patchStrategy:"merge" patchMergeKey:"name"` - NonMergingList []MergeItem - MergingIntList []int `patchStrategy:"merge"` - NonMergingIntList []int - MergeItemPtr *MergeItem `patchStrategy:"merge" patchMergeKey:"name"` - SimpleMap map[string]string - ReplacingItem runtime.RawExtension `patchStrategy:"replace"` + Name string + Value string + Other string + MergingList []MergeItem `patchStrategy:"merge" patchMergeKey:"name"` + NonMergingList []MergeItem + MergingIntList []int `patchStrategy:"merge"` + NonMergingIntList []int + MergeItemPtr *MergeItem `patchStrategy:"merge" patchMergeKey:"name"` + SimpleMap map[string]string + ReplacingItem runtime.RawExtension `patchStrategy:"replace"` + RetainKeysMap RetainKeysMergeItem `patchStrategy:"retainKeys"` + RetainKeysMergingList []MergeItem `patchStrategy:"merge,retainKeys" patchMergeKey:"name"` +} + +type RetainKeysMergeItem struct { + Name string + Value string + Other string + SimpleMap map[string]string + MergingIntList []int `patchStrategy:"merge"` + MergingList []MergeItem `patchStrategy:"merge" patchMergeKey:"name"` + NonMergingList []MergeItem } var mergeItem MergeItem @@ -276,8 +289,11 @@ func TestSortMergeLists(t *testing.T) { } // These are test cases for StrategicMergePatch that cannot be generated using -// CreateTwoWayMergePatch because it doesn't use the replace directive, generate -// duplicate integers for a merging list patch, or generate empty merging lists. +// CreateTwoWayMergePatch because it may be one of the following cases: +// - not use the replace directive. +// - generate duplicate integers for a merging list patch. +// - generate empty merging lists. +// - use patch format from an old client. var customStrategicMergePatchTestCaseData = []byte(` testCases: - description: unique scalars when merging lists @@ -357,8 +373,268 @@ testCases: mergingList: - name: 2 value: a + - description: retainKeys map can add a field when no retainKeys directive present + original: + retainKeysMap: + name: foo + twoWay: + retainKeysMap: + value: bar + modified: + retainKeysMap: + name: foo + value: bar + - description: retainKeys map can change a field when no retainKeys directive present + original: + retainKeysMap: + name: foo + value: a + twoWay: + retainKeysMap: + value: b + modified: + retainKeysMap: + name: foo + value: b + - description: retainKeys map can delete a field when no retainKeys directive present + original: + retainKeysMap: + name: foo + value: a + twoWay: + retainKeysMap: + value: null + modified: + retainKeysMap: + name: foo + - description: retainKeys map merge an empty map + original: + retainKeysMap: + name: foo + value: a + twoWay: + retainKeysMap: {} + modified: + retainKeysMap: + name: foo + value: a + - description: retainKeys list can add a field when no retainKeys directive present + original: + retainKeysMergingList: + - name: bar + - name: foo + twoWay: + retainKeysMergingList: + - name: foo + value: a + modified: + retainKeysMergingList: + - name: bar + - name: foo + value: a + - description: retainKeys list can change a field when no retainKeys directive present + original: + retainKeysMergingList: + - name: bar + - name: foo + value: a + twoWay: + retainKeysMergingList: + - name: foo + value: b + modified: + retainKeysMergingList: + - name: bar + - name: foo + value: b + - description: retainKeys list can delete a field when no retainKeys directive present + original: + retainKeysMergingList: + - name: bar + - name: foo + value: a + twoWay: + retainKeysMergingList: + - name: foo + value: null + modified: + retainKeysMergingList: + - name: bar + - name: foo + - description: preserve the order from the patch in a merging list + original: + mergingList: + - name: 1 + - name: 2 + value: b + - name: 3 + twoWay: + mergingList: + - name: 3 + value: c + - name: 1 + value: a + - name: 2 + other: x + modified: + mergingList: + - name: 3 + value: c + - name: 1 + value: a + - name: 2 + value: b + other: x + - description: preserve the order from the patch in a merging list 2 + original: + mergingList: + - name: 1 + - name: 2 + value: b + - name: 3 + twoWay: + mergingList: + - name: 3 + value: c + - name: 1 + value: a + modified: + mergingList: + - name: 2 + value: b + - name: 3 + value: c + - name: 1 + value: a + - description: preserve the order from the patch in a merging int list + original: + mergingIntList: + - 1 + - 2 + - 3 + twoWay: + mergingIntList: + - 3 + - 1 + - 2 + modified: + mergingIntList: + - 3 + - 1 + - 2 + - description: preserve the order from the patch in a merging int list + original: + mergingIntList: + - 1 + - 2 + - 3 + twoWay: + mergingIntList: + - 3 + - 1 + modified: + mergingIntList: + - 2 + - 3 + - 1 `) +var customStrategicMergePatchRawTestCases = []StrategicMergePatchRawTestCase{ + { + Description: "$setElementOrder contains item that is not present in the list to be merged", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 3 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 3 + - name: 2 + - name: 1 +mergingList: + - name: 3 + value: 3 + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 3 + value: 3 + - name: 1 + value: 1 +`), + }, + }, + { + Description: "$setElementOrder contains item that is not present in the int list to be merged", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 3 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 3 + - 2 + - 1 +`), + Modified: []byte(` +mergingIntList: + - 3 + - 1 +`), + }, + }, + { + Description: "should check if order in $setElementOrder and patch list match", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 3 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 + - name: 3 +mergingList: + - name: 3 + value: 3 + - name: 1 + value: 1 +`), + ExpectedError: "doesn't match", + }, + }, + { + Description: "$setElementOrder contains item that is not present in the int list to be merged", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 3 + - 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 1 + - 2 + - 3 +mergingIntList: + - 3 + - 1 +`), + ExpectedError: "doesn't match", + }, + }, +} + func TestCustomStrategicMergePatch(t *testing.T) { tc := StrategicMergePatchTestCases{} err := yaml.Unmarshal(customStrategicMergePatchTestCaseData, &tc) @@ -369,7 +645,12 @@ func TestCustomStrategicMergePatch(t *testing.T) { for _, c := range tc.TestCases { original, expectedTwoWayPatch, _, expectedResult := twoWayTestCaseToJSONOrFail(t, c) - testPatchApplication(t, original, expectedTwoWayPatch, expectedResult, c.Description) + testPatchApplication(t, original, expectedTwoWayPatch, expectedResult, c.Description, "") + } + + for _, c := range customStrategicMergePatchRawTestCases { + original, expectedTwoWayPatch, _, expectedResult := twoWayRawTestCaseToJSONOrFail(t, c) + testPatchApplication(t, original, expectedTwoWayPatch, expectedResult, c.Description, c.ExpectedError) } } @@ -648,1345 +929,5043 @@ testCases: nonMergingIntList: - 2 - 3 - - description: merge lists of scalars - original: - mergingIntList: - - 1 - - 2 - twoWay: - mergingIntList: - - 3 - modified: - mergingIntList: - - 1 - - 2 - - 3 - current: - mergingIntList: - - 1 - - 2 - - 4 - threeWay: - mergingIntList: - - 3 - result: - mergingIntList: - - 1 - - 2 - - 3 - - 4 - - description: merge lists of maps + - description: delete all maps from merging list original: mergingList: - name: 1 - name: 2 - value: 2 twoWay: mergingList: - - name: 3 - value: 3 - - name: 4 - value: 4 - modified: - mergingList: - - name: 4 - value: 4 - name: 1 + $patch: delete - name: 2 - value: 2 - - name: 3 - value: 3 + $patch: delete + modified: + mergingList: [] current: mergingList: - name: 1 - other: a - name: 2 - value: 2 - other: b threeWay: - mergingList: - - name: 3 - value: 3 - - name: 4 - value: 4 - result: mergingList: - name: 1 - other: a + $patch: delete - name: 2 - value: 2 - other: b - - name: 3 - value: 3 - - name: 4 - value: 4 - - description: merge lists of maps with conflict + $patch: delete + result: + mergingList: [] + - description: delete all maps from merging list with conflict original: mergingList: - name: 1 - name: 2 - value: 2 twoWay: - mergingList: - - name: 3 - value: 3 - modified: mergingList: - name: 1 + $patch: delete - name: 2 - value: 2 - - name: 3 - value: 3 + $patch: delete + modified: + mergingList: [] current: mergingList: - name: 1 other: a - name: 2 - value: 3 other: b threeWay: - mergingList: - - name: 2 - value: 2 - - name: 3 - value: 3 - result: mergingList: - name: 1 - other: a + $patch: delete - name: 2 - value: 2 - other: b - - name: 3 - value: 3 - - description: add field to map in merging list + $patch: delete + result: + mergingList: [] + - description: delete all maps from empty merging list original: mergingList: - name: 1 - name: 2 - value: 2 twoWay: mergingList: - name: 1 - value: 1 - modified: - mergingList: - - name: 1 - value: 1 + $patch: delete - name: 2 - value: 2 + $patch: delete + modified: + mergingList: [] current: - mergingList: - - name: 1 - other: a - - name: 2 - value: 2 - other: b + mergingList: [] threeWay: mergingList: - name: 1 - value: 1 - result: - mergingList: - - name: 1 - value: 1 - other: a + $patch: delete - name: 2 - value: 2 - other: b - - description: add field to map in merging list with conflict + $patch: delete + result: + mergingList: [] + - description: merge empty merging lists original: - mergingList: - - name: 1 - - name: 2 - value: 2 + mergingList: [] twoWay: - mergingList: - - name: 1 - value: 1 - modified: - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - current: - mergingList: - - name: 1 - other: a - - name: 3 - value: 2 - other: b - threeWay: - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - result: - mergingList: - - name: 1 - value: 1 - other: a - - name: 2 - value: 2 - - name: 3 - value: 2 - other: b - - description: add duplicate field to map in merging list - original: - mergingList: - - name: 1 - - name: 2 - value: 2 - twoWay: - mergingList: - - name: 1 - value: 1 + {} modified: - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 + mergingList: [] current: - mergingList: - - name: 1 - value: 1 - other: a - - name: 2 - value: 2 - other: b + mergingList: [] threeWay: {} result: - mergingList: - - name: 1 - value: 1 - other: a - - name: 2 - value: 2 - other: b - - description: add duplicate field to map in merging list with conflict + mergingList: [] + - description: defined null values should propagate overwrite current fields (with conflict) original: - mergingList: - - name: 1 - - name: 2 - value: 2 + name: 2 twoWay: - mergingList: - - name: 1 - value: 1 + name: 1 + value: 1 + other: null + twoWayResult: + name: 1 + value: 1 modified: - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 + name: 1 + value: 1 + other: null current: - mergingList: - - name: 1 - value: 1 - other: a - - name: 2 - value: 3 - other: b + name: a + other: a threeWay: - mergingList: - - name: 2 - value: 2 + name: 1 + value: 1 + other: null result: - mergingList: - - name: 1 - value: 1 - other: a - - name: 2 - value: 2 - other: b - - description: replace map field value in merging list + name: 1 + value: 1 + - description: defined null values should propagate removing original fields original: - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - twoWay: - mergingList: - - name: 1 - value: a - modified: - mergingList: - - name: 1 - value: a - - name: 2 - value: 2 + name: original-name + value: original-value current: - mergingList: - - name: 1 - value: 1 - other: a - - name: 2 - value: 2 - other: b - threeWay: - mergingList: - - name: 1 - value: a - result: - mergingList: - - name: 1 - value: a - other: a - - name: 2 - value: 2 - other: b - - description: replace map field value in merging list with conflict - original: - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - twoWay: - mergingList: - - name: 1 - value: a + name: original-name + value: original-value + other: current-other modified: - mergingList: - - name: 1 - value: a - - name: 2 - value: 2 - current: - mergingList: - - name: 1 - value: 3 - other: a - - name: 2 - value: 2 - other: b - threeWay: - mergingList: - - name: 1 - value: a - result: - mergingList: - - name: 1 - value: a - other: a - - name: 2 - value: 2 - other: b - - description: delete map from merging list - original: - mergingList: - - name: 1 - - name: 2 + name: modified-name + value: null twoWay: - mergingList: - - name: 1 - $patch: delete - modified: - mergingList: - - name: 2 - current: - mergingList: - - name: 1 - - name: 2 - other: b + name: modified-name + value: null + twoWayResult: + name: modified-name threeWay: - mergingList: - - name: 1 - $patch: delete + name: modified-name + value: null result: - mergingList: - - name: 2 - other: b - - description: delete map from merging list with conflict + name: modified-name + other: current-other + - description: nil patch with retainKeys map original: - mergingList: - - name: 1 - - name: 2 - twoWay: - mergingList: - - name: 1 - $patch: delete - modified: - mergingList: - - name: 2 + name: a + retainKeysMap: + name: foo current: - mergingList: - - name: 1 - other: a - - name: 2 - other: b - threeWay: - mergingList: - - name: 1 - $patch: delete - result: - mergingList: - - name: 2 - other: b - - description: delete missing map from merging list - original: - mergingList: - - name: 1 - - name: 2 - twoWay: - mergingList: - - name: 1 - $patch: delete + name: a + value: b + retainKeysMap: + name: foo modified: - mergingList: - - name: 2 - current: - mergingList: - - name: 2 - other: b - threeWay: - mergingList: - - name: 1 - $patch: delete + name: a + retainKeysMap: + name: foo + twoWay: {} + threeWay: {} result: - mergingList: - - name: 2 - other: b - - description: delete missing map from merging list with conflict + name: a + value: b + retainKeysMap: + name: foo + - description: retainKeys map with no change should not be present original: - mergingList: - - name: 1 - - name: 2 - twoWay: - mergingList: - - name: 1 - $patch: delete - modified: - mergingList: - - name: 2 + name: a + retainKeysMap: + name: foo current: - mergingList: - - name: 3 - other: a + name: a + other: c + retainKeysMap: + name: foo + modified: + name: a + value: b + retainKeysMap: + name: foo + twoWay: + value: b threeWay: - mergingList: - - name: 1 - $patch: delete - - name: 2 + value: b result: - mergingList: - - name: 2 - - name: 3 - other: a - - description: add map and delete map from merging list - original: - merginglist: - - name: 1 - - name: 2 - twoWay: - merginglist: - - name: 1 - $patch: delete - - name: 3 - modified: - merginglist: - - name: 2 - - name: 3 - current: - merginglist: - - name: 1 - - name: 2 - other: b - - name: 4 - other: c - threeWay: - merginglist: - - name: 1 - $patch: delete - - name: 3 - result: - merginglist: - - name: 2 - other: b - - name: 3 - - name: 4 - other: c - - description: add map and delete map from merging list with conflict - original: - merginglist: - - name: 1 - - name: 2 - twoWay: - merginglist: - - name: 1 - $patch: delete - - name: 3 - modified: - merginglist: - - name: 2 - - name: 3 - current: - merginglist: - - name: 1 - other: a - - name: 4 - other: c - threeWay: - merginglist: - - name: 1 - $patch: delete - - name: 2 - - name: 3 - result: - merginglist: - - name: 2 - - name: 3 - - name: 4 - other: c - - description: delete all maps from merging list - original: - mergingList: - - name: 1 - - name: 2 - twoWay: - mergingList: - - name: 1 - $patch: delete - - name: 2 - $patch: delete - modified: - mergingList: [] - current: - mergingList: - - name: 1 - - name: 2 - threeWay: - mergingList: - - name: 1 - $patch: delete - - name: 2 - $patch: delete - result: - mergingList: [] - - description: delete all maps from merging list with conflict - original: - mergingList: - - name: 1 - - name: 2 - twoWay: - mergingList: - - name: 1 - $patch: delete - - name: 2 - $patch: delete - modified: - mergingList: [] - current: - mergingList: - - name: 1 - other: a - - name: 2 - other: b - threeWay: - mergingList: - - name: 1 - $patch: delete - - name: 2 - $patch: delete - result: - mergingList: [] - - description: delete all maps from empty merging list - original: - mergingList: - - name: 1 - - name: 2 - twoWay: - mergingList: - - name: 1 - $patch: delete - - name: 2 - $patch: delete - modified: - mergingList: [] - current: - mergingList: [] - threeWay: - mergingList: - - name: 1 - $patch: delete - - name: 2 - $patch: delete - result: - mergingList: [] - - description: delete field from map in merging list - original: - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - twoWay: - mergingList: - - name: 1 - value: null - modified: - mergingList: - - name: 1 - - name: 2 - value: 2 - current: - mergingList: - - name: 1 - value: 1 - other: a - - name: 2 - value: 2 - other: b - threeWay: - mergingList: - - name: 1 - value: null - result: - mergingList: - - name: 1 - other: a - - name: 2 - value: 2 - other: b - - description: delete field from map in merging list with conflict - original: - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - twoWay: - mergingList: - - name: 1 - value: null - modified: - mergingList: - - name: 1 - - name: 2 - value: 2 - current: - mergingList: - - name: 1 - value: a - other: a - - name: 2 - value: 2 - threeWay: - mergingList: - - name: 1 - value: null - result: - mergingList: - - name: 1 - other: a - - name: 2 - value: 2 - - description: delete missing field from map in merging list - original: - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - twoWay: - mergingList: - - name: 1 - value: null - modified: - mergingList: - - name: 1 - - name: 2 - value: 2 - current: - mergingList: - - name: 1 - other: a - - name: 2 - value: 2 - other: b - threeWay: - mergingList: - - name: 1 - value: null - result: - mergingList: - - name: 1 - other: a - - name: 2 - value: 2 - other: b - - description: delete missing field from map in merging list with conflict - original: - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - twoWay: - mergingList: - - name: 1 - value: null - modified: - mergingList: - - name: 1 - - name: 2 - value: 2 - current: - mergingList: - - name: 1 - other: a - - name: 2 - other: b - threeWay: - mergingList: - - name: 1 - value: null - - name: 2 - value: 2 - result: - mergingList: - - name: 1 - other: a - - name: 2 - value: 2 - other: b - - description: replace non merging list nested in merging list - original: - mergingList: - - name: 1 - nonMergingList: - - name: 1 - - name: 2 - value: 2 - - name: 2 - twoWay: - mergingList: - - name: 1 - nonMergingList: - - name: 1 - value: 1 - modified: - mergingList: - - name: 1 - nonMergingList: - - name: 1 - value: 1 - - name: 2 - current: - mergingList: - - name: 1 - other: a - nonMergingList: - - name: 1 - - name: 2 - value: 2 - - name: 2 - other: b - threeWay: - mergingList: - - name: 1 - nonMergingList: - - name: 1 - value: 1 - result: - mergingList: - - name: 1 - other: a - nonMergingList: - - name: 1 - value: 1 - - name: 2 - other: b - - description: replace non merging list nested in merging list with value conflict - original: - mergingList: - - name: 1 - nonMergingList: - - name: 1 - - name: 2 - value: 2 - - name: 2 - twoWay: - mergingList: - - name: 1 - nonMergingList: - - name: 1 - value: 1 - modified: - mergingList: - - name: 1 - nonMergingList: - - name: 1 - value: 1 - - name: 2 - current: - mergingList: - - name: 1 - other: a - nonMergingList: - - name: 1 - value: c - - name: 2 - other: b - threeWay: - mergingList: - - name: 1 - nonMergingList: - - name: 1 - value: 1 - result: - mergingList: - - name: 1 - other: a - nonMergingList: - - name: 1 - value: 1 - - name: 2 - other: b - - description: replace non merging list nested in merging list with deletion conflict - original: - mergingList: - - name: 1 - nonMergingList: - - name: 1 - - name: 2 - value: 2 - - name: 2 - twoWay: - mergingList: - - name: 1 - nonMergingList: - - name: 1 - value: 1 - modified: - mergingList: - - name: 1 - nonMergingList: - - name: 1 - value: 1 - - name: 2 - current: - mergingList: - - name: 1 - other: a - nonMergingList: - - name: 2 - value: 2 - - name: 2 - other: b - threeWay: - mergingList: - - name: 1 - nonMergingList: - - name: 1 - value: 1 - result: - mergingList: - - name: 1 - other: a - nonMergingList: - - name: 1 - value: 1 - - name: 2 - other: b - - description: add field to map in merging list nested in merging list - original: - mergingList: - - name: 1 - mergingList: - - name: 1 - - name: 2 - value: 2 - - name: 2 - twoWay: - mergingList: - - name: 1 - mergingList: - - name: 1 - value: 1 - modified: - mergingList: - - name: 1 - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - - name: 2 - current: - mergingList: - - name: 1 - other: a - mergingList: - - name: 1 - - name: 2 - value: 2 - - name: 2 - other: b - threeWay: - mergingList: - - name: 1 - mergingList: - - name: 1 - value: 1 - result: - mergingList: - - name: 1 - other: a - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - - name: 2 - other: b - - description: add field to map in merging list nested in merging list with value conflict - original: - mergingList: - - name: 1 - mergingList: - - name: 1 - - name: 2 - value: 2 - - name: 2 - twoWay: - mergingList: - - name: 1 - mergingList: - - name: 1 - value: 1 - modified: - mergingList: - - name: 1 - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - - name: 2 - current: - mergingList: - - name: 1 - other: a - mergingList: - - name: 1 - value: a - other: c - - name: 2 - value: b - other: d - - name: 2 - other: b - threeWay: - mergingList: - - name: 1 - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - result: - mergingList: - - name: 1 - other: a - mergingList: - - name: 1 - value: 1 - other: c - - name: 2 - value: 2 - other: d - - name: 2 - other: b - - description: add field to map in merging list nested in merging list with deletion conflict - original: - mergingList: - - name: 1 - mergingList: - - name: 1 - - name: 2 - value: 2 - - name: 2 - twoWay: - mergingList: - - name: 1 - mergingList: - - name: 1 - value: 1 - modified: - mergingList: - - name: 1 - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - - name: 2 - current: - mergingList: - - name: 1 - other: a - mergingList: - - name: 2 - value: 2 - other: d - - name: 2 - other: b - threeWay: - mergingList: - - name: 1 - mergingList: - - name: 1 - value: 1 - result: - mergingList: - - name: 1 - other: a - mergingList: - - name: 1 - value: 1 - - name: 2 - value: 2 - other: d - - name: 2 - other: b - - description: merge empty merging lists - original: - mergingList: [] - twoWay: - {} - modified: - mergingList: [] - current: - mergingList: [] - threeWay: - {} - result: - mergingList: [] - - description: add map to merging list by pointer - original: - mergeItemPtr: - - name: 1 - twoWay: - mergeItemPtr: - - name: 2 - modified: - mergeItemPtr: - - name: 1 - - name: 2 - current: - mergeItemPtr: - - name: 1 - other: a - - name: 3 - threeWay: - mergeItemPtr: - - name: 2 - result: - mergeItemPtr: - - name: 1 - other: a - - name: 2 - - name: 3 - - description: add map to merging list by pointer with conflict - original: - mergeItemPtr: - - name: 1 - twoWay: - mergeItemPtr: - - name: 2 - modified: - mergeItemPtr: - - name: 1 - - name: 2 - current: - mergeItemPtr: - - name: 3 - threeWay: - mergeItemPtr: - - name: 1 - - name: 2 - result: - mergeItemPtr: - - name: 1 - - name: 2 - - name: 3 - - description: add field to map in merging list by pointer - original: - mergeItemPtr: - - name: 1 - mergeItemPtr: - - name: 1 - - name: 2 - value: 2 - - name: 2 - twoWay: - mergeItemPtr: - - name: 1 - mergeItemPtr: - - name: 1 - value: 1 - modified: - mergeItemPtr: - - name: 1 - mergeItemPtr: - - name: 1 - value: 1 - - name: 2 - value: 2 - - name: 2 - current: - mergeItemPtr: - - name: 1 - other: a - mergeItemPtr: - - name: 1 - other: a - - name: 2 - value: 2 - other: b - - name: 2 - other: b - threeWay: - mergeItemPtr: - - name: 1 - mergeItemPtr: - - name: 1 - value: 1 - result: - mergeItemPtr: - - name: 1 - other: a - mergeItemPtr: - - name: 1 - value: 1 - other: a - - name: 2 - value: 2 - other: b - - name: 2 - other: b - - description: add field to map in merging list by pointer with conflict - original: - mergeItemPtr: - - name: 1 - mergeItemPtr: - - name: 1 - - name: 2 - value: 2 - - name: 2 - twoWay: - mergeItemPtr: - - name: 1 - mergeItemPtr: - - name: 1 - value: 1 - modified: - mergeItemPtr: - - name: 1 - mergeItemPtr: - - name: 1 - value: 1 - - name: 2 - value: 2 - - name: 2 - current: - mergeItemPtr: - - name: 1 - other: a - mergeItemPtr: - - name: 1 - value: a - - name: 2 - value: 2 - other: b - - name: 2 - other: b - threeWay: - mergeItemPtr: - - name: 1 - mergeItemPtr: - - name: 1 - value: 1 - result: - mergeItemPtr: - - name: 1 - other: a - mergeItemPtr: - - name: 1 - value: 1 - - name: 2 - value: 2 - other: b - - name: 2 - other: b - - description: defined null values should propagate overwrite current fields (with conflict) - original: - name: 2 - twoWay: - name: 1 - value: 1 - other: null - twoWayResult: - name: 1 - value: 1 - modified: - name: 1 - value: 1 - other: null - current: name: a - other: a - threeWay: - name: 1 - value: 1 - other: null - result: - name: 1 - value: 1 - - description: defined null values should propagate removing original fields - original: - name: original-name - value: original-value - current: - name: original-name - value: original-value - other: current-other - modified: - name: modified-name - value: null - twoWay: - name: modified-name - value: null - twoWayResult: - name: modified-name - threeWay: - name: modified-name - value: null - result: - name: modified-name - other: current-other + value: b + other: c + retainKeysMap: + name: foo `) -var strategicMergePatchRawTestCases = []StrategicMergePatchRawTestCase{ +var strategicMergePatchRawTestCases = []StrategicMergePatchRawTestCase{ + { + Description: "delete items in lists of scalars", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 2 + - 3 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 1 + - 2 +$deleteFromPrimitiveList/mergingIntList: + - 3 +`), + Modified: []byte(` +mergingIntList: + - 1 + - 2 +`), + Current: []byte(` +mergingIntList: + - 1 + - 2 + - 3 + - 4 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: + - 1 + - 2 +$deleteFromPrimitiveList/mergingIntList: + - 3 +`), + Result: []byte(` +mergingIntList: + - 1 + - 2 + - 4 +`), + }, + }, + { + Description: "delete all duplicate items in lists of scalars", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 2 + - 3 + - 3 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 1 + - 2 +$deleteFromPrimitiveList/mergingIntList: + - 3 +`), + Modified: []byte(` +mergingIntList: + - 1 + - 2 +`), + Current: []byte(` +mergingIntList: + - 1 + - 2 + - 3 + - 3 + - 4 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: + - 1 + - 2 +$deleteFromPrimitiveList/mergingIntList: + - 3 +`), + Result: []byte(` +mergingIntList: + - 1 + - 2 + - 4 +`), + }, + }, + { + Description: "add and delete items in lists of scalars", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 2 + - 3 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 1 + - 2 + - 4 +$deleteFromPrimitiveList/mergingIntList: + - 3 +mergingIntList: + - 4 +`), + Modified: []byte(` +mergingIntList: + - 1 + - 2 + - 4 +`), + Current: []byte(` +mergingIntList: + - 1 + - 2 + - 3 + - 4 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: + - 1 + - 2 + - 4 +$deleteFromPrimitiveList/mergingIntList: + - 3 +`), + Result: []byte(` +mergingIntList: + - 1 + - 2 + - 4 +`), + }, + }, + { + Description: "merge lists of maps", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 4 + - name: 1 + - name: 2 + - name: 3 +mergingList: + - name: 4 + value: 4 + - name: 3 + value: 3 +`), + Modified: []byte(` +mergingList: + - name: 4 + value: 4 + - name: 1 + - name: 2 + value: 2 + - name: 3 + value: 3 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 4 + - name: 1 + - name: 2 + - name: 3 +mergingList: + - name: 4 + value: 4 + - name: 3 + value: 3 +`), + Result: []byte(` +mergingList: + - name: 4 + value: 4 + - name: 1 + other: a + - name: 2 + value: 2 + other: b + - name: 3 + value: 3 +`), + }, + }, + { + Description: "merge lists of maps with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 + - name: 3 +mergingList: + - name: 3 + value: 3 +`), + Modified: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 + - name: 3 + value: 3 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 3 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 + - name: 3 +mergingList: + - name: 2 + value: 2 + - name: 3 + value: 3 +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + other: b + - name: 3 + value: 3 +`), + }, + }, + { + Description: "add field to map in merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: 1 +`), + Result: []byte(` +mergingList: + - name: 1 + value: 1 + other: a + - name: 2 + value: 2 + other: b +`), + }, + }, + { + Description: "add field to map in merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: 1 +`), + Result: []byte(` +mergingList: + - name: 1 + value: 1 + other: a + - name: 2 + value: 2 + other: b +`), + }, + }, + { + Description: "add field to map in merging list with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 3 + value: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 +`), + Result: []byte(` +mergingList: + - name: 1 + value: 1 + other: a + - name: 2 + value: 2 + - name: 3 + value: 2 + other: b +`), + }, + }, + { + Description: "add duplicate field to map in merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + value: 1 + other: a + - name: 2 + value: 2 + other: b +`), + ThreeWay: []byte(`{}`), + Result: []byte(` +mergingList: + - name: 1 + value: 1 + other: a + - name: 2 + value: 2 + other: b +`), + }, + }, + { + Description: "add an item that already exists in current object in merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + value: a + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 + - name: 3 +mergingList: + - name: 3 +`), + Modified: []byte(` +mergingList: + - name: 1 + value: a + - name: 2 + - name: 3 +`), + Current: []byte(` +mergingList: + - name: 1 + value: a + other: x + - name: 2 + - name: 3 +`), + ThreeWay: []byte(`{}`), + Result: []byte(` +mergingList: + - name: 1 + value: a + other: x + - name: 2 + - name: 3 +`), + }, + }, + { + Description: "add duplicate field to map in merging list with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + value: 1 + other: a + - name: 2 + value: 3 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 2 + value: 2 +`), + Result: []byte(` +mergingList: + - name: 1 + value: 1 + other: a + - name: 2 + value: 2 + other: b +`), + }, + }, + { + Description: "replace map field value in merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: a +`), + Modified: []byte(` +mergingList: + - name: 1 + value: a + - name: 2 + value: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + value: 1 + other: a + - name: 2 + value: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: a +`), + Result: []byte(` +mergingList: + - name: 1 + value: a + other: a + - name: 2 + value: 2 + other: b +`), + }, + }, + { + Description: "replace map field value in merging list with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: a +`), + Modified: []byte(` +mergingList: + - name: 1 + value: a + - name: 2 + value: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + value: 3 + other: a + - name: 2 + value: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: a +`), + Result: []byte(` +mergingList: + - name: 1 + value: a + other: a + - name: 2 + value: 2 + other: b +`), + }, + }, + { + Description: "delete map from merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 2 +mergingList: + - name: 1 + $patch: delete +`), + Modified: []byte(` +mergingList: + - name: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 2 +mergingList: + - name: 1 + $patch: delete +`), + Result: []byte(` +mergingList: + - name: 2 + other: b +`), + }, + }, + { + Description: "delete map from merging list with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 2 +mergingList: + - name: 1 + $patch: delete +`), + Modified: []byte(` +mergingList: + - name: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 2 +mergingList: + - name: 1 + $patch: delete +`), + Result: []byte(` +mergingList: + - name: 2 + other: b +`), + }, + }, + { + Description: "delete missing map from merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 2 +mergingList: + - name: 1 + $patch: delete +`), + Modified: []byte(` +mergingList: + - name: 2 +`), + Current: []byte(` +mergingList: + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 2 +mergingList: + - name: 1 + $patch: delete +`), + Result: []byte(` +mergingList: + - name: 2 + other: b +`), + }, + }, + { + Description: "delete missing map from merging list with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 2 +mergingList: + - name: 1 + $patch: delete +`), + Modified: []byte(` +mergingList: + - name: 2 +`), + Current: []byte(` +mergingList: + - name: 3 + other: a +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 2 +mergingList: + - name: 2 + - name: 1 + $patch: delete +`), + Result: []byte(` +mergingList: + - name: 2 + - name: 3 + other: a +`), + }, + }, + { + Description: "add map and delete map from merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 2 + - name: 3 +mergingList: + - name: 3 + - name: 1 + $patch: delete +`), + Modified: []byte(` +mergingList: + - name: 2 + - name: 3 +`), + Current: []byte(` +mergingList: + - name: 1 + - name: 2 + other: b + - name: 4 + other: c +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 2 + - name: 3 +mergingList: + - name: 3 + - name: 1 + $patch: delete +`), + Result: []byte(` +mergingList: + - name: 2 + other: b + - name: 4 + other: c + - name: 3 +`), + }, + }, + { + Description: "add map and delete map from merging list with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 2 + - name: 3 +mergingList: + - name: 3 + - name: 1 + $patch: delete +`), + Modified: []byte(` +mergingList: + - name: 2 + - name: 3 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 4 + other: c +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 2 + - name: 3 +mergingList: + - name: 2 + - name: 3 + - name: 1 + $patch: delete +`), + Result: []byte(` +mergingList: + - name: 4 + other: c + - name: 2 + - name: 3 +`), + }, + }, + { + Description: "delete field from map in merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: null +`), + Modified: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + value: 1 + other: a + - name: 2 + value: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: null +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + other: b +`), + }, + }, + { + Description: "delete field from map in merging list with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: null +`), + Modified: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + value: a + other: a + - name: 2 + value: 2 +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: null +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 +`), + }, + }, + { + Description: "delete missing field from map in merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: null +`), + Modified: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: null +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + other: b +`), + }, + }, + { + Description: "delete missing field from map in merging list with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: null +`), + Modified: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + value: null + - name: 2 + value: 2 +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + other: b +`), + }, + }, + { + Description: "replace non merging list nested in merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + nonMergingList: + - name: 1 + - name: 2 + value: 2 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + nonMergingList: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 1 + nonMergingList: + - name: 1 + value: 1 + - name: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + nonMergingList: + - name: 1 + - name: 2 + value: 2 + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + nonMergingList: + - name: 1 + value: 1 +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + nonMergingList: + - name: 1 + value: 1 + - name: 2 + other: b +`), + }, + }, + { + Description: "replace non merging list nested in merging list with value conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + nonMergingList: + - name: 1 + - name: 2 + value: 2 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + nonMergingList: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 1 + nonMergingList: + - name: 1 + value: 1 + - name: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + nonMergingList: + - name: 1 + value: c + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + nonMergingList: + - name: 1 + value: 1 +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + nonMergingList: + - name: 1 + value: 1 + - name: 2 + other: b +`), + }, + }, + { + Description: "replace non merging list nested in merging list with value conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + nonMergingList: + - name: 1 + - name: 2 + value: 2 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + nonMergingList: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 1 + nonMergingList: + - name: 1 + value: 1 + - name: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + nonMergingList: + - name: 1 + value: c + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + nonMergingList: + - name: 1 + value: 1 +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + nonMergingList: + - name: 1 + value: 1 + - name: 2 + other: b +`), + }, + }, + { + Description: "replace non merging list nested in merging list with deletion conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + nonMergingList: + - name: 1 + - name: 2 + value: 2 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + nonMergingList: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 1 + nonMergingList: + - name: 1 + value: 1 + - name: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + nonMergingList: + - name: 2 + value: 2 + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - name: 1 + nonMergingList: + - name: 1 + value: 1 +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + nonMergingList: + - name: 1 + value: 1 + - name: 2 + other: b +`), + }, + }, + { + Description: "add field to map in merging list nested in merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + mergingList: + - name: 1 + - name: 2 + value: 2 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - $setElementOrder/mergingList: + - name: 1 + - name: 2 + name: 1 + mergingList: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 1 + mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 + - name: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + mergingList: + - name: 1 + - name: 2 + value: 2 + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - $setElementOrder/mergingList: + - name: 1 + - name: 2 + name: 1 + mergingList: + - name: 1 + value: 1 +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 + - name: 2 + other: b +`), + }, + }, + { + Description: "add field to map in merging list nested in merging list with value conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + mergingList: + - name: 1 + - name: 2 + value: 2 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - $setElementOrder/mergingList: + - name: 1 + - name: 2 + name: 1 + mergingList: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 1 + mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 + - name: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + mergingList: + - name: 1 + value: a + other: c + - name: 2 + value: b + other: d + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - $setElementOrder/mergingList: + - name: 1 + - name: 2 + name: 1 + mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + mergingList: + - name: 1 + value: 1 + other: c + - name: 2 + value: 2 + other: d + - name: 2 + other: b +`), + }, + }, + { + Description: "add field to map in merging list nested in merging list with deletion conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + mergingList: + - name: 1 + - name: 2 + value: 2 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - $setElementOrder/mergingList: + - name: 1 + - name: 2 + name: 1 + mergingList: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 1 + mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 + - name: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + mergingList: + - name: 2 + value: 2 + other: d + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - $setElementOrder/mergingList: + - name: 1 + - name: 2 + name: 1 + mergingList: + - name: 1 + value: 1 +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + mergingList: + - name: 1 + value: 1 + - name: 2 + value: 2 + other: d + - name: 2 + other: b +`), + }, + }, + + { + Description: "add field to map in merging list nested in merging list with deletion conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + mergingList: + - name: 1 + - name: 2 + value: 2 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - $setElementOrder/mergingList: + - name: 2 + - name: 1 + name: 1 + mergingList: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergingList: + - name: 1 + mergingList: + - name: 2 + value: 2 + - name: 1 + value: 1 + - name: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + mergingList: + - name: 2 + value: 2 + other: d + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 2 +mergingList: + - $setElementOrder/mergingList: + - name: 2 + - name: 1 + name: 1 + mergingList: + - name: 1 + value: 1 +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + mergingList: + - name: 2 + value: 2 + other: d + - name: 1 + value: 1 + - name: 2 + other: b +`), + }, + }, + { + Description: "add map to merging list by pointer", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergeItemPtr: + - name: 1 +`), + TwoWay: []byte(` +$setElementOrder/mergeItemPtr: + - name: 1 + - name: 2 +mergeItemPtr: + - name: 2 +`), + Modified: []byte(` +mergeItemPtr: + - name: 1 + - name: 2 +`), + Current: []byte(` +mergeItemPtr: + - name: 1 + other: a + - name: 3 +`), + ThreeWay: []byte(` +$setElementOrder/mergeItemPtr: + - name: 1 + - name: 2 +mergeItemPtr: + - name: 2 +`), + Result: []byte(` +mergeItemPtr: + - name: 1 + other: a + - name: 2 + - name: 3 +`), + }, + }, + { + Description: "add map to merging list by pointer with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergeItemPtr: + - name: 1 +`), + TwoWay: []byte(` +$setElementOrder/mergeItemPtr: + - name: 1 + - name: 2 +mergeItemPtr: + - name: 2 +`), + Modified: []byte(` +mergeItemPtr: + - name: 1 + - name: 2 +`), + Current: []byte(` +mergeItemPtr: + - name: 3 +`), + ThreeWay: []byte(` +$setElementOrder/mergeItemPtr: + - name: 1 + - name: 2 +mergeItemPtr: + - name: 1 + - name: 2 +`), + Result: []byte(` +mergeItemPtr: + - name: 1 + - name: 2 + - name: 3 +`), + }, + }, + { + Description: "add field to map in merging list by pointer", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergeItemPtr: + - name: 1 + mergeItemPtr: + - name: 1 + - name: 2 + value: 2 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergeItemPtr: + - name: 1 + - name: 2 +mergeItemPtr: + - $setElementOrder/mergeItemPtr: + - name: 1 + - name: 2 + name: 1 + mergeItemPtr: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergeItemPtr: + - name: 1 + mergeItemPtr: + - name: 1 + value: 1 + - name: 2 + value: 2 + - name: 2 +`), + Current: []byte(` +mergeItemPtr: + - name: 1 + other: a + mergeItemPtr: + - name: 1 + other: a + - name: 2 + value: 2 + other: b + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergeItemPtr: + - name: 1 + - name: 2 +mergeItemPtr: + - $setElementOrder/mergeItemPtr: + - name: 1 + - name: 2 + name: 1 + mergeItemPtr: + - name: 1 + value: 1 +`), + Result: []byte(` +mergeItemPtr: + - name: 1 + other: a + mergeItemPtr: + - name: 1 + value: 1 + other: a + - name: 2 + value: 2 + other: b + - name: 2 + other: b +`), + }, + }, + { + Description: "add field to map in merging list by pointer with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergeItemPtr: + - name: 1 + mergeItemPtr: + - name: 1 + - name: 2 + value: 2 + - name: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergeItemPtr: + - name: 1 + - name: 2 +mergeItemPtr: + - $setElementOrder/mergeItemPtr: + - name: 1 + - name: 2 + name: 1 + mergeItemPtr: + - name: 1 + value: 1 +`), + Modified: []byte(` +mergeItemPtr: + - name: 1 + mergeItemPtr: + - name: 1 + value: 1 + - name: 2 + value: 2 + - name: 2 +`), + Current: []byte(` +mergeItemPtr: + - name: 1 + other: a + mergeItemPtr: + - name: 1 + value: a + - name: 2 + value: 2 + other: b + - name: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergeItemPtr: + - name: 1 + - name: 2 +mergeItemPtr: + - $setElementOrder/mergeItemPtr: + - name: 1 + - name: 2 + name: 1 + mergeItemPtr: + - name: 1 + value: 1 +`), + Result: []byte(` +mergeItemPtr: + - name: 1 + other: a + mergeItemPtr: + - name: 1 + value: 1 + - name: 2 + value: 2 + other: b + - name: 2 + other: b +`), + }, + }, + { + Description: "merge lists of scalars", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: +- 1 +- 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: +- 1 +- 2 +- 3 +mergingIntList: +- 3 +`), + Modified: []byte(` +mergingIntList: +- 1 +- 2 +- 3 +`), + Current: []byte(` +mergingIntList: +- 1 +- 2 +- 4 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: +- 1 +- 2 +- 3 +mergingIntList: +- 3 +`), + Result: []byte(` +mergingIntList: +- 1 +- 2 +- 3 +- 4 +`), + }, + }, + { + Description: "add duplicate field to map in merging int list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 1 + - 2 + - 3 +mergingIntList: + - 3 +`), + Modified: []byte(` +mergingIntList: + - 1 + - 2 + - 3 +`), + Current: []byte(` +mergingIntList: + - 1 + - 2 + - 3 +`), + ThreeWay: []byte(`{}`), + Result: []byte(` +mergingIntList: + - 1 + - 2 + - 3 +`), + }, + }, + // test case for setElementOrder + { + Description: "add an item in a list of primitives and preserve order", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: +- 1 +- 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: +- 3 +- 1 +- 2 +mergingIntList: +- 3 +`), + Modified: []byte(` +mergingIntList: +- 3 +- 1 +- 2 +`), + Current: []byte(` +mergingIntList: +- 1 +- 4 +- 2 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: +- 3 +- 1 +- 2 +mergingIntList: +- 3 +`), + Result: []byte(` +mergingIntList: +- 3 +- 1 +- 4 +- 2 +`), + }, + }, + { + Description: "delete an item in a list of primitives and preserve order", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: +- 1 +- 2 +- 3 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: +- 2 +- 1 +$deleteFromPrimitiveList/mergingIntList: +- 3 +`), + Modified: []byte(` +mergingIntList: +- 2 +- 1 +`), + Current: []byte(` +mergingIntList: +- 1 +- 2 +- 3 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: +- 2 +- 1 +$deleteFromPrimitiveList/mergingIntList: +- 3 +`), + Result: []byte(` +mergingIntList: +- 2 +- 1 +`), + }, + }, + { + Description: "add an item in a list and preserve order", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 3 + - name: 1 + - name: 2 +mergingList: + - name: 3 + value: 3 +`), + Modified: []byte(` +mergingList: + - name: 3 + value: 3 + - name: 1 + - name: 2 + value: 2 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 3 + - name: 1 + - name: 2 +mergingList: + - name: 3 + value: 3 +`), + Result: []byte(` +mergingList: + - name: 3 + value: 3 + - name: 1 + other: a + - name: 2 + value: 2 + other: b +`), + }, + }, + { + Description: "add multiple items in a list and preserve order", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 4 + - name: 2 + - name: 3 +mergingList: + - name: 4 + value: 4 + - name: 3 + value: 3 +`), + Modified: []byte(` +mergingList: + - name: 1 + - name: 4 + value: 4 + - name: 2 + value: 2 + - name: 3 + value: 3 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + other: b +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 1 + - name: 4 + - name: 2 + - name: 3 +mergingList: + - name: 4 + value: 4 + - name: 3 + value: 3 +`), + Result: []byte(` +mergingList: + - name: 1 + other: a + - name: 4 + value: 4 + - name: 2 + value: 2 + other: b + - name: 3 + value: 3 +`), + }, + }, + { + Description: "delete an item in a list and preserve order", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 3 + value: 3 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 2 + - name: 1 +mergingList: + - name: 3 + $patch: delete +`), + Modified: []byte(` +mergingList: + - name: 2 + value: 2 + - name: 1 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + other: b + - name: 3 + value: 3 +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 2 + - name: 1 +mergingList: + - name: 3 + $patch: delete +`), + Result: []byte(` +mergingList: + - name: 2 + value: 2 + other: b + - name: 1 + other: a +`), + }, + }, + { + Description: "change an item in a list and preserve order", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 3 + value: 3 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 2 + - name: 3 + - name: 1 +mergingList: + - name: 3 + value: x +`), + Modified: []byte(` +mergingList: + - name: 2 + value: 2 + - name: 3 + value: x + - name: 1 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + other: b + - name: 3 + value: 3 +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 2 + - name: 3 + - name: 1 +mergingList: + - name: 3 + value: x +`), + Result: []byte(` +mergingList: + - name: 2 + value: 2 + other: b + - name: 3 + value: x + - name: 1 + other: a +`), + }, + }, + { + Description: "add and delete an item in a list and preserve order", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 3 + value: 3 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 4 + - name: 2 + - name: 1 +mergingList: + - name: 4 + value: 4 + - name: 3 + $patch: delete +`), + Modified: []byte(` +mergingList: + - name: 4 + value: 4 + - name: 2 + value: 2 + - name: 1 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + other: b + - name: 3 + value: 3 +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 4 + - name: 2 + - name: 1 +mergingList: + - name: 4 + value: 4 + - name: 3 + $patch: delete +`), + Result: []byte(` +mergingList: + - name: 4 + value: 4 + - name: 2 + value: 2 + other: b + - name: 1 + other: a +`), + }, + }, + { + Description: "set elements order in a list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 3 + value: 3 + - name: 4 + value: 4 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 4 + - name: 2 + - name: 3 + - name: 1 +`), + Modified: []byte(` +mergingList: + - name: 4 + value: 4 + - name: 2 + value: 2 + - name: 3 + value: 3 + - name: 1 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 3 + value: 3 + - name: 4 + value: 4 + - name: 2 + value: 2 +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 4 + - name: 2 + - name: 3 + - name: 1 +`), + Result: []byte(` +mergingList: + - name: 4 + value: 4 + - name: 2 + value: 2 + - name: 3 + value: 3 + - name: 1 + other: a +`), + }, + }, + { + Description: "set elements order in a list with server-only items", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 3 + value: 3 + - name: 4 + value: 4 + - name: 2 + value: 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 4 + - name: 2 + - name: 3 + - name: 1 +`), + Modified: []byte(` +mergingList: + - name: 4 + value: 4 + - name: 2 + value: 2 + - name: 3 + value: 3 + - name: 1 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 3 + value: 3 + - name: 4 + value: 4 + - name: 2 + value: 2 + - name: 9 +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 4 + - name: 2 + - name: 3 + - name: 1 +`), + Result: []byte(` +mergingList: + - name: 4 + value: 4 + - name: 2 + value: 2 + - name: 3 + value: 3 + - name: 1 + other: a + - name: 9 +`), + }, + }, + { + Description: "set elements order in a list with server-only items 2", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 + - name: 3 + value: 3 + - name: 4 + value: 4 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 2 + - name: 1 + - name: 4 + - name: 3 +`), + Modified: []byte(` +mergingList: + - name: 2 + value: 2 + - name: 1 + - name: 4 + value: 4 + - name: 3 + value: 3 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + - name: 9 + - name: 3 + value: 3 + - name: 4 + value: 4 +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 2 + - name: 1 + - name: 4 + - name: 3 +`), + Result: []byte(` +mergingList: + - name: 2 + value: 2 + - name: 1 + other: a + - name: 9 + - name: 4 + value: 4 + - name: 3 + value: 3 +`), + }, + }, + { + Description: "set elements order in a list with server-only items 3", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: + - name: 1 + - name: 2 + value: 2 + - name: 3 + value: 3 + - name: 4 + value: 4 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: + - name: 2 + - name: 1 + - name: 4 + - name: 3 +`), + Modified: []byte(` +mergingList: + - name: 2 + value: 2 + - name: 1 + - name: 4 + value: 4 + - name: 3 + value: 3 +`), + Current: []byte(` +mergingList: + - name: 1 + other: a + - name: 2 + value: 2 + - name: 7 + - name: 9 + - name: 8 + - name: 3 + value: 3 + - name: 4 + value: 4 +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: + - name: 2 + - name: 1 + - name: 4 + - name: 3 +`), + Result: []byte(` +mergingList: + - name: 2 + value: 2 + - name: 1 + other: a + - name: 7 + - name: 9 + - name: 8 + - name: 4 + value: 4 + - name: 3 + value: 3 +`), + }, + }, + { + Description: "add an item in a int list and preserve order", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 3 + - 1 + - 2 +mergingIntList: + - 3 +`), + Modified: []byte(` +mergingIntList: + - 3 + - 1 + - 2 +`), + Current: []byte(` +mergingIntList: + - 1 + - 2 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: + - 3 + - 1 + - 2 +mergingIntList: + - 3 +`), + Result: []byte(` +mergingIntList: + - 3 + - 1 + - 2 +`), + }, + }, + { + Description: "add multiple items in a int list and preserve order", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 1 + - 4 + - 2 + - 3 +mergingIntList: + - 4 + - 3 +`), + Modified: []byte(` +mergingIntList: + - 1 + - 4 + - 2 + - 3 +`), + Current: []byte(` +mergingIntList: + - 1 + - 2 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: + - 1 + - 4 + - 2 + - 3 +mergingIntList: + - 4 + - 3 +`), + Result: []byte(` +mergingIntList: + - 1 + - 4 + - 2 + - 3 +`), + }, + }, + { + Description: "delete an item in a int list and preserve order", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 3 + - 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 2 + - 1 +$deleteFromPrimitiveList/mergingIntList: + - 3 +`), + Modified: []byte(` +mergingIntList: + - 2 + - 1 +`), + Current: []byte(` +mergingIntList: + - 1 + - 2 + - 3 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: + - 2 + - 1 +$deleteFromPrimitiveList/mergingIntList: + - 3 +`), + Result: []byte(` +mergingIntList: + - 2 + - 1 +`), + }, + }, + { + Description: "add and delete an item in a int list and preserve order", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 3 + - 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 4 + - 2 + - 1 +mergingIntList: + - 4 +$deleteFromPrimitiveList/mergingIntList: + - 3 +`), + Modified: []byte(` +mergingIntList: + - 4 + - 2 + - 1 +`), + Current: []byte(` +mergingIntList: + - 1 + - 2 + - 3 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: + - 4 + - 2 + - 1 +mergingIntList: + - 4 +$deleteFromPrimitiveList/mergingIntList: + - 3 +`), + Result: []byte(` +mergingIntList: + - 4 + - 2 + - 1 +`), + }, + }, + { + Description: "set elements order in a int list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 3 + - 4 + - 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 4 + - 2 + - 3 + - 1 +`), + Modified: []byte(` +mergingIntList: + - 4 + - 2 + - 3 + - 1 +`), + Current: []byte(` +mergingIntList: + - 1 + - 3 + - 4 + - 2 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: + - 4 + - 2 + - 3 + - 1 +`), + Result: []byte(` +mergingIntList: + - 4 + - 2 + - 3 + - 1 +`), + }, + }, + { + Description: "set elements order in a int list with server-only items", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 3 + - 4 + - 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 4 + - 2 + - 3 + - 1 +`), + Modified: []byte(` +mergingIntList: + - 4 + - 2 + - 3 + - 1 +`), + Current: []byte(` +mergingIntList: + - 1 + - 3 + - 4 + - 2 + - 9 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: + - 4 + - 2 + - 3 + - 1 +`), + Result: []byte(` +mergingIntList: + - 4 + - 2 + - 3 + - 1 + - 9 +`), + }, + }, + { + Description: "set elements order in a int list with server-only items 2", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 2 + - 3 + - 4 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 2 + - 1 + - 4 + - 3 +`), + Modified: []byte(` +mergingIntList: + - 2 + - 1 + - 4 + - 3 +`), + Current: []byte(` +mergingIntList: + - 1 + - 2 + - 9 + - 3 + - 4 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: + - 2 + - 1 + - 4 + - 3 +`), + Result: []byte(` +mergingIntList: + - 2 + - 1 + - 9 + - 4 + - 3 +`), + }, + }, + { + Description: "set elements order in a int list with server-only items 3", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: + - 1 + - 2 + - 3 + - 4 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: + - 2 + - 1 + - 4 + - 3 +`), + Modified: []byte(` +mergingIntList: + - 2 + - 1 + - 4 + - 3 +`), + Current: []byte(` +mergingIntList: + - 1 + - 2 + - 7 + - 9 + - 8 + - 3 + - 4 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: + - 2 + - 1 + - 4 + - 3 +`), + Result: []byte(` +mergingIntList: + - 2 + - 1 + - 7 + - 9 + - 8 + - 4 + - 3 +`), + }, + }, + { + // This test case is used just to demonstrate the behavior when dealing with a list with duplicate + Description: "behavior of set element order for a merging list with duplicate", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingList: +- name: 1 +- name: 2 + value: dup1 +- name: 3 +- name: 2 + value: dup2 +- name: 4 +`), + Current: []byte(` +mergingList: +- name: 1 +- name: 2 + value: dup1 +- name: 3 +- name: 2 + value: dup2 +- name: 4 +`), + Modified: []byte(` +mergingList: +- name: 2 + value: dup1 +- name: 1 +- name: 4 +- name: 3 +- name: 2 + value: dup2 +`), + TwoWay: []byte(` +$setElementOrder/mergingList: +- name: 2 +- name: 1 +- name: 4 +- name: 3 +- name: 2 +`), + TwoWayResult: []byte(` +mergingList: +- name: 2 + value: dup1 +- name: 2 + value: dup2 +- name: 1 +- name: 4 +- name: 3 +`), + ThreeWay: []byte(` +$setElementOrder/mergingList: +- name: 2 +- name: 1 +- name: 4 +- name: 3 +- name: 2 +`), + Result: []byte(` +mergingList: +- name: 2 + value: dup1 +- name: 2 + value: dup2 +- name: 1 +- name: 4 +- name: 3 +`), + }, + }, + { + // This test case is used just to demonstrate the behavior when dealing with a list with duplicate + Description: "behavior of set element order for a merging int list with duplicate", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +mergingIntList: +- 1 +- 2 +- 3 +- 2 +- 4 +`), + Current: []byte(` +mergingIntList: +- 1 +- 2 +- 3 +- 2 +- 4 +`), + Modified: []byte(` +mergingIntList: +- 2 +- 1 +- 4 +- 3 +- 2 +`), + TwoWay: []byte(` +$setElementOrder/mergingIntList: +- 2 +- 1 +- 4 +- 3 +- 2 +`), + TwoWayResult: []byte(` +mergingIntList: +- 2 +- 2 +- 1 +- 4 +- 3 +`), + ThreeWay: []byte(` +$setElementOrder/mergingIntList: +- 2 +- 1 +- 4 +- 3 +- 2 +`), + Result: []byte(` +mergingIntList: +- 2 +- 2 +- 1 +- 4 +- 3 +`), + }, + }, + { + Description: "retainKeys map should clear defaulted field", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(`{}`), + Current: []byte(` +retainKeysMap: + value: foo +`), + Modified: []byte(` +retainKeysMap: + other: bar +`), + TwoWay: []byte(` +retainKeysMap: + other: bar +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - other + other: bar +`), + Result: []byte(` +retainKeysMap: + other: bar +`), + }, + }, + { + Description: "retainKeys map should clear defaulted field with conflict (discriminated union)", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(`{}`), + Current: []byte(` +retainKeysMap: + name: type1 + value: foo +`), + Modified: []byte(` +retainKeysMap: + name: type2 + other: bar +`), + TwoWay: []byte(` +retainKeysMap: + name: type2 + other: bar +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - other + name: type2 + other: bar +`), + Result: []byte(` +retainKeysMap: + name: type2 + other: bar +`), + }, + }, + { + Description: "retainKeys map adds a field", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo +`), + Current: []byte(` +retainKeysMap: + name: foo +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - value + value: bar +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - value + value: bar +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar +`), + }, + }, + { + Description: "retainKeys map adds a field and clear a field", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo +`), + Current: []byte(` +retainKeysMap: + name: foo + other: a +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - value + value: bar +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - value + value: bar +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar +`), + }, + }, + { + Description: "retainKeys map deletes a field", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + value: bar +`), + Current: []byte(` +retainKeysMap: + name: foo + value: bar +`), + Modified: []byte(` +retainKeysMap: + name: foo +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + value: null +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + value: null +`), + Result: []byte(` +retainKeysMap: + name: foo +`), + }, + }, + { + Description: "retainKeys map deletes a field and clears a field", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + value: bar +`), + Current: []byte(` +retainKeysMap: + name: foo + value: bar + other: a +`), + Modified: []byte(` +retainKeysMap: + name: foo +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + value: null +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + value: null +`), + Result: []byte(` +retainKeysMap: + name: foo +`), + }, + }, + { + Description: "retainKeys map clears a field", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + value: bar +`), + Current: []byte(` +retainKeysMap: + name: foo + value: bar + other: a +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar +`), + TwoWay: []byte(`{}`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - value +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar +`), + }, + }, + { + Description: "retainKeys map nested map with no change", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + simpleMap: + key1: a +`), + Current: []byte(` +retainKeysMap: + name: foo + simpleMap: + key1: a +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: a +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - simpleMap + - value + value: bar +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - simpleMap + - value + value: bar +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: a +`), + }, + }, + { + Description: "retainKeys map adds a field in a nested map", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: a +`), + Current: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: a + key3: c +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: a + key2: b +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - simpleMap + - value + simpleMap: + key2: b +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - simpleMap + - value + simpleMap: + key2: b +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: a + key2: b + key3: c +`), + }, + }, + { + Description: "retainKeys map deletes a field in a nested map", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: a + key2: b +`), + Current: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: a + key2: b + key3: c +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: a +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - simpleMap + - value + simpleMap: + key2: null +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - simpleMap + - value + simpleMap: + key2: null +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: a + key3: c +`), + }, + }, + { + Description: "retainKeys map changes a field in a nested map", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: a + key2: b +`), + Current: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: a + key2: b + key3: c +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: x + key2: b +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - simpleMap + - value + simpleMap: + key1: x +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - simpleMap + - value + simpleMap: + key1: x +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: x + key2: b + key3: c +`), + }, + }, + { + Description: "retainKeys map changes a field in a nested map with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: old + key2: b +`), + Current: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: new + key2: b + key3: c +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: modified + key2: b +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - simpleMap + - value + simpleMap: + key1: modified +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - simpleMap + - value + simpleMap: + key1: modified +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar + simpleMap: + key1: modified + key2: b + key3: c +`), + }, + }, + { + Description: "retainKeys map replaces non-merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + value: bar + nonMergingList: + - name: a + - name: b +`), + Current: []byte(` +retainKeysMap: + name: foo + value: bar + nonMergingList: + - name: a + - name: b +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar + nonMergingList: + - name: a + - name: c + - name: b +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - nonMergingList + - value + nonMergingList: + - name: a + - name: c + - name: b +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - nonMergingList + - value + nonMergingList: + - name: a + - name: c + - name: b +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar + nonMergingList: + - name: a + - name: c + - name: b +`), + }, + }, + { + Description: "retainKeys map nested non-merging list with no change", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + nonMergingList: + - name: a + - name: b +`), + Current: []byte(` +retainKeysMap: + name: foo + nonMergingList: + - name: a + - name: b +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar + nonMergingList: + - name: a + - name: b +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - nonMergingList + - value + value: bar +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - nonMergingList + - value + value: bar +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar + nonMergingList: + - name: a + - name: b +`), + }, + }, + { + Description: "retainKeys map nested non-merging list with no change with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + nonMergingList: + - name: a + - name: b +`), + Current: []byte(` +retainKeysMap: + name: foo + nonMergingList: + - name: a + - name: b + - name: c +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar + nonMergingList: + - name: a + - name: b +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - nonMergingList + - value + value: bar +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - nonMergingList + - value + value: bar + nonMergingList: + - name: a + - name: b +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar + nonMergingList: + - name: a + - name: b +`), + }, + }, + { + Description: "retainKeys map deletes nested non-merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + nonMergingList: + - name: a + - name: b +`), + Current: []byte(` +retainKeysMap: + name: foo + nonMergingList: + - name: a + - name: b +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - value + value: bar + nonMergingList: null +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - value + value: bar + nonMergingList: null +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar +`), + }, + }, + { + Description: "retainKeys map delete nested non-merging list with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + nonMergingList: + - name: a + - name: b +`), + Current: []byte(` +retainKeysMap: + name: foo + nonMergingList: + - name: a + - name: b + - name: c +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - value + value: bar + nonMergingList: null +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - value + value: bar + nonMergingList: null +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar +`), + }, + }, + { + Description: "retainKeys map nested merging int list with no change", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 2 +`), + Current: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 2 + - 3 +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar + mergingIntList: + - 1 + - 2 +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - mergingIntList + - name + - value + value: bar +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - mergingIntList + - name + - value + $setElementOrder/mergingIntList: + - 1 + - 2 + value: bar +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar + mergingIntList: + - 1 + - 2 + - 3 +`), + }, + }, + { + Description: "retainKeys map adds an item in nested merging int list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 2 +`), + Current: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 2 + - 3 +`), + Modified: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 2 + - 4 +`), + TwoWay: []byte(` +retainKeysMap: + $setElementOrder/mergingIntList: + - 1 + - 2 + - 4 + $retainKeys: + - mergingIntList + - name + mergingIntList: + - 4 +`), + ThreeWay: []byte(` +retainKeysMap: + $setElementOrder/mergingIntList: + - 1 + - 2 + - 4 + $retainKeys: + - mergingIntList + - name + mergingIntList: + - 4 +`), + Result: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 2 + - 4 + - 3 +`), + }, + }, + { + Description: "retainKeys map deletes an item in nested merging int list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 2 + - 3 +`), + Current: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 2 + - 3 + - 4 +`), + Modified: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 3 +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - mergingIntList + - name + $deleteFromPrimitiveList/mergingIntList: + - 2 + $setElementOrder/mergingIntList: + - 1 + - 3 +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - mergingIntList + - name + $deleteFromPrimitiveList/mergingIntList: + - 2 + $setElementOrder/mergingIntList: + - 1 + - 3 +`), + Result: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 3 + - 4 +`), + }, + }, + { + Description: "retainKeys map adds an item and deletes an item in nested merging int list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 2 + - 3 +`), + Current: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 2 + - 3 + - 4 +`), + Modified: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 3 + - 5 +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - mergingIntList + - name + mergingIntList: + - 5 + $deleteFromPrimitiveList/mergingIntList: + - 2 + $setElementOrder/mergingIntList: + - 1 + - 3 + - 5 +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - mergingIntList + - name + mergingIntList: + - 5 + $deleteFromPrimitiveList/mergingIntList: + - 2 + $setElementOrder/mergingIntList: + - 1 + - 3 + - 5 +`), + Result: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 3 + - 5 + - 4 +`), + }, + }, + { + Description: "retainKeys map deletes nested merging int list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 2 + - 3 +`), + Current: []byte(` +retainKeysMap: + name: foo + mergingIntList: + - 1 + - 2 + - 3 +`), + Modified: []byte(` +retainKeysMap: + name: foo +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + mergingIntList: null +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + mergingIntList: null +`), + Result: []byte(` +retainKeysMap: + name: foo +`), + }, + }, + { + Description: "retainKeys map nested merging list with no change", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b +`), + Current: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b + - name: c +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar + mergingList: + - name: a + - name: b +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - mergingList + - name + - value + value: bar +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - mergingList + - name + - value + $setElementOrder/mergingList: + - name: a + - name: b + value: bar +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar + mergingList: + - name: a + - name: b + - name: c +`), + }, + }, + { + Description: "retainKeys map adds an item in nested merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b +`), + Current: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b + - name: x +`), + Modified: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b + - name: c +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - mergingList + - name + $setElementOrder/mergingList: + - name: a + - name: b + - name: c + mergingList: + - name: c +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - mergingList + - name + $setElementOrder/mergingList: + - name: a + - name: b + - name: c + mergingList: + - name: c +`), + Result: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b + - name: c + - name: x +`), + }, + }, + { + Description: "retainKeys map changes an item in nested merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b + value: foo +`), + Current: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b + value: foo + - name: x +`), + Modified: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b + value: bar +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - mergingList + - name + $setElementOrder/mergingList: + - name: a + - name: b + mergingList: + - name: b + value: bar +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - mergingList + - name + $setElementOrder/mergingList: + - name: a + - name: b + mergingList: + - name: b + value: bar +`), + Result: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b + value: bar + - name: x +`), + }, + }, + { + Description: "retainKeys map deletes nested merging list", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b +`), + Current: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b +`), + Modified: []byte(` +retainKeysMap: + name: foo + value: bar +`), + TwoWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - value + value: bar + mergingList: null +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - name + - value + value: bar + mergingList: null +`), + Result: []byte(` +retainKeysMap: + name: foo + value: bar +`), + }, + }, { - Description: "delete items in lists of scalars", + Description: "retainKeys map deletes an item in nested merging list", StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ Original: []byte(` -mergingIntList: - - 1 - - 2 - - 3 +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b +`), + Current: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: b + - name: x +`), + Modified: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a `), TwoWay: []byte(` -$deleteFromPrimitiveList/mergingIntList: - - 3 +retainKeysMap: + $retainKeys: + - mergingList + - name + $setElementOrder/mergingList: + - name: a + mergingList: + - name: b + $patch: delete +`), + ThreeWay: []byte(` +retainKeysMap: + $retainKeys: + - mergingList + - name + $setElementOrder/mergingList: + - name: a + mergingList: + - name: b + $patch: delete +`), + Result: []byte(` +retainKeysMap: + name: foo + mergingList: + - name: a + - name: x +`), + }, + }, + { + Description: "retainKeys list of maps clears a field", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: a +`), + Current: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: a + other: x `), Modified: []byte(` -mergingIntList: - - 1 - - 2 +retainKeysMergingList: +- name: bar +- name: foo + value: a +`), + TwoWay: []byte(`{}`), + ThreeWay: []byte(` +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + - value + name: foo +`), + Result: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: a +`), + }, + }, + { + Description: "retainKeys list of maps clears a field with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: old `), Current: []byte(` -mergingIntList: - - 1 - - 2 - - 3 - - 4 +retainKeysMergingList: +- name: bar +- name: foo + value: new + other: x +`), + Modified: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: modified +`), + TwoWay: []byte(` +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + - value + name: foo + value: modified `), ThreeWay: []byte(` -$deleteFromPrimitiveList/mergingIntList: - - 3 +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + - value + name: foo + value: modified `), Result: []byte(` -mergingIntList: - - 1 - - 2 - - 4 +retainKeysMergingList: +- name: bar +- name: foo + value: modified `), }, }, { - Description: "delete all duplicate items in lists of scalars", + Description: "retainKeys list of maps changes a field and clear a field", StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ Original: []byte(` -mergingIntList: - - 1 - - 2 - - 3 - - 3 +retainKeysMergingList: +- name: bar +- name: foo + value: old +`), + Current: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: old + other: x +`), + Modified: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: new `), TwoWay: []byte(` -$deleteFromPrimitiveList/mergingIntList: - - 3 +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + - value + name: foo + value: new +`), + ThreeWay: []byte(` +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + - value + name: foo + value: new +`), + Result: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: new +`), + }, + }, + { + Description: "retainKeys list of maps changes a field and clear a field with conflict", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: old +`), + Current: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: modified + other: x `), Modified: []byte(` -mergingIntList: - - 1 - - 2 +retainKeysMergingList: +- name: bar +- name: foo + value: new +`), + TwoWay: []byte(` +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + - value + name: foo + value: new +`), + ThreeWay: []byte(` +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + - value + name: foo + value: new +`), + Result: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: new +`), + }, + }, + { + Description: "retainKeys list of maps adds a field", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMergingList: +- name: bar +- name: foo `), Current: []byte(` -mergingIntList: - - 1 - - 2 - - 3 - - 3 - - 4 +retainKeysMergingList: +- name: bar +- name: foo +`), + Modified: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: a +`), + TwoWay: []byte(` +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + - value + name: foo + value: a `), ThreeWay: []byte(` -$deleteFromPrimitiveList/mergingIntList: - - 3 +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + - value + name: foo + value: a `), Result: []byte(` -mergingIntList: - - 1 - - 2 - - 4 +retainKeysMergingList: +- name: bar +- name: foo + value: a `), }, }, { - Description: "add and delete items in lists of scalars", + Description: "retainKeys list of maps adds a field and clear a field", StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ Original: []byte(` -mergingIntList: - - 1 - - 2 - - 3 +retainKeysMergingList: +- name: bar +- name: foo +`), + Current: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + other: x +`), + Modified: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: a `), TwoWay: []byte(` -$deleteFromPrimitiveList/mergingIntList: - - 3 -mergingIntList: - - 4 +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + - value + name: foo + value: a +`), + ThreeWay: []byte(` +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + - value + name: foo + value: a +`), + Result: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: a +`), + }, + }, + { + Description: "retainKeys list of maps deletes a field", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: a +`), + Current: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: a `), Modified: []byte(` -mergingIntList: - - 1 - - 2 - - 4 +retainKeysMergingList: +- name: bar +- name: foo +`), + TwoWay: []byte(` +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + name: foo + value: null +`), + ThreeWay: []byte(` +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + name: foo + value: null +`), + Result: []byte(` +retainKeysMergingList: +- name: bar +- name: foo +`), + }, + }, + { + Description: "retainKeys list of maps deletes a field and clear a field", + StrategicMergePatchRawTestCaseData: StrategicMergePatchRawTestCaseData{ + Original: []byte(` +retainKeysMergingList: +- name: bar +- name: foo + value: a `), Current: []byte(` -mergingIntList: - - 1 - - 2 - - 3 - - 4 +retainKeysMergingList: +- name: bar +- name: foo + value: a + other: x +`), + Modified: []byte(` +retainKeysMergingList: +- name: bar +- name: foo +`), + TwoWay: []byte(` +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + name: foo + value: null `), ThreeWay: []byte(` -$deleteFromPrimitiveList/mergingIntList: - - 3 +$setElementOrder/retainKeysMergingList: + - name: bar + - name: foo +retainKeysMergingList: +- $retainKeys: + - name + name: foo + value: null `), Result: []byte(` -mergingIntList: - - 1 - - 2 - - 4 +retainKeysMergingList: +- name: bar +- name: foo `), }, }, @@ -2046,7 +6025,7 @@ func testTwoWayPatch(t *testing.T, c StrategicMergePatchTestCase) { } testPatchCreation(t, expectedPatch, actualPatch, c.Description) - testPatchApplication(t, original, actualPatch, expectedResult, c.Description) + testPatchApplication(t, original, actualPatch, expectedResult, c.Description, "") } func testTwoWayPatchForRawTestCase(t *testing.T, c StrategicMergePatchRawTestCase) { @@ -2060,7 +6039,7 @@ func testTwoWayPatchForRawTestCase(t *testing.T, c StrategicMergePatchRawTestCas } testPatchCreation(t, expectedPatch, actualPatch, c.Description) - testPatchApplication(t, original, actualPatch, expectedResult, c.Description) + testPatchApplication(t, original, actualPatch, expectedResult, c.Description, c.ExpectedError) } func twoWayTestCaseToJSONOrFail(t *testing.T, c StrategicMergePatchTestCase) ([]byte, []byte, []byte, []byte) { @@ -2110,7 +6089,7 @@ func testThreeWayPatch(t *testing.T, c StrategicMergePatchTestCase) { } testPatchCreation(t, expected, actual, c.Description) - testPatchApplication(t, current, actual, result, c.Description) + testPatchApplication(t, current, actual, result, c.Description, "") } return @@ -2123,7 +6102,7 @@ func testThreeWayPatch(t *testing.T, c StrategicMergePatchTestCase) { } testPatchCreation(t, expected, actual, c.Description) - testPatchApplication(t, current, actual, result, c.Description) + testPatchApplication(t, current, actual, result, c.Description, "") } func testThreeWayPatchForRawTestCase(t *testing.T, c StrategicMergePatchRawTestCase) { @@ -2151,7 +6130,7 @@ func testThreeWayPatchForRawTestCase(t *testing.T, c StrategicMergePatchRawTestC } testPatchCreation(t, expected, actual, c.Description) - testPatchApplication(t, current, actual, result, c.Description) + testPatchApplication(t, current, actual, result, c.Description, c.ExpectedError) } return @@ -2164,7 +6143,7 @@ func testThreeWayPatchForRawTestCase(t *testing.T, c StrategicMergePatchRawTestC } testPatchCreation(t, expected, actual, c.Description) - testPatchApplication(t, current, actual, result, c.Description) + testPatchApplication(t, current, actual, result, c.Description, c.ExpectedError) } func threeWayTestCaseToJSONOrFail(t *testing.T, c StrategicMergePatchTestCase) ([]byte, []byte, []byte, []byte, []byte) { @@ -2184,40 +6163,32 @@ func threeWayRawTestCaseToJSONOrFail(t *testing.T, c StrategicMergePatchRawTestC } func testPatchCreation(t *testing.T, expected, actual []byte, description string) { - sorted, err := sortMergeListsByName(actual, mergeItem) - if err != nil { - t.Errorf("error: %s\nin test case: %s\ncannot sort patch:\n%s\n", - err, description, jsonToYAMLOrError(actual)) - return - } - - if !reflect.DeepEqual(sorted, expected) { + if !reflect.DeepEqual(actual, expected) { t.Errorf("error in test case: %s\nexpected patch:\n%s\ngot:\n%s\n", - description, jsonToYAMLOrError(expected), jsonToYAMLOrError(sorted)) + description, jsonToYAMLOrError(expected), jsonToYAMLOrError(actual)) return } } -func testPatchApplication(t *testing.T, original, patch, expected []byte, description string) { +func testPatchApplication(t *testing.T, original, patch, expected []byte, description, expectedError string) { result, err := StrategicMergePatch(original, patch, mergeItem) + if len(expectedError) != 0 { + if err != nil && strings.Contains(err.Error(), expectedError) { + return + } + t.Errorf("expected error should contain:\n%s\nin test case: %s\nbut got:\n%s\n", expectedError, description, err) + } if err != nil { t.Errorf("error: %s\nin test case: %s\ncannot apply patch:\n%s\nto original:\n%s\n", err, description, jsonToYAMLOrError(patch), jsonToYAMLOrError(original)) return } - sorted, err := sortMergeListsByName(result, mergeItem) - if err != nil { - t.Errorf("error: %s\nin test case: %s\ncannot sort result object:\n%s\n", - err, description, jsonToYAMLOrError(result)) - return - } - - if !reflect.DeepEqual(sorted, expected) { + if !reflect.DeepEqual(result, expected) { format := "error in test case: %s\npatch application failed:\noriginal:\n%s\npatch:\n%s\nexpected:\n%s\ngot:\n%s\n" t.Errorf(format, description, jsonToYAMLOrError(original), jsonToYAMLOrError(patch), - jsonToYAMLOrError(expected), jsonToYAMLOrError(sorted)) + jsonToYAMLOrError(expected), jsonToYAMLOrError(result)) return } } @@ -2502,6 +6473,9 @@ replacingItem: The: RawExtension `), TwoWay: []byte(` +$setElementOrder/merginglist: + - name: 1 + - name: 2 merginglist: - name: 2 replacingItem: @@ -2522,6 +6496,9 @@ replacingItem: The: RawExtension `), ThreeWay: []byte(` +$setElementOrder/merginglist: + - name: 1 + - name: 2 merginglist: - name: 2 replacingItem: @@ -2535,8 +6512,8 @@ value: some-value other: current-other merginglist: - name: 1 - - name: 3 - name: 2 + - name: 3 replacingItem: Newly: Modified Yaml: Inside @@ -2548,88 +6525,8 @@ replacingItem: func TestReplaceWithRawExtension(t *testing.T) { for _, c := range replaceRawExtensionPatchTestCases { - testTwoWayPatchWithoutSorting(t, c) - testThreeWayPatchWithoutSorting(t, c) - } -} - -func testTwoWayPatchWithoutSorting(t *testing.T, c StrategicMergePatchRawTestCase) { - original, expectedPatch, modified, expectedResult := twoWayRawTestCaseToJSONOrFail(t, c) - - actualPatch, err := CreateTwoWayMergePatch(original, modified, mergeItem) - if err != nil { - t.Errorf("error: %s\nin test case: %s\ncannot create two way patch:\noriginal:%s\ntwoWay:%s\nmodified:%s\ncurrent:%s\nthreeWay:%s\nresult:%s\n", - err, c.Description, c.Original, c.TwoWay, c.Modified, c.Current, c.ThreeWay, c.Result) - return - } - - testPatchCreationWithoutSorting(t, expectedPatch, actualPatch, c.Description) - testPatchApplicationWithoutSorting(t, original, actualPatch, expectedResult, c.Description) -} - -func testThreeWayPatchWithoutSorting(t *testing.T, c StrategicMergePatchRawTestCase) { - original, modified, current, expected, result := threeWayRawTestCaseToJSONOrFail(t, c) - actual, err := CreateThreeWayMergePatch(original, modified, current, mergeItem, false) - if err != nil { - if !mergepatch.IsConflict(err) { - t.Errorf("error: %s\nin test case: %s\ncannot create three way patch:\noriginal:%s\ntwoWay:%s\nmodified:%s\ncurrent:%s\nthreeWay:%s\nresult:%s\n", - err, c.Description, c.Original, c.TwoWay, c.Modified, c.Current, c.ThreeWay, c.Result) - return - } - - if !strings.Contains(c.Description, "conflict") { - t.Errorf("unexpected conflict: %s\nin test case: %s\ncannot create three way patch:\noriginal:%s\ntwoWay:%s\nmodified:%s\ncurrent:%s\nthreeWay:%s\nresult:%s\n", - err, c.Description, c.Original, c.TwoWay, c.Modified, c.Current, c.ThreeWay, c.Result) - return - } - - if len(c.Result) > 0 { - actual, err := CreateThreeWayMergePatch(original, modified, current, mergeItem, true) - if err != nil { - t.Errorf("error: %s\nin test case: %s\ncannot force three way patch application:\noriginal:%s\ntwoWay:%s\nmodified:%s\ncurrent:%s\nthreeWay:%s\nresult:%s\n", - err, c.Description, c.Original, c.TwoWay, c.Modified, c.Current, c.ThreeWay, c.Result) - return - } - - testPatchCreationWithoutSorting(t, expected, actual, c.Description) - testPatchApplicationWithoutSorting(t, current, actual, result, c.Description) - } - - return - } - - if strings.Contains(c.Description, "conflict") || len(c.Result) < 1 { - t.Errorf("error: %s\nin test case: %s\nexpected conflict did not occur:\noriginal:%s\ntwoWay:%s\nmodified:%s\ncurrent:%s\nthreeWay:%s\nresult:%s\n", - err, c.Description, c.Original, c.TwoWay, c.Modified, c.Current, c.ThreeWay, c.Result) - return - } - - testPatchCreationWithoutSorting(t, expected, actual, c.Description) - testPatchApplicationWithoutSorting(t, current, actual, result, c.Description) -} - -func testPatchCreationWithoutSorting(t *testing.T, expected, actual []byte, description string) { - if !reflect.DeepEqual(actual, expected) { - t.Errorf("error in test case: %s\nexpected patch:\n%s\ngot:\n%s\n", - description, jsonToYAMLOrError(expected), jsonToYAMLOrError(actual)) - return - } -} - -func testPatchApplicationWithoutSorting(t *testing.T, original, patch, expected []byte, description string) { - result, err := StrategicMergePatch(original, patch, mergeItem) - if err != nil { - t.Errorf("error: %s\nin test case: %s\ncannot apply patch:\n%s\nto original:\n%s\n", - err, description, jsonToYAMLOrError(patch), jsonToYAMLOrError(original)) - return - } - - if !reflect.DeepEqual(result, expected) { - format := "error in test case: %s\npatch application failed:\noriginal:\n%s\npatch:\n%s\nexpected:\n%s\ngot:\n%s\n" - t.Errorf(format, description, - jsonToYAMLOrError(original), jsonToYAMLOrError(patch), - jsonToYAMLOrError(expected), jsonToYAMLOrError(result)) - return + testTwoWayPatchForRawTestCase(t, c) + testThreeWayPatchForRawTestCase(t, c) } } diff --git a/staging/src/k8s.io/apimachinery/pkg/util/wait/wait.go b/staging/src/k8s.io/apimachinery/pkg/util/wait/wait.go index 1538550e3dd02..badaa21596c86 100644 --- a/staging/src/k8s.io/apimachinery/pkg/util/wait/wait.go +++ b/staging/src/k8s.io/apimachinery/pkg/util/wait/wait.go @@ -65,9 +65,9 @@ func NonSlidingUntil(f func(), period time.Duration, stopCh <-chan struct{}) { // JitterUntil loops until stop channel is closed, running f every period. // // If jitterFactor is positive, the period is jittered before every run of f. -// If jitterFactor is not positive, the period is unchanged and not jitterd. +// If jitterFactor is not positive, the period is unchanged and not jittered. // -// If slidingis true, the period is computed after f runs. If it is false then +// If sliding is true, the period is computed after f runs. If it is false then // period includes the runtime for f. // // Close stopCh to stop. f may not be invoked if stop channel is already @@ -138,14 +138,14 @@ type ConditionFunc func() (done bool, err error) // Backoff holds parameters applied to a Backoff function. type Backoff struct { Duration time.Duration // the base duration - Factor float64 // Duration is multipled by factor each iteration + Factor float64 // Duration is multiplied by factor each iteration Jitter float64 // The amount of jitter applied each iteration Steps int // Exit with error after this many steps } // ExponentialBackoff repeats a condition check with exponential backoff. // -// It checks the condition up to Steps times, increasing the wait by multipling +// It checks the condition up to Steps times, increasing the wait by multiplying // the previous duration by Factor. // // If Jitter is greater than zero, a random amount of each duration is added diff --git a/staging/src/k8s.io/apimachinery/pkg/watch/until.go b/staging/src/k8s.io/apimachinery/pkg/watch/until.go index 6e139de5907f3..c2772ddb57a6a 100644 --- a/staging/src/k8s.io/apimachinery/pkg/watch/until.go +++ b/staging/src/k8s.io/apimachinery/pkg/watch/until.go @@ -29,8 +29,8 @@ import ( // from false to true). type ConditionFunc func(event Event) (bool, error) -// errWatchClosed is returned when the watch channel is closed before timeout in Until. -var errWatchClosed = errors.New("watch closed before Until timeout") +// ErrWatchClosed is returned when the watch channel is closed before timeout in Until. +var ErrWatchClosed = errors.New("watch closed before Until timeout") // Until reads items from the watch until each provided condition succeeds, and then returns the last watch // encountered. The first condition that returns an error terminates the watch (and the event is also returned). @@ -65,7 +65,7 @@ func Until(timeout time.Duration, watcher Interface, conditions ...ConditionFunc select { case event, ok := <-ch: if !ok { - return lastEvent, errWatchClosed + return lastEvent, ErrWatchClosed } lastEvent = &event diff --git a/staging/src/k8s.io/apimachinery/third_party/forked/golang/json/OWNERS b/staging/src/k8s.io/apimachinery/third_party/forked/golang/json/OWNERS new file mode 100644 index 0000000000000..8e8d9fce8efa8 --- /dev/null +++ b/staging/src/k8s.io/apimachinery/third_party/forked/golang/json/OWNERS @@ -0,0 +1,5 @@ +approvers: +- pwittrock +reviewers: +- mengqiy +- apelisse diff --git a/staging/src/k8s.io/apimachinery/third_party/forked/golang/json/fields.go b/staging/src/k8s.io/apimachinery/third_party/forked/golang/json/fields.go index 1d17270ee4681..ac6d9cb96b1d3 100644 --- a/staging/src/k8s.io/apimachinery/third_party/forked/golang/json/fields.go +++ b/staging/src/k8s.io/apimachinery/third_party/forked/golang/json/fields.go @@ -17,16 +17,25 @@ import ( "unicode/utf8" ) +const ( + patchStrategyTagKey = "patchStrategy" + patchMergeKeyTagKey = "patchMergeKey" +) + // Finds the patchStrategy and patchMergeKey struct tag fields on a given // struct field given the struct type and the JSON name of the field. +// It returns field type, a slice of patch strategies, merge key and error. // TODO: fix the returned errors to be introspectable. -func LookupPatchMetadata(t reflect.Type, jsonField string) (reflect.Type, string, string, error) { +func LookupPatchMetadata(t reflect.Type, jsonField string) ( + elemType reflect.Type, patchStrategies []string, patchMergeKey string, e error) { if t.Kind() == reflect.Map { - return t.Elem(), "", "", nil + elemType = t.Elem() + return } if t.Kind() != reflect.Struct { - return nil, "", "", fmt.Errorf("merging an object in json but data type is not map or struct, instead is: %s", + e = fmt.Errorf("merging an object in json but data type is not map or struct, instead is: %s", t.Kind().String()) + return } jf := []byte(jsonField) // Find the field that the JSON library would use. @@ -50,11 +59,14 @@ func LookupPatchMetadata(t reflect.Type, jsonField string) (reflect.Type, string for i := 1; i < len(f.index); i++ { tjf = tjf.Type.Field(f.index[i]) } - patchStrategy := tjf.Tag.Get("patchStrategy") - patchMergeKey := tjf.Tag.Get("patchMergeKey") - return tjf.Type, patchStrategy, patchMergeKey, nil + patchStrategy := tjf.Tag.Get(patchStrategyTagKey) + patchMergeKey = tjf.Tag.Get(patchMergeKeyTagKey) + patchStrategies = strings.Split(patchStrategy, ",") + elemType = tjf.Type + return } - return nil, "", "", fmt.Errorf("unable to find api field in struct %s for the json field %q", t.Name(), jsonField) + e = fmt.Errorf("unable to find api field in struct %s for the json field %q", t.Name(), jsonField) + return } // A field represents a single field found in a struct. diff --git a/plugin/pkg/admission/namespace/lifecycle/BUILD b/staging/src/k8s.io/apiserver/pkg/admission/plugin/namespace/lifecycle/BUILD similarity index 63% rename from plugin/pkg/admission/namespace/lifecycle/BUILD rename to staging/src/k8s.io/apiserver/pkg/admission/plugin/namespace/lifecycle/BUILD index 5d0428688abcc..10bba641e2b46 100644 --- a/plugin/pkg/admission/namespace/lifecycle/BUILD +++ b/staging/src/k8s.io/apiserver/pkg/admission/plugin/namespace/lifecycle/BUILD @@ -13,11 +13,6 @@ go_library( srcs = ["admission.go"], tags = ["automanaged"], deps = [ - "//pkg/api:go_default_library", - "//pkg/client/clientset_generated/internalclientset:go_default_library", - "//pkg/client/informers/informers_generated/internalversion:go_default_library", - "//pkg/client/listers/core/internalversion:go_default_library", - "//pkg/kubeapiserver/admission:go_default_library", "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", @@ -26,6 +21,11 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/util/clock:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", "//vendor/k8s.io/apiserver/pkg/admission:go_default_library", + "//vendor/k8s.io/apiserver/pkg/admission/initializer:go_default_library", + "//vendor/k8s.io/client-go/informers:go_default_library", + "//vendor/k8s.io/client-go/kubernetes:go_default_library", + "//vendor/k8s.io/client-go/listers/core/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", ], ) @@ -35,11 +35,6 @@ go_test( library = ":go_default_library", tags = ["automanaged"], deps = [ - "//pkg/api:go_default_library", - "//pkg/client/clientset_generated/internalclientset:go_default_library", - "//pkg/client/clientset_generated/internalclientset/fake:go_default_library", - "//pkg/client/informers/informers_generated/internalversion:go_default_library", - "//pkg/kubeapiserver/admission:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", @@ -47,19 +42,11 @@ go_test( "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", "//vendor/k8s.io/apiserver/pkg/admission:go_default_library", + "//vendor/k8s.io/apiserver/pkg/admission/initializer:go_default_library", + "//vendor/k8s.io/client-go/informers:go_default_library", + "//vendor/k8s.io/client-go/kubernetes:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/fake:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", "//vendor/k8s.io/client-go/testing:go_default_library", ], ) - -filegroup( - name = "package-srcs", - srcs = glob(["**"]), - tags = ["automanaged"], - visibility = ["//visibility:private"], -) - -filegroup( - name = "all-srcs", - srcs = [":package-srcs"], - tags = ["automanaged"], -) diff --git a/plugin/pkg/admission/namespace/lifecycle/admission.go b/staging/src/k8s.io/apiserver/pkg/admission/plugin/namespace/lifecycle/admission.go similarity index 86% rename from plugin/pkg/admission/namespace/lifecycle/admission.go rename to staging/src/k8s.io/apiserver/pkg/admission/plugin/namespace/lifecycle/admission.go index aab86656a17a0..e01445621e21d 100644 --- a/plugin/pkg/admission/namespace/lifecycle/admission.go +++ b/staging/src/k8s.io/apiserver/pkg/admission/plugin/namespace/lifecycle/admission.go @@ -30,11 +30,11 @@ import ( "k8s.io/apimachinery/pkg/util/clock" "k8s.io/apimachinery/pkg/util/sets" "k8s.io/apiserver/pkg/admission" - "k8s.io/kubernetes/pkg/api" - "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset" - informers "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion" - corelisters "k8s.io/kubernetes/pkg/client/listers/core/internalversion" - kubeapiserveradmission "k8s.io/kubernetes/pkg/kubeapiserver/admission" + "k8s.io/apiserver/pkg/admission/initializer" + "k8s.io/client-go/informers" + "k8s.io/client-go/kubernetes" + corelisters "k8s.io/client-go/listers/core/v1" + "k8s.io/client-go/pkg/api/v1" ) const ( @@ -61,7 +61,7 @@ func Register(plugins *admission.Plugins) { // It enforces life-cycle constraints around a Namespace depending on its Phase type lifecycle struct { *admission.Handler - client internalclientset.Interface + client kubernetes.Interface immortalNamespaces sets.String namespaceLister corelisters.NamespaceLister // forceLiveLookupCache holds a list of entries for namespaces that we have a strong reason to believe are stale in our local cache. @@ -73,11 +73,11 @@ type forceLiveLookupEntry struct { expiry time.Time } -var _ = kubeapiserveradmission.WantsInternalKubeInformerFactory(&lifecycle{}) -var _ = kubeapiserveradmission.WantsInternalKubeClientSet(&lifecycle{}) +var _ = initializer.WantsExternalKubeInformerFactory(&lifecycle{}) +var _ = initializer.WantsExternalKubeClientSet(&lifecycle{}) -func makeNamespaceKey(namespace string) *api.Namespace { - return &api.Namespace{ +func makeNamespaceKey(namespace string) *v1.Namespace { + return &v1.Namespace{ ObjectMeta: metav1.ObjectMeta{ Name: namespace, Namespace: "", @@ -87,14 +87,14 @@ func makeNamespaceKey(namespace string) *api.Namespace { func (l *lifecycle) Admit(a admission.Attributes) error { // prevent deletion of immortal namespaces - if a.GetOperation() == admission.Delete && a.GetKind().GroupKind() == api.Kind("Namespace") && l.immortalNamespaces.Has(a.GetName()) { + if a.GetOperation() == admission.Delete && a.GetKind().GroupKind() == v1.SchemeGroupVersion.WithKind("Namespace").GroupKind() && l.immortalNamespaces.Has(a.GetName()) { return errors.NewForbidden(a.GetResource().GroupResource(), a.GetName(), fmt.Errorf("this namespace may not be deleted")) } // if we're here, then we've already passed authentication, so we're allowed to do what we're trying to do // if we're here, then the API server has found a route, which means that if we have a non-empty namespace // its a namespaced resource. - if len(a.GetNamespace()) == 0 || a.GetKind().GroupKind() == api.Kind("Namespace") { + if len(a.GetNamespace()) == 0 || a.GetKind().GroupKind() == v1.SchemeGroupVersion.WithKind("Namespace").GroupKind() { // if a namespace is deleted, we want to prevent all further creates into it // while it is undergoing termination. to reduce incidences where the cache // is slow to update, we add the namespace into a force live lookup list to ensure @@ -151,7 +151,7 @@ func (l *lifecycle) Admit(a admission.Attributes) error { forceLiveLookup := false if _, ok := l.forceLiveLookupCache.Get(a.GetNamespace()); ok { // we think the namespace was marked for deletion, but our current local cache says otherwise, we will force a live lookup. - forceLiveLookup = exists && namespace.Status.Phase == api.NamespaceActive + forceLiveLookup = exists && namespace.Status.Phase == v1.NamespaceActive } // refuse to operate on non-existent namespaces @@ -169,7 +169,7 @@ func (l *lifecycle) Admit(a admission.Attributes) error { // ensure that we're not trying to create objects in terminating namespaces if a.GetOperation() == admission.Create { - if namespace.Status.Phase != api.NamespaceTerminating { + if namespace.Status.Phase != v1.NamespaceTerminating { return nil } @@ -194,13 +194,13 @@ func newLifecycleWithClock(immortalNamespaces sets.String, clock utilcache.Clock }, nil } -func (l *lifecycle) SetInternalKubeInformerFactory(f informers.SharedInformerFactory) { - namespaceInformer := f.Core().InternalVersion().Namespaces() +func (l *lifecycle) SetExternalKubeInformerFactory(f informers.SharedInformerFactory) { + namespaceInformer := f.Core().V1().Namespaces() l.namespaceLister = namespaceInformer.Lister() l.SetReadyFunc(namespaceInformer.Informer().HasSynced) } -func (l *lifecycle) SetInternalKubeClientSet(client internalclientset.Interface) { +func (l *lifecycle) SetExternalKubeClientSet(client kubernetes.Interface) { l.client = client } diff --git a/plugin/pkg/admission/namespace/lifecycle/admission_test.go b/staging/src/k8s.io/apiserver/pkg/admission/plugin/namespace/lifecycle/admission_test.go similarity index 65% rename from plugin/pkg/admission/namespace/lifecycle/admission_test.go rename to staging/src/k8s.io/apiserver/pkg/admission/plugin/namespace/lifecycle/admission_test.go index 39ce5f0da1738..7b2e2b064130b 100644 --- a/plugin/pkg/admission/namespace/lifecycle/admission_test.go +++ b/staging/src/k8s.io/apiserver/pkg/admission/plugin/namespace/lifecycle/admission_test.go @@ -28,12 +28,12 @@ import ( "k8s.io/apimachinery/pkg/util/sets" "k8s.io/apimachinery/pkg/util/wait" "k8s.io/apiserver/pkg/admission" + kubeadmission "k8s.io/apiserver/pkg/admission/initializer" + informers "k8s.io/client-go/informers" + clientset "k8s.io/client-go/kubernetes" + "k8s.io/client-go/kubernetes/fake" + "k8s.io/client-go/pkg/api/v1" core "k8s.io/client-go/testing" - "k8s.io/kubernetes/pkg/api" - clientset "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset" - "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset/fake" - informers "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion" - kubeadmission "k8s.io/kubernetes/pkg/kubeapiserver/admission" ) // newHandlerForTest returns a configured handler for testing. @@ -48,29 +48,32 @@ func newHandlerForTestWithClock(c clientset.Interface, cacheClock clock.Clock) ( if err != nil { return nil, f, err } - pluginInitializer := kubeadmission.NewPluginInitializer(c, f, nil, nil, nil, nil) + pluginInitializer, err := kubeadmission.New(c, f, nil) + if err != nil { + return handler, f, err + } pluginInitializer.Initialize(handler) err = admission.Validate(handler) return handler, f, err } // newMockClientForTest creates a mock client that returns a client configured for the specified list of namespaces with the specified phase. -func newMockClientForTest(namespaces map[string]api.NamespacePhase) *fake.Clientset { +func newMockClientForTest(namespaces map[string]v1.NamespacePhase) *fake.Clientset { mockClient := &fake.Clientset{} mockClient.AddReactor("list", "namespaces", func(action core.Action) (bool, runtime.Object, error) { - namespaceList := &api.NamespaceList{ + namespaceList := &v1.NamespaceList{ ListMeta: metav1.ListMeta{ ResourceVersion: fmt.Sprintf("%d", len(namespaces)), }, } index := 0 for name, phase := range namespaces { - namespaceList.Items = append(namespaceList.Items, api.Namespace{ + namespaceList.Items = append(namespaceList.Items, v1.Namespace{ ObjectMeta: metav1.ObjectMeta{ Name: name, ResourceVersion: fmt.Sprintf("%d", index), }, - Status: api.NamespaceStatus{ + Status: v1.NamespaceStatus{ Phase: phase, }, }) @@ -82,19 +85,19 @@ func newMockClientForTest(namespaces map[string]api.NamespacePhase) *fake.Client } // newPod returns a new pod for the specified namespace -func newPod(namespace string) api.Pod { - return api.Pod{ +func newPod(namespace string) v1.Pod { + return v1.Pod{ ObjectMeta: metav1.ObjectMeta{Name: "123", Namespace: namespace}, - Spec: api.PodSpec{ - Volumes: []api.Volume{{Name: "vol"}}, - Containers: []api.Container{{Name: "ctr", Image: "image"}}, + Spec: v1.PodSpec{ + Volumes: []v1.Volume{{Name: "vol"}}, + Containers: []v1.Container{{Name: "ctr", Image: "image"}}, }, } } func TestAccessReviewCheckOnMissingNamespace(t *testing.T) { namespace := "test" - mockClient := newMockClientForTest(map[string]api.NamespacePhase{}) + mockClient := newMockClientForTest(map[string]v1.NamespacePhase{}) mockClient.AddReactor("get", "namespaces", func(action core.Action) (bool, runtime.Object, error) { return true, nil, fmt.Errorf("nope, out of luck") }) @@ -113,7 +116,7 @@ func TestAccessReviewCheckOnMissingNamespace(t *testing.T) { // TestAdmissionNamespaceDoesNotExist verifies pod is not admitted if namespace does not exist. func TestAdmissionNamespaceDoesNotExist(t *testing.T) { namespace := "test" - mockClient := newMockClientForTest(map[string]api.NamespacePhase{}) + mockClient := newMockClientForTest(map[string]v1.NamespacePhase{}) mockClient.AddReactor("get", "namespaces", func(action core.Action) (bool, runtime.Object, error) { return true, nil, fmt.Errorf("nope, out of luck") }) @@ -124,7 +127,7 @@ func TestAdmissionNamespaceDoesNotExist(t *testing.T) { informerFactory.Start(wait.NeverStop) pod := newPod(namespace) - err = handler.Admit(admission.NewAttributesRecord(&pod, nil, api.Kind("Pod").WithVersion("version"), pod.Namespace, pod.Name, api.Resource("pods").WithVersion("version"), "", admission.Create, nil)) + err = handler.Admit(admission.NewAttributesRecord(&pod, nil, v1.SchemeGroupVersion.WithKind("Pod").GroupKind().WithVersion("version"), pod.Namespace, pod.Name, v1.Resource("pods").WithVersion("version"), "", admission.Create, nil)) if err == nil { actions := "" for _, action := range mockClient.Actions() { @@ -137,8 +140,8 @@ func TestAdmissionNamespaceDoesNotExist(t *testing.T) { // TestAdmissionNamespaceActive verifies a resource is admitted when the namespace is active. func TestAdmissionNamespaceActive(t *testing.T) { namespace := "test" - mockClient := newMockClientForTest(map[string]api.NamespacePhase{ - namespace: api.NamespaceActive, + mockClient := newMockClientForTest(map[string]v1.NamespacePhase{ + namespace: v1.NamespaceActive, }) handler, informerFactory, err := newHandlerForTest(mockClient) @@ -148,7 +151,7 @@ func TestAdmissionNamespaceActive(t *testing.T) { informerFactory.Start(wait.NeverStop) pod := newPod(namespace) - err = handler.Admit(admission.NewAttributesRecord(&pod, nil, api.Kind("Pod").WithVersion("version"), pod.Namespace, pod.Name, api.Resource("pods").WithVersion("version"), "", admission.Create, nil)) + err = handler.Admit(admission.NewAttributesRecord(&pod, nil, v1.SchemeGroupVersion.WithKind("Pod").GroupKind().WithVersion("version"), pod.Namespace, pod.Name, v1.Resource("pods").WithVersion("version"), "", admission.Create, nil)) if err != nil { t.Errorf("unexpected error returned from admission handler") } @@ -157,8 +160,8 @@ func TestAdmissionNamespaceActive(t *testing.T) { // TestAdmissionNamespaceTerminating verifies a resource is not created when the namespace is active. func TestAdmissionNamespaceTerminating(t *testing.T) { namespace := "test" - mockClient := newMockClientForTest(map[string]api.NamespacePhase{ - namespace: api.NamespaceTerminating, + mockClient := newMockClientForTest(map[string]v1.NamespacePhase{ + namespace: v1.NamespaceTerminating, }) handler, informerFactory, err := newHandlerForTest(mockClient) @@ -169,31 +172,31 @@ func TestAdmissionNamespaceTerminating(t *testing.T) { pod := newPod(namespace) // verify create operations in the namespace cause an error - err = handler.Admit(admission.NewAttributesRecord(&pod, nil, api.Kind("Pod").WithVersion("version"), pod.Namespace, pod.Name, api.Resource("pods").WithVersion("version"), "", admission.Create, nil)) + err = handler.Admit(admission.NewAttributesRecord(&pod, nil, v1.SchemeGroupVersion.WithKind("Pod").GroupKind().WithVersion("version"), pod.Namespace, pod.Name, v1.Resource("pods").WithVersion("version"), "", admission.Create, nil)) if err == nil { t.Errorf("Expected error rejecting creates in a namespace when it is terminating") } // verify update operations in the namespace can proceed - err = handler.Admit(admission.NewAttributesRecord(&pod, nil, api.Kind("Pod").WithVersion("version"), pod.Namespace, pod.Name, api.Resource("pods").WithVersion("version"), "", admission.Update, nil)) + err = handler.Admit(admission.NewAttributesRecord(&pod, nil, v1.SchemeGroupVersion.WithKind("Pod").GroupKind().WithVersion("version"), pod.Namespace, pod.Name, v1.Resource("pods").WithVersion("version"), "", admission.Update, nil)) if err != nil { t.Errorf("Unexpected error returned from admission handler: %v", err) } // verify delete operations in the namespace can proceed - err = handler.Admit(admission.NewAttributesRecord(nil, nil, api.Kind("Pod").WithVersion("version"), pod.Namespace, pod.Name, api.Resource("pods").WithVersion("version"), "", admission.Delete, nil)) + err = handler.Admit(admission.NewAttributesRecord(nil, nil, v1.SchemeGroupVersion.WithKind("Pod").GroupKind().WithVersion("version"), pod.Namespace, pod.Name, v1.Resource("pods").WithVersion("version"), "", admission.Delete, nil)) if err != nil { t.Errorf("Unexpected error returned from admission handler: %v", err) } // verify delete of namespace default can never proceed - err = handler.Admit(admission.NewAttributesRecord(nil, nil, api.Kind("Namespace").WithVersion("version"), "", metav1.NamespaceDefault, api.Resource("namespaces").WithVersion("version"), "", admission.Delete, nil)) + err = handler.Admit(admission.NewAttributesRecord(nil, nil, v1.SchemeGroupVersion.WithKind("Namespace").GroupKind().WithVersion("version"), "", metav1.NamespaceDefault, v1.Resource("namespaces").WithVersion("version"), "", admission.Delete, nil)) if err == nil { t.Errorf("Expected an error that this namespace can never be deleted") } // verify delete of namespace other than default can proceed - err = handler.Admit(admission.NewAttributesRecord(nil, nil, api.Kind("Namespace").WithVersion("version"), "", "other", api.Resource("namespaces").WithVersion("version"), "", admission.Delete, nil)) + err = handler.Admit(admission.NewAttributesRecord(nil, nil, v1.SchemeGroupVersion.WithKind("Namespace").GroupKind().WithVersion("version"), "", "other", v1.Resource("namespaces").WithVersion("version"), "", admission.Delete, nil)) if err != nil { t.Errorf("Did not expect an error %v", err) } @@ -203,11 +206,11 @@ func TestAdmissionNamespaceTerminating(t *testing.T) { func TestAdmissionNamespaceForceLiveLookup(t *testing.T) { namespace := "test" getCalls := int64(0) - phases := map[string]api.NamespacePhase{namespace: api.NamespaceActive} + phases := map[string]v1.NamespacePhase{namespace: v1.NamespaceActive} mockClient := newMockClientForTest(phases) mockClient.AddReactor("get", "namespaces", func(action core.Action) (bool, runtime.Object, error) { getCalls++ - return true, &api.Namespace{ObjectMeta: metav1.ObjectMeta{Name: namespace}, Status: api.NamespaceStatus{Phase: phases[namespace]}}, nil + return true, &v1.Namespace{ObjectMeta: metav1.ObjectMeta{Name: namespace}, Status: v1.NamespaceStatus{Phase: phases[namespace]}}, nil }) fakeClock := clock.NewFakeClock(time.Now()) @@ -220,7 +223,7 @@ func TestAdmissionNamespaceForceLiveLookup(t *testing.T) { pod := newPod(namespace) // verify create operations in the namespace is allowed - err = handler.Admit(admission.NewAttributesRecord(&pod, nil, api.Kind("Pod").WithVersion("version"), pod.Namespace, pod.Name, api.Resource("pods").WithVersion("version"), "", admission.Create, nil)) + err = handler.Admit(admission.NewAttributesRecord(&pod, nil, v1.SchemeGroupVersion.WithKind("Pod").GroupKind().WithVersion("version"), pod.Namespace, pod.Name, v1.Resource("pods").WithVersion("version"), "", admission.Create, nil)) if err != nil { t.Errorf("Unexpected error rejecting creates in an active namespace") } @@ -230,7 +233,7 @@ func TestAdmissionNamespaceForceLiveLookup(t *testing.T) { getCalls = 0 // verify delete of namespace can proceed - err = handler.Admit(admission.NewAttributesRecord(nil, nil, api.Kind("Namespace").WithVersion("version"), "", namespace, api.Resource("namespaces").WithVersion("version"), "", admission.Delete, nil)) + err = handler.Admit(admission.NewAttributesRecord(nil, nil, v1.SchemeGroupVersion.WithKind("Namespace").GroupKind().WithVersion("version"), "", namespace, v1.Resource("namespaces").WithVersion("version"), "", admission.Delete, nil)) if err != nil { t.Errorf("Expected namespace deletion to be allowed") } @@ -240,10 +243,10 @@ func TestAdmissionNamespaceForceLiveLookup(t *testing.T) { getCalls = 0 // simulate the phase changing - phases[namespace] = api.NamespaceTerminating + phases[namespace] = v1.NamespaceTerminating // verify create operations in the namespace cause an error - err = handler.Admit(admission.NewAttributesRecord(&pod, nil, api.Kind("Pod").WithVersion("version"), pod.Namespace, pod.Name, api.Resource("pods").WithVersion("version"), "", admission.Create, nil)) + err = handler.Admit(admission.NewAttributesRecord(&pod, nil, v1.SchemeGroupVersion.WithKind("Pod").GroupKind().WithVersion("version"), pod.Namespace, pod.Name, v1.Resource("pods").WithVersion("version"), "", admission.Create, nil)) if err == nil { t.Errorf("Expected error rejecting creates in a namespace right after deleting it") } @@ -256,7 +259,7 @@ func TestAdmissionNamespaceForceLiveLookup(t *testing.T) { fakeClock.Step(forceLiveLookupTTL) // verify create operations in the namespace cause an error - err = handler.Admit(admission.NewAttributesRecord(&pod, nil, api.Kind("Pod").WithVersion("version"), pod.Namespace, pod.Name, api.Resource("pods").WithVersion("version"), "", admission.Create, nil)) + err = handler.Admit(admission.NewAttributesRecord(&pod, nil, v1.SchemeGroupVersion.WithKind("Pod").GroupKind().WithVersion("version"), pod.Namespace, pod.Name, v1.Resource("pods").WithVersion("version"), "", admission.Create, nil)) if err == nil { t.Errorf("Expected error rejecting creates in a namespace right after deleting it") } @@ -269,7 +272,7 @@ func TestAdmissionNamespaceForceLiveLookup(t *testing.T) { fakeClock.Step(time.Millisecond) // verify create operations in the namespace don't force a live lookup after the timeout - handler.Admit(admission.NewAttributesRecord(&pod, nil, api.Kind("Pod").WithVersion("version"), pod.Namespace, pod.Name, api.Resource("pods").WithVersion("version"), "", admission.Create, nil)) + handler.Admit(admission.NewAttributesRecord(&pod, nil, v1.SchemeGroupVersion.WithKind("Pod").GroupKind().WithVersion("version"), pod.Namespace, pod.Name, v1.Resource("pods").WithVersion("version"), "", admission.Create, nil)) if getCalls != 0 { t.Errorf("Expected no live lookup of the namespace at t=forceLiveLookupTTL+1ms, got %d", getCalls) } diff --git a/staging/src/k8s.io/apiserver/pkg/apis/audit/helpers.go b/staging/src/k8s.io/apiserver/pkg/apis/audit/helpers.go index 3f54fc1e843bb..05fe72c0ff953 100644 --- a/staging/src/k8s.io/apiserver/pkg/apis/audit/helpers.go +++ b/staging/src/k8s.io/apiserver/pkg/apis/audit/helpers.go @@ -36,11 +36,3 @@ func (a Level) Less(b Level) bool { func (a Level) GreaterOrEqual(b Level) bool { return ordLevel(a) >= ordLevel(b) } - -func NewConstantPolicy(level Level) *Policy { - return &Policy{ - Rules: []PolicyRule{ - {Level: level}, - }, - } -} diff --git a/staging/src/k8s.io/apiserver/pkg/apis/audit/types.go b/staging/src/k8s.io/apiserver/pkg/apis/audit/types.go index 47ed85d615cdd..0ca857678cead 100644 --- a/staging/src/k8s.io/apiserver/pkg/apis/audit/types.go +++ b/staging/src/k8s.io/apiserver/pkg/apis/audit/types.go @@ -61,6 +61,8 @@ const ( // The stage for events generated once the response body has been completed, and no more bytes // will be sent. StageResponseComplete = "ResponseComplete" + // The stage for events generated when a panic occured. + StagePanic = "Panic" ) // Event captures all the information that can be included in an API audit log. diff --git a/staging/src/k8s.io/apiserver/pkg/apis/audit/v1alpha1/types.go b/staging/src/k8s.io/apiserver/pkg/apis/audit/v1alpha1/types.go index 33886a6e426ca..a08e55da83ac4 100644 --- a/staging/src/k8s.io/apiserver/pkg/apis/audit/v1alpha1/types.go +++ b/staging/src/k8s.io/apiserver/pkg/apis/audit/v1alpha1/types.go @@ -62,6 +62,8 @@ const ( // The stage for events generated once the response body has been completed, and no more bytes // will be sent. StageResponseComplete = "ResponseComplete" + // The stage for events generated when a panic occured. + StagePanic = "Panic" ) // Event captures all the information that can be included in an API audit log. diff --git a/staging/src/k8s.io/apiserver/pkg/apis/audit/validation/BUILD b/staging/src/k8s.io/apiserver/pkg/apis/audit/validation/BUILD new file mode 100644 index 0000000000000..63cbc6bacd89f --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/apis/audit/validation/BUILD @@ -0,0 +1,27 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["validation_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = ["//vendor/k8s.io/apiserver/pkg/apis/audit:go_default_library"], +) + +go_library( + name = "go_default_library", + srcs = ["validation.go"], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/util/validation/field:go_default_library", + "//vendor/k8s.io/apiserver/pkg/apis/audit:go_default_library", + ], +) diff --git a/staging/src/k8s.io/apiserver/pkg/apis/audit/validation/validation.go b/staging/src/k8s.io/apiserver/pkg/apis/audit/validation/validation.go new file mode 100644 index 0000000000000..2ceead05f4bb3 --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/apis/audit/validation/validation.go @@ -0,0 +1,62 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package validation + +import ( + "k8s.io/apimachinery/pkg/util/validation/field" + "k8s.io/apiserver/pkg/apis/audit" +) + +func ValidatePolicy(policy *audit.Policy) field.ErrorList { + var allErrs field.ErrorList + rulePath := field.NewPath("rules") + for i, rule := range policy.Rules { + allErrs = append(allErrs, validatePolicyRule(rule, rulePath.Index(i))...) + } + return allErrs +} + +func validatePolicyRule(rule audit.PolicyRule, fldPath *field.Path) field.ErrorList { + var allErrs field.ErrorList + allErrs = append(allErrs, validateLevel(rule.Level, fldPath.Child("level"))...) + + if len(rule.NonResourceURLs) > 0 { + if len(rule.Resources) > 0 || len(rule.Namespaces) > 0 { + allErrs = append(allErrs, field.Invalid(fldPath.Child("nonResourceURLs"), rule.NonResourceURLs, "rules cannot apply to both regular resources and non-resource URLs")) + } + } + + return allErrs +} + +var validLevels = []string{ + string(audit.LevelNone), + string(audit.LevelMetadata), + string(audit.LevelRequest), + string(audit.LevelRequestResponse), +} + +func validateLevel(level audit.Level, fldPath *field.Path) field.ErrorList { + switch level { + case audit.LevelNone, audit.LevelMetadata, audit.LevelRequest, audit.LevelRequestResponse: + return nil + case "": + return field.ErrorList{field.Required(fldPath, "")} + default: + return field.ErrorList{field.NotSupported(fldPath, level, validLevels)} + } +} diff --git a/staging/src/k8s.io/apiserver/pkg/apis/audit/validation/validation_test.go b/staging/src/k8s.io/apiserver/pkg/apis/audit/validation/validation_test.go new file mode 100644 index 0000000000000..07e354bc7bf74 --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/apis/audit/validation/validation_test.go @@ -0,0 +1,89 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package validation + +import ( + "testing" + + "k8s.io/apiserver/pkg/apis/audit" +) + +func TestValidatePolicy(t *testing.T) { + validRules := []audit.PolicyRule{ + { // Defaulting rule + Level: audit.LevelMetadata, + }, { // Matching non-humans + Level: audit.LevelNone, + UserGroups: []string{"system:serviceaccounts", "system:nodes"}, + }, { // Specific request + Level: audit.LevelRequestResponse, + Verbs: []string{"get"}, + Resources: []audit.GroupResources{{Resources: []string{"secrets"}}}, + Namespaces: []string{"kube-system"}, + }, { // Some non-resource URLs + Level: audit.LevelMetadata, + UserGroups: []string{"developers"}, + NonResourceURLs: []string{ + "/logs*", + "/healthz*", + "/metrics", + }, + }, + } + successCases := []audit.Policy{} + for _, rule := range validRules { + successCases = append(successCases, audit.Policy{Rules: []audit.PolicyRule{rule}}) + } + successCases = append(successCases, audit.Policy{}) // Empty policy is valid. + successCases = append(successCases, audit.Policy{Rules: validRules}) // Multiple rules. + + for i, policy := range successCases { + if errs := ValidatePolicy(&policy); len(errs) != 0 { + t.Errorf("[%d] Expected policy %#v to be valid: %v", i, policy, errs) + } + } + + invalidRules := []audit.PolicyRule{ + {}, // Empty rule (missing Level) + { // Missing level + Verbs: []string{"get"}, + Resources: []audit.GroupResources{{Resources: []string{"secrets"}}}, + Namespaces: []string{"kube-system"}, + }, { // Invalid Level + Level: "FooBar", + }, { // NonResourceURLs + Namespaces + Level: audit.LevelMetadata, + Namespaces: []string{"default"}, + NonResourceURLs: []string{"/logs*"}, + }, { // NonResourceURLs + ResourceKinds + Level: audit.LevelMetadata, + Resources: []audit.GroupResources{{Resources: []string{"secrets"}}}, + NonResourceURLs: []string{"/logs*"}, + }, + } + errorCases := []audit.Policy{} + for _, rule := range invalidRules { + errorCases = append(errorCases, audit.Policy{Rules: []audit.PolicyRule{rule}}) + } + errorCases = append(errorCases, audit.Policy{Rules: append(validRules, audit.PolicyRule{})}) // Multiple rules. + + for i, policy := range errorCases { + if errs := ValidatePolicy(&policy); len(errs) == 0 { + t.Errorf("[%d] Expected policy %#v to be invalid!", i, policy) + } + } +} diff --git a/staging/src/k8s.io/apiserver/pkg/audit/BUILD b/staging/src/k8s.io/apiserver/pkg/audit/BUILD index 298acbed73324..4e67f4299351e 100644 --- a/staging/src/k8s.io/apiserver/pkg/audit/BUILD +++ b/staging/src/k8s.io/apiserver/pkg/audit/BUILD @@ -5,13 +5,16 @@ licenses(["notice"]) load( "@io_bazel_rules_go//go:def.bzl", "go_library", + "go_test", ) go_library( name = "go_default_library", srcs = [ "request.go", + "scheme.go", "types.go", + "union.go", ], tags = ["automanaged"], deps = [ @@ -20,10 +23,24 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/errors:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/net:go_default_library", "//vendor/k8s.io/apiserver/pkg/apis/audit:go_default_library", + "//vendor/k8s.io/apiserver/pkg/apis/audit/v1alpha1:go_default_library", "//vendor/k8s.io/apiserver/pkg/authorization/authorizer:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/authentication/v1:go_default_library", ], ) + +go_test( + name = "go_default_test", + srcs = ["union_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apiserver/pkg/apis/audit:go_default_library", + ], +) diff --git a/staging/src/k8s.io/apiserver/pkg/audit/policy/BUILD b/staging/src/k8s.io/apiserver/pkg/audit/policy/BUILD new file mode 100644 index 0000000000000..3ceb86a349cb3 --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/audit/policy/BUILD @@ -0,0 +1,44 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "checker_test.go", + "reader_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/github.com/stretchr/testify/assert:go_default_library", + "//vendor/github.com/stretchr/testify/require:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/diff:go_default_library", + "//vendor/k8s.io/apiserver/pkg/apis/audit:go_default_library", + "//vendor/k8s.io/apiserver/pkg/authentication/user:go_default_library", + "//vendor/k8s.io/apiserver/pkg/authorization/authorizer:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "checker.go", + "reader.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apiserver/pkg/apis/audit:go_default_library", + "//vendor/k8s.io/apiserver/pkg/apis/audit/v1alpha1:go_default_library", + "//vendor/k8s.io/apiserver/pkg/apis/audit/validation:go_default_library", + "//vendor/k8s.io/apiserver/pkg/audit:go_default_library", + "//vendor/k8s.io/apiserver/pkg/authorization/authorizer:go_default_library", + ], +) diff --git a/staging/src/k8s.io/apiserver/pkg/audit/policy/checker.go b/staging/src/k8s.io/apiserver/pkg/audit/policy/checker.go new file mode 100644 index 0000000000000..526710c2c6fc4 --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/audit/policy/checker.go @@ -0,0 +1,177 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package policy + +import ( + "strings" + + "k8s.io/apiserver/pkg/apis/audit" + "k8s.io/apiserver/pkg/authorization/authorizer" +) + +const ( + // DefaultAuditLevel is the default level to audit at, if no policy rules are matched. + DefaultAuditLevel = audit.LevelNone +) + +// Checker exposes methods for checking the policy rules. +type Checker interface { + // Check the audit level for a request with the given authorizer attributes. + Level(authorizer.Attributes) audit.Level +} + +// NewChecker creates a new policy checker. +func NewChecker(policy *audit.Policy) Checker { + return &policyChecker{*policy} +} + +// FakeChecker creates a checker that returns a constant level for all requests (for testing). +func FakeChecker(level audit.Level) Checker { + return &fakeChecker{level} +} + +type policyChecker struct { + audit.Policy +} + +func (p *policyChecker) Level(attrs authorizer.Attributes) audit.Level { + for _, rule := range p.Rules { + if ruleMatches(&rule, attrs) { + return rule.Level + } + } + return DefaultAuditLevel +} + +// Check whether the rule matches the request attrs. +func ruleMatches(r *audit.PolicyRule, attrs authorizer.Attributes) bool { + if len(r.Users) > 0 { + if !hasString(r.Users, attrs.GetUser().GetName()) { + return false + } + } + if len(r.UserGroups) > 0 { + matched := false + for _, group := range attrs.GetUser().GetGroups() { + if hasString(r.UserGroups, group) { + matched = true + break + } + } + if !matched { + return false + } + } + if len(r.Verbs) > 0 { + if !hasString(r.Verbs, attrs.GetVerb()) { + return false + } + } + + if len(r.Namespaces) > 0 || len(r.Resources) > 0 { + return ruleMatchesResource(r, attrs) + } + + if len(r.NonResourceURLs) > 0 { + return ruleMatchesNonResource(r, attrs) + } + + return true +} + +// Check whether the rule's non-resource URLs match the request attrs. +func ruleMatchesNonResource(r *audit.PolicyRule, attrs authorizer.Attributes) bool { + if attrs.IsResourceRequest() { + return false + } + + path := attrs.GetPath() + for _, spec := range r.NonResourceURLs { + if pathMatches(path, spec) { + return true + } + } + + return false +} + +// Check whether the path matches the path specification. +func pathMatches(path, spec string) bool { + // Allow wildcard match + if spec == "*" { + return true + } + // Allow exact match + if spec == path { + return true + } + // Allow a trailing * subpath match + if strings.HasSuffix(spec, "*") && strings.HasPrefix(path, strings.TrimRight(spec, "*")) { + return true + } + return false +} + +// Check whether the rule's resource fields match the request attrs. +func ruleMatchesResource(r *audit.PolicyRule, attrs authorizer.Attributes) bool { + if !attrs.IsResourceRequest() { + return false + } + + if len(r.Namespaces) > 0 { + if !hasString(r.Namespaces, attrs.GetNamespace()) { // Non-namespaced resources use the empty string. + return false + } + } + if len(r.Resources) == 0 { + return true + } + + apiGroup := attrs.GetAPIGroup() + resource := attrs.GetResource() + for _, gr := range r.Resources { + if gr.Group == apiGroup { + if len(gr.Resources) == 0 { + return true + } + for _, res := range gr.Resources { + if res == resource { + return true + } + } + } + } + return false +} + +// Utility function to check whether a string slice contains a string. +func hasString(slice []string, value string) bool { + for _, s := range slice { + if s == value { + return true + } + } + return false +} + +type fakeChecker struct { + level audit.Level +} + +func (f *fakeChecker) Level(_ authorizer.Attributes) audit.Level { + return f.level +} diff --git a/staging/src/k8s.io/apiserver/pkg/audit/policy/checker_test.go b/staging/src/k8s.io/apiserver/pkg/audit/policy/checker_test.go new file mode 100644 index 0000000000000..29cf1a4689a9a --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/audit/policy/checker_test.go @@ -0,0 +1,162 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package policy + +import ( + "strings" + "testing" + + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + + "k8s.io/apiserver/pkg/apis/audit" + "k8s.io/apiserver/pkg/authentication/user" + "k8s.io/apiserver/pkg/authorization/authorizer" +) + +func TestChecker(t *testing.T) { + tim := &user.DefaultInfo{ + Name: "tim@k8s.io", + Groups: []string{"humans", "developers"}, + } + attrs := map[string]authorizer.Attributes{ + "namespaced": &authorizer.AttributesRecord{ + User: tim, + Verb: "get", + Namespace: "default", + APIGroup: "", // Core + APIVersion: "v1", + Resource: "pods", + Name: "busybox", + ResourceRequest: true, + Path: "/api/v1/namespaces/default/pods/busybox", + }, + "cluster": &authorizer.AttributesRecord{ + User: tim, + Verb: "get", + APIGroup: "rbac.authorization.k8s.io", // Core + APIVersion: "v1beta1", + Resource: "clusterroles", + Name: "edit", + ResourceRequest: true, + Path: "/apis/rbac.authorization.k8s.io/v1beta1/clusterroles/edit", + }, + "nonResource": &authorizer.AttributesRecord{ + User: tim, + Verb: "get", + ResourceRequest: false, + Path: "/logs/kubelet.log", + }, + } + + rules := map[string]audit.PolicyRule{ + "default": { + Level: audit.LevelMetadata, + }, + "create": { + Level: audit.LevelRequest, + Verbs: []string{"create"}, + }, + "tims": { + Level: audit.LevelMetadata, + Users: []string{"tim@k8s.io"}, + }, + "humans": { + Level: audit.LevelMetadata, + UserGroups: []string{"humans"}, + }, + "serviceAccounts": { + Level: audit.LevelRequest, + UserGroups: []string{"system:serviceaccounts"}, + }, + "getPods": { + Level: audit.LevelRequestResponse, + Verbs: []string{"get"}, + Resources: []audit.GroupResources{{Resources: []string{"pods"}}}, + }, + "getClusterRoles": { + Level: audit.LevelRequestResponse, + Verbs: []string{"get"}, + Resources: []audit.GroupResources{{ + Group: "rbac.authorization.k8s.io", + Resources: []string{"clusterroles"}, + }}, + Namespaces: []string{""}, + }, + "getLogs": { + Level: audit.LevelRequestResponse, + Verbs: []string{"get"}, + NonResourceURLs: []string{ + "/logs*", + }, + }, + "getMetrics": { + Level: audit.LevelRequest, + Verbs: []string{"get"}, + NonResourceURLs: []string{ + "/metrics", + }, + }, + } + + test := func(req string, expected audit.Level, ruleNames ...string) { + policy := audit.Policy{} + for _, rule := range ruleNames { + require.Contains(t, rules, rule) + policy.Rules = append(policy.Rules, rules[rule]) + } + require.Contains(t, attrs, req) + actual := NewChecker(&policy).Level(attrs[req]) + assert.Equal(t, expected, actual, "request:%s rules:%s", req, strings.Join(ruleNames, ",")) + } + + test("namespaced", audit.LevelMetadata, "default") + test("namespaced", audit.LevelNone, "create") + test("namespaced", audit.LevelMetadata, "tims") + test("namespaced", audit.LevelMetadata, "humans") + test("namespaced", audit.LevelNone, "serviceAccounts") + test("namespaced", audit.LevelRequestResponse, "getPods") + test("namespaced", audit.LevelNone, "getClusterRoles") + test("namespaced", audit.LevelNone, "getLogs") + test("namespaced", audit.LevelNone, "getMetrics") + test("namespaced", audit.LevelMetadata, "getMetrics", "serviceAccounts", "default") + test("namespaced", audit.LevelRequestResponse, "getMetrics", "getPods", "default") + + test("cluster", audit.LevelMetadata, "default") + test("cluster", audit.LevelNone, "create") + test("cluster", audit.LevelMetadata, "tims") + test("cluster", audit.LevelMetadata, "humans") + test("cluster", audit.LevelNone, "serviceAccounts") + test("cluster", audit.LevelNone, "getPods") + test("cluster", audit.LevelRequestResponse, "getClusterRoles") + test("cluster", audit.LevelNone, "getLogs") + test("cluster", audit.LevelNone, "getMetrics") + test("cluster", audit.LevelMetadata, "getMetrics", "serviceAccounts", "default") + test("cluster", audit.LevelRequestResponse, "getMetrics", "getClusterRoles", "default") + + test("nonResource", audit.LevelMetadata, "default") + test("nonResource", audit.LevelNone, "create") + test("nonResource", audit.LevelMetadata, "tims") + test("nonResource", audit.LevelMetadata, "humans") + test("nonResource", audit.LevelNone, "serviceAccounts") + test("nonResource", audit.LevelNone, "getPods") + test("nonResource", audit.LevelNone, "getClusterRoles") + test("nonResource", audit.LevelRequestResponse, "getLogs") + test("nonResource", audit.LevelNone, "getMetrics") + test("nonResource", audit.LevelMetadata, "getMetrics", "serviceAccounts", "default") + test("nonResource", audit.LevelRequestResponse, "getLogs", "getClusterRoles", "default") +} diff --git a/staging/src/k8s.io/apiserver/pkg/audit/policy/reader.go b/staging/src/k8s.io/apiserver/pkg/audit/policy/reader.go new file mode 100644 index 0000000000000..afd50152e1e0c --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/audit/policy/reader.go @@ -0,0 +1,57 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package policy + +import ( + "fmt" + "io/ioutil" + + "k8s.io/apimachinery/pkg/runtime" + auditinternal "k8s.io/apiserver/pkg/apis/audit" + auditv1alpha1 "k8s.io/apiserver/pkg/apis/audit/v1alpha1" + "k8s.io/apiserver/pkg/apis/audit/validation" + "k8s.io/apiserver/pkg/audit" +) + +func LoadPolicyFromFile(filePath string) (*auditinternal.Policy, error) { + if filePath == "" { + return nil, fmt.Errorf("file path not specified") + } + policyDef, err := ioutil.ReadFile(filePath) + if err != nil { + return nil, fmt.Errorf("failed to read file path %q: %+v", filePath, err) + } + if len(policyDef) == 0 { + return nil, fmt.Errorf("file %q was empty", filePath) + } + policyVersioned := &auditv1alpha1.Policy{} + + decoder := audit.Codecs.UniversalDecoder(auditv1alpha1.SchemeGroupVersion) + if err := runtime.DecodeInto(decoder, policyDef, policyVersioned); err != nil { + return nil, fmt.Errorf("failed decoding file %q: %v", filePath, err) + } + + policy := &auditinternal.Policy{} + if err := audit.Scheme.Convert(policyVersioned, policy, nil); err != nil { + return nil, fmt.Errorf("failed converting policy: %v", err) + } + + if err := validation.ValidatePolicy(policy); err != nil { + return nil, err.ToAggregate() + } + return policy, nil +} diff --git a/staging/src/k8s.io/apiserver/pkg/audit/policy/reader_test.go b/staging/src/k8s.io/apiserver/pkg/audit/policy/reader_test.go new file mode 100644 index 0000000000000..be76364f59cac --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/audit/policy/reader_test.go @@ -0,0 +1,86 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package policy + +import ( + "io/ioutil" + "os" + "reflect" + "testing" + + "k8s.io/apimachinery/pkg/util/diff" + "k8s.io/apiserver/pkg/apis/audit" + + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" +) + +const policyDef = ` +rules: + - level: None + nonResourceURLs: + - /healthz* + - /version + - level: RequestResponse + users: ["tim"] + userGroups: ["testers", "developers"] + verbs: ["patch", "delete", "create"] + resources: + - group: "" + - group: "rbac.authorization.k8s.io" + resources: ["clusterroles", "clusterrolebindings"] + namespaces: ["default", "kube-system"] + - level: Metadata +` + +var expectedPolicy = &audit.Policy{ + Rules: []audit.PolicyRule{{ + Level: audit.LevelNone, + NonResourceURLs: []string{"/healthz*", "/version"}, + }, { + Level: audit.LevelRequestResponse, + Users: []string{"tim"}, + UserGroups: []string{"testers", "developers"}, + Verbs: []string{"patch", "delete", "create"}, + Resources: []audit.GroupResources{{}, { + Group: "rbac.authorization.k8s.io", + Resources: []string{"clusterroles", "clusterrolebindings"}, + }}, + Namespaces: []string{"default", "kube-system"}, + }, { + Level: audit.LevelMetadata, + }}, +} + +func TestParser(t *testing.T) { + // Create a policy file. + f, err := ioutil.TempFile("", "policy.yaml") + require.NoError(t, err) + defer os.Remove(f.Name()) + + _, err = f.WriteString(policyDef) + require.NoError(t, err) + require.NoError(t, f.Close()) + + policy, err := LoadPolicyFromFile(f.Name()) + require.NoError(t, err) + + assert.Len(t, policy.Rules, 3) // Sanity check. + if !reflect.DeepEqual(policy, expectedPolicy) { + t.Errorf("Unexpected policy! Diff:\n%s", diff.ObjectDiff(policy, expectedPolicy)) + } +} diff --git a/staging/src/k8s.io/apiserver/pkg/audit/request.go b/staging/src/k8s.io/apiserver/pkg/audit/request.go index f233da94f01cf..4332ca363d7d5 100644 --- a/staging/src/k8s.io/apiserver/pkg/audit/request.go +++ b/staging/src/k8s.io/apiserver/pkg/audit/request.go @@ -40,21 +40,14 @@ import ( authenticationv1 "k8s.io/client-go/pkg/apis/authentication/v1" ) -// NewEventFromRequest generates an audit event for the request. -func NewEventFromRequest(req *http.Request, policy *auditinternal.Policy, attribs authorizer.Attributes) (*auditinternal.Event, error) { +func NewEventFromRequest(req *http.Request, level auditinternal.Level, attribs authorizer.Attributes) (*auditinternal.Event, error) { ev := &auditinternal.Event{ Timestamp: metav1.NewTime(time.Now()), Verb: attribs.GetVerb(), RequestURI: req.URL.RequestURI(), } - // set the level - ev.Level = auditinternal.LevelNone - if policy != nil && len(policy.Rules) > 0 { - // This is just a hack to get through the test without setting a high level by default. - // TODO(audit): add the policy evalutation here - ev.Level = policy.Rules[0].Level - } + ev.Level = level // prefer the id from the headers. If not available, create a new one. // TODO(audit): do we want to forbid the header for non-front-proxy users? @@ -101,10 +94,11 @@ func NewEventFromRequest(req *http.Request, policy *auditinternal.Policy, attrib if attribs.IsResourceRequest() { ev.ObjectRef = &auditinternal.ObjectReference{ - Namespace: attribs.GetNamespace(), - Name: attribs.GetName(), - Resource: attribs.GetResource(), - APIVersion: attribs.GetAPIGroup() + "/" + attribs.GetAPIVersion(), + Namespace: attribs.GetNamespace(), + Name: attribs.GetName(), + Resource: attribs.GetResource(), + Subresource: attribs.GetSubresource(), + APIVersion: attribs.GetAPIGroup() + "/" + attribs.GetAPIVersion(), } } diff --git a/staging/src/k8s.io/apiserver/pkg/audit/scheme.go b/staging/src/k8s.io/apiserver/pkg/audit/scheme.go new file mode 100644 index 0000000000000..1ab6f5bd7c52d --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/audit/scheme.go @@ -0,0 +1,34 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// TODO: Delete this file if we generate a clientset. +package audit + +import ( + "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/apiserver/pkg/apis/audit/v1alpha1" +) + +var Scheme = runtime.NewScheme() +var Codecs = serializer.NewCodecFactory(Scheme) + +func init() { + v1.AddToGroupVersion(Scheme, schema.GroupVersion{Version: "v1"}) + v1alpha1.AddToScheme(Scheme) +} diff --git a/staging/src/k8s.io/apiserver/pkg/audit/union.go b/staging/src/k8s.io/apiserver/pkg/audit/union.go new file mode 100644 index 0000000000000..ba969cec98b6b --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/audit/union.go @@ -0,0 +1,51 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package audit + +import ( + "k8s.io/apimachinery/pkg/util/errors" + auditinternal "k8s.io/apiserver/pkg/apis/audit" +) + +// Union returns an audit Backend which logs events to a set of backends. The returned +// Sink implementation blocks in turn for each call to ProcessEvents. +func Union(backends ...Backend) Backend { + if len(backends) == 1 { + return backends[0] + } + return union{backends} +} + +type union struct { + backends []Backend +} + +func (u union) ProcessEvents(events ...*auditinternal.Event) { + for _, backend := range u.backends { + backend.ProcessEvents(events...) + } +} + +func (u union) Run(stopCh <-chan struct{}) error { + var funcs []func() error + for _, backend := range u.backends { + funcs = append(funcs, func() error { + return backend.Run(stopCh) + }) + } + return errors.AggregateGoroutines(funcs...) +} diff --git a/staging/src/k8s.io/apiserver/pkg/audit/union_test.go b/staging/src/k8s.io/apiserver/pkg/audit/union_test.go new file mode 100644 index 0000000000000..c016f3d07c716 --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/audit/union_test.go @@ -0,0 +1,73 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package audit + +import ( + "strconv" + "testing" + + "k8s.io/apimachinery/pkg/types" + auditinternal "k8s.io/apiserver/pkg/apis/audit" +) + +type fakeBackend struct { + events []*auditinternal.Event +} + +func (f *fakeBackend) ProcessEvents(events ...*auditinternal.Event) { + f.events = append(f.events, events...) +} + +func (f *fakeBackend) Run(stopCh <-chan struct{}) error { + return nil +} + +func TestUnion(t *testing.T) { + backends := []Backend{ + new(fakeBackend), + new(fakeBackend), + new(fakeBackend), + } + + b := Union(backends...) + + n := 5 + + var events []*auditinternal.Event + for i := 0; i < n; i++ { + events = append(events, &auditinternal.Event{ + AuditID: types.UID(strconv.Itoa(i)), + }) + } + b.ProcessEvents(events...) + + for i, b := range backends { + // so we can inspect the underlying events. + backend := b.(*fakeBackend) + + if got := len(backend.events); got != n { + t.Errorf("backend %d wanted %d events, got %d", i, n, got) + continue + } + for j, event := range backend.events { + wantID := types.UID(strconv.Itoa(j)) + if event.AuditID != wantID { + t.Errorf("backend %d event %d wanted id %s, got %s", i, j, wantID, event.AuditID) + } + } + } +} diff --git a/staging/src/k8s.io/apiserver/pkg/endpoints/BUILD b/staging/src/k8s.io/apiserver/pkg/endpoints/BUILD index 9d43086babc2a..2bdc93a93adc1 100644 --- a/staging/src/k8s.io/apiserver/pkg/endpoints/BUILD +++ b/staging/src/k8s.io/apiserver/pkg/endpoints/BUILD @@ -45,6 +45,7 @@ go_test( "//vendor/k8s.io/apiserver/pkg/apis/example/fuzzer:go_default_library", "//vendor/k8s.io/apiserver/pkg/apis/example/v1:go_default_library", "//vendor/k8s.io/apiserver/pkg/audit:go_default_library", + "//vendor/k8s.io/apiserver/pkg/audit/policy:go_default_library", "//vendor/k8s.io/apiserver/pkg/endpoints/filters:go_default_library", "//vendor/k8s.io/apiserver/pkg/endpoints/handlers:go_default_library", "//vendor/k8s.io/apiserver/pkg/endpoints/handlers/responsewriters:go_default_library", diff --git a/staging/src/k8s.io/apiserver/pkg/endpoints/apiserver_test.go b/staging/src/k8s.io/apiserver/pkg/endpoints/apiserver_test.go index eb2abc3b0356b..7cc02f7b279e5 100644 --- a/staging/src/k8s.io/apiserver/pkg/endpoints/apiserver_test.go +++ b/staging/src/k8s.io/apiserver/pkg/endpoints/apiserver_test.go @@ -57,6 +57,7 @@ import ( examplefuzzer "k8s.io/apiserver/pkg/apis/example/fuzzer" examplev1 "k8s.io/apiserver/pkg/apis/example/v1" "k8s.io/apiserver/pkg/audit" + auditpolicy "k8s.io/apiserver/pkg/audit/policy" genericapifilters "k8s.io/apiserver/pkg/endpoints/filters" "k8s.io/apiserver/pkg/endpoints/handlers/responsewriters" "k8s.io/apiserver/pkg/endpoints/request" @@ -334,7 +335,7 @@ func handleInternal(storage map[string]rest.Storage, admissionControl admission. } } - handler := genericapifilters.WithAudit(mux, requestContextMapper, auditSink, auditinternal.NewConstantPolicy(auditinternal.LevelRequestResponse), func(r *http.Request, requestInfo *request.RequestInfo) bool { + handler := genericapifilters.WithAudit(mux, requestContextMapper, auditSink, auditpolicy.FakeChecker(auditinternal.LevelRequestResponse), func(r *http.Request, requestInfo *request.RequestInfo) bool { // simplified long-running check return requestInfo.Verb == "watch" || requestInfo.Verb == "proxy" }) diff --git a/staging/src/k8s.io/apiserver/pkg/endpoints/audit_test.go b/staging/src/k8s.io/apiserver/pkg/endpoints/audit_test.go index 4fd42e61a2045..728e93b2a6e8a 100644 --- a/staging/src/k8s.io/apiserver/pkg/endpoints/audit_test.go +++ b/staging/src/k8s.io/apiserver/pkg/endpoints/audit_test.go @@ -127,7 +127,7 @@ func TestAudit(t *testing.T) { }, selfLinker, 200, - 1, + 2, []eventCheck{ noRequestBody(0), responseBodyMatches(0, `{.*"name":"c".*}`), @@ -144,7 +144,7 @@ func TestAudit(t *testing.T) { namespace: "other", }, 200, - 1, + 2, []eventCheck{ noRequestBody(0), responseBodyMatches(0, `{.*"name":"a".*"name":"b".*}`), @@ -157,7 +157,7 @@ func TestAudit(t *testing.T) { }, selfLinker, 201, - 1, + 2, []eventCheck{ requestBodyIs(0, string(simpleFooJSON)), responseBodyMatches(0, `{.*"foo".*}`), @@ -170,7 +170,7 @@ func TestAudit(t *testing.T) { }, selfLinker, 405, - 1, + 2, []eventCheck{ noRequestBody(0), // the 405 is thrown long before the create handler would be executed noResponseBody(0), // the 405 is thrown long before the create handler would be executed @@ -183,7 +183,7 @@ func TestAudit(t *testing.T) { }, selfLinker, 200, - 1, + 2, []eventCheck{ noRequestBody(0), responseBodyMatches(0, `{.*"kind":"Status".*"status":"Success".*}`), @@ -196,7 +196,7 @@ func TestAudit(t *testing.T) { }, selfLinker, 200, - 1, + 2, []eventCheck{ requestBodyMatches(0, "DeleteOptions"), responseBodyMatches(0, `{.*"kind":"Status".*"status":"Success".*}`), @@ -209,7 +209,7 @@ func TestAudit(t *testing.T) { }, selfLinker, 200, - 1, + 2, []eventCheck{ requestBodyIs(0, string(simpleCPrimeJSON)), responseBodyMatches(0, `{.*"bla".*}`), @@ -222,7 +222,7 @@ func TestAudit(t *testing.T) { }, selfLinker, 400, - 1, + 2, []eventCheck{ requestBodyIs(0, string(simpleCPrimeJSON)), responseBodyMatches(0, `"Status".*"status":"Failure".*"code":400}`), @@ -242,7 +242,7 @@ func TestAudit(t *testing.T) { namespace: "other", }, 200, - 1, + 2, []eventCheck{ requestBodyIs(0, `{"labels":{"foo":"bar"}}`), responseBodyMatches(0, `"name":"c".*"labels":{"foo":"bar"}`), @@ -259,7 +259,7 @@ func TestAudit(t *testing.T) { namespace: "other", }, 200, - 2, + 3, []eventCheck{ noRequestBody(0), noResponseBody(0), diff --git a/staging/src/k8s.io/apiserver/pkg/endpoints/filters/BUILD b/staging/src/k8s.io/apiserver/pkg/endpoints/filters/BUILD index f10ee11b57d28..3c52d52c28d72 100644 --- a/staging/src/k8s.io/apiserver/pkg/endpoints/filters/BUILD +++ b/staging/src/k8s.io/apiserver/pkg/endpoints/filters/BUILD @@ -24,6 +24,7 @@ go_test( "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", "//vendor/k8s.io/apiserver/pkg/apis/audit:go_default_library", + "//vendor/k8s.io/apiserver/pkg/audit/policy:go_default_library", "//vendor/k8s.io/apiserver/pkg/authentication/authenticator:go_default_library", "//vendor/k8s.io/apiserver/pkg/authentication/user:go_default_library", "//vendor/k8s.io/apiserver/pkg/authorization/authorizer:go_default_library", @@ -56,6 +57,7 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", "//vendor/k8s.io/apiserver/pkg/apis/audit:go_default_library", "//vendor/k8s.io/apiserver/pkg/audit:go_default_library", + "//vendor/k8s.io/apiserver/pkg/audit/policy:go_default_library", "//vendor/k8s.io/apiserver/pkg/authentication/authenticator:go_default_library", "//vendor/k8s.io/apiserver/pkg/authentication/serviceaccount:go_default_library", "//vendor/k8s.io/apiserver/pkg/authentication/user:go_default_library", diff --git a/staging/src/k8s.io/apiserver/pkg/endpoints/filters/audit.go b/staging/src/k8s.io/apiserver/pkg/endpoints/filters/audit.go index b64b40341742a..02b32a00745d5 100644 --- a/staging/src/k8s.io/apiserver/pkg/endpoints/filters/audit.go +++ b/staging/src/k8s.io/apiserver/pkg/endpoints/filters/audit.go @@ -19,16 +19,16 @@ package filters import ( "bufio" "errors" + "fmt" "net" "net/http" "sync" - "fmt" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" utilruntime "k8s.io/apimachinery/pkg/util/runtime" auditinternal "k8s.io/apiserver/pkg/apis/audit" "k8s.io/apiserver/pkg/audit" + "k8s.io/apiserver/pkg/audit/policy" "k8s.io/apiserver/pkg/endpoints/handlers/responsewriters" "k8s.io/apiserver/pkg/endpoints/request" ) @@ -49,8 +49,8 @@ import ( // 2. the response line containing: // - the unique id from 1 // - response code -func WithAudit(handler http.Handler, requestContextMapper request.RequestContextMapper, sink audit.Sink, policy *auditinternal.Policy, longRunningCheck request.LongRunningRequestCheck) http.Handler { - if sink == nil { +func WithAudit(handler http.Handler, requestContextMapper request.RequestContextMapper, sink audit.Sink, policy policy.Checker, longRunningCheck request.LongRunningRequestCheck) http.Handler { + if sink == nil || policy == nil { return handler } return http.HandlerFunc(func(w http.ResponseWriter, req *http.Request) { @@ -67,7 +67,14 @@ func WithAudit(handler http.Handler, requestContextMapper request.RequestContext return } - ev, err := audit.NewEventFromRequest(req, policy, attribs) + level := policy.Level(attribs) + if level == auditinternal.LevelNone { + // Don't audit. + handler.ServeHTTP(w, req) + return + } + + ev, err := audit.NewEventFromRequest(req, level, attribs) if err != nil { utilruntime.HandleError(fmt.Errorf("failed to complete audit event from request: %v", err)) responsewriters.InternalError(w, req, errors.New("failed to update context")) @@ -81,12 +88,14 @@ func WithAudit(handler http.Handler, requestContextMapper request.RequestContext return } + ev.Stage = auditinternal.StageRequestReceived + sink.ProcessEvents(ev) + // intercept the status code - longRunning := false var longRunningSink audit.Sink if longRunningCheck != nil { ri, _ := request.RequestInfoFrom(ctx) - if longRunning = longRunningCheck(req, ri); longRunning { + if longRunningCheck(req, ri) { longRunningSink = sink } } @@ -96,19 +105,34 @@ func WithAudit(handler http.Handler, requestContextMapper request.RequestContext // running requests, this will be the second audit event. defer func() { if r := recover(); r != nil { + defer panic(r) + ev.Stage = auditinternal.StagePanic ev.ResponseStatus = &metav1.Status{ - Code: http.StatusInternalServerError, + Code: http.StatusInternalServerError, + Status: metav1.StatusFailure, + Reason: metav1.StatusReasonInternalError, + Message: fmt.Sprintf("APIServer panic'd: %v", r), } sink.ProcessEvents(ev) - panic(r) + return } - if ev.ResponseStatus == nil { - ev.ResponseStatus = &metav1.Status{ - Code: 200, - } + // if no StageResponseStarted event was sent b/c neither a status code nor a body was sent, fake it here + fakedSuccessStatus := &metav1.Status{ + Code: http.StatusOK, + Status: metav1.StatusSuccess, + Message: "Connection closed early", + } + if ev.ResponseStatus == nil && longRunningSink != nil { + ev.ResponseStatus = fakedSuccessStatus + ev.Stage = auditinternal.StageResponseStarted + longRunningSink.ProcessEvents(ev) } + ev.Stage = auditinternal.StageResponseComplete + if ev.ResponseStatus == nil { + ev.ResponseStatus = fakedSuccessStatus + } sink.ProcessEvents(ev) }() handler.ServeHTTP(respWriter, req) @@ -146,17 +170,15 @@ type auditResponseWriter struct { func (a *auditResponseWriter) processCode(code int) { a.once.Do(func() { - if a.sink != nil { - a.sink.ProcessEvents(a.event) - } - - // for now we use the ResponseStatus as marker that it's the first or second event - // of a long running request. As soon as we have such a field in the event, we can - // change this. if a.event.ResponseStatus == nil { a.event.ResponseStatus = &metav1.Status{} } a.event.ResponseStatus.Code = int32(code) + a.event.Stage = auditinternal.StageResponseStarted + + if a.sink != nil { + a.sink.ProcessEvents(a.event) + } }) } diff --git a/staging/src/k8s.io/apiserver/pkg/endpoints/filters/audit_test.go b/staging/src/k8s.io/apiserver/pkg/endpoints/filters/audit_test.go index 14dc84da4a936..b85f6c8c23f73 100644 --- a/staging/src/k8s.io/apiserver/pkg/endpoints/filters/audit_test.go +++ b/staging/src/k8s.io/apiserver/pkg/endpoints/filters/audit_test.go @@ -19,6 +19,7 @@ package filters import ( "bufio" "bytes" + "fmt" "net" "net/http" "net/http/httptest" @@ -31,6 +32,7 @@ import ( "k8s.io/apimachinery/pkg/util/wait" auditinternal "k8s.io/apiserver/pkg/apis/audit" + "k8s.io/apiserver/pkg/audit/policy" "k8s.io/apiserver/pkg/authentication/user" "k8s.io/apiserver/pkg/endpoints/request" pluginlog "k8s.io/apiserver/plugin/pkg/audit/log" @@ -176,10 +178,17 @@ func (*fakeHTTPHandler) ServeHTTP(w http.ResponseWriter, req *http.Request) { } func TestAudit(t *testing.T) { - shortRunningPrefix := `[\d\:\-\.\+TZ]+ AUDIT: id="[\w-]+" ip="127.0.0.1" method="list" user="admin" groups="" as="" asgroups="" namespace="default" uri="/api/v1/namespaces/default/pods"` - longRunningPrefix := `[\d\:\-\.\+TZ]+ AUDIT: id="[\w-]+" ip="127.0.0.1" method="watch" user="admin" groups="" as="" asgroups="" namespace="default" uri="/api/v1/namespaces/default/pods\?watch=true"` + writingShortRunningPrefix := func(stage string) string { + return fmt.Sprintf(`[\d\:\-\.\+TZ]+ AUDIT: id="[\w-]+" stage="%s" ip="127.0.0.1" method="update" user="admin" groups="" as="" asgroups="" namespace="default" uri="/api/v1/namespaces/default/pods/foo"`, stage) + } + readOnlyShortRunningPrefix := func(stage string) string { + return fmt.Sprintf(`[\d\:\-\.\+TZ]+ AUDIT: id="[\w-]+" stage="%s" ip="127.0.0.1" method="get" user="admin" groups="" as="" asgroups="" namespace="default" uri="/api/v1/namespaces/default/pods/foo"`, stage) + } + longRunningPrefix := func(stage string) string { + return fmt.Sprintf(`[\d\:\-\.\+TZ]+ AUDIT: id="[\w-]+" stage="%s" ip="127.0.0.1" method="watch" user="admin" groups="" as="" asgroups="" namespace="default" uri="/api/v1/namespaces/default/pods\?watch=true"`, stage) + } - shortRunningPath := "/api/v1/namespaces/default/pods" + shortRunningPath := "/api/v1/namespaces/default/pods/foo" longRunningPath := "/api/v1/namespaces/default/pods?watch=true" delay := 500 * time.Millisecond @@ -187,58 +196,93 @@ func TestAudit(t *testing.T) { for _, test := range []struct { desc string path string + verb string handler func(http.ResponseWriter, *http.Request) expected []string }{ - // short running requests + // short running requests with read-only verb { - "empty", + "read-only empty", shortRunningPath, + "GET", func(http.ResponseWriter, *http.Request) {}, []string{ - shortRunningPrefix + ` response="200"`, + readOnlyShortRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + readOnlyShortRunningPrefix(auditinternal.StageResponseComplete) + ` response="200"`, + }, + }, + { + "read-only panic", + shortRunningPath, + "GET", + func(w http.ResponseWriter, req *http.Request) { + panic("kaboom") + }, + []string{ + readOnlyShortRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + readOnlyShortRunningPrefix(auditinternal.StagePanic) + ` response="500"`, }, }, + + // short running request with non-read-only verb { - "sleep", + "writing empty", shortRunningPath, + "PUT", + func(http.ResponseWriter, *http.Request) {}, + []string{ + writingShortRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + writingShortRunningPrefix(auditinternal.StageResponseComplete) + ` response="200"`, + }, + }, + { + "writing sleep", + shortRunningPath, + "PUT", func(http.ResponseWriter, *http.Request) { time.Sleep(delay) }, []string{ - shortRunningPrefix + ` response="200"`, + writingShortRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + writingShortRunningPrefix(auditinternal.StageResponseComplete) + ` response="200"`, }, }, { - "403+write", + "writing 403+write", shortRunningPath, + "PUT", func(w http.ResponseWriter, req *http.Request) { w.WriteHeader(403) w.Write([]byte("foo")) }, []string{ - shortRunningPrefix + ` response="403"`, + writingShortRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + writingShortRunningPrefix(auditinternal.StageResponseComplete) + ` response="403"`, }, }, { - "panic", + "writing panic", shortRunningPath, + "PUT", func(w http.ResponseWriter, req *http.Request) { panic("kaboom") }, []string{ - shortRunningPrefix + ` response="500"`, + writingShortRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + writingShortRunningPrefix(auditinternal.StagePanic) + ` response="500"`, }, }, { - "write+panic", + "writing write+panic", shortRunningPath, + "PUT", func(w http.ResponseWriter, req *http.Request) { w.Write([]byte("foo")) panic("kaboom") }, []string{ - shortRunningPrefix + ` response="500"`, + writingShortRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + writingShortRunningPrefix(auditinternal.StagePanic) + ` response="500"`, }, }, @@ -246,100 +290,114 @@ func TestAudit(t *testing.T) { { "empty longrunning", longRunningPath, + "GET", func(http.ResponseWriter, *http.Request) {}, []string{ - longRunningPrefix + ` response="200"`, + longRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + longRunningPrefix(auditinternal.StageResponseStarted) + ` response="200"`, + longRunningPrefix(auditinternal.StageResponseComplete) + ` response="200"`, }, }, { "sleep longrunning", longRunningPath, + "GET", func(http.ResponseWriter, *http.Request) { time.Sleep(delay) }, []string{ - longRunningPrefix + ` response="200"`, + longRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + longRunningPrefix(auditinternal.StageResponseStarted) + ` response="200"`, + longRunningPrefix(auditinternal.StageResponseComplete) + ` response="200"`, }, }, { "sleep+403 longrunning", longRunningPath, + "GET", func(w http.ResponseWriter, req *http.Request) { time.Sleep(delay) w.WriteHeader(403) }, []string{ - longRunningPrefix + ` response=""`, - longRunningPrefix + ` response="403"`, + longRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + longRunningPrefix(auditinternal.StageResponseStarted) + ` response="403"`, + longRunningPrefix(auditinternal.StageResponseComplete) + ` response="403"`, }, }, { "write longrunning", longRunningPath, + "GET", func(w http.ResponseWriter, req *http.Request) { w.Write([]byte("foo")) }, []string{ - longRunningPrefix + ` response=""`, - longRunningPrefix + ` response="200"`, + longRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + longRunningPrefix(auditinternal.StageResponseStarted) + ` response="200"`, + longRunningPrefix(auditinternal.StageResponseComplete) + ` response="200"`, }, }, { "403+write longrunning", longRunningPath, + "GET", func(w http.ResponseWriter, req *http.Request) { w.WriteHeader(403) w.Write([]byte("foo")) }, []string{ - longRunningPrefix + ` response=""`, - longRunningPrefix + ` response="403"`, + longRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + longRunningPrefix(auditinternal.StageResponseStarted) + ` response="403"`, + longRunningPrefix(auditinternal.StageResponseComplete) + ` response="403"`, }, }, { "panic longrunning", longRunningPath, + "GET", func(w http.ResponseWriter, req *http.Request) { panic("kaboom") }, []string{ - longRunningPrefix + ` response="500"`, + longRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + longRunningPrefix(auditinternal.StagePanic) + ` response="500"`, }, }, { "write+panic longrunning", longRunningPath, + "GET", func(w http.ResponseWriter, req *http.Request) { w.Write([]byte("foo")) panic("kaboom") }, []string{ - longRunningPrefix + ` response=""`, - longRunningPrefix + ` response="500"`, + longRunningPrefix(auditinternal.StageRequestReceived) + ` response=""`, + longRunningPrefix(auditinternal.StageResponseStarted) + ` response="200"`, + longRunningPrefix(auditinternal.StagePanic) + ` response="500"`, }, }, } { var buf bytes.Buffer backend := pluginlog.NewBackend(&buf) + policyChecker := policy.FakeChecker(auditinternal.LevelRequestResponse) handler := WithAudit(http.HandlerFunc(test.handler), &fakeRequestContextMapper{ user: &user.DefaultInfo{Name: "admin"}, - }, backend, auditinternal.NewConstantPolicy(auditinternal.LevelRequestResponse), func(r *http.Request, ri *request.RequestInfo) bool { + }, backend, policyChecker, func(r *http.Request, ri *request.RequestInfo) bool { // simplified long-running check return ri.Verb == "watch" }) - req, _ := http.NewRequest("GET", test.path, nil) + req, _ := http.NewRequest(test.verb, test.path, nil) req.RemoteAddr = "127.0.0.1" - done := make(chan struct{}) - go func() { + func() { defer func() { recover() - close(done) }() handler.ServeHTTP(httptest.NewRecorder(), req) }() - <-done t.Logf("[%s] audit log: %v", test.desc, buf.String()) @@ -386,8 +444,29 @@ func (*fakeRequestContextMapper) Update(req *http.Request, context request.Conte } func TestAuditNoPanicOnNilUser(t *testing.T) { - handler := WithAudit(&fakeHTTPHandler{}, &fakeRequestContextMapper{}, &fakeAuditSink{}, auditinternal.NewConstantPolicy(auditinternal.LevelRequestResponse), nil) + policyChecker := policy.FakeChecker(auditinternal.LevelRequestResponse) + handler := WithAudit(&fakeHTTPHandler{}, &fakeRequestContextMapper{}, &fakeAuditSink{}, policyChecker, nil) req, _ := http.NewRequest("GET", "/api/v1/namespaces/default/pods", nil) req.RemoteAddr = "127.0.0.1" handler.ServeHTTP(httptest.NewRecorder(), req) } + +func TestAuditLevelNone(t *testing.T) { + sink := &fakeAuditSink{} + var handler http.Handler + handler = http.HandlerFunc(func(w http.ResponseWriter, _ *http.Request) { + w.WriteHeader(200) + }) + policyChecker := policy.FakeChecker(auditinternal.LevelNone) + handler = WithAudit(handler, &fakeRequestContextMapper{ + user: &user.DefaultInfo{Name: "admin"}, + }, sink, policyChecker, nil) + + req, _ := http.NewRequest("GET", "/api/v1/namespaces/default/pods", nil) + req.RemoteAddr = "127.0.0.1" + + handler.ServeHTTP(httptest.NewRecorder(), req) + if len(sink.events) > 0 { + t.Errorf("Generated events, but should not have: %#v", sink.events) + } +} diff --git a/staging/src/k8s.io/apiserver/pkg/endpoints/installer.go b/staging/src/k8s.io/apiserver/pkg/endpoints/installer.go index f7344bdb91a84..f4e66bd6ad857 100644 --- a/staging/src/k8s.io/apiserver/pkg/endpoints/installer.go +++ b/staging/src/k8s.io/apiserver/pkg/endpoints/installer.go @@ -800,8 +800,12 @@ func (a *APIInstaller) registerResourceHandlers(path string, storage rest.Storag return nil, fmt.Errorf("unrecognized action verb: %s", action.Verb) } for _, route := range routes { - route.Metadata(ROUTE_META_GVK, reqScope.Kind) - route.Metadata(ROUTE_META_ACTION, action.Verb) + route.Metadata(ROUTE_META_GVK, metav1.GroupVersionKind{ + Group: reqScope.Kind.Group, + Version: reqScope.Kind.Version, + Kind: reqScope.Kind.Kind, + }) + route.Metadata(ROUTE_META_ACTION, strings.ToLower(action.Verb)) ws.Route(route) } // Note: update GetAuthorizerAttributes() when adding a custom handler. diff --git a/staging/src/k8s.io/apiserver/pkg/features/kube_features.go b/staging/src/k8s.io/apiserver/pkg/features/kube_features.go index 8ab10fa200c04..1b896e1e55629 100644 --- a/staging/src/k8s.io/apiserver/pkg/features/kube_features.go +++ b/staging/src/k8s.io/apiserver/pkg/features/kube_features.go @@ -33,6 +33,14 @@ const ( // StreamingProxyRedirects controls whether the apiserver should intercept (and follow) // redirects from the backend (Kubelet) for streaming requests (exec/attach/port-forward). StreamingProxyRedirects utilfeature.Feature = "StreamingProxyRedirects" + + // owner: timstclair + // alpha: v1.7 + // + // AdvancedAuditing enables a much more general API auditing pipeline, which includes support for + // pluggable output backends and an audit policy specifying how different requests should be + // audited. + AdvancedAuditing utilfeature.Feature = "AdvancedAuditing" ) func init() { @@ -44,4 +52,5 @@ func init() { // available throughout Kubernetes binaries. var defaultKubernetesFeatureGates = map[utilfeature.Feature]utilfeature.FeatureSpec{ StreamingProxyRedirects: {Default: true, PreRelease: utilfeature.Beta}, + AdvancedAuditing: {Default: false, PreRelease: utilfeature.Alpha}, } diff --git a/staging/src/k8s.io/apiserver/pkg/registry/generic/registry/store.go b/staging/src/k8s.io/apiserver/pkg/registry/generic/registry/store.go index a6867426c5d27..74b0fa6b7c7a2 100644 --- a/staging/src/k8s.io/apiserver/pkg/registry/generic/registry/store.go +++ b/staging/src/k8s.io/apiserver/pkg/registry/generic/registry/store.go @@ -143,8 +143,7 @@ type Store struct { // AfterUpdate implements a further operation to run after a resource is // updated and before it is decorated, optional. AfterUpdate ObjectFunc - // DeleteStrategy implements resource-specific behavior during deletion, - // optional. + // DeleteStrategy implements resource-specific behavior during deletion. DeleteStrategy rest.RESTDeleteStrategy // AfterDelete implements a further operation to run after a resource is // deleted and before it is decorated, optional. @@ -1032,7 +1031,16 @@ func (e *Store) Watch(ctx genericapirequest.Context, options *metainternalversio func (e *Store) WatchPredicate(ctx genericapirequest.Context, p storage.SelectionPredicate, resourceVersion string) (watch.Interface, error) { if name, ok := p.MatchesSingle(); ok { if key, err := e.KeyFunc(ctx, name); err == nil { - w, err := e.Storage.Watch(ctx, key, resourceVersion, p) + // For performance reasons, we can optimize the further computations of + // selector, by removing then "matches-single" fields, because they are + // already satisfied by choosing appropriate key. + sp, err := p.RemoveMatchesSingleRequirements() + if err != nil { + glog.Warningf("Couldn't remove matches-single requirements: %v", err) + // Since we couldn't optimize selector, reset to the original one. + sp = p + } + w, err := e.Storage.Watch(ctx, key, resourceVersion, sp) if err != nil { return nil, err } @@ -1138,6 +1146,10 @@ func (e *Store) CompleteWithOptions(options *generic.StoreOptions) error { return fmt.Errorf("store for %s must have CreateStrategy or UpdateStrategy set", e.QualifiedResource.String()) } + if e.DeleteStrategy == nil { + return fmt.Errorf("store for %s must have DeleteStrategy set", e.QualifiedResource.String()) + } + if options.RESTOptions == nil { return fmt.Errorf("options for %s must have RESTOptions set", e.QualifiedResource.String()) } diff --git a/staging/src/k8s.io/apiserver/pkg/registry/rest/create.go b/staging/src/k8s.io/apiserver/pkg/registry/rest/create.go index 60ac7ccf21839..25beba65f3064 100644 --- a/staging/src/k8s.io/apiserver/pkg/registry/rest/create.go +++ b/staging/src/k8s.io/apiserver/pkg/registry/rest/create.go @@ -44,6 +44,11 @@ type RESTCreateStrategy interface { // the object. For example: remove fields that are not to be persisted, // sort order-insensitive list fields, etc. This should not remove fields // whose presence would be considered a validation error. + // + // Often implemented as a type check and an initailization or clearing of + // status. Clear the status because status changes are internal. External + // callers of an api (users) should not be setting an initial status on + // newly created objects. PrepareForCreate(ctx genericapirequest.Context, obj runtime.Object) // Validate returns an ErrorList with validation errors or nil. Validate // is invoked after default fields in the object have been filled in @@ -54,7 +59,8 @@ type RESTCreateStrategy interface { // ensures that code that operates on these objects can rely on the common // form for things like comparison. Canonicalize is invoked after // validation has succeeded but before the object has been persisted. - // This method may mutate the object. + // This method may mutate the object. Often implemented as a type check or + // empty method. Canonicalize(obj runtime.Object) } diff --git a/staging/src/k8s.io/apiserver/pkg/server/BUILD b/staging/src/k8s.io/apiserver/pkg/server/BUILD index 1526f24adbd20..29543a789f9e6 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/BUILD +++ b/staging/src/k8s.io/apiserver/pkg/server/BUILD @@ -52,6 +52,7 @@ go_library( "handler.go", "healthz.go", "hooks.go", + "plugins.go", "serve.go", ], tags = ["automanaged"], @@ -76,9 +77,10 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/util/validation:go_default_library", "//vendor/k8s.io/apimachinery/pkg/version:go_default_library", "//vendor/k8s.io/apiserver/pkg/admission:go_default_library", + "//vendor/k8s.io/apiserver/pkg/admission/plugin/namespace/lifecycle:go_default_library", "//vendor/k8s.io/apiserver/pkg/apis/apiserver/install:go_default_library", - "//vendor/k8s.io/apiserver/pkg/apis/audit:go_default_library", "//vendor/k8s.io/apiserver/pkg/audit:go_default_library", + "//vendor/k8s.io/apiserver/pkg/audit/policy:go_default_library", "//vendor/k8s.io/apiserver/pkg/authentication/authenticator:go_default_library", "//vendor/k8s.io/apiserver/pkg/authentication/authenticatorfactory:go_default_library", "//vendor/k8s.io/apiserver/pkg/authentication/request/union:go_default_library", @@ -92,12 +94,14 @@ go_library( "//vendor/k8s.io/apiserver/pkg/endpoints/handlers/responsewriters:go_default_library", "//vendor/k8s.io/apiserver/pkg/endpoints/openapi:go_default_library", "//vendor/k8s.io/apiserver/pkg/endpoints/request:go_default_library", + "//vendor/k8s.io/apiserver/pkg/features:go_default_library", "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", "//vendor/k8s.io/apiserver/pkg/registry/rest:go_default_library", "//vendor/k8s.io/apiserver/pkg/server/filters:go_default_library", "//vendor/k8s.io/apiserver/pkg/server/healthz:go_default_library", "//vendor/k8s.io/apiserver/pkg/server/mux:go_default_library", "//vendor/k8s.io/apiserver/pkg/server/routes:go_default_library", + "//vendor/k8s.io/apiserver/pkg/util/feature:go_default_library", "//vendor/k8s.io/client-go/informers:go_default_library", "//vendor/k8s.io/client-go/rest:go_default_library", "//vendor/k8s.io/client-go/util/cert:go_default_library", diff --git a/staging/src/k8s.io/apiserver/pkg/server/config.go b/staging/src/k8s.io/apiserver/pkg/server/config.go index 2475e50be93f1..9708277f37a9b 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/config.go +++ b/staging/src/k8s.io/apiserver/pkg/server/config.go @@ -20,6 +20,7 @@ import ( "crypto/tls" "crypto/x509" "fmt" + "io" "net" "net/http" goruntime "runtime" @@ -38,8 +39,8 @@ import ( "k8s.io/apimachinery/pkg/util/sets" "k8s.io/apimachinery/pkg/version" "k8s.io/apiserver/pkg/admission" - auditinternal "k8s.io/apiserver/pkg/apis/audit" "k8s.io/apiserver/pkg/audit" + auditpolicy "k8s.io/apiserver/pkg/audit/policy" "k8s.io/apiserver/pkg/authentication/authenticator" "k8s.io/apiserver/pkg/authentication/authenticatorfactory" authenticatorunion "k8s.io/apiserver/pkg/authentication/request/union" @@ -51,10 +52,12 @@ import ( genericapifilters "k8s.io/apiserver/pkg/endpoints/filters" apiopenapi "k8s.io/apiserver/pkg/endpoints/openapi" apirequest "k8s.io/apiserver/pkg/endpoints/request" + "k8s.io/apiserver/pkg/features" genericregistry "k8s.io/apiserver/pkg/registry/generic" genericfilters "k8s.io/apiserver/pkg/server/filters" "k8s.io/apiserver/pkg/server/healthz" "k8s.io/apiserver/pkg/server/routes" + utilfeature "k8s.io/apiserver/pkg/util/feature" "k8s.io/client-go/informers" restclient "k8s.io/client-go/rest" certutil "k8s.io/client-go/util/cert" @@ -101,11 +104,12 @@ type Config struct { // Version will enable the /version endpoint if non-nil Version *version.Info + // LegacyAuditWriter is the destination for audit logs. If nil, they will not be written. + LegacyAuditWriter io.Writer // AuditBackend is where audit events are sent to. AuditBackend audit.Backend - // AuditPolicy defines rules which determine the audit level for different requests. - AuditPolicy *auditinternal.Policy - + // AuditPolicyChecker makes the decision of whether and how to audit log a request. + AuditPolicyChecker auditpolicy.Checker // SupportsBasicAuth indicates that's at least one Authenticator supports basic auth // If this is true, a basic auth challenge is returned on authentication failure // TODO(roberthbailey): Remove once the server no longer supports http basic auth. @@ -247,7 +251,7 @@ func DefaultOpenAPIConfig(getDefinitions openapicommon.GetOpenAPIDefinitions, sc // WebServices set. func DefaultSwaggerConfig() *swagger.Config { return &swagger.Config{ - ApiPath: "/swaggerapi/", + ApiPath: "/swaggerapi", SwaggerPath: "/swaggerui/", SwaggerFilePath: "/swagger-ui/", SchemaFormatHandler: func(typeName string) string { @@ -365,7 +369,8 @@ func (c *Config) SkipComplete() completedConfig { } // New creates a new server which logically combines the handling chain with the passed server. -func (c completedConfig) New(delegationTarget DelegationTarget) (*GenericAPIServer, error) { +// name is used to differentiate for logging. The handler chain in particular can be difficult as it starts delgating. +func (c completedConfig) New(name string, delegationTarget DelegationTarget) (*GenericAPIServer, error) { // The delegationTarget and the config must agree on the RequestContextMapper if c.Serializer == nil { @@ -378,7 +383,7 @@ func (c completedConfig) New(delegationTarget DelegationTarget) (*GenericAPIServ handlerChainBuilder := func(handler http.Handler) http.Handler { return c.BuildHandlerChainFunc(handler, c.Config) } - apiServerHandler := NewAPIServerHandler(c.RequestContextMapper, c.Serializer, handlerChainBuilder, delegationTarget.UnprotectedHandler()) + apiServerHandler := NewAPIServerHandler(name, c.RequestContextMapper, c.Serializer, handlerChainBuilder, delegationTarget.UnprotectedHandler()) s := &GenericAPIServer{ discoveryAddresses: c.DiscoveryAddresses, @@ -445,7 +450,7 @@ func (c completedConfig) New(delegationTarget DelegationTarget) (*GenericAPIServ // use the UnprotectedHandler from the delegation target to ensure that we don't attempt to double authenticator, authorize, // or some other part of the filter chain in delegation cases. if delegationTarget.UnprotectedHandler() == nil && c.EnableIndex { - s.Handler.PostGoRestfulMux.NotFoundHandler(routes.IndexLister{ + s.Handler.NonGoRestfulMux.NotFoundHandler(routes.IndexLister{ StatusCode: http.StatusNotFound, PathProvider: s.listedPathProvider, }) @@ -457,8 +462,11 @@ func (c completedConfig) New(delegationTarget DelegationTarget) (*GenericAPIServ func DefaultBuildHandlerChain(apiHandler http.Handler, c *Config) http.Handler { handler := genericapifilters.WithAuthorization(apiHandler, c.RequestContextMapper, c.Authorizer) handler = genericapifilters.WithImpersonation(handler, c.RequestContextMapper, c.Authorizer) - // TODO(audit): use WithLegacyAudit if feature flag is false - handler = genericapifilters.WithAudit(handler, c.RequestContextMapper, c.AuditBackend, c.AuditPolicy, c.LongRunningFunc) + if utilfeature.DefaultFeatureGate.Enabled(features.AdvancedAuditing) { + handler = genericapifilters.WithAudit(handler, c.RequestContextMapper, c.AuditBackend, c.AuditPolicyChecker, c.LongRunningFunc) + } else { + handler = genericapifilters.WithLegacyAudit(handler, c.RequestContextMapper, c.LegacyAuditWriter) + } handler = genericapifilters.WithAuthentication(handler, c.RequestContextMapper, c.Authenticator, genericapifilters.Unauthorized(c.SupportsBasicAuth)) handler = genericfilters.WithCORS(handler, c.CorsAllowedOriginList, nil, nil, nil, "true") handler = genericfilters.WithPanicRecovery(handler) @@ -471,22 +479,22 @@ func DefaultBuildHandlerChain(apiHandler http.Handler, c *Config) http.Handler { func installAPI(s *GenericAPIServer, c *Config) { if c.EnableIndex { - routes.Index{}.Install(s.listedPathProvider, s.Handler.PostGoRestfulMux) + routes.Index{}.Install(s.listedPathProvider, s.Handler.NonGoRestfulMux) } if c.SwaggerConfig != nil && c.EnableSwaggerUI { - routes.SwaggerUI{}.Install(s.Handler.PostGoRestfulMux) + routes.SwaggerUI{}.Install(s.Handler.NonGoRestfulMux) } if c.EnableProfiling { - routes.Profiling{}.Install(s.Handler.PostGoRestfulMux) + routes.Profiling{}.Install(s.Handler.NonGoRestfulMux) if c.EnableContentionProfiling { goruntime.SetBlockProfileRate(1) } } if c.EnableMetrics { if c.EnableProfiling { - routes.MetricsWithReset{}.Install(s.Handler.PostGoRestfulMux) + routes.MetricsWithReset{}.Install(s.Handler.NonGoRestfulMux) } else { - routes.DefaultMetrics{}.Install(s.Handler.PostGoRestfulMux) + routes.DefaultMetrics{}.Install(s.Handler.NonGoRestfulMux) } } routes.Version{Version: c.Version}.Install(s.Handler.GoRestfulContainer) diff --git a/staging/src/k8s.io/apiserver/pkg/server/config_test.go b/staging/src/k8s.io/apiserver/pkg/server/config_test.go index 8597ec541eb6d..c94046d0b8ece 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/config_test.go +++ b/staging/src/k8s.io/apiserver/pkg/server/config_test.go @@ -52,11 +52,11 @@ func TestNewWithDelegate(t *testing.T) { return fmt.Errorf("delegate failed healthcheck") })) - delegateServer, err := delegateConfig.SkipComplete().New(EmptyDelegate) + delegateServer, err := delegateConfig.SkipComplete().New("test", EmptyDelegate) if err != nil { t.Fatal(err) } - delegateServer.Handler.PostGoRestfulMux.HandleFunc("/foo", func(w http.ResponseWriter, _ *http.Request) { + delegateServer.Handler.NonGoRestfulMux.HandleFunc("/foo", func(w http.ResponseWriter, _ *http.Request) { w.WriteHeader(http.StatusForbidden) }) @@ -81,11 +81,11 @@ func TestNewWithDelegate(t *testing.T) { return fmt.Errorf("wrapping failed healthcheck") })) - wrappingServer, err := wrappingConfig.Complete().New(delegateServer) + wrappingServer, err := wrappingConfig.Complete().New("test", delegateServer) if err != nil { t.Fatal(err) } - wrappingServer.Handler.PostGoRestfulMux.HandleFunc("/bar", func(w http.ResponseWriter, r *http.Request) { + wrappingServer.Handler.NonGoRestfulMux.HandleFunc("/bar", func(w http.ResponseWriter, r *http.Request) { w.WriteHeader(http.StatusUnauthorized) }) @@ -113,7 +113,7 @@ func TestNewWithDelegate(t *testing.T) { "/healthz/poststarthook/generic-apiserver-start-informers", "/healthz/poststarthook/wrapping-post-start-hook", "/healthz/wrapping-health", - "/swaggerapi/" + "/swaggerapi" ] }`, t) checkPath(server.URL+"/healthz", http.StatusInternalServerError, `[+]ping ok diff --git a/staging/src/k8s.io/apiserver/pkg/server/genericapiserver.go b/staging/src/k8s.io/apiserver/pkg/server/genericapiserver.go index 192180fe0f3ea..29a6fed127f11 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/genericapiserver.go +++ b/staging/src/k8s.io/apiserver/pkg/server/genericapiserver.go @@ -168,7 +168,8 @@ type DelegationTarget interface { } func (s *GenericAPIServer) UnprotectedHandler() http.Handler { - return s.Handler.GoRestfulContainer.ServeMux + // when we delegate, we need the server we're delegating to choose whether or not to use gorestful + return s.Handler.Director } func (s *GenericAPIServer) PostStartHooks() map[string]postStartHookEntry { return s.postStartHooks @@ -235,7 +236,7 @@ func (s *GenericAPIServer) PrepareRun() preparedGenericAPIServer { if s.openAPIConfig != nil { routes.OpenAPI{ Config: s.openAPIConfig, - }.Install(s.Handler.GoRestfulContainer, s.Handler.PostGoRestfulMux) + }.Install(s.Handler.GoRestfulContainer, s.Handler.NonGoRestfulMux) } s.installHealthz() diff --git a/staging/src/k8s.io/apiserver/pkg/server/genericapiserver_test.go b/staging/src/k8s.io/apiserver/pkg/server/genericapiserver_test.go index c1f355f0ed494..b8aed64c1f8ee 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/genericapiserver_test.go +++ b/staging/src/k8s.io/apiserver/pkg/server/genericapiserver_test.go @@ -114,7 +114,7 @@ func setUp(t *testing.T) (*etcdtesting.EtcdTestServer, Config, *assert.Assertion func newMaster(t *testing.T) (*GenericAPIServer, *etcdtesting.EtcdTestServer, Config, *assert.Assertions) { etcdserver, config, assert := setUp(t) - s, err := config.Complete().New(EmptyDelegate) + s, err := config.Complete().New("test", EmptyDelegate) if err != nil { t.Fatalf("Error in bringing up the server: %v", err) } @@ -146,7 +146,7 @@ func TestInstallAPIGroups(t *testing.T) { config.LegacyAPIGroupPrefixes = sets.NewString("/apiPrefix") config.DiscoveryAddresses = discovery.DefaultAddresses{DefaultAddress: "ExternalAddress"} - s, err := config.SkipComplete().New(EmptyDelegate) + s, err := config.SkipComplete().New("test", EmptyDelegate) if err != nil { t.Fatalf("Error in bringing up the server: %v", err) } @@ -309,7 +309,7 @@ func TestPrepareRun(t *testing.T) { assert.NotNil(config.SwaggerConfig) - server := httptest.NewServer(s.Handler.GoRestfulContainer.ServeMux) + server := httptest.NewServer(s.Handler.Director) defer server.Close() done := make(chan struct{}) @@ -347,13 +347,13 @@ func TestCustomHandlerChain(t *testing.T) { called = true }) - s, err := config.SkipComplete().New(EmptyDelegate) + s, err := config.SkipComplete().New("test", EmptyDelegate) if err != nil { t.Fatalf("Error in bringing up the server: %v", err) } - s.Handler.PostGoRestfulMux.Handle("/nonswagger", handler) - s.Handler.PostGoRestfulMux.Handle("/secret", handler) + s.Handler.NonGoRestfulMux.Handle("/nonswagger", handler) + s.Handler.NonGoRestfulMux.Handle("/secret", handler) type Test struct { handler http.Handler @@ -402,7 +402,7 @@ func TestNotRestRoutesHaveAuth(t *testing.T) { kubeVersion := fakeVersion() config.Version = &kubeVersion - s, err := config.SkipComplete().New(EmptyDelegate) + s, err := config.SkipComplete().New("test", EmptyDelegate) if err != nil { t.Fatalf("Error in bringing up the server: %v", err) } diff --git a/staging/src/k8s.io/apiserver/pkg/server/handler.go b/staging/src/k8s.io/apiserver/pkg/server/handler.go index 148f8a020a92e..48d1408a45cb9 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/handler.go +++ b/staging/src/k8s.io/apiserver/pkg/server/handler.go @@ -23,6 +23,7 @@ import ( "net/http" rt "runtime" "sort" + "strings" "github.com/emicklei/go-restful" "github.com/golang/glog" @@ -37,27 +38,45 @@ import ( ) // APIServerHandlers holds the different http.Handlers used by the API server. -// This includes the full handler chain, the gorestful handler (used for the API) which falls through to the postGoRestful handler -// and the postGoRestful handler (which can contain a fallthrough of its own) +// This includes the full handler chain, the director (which chooses between gorestful and nonGoRestful, +// the gorestful handler (used for the API) which falls through to the nonGoRestful handler on unregistered paths, +// and the nonGoRestful handler (which can contain a fallthrough of its own) +// FullHandlerChain -> Director -> {GoRestfulContainer,NonGoRestfulMux} based on inspection of registered web services type APIServerHandler struct { // FullHandlerChain is the one that is eventually served with. It should include the full filter - // chain and then call the GoRestfulContainer. + // chain and then call the Director. FullHandlerChain http.Handler - // The registered APIs + // The registered APIs. InstallAPIs uses this. Other servers probably shouldn't access this directly. GoRestfulContainer *restful.Container - // PostGoRestfulMux is the final HTTP handler in the chain. + // NonGoRestfulMux is the final HTTP handler in the chain. // It comes after all filters and the API handling - PostGoRestfulMux *mux.PathRecorderMux + // This is where other servers can attach handler to various parts of the chain. + NonGoRestfulMux *mux.PathRecorderMux + + // Director is here so that we can properly handle fall through and proxy cases. + // This looks a bit bonkers, but here's what's happening. We need to have /apis handling registered in gorestful in order to have + // swagger generated for compatibility. Doing that with `/apis` as a webservice, means that it forcibly 404s (no defaulting allowed) + // all requests which are not /apis or /apis/. We need those calls to fall through behind goresful for proper delegation. Trying to + // register for a pattern which includes everything behind it doesn't work because gorestful negotiates for verbs and content encoding + // and all those things go crazy when gorestful really just needs to pass through. In addition, openapi enforces unique verb constraints + // which we don't fit into and it still muddies up swagger. Trying to switch the webservices into a route doesn't work because the + // containing webservice faces all the same problems listed above. + // This leads to the crazy thing done here. Our mux does what we need, so we'll place it in front of gorestful. It will introspect to + // decide if the the route is likely to be handled by goresful and route there if needed. Otherwise, it goes to PostGoRestful mux in + // order to handle "normal" paths and delegation. Hopefully no API consumers will ever have to deal with this level of detail. I think + // we should consider completely removing gorestful. + // Other servers should only use this opaquely to delegate to an API server. + Director http.Handler } // HandlerChainBuilderFn is used to wrap the GoRestfulContainer handler using the provided handler chain. // It is normally used to apply filtering like authentication and authorization type HandlerChainBuilderFn func(apiHandler http.Handler) http.Handler -func NewAPIServerHandler(contextMapper request.RequestContextMapper, s runtime.NegotiatedSerializer, handlerChainBuilder HandlerChainBuilderFn, notFoundHandler http.Handler) *APIServerHandler { - postGoRestfulMux := genericmux.NewPathRecorderMux() +func NewAPIServerHandler(name string, contextMapper request.RequestContextMapper, s runtime.NegotiatedSerializer, handlerChainBuilder HandlerChainBuilderFn, notFoundHandler http.Handler) *APIServerHandler { + nonGoRestfulMux := genericmux.NewPathRecorderMux(name) if notFoundHandler != nil { - postGoRestfulMux.NotFoundHandler(notFoundHandler) + nonGoRestfulMux.NotFoundHandler(notFoundHandler) } gorestfulContainer := restful.NewContainer() @@ -74,14 +93,17 @@ func NewAPIServerHandler(contextMapper request.RequestContextMapper, s runtime.N serviceErrorHandler(ctx, s, serviceErr, request, response) }) - // register the defaultHandler for everything. This will allow an unhandled request to fall through to another handler instead of - // ending up with a forced 404 - gorestfulContainer.Handle("/", postGoRestfulMux) + director := director{ + name: name, + goRestfulContainer: gorestfulContainer, + nonGoRestfulMux: nonGoRestfulMux, + } return &APIServerHandler{ - FullHandlerChain: handlerChainBuilder(gorestfulContainer.ServeMux), + FullHandlerChain: handlerChainBuilder(director), GoRestfulContainer: gorestfulContainer, - PostGoRestfulMux: postGoRestfulMux, + NonGoRestfulMux: nonGoRestfulMux, + Director: director, } } @@ -92,12 +114,53 @@ func (a *APIServerHandler) ListedPaths() []string { for _, ws := range a.GoRestfulContainer.RegisteredWebServices() { handledPaths = append(handledPaths, ws.RootPath()) } - handledPaths = append(handledPaths, a.PostGoRestfulMux.ListedPaths()...) + handledPaths = append(handledPaths, a.NonGoRestfulMux.ListedPaths()...) sort.Strings(handledPaths) return handledPaths } +type director struct { + name string + goRestfulContainer *restful.Container + nonGoRestfulMux *mux.PathRecorderMux +} + +func (d director) ServeHTTP(w http.ResponseWriter, req *http.Request) { + path := req.URL.Path + + // check to see if our webservices want to claim this path + for _, ws := range d.goRestfulContainer.RegisteredWebServices() { + switch { + case ws.RootPath() == "/apis": + // if we are exactly /apis or /apis/, then we need special handling in loop. + // normally these are passed to the nonGoRestfulMux, but if discovery is enabled, it will go directly. + // We can't rely on a prefix match since /apis matches everything (see the big comment on Director above) + if path == "/apis" || path == "/apis/" { + glog.V(5).Infof("%v: %v %q satisfied by gorestful with webservice %v", d.name, req.Method, path, ws.RootPath()) + // don't use servemux here because gorestful servemuxes get messed up when removing webservices + // TODO fix gorestful, remove TPRs, or stop using gorestful + d.goRestfulContainer.Dispatch(w, req) + return + } + + case strings.HasPrefix(path, ws.RootPath()): + // ensure an exact match or a path boundary match + if len(path) == len(ws.RootPath()) || path[len(ws.RootPath())] == '/' { + glog.V(5).Infof("%v: %v %q satisfied by gorestful with webservice %v", d.name, req.Method, path, ws.RootPath()) + // don't use servemux here because gorestful servemuxes get messed up when removing webservices + // TODO fix gorestful, remove TPRs, or stop using gorestful + d.goRestfulContainer.Dispatch(w, req) + return + } + } + } + + // if we didn't find a match, then we just skip gorestful altogether + glog.V(5).Infof("%v: %v %q satisfied by nonGoRestful", d.name, req.Method, path) + d.nonGoRestfulMux.ServeHTTP(w, req) +} + //TODO: Unify with RecoverPanics? func logStackOnRecover(s runtime.NegotiatedSerializer, panicReason interface{}, w http.ResponseWriter) { var buffer bytes.Buffer diff --git a/staging/src/k8s.io/apiserver/pkg/server/healthz.go b/staging/src/k8s.io/apiserver/pkg/server/healthz.go index 527917478d31c..43e102b5cc723 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/healthz.go +++ b/staging/src/k8s.io/apiserver/pkg/server/healthz.go @@ -41,5 +41,5 @@ func (s *GenericAPIServer) installHealthz() { defer s.healthzLock.Unlock() s.healthzCreated = true - healthz.InstallHandler(s.Handler.PostGoRestfulMux, s.healthzChecks...) + healthz.InstallHandler(s.Handler.NonGoRestfulMux, s.healthzChecks...) } diff --git a/staging/src/k8s.io/apiserver/pkg/server/mux/BUILD b/staging/src/k8s.io/apiserver/pkg/server/mux/BUILD index 16b6684df213f..de2309ec3f548 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/mux/BUILD +++ b/staging/src/k8s.io/apiserver/pkg/server/mux/BUILD @@ -24,6 +24,7 @@ go_library( ], tags = ["automanaged"], deps = [ + "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", ], diff --git a/staging/src/k8s.io/apiserver/pkg/server/mux/pathrecorder.go b/staging/src/k8s.io/apiserver/pkg/server/mux/pathrecorder.go index 4583a876cb54e..2f0eb7aa5b224 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/mux/pathrecorder.go +++ b/staging/src/k8s.io/apiserver/pkg/server/mux/pathrecorder.go @@ -25,12 +25,17 @@ import ( "sync" "sync/atomic" + "github.com/golang/glog" + utilruntime "k8s.io/apimachinery/pkg/util/runtime" "k8s.io/apimachinery/pkg/util/sets" ) // PathRecorderMux wraps a mux object and records the registered exposedPaths. type PathRecorderMux struct { + // name is used for logging so you can trace requests through + name string + lock sync.Mutex notFoundHandler http.Handler pathToHandler map[string]http.Handler @@ -53,6 +58,9 @@ type PathRecorderMux struct { // pathHandler is an http.Handler that will satify requests first by exact match, then by prefix, // then by notFoundHandler type pathHandler struct { + // muxName is used for logging so you can trace requests through + muxName string + // pathToHandler is a map of exactly matching request to its handler pathToHandler map[string]http.Handler @@ -72,8 +80,9 @@ type prefixHandler struct { } // NewPathRecorderMux creates a new PathRecorderMux -func NewPathRecorderMux() *PathRecorderMux { +func NewPathRecorderMux(name string) *PathRecorderMux { ret := &PathRecorderMux{ + name: name, pathToHandler: map[string]http.Handler{}, prefixToHandler: map[string]http.Handler{}, mux: atomic.Value{}, @@ -104,6 +113,7 @@ func (m *PathRecorderMux) trackCallers(path string) { // not be consistent func (m *PathRecorderMux) refreshMuxLocked() { newMux := &pathHandler{ + muxName: m.name, pathToHandler: map[string]http.Handler{}, prefixHandlers: []prefixHandler{}, notFoundHandler: http.NotFoundHandler(), @@ -227,17 +237,20 @@ func (m *PathRecorderMux) ServeHTTP(w http.ResponseWriter, r *http.Request) { // ServeHTTP makes it an http.Handler func (h *pathHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) { if exactHandler, ok := h.pathToHandler[r.URL.Path]; ok { + glog.V(5).Infof("%v: %q satisfied by exact match", h.muxName, r.URL.Path) exactHandler.ServeHTTP(w, r) return } for _, prefixHandler := range h.prefixHandlers { if strings.HasPrefix(r.URL.Path, prefixHandler.prefix) { + glog.V(5).Infof("%v: %q satisfied by prefix %v", h.muxName, r.URL.Path, prefixHandler.prefix) prefixHandler.handler.ServeHTTP(w, r) return } } + glog.V(5).Infof("%v: %q satisfied by NotFoundHandler", h.muxName, r.URL.Path) h.notFoundHandler.ServeHTTP(w, r) } diff --git a/staging/src/k8s.io/apiserver/pkg/server/mux/pathrecorder_test.go b/staging/src/k8s.io/apiserver/pkg/server/mux/pathrecorder_test.go index 6d15b47e24c7f..1ff767915e3d8 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/mux/pathrecorder_test.go +++ b/staging/src/k8s.io/apiserver/pkg/server/mux/pathrecorder_test.go @@ -25,7 +25,7 @@ import ( ) func TestSecretHandlers(t *testing.T) { - c := NewPathRecorderMux() + c := NewPathRecorderMux("test") c.UnlistedHandleFunc("/secret", func(http.ResponseWriter, *http.Request) {}) c.HandleFunc("/nonswagger", func(http.ResponseWriter, *http.Request) {}) assert.NotContains(t, c.ListedPaths(), "/secret") @@ -36,7 +36,7 @@ func TestUnregisterHandlers(t *testing.T) { first := 0 second := 0 - c := NewPathRecorderMux() + c := NewPathRecorderMux("test") s := httptest.NewServer(c) defer s.Close() @@ -69,7 +69,7 @@ func TestUnregisterHandlers(t *testing.T) { } func TestPrefixHandlers(t *testing.T) { - c := NewPathRecorderMux() + c := NewPathRecorderMux("test") s := httptest.NewServer(c) defer s.Close() diff --git a/staging/src/k8s.io/apiserver/pkg/server/options/BUILD b/staging/src/k8s.io/apiserver/pkg/server/options/BUILD index 6d41fea41494e..8e616203fb683 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/options/BUILD +++ b/staging/src/k8s.io/apiserver/pkg/server/options/BUILD @@ -54,6 +54,8 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/util/net:go_default_library", "//vendor/k8s.io/apiserver/pkg/admission:go_default_library", "//vendor/k8s.io/apiserver/pkg/admission/initializer:go_default_library", + "//vendor/k8s.io/apiserver/pkg/audit:go_default_library", + "//vendor/k8s.io/apiserver/pkg/audit/policy:go_default_library", "//vendor/k8s.io/apiserver/pkg/authentication/authenticatorfactory:go_default_library", "//vendor/k8s.io/apiserver/pkg/authorization/authorizerfactory:go_default_library", "//vendor/k8s.io/apiserver/pkg/features:go_default_library", @@ -65,6 +67,7 @@ go_library( "//vendor/k8s.io/apiserver/pkg/util/feature:go_default_library", "//vendor/k8s.io/apiserver/pkg/util/flag:go_default_library", "//vendor/k8s.io/apiserver/plugin/pkg/audit/log:go_default_library", + "//vendor/k8s.io/apiserver/plugin/pkg/audit/webhook:go_default_library", "//vendor/k8s.io/client-go/informers:go_default_library", "//vendor/k8s.io/client-go/kubernetes:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1:go_default_library", diff --git a/staging/src/k8s.io/apiserver/pkg/server/options/admission.go b/staging/src/k8s.io/apiserver/pkg/server/options/admission.go index 6d2003bd673a4..760f4fc3da7c5 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/options/admission.go +++ b/staging/src/k8s.io/apiserver/pkg/server/options/admission.go @@ -35,11 +35,16 @@ type AdmissionOptions struct { } // NewAdmissionOptions creates a new instance of AdmissionOptions +// Note: +// In addition it calls RegisterAllAdmissionPlugins to register +// all generic admission plugins. func NewAdmissionOptions() *AdmissionOptions { - return &AdmissionOptions{ + options := &AdmissionOptions{ Plugins: &admission.Plugins{}, PluginNames: []string{}, } + server.RegisterAllAdmissionPlugins(options.Plugins) + return options } // AddFlags adds flags related to admission for a specific APIServer to the specified FlagSet diff --git a/staging/src/k8s.io/apiserver/pkg/server/options/audit.go b/staging/src/k8s.io/apiserver/pkg/server/options/audit.go index c9362d2312ce2..b5f310af04118 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/options/audit.go +++ b/staging/src/k8s.io/apiserver/pkg/server/options/audit.go @@ -17,16 +17,47 @@ limitations under the License. package options import ( + "fmt" "io" "os" + "strings" "github.com/spf13/pflag" "gopkg.in/natefinch/lumberjack.v2" + "k8s.io/apiserver/pkg/audit" + "k8s.io/apiserver/pkg/audit/policy" + "k8s.io/apiserver/pkg/features" "k8s.io/apiserver/pkg/server" + utilfeature "k8s.io/apiserver/pkg/util/feature" pluginlog "k8s.io/apiserver/plugin/pkg/audit/log" + pluginwebhook "k8s.io/apiserver/plugin/pkg/audit/webhook" ) +func appendBackend(existing, newBackend audit.Backend) audit.Backend { + if existing == nil { + return newBackend + } + return audit.Union(existing, newBackend) +} + +func advancedAuditingEnabled() bool { + return utilfeature.DefaultFeatureGate.Enabled(features.AdvancedAuditing) +} + +type AuditOptions struct { + // Policy configuration file for filtering audit events that are captured. + // If unspecified, a default is provided. + PolicyFile string + + // Plugin options + + LogOptions AuditLogOptions + WebhookOptions AuditWebhookOptions +} + +// AuditLogOptions holds the legacy audit log writer. If the AdvancedAuditing feature +// is enabled, these options determine the output of the structured audit log. type AuditLogOptions struct { Path string MaxAge int @@ -34,8 +65,61 @@ type AuditLogOptions struct { MaxSize int } -func NewAuditLogOptions() *AuditLogOptions { - return &AuditLogOptions{} +// AuditWebhookOptions control the webhook configuration for audit events. +type AuditWebhookOptions struct { + ConfigFile string + // Should the webhook asynchronous batch events to the webhook backend or + // should the webhook block responses? + // + // Defaults to asynchronous batch events. + Mode string +} + +func NewAuditOptions() *AuditOptions { + return &AuditOptions{ + WebhookOptions: AuditWebhookOptions{Mode: pluginwebhook.ModeBatch}, + } +} + +func (o *AuditOptions) AddFlags(fs *pflag.FlagSet) { + fs.StringVar(&o.PolicyFile, "audit-policy-file", o.PolicyFile, + "Path to the file that defines the audit policy configuration. Requires the 'AdvancedAuditing' feature gate."+ + " With AdvancedAuditing, a profile is required to enable auditing.") + + o.LogOptions.AddFlags(fs) + o.WebhookOptions.AddFlags(fs) +} + +func (o *AuditOptions) ApplyTo(c *server.Config) error { + // Apply generic options. + if err := o.applyTo(c); err != nil { + return err + } + + // Apply plugin options. + if err := o.LogOptions.applyTo(c); err != nil { + return err + } + if err := o.WebhookOptions.applyTo(c); err != nil { + return err + } + return nil +} + +func (o *AuditOptions) applyTo(c *server.Config) error { + if o.PolicyFile == "" { + return nil + } + + if !advancedAuditingEnabled() { + return fmt.Errorf("feature '%s' must be enabled to set an audit policy", features.AdvancedAuditing) + } + p, err := policy.LoadPolicyFromFile(o.PolicyFile) + if err != nil { + return fmt.Errorf("loading audit policy file: %v", err) + } + c.AuditPolicyChecker = policy.NewChecker(p) + return nil } func (o *AuditLogOptions) AddFlags(fs *pflag.FlagSet) { @@ -49,8 +133,8 @@ func (o *AuditLogOptions) AddFlags(fs *pflag.FlagSet) { "The maximum size in megabytes of the audit log file before it gets rotated.") } -func (o *AuditLogOptions) ApplyTo(c *server.Config) error { - if len(o.Path) == 0 { +func (o *AuditLogOptions) applyTo(c *server.Config) error { + if o.Path == "" { return nil } @@ -63,6 +147,36 @@ func (o *AuditLogOptions) ApplyTo(c *server.Config) error { MaxSize: o.MaxSize, } } - c.AuditBackend = pluginlog.NewBackend(w) + c.LegacyAuditWriter = w + + if advancedAuditingEnabled() { + c.AuditBackend = appendBackend(c.AuditBackend, pluginlog.NewBackend(w)) + } + return nil +} + +func (o *AuditWebhookOptions) AddFlags(fs *pflag.FlagSet) { + fs.StringVar(&o.ConfigFile, "audit-webhook-config-file", o.ConfigFile, + "Path to a kubeconfig formatted file that defines the audit webhook configuration."+ + " Requires the 'AdvancedAuditing' feature gate.") + fs.StringVar(&o.Mode, "audit-webhook-mode", o.Mode, + "Strategy for sending audit events. Blocking indicates sending events should block"+ + " server responses. Batch causes the webhook to buffer and send events"+ + " asynchronously. Known modes are "+strings.Join(pluginwebhook.AllowedModes, ",")+".") +} + +func (o *AuditWebhookOptions) applyTo(c *server.Config) error { + if o.ConfigFile == "" { + return nil + } + + if !advancedAuditingEnabled() { + return fmt.Errorf("feature '%s' must be enabled to set an audit webhook", features.AdvancedAuditing) + } + webhook, err := pluginwebhook.NewBackend(o.ConfigFile, o.Mode) + if err != nil { + return fmt.Errorf("initializing audit webhook: %v", err) + } + c.AuditBackend = appendBackend(c.AuditBackend, webhook) return nil } diff --git a/staging/src/k8s.io/apiserver/pkg/server/options/encryptionconfig/BUILD b/staging/src/k8s.io/apiserver/pkg/server/options/encryptionconfig/BUILD new file mode 100644 index 0000000000000..de403c56180b1 --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/server/options/encryptionconfig/BUILD @@ -0,0 +1,36 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_library( + name = "go_default_library", + srcs = [ + "config.go", + "types.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/ghodss/yaml:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage/value:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage/value/encrypt/aes:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage/value/encrypt/identity:go_default_library", + ], +) + +go_test( + name = "go_default_test", + srcs = ["encryptionconfig_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage/value:go_default_library", + ], +) diff --git a/staging/src/k8s.io/apiserver/pkg/server/options/encryptionconfig/config.go b/staging/src/k8s.io/apiserver/pkg/server/options/encryptionconfig/config.go new file mode 100644 index 0000000000000..4986e3c1b058a --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/server/options/encryptionconfig/config.go @@ -0,0 +1,178 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package encryptionconfig + +import ( + "crypto/aes" + "encoding/base64" + "fmt" + "io" + "io/ioutil" + "os" + + yaml "github.com/ghodss/yaml" + + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apiserver/pkg/storage/value" + aestransformer "k8s.io/apiserver/pkg/storage/value/encrypt/aes" + "k8s.io/apiserver/pkg/storage/value/encrypt/identity" +) + +const ( + aesTransformerPrefixV1 = "k8s:enc:aes:v1:" +) + +// GetTransformerOverrides returns the transformer overrides by reading and parsing the encryption provider configuration file +func GetTransformerOverrides(filepath string) (map[schema.GroupResource]value.Transformer, error) { + f, err := os.Open(filepath) + if err != nil { + return nil, fmt.Errorf("error opening encryption provider configuration file %q: %v", filepath, err) + } + defer f.Close() + + result, err := ParseEncryptionConfiguration(f) + if err != nil { + return nil, fmt.Errorf("error while parsing encryption provider configuration file %q: %v", filepath, err) + } + return result, nil +} + +// ParseEncryptionConfiguration parses configuration data and returns the transformer overrides +func ParseEncryptionConfiguration(f io.Reader) (map[schema.GroupResource]value.Transformer, error) { + configFileContents, err := ioutil.ReadAll(f) + if err != nil { + return nil, fmt.Errorf("could not read contents: %v", err) + } + + var config EncryptionConfig + err = yaml.Unmarshal(configFileContents, &config) + if err != nil { + return nil, fmt.Errorf("error while parsing file: %v", err) + } + + if config.Kind != "EncryptionConfig" && config.Kind != "" { + return nil, fmt.Errorf("invalid configuration kind %q provided", config.Kind) + } + if config.Kind == "" { + return nil, fmt.Errorf("invalid configuration file, missing Kind") + } + // TODO config.APIVersion is unchecked + + resourceToPrefixTransformer := map[schema.GroupResource][]value.PrefixTransformer{} + + // For each entry in the configuration + for _, resourceConfig := range config.Resources { + transformers, err := GetPrefixTransformers(&resourceConfig) + if err != nil { + return nil, err + } + + // For each resource, create a list of providers to use + for _, resource := range resourceConfig.Resources { + gr := schema.ParseGroupResource(resource) + resourceToPrefixTransformer[gr] = append( + resourceToPrefixTransformer[gr], transformers...) + } + } + + result := map[schema.GroupResource]value.Transformer{} + for gr, transList := range resourceToPrefixTransformer { + result[gr] = value.NewMutableTransformer(value.NewPrefixTransformers(fmt.Errorf("no matching prefix found"), transList...)) + } + return result, nil +} + +// GetPrefixTransformer constructs and returns the appropriate prefix transformers for the passed resource using its configuration +func GetPrefixTransformers(config *ResourceConfig) ([]value.PrefixTransformer, error) { + var result []value.PrefixTransformer + for _, provider := range config.Providers { + found := false + + if provider.AES != nil { + transformer, err := GetAESPrefixTransformer(provider.AES) + found = true + if err != nil { + return result, err + } + result = append(result, transformer) + } + + if provider.Identity != nil { + if found == true { + return result, fmt.Errorf("more than one provider specified in a single element, should split into different list elements") + } + found = true + result = append(result, value.PrefixTransformer{ + Transformer: identity.NewEncryptCheckTransformer(), + Prefix: []byte{}, + }) + } + + if found == false { + return result, fmt.Errorf("invalid provider configuration provided") + } + } + return result, nil +} + +// GetAESPrefixTransformer returns a prefix transformer from the provided configuration +func GetAESPrefixTransformer(config *AESConfig) (value.PrefixTransformer, error) { + var result value.PrefixTransformer + + if len(config.Keys) == 0 { + return result, fmt.Errorf("aes provider has no valid keys") + } + for _, key := range config.Keys { + if key.Name == "" { + return result, fmt.Errorf("key with invalid name provided") + } + if key.Secret == "" { + return result, fmt.Errorf("key %v has no provided secret", key.Name) + } + } + + keyTransformers := []value.PrefixTransformer{} + + for _, keyData := range config.Keys { + key, err := base64.StdEncoding.DecodeString(keyData.Secret) + if err != nil { + return result, fmt.Errorf("could not obtain secret for named key %s: %s", keyData.Name, err) + } + block, err := aes.NewCipher(key) + if err != nil { + return result, fmt.Errorf("error while creating cipher for named key %s: %s", keyData.Name, err) + } + + // Create a new PrefixTransformer for this key + keyTransformers = append(keyTransformers, + value.PrefixTransformer{ + Transformer: aestransformer.NewGCMTransformer(block), + Prefix: []byte(keyData.Name + ":"), + }) + } + + // Create a prefixTransformer which can choose between these keys + keyTransformer := value.NewPrefixTransformers( + fmt.Errorf("no matching key was found for the provided AES transformer"), keyTransformers...) + + // Create a PrefixTransformer which shall later be put in a list with other providers + result = value.PrefixTransformer{ + Transformer: keyTransformer, + Prefix: []byte(aesTransformerPrefixV1), + } + return result, nil +} diff --git a/staging/src/k8s.io/apiserver/pkg/server/options/encryptionconfig/encryptionconfig_test.go b/staging/src/k8s.io/apiserver/pkg/server/options/encryptionconfig/encryptionconfig_test.go new file mode 100644 index 0000000000000..ae7f10c140c38 --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/server/options/encryptionconfig/encryptionconfig_test.go @@ -0,0 +1,172 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package encryptionconfig + +import ( + "bytes" + "strings" + "testing" + + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apiserver/pkg/storage/value" +) + +const ( + sampleText = "abcdefghijklmnopqrstuvwxyz" + + sampleContextText = "0123456789" + + correctConfigWithIdentityFirst = ` +kind: EncryptionConfig +apiVersion: v1 +resources: + - resources: + - secrets + - namespaces + providers: + - identity: {} + - aes: + keys: + - name: key1 + secret: c2VjcmV0IGlzIHNlY3VyZQ== + - name: key2 + secret: dGhpcyBpcyBwYXNzd29yZA== +` + + correctConfigWithAesFirst = ` +kind: EncryptionConfig +apiVersion: v1 +resources: + - resources: + - secrets + providers: + - aes: + keys: + - name: key1 + secret: c2VjcmV0IGlzIHNlY3VyZQ== + - name: key2 + secret: dGhpcyBpcyBwYXNzd29yZA== + - identity: {} +` + + incorrectConfigNoSecretForKey = ` +kind: EncryptionConfig +apiVersion: v1 +resources: + - resources: + - namespaces + - secrets + providers: + - aes: + keys: + - name: key1 +` + + incorrectConfigInvalidKey = ` +kind: EncryptionConfig +apiVersion: v1 +resources: + - resources: + - namespaces + - secrets + providers: + - aes: + keys: + - name: key1 + secret: c2VjcmV0IGlzIHNlY3VyZQ== + - name: key2 + secret: YSBzZWNyZXQgYSBzZWNyZXQ= +` +) + +func TestEncryptionProviderConfigCorrect(t *testing.T) { + // Creates two transformers with different ordering of identity and AES transformers. + // Transforms data using one of them, and tries to untransform using both of them. + // Repeats this for both the possible combinations. + + identityFirstTransformerOverrides, err := ParseEncryptionConfiguration(strings.NewReader(correctConfigWithIdentityFirst)) + if err != nil { + t.Fatalf("error while parsing configuration file: %s.\nThe file was:\n%s", err, correctConfigWithIdentityFirst) + } + + aesFirstTransformerOverrides, err := ParseEncryptionConfiguration(strings.NewReader(correctConfigWithAesFirst)) + if err != nil { + t.Fatalf("error while parsing configuration file: %s.\nThe file was:\n%s", err, correctConfigWithAesFirst) + } + + // Pick the transformer for any of the returned resources. + identityFirstTransformer := identityFirstTransformerOverrides[schema.ParseGroupResource("secrets")] + aesFirstTransformer := aesFirstTransformerOverrides[schema.ParseGroupResource("secrets")] + + context := value.DefaultContext([]byte(sampleContextText)) + originalText := []byte(sampleText) + + testCases := []struct { + WritingTransformer value.Transformer + Name string + AesStale bool + IdentityStale bool + }{ + {aesFirstTransformer, "aesFirst", false, true}, + {identityFirstTransformer, "identityFirst", true, false}, + } + + for _, testCase := range testCases { + transformedData, err := testCase.WritingTransformer.TransformToStorage(originalText, context) + if err != nil { + t.Fatalf("%s: error while transforming data to storage: %s", testCase.Name, err) + } + + aesUntransformedData, stale, err := aesFirstTransformer.TransformFromStorage(transformedData, context) + if err != nil { + t.Fatalf("%s: error while reading using aesFirst transformer: %s", testCase.Name, err) + } + if stale != testCase.AesStale { + t.Fatalf("%s: wrong stale information on reading using aesFirst transformer, should be %v", testCase.Name, testCase.AesStale) + } + + identityUntransformedData, stale, err := identityFirstTransformer.TransformFromStorage(transformedData, context) + if err != nil { + t.Fatalf("%s: error while reading using identityFirst transformer: %s", testCase.Name, err) + } + if stale != testCase.IdentityStale { + t.Fatalf("%s: wrong stale information on reading using identityFirst transformer, should be %v", testCase.Name, testCase.IdentityStale) + } + + if bytes.Compare(aesUntransformedData, originalText) != 0 { + t.Fatalf("%s: aesFirst transformer transformed data incorrectly. Expected: %v, got %v", testCase.Name, originalText, aesUntransformedData) + } + + if bytes.Compare(identityUntransformedData, originalText) != 0 { + t.Fatalf("%s: identityFirst transformer transformed data incorrectly. Expected: %v, got %v", testCase.Name, originalText, aesUntransformedData) + } + } +} + +// Throw error if key has no secret +func TestEncryptionProviderConfigNoSecretForKey(t *testing.T) { + if _, err := ParseEncryptionConfiguration(strings.NewReader(incorrectConfigNoSecretForKey)); err == nil { + t.Fatalf("invalid configuration file (one key has no secret) got parsed:\n%s", incorrectConfigNoSecretForKey) + } +} + +// Throw error if invalid key for AES +func TestEncryptionProviderConfigInvalidKey(t *testing.T) { + if _, err := ParseEncryptionConfiguration(strings.NewReader(incorrectConfigInvalidKey)); err == nil { + t.Fatalf("invalid configuration file (bad AES key) got parsed:\n%s", incorrectConfigInvalidKey) + } +} diff --git a/staging/src/k8s.io/apiserver/pkg/server/options/encryptionconfig/types.go b/staging/src/k8s.io/apiserver/pkg/server/options/encryptionconfig/types.go new file mode 100644 index 0000000000000..ea23ac4053935 --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/server/options/encryptionconfig/types.go @@ -0,0 +1,61 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package encryptionconfig + +// EncryptionConfig stores the complete configuration for encryption providers. +type EncryptionConfig struct { + // kind is the type of configuration file. + Kind string `json:"kind"` + // apiVersion is the API version this file has to be parsed as. + APIVersion string `json:"apiVersion"` + // resources is a list containing resources, and their corresponding encryption providers. + Resources []ResourceConfig `json:"resources"` +} + +// ResourceConfig stores per resource configuration. +type ResourceConfig struct { + // resources is a list of kubernetes resources which have to be encrypted. + Resources []string `json:"resources"` + // providers is a list of transformers to be used for reading and writing the resources to disk. + // eg: aes, identity. + Providers []ProviderConfig `json:"providers"` +} + +// ProviderConfig stores the provided configuration for an encryption provider. +type ProviderConfig struct { + // aes is the configuration for the AEAD-GCM transformer. + AES *AESConfig `json:"aes,omitempty"` + // identity is the (empty) configuration for the identity transformer. + Identity *IdentityConfig `json:"identity,omitempty"` +} + +// AESConfig contains the API configuration for an AES transformer. +type AESConfig struct { + // keys is a list of keys to be used for creating the AES transformer. + Keys []Key `json:"keys"` +} + +// Key contains name and secret of the provided key for AES transformer. +type Key struct { + // name is the name of the key to be used while storing data to disk. + Name string `json:"name"` + // secret is the actual AES key, encoded in base64. It has to be 16, 24 or 32 bytes long. + Secret string `json:"secret"` +} + +// IdentityConfig is an empty struct to allow identity transformer in provider configuration. +type IdentityConfig struct{} diff --git a/staging/src/k8s.io/apiserver/pkg/server/options/etcd.go b/staging/src/k8s.io/apiserver/pkg/server/options/etcd.go index 5bfa27e60ac9e..e255b636050b0 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/options/etcd.go +++ b/staging/src/k8s.io/apiserver/pkg/server/options/etcd.go @@ -30,7 +30,8 @@ import ( ) type EtcdOptions struct { - StorageConfig storagebackend.Config + StorageConfig storagebackend.Config + EncryptionProviderConfigFilepath string EtcdServersOverrides []string @@ -109,6 +110,9 @@ func (s *EtcdOptions) AddFlags(fs *pflag.FlagSet) { fs.BoolVar(&s.StorageConfig.Quorum, "etcd-quorum-read", s.StorageConfig.Quorum, "If true, enable quorum read.") + + fs.StringVar(&s.EncryptionProviderConfigFilepath, "experimental-encryption-provider-config", s.EncryptionProviderConfigFilepath, + "The file containing configuration for encryption providers to be used for storing secrets in etcd") } func (s *EtcdOptions) ApplyTo(c *server.Config) error { diff --git a/staging/src/k8s.io/apiserver/pkg/server/options/recommended.go b/staging/src/k8s.io/apiserver/pkg/server/options/recommended.go index cf0ba4016e6ea..92ec3e8e22f54 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/options/recommended.go +++ b/staging/src/k8s.io/apiserver/pkg/server/options/recommended.go @@ -31,7 +31,7 @@ type RecommendedOptions struct { SecureServing *SecureServingOptions Authentication *DelegatingAuthenticationOptions Authorization *DelegatingAuthorizationOptions - Audit *AuditLogOptions + Audit *AuditOptions Features *FeatureOptions } @@ -41,7 +41,7 @@ func NewRecommendedOptions(prefix string, copier runtime.ObjectCopier, codec run SecureServing: NewSecureServingOptions(), Authentication: NewDelegatingAuthenticationOptions(), Authorization: NewDelegatingAuthorizationOptions(), - Audit: NewAuditLogOptions(), + Audit: NewAuditOptions(), Features: NewFeatureOptions(), } } diff --git a/staging/src/k8s.io/apiserver/pkg/server/options/serving_test.go b/staging/src/k8s.io/apiserver/pkg/server/options/serving_test.go index ec4d8e8edca7c..c1869dd1bd5a4 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/options/serving_test.go +++ b/staging/src/k8s.io/apiserver/pkg/server/options/serving_test.go @@ -475,7 +475,7 @@ NextTest: return } - s, err := config.Complete().New(server.EmptyDelegate) + s, err := config.Complete().New("test", server.EmptyDelegate) if err != nil { t.Errorf("%q - failed creating the server: %v", title, err) return diff --git a/staging/src/k8s.io/apiserver/pkg/server/plugins.go b/staging/src/k8s.io/apiserver/pkg/server/plugins.go new file mode 100644 index 0000000000000..404e8afc4c8ae --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/server/plugins.go @@ -0,0 +1,28 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package server + +// This file exists to force the desired plugin implementations to be linked into genericapi pkg. +import ( + "k8s.io/apiserver/pkg/admission" + "k8s.io/apiserver/pkg/admission/plugin/namespace/lifecycle" +) + +// RegisterAllAdmissionPlugins registers all admission plugins +func RegisterAllAdmissionPlugins(plugins *admission.Plugins) { + lifecycle.Register(plugins) +} diff --git a/staging/src/k8s.io/apiserver/pkg/server/storage/BUILD b/staging/src/k8s.io/apiserver/pkg/server/storage/BUILD index 324e82c6ef9f6..eec4c23df61a7 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/storage/BUILD +++ b/staging/src/k8s.io/apiserver/pkg/server/storage/BUILD @@ -48,5 +48,6 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/recognizer:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", "//vendor/k8s.io/apiserver/pkg/storage/storagebackend:go_default_library", + "//vendor/k8s.io/apiserver/pkg/storage/value:go_default_library", ], ) diff --git a/staging/src/k8s.io/apiserver/pkg/server/storage/storage_factory.go b/staging/src/k8s.io/apiserver/pkg/server/storage/storage_factory.go index 790d9ca0cd8f9..2ceff3b6121bd 100644 --- a/staging/src/k8s.io/apiserver/pkg/server/storage/storage_factory.go +++ b/staging/src/k8s.io/apiserver/pkg/server/storage/storage_factory.go @@ -28,6 +28,7 @@ import ( "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/util/sets" "k8s.io/apiserver/pkg/storage/storagebackend" + "k8s.io/apiserver/pkg/storage/value" ) // Backend describes the storage servers, the information here should be enough @@ -109,6 +110,8 @@ type groupResourceOverrides struct { // decoderDecoratorFn is optional and may wrap the provided decoders (can add new decoders). The order of // returned decoders will be priority for attempt to decode. decoderDecoratorFn func([]runtime.Decoder) []runtime.Decoder + // transformer is optional and shall encrypt that resource at rest. + transformer value.Transformer } // Apply overrides the provided config and options if the override has a value in that position @@ -132,6 +135,9 @@ func (o groupResourceOverrides) Apply(config *storagebackend.Config, options *St if o.decoderDecoratorFn != nil { options.DecoderDecoratorFn = o.decoderDecoratorFn } + if o.transformer != nil { + config.Transformer = o.transformer + } } var _ StorageFactory = &DefaultStorageFactory{} @@ -193,6 +199,12 @@ func (s *DefaultStorageFactory) SetSerializer(groupResource schema.GroupResource s.Overrides[groupResource] = overrides } +func (s *DefaultStorageFactory) SetTransformer(groupResource schema.GroupResource, transformer value.Transformer) { + overrides := s.Overrides[groupResource] + overrides.transformer = transformer + s.Overrides[groupResource] = overrides +} + // AddCohabitatingResources links resources together the order of the slice matters! its the priority order of lookup for finding a storage location func (s *DefaultStorageFactory) AddCohabitatingResources(groupResources ...schema.GroupResource) { for _, groupResource := range groupResources { diff --git a/staging/src/k8s.io/apiserver/pkg/storage/etcd3/store.go b/staging/src/k8s.io/apiserver/pkg/storage/etcd3/store.go index 1e9fbed8ed13d..210b67084c499 100644 --- a/staging/src/k8s.io/apiserver/pkg/storage/etcd3/store.go +++ b/staging/src/k8s.io/apiserver/pkg/storage/etcd3/store.go @@ -388,7 +388,7 @@ func (s *store) List(ctx context.Context, key, resourceVersion string, pred stor elems := make([]*elemForDecode, 0, len(getResp.Kvs)) for _, kv := range getResp.Kvs { - data, _, err := s.transformer.TransformFromStorage(kv.Value, authenticatedDataString(key)) + data, _, err := s.transformer.TransformFromStorage(kv.Value, authenticatedDataString(kv.Key)) if err != nil { utilruntime.HandleError(fmt.Errorf("unable to transform key %q: %v", key, err)) continue diff --git a/staging/src/k8s.io/apiserver/pkg/storage/etcd3/watcher.go b/staging/src/k8s.io/apiserver/pkg/storage/etcd3/watcher.go index b42ae4b80f411..cb172564d3d69 100644 --- a/staging/src/k8s.io/apiserver/pkg/storage/etcd3/watcher.go +++ b/staging/src/k8s.io/apiserver/pkg/storage/etcd3/watcher.go @@ -17,8 +17,11 @@ limitations under the License. package etcd3 import ( + "errors" "fmt" "net/http" + "os" + "strconv" "strings" "sync" @@ -40,6 +43,24 @@ const ( outgoingBufSize = 100 ) +// fatalOnDecodeError is used during testing to panic the server if watcher encounters a decoding error +var fatalOnDecodeError = false + +// errTestingDecode is the only error that testingDeferOnDecodeError catches during a panic +var errTestingDecode = errors.New("sentinel error only used during testing to indicate watch decoding error") + +// testingDeferOnDecodeError is used during testing to recover from a panic caused by errTestingDecode, all other values continue to panic +func testingDeferOnDecodeError() { + if r := recover(); r != nil && r != errTestingDecode { + panic(r) + } +} + +func init() { + // check to see if we are running in a test environment + fatalOnDecodeError, _ = strconv.ParseBool(os.Getenv("KUBE_PANIC_WATCH_DECODE_ERROR")) +} + type watcher struct { client *clientv3.Client codec runtime.Codec @@ -373,9 +394,18 @@ func (wc *watchChan) prepareObjs(e *event) (curObj runtime.Object, oldObj runtim return curObj, oldObj, nil } -func decodeObj(codec runtime.Codec, versioner storage.Versioner, data []byte, rev int64) (runtime.Object, error) { +func decodeObj(codec runtime.Codec, versioner storage.Versioner, data []byte, rev int64) (_ runtime.Object, err error) { obj, err := runtime.Decode(codec, []byte(data)) if err != nil { + if fatalOnDecodeError { + // catch watch decode error iff we caused it on + // purpose during a unit test + defer testingDeferOnDecodeError() + // we are running in a test environment and thus an + // error here is due to a coder mistake if the defer + // does not catch it + panic(err) + } return nil, err } // ensure resource version is set on the object we load from etcd diff --git a/staging/src/k8s.io/apiserver/pkg/storage/etcd3/watcher_test.go b/staging/src/k8s.io/apiserver/pkg/storage/etcd3/watcher_test.go index 00c31735a91f0..58cbfe4c29bbd 100644 --- a/staging/src/k8s.io/apiserver/pkg/storage/etcd3/watcher_test.go +++ b/staging/src/k8s.io/apiserver/pkg/storage/etcd3/watcher_test.go @@ -17,7 +17,6 @@ limitations under the License. package etcd3 import ( - "errors" "fmt" "reflect" "strconv" @@ -327,7 +326,7 @@ type testCodec struct { } func (c *testCodec) Decode(data []byte, defaults *schema.GroupVersionKind, into runtime.Object) (runtime.Object, *schema.GroupVersionKind, error) { - return nil, nil, errors.New("Expected decoding failure") + return nil, nil, errTestingDecode } func testCheckEventType(t *testing.T, expectEventType watch.EventType, w watch.Interface) { diff --git a/staging/src/k8s.io/apiserver/pkg/storage/selection_predicate.go b/staging/src/k8s.io/apiserver/pkg/storage/selection_predicate.go index c4f79288d949f..8878245d1f2c2 100644 --- a/staging/src/k8s.io/apiserver/pkg/storage/selection_predicate.go +++ b/staging/src/k8s.io/apiserver/pkg/storage/selection_predicate.go @@ -65,16 +65,41 @@ func (s *SelectionPredicate) MatchesLabelsAndFields(l labels.Set, f fields.Set) return matched } +const matchesSingleField = "metadata.name" + +func removeMatchesSingleField(field, value string) (string, string, error) { + if field == matchesSingleField { + return "", "", nil + } + return field, value, nil +} + // MatchesSingle will return (name, true) if and only if s.Field matches on the object's // name. func (s *SelectionPredicate) MatchesSingle() (string, bool) { - // TODO: should be namespace.name - if name, ok := s.Field.RequiresExactMatch("metadata.name"); ok { + if name, ok := s.Field.RequiresExactMatch(matchesSingleField); ok { return name, true } return "", false } +func (s *SelectionPredicate) RemoveMatchesSingleRequirements() (SelectionPredicate, error) { + var fieldsSelector fields.Selector + if s.Field != nil { + var err error + fieldsSelector, err = s.Field.Transform(removeMatchesSingleField) + if err != nil { + return SelectionPredicate{}, err + } + } + return SelectionPredicate{ + Label: s.Label, + Field: fieldsSelector, + GetAttrs: s.GetAttrs, + IndexFields: s.IndexFields, + }, nil +} + // For any index defined by IndexFields, if a matcher can match only (a subset) // of objects that return for a given index, a pair (, ) // wil be returned. diff --git a/staging/src/k8s.io/apiserver/pkg/storage/storagebackend/factory/etcd3.go b/staging/src/k8s.io/apiserver/pkg/storage/storagebackend/factory/etcd3.go index 2c838a09ce746..ff6753a01105a 100644 --- a/staging/src/k8s.io/apiserver/pkg/storage/storagebackend/factory/etcd3.go +++ b/staging/src/k8s.io/apiserver/pkg/storage/storagebackend/factory/etcd3.go @@ -58,7 +58,7 @@ func newETCD3Storage(c storagebackend.Config) (storage.Interface, DestroyFunc, e } transformer := c.Transformer if transformer == nil { - transformer = value.IdentityTransformer + transformer = value.NewMutableTransformer(value.IdentityTransformer) } if c.Quorum { return etcd3.New(client, c.Codec, c.Prefix, transformer), destroyFunc, nil diff --git a/staging/src/k8s.io/apiserver/pkg/storage/value/encrypt/identity/BUILD b/staging/src/k8s.io/apiserver/pkg/storage/value/encrypt/identity/BUILD new file mode 100644 index 0000000000000..3043fe2065b38 --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/storage/value/encrypt/identity/BUILD @@ -0,0 +1,15 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["identity.go"], + tags = ["automanaged"], + deps = ["//vendor/k8s.io/apiserver/pkg/storage/value:go_default_library"], +) diff --git a/staging/src/k8s.io/apiserver/pkg/storage/value/encrypt/identity/identity.go b/staging/src/k8s.io/apiserver/pkg/storage/value/encrypt/identity/identity.go new file mode 100644 index 0000000000000..0f7f1a70393d9 --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/storage/value/encrypt/identity/identity.go @@ -0,0 +1,50 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package identity + +import ( + "bytes" + "fmt" + + "k8s.io/apiserver/pkg/storage/value" +) + +// encryptIdentityTransformer performs no transformation on provided data, but validates +// that the data is not encrypted data during TransformFromStorage +type identityTransformer struct{} + +// NewEncryptCheckTransformer returns an identityTransformer which returns an error +// on attempts to read encrypted data +func NewEncryptCheckTransformer() value.Transformer { + return identityTransformer{} +} + +// TransformFromStorage returns the input bytes if the data is not encrypted +func (identityTransformer) TransformFromStorage(b []byte, context value.Context) ([]byte, bool, error) { + // EncryptIdentityTransformer has to return an error if the data is encoded using another transformer. + // JSON data starts with '{'. Protobuf data has a prefix 'k8s[\x00-\xFF]'. + // Prefix 'k8s:enc:' is reserved for encrypted data on disk. + if bytes.HasPrefix(b, []byte("k8s:enc:")) { + return []byte{}, false, fmt.Errorf("identity transformer tried to read encrypted data") + } + return b, false, nil +} + +// TransformToStorage implements the Transformer interface for encryptIdentityTransformer +func (identityTransformer) TransformToStorage(b []byte, context value.Context) ([]byte, error) { + return b, nil +} diff --git a/staging/src/k8s.io/apiserver/pkg/storage/value/transformer.go b/staging/src/k8s.io/apiserver/pkg/storage/value/transformer.go index ab5d4af959bf8..04af5d6db7b64 100644 --- a/staging/src/k8s.io/apiserver/pkg/storage/value/transformer.go +++ b/staging/src/k8s.io/apiserver/pkg/storage/value/transformer.go @@ -126,6 +126,13 @@ func (t *prefixTransformers) TransformFromStorage(data []byte, context Context) for i, transformer := range t.transformers { if bytes.HasPrefix(data, transformer.Prefix) { result, stale, err := transformer.Transformer.TransformFromStorage(data[len(transformer.Prefix):], context) + // To migrate away from encryption, user can specify an identity transformer higher up + // (in the config file) than the encryption transformer. In that scenario, the identity transformer needs to + // identify (during reads from disk) whether the data being read is encrypted or not. If the data is encrypted, + // it shall throw an error, but that error should not prevent subsequent transformers from being tried. + if len(transformer.Prefix) == 0 && err != nil { + continue + } return result, stale || i != 0, err } } diff --git a/staging/src/k8s.io/apiserver/pkg/util/proxy/BUILD b/staging/src/k8s.io/apiserver/pkg/util/proxy/BUILD index 1d186a60f30dc..7e369534ce8d8 100644 --- a/staging/src/k8s.io/apiserver/pkg/util/proxy/BUILD +++ b/staging/src/k8s.io/apiserver/pkg/util/proxy/BUILD @@ -12,11 +12,19 @@ go_test( name = "go_default_test", srcs = [ "dial_test.go", + "proxy_test.go", "transport_test.go", ], library = ":go_default_library", tags = ["automanaged"], - deps = ["//vendor/k8s.io/apimachinery/pkg/util/net:go_default_library"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/net:go_default_library", + "//vendor/k8s.io/client-go/listers/core/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], ) go_library( @@ -24,6 +32,7 @@ go_library( srcs = [ "dial.go", "doc.go", + "proxy.go", "transport.go", ], tags = ["automanaged"], @@ -31,8 +40,12 @@ go_library( "//vendor/github.com/golang/glog:go_default_library", "//vendor/golang.org/x/net/html:go_default_library", "//vendor/golang.org/x/net/html/atom:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/net:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", "//vendor/k8s.io/apimachinery/third_party/forked/golang/netutil:go_default_library", + "//vendor/k8s.io/client-go/listers/core/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", ], ) diff --git a/staging/src/k8s.io/apiserver/pkg/util/proxy/proxy.go b/staging/src/k8s.io/apiserver/pkg/util/proxy/proxy.go new file mode 100644 index 0000000000000..db631dfde3bb7 --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/util/proxy/proxy.go @@ -0,0 +1,127 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package proxy + +import ( + "fmt" + "math/rand" + "net" + "net/url" + "strconv" + + "k8s.io/apimachinery/pkg/api/errors" + listersv1 "k8s.io/client-go/listers/core/v1" + "k8s.io/client-go/pkg/api/v1" + + "k8s.io/apimachinery/pkg/util/intstr" +) + +// findServicePort finds the service port by name or numerically. +func findServicePort(svc *v1.Service, port intstr.IntOrString) (*v1.ServicePort, error) { + for _, svcPort := range svc.Spec.Ports { + if (port.Type == intstr.Int && int32(svcPort.Port) == port.IntVal) || (port.Type == intstr.String && svcPort.Name == port.StrVal) { + return &svcPort, nil + } + } + return nil, errors.NewServiceUnavailable(fmt.Sprintf("no service port %q found for service %q", port.String(), svc.Name)) +} + +// ResourceLocation returns a URL to which one can send traffic for the specified service. +func ResolveEndpoint(services listersv1.ServiceLister, endpoints listersv1.EndpointsLister, namespace, id string) (*url.URL, error) { + svc, err := services.Services(namespace).Get(id) + if err != nil { + return nil, err + } + + port := intstr.FromInt(443) + svcPort, err := findServicePort(svc, port) + if err != nil { + return nil, err + } + + switch { + case svc.Spec.Type == v1.ServiceTypeClusterIP, svc.Spec.Type == v1.ServiceTypeLoadBalancer, svc.Spec.Type == v1.ServiceTypeNodePort: + // these are fine + default: + return nil, fmt.Errorf("unsupported service type %q", svc.Spec.Type) + } + + eps, err := endpoints.Endpoints(namespace).Get(svc.Name) + if err != nil { + return nil, err + } + if len(eps.Subsets) == 0 { + return nil, errors.NewServiceUnavailable(fmt.Sprintf("no endpoints available for service %q", svc.Name)) + } + + // Pick a random Subset to start searching from. + ssSeed := rand.Intn(len(eps.Subsets)) + + // Find a Subset that has the port. + for ssi := 0; ssi < len(eps.Subsets); ssi++ { + ss := &eps.Subsets[(ssSeed+ssi)%len(eps.Subsets)] + if len(ss.Addresses) == 0 { + continue + } + for i := range ss.Ports { + if ss.Ports[i].Name == svcPort.Name { + // Pick a random address. + ip := ss.Addresses[rand.Intn(len(ss.Addresses))].IP + port := int(ss.Ports[i].Port) + return &url.URL{ + Scheme: "https", + Host: net.JoinHostPort(ip, strconv.Itoa(port)), + }, nil + } + } + } + return nil, errors.NewServiceUnavailable(fmt.Sprintf("no endpoints available for service %q", id)) +} + +func ResolveCluster(services listersv1.ServiceLister, namespace, id string) (*url.URL, error) { + svc, err := services.Services(namespace).Get(id) + if err != nil { + return nil, err + } + + port := intstr.FromInt(443) + + switch { + case svc.Spec.Type == v1.ServiceTypeClusterIP && svc.Spec.ClusterIP == v1.ClusterIPNone: + return nil, fmt.Errorf(`cannot route to service with ClusterIP "None"`) + // use IP from a clusterIP for these service types + case svc.Spec.Type == v1.ServiceTypeClusterIP, svc.Spec.Type == v1.ServiceTypeLoadBalancer, svc.Spec.Type == v1.ServiceTypeNodePort: + svcPort, err := findServicePort(svc, port) + if err != nil { + return nil, err + } + return &url.URL{ + Scheme: "https", + Host: net.JoinHostPort(svc.Spec.ClusterIP, fmt.Sprintf("%d", svcPort.Port)), + }, nil + case svc.Spec.Type == v1.ServiceTypeExternalName: + if port.Type != intstr.Int { + return nil, fmt.Errorf("named ports not supported") + } + return &url.URL{ + Scheme: "https", + Host: net.JoinHostPort(svc.Spec.ExternalName, port.String()), + }, nil + default: + return nil, fmt.Errorf("unsupported service type %q", svc.Spec.Type) + } +} diff --git a/staging/src/k8s.io/apiserver/pkg/util/proxy/proxy_test.go b/staging/src/k8s.io/apiserver/pkg/util/proxy/proxy_test.go new file mode 100644 index 0000000000000..f21cfeed114f8 --- /dev/null +++ b/staging/src/k8s.io/apiserver/pkg/util/proxy/proxy_test.go @@ -0,0 +1,243 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package proxy + +import ( + "net/url" + "testing" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/intstr" + v1listers "k8s.io/client-go/listers/core/v1" + "k8s.io/client-go/pkg/api/v1" + "k8s.io/client-go/tools/cache" +) + +func TestResolve(t *testing.T) { + matchingEndpoints := func(svc *v1.Service) []*v1.Endpoints { + ports := []v1.EndpointPort{} + for _, p := range svc.Spec.Ports { + if p.TargetPort.Type != intstr.Int { + continue + } + ports = append(ports, v1.EndpointPort{Name: p.Name, Port: p.TargetPort.IntVal}) + } + + return []*v1.Endpoints{{ + ObjectMeta: metav1.ObjectMeta{Namespace: svc.Namespace, Name: svc.Name}, + Subsets: []v1.EndpointSubset{{ + Addresses: []v1.EndpointAddress{{Hostname: "dummy-host", IP: "127.0.0.1"}}, + Ports: ports, + }}, + }} + } + + type expectation struct { + url string + error bool + } + + tests := []struct { + name string + services []*v1.Service + endpoints func(svc *v1.Service) []*v1.Endpoints + + clusterMode expectation + endpointMode expectation + }{ + { + name: "cluster ip without 443 port", + services: []*v1.Service{ + { + ObjectMeta: metav1.ObjectMeta{Namespace: "one", Name: "alfa"}, + Spec: v1.ServiceSpec{ + Type: v1.ServiceTypeClusterIP, + ClusterIP: "hit", + Ports: []v1.ServicePort{ + {Port: 1234, TargetPort: intstr.FromInt(1234)}, + }, + }, + }, + }, + endpoints: matchingEndpoints, + + clusterMode: expectation{error: true}, + endpointMode: expectation{error: true}, + }, + { + name: "cluster ip", + services: []*v1.Service{ + { + ObjectMeta: metav1.ObjectMeta{Namespace: "one", Name: "alfa"}, + Spec: v1.ServiceSpec{ + Type: v1.ServiceTypeClusterIP, + ClusterIP: "hit", + Ports: []v1.ServicePort{ + {Name: "https", Port: 443, TargetPort: intstr.FromInt(1443)}, + {Port: 1234, TargetPort: intstr.FromInt(1234)}, + }, + }, + }, + }, + endpoints: matchingEndpoints, + + clusterMode: expectation{url: "https://hit:443"}, + endpointMode: expectation{url: "https://127.0.0.1:1443"}, + }, + { + name: "cluster ip without endpoints", + services: []*v1.Service{ + { + ObjectMeta: metav1.ObjectMeta{Namespace: "one", Name: "alfa"}, + Spec: v1.ServiceSpec{ + Type: v1.ServiceTypeClusterIP, + ClusterIP: "hit", + Ports: []v1.ServicePort{ + {Name: "https", Port: 443, TargetPort: intstr.FromInt(1443)}, + {Port: 1234, TargetPort: intstr.FromInt(1234)}, + }, + }, + }, + }, + endpoints: nil, + + clusterMode: expectation{url: "https://hit:443"}, + endpointMode: expectation{error: true}, + }, + { + name: "none cluster ip", + services: []*v1.Service{ + { + ObjectMeta: metav1.ObjectMeta{Namespace: "one", Name: "alfa"}, + Spec: v1.ServiceSpec{ + Type: v1.ServiceTypeClusterIP, + ClusterIP: v1.ClusterIPNone, + }, + }, + }, + endpoints: nil, + + clusterMode: expectation{error: true}, + endpointMode: expectation{error: true}, + }, + { + name: "loadbalancer", + services: []*v1.Service{ + { + ObjectMeta: metav1.ObjectMeta{Namespace: "one", Name: "alfa"}, + Spec: v1.ServiceSpec{ + Type: v1.ServiceTypeLoadBalancer, + ClusterIP: "lb", + Ports: []v1.ServicePort{ + {Name: "https", Port: 443, TargetPort: intstr.FromInt(1443)}, + {Port: 1234, TargetPort: intstr.FromInt(1234)}, + }, + }, + }, + }, + endpoints: matchingEndpoints, + + clusterMode: expectation{url: "https://lb:443"}, + endpointMode: expectation{url: "https://127.0.0.1:1443"}, + }, + { + name: "node port", + services: []*v1.Service{ + { + ObjectMeta: metav1.ObjectMeta{Namespace: "one", Name: "alfa"}, + Spec: v1.ServiceSpec{ + Type: v1.ServiceTypeNodePort, + ClusterIP: "np", + Ports: []v1.ServicePort{ + {Name: "https", Port: 443, TargetPort: intstr.FromInt(1443)}, + {Port: 1234, TargetPort: intstr.FromInt(1234)}, + }, + }, + }, + }, + endpoints: matchingEndpoints, + + clusterMode: expectation{url: "https://np:443"}, + endpointMode: expectation{url: "https://127.0.0.1:1443"}, + }, + { + name: "external name", + services: []*v1.Service{ + { + ObjectMeta: metav1.ObjectMeta{Namespace: "one", Name: "alfa"}, + Spec: v1.ServiceSpec{ + Type: v1.ServiceTypeExternalName, + ExternalName: "foo.bar.com", + }, + }, + }, + endpoints: nil, + + clusterMode: expectation{url: "https://foo.bar.com:443"}, + endpointMode: expectation{error: true}, + }, + { + name: "missing service", + services: nil, + endpoints: nil, + + clusterMode: expectation{error: true}, + endpointMode: expectation{error: true}, + }, + } + + for _, test := range tests { + serviceCache := cache.NewIndexer(cache.MetaNamespaceKeyFunc, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}) + serviceLister := v1listers.NewServiceLister(serviceCache) + for i := range test.services { + if err := serviceCache.Add(test.services[i]); err != nil { + t.Fatalf("%s unexpected service add error: %v", test.name, err) + } + } + + endpointCache := cache.NewIndexer(cache.MetaNamespaceKeyFunc, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}) + endpointLister := v1listers.NewEndpointsLister(endpointCache) + if test.endpoints != nil { + for _, svc := range test.services { + for _, ep := range test.endpoints(svc) { + if err := endpointCache.Add(ep); err != nil { + t.Fatalf("%s unexpected endpoint add error: %v", test.name, err) + } + } + } + } + + check := func(mode string, expected expectation, url *url.URL, err error) { + switch { + case err == nil && expected.error: + t.Errorf("%s in %s mode expected error, got none", test.name, mode) + case err != nil && expected.error: + // ignore + case err != nil: + t.Errorf("%s in %s mode unexpected error: %v", test.name, mode, err) + case url.String() != expected.url: + t.Errorf("%s in %s mode expected url %q, got %q", test.name, mode, expected.url, url.String()) + } + } + + clusterURL, err := ResolveCluster(serviceLister, "one", "alfa") + check("cluster", test.clusterMode, clusterURL, err) + + endpointURL, err := ResolveEndpoint(serviceLister, endpointLister, "one", "alfa") + check("endpoint", test.endpointMode, endpointURL, err) + } +} diff --git a/staging/src/k8s.io/apiserver/plugin/pkg/audit/log/backend.go b/staging/src/k8s.io/apiserver/plugin/pkg/audit/log/backend.go index fe15a77d803ff..3712d728c7a8d 100644 --- a/staging/src/k8s.io/apiserver/plugin/pkg/audit/log/backend.go +++ b/staging/src/k8s.io/apiserver/plugin/pkg/audit/log/backend.go @@ -82,8 +82,8 @@ func (b *backend) logEvent(ev *auditinternal.Event) { ip = ev.SourceIPs[0] } - line := fmt.Sprintf("%s AUDIT: id=%q ip=%q method=%q user=%q groups=%q as=%q asgroups=%q namespace=%q uri=%q response=\"%s\"\n", - ev.Timestamp.Format(time.RFC3339Nano), ev.AuditID, ip, ev.Verb, username, groups, asuser, asgroups, namespace, ev.RequestURI, response) + line := fmt.Sprintf("%s AUDIT: id=%q stage=%q ip=%q method=%q user=%q groups=%q as=%q asgroups=%q namespace=%q uri=%q response=\"%s\"\n", + ev.Timestamp.Format(time.RFC3339Nano), ev.AuditID, ev.Stage, ip, ev.Verb, username, groups, asuser, asgroups, namespace, ev.RequestURI, response) if _, err := fmt.Fprint(b.out, line); err != nil { glog.Errorf("Unable to write audit log: %s, the error is: %v", line, err) } diff --git a/staging/src/k8s.io/apiserver/plugin/pkg/audit/webhook/BUILD b/staging/src/k8s.io/apiserver/plugin/pkg/audit/webhook/BUILD new file mode 100644 index 0000000000000..d11c970f18340 --- /dev/null +++ b/staging/src/k8s.io/apiserver/plugin/pkg/audit/webhook/BUILD @@ -0,0 +1,46 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["webhook_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/github.com/stretchr/testify/assert:go_default_library", + "//vendor/github.com/stretchr/testify/require:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/json:go_default_library", + "//vendor/k8s.io/apiserver/pkg/apis/audit:go_default_library", + "//vendor/k8s.io/apiserver/pkg/apis/audit/v1alpha1:go_default_library", + "//vendor/k8s.io/apiserver/pkg/audit:go_default_library", + "//vendor/k8s.io/client-go/tools/clientcmd/api/v1:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = ["webhook.go"], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", + "//vendor/k8s.io/apiserver/pkg/apis/audit:go_default_library", + "//vendor/k8s.io/apiserver/pkg/apis/audit/install:go_default_library", + "//vendor/k8s.io/apiserver/pkg/apis/audit/v1alpha1:go_default_library", + "//vendor/k8s.io/apiserver/pkg/audit:go_default_library", + "//vendor/k8s.io/apiserver/pkg/util/webhook:go_default_library", + ], +) diff --git a/staging/src/k8s.io/apiserver/plugin/pkg/audit/webhook/webhook.go b/staging/src/k8s.io/apiserver/plugin/pkg/audit/webhook/webhook.go new file mode 100644 index 0000000000000..7dfc1b7158a41 --- /dev/null +++ b/staging/src/k8s.io/apiserver/plugin/pkg/audit/webhook/webhook.go @@ -0,0 +1,285 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// Package webhook implements the audit.Backend interface using HTTP webhooks. +package webhook + +import ( + "fmt" + "reflect" + "strings" + "time" + + "github.com/golang/glog" + + "k8s.io/apimachinery/pkg/apimachinery/announced" + "k8s.io/apimachinery/pkg/apimachinery/registered" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/util/runtime" + auditinternal "k8s.io/apiserver/pkg/apis/audit" + "k8s.io/apiserver/pkg/apis/audit/install" + auditv1alpha1 "k8s.io/apiserver/pkg/apis/audit/v1alpha1" + "k8s.io/apiserver/pkg/audit" + "k8s.io/apiserver/pkg/util/webhook" +) + +const ( + // ModeBatch indicates that the webhook should buffer audit events + // internally, sending batch updates either once a certain number of + // events have been received or a certain amount of time has passed. + ModeBatch = "batch" + // ModeBlocking causes the webhook to block on every attempt to process + // a set of events. This causes requests to the API server to wait for a + // round trip to the external audit service before sending a response. + ModeBlocking = "blocking" +) + +// AllowedModes is the modes known by this webhook. +var AllowedModes = []string{ + ModeBatch, + ModeBlocking, +} + +const ( + // Default configuration values for ModeBatch. + // + // TODO(ericchiang): Make these value configurable. Maybe through a + // kubeconfig extension? + defaultBatchBufferSize = 1000 // Buffer up to 1000 events before blocking. + defaultBatchMaxSize = 100 // Only send 100 events at a time. + defaultBatchMaxWait = time.Minute // Send events at least once a minute. +) + +// NewBackend returns an audit backend that sends events over HTTP to an external service. +// The mode indicates the caching behavior of the webhook. Either blocking (ModeBlocking) +// or buffered with batch POSTs (ModeBatch). +func NewBackend(kubeConfigFile string, mode string) (audit.Backend, error) { + switch mode { + case ModeBatch: + return newBatchWebhook(kubeConfigFile) + case ModeBlocking: + return newBlockingWebhook(kubeConfigFile) + default: + return nil, fmt.Errorf("webhook mode %q is not in list of known modes (%s)", + mode, strings.Join(AllowedModes, ",")) + } +} + +var ( + // NOTE: Copied from other webhook implementations + // + // Can we make these passable to NewGenericWebhook? + groupFactoryRegistry = make(announced.APIGroupFactoryRegistry) + groupVersions = []schema.GroupVersion{auditv1alpha1.SchemeGroupVersion} + registry = registered.NewOrDie("") +) + +func init() { + registry.RegisterVersions(groupVersions) + if err := registry.EnableVersions(groupVersions...); err != nil { + panic(fmt.Sprintf("failed to enable version %v", groupVersions)) + } + install.Install(groupFactoryRegistry, registry, audit.Scheme) +} + +func loadWebhook(configFile string) (*webhook.GenericWebhook, error) { + return webhook.NewGenericWebhook(registry, audit.Codecs, configFile, groupVersions, 0) +} + +func newBlockingWebhook(configFile string) (*blockingBackend, error) { + w, err := loadWebhook(configFile) + if err != nil { + return nil, err + } + return &blockingBackend{w}, nil +} + +type blockingBackend struct { + w *webhook.GenericWebhook +} + +func (b *blockingBackend) Run(stopCh <-chan struct{}) error { + return nil +} + +func (b *blockingBackend) ProcessEvents(ev ...*auditinternal.Event) { + if err := b.processEvents(ev...); err != nil { + glog.Errorf("failed to POST webhook events: %v", err) + } +} + +func (b *blockingBackend) processEvents(ev ...*auditinternal.Event) error { + var list auditinternal.EventList + for _, e := range ev { + list.Items = append(list.Items, *e) + } + // NOTE: No exponential backoff because this is the blocking webhook + // mode. Any attempts to retry will block API server requests. + return b.w.RestClient.Post().Body(&list).Do().Error() +} + +// Copied from generated code in k8s.io/apiserver/pkg/apis/audit. +// +// TODO(ericchiang): Have the generated code expose these methods like metav1.GetGeneratedDeepCopyFuncs(). +var auditDeepCopyFuncs = []conversion.GeneratedDeepCopyFunc{ + {Fn: auditinternal.DeepCopy_audit_Event, InType: reflect.TypeOf(&auditinternal.Event{})}, + {Fn: auditinternal.DeepCopy_audit_EventList, InType: reflect.TypeOf(&auditinternal.EventList{})}, + {Fn: auditinternal.DeepCopy_audit_GroupResources, InType: reflect.TypeOf(&auditinternal.GroupResources{})}, + {Fn: auditinternal.DeepCopy_audit_ObjectReference, InType: reflect.TypeOf(&auditinternal.ObjectReference{})}, + {Fn: auditinternal.DeepCopy_audit_Policy, InType: reflect.TypeOf(&auditinternal.Policy{})}, + {Fn: auditinternal.DeepCopy_audit_PolicyList, InType: reflect.TypeOf(&auditinternal.PolicyList{})}, + {Fn: auditinternal.DeepCopy_audit_PolicyRule, InType: reflect.TypeOf(&auditinternal.PolicyRule{})}, + {Fn: auditinternal.DeepCopy_audit_UserInfo, InType: reflect.TypeOf(&auditinternal.UserInfo{})}, +} + +func newBatchWebhook(configFile string) (*batchBackend, error) { + w, err := loadWebhook(configFile) + if err != nil { + return nil, err + } + + c := conversion.NewCloner() + for _, f := range metav1.GetGeneratedDeepCopyFuncs() { + if err := c.RegisterGeneratedDeepCopyFunc(f); err != nil { + return nil, fmt.Errorf("registering meta deep copy method: %v", err) + } + } + + for _, f := range auditDeepCopyFuncs { + if err := c.RegisterGeneratedDeepCopyFunc(f); err != nil { + return nil, fmt.Errorf("registering audit deep copy method: %v", err) + } + } + + return &batchBackend{ + w: w, + buffer: make(chan *auditinternal.Event, defaultBatchBufferSize), + maxBatchSize: defaultBatchMaxSize, + maxBatchWait: defaultBatchMaxWait, + cloner: c, + }, nil +} + +type batchBackend struct { + w *webhook.GenericWebhook + + // Cloner is used to deep copy events as they are buffered. + cloner *conversion.Cloner + + // Channel to buffer events in memory before sending them on the webhook. + buffer chan *auditinternal.Event + // Maximum number of events that can be sent at once. + maxBatchSize int + // Amount of time to wait after sending events before force sending another set. + // + // Receiving maxBatchSize events will always trigger a send, regardless of + // if this amount of time has been reached. + maxBatchWait time.Duration +} + +func (b *batchBackend) Run(stopCh <-chan struct{}) error { + f := func() { + // Recover from any panics caused by this method so a panic in the + // goroutine can't bring down the main routine. + defer runtime.HandleCrash() + + t := time.NewTimer(b.maxBatchWait) + defer t.Stop() // Release ticker resources + + b.sendBatchEvents(stopCh, t.C) + } + + go func() { + for { + f() + + select { + case <-stopCh: + return + default: + } + } + }() + return nil +} + +// sendBatchEvents attempts to batch some number of events to the backend. It POSTs events +// in a goroutine and logging any error encountered during the POST. +// +// The following things can cause sendBatchEvents to exit: +// +// * Some maximum number of events are received. +// * Timer has passed, all queued events are sent. +// * StopCh is closed, all queued events are sent. +// +func (b *batchBackend) sendBatchEvents(stopCh <-chan struct{}, timer <-chan time.Time) { + var events []auditinternal.Event + +L: + for i := 0; i < b.maxBatchSize; i++ { + select { + case ev := <-b.buffer: + events = append(events, *ev) + case <-timer: + // Timer has expired. Send whatever events are in the queue. + break L + case <-stopCh: + // Webhook has shut down. Send the last events. + break L + } + } + + if len(events) == 0 { + return + } + + list := auditinternal.EventList{Items: events} + go func() { + // Execute the webhook POST in a goroutine to keep it from blocking. + // This lets the webhook continue to drain the queue immediatly. + + defer runtime.HandleCrash() + + err := webhook.WithExponentialBackoff(0, func() error { + return b.w.RestClient.Post().Body(&list).Do().Error() + }) + if err != nil { + glog.Errorf("failed to POST webhook events: %v", err) + } + }() + return +} + +func (b *batchBackend) ProcessEvents(ev ...*auditinternal.Event) { + for i, e := range ev { + // Per the audit.Backend interface these events are reused after being + // sent to the Sink. Deep copy and send the copy to the queue. + event := new(auditinternal.Event) + if err := auditinternal.DeepCopy_audit_Event(e, event, b.cloner); err != nil { + glog.Errorf("failed to clone audit event: %v: %#v", err, e) + return + } + + select { + case b.buffer <- event: + default: + glog.Errorf("audit webhook queue blocked, failed to send %d event(s)", len(ev)-i) + return + } + } +} diff --git a/staging/src/k8s.io/apiserver/plugin/pkg/audit/webhook/webhook_test.go b/staging/src/k8s.io/apiserver/plugin/pkg/audit/webhook/webhook_test.go new file mode 100644 index 0000000000000..728e209c4a475 --- /dev/null +++ b/staging/src/k8s.io/apiserver/plugin/pkg/audit/webhook/webhook_test.go @@ -0,0 +1,332 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package webhook + +import ( + stdjson "encoding/json" + "fmt" + "io" + "io/ioutil" + "net/http" + "net/http/httptest" + "os" + "sync" + "sync/atomic" + "testing" + "time" + + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/serializer/json" + auditinternal "k8s.io/apiserver/pkg/apis/audit" + auditv1alpha1 "k8s.io/apiserver/pkg/apis/audit/v1alpha1" + "k8s.io/apiserver/pkg/audit" + "k8s.io/client-go/tools/clientcmd/api/v1" +) + +// newWebhookHandler returns a handler which recieves webhook events and decodes the +// request body. The caller passes a callback which is called on each webhook POST. +func newWebhookHandler(t *testing.T, cb func(events *auditv1alpha1.EventList)) http.Handler { + s := json.NewSerializer(json.DefaultMetaFactory, audit.Scheme, audit.Scheme, false) + return &testWebhookHandler{ + t: t, + onEvents: cb, + serializer: s, + } +} + +type testWebhookHandler struct { + t *testing.T + + onEvents func(events *auditv1alpha1.EventList) + + serializer runtime.Serializer +} + +func (t *testWebhookHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) { + err := func() error { + body, err := ioutil.ReadAll(r.Body) + if err != nil { + return fmt.Errorf("read webhook request body: %v", err) + } + + obj, _, err := t.serializer.Decode(body, nil, &auditv1alpha1.EventList{}) + if err != nil { + return fmt.Errorf("decode request body: %v", err) + } + list, ok := obj.(*auditv1alpha1.EventList) + if !ok { + return fmt.Errorf("expected *v1alpha1.EventList got %T", obj) + } + t.onEvents(list) + return nil + }() + + if err == nil { + io.WriteString(w, "{}") + return + } + // In a goroutine, can't call Fatal. + assert.NoError(t.t, err, "failed to read request body") + http.Error(w, err.Error(), http.StatusInternalServerError) +} + +func newTestBlockingWebhook(t *testing.T, endpoint string) *blockingBackend { + return newWebhook(t, endpoint, ModeBlocking).(*blockingBackend) +} + +func newTestBatchWebhook(t *testing.T, endpoint string) *batchBackend { + return newWebhook(t, endpoint, ModeBatch).(*batchBackend) +} + +func newWebhook(t *testing.T, endpoint string, mode string) audit.Backend { + config := v1.Config{ + Clusters: []v1.NamedCluster{ + {Cluster: v1.Cluster{Server: endpoint, InsecureSkipTLSVerify: true}}, + }, + } + f, err := ioutil.TempFile("", "k8s_audit_webhook_test_") + require.NoError(t, err, "creating temp file") + + defer func() { + f.Close() + os.Remove(f.Name()) + }() + + // NOTE(ericchiang): Do we need to use a proper serializer? + require.NoError(t, stdjson.NewEncoder(f).Encode(config), "writing kubeconfig") + + backend, err := NewBackend(f.Name(), mode) + require.NoError(t, err, "initializing backend") + + return backend +} + +func TestWebhook(t *testing.T) { + gotEvents := false + defer func() { require.True(t, gotEvents, "no events received") }() + + s := httptest.NewServer(newWebhookHandler(t, func(events *auditv1alpha1.EventList) { + gotEvents = true + })) + defer s.Close() + + backend := newTestBlockingWebhook(t, s.URL) + + // Ensure this doesn't return a serialization error. + event := &auditinternal.Event{} + require.NoError(t, backend.processEvents(event), "failed to send events") +} + +// waitForEmptyBuffer indicates when the sendBatchEvents method has read from the +// existing buffer. This lets test coordinate closing a timer and stop channel +// until the for loop has read from the buffer. +func waitForEmptyBuffer(b *batchBackend) { + for len(b.buffer) != 0 { + time.Sleep(time.Millisecond) + } +} + +func TestBatchWebhookMaxEvents(t *testing.T) { + nRest := 10 + events := make([]*auditinternal.Event, defaultBatchMaxSize+nRest) // greater than max size. + for i := range events { + events[i] = &auditinternal.Event{} + } + + got := make(chan int, 2) + s := httptest.NewServer(newWebhookHandler(t, func(events *auditv1alpha1.EventList) { + got <- len(events.Items) + })) + defer s.Close() + + backend := newTestBatchWebhook(t, s.URL) + + backend.ProcessEvents(events...) + + stopCh := make(chan struct{}) + timer := make(chan time.Time, 1) + + backend.sendBatchEvents(stopCh, timer) + require.Equal(t, defaultBatchMaxSize, <-got, "did not get batch max size") + + go func() { + waitForEmptyBuffer(backend) // wait for the buffer to empty + timer <- time.Now() // Trigger the wait timeout + }() + + backend.sendBatchEvents(stopCh, timer) + require.Equal(t, nRest, <-got, "failed to get the rest of the events") +} + +func TestBatchWebhookStopCh(t *testing.T) { + events := make([]*auditinternal.Event, 1) // less than max size. + for i := range events { + events[i] = &auditinternal.Event{} + } + + expected := len(events) + got := make(chan int, 2) + s := httptest.NewServer(newWebhookHandler(t, func(events *auditv1alpha1.EventList) { + got <- len(events.Items) + })) + defer s.Close() + + backend := newTestBatchWebhook(t, s.URL) + backend.ProcessEvents(events...) + + stopCh := make(chan struct{}) + timer := make(chan time.Time) + + go func() { + waitForEmptyBuffer(backend) + close(stopCh) // stop channel has stopped + }() + backend.sendBatchEvents(stopCh, timer) + require.Equal(t, expected, <-got, "get queued events after timer expires") +} + +func TestBatchWebhookEmptyBuffer(t *testing.T) { + events := make([]*auditinternal.Event, 1) // less than max size. + for i := range events { + events[i] = &auditinternal.Event{} + } + + expected := len(events) + got := make(chan int, 2) + s := httptest.NewServer(newWebhookHandler(t, func(events *auditv1alpha1.EventList) { + got <- len(events.Items) + })) + defer s.Close() + + backend := newTestBatchWebhook(t, s.URL) + + stopCh := make(chan struct{}) + timer := make(chan time.Time, 1) + + timer <- time.Now() // Timer is done. + + // Buffer is empty, no events have been queued. This should exit but send no events. + backend.sendBatchEvents(stopCh, timer) + + // Send additional events after the sendBatchEvents has been called. + backend.ProcessEvents(events...) + go func() { + waitForEmptyBuffer(backend) + timer <- time.Now() + }() + + backend.sendBatchEvents(stopCh, timer) + + // Make sure we didn't get a POST with zero events. + require.Equal(t, expected, <-got, "expected one event") +} + +func TestBatchBufferFull(t *testing.T) { + events := make([]*auditinternal.Event, defaultBatchBufferSize+1) // More than buffered size + for i := range events { + events[i] = &auditinternal.Event{} + } + s := httptest.NewServer(newWebhookHandler(t, func(events *auditv1alpha1.EventList) { + // Do nothing. + })) + defer s.Close() + + backend := newTestBatchWebhook(t, s.URL) + + // Make sure this doesn't block. + backend.ProcessEvents(events...) +} + +func TestBatchRun(t *testing.T) { + + // Divisable by max batch size so we don't have to wait for a minute for + // the test to finish. + events := make([]*auditinternal.Event, defaultBatchMaxSize*3) + for i := range events { + events[i] = &auditinternal.Event{} + } + + got := new(int64) + want := len(events) + + wg := new(sync.WaitGroup) + wg.Add(want) + done := make(chan struct{}) + + go func() { + wg.Wait() + // When the expected number of events have been received, close the channel. + close(done) + }() + + s := httptest.NewServer(newWebhookHandler(t, func(events *auditv1alpha1.EventList) { + atomic.AddInt64(got, int64(len(events.Items))) + wg.Add(-len(events.Items)) + })) + defer s.Close() + + stopCh := make(chan struct{}) + defer close(stopCh) + + backend := newTestBatchWebhook(t, s.URL) + + // Test the Run codepath. E.g. that the spawned goroutines behave correctly. + backend.Run(stopCh) + + backend.ProcessEvents(events...) + + select { + case <-done: + // Received all the events. + case <-time.After(2 * time.Minute): + t.Errorf("expected %d events got %d", want, atomic.LoadInt64(got)) + } +} + +func TestBatchConcurrentRequests(t *testing.T) { + events := make([]*auditinternal.Event, defaultBatchBufferSize) // Don't drop events + for i := range events { + events[i] = &auditinternal.Event{} + } + + wg := new(sync.WaitGroup) + wg.Add(len(events)) + + s := httptest.NewServer(newWebhookHandler(t, func(events *auditv1alpha1.EventList) { + wg.Add(-len(events.Items)) + + // Since the webhook makes concurrent requests, blocking on the webhook response + // shouldn't block the webhook from sending more events. + // + // Wait for all responses to be received before sending the response. + wg.Wait() + })) + defer s.Close() + + stopCh := make(chan struct{}) + defer close(stopCh) + + backend := newTestBatchWebhook(t, s.URL) + backend.Run(stopCh) + + backend.ProcessEvents(events...) + // Wait for the webhook to receive all events. + wg.Wait() +} diff --git a/staging/src/k8s.io/client-go/examples/create-update-delete-deployment/BUILD b/staging/src/k8s.io/client-go/examples/create-update-delete-deployment/BUILD new file mode 100644 index 0000000000000..8179d0cf146cb --- /dev/null +++ b/staging/src/k8s.io/client-go/examples/create-update-delete-deployment/BUILD @@ -0,0 +1,29 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_binary", + "go_library", +) + +go_binary( + name = "create-update-delete-deployment", + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = ["main.go"], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/apps/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/tools/clientcmd:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/examples/create-update-delete-deployment/README.md b/staging/src/k8s.io/client-go/examples/create-update-delete-deployment/README.md new file mode 100644 index 0000000000000..6b7ed4eac988b --- /dev/null +++ b/staging/src/k8s.io/client-go/examples/create-update-delete-deployment/README.md @@ -0,0 +1,81 @@ +# Create, Update & Delete Deployment + +This example program demonstrates the fundamental operations for managing on +[Deployment][1] resources, such as `Create`, `List`, `Update` and `Delete`. + +You can adopt the source code from this example to write programs that manage +other types of resources through the Kubernetes API. + +## Running this example + +Make sure you have a Kubernetes cluster and `kubectl` is configured: + + kubectl get nodes + +Compile this example on your workstation: + +``` +cd create-update-delete-deployment +go build -o ./app +``` + +Now, run this application on your workstation with your local kubeconfig file: + +``` +./app -kubeconfig=$HOME/.kube/config +``` + +Running this command will execute the following operations on your cluster: + +1. **Create Deployment:** This will create a 2 replica Deployment. Verify with + `kubectl get pods`. +2. **Update Deployment:** This will update the Deployment resource created in + previous step to set the replica count to 1 and add annotations. You are + encouraged to inspect the retry loop that handles conflicts. Verify the new + replica count and `foo=bar` annotation with `kubectl describe deployment + demo`. +3. **List Deployments:** This will retrieve Deployments in the `default` + namespace and print their names and replica counts. +4. **Delete Deployment:** This will delete the Deployment object and its + dependent ReplicaSet resource. Verify with `kubectl get deployments`. + +Each step is separated by an interactive prompt. You must hit the +Return key to proceeed to the next step. You can use these prompts as +a break to take time to run `kubectl` and inspect the result of the operations +executed. + +You should see an output like the following: + +``` +Creating deployment... +Created deployment "demo-deployment". +-> Press Return key to continue. + +Updating deployment... +Updated deployment... +-> Press Return key to continue. + +Listing deployments in namespace "default": + * demo-deployment (1 replicas) +-> Press Return key to continue. + +Deleting deployment... +Deleted deployment. +``` + +## Cleanup + +Successfully running this program will clean the created artifacts. If you +terminate the program without completing, you can clean up the created +deployment with: + + kubectl delete deploy demo-deployment + +## Troubleshooting + +If you are getting the following error, make sure Kubernetes version of your +cluster is v1.6 or above in `kubectl version`: + + panic: the server could not find the requested resource + +[1]: https://kubernetes.io/docs/user-guide/deployments/ diff --git a/staging/src/k8s.io/client-go/examples/create-update-delete-deployment/main.go b/staging/src/k8s.io/client-go/examples/create-update-delete-deployment/main.go new file mode 100644 index 0000000000000..2913510f2e366 --- /dev/null +++ b/staging/src/k8s.io/client-go/examples/create-update-delete-deployment/main.go @@ -0,0 +1,165 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// Note: the example only works with the code within the same release/branch. +package main + +import ( + "bufio" + "flag" + "fmt" + "os" + + "k8s.io/apimachinery/pkg/api/errors" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/client-go/kubernetes" + apiv1 "k8s.io/client-go/pkg/api/v1" + appsv1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" + "k8s.io/client-go/tools/clientcmd" + // Uncomment the following line to load the gcp plugin (only required to authenticate against GKE clusters). + // _ "k8s.io/client-go/plugin/pkg/client/auth/gcp" +) + +func main() { + kubeconfig := flag.String("kubeconfig", "", "absolute path to the kubeconfig file") + flag.Parse() + if *kubeconfig == "" { + panic("-kubeconfig not specified") + } + config, err := clientcmd.BuildConfigFromFlags("", *kubeconfig) + if err != nil { + panic(err) + } + clientset, err := kubernetes.NewForConfig(config) + if err != nil { + panic(err) + } + + deploymentsClient := clientset.AppsV1beta1().Deployments(apiv1.NamespaceDefault) + + deployment := &appsv1beta1.Deployment{ + ObjectMeta: metav1.ObjectMeta{ + Name: "demo-deployment", + }, + Spec: appsv1beta1.DeploymentSpec{ + Replicas: int32Ptr(2), + Template: apiv1.PodTemplateSpec{ + ObjectMeta: metav1.ObjectMeta{ + Labels: map[string]string{ + "app": "demo", + }, + }, + Spec: apiv1.PodSpec{ + Containers: []apiv1.Container{ + { + Name: "web", + Image: "nginx:1.13", + Ports: []apiv1.ContainerPort{ + { + Name: "http", + Protocol: apiv1.ProtocolTCP, + ContainerPort: 80, + }, + }, + }, + }, + }, + }, + }, + } + + // Create Deployment + fmt.Println("Creating deployment...") + result, err := deploymentsClient.Create(deployment) + if err != nil { + panic(err) + } + fmt.Printf("Created deployment %q.\n", result.GetObjectMeta().GetName()) + + // Update Deployment + prompt() + fmt.Println("Updating deployment...") + // You have two options to Update() this Deployment: + // + // 1. Modify the "deployment" variable and call: Update(deployment). + // This works like the "kubectl replace" command and it overwrites/loses changes + // made by other clients between you Create() and Update() the object. + // 2. Modify the "result" returned by Create()/Get() and retry Update(result) until + // you no longer get a conflict error. This way, you can preserve changes made + // by other clients between Create() and Update(). This is implemented below: + + for { + result.Spec.Replicas = int32Ptr(1) // reduce replica count + result.Spec.Template.Annotations = map[string]string{ // add annotations + "foo": "bar", + } + + if _, err := deploymentsClient.Update(result); errors.IsConflict(err) { + // Deployment is modified in the meanwhile, query the latest version + // and modify the retrieved object. + fmt.Println("encountered conflict, retrying") + result, err = deploymentsClient.Get("demo-deployment", metav1.GetOptions{}) + if err != nil { + panic(fmt.Errorf("Get failed: %+v", err)) + } + } else if err != nil { + panic(err) + } else { + break + } + + // TODO: You should sleep here with an exponential backoff to avoid + // exhausting the apiserver, and add a limit/timeout on the retries to + // avoid getting stuck in this loop indefintiely. + } + fmt.Println("Updated deployment...") + + // List Deployments + prompt() + fmt.Printf("Listing deployments in namespace %q:\n", apiv1.NamespaceDefault) + list, err := deploymentsClient.List(metav1.ListOptions{}) + if err != nil { + panic(err) + } + for _, d := range list.Items { + fmt.Printf(" * %s (%d replicas)\n", d.Name, *d.Spec.Replicas) + } + + // Delete Deployment + prompt() + fmt.Println("Deleting deployment...") + deletePolicy := metav1.DeletePropagationForeground + if err := deploymentsClient.Delete("demo-deployment", &metav1.DeleteOptions{ + PropagationPolicy: &deletePolicy, + }); err != nil { + panic(err) + } + fmt.Println("Deleted deployment.") +} + +func prompt() { + fmt.Printf("-> Press Return key to continue.") + scanner := bufio.NewScanner(os.Stdin) + for scanner.Scan() { + break + } + if err := scanner.Err(); err != nil { + panic(err) + } + fmt.Println() +} + +func int32Ptr(i int32) *int32 { return &i } diff --git a/staging/src/k8s.io/client-go/examples/out-of-cluster/README.md b/staging/src/k8s.io/client-go/examples/out-of-cluster/README.md new file mode 100644 index 0000000000000..f82e8d31abd69 --- /dev/null +++ b/staging/src/k8s.io/client-go/examples/out-of-cluster/README.md @@ -0,0 +1,34 @@ +# Authenticating outside the cluster + +This example shows you how to authenticate to the Kubernetes API from an +application running outside the Kubernetes cluster with client-go. + +You can use your kubeconfig file that contains the context information +of your cluster to initialize a client. The kubeconfig file is also used +by the `kubectl` command to authenticate to the clusters. + +## Running this example + +Make sure your `kubectl` is configured and pointed to a cluster. Run +`kubectl get nodes` to confirm. + +Run this application with: + + cd out-of-cluster + go build -o app . + ./app + +Running this application will use the kubeconfig file and then authenticate to the +cluster, and print the number of nodes in the cluster every 10 seconds: + + $ ./app + There are 3 pods in the cluster + There are 3 pods in the cluster + There are 3 pods in the cluster + ... + +Press Ctrl+C to quit this application. + +> **Note:** You can use the `-kubeconfig` option to use a different config file. By default +this program picks up the default file used by kubectl (when `KUBECONFIG` +environment variable is not set). diff --git a/staging/src/k8s.io/client-go/examples/out-of-cluster/main.go b/staging/src/k8s.io/client-go/examples/out-of-cluster/main.go index a76fd2cb64a6e..b76278b7e94f4 100644 --- a/staging/src/k8s.io/client-go/examples/out-of-cluster/main.go +++ b/staging/src/k8s.io/client-go/examples/out-of-cluster/main.go @@ -20,6 +20,8 @@ package main import ( "flag" "fmt" + "os" + "path/filepath" "time" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -30,14 +32,21 @@ import ( ) func main() { - kubeconfig := flag.String("kubeconfig", "./config", "absolute path to the kubeconfig file") + var kubeconfig *string + if home := homeDir(); home != "" { + kubeconfig = flag.String("kubeconfig", filepath.Join(home, ".kube", "config"), "(optional) absolute path to the kubeconfig file") + } else { + kubeconfig = flag.String("kubeconfig", "", "absolute path to the kubeconfig file") + } flag.Parse() - // uses the current context in kubeconfig + + // use the current context in kubeconfig config, err := clientcmd.BuildConfigFromFlags("", *kubeconfig) if err != nil { panic(err.Error()) } - // creates the clientset + + // create the clientset clientset, err := kubernetes.NewForConfig(config) if err != nil { panic(err.Error()) @@ -51,3 +60,10 @@ func main() { time.Sleep(10 * time.Second) } } + +func homeDir() string { + if h := os.Getenv("HOME"); h != "" { + return h + } + return os.Getenv("USERPROFILE") // windows +} diff --git a/staging/src/k8s.io/client-go/informers/BUILD b/staging/src/k8s.io/client-go/informers/BUILD index 8326e4fad65b5..f1d8113b0e287 100644 --- a/staging/src/k8s.io/client-go/informers/BUILD +++ b/staging/src/k8s.io/client-go/informers/BUILD @@ -17,6 +17,7 @@ go_library( deps = [ "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/client-go/informers/admissionregistration:go_default_library", "//vendor/k8s.io/client-go/informers/apps:go_default_library", "//vendor/k8s.io/client-go/informers/autoscaling:go_default_library", "//vendor/k8s.io/client-go/informers/batch:go_default_library", @@ -24,12 +25,14 @@ go_library( "//vendor/k8s.io/client-go/informers/core:go_default_library", "//vendor/k8s.io/client-go/informers/extensions:go_default_library", "//vendor/k8s.io/client-go/informers/internalinterfaces:go_default_library", + "//vendor/k8s.io/client-go/informers/networking:go_default_library", "//vendor/k8s.io/client-go/informers/policy:go_default_library", "//vendor/k8s.io/client-go/informers/rbac:go_default_library", "//vendor/k8s.io/client-go/informers/settings:go_default_library", "//vendor/k8s.io/client-go/informers/storage:go_default_library", "//vendor/k8s.io/client-go/kubernetes:go_default_library", "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/apps/v1beta1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/autoscaling/v1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1:go_default_library", @@ -37,6 +40,7 @@ go_library( "//vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/networking/v1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/policy/v1beta1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1:go_default_library", diff --git a/staging/src/k8s.io/client-go/informers/admissionregistration/BUILD b/staging/src/k8s.io/client-go/informers/admissionregistration/BUILD new file mode 100644 index 0000000000000..ca0f9dd2281eb --- /dev/null +++ b/staging/src/k8s.io/client-go/informers/admissionregistration/BUILD @@ -0,0 +1,18 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["interface.go"], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/client-go/informers/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/informers/internalinterfaces:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/informers/admissionregistration/interface.go b/staging/src/k8s.io/client-go/informers/admissionregistration/interface.go new file mode 100644 index 0000000000000..19099ba0225ba --- /dev/null +++ b/staging/src/k8s.io/client-go/informers/admissionregistration/interface.go @@ -0,0 +1,44 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package admissionregistration + +import ( + v1alpha1 "k8s.io/client-go/informers/admissionregistration/v1alpha1" + internalinterfaces "k8s.io/client-go/informers/internalinterfaces" +) + +// Interface provides access to each of this group's versions. +type Interface interface { + // V1alpha1 provides access to shared informers for resources in V1alpha1. + V1alpha1() v1alpha1.Interface +} + +type group struct { + internalinterfaces.SharedInformerFactory +} + +// New returns a new Interface. +func New(f internalinterfaces.SharedInformerFactory) Interface { + return &group{f} +} + +// V1alpha1 returns a new v1alpha1.Interface. +func (g *group) V1alpha1() v1alpha1.Interface { + return v1alpha1.New(g.SharedInformerFactory) +} diff --git a/staging/src/k8s.io/client-go/informers/admissionregistration/v1alpha1/BUILD b/staging/src/k8s.io/client-go/informers/admissionregistration/v1alpha1/BUILD new file mode 100644 index 0000000000000..05fc570b15f52 --- /dev/null +++ b/staging/src/k8s.io/client-go/informers/admissionregistration/v1alpha1/BUILD @@ -0,0 +1,28 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "externaladmissionhookconfiguration.go", + "initializerconfiguration.go", + "interface.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/informers/internalinterfaces:go_default_library", + "//vendor/k8s.io/client-go/kubernetes:go_default_library", + "//vendor/k8s.io/client-go/listers/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/informers/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go b/staging/src/k8s.io/client-go/informers/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go new file mode 100644 index 0000000000000..80fd1e052593b --- /dev/null +++ b/staging/src/k8s.io/client-go/informers/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go @@ -0,0 +1,68 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + internalinterfaces "k8s.io/client-go/informers/internalinterfaces" + kubernetes "k8s.io/client-go/kubernetes" + v1alpha1 "k8s.io/client-go/listers/admissionregistration/v1alpha1" + admissionregistration_v1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" + cache "k8s.io/client-go/tools/cache" + time "time" +) + +// ExternalAdmissionHookConfigurationInformer provides access to a shared informer and lister for +// ExternalAdmissionHookConfigurations. +type ExternalAdmissionHookConfigurationInformer interface { + Informer() cache.SharedIndexInformer + Lister() v1alpha1.ExternalAdmissionHookConfigurationLister +} + +type externalAdmissionHookConfigurationInformer struct { + factory internalinterfaces.SharedInformerFactory +} + +func newExternalAdmissionHookConfigurationInformer(client kubernetes.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + sharedIndexInformer := cache.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options v1.ListOptions) (runtime.Object, error) { + return client.AdmissionregistrationV1alpha1().ExternalAdmissionHookConfigurations(v1.NamespaceAll).List(options) + }, + WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { + return client.AdmissionregistrationV1alpha1().ExternalAdmissionHookConfigurations(v1.NamespaceAll).Watch(options) + }, + }, + &admissionregistration_v1alpha1.ExternalAdmissionHookConfiguration{}, + resyncPeriod, + cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, + ) + + return sharedIndexInformer +} + +func (f *externalAdmissionHookConfigurationInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&admissionregistration_v1alpha1.ExternalAdmissionHookConfiguration{}, newExternalAdmissionHookConfigurationInformer) +} + +func (f *externalAdmissionHookConfigurationInformer) Lister() v1alpha1.ExternalAdmissionHookConfigurationLister { + return v1alpha1.NewExternalAdmissionHookConfigurationLister(f.Informer().GetIndexer()) +} diff --git a/staging/src/k8s.io/client-go/informers/admissionregistration/v1alpha1/initializerconfiguration.go b/staging/src/k8s.io/client-go/informers/admissionregistration/v1alpha1/initializerconfiguration.go new file mode 100644 index 0000000000000..4fd4df13e7b92 --- /dev/null +++ b/staging/src/k8s.io/client-go/informers/admissionregistration/v1alpha1/initializerconfiguration.go @@ -0,0 +1,68 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + internalinterfaces "k8s.io/client-go/informers/internalinterfaces" + kubernetes "k8s.io/client-go/kubernetes" + v1alpha1 "k8s.io/client-go/listers/admissionregistration/v1alpha1" + admissionregistration_v1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" + cache "k8s.io/client-go/tools/cache" + time "time" +) + +// InitializerConfigurationInformer provides access to a shared informer and lister for +// InitializerConfigurations. +type InitializerConfigurationInformer interface { + Informer() cache.SharedIndexInformer + Lister() v1alpha1.InitializerConfigurationLister +} + +type initializerConfigurationInformer struct { + factory internalinterfaces.SharedInformerFactory +} + +func newInitializerConfigurationInformer(client kubernetes.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + sharedIndexInformer := cache.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options v1.ListOptions) (runtime.Object, error) { + return client.AdmissionregistrationV1alpha1().InitializerConfigurations(v1.NamespaceAll).List(options) + }, + WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { + return client.AdmissionregistrationV1alpha1().InitializerConfigurations(v1.NamespaceAll).Watch(options) + }, + }, + &admissionregistration_v1alpha1.InitializerConfiguration{}, + resyncPeriod, + cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, + ) + + return sharedIndexInformer +} + +func (f *initializerConfigurationInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&admissionregistration_v1alpha1.InitializerConfiguration{}, newInitializerConfigurationInformer) +} + +func (f *initializerConfigurationInformer) Lister() v1alpha1.InitializerConfigurationLister { + return v1alpha1.NewInitializerConfigurationLister(f.Informer().GetIndexer()) +} diff --git a/staging/src/k8s.io/client-go/informers/admissionregistration/v1alpha1/interface.go b/staging/src/k8s.io/client-go/informers/admissionregistration/v1alpha1/interface.go new file mode 100644 index 0000000000000..33ff70766c576 --- /dev/null +++ b/staging/src/k8s.io/client-go/informers/admissionregistration/v1alpha1/interface.go @@ -0,0 +1,50 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package v1alpha1 + +import ( + internalinterfaces "k8s.io/client-go/informers/internalinterfaces" +) + +// Interface provides access to all the informers in this group version. +type Interface interface { + // ExternalAdmissionHookConfigurations returns a ExternalAdmissionHookConfigurationInformer. + ExternalAdmissionHookConfigurations() ExternalAdmissionHookConfigurationInformer + // InitializerConfigurations returns a InitializerConfigurationInformer. + InitializerConfigurations() InitializerConfigurationInformer +} + +type version struct { + internalinterfaces.SharedInformerFactory +} + +// New returns a new Interface. +func New(f internalinterfaces.SharedInformerFactory) Interface { + return &version{f} +} + +// ExternalAdmissionHookConfigurations returns a ExternalAdmissionHookConfigurationInformer. +func (v *version) ExternalAdmissionHookConfigurations() ExternalAdmissionHookConfigurationInformer { + return &externalAdmissionHookConfigurationInformer{factory: v.SharedInformerFactory} +} + +// InitializerConfigurations returns a InitializerConfigurationInformer. +func (v *version) InitializerConfigurations() InitializerConfigurationInformer { + return &initializerConfigurationInformer{factory: v.SharedInformerFactory} +} diff --git a/staging/src/k8s.io/client-go/informers/apps/v1beta1/BUILD b/staging/src/k8s.io/client-go/informers/apps/v1beta1/BUILD index f19eeacba976a..927903f6b787c 100644 --- a/staging/src/k8s.io/client-go/informers/apps/v1beta1/BUILD +++ b/staging/src/k8s.io/client-go/informers/apps/v1beta1/BUILD @@ -10,6 +10,7 @@ load( go_library( name = "go_default_library", srcs = [ + "controllerrevision.go", "deployment.go", "interface.go", "statefulset.go", diff --git a/staging/src/k8s.io/client-go/informers/apps/v1beta1/controllerrevision.go b/staging/src/k8s.io/client-go/informers/apps/v1beta1/controllerrevision.go new file mode 100644 index 0000000000000..ef4dfce6baa79 --- /dev/null +++ b/staging/src/k8s.io/client-go/informers/apps/v1beta1/controllerrevision.go @@ -0,0 +1,68 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package v1beta1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + internalinterfaces "k8s.io/client-go/informers/internalinterfaces" + kubernetes "k8s.io/client-go/kubernetes" + v1beta1 "k8s.io/client-go/listers/apps/v1beta1" + apps_v1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" + cache "k8s.io/client-go/tools/cache" + time "time" +) + +// ControllerRevisionInformer provides access to a shared informer and lister for +// ControllerRevisions. +type ControllerRevisionInformer interface { + Informer() cache.SharedIndexInformer + Lister() v1beta1.ControllerRevisionLister +} + +type controllerRevisionInformer struct { + factory internalinterfaces.SharedInformerFactory +} + +func newControllerRevisionInformer(client kubernetes.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + sharedIndexInformer := cache.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options v1.ListOptions) (runtime.Object, error) { + return client.AppsV1beta1().ControllerRevisions(v1.NamespaceAll).List(options) + }, + WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { + return client.AppsV1beta1().ControllerRevisions(v1.NamespaceAll).Watch(options) + }, + }, + &apps_v1beta1.ControllerRevision{}, + resyncPeriod, + cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, + ) + + return sharedIndexInformer +} + +func (f *controllerRevisionInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&apps_v1beta1.ControllerRevision{}, newControllerRevisionInformer) +} + +func (f *controllerRevisionInformer) Lister() v1beta1.ControllerRevisionLister { + return v1beta1.NewControllerRevisionLister(f.Informer().GetIndexer()) +} diff --git a/staging/src/k8s.io/client-go/informers/apps/v1beta1/interface.go b/staging/src/k8s.io/client-go/informers/apps/v1beta1/interface.go index 3bb78b150ef45..11f55faad9d04 100644 --- a/staging/src/k8s.io/client-go/informers/apps/v1beta1/interface.go +++ b/staging/src/k8s.io/client-go/informers/apps/v1beta1/interface.go @@ -24,6 +24,8 @@ import ( // Interface provides access to all the informers in this group version. type Interface interface { + // ControllerRevisions returns a ControllerRevisionInformer. + ControllerRevisions() ControllerRevisionInformer // Deployments returns a DeploymentInformer. Deployments() DeploymentInformer // StatefulSets returns a StatefulSetInformer. @@ -39,6 +41,11 @@ func New(f internalinterfaces.SharedInformerFactory) Interface { return &version{f} } +// ControllerRevisions returns a ControllerRevisionInformer. +func (v *version) ControllerRevisions() ControllerRevisionInformer { + return &controllerRevisionInformer{factory: v.SharedInformerFactory} +} + // Deployments returns a DeploymentInformer. func (v *version) Deployments() DeploymentInformer { return &deploymentInformer{factory: v.SharedInformerFactory} diff --git a/staging/src/k8s.io/client-go/informers/factory.go b/staging/src/k8s.io/client-go/informers/factory.go index 4116be71dd972..546158afd426e 100644 --- a/staging/src/k8s.io/client-go/informers/factory.go +++ b/staging/src/k8s.io/client-go/informers/factory.go @@ -21,6 +21,7 @@ package informers import ( runtime "k8s.io/apimachinery/pkg/runtime" schema "k8s.io/apimachinery/pkg/runtime/schema" + admissionregistration "k8s.io/client-go/informers/admissionregistration" apps "k8s.io/client-go/informers/apps" autoscaling "k8s.io/client-go/informers/autoscaling" batch "k8s.io/client-go/informers/batch" @@ -28,6 +29,7 @@ import ( core "k8s.io/client-go/informers/core" extensions "k8s.io/client-go/informers/extensions" internalinterfaces "k8s.io/client-go/informers/internalinterfaces" + networking "k8s.io/client-go/informers/networking" policy "k8s.io/client-go/informers/policy" rbac "k8s.io/client-go/informers/rbac" settings "k8s.io/client-go/informers/settings" @@ -119,18 +121,24 @@ type SharedInformerFactory interface { ForResource(resource schema.GroupVersionResource) (GenericInformer, error) WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool + Admissionregistration() admissionregistration.Interface Apps() apps.Interface Autoscaling() autoscaling.Interface Batch() batch.Interface Certificates() certificates.Interface Core() core.Interface Extensions() extensions.Interface + Networking() networking.Interface Policy() policy.Interface Rbac() rbac.Interface Settings() settings.Interface Storage() storage.Interface } +func (f *sharedInformerFactory) Admissionregistration() admissionregistration.Interface { + return admissionregistration.New(f) +} + func (f *sharedInformerFactory) Apps() apps.Interface { return apps.New(f) } @@ -155,6 +163,10 @@ func (f *sharedInformerFactory) Extensions() extensions.Interface { return extensions.New(f) } +func (f *sharedInformerFactory) Networking() networking.Interface { + return networking.New(f) +} + func (f *sharedInformerFactory) Policy() policy.Interface { return policy.New(f) } diff --git a/staging/src/k8s.io/client-go/informers/generic.go b/staging/src/k8s.io/client-go/informers/generic.go index f20c036adfc70..19b66a52bd745 100644 --- a/staging/src/k8s.io/client-go/informers/generic.go +++ b/staging/src/k8s.io/client-go/informers/generic.go @@ -22,6 +22,7 @@ import ( "fmt" schema "k8s.io/apimachinery/pkg/runtime/schema" api_v1 "k8s.io/client-go/pkg/api/v1" + v1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" v1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" v1 "k8s.io/client-go/pkg/apis/autoscaling/v1" v2alpha1 "k8s.io/client-go/pkg/apis/autoscaling/v2alpha1" @@ -29,8 +30,9 @@ import ( batch_v2alpha1 "k8s.io/client-go/pkg/apis/batch/v2alpha1" certificates_v1beta1 "k8s.io/client-go/pkg/apis/certificates/v1beta1" extensions_v1beta1 "k8s.io/client-go/pkg/apis/extensions/v1beta1" + networking_v1 "k8s.io/client-go/pkg/apis/networking/v1" policy_v1beta1 "k8s.io/client-go/pkg/apis/policy/v1beta1" - v1alpha1 "k8s.io/client-go/pkg/apis/rbac/v1alpha1" + rbac_v1alpha1 "k8s.io/client-go/pkg/apis/rbac/v1alpha1" rbac_v1beta1 "k8s.io/client-go/pkg/apis/rbac/v1beta1" settings_v1alpha1 "k8s.io/client-go/pkg/apis/settings/v1alpha1" storage_v1 "k8s.io/client-go/pkg/apis/storage/v1" @@ -64,7 +66,15 @@ func (f *genericInformer) Lister() cache.GenericLister { // TODO extend this to unknown resources with a client pool func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource) (GenericInformer, error) { switch resource { - // Group=Apps, Version=V1beta1 + // Group=Admissionregistration, Version=V1alpha1 + case v1alpha1.SchemeGroupVersion.WithResource("externaladmissionhookconfigurations"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Admissionregistration().V1alpha1().ExternalAdmissionHookConfigurations().Informer()}, nil + case v1alpha1.SchemeGroupVersion.WithResource("initializerconfigurations"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Admissionregistration().V1alpha1().InitializerConfigurations().Informer()}, nil + + // Group=Apps, Version=V1beta1 + case v1beta1.SchemeGroupVersion.WithResource("controllerrevisions"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Apps().V1beta1().ControllerRevisions().Informer()}, nil case v1beta1.SchemeGroupVersion.WithResource("deployments"): return &genericInformer{resource: resource.GroupResource(), informer: f.Apps().V1beta1().Deployments().Informer()}, nil case v1beta1.SchemeGroupVersion.WithResource("statefulsets"): @@ -138,18 +148,22 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource case extensions_v1beta1.SchemeGroupVersion.WithResource("thirdpartyresources"): return &genericInformer{resource: resource.GroupResource(), informer: f.Extensions().V1beta1().ThirdPartyResources().Informer()}, nil + // Group=Networking, Version=V1 + case networking_v1.SchemeGroupVersion.WithResource("networkpolicies"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Networking().V1().NetworkPolicies().Informer()}, nil + // Group=Policy, Version=V1beta1 case policy_v1beta1.SchemeGroupVersion.WithResource("poddisruptionbudgets"): return &genericInformer{resource: resource.GroupResource(), informer: f.Policy().V1beta1().PodDisruptionBudgets().Informer()}, nil // Group=Rbac, Version=V1alpha1 - case v1alpha1.SchemeGroupVersion.WithResource("clusterroles"): + case rbac_v1alpha1.SchemeGroupVersion.WithResource("clusterroles"): return &genericInformer{resource: resource.GroupResource(), informer: f.Rbac().V1alpha1().ClusterRoles().Informer()}, nil - case v1alpha1.SchemeGroupVersion.WithResource("clusterrolebindings"): + case rbac_v1alpha1.SchemeGroupVersion.WithResource("clusterrolebindings"): return &genericInformer{resource: resource.GroupResource(), informer: f.Rbac().V1alpha1().ClusterRoleBindings().Informer()}, nil - case v1alpha1.SchemeGroupVersion.WithResource("roles"): + case rbac_v1alpha1.SchemeGroupVersion.WithResource("roles"): return &genericInformer{resource: resource.GroupResource(), informer: f.Rbac().V1alpha1().Roles().Informer()}, nil - case v1alpha1.SchemeGroupVersion.WithResource("rolebindings"): + case rbac_v1alpha1.SchemeGroupVersion.WithResource("rolebindings"): return &genericInformer{resource: resource.GroupResource(), informer: f.Rbac().V1alpha1().RoleBindings().Informer()}, nil // Group=Rbac, Version=V1beta1 diff --git a/staging/src/k8s.io/client-go/informers/networking/BUILD b/staging/src/k8s.io/client-go/informers/networking/BUILD new file mode 100644 index 0000000000000..829a7228897fa --- /dev/null +++ b/staging/src/k8s.io/client-go/informers/networking/BUILD @@ -0,0 +1,18 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["interface.go"], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/client-go/informers/internalinterfaces:go_default_library", + "//vendor/k8s.io/client-go/informers/networking/v1:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/informers/networking/interface.go b/staging/src/k8s.io/client-go/informers/networking/interface.go new file mode 100644 index 0000000000000..a5df58b0418fa --- /dev/null +++ b/staging/src/k8s.io/client-go/informers/networking/interface.go @@ -0,0 +1,44 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package networking + +import ( + internalinterfaces "k8s.io/client-go/informers/internalinterfaces" + v1 "k8s.io/client-go/informers/networking/v1" +) + +// Interface provides access to each of this group's versions. +type Interface interface { + // V1 provides access to shared informers for resources in V1. + V1() v1.Interface +} + +type group struct { + internalinterfaces.SharedInformerFactory +} + +// New returns a new Interface. +func New(f internalinterfaces.SharedInformerFactory) Interface { + return &group{f} +} + +// V1 returns a new v1.Interface. +func (g *group) V1() v1.Interface { + return v1.New(g.SharedInformerFactory) +} diff --git a/staging/src/k8s.io/client-go/informers/networking/v1/BUILD b/staging/src/k8s.io/client-go/informers/networking/v1/BUILD new file mode 100644 index 0000000000000..43b6553e5c5f2 --- /dev/null +++ b/staging/src/k8s.io/client-go/informers/networking/v1/BUILD @@ -0,0 +1,27 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "interface.go", + "networkpolicy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/informers/internalinterfaces:go_default_library", + "//vendor/k8s.io/client-go/kubernetes:go_default_library", + "//vendor/k8s.io/client-go/listers/networking/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/networking/v1:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/informers/networking/v1/interface.go b/staging/src/k8s.io/client-go/informers/networking/v1/interface.go new file mode 100644 index 0000000000000..2ae314a5a51af --- /dev/null +++ b/staging/src/k8s.io/client-go/informers/networking/v1/interface.go @@ -0,0 +1,43 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package v1 + +import ( + internalinterfaces "k8s.io/client-go/informers/internalinterfaces" +) + +// Interface provides access to all the informers in this group version. +type Interface interface { + // NetworkPolicies returns a NetworkPolicyInformer. + NetworkPolicies() NetworkPolicyInformer +} + +type version struct { + internalinterfaces.SharedInformerFactory +} + +// New returns a new Interface. +func New(f internalinterfaces.SharedInformerFactory) Interface { + return &version{f} +} + +// NetworkPolicies returns a NetworkPolicyInformer. +func (v *version) NetworkPolicies() NetworkPolicyInformer { + return &networkPolicyInformer{factory: v.SharedInformerFactory} +} diff --git a/staging/src/k8s.io/client-go/informers/networking/v1/networkpolicy.go b/staging/src/k8s.io/client-go/informers/networking/v1/networkpolicy.go new file mode 100644 index 0000000000000..46475df8b43d1 --- /dev/null +++ b/staging/src/k8s.io/client-go/informers/networking/v1/networkpolicy.go @@ -0,0 +1,68 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by informer-gen + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + internalinterfaces "k8s.io/client-go/informers/internalinterfaces" + kubernetes "k8s.io/client-go/kubernetes" + v1 "k8s.io/client-go/listers/networking/v1" + networking_v1 "k8s.io/client-go/pkg/apis/networking/v1" + cache "k8s.io/client-go/tools/cache" + time "time" +) + +// NetworkPolicyInformer provides access to a shared informer and lister for +// NetworkPolicies. +type NetworkPolicyInformer interface { + Informer() cache.SharedIndexInformer + Lister() v1.NetworkPolicyLister +} + +type networkPolicyInformer struct { + factory internalinterfaces.SharedInformerFactory +} + +func newNetworkPolicyInformer(client kubernetes.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + sharedIndexInformer := cache.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options meta_v1.ListOptions) (runtime.Object, error) { + return client.NetworkingV1().NetworkPolicies(meta_v1.NamespaceAll).List(options) + }, + WatchFunc: func(options meta_v1.ListOptions) (watch.Interface, error) { + return client.NetworkingV1().NetworkPolicies(meta_v1.NamespaceAll).Watch(options) + }, + }, + &networking_v1.NetworkPolicy{}, + resyncPeriod, + cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, + ) + + return sharedIndexInformer +} + +func (f *networkPolicyInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&networking_v1.NetworkPolicy{}, newNetworkPolicyInformer) +} + +func (f *networkPolicyInformer) Lister() v1.NetworkPolicyLister { + return v1.NewNetworkPolicyLister(f.Informer().GetIndexer()) +} diff --git a/staging/src/k8s.io/client-go/kubernetes/BUILD b/staging/src/k8s.io/client-go/kubernetes/BUILD index 26e43863d57b3..089edd660fbaf 100644 --- a/staging/src/k8s.io/client-go/kubernetes/BUILD +++ b/staging/src/k8s.io/client-go/kubernetes/BUILD @@ -17,6 +17,7 @@ go_library( deps = [ "//vendor/github.com/golang/glog:go_default_library", "//vendor/k8s.io/client-go/discovery:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/authentication/v1:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1:go_default_library", @@ -29,6 +30,7 @@ go_library( "//vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/core/v1:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/networking/v1:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1:go_default_library", diff --git a/staging/src/k8s.io/client-go/kubernetes/clientset.go b/staging/src/k8s.io/client-go/kubernetes/clientset.go index 5fd0c54e8f578..8a05da50d1a17 100644 --- a/staging/src/k8s.io/client-go/kubernetes/clientset.go +++ b/staging/src/k8s.io/client-go/kubernetes/clientset.go @@ -19,6 +19,7 @@ package kubernetes import ( glog "github.com/golang/glog" discovery "k8s.io/client-go/discovery" + admissionregistrationv1alpha1 "k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1" appsv1beta1 "k8s.io/client-go/kubernetes/typed/apps/v1beta1" authenticationv1 "k8s.io/client-go/kubernetes/typed/authentication/v1" authenticationv1beta1 "k8s.io/client-go/kubernetes/typed/authentication/v1beta1" @@ -31,6 +32,7 @@ import ( certificatesv1beta1 "k8s.io/client-go/kubernetes/typed/certificates/v1beta1" corev1 "k8s.io/client-go/kubernetes/typed/core/v1" extensionsv1beta1 "k8s.io/client-go/kubernetes/typed/extensions/v1beta1" + networkingv1 "k8s.io/client-go/kubernetes/typed/networking/v1" policyv1beta1 "k8s.io/client-go/kubernetes/typed/policy/v1beta1" rbacv1alpha1 "k8s.io/client-go/kubernetes/typed/rbac/v1alpha1" rbacv1beta1 "k8s.io/client-go/kubernetes/typed/rbac/v1beta1" @@ -43,6 +45,9 @@ import ( type Interface interface { Discovery() discovery.DiscoveryInterface + AdmissionregistrationV1alpha1() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface + // Deprecated: please explicitly pick a version if possible. + Admissionregistration() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface CoreV1() corev1.CoreV1Interface // Deprecated: please explicitly pick a version if possible. Core() corev1.CoreV1Interface @@ -71,6 +76,9 @@ type Interface interface { ExtensionsV1beta1() extensionsv1beta1.ExtensionsV1beta1Interface // Deprecated: please explicitly pick a version if possible. Extensions() extensionsv1beta1.ExtensionsV1beta1Interface + NetworkingV1() networkingv1.NetworkingV1Interface + // Deprecated: please explicitly pick a version if possible. + Networking() networkingv1.NetworkingV1Interface PolicyV1beta1() policyv1beta1.PolicyV1beta1Interface // Deprecated: please explicitly pick a version if possible. Policy() policyv1beta1.PolicyV1beta1Interface @@ -91,6 +99,7 @@ type Interface interface { // version included in a Clientset. type Clientset struct { *discovery.DiscoveryClient + *admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Client *corev1.CoreV1Client *appsv1beta1.AppsV1beta1Client *authenticationv1.AuthenticationV1Client @@ -103,6 +112,7 @@ type Clientset struct { *batchv2alpha1.BatchV2alpha1Client *certificatesv1beta1.CertificatesV1beta1Client *extensionsv1beta1.ExtensionsV1beta1Client + *networkingv1.NetworkingV1Client *policyv1beta1.PolicyV1beta1Client *rbacv1beta1.RbacV1beta1Client *rbacv1alpha1.RbacV1alpha1Client @@ -111,6 +121,23 @@ type Clientset struct { *storagev1.StorageV1Client } +// AdmissionregistrationV1alpha1 retrieves the AdmissionregistrationV1alpha1Client +func (c *Clientset) AdmissionregistrationV1alpha1() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface { + if c == nil { + return nil + } + return c.AdmissionregistrationV1alpha1Client +} + +// Deprecated: Admissionregistration retrieves the default version of AdmissionregistrationClient. +// Please explicitly pick a version. +func (c *Clientset) Admissionregistration() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface { + if c == nil { + return nil + } + return c.AdmissionregistrationV1alpha1Client +} + // CoreV1 retrieves the CoreV1Client func (c *Clientset) CoreV1() corev1.CoreV1Interface { if c == nil { @@ -279,6 +306,23 @@ func (c *Clientset) Extensions() extensionsv1beta1.ExtensionsV1beta1Interface { return c.ExtensionsV1beta1Client } +// NetworkingV1 retrieves the NetworkingV1Client +func (c *Clientset) NetworkingV1() networkingv1.NetworkingV1Interface { + if c == nil { + return nil + } + return c.NetworkingV1Client +} + +// Deprecated: Networking retrieves the default version of NetworkingClient. +// Please explicitly pick a version. +func (c *Clientset) Networking() networkingv1.NetworkingV1Interface { + if c == nil { + return nil + } + return c.NetworkingV1Client +} + // PolicyV1beta1 retrieves the PolicyV1beta1Client func (c *Clientset) PolicyV1beta1() policyv1beta1.PolicyV1beta1Interface { if c == nil { @@ -379,6 +423,10 @@ func NewForConfig(c *rest.Config) (*Clientset, error) { } var cs Clientset var err error + cs.AdmissionregistrationV1alpha1Client, err = admissionregistrationv1alpha1.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } cs.CoreV1Client, err = corev1.NewForConfig(&configShallowCopy) if err != nil { return nil, err @@ -427,6 +475,10 @@ func NewForConfig(c *rest.Config) (*Clientset, error) { if err != nil { return nil, err } + cs.NetworkingV1Client, err = networkingv1.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } cs.PolicyV1beta1Client, err = policyv1beta1.NewForConfig(&configShallowCopy) if err != nil { return nil, err @@ -464,6 +516,7 @@ func NewForConfig(c *rest.Config) (*Clientset, error) { // panics if there is an error in the config. func NewForConfigOrDie(c *rest.Config) *Clientset { var cs Clientset + cs.AdmissionregistrationV1alpha1Client = admissionregistrationv1alpha1.NewForConfigOrDie(c) cs.CoreV1Client = corev1.NewForConfigOrDie(c) cs.AppsV1beta1Client = appsv1beta1.NewForConfigOrDie(c) cs.AuthenticationV1Client = authenticationv1.NewForConfigOrDie(c) @@ -476,6 +529,7 @@ func NewForConfigOrDie(c *rest.Config) *Clientset { cs.BatchV2alpha1Client = batchv2alpha1.NewForConfigOrDie(c) cs.CertificatesV1beta1Client = certificatesv1beta1.NewForConfigOrDie(c) cs.ExtensionsV1beta1Client = extensionsv1beta1.NewForConfigOrDie(c) + cs.NetworkingV1Client = networkingv1.NewForConfigOrDie(c) cs.PolicyV1beta1Client = policyv1beta1.NewForConfigOrDie(c) cs.RbacV1beta1Client = rbacv1beta1.NewForConfigOrDie(c) cs.RbacV1alpha1Client = rbacv1alpha1.NewForConfigOrDie(c) @@ -490,6 +544,7 @@ func NewForConfigOrDie(c *rest.Config) *Clientset { // New creates a new Clientset for the given RESTClient. func New(c rest.Interface) *Clientset { var cs Clientset + cs.AdmissionregistrationV1alpha1Client = admissionregistrationv1alpha1.New(c) cs.CoreV1Client = corev1.New(c) cs.AppsV1beta1Client = appsv1beta1.New(c) cs.AuthenticationV1Client = authenticationv1.New(c) @@ -502,6 +557,7 @@ func New(c rest.Interface) *Clientset { cs.BatchV2alpha1Client = batchv2alpha1.New(c) cs.CertificatesV1beta1Client = certificatesv1beta1.New(c) cs.ExtensionsV1beta1Client = extensionsv1beta1.New(c) + cs.NetworkingV1Client = networkingv1.New(c) cs.PolicyV1beta1Client = policyv1beta1.New(c) cs.RbacV1beta1Client = rbacv1beta1.New(c) cs.RbacV1alpha1Client = rbacv1alpha1.New(c) diff --git a/staging/src/k8s.io/client-go/kubernetes/fake/BUILD b/staging/src/k8s.io/client-go/kubernetes/fake/BUILD index 2d69e4a784908..9954286f76f09 100644 --- a/staging/src/k8s.io/client-go/kubernetes/fake/BUILD +++ b/staging/src/k8s.io/client-go/kubernetes/fake/BUILD @@ -24,6 +24,8 @@ go_library( "//vendor/k8s.io/client-go/discovery:go_default_library", "//vendor/k8s.io/client-go/discovery/fake:go_default_library", "//vendor/k8s.io/client-go/kubernetes:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/fake:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/authentication/v1:go_default_library", @@ -48,6 +50,8 @@ go_library( "//vendor/k8s.io/client-go/kubernetes/typed/core/v1/fake:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/fake:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/networking/v1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/networking/v1/fake:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/fake:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1:go_default_library", @@ -61,6 +65,7 @@ go_library( "//vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1:go_default_library", "//vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/fake:go_default_library", "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/apps/v1beta1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/authentication/v1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1:go_default_library", @@ -72,6 +77,7 @@ go_library( "//vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/networking/v1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/policy/v1beta1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1:go_default_library", diff --git a/staging/src/k8s.io/client-go/kubernetes/fake/clientset_generated.go b/staging/src/k8s.io/client-go/kubernetes/fake/clientset_generated.go index cd5254d05e949..38303e3ed42d5 100644 --- a/staging/src/k8s.io/client-go/kubernetes/fake/clientset_generated.go +++ b/staging/src/k8s.io/client-go/kubernetes/fake/clientset_generated.go @@ -22,6 +22,8 @@ import ( "k8s.io/client-go/discovery" fakediscovery "k8s.io/client-go/discovery/fake" kubernetes "k8s.io/client-go/kubernetes" + admissionregistrationv1alpha1 "k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1" + fakeadmissionregistrationv1alpha1 "k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake" appsv1beta1 "k8s.io/client-go/kubernetes/typed/apps/v1beta1" fakeappsv1beta1 "k8s.io/client-go/kubernetes/typed/apps/v1beta1/fake" authenticationv1 "k8s.io/client-go/kubernetes/typed/authentication/v1" @@ -46,6 +48,8 @@ import ( fakecorev1 "k8s.io/client-go/kubernetes/typed/core/v1/fake" extensionsv1beta1 "k8s.io/client-go/kubernetes/typed/extensions/v1beta1" fakeextensionsv1beta1 "k8s.io/client-go/kubernetes/typed/extensions/v1beta1/fake" + networkingv1 "k8s.io/client-go/kubernetes/typed/networking/v1" + fakenetworkingv1 "k8s.io/client-go/kubernetes/typed/networking/v1/fake" policyv1beta1 "k8s.io/client-go/kubernetes/typed/policy/v1beta1" fakepolicyv1beta1 "k8s.io/client-go/kubernetes/typed/policy/v1beta1/fake" rbacv1alpha1 "k8s.io/client-go/kubernetes/typed/rbac/v1alpha1" @@ -94,6 +98,16 @@ func (c *Clientset) Discovery() discovery.DiscoveryInterface { var _ kubernetes.Interface = &Clientset{} +// AdmissionregistrationV1alpha1 retrieves the AdmissionregistrationV1alpha1Client +func (c *Clientset) AdmissionregistrationV1alpha1() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface { + return &fakeadmissionregistrationv1alpha1.FakeAdmissionregistrationV1alpha1{Fake: &c.Fake} +} + +// Admissionregistration retrieves the AdmissionregistrationV1alpha1Client +func (c *Clientset) Admissionregistration() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface { + return &fakeadmissionregistrationv1alpha1.FakeAdmissionregistrationV1alpha1{Fake: &c.Fake} +} + // CoreV1 retrieves the CoreV1Client func (c *Clientset) CoreV1() corev1.CoreV1Interface { return &fakecorev1.FakeCoreV1{Fake: &c.Fake} @@ -194,6 +208,16 @@ func (c *Clientset) Extensions() extensionsv1beta1.ExtensionsV1beta1Interface { return &fakeextensionsv1beta1.FakeExtensionsV1beta1{Fake: &c.Fake} } +// NetworkingV1 retrieves the NetworkingV1Client +func (c *Clientset) NetworkingV1() networkingv1.NetworkingV1Interface { + return &fakenetworkingv1.FakeNetworkingV1{Fake: &c.Fake} +} + +// Networking retrieves the NetworkingV1Client +func (c *Clientset) Networking() networkingv1.NetworkingV1Interface { + return &fakenetworkingv1.FakeNetworkingV1{Fake: &c.Fake} +} + // PolicyV1beta1 retrieves the PolicyV1beta1Client func (c *Clientset) PolicyV1beta1() policyv1beta1.PolicyV1beta1Interface { return &fakepolicyv1beta1.FakePolicyV1beta1{Fake: &c.Fake} diff --git a/staging/src/k8s.io/client-go/kubernetes/fake/register.go b/staging/src/k8s.io/client-go/kubernetes/fake/register.go index ee162ba5f01ff..2b3e1667e6c25 100644 --- a/staging/src/k8s.io/client-go/kubernetes/fake/register.go +++ b/staging/src/k8s.io/client-go/kubernetes/fake/register.go @@ -22,6 +22,7 @@ import ( schema "k8s.io/apimachinery/pkg/runtime/schema" serializer "k8s.io/apimachinery/pkg/runtime/serializer" corev1 "k8s.io/client-go/pkg/api/v1" + admissionregistrationv1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" appsv1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" authenticationv1 "k8s.io/client-go/pkg/apis/authentication/v1" authenticationv1beta1 "k8s.io/client-go/pkg/apis/authentication/v1beta1" @@ -33,6 +34,7 @@ import ( batchv2alpha1 "k8s.io/client-go/pkg/apis/batch/v2alpha1" certificatesv1beta1 "k8s.io/client-go/pkg/apis/certificates/v1beta1" extensionsv1beta1 "k8s.io/client-go/pkg/apis/extensions/v1beta1" + networkingv1 "k8s.io/client-go/pkg/apis/networking/v1" policyv1beta1 "k8s.io/client-go/pkg/apis/policy/v1beta1" rbacv1alpha1 "k8s.io/client-go/pkg/apis/rbac/v1alpha1" rbacv1beta1 "k8s.io/client-go/pkg/apis/rbac/v1beta1" @@ -65,6 +67,7 @@ func init() { // After this, RawExtensions in Kubernetes types will serialize kube-aggregator types // correctly. func AddToScheme(scheme *runtime.Scheme) { + admissionregistrationv1alpha1.AddToScheme(scheme) corev1.AddToScheme(scheme) appsv1beta1.AddToScheme(scheme) authenticationv1.AddToScheme(scheme) @@ -77,6 +80,7 @@ func AddToScheme(scheme *runtime.Scheme) { batchv2alpha1.AddToScheme(scheme) certificatesv1beta1.AddToScheme(scheme) extensionsv1beta1.AddToScheme(scheme) + networkingv1.AddToScheme(scheme) policyv1beta1.AddToScheme(scheme) rbacv1beta1.AddToScheme(scheme) rbacv1alpha1.AddToScheme(scheme) diff --git a/staging/src/k8s.io/client-go/kubernetes/scheme/BUILD b/staging/src/k8s.io/client-go/kubernetes/scheme/BUILD index 875dd60cc5e15..93447ef0754a2 100644 --- a/staging/src/k8s.io/client-go/kubernetes/scheme/BUILD +++ b/staging/src/k8s.io/client-go/kubernetes/scheme/BUILD @@ -20,6 +20,7 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/apps/v1beta1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/authentication/v1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1:go_default_library", @@ -31,6 +32,7 @@ go_library( "//vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/networking/v1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/policy/v1beta1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1:go_default_library", diff --git a/staging/src/k8s.io/client-go/kubernetes/scheme/register.go b/staging/src/k8s.io/client-go/kubernetes/scheme/register.go index 1fe5dbe4cee7e..c4af63a465f2c 100644 --- a/staging/src/k8s.io/client-go/kubernetes/scheme/register.go +++ b/staging/src/k8s.io/client-go/kubernetes/scheme/register.go @@ -22,6 +22,7 @@ import ( schema "k8s.io/apimachinery/pkg/runtime/schema" serializer "k8s.io/apimachinery/pkg/runtime/serializer" corev1 "k8s.io/client-go/pkg/api/v1" + admissionregistrationv1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" appsv1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" authenticationv1 "k8s.io/client-go/pkg/apis/authentication/v1" authenticationv1beta1 "k8s.io/client-go/pkg/apis/authentication/v1beta1" @@ -33,6 +34,7 @@ import ( batchv2alpha1 "k8s.io/client-go/pkg/apis/batch/v2alpha1" certificatesv1beta1 "k8s.io/client-go/pkg/apis/certificates/v1beta1" extensionsv1beta1 "k8s.io/client-go/pkg/apis/extensions/v1beta1" + networkingv1 "k8s.io/client-go/pkg/apis/networking/v1" policyv1beta1 "k8s.io/client-go/pkg/apis/policy/v1beta1" rbacv1alpha1 "k8s.io/client-go/pkg/apis/rbac/v1alpha1" rbacv1beta1 "k8s.io/client-go/pkg/apis/rbac/v1beta1" @@ -65,6 +67,7 @@ func init() { // After this, RawExtensions in Kubernetes types will serialize kube-aggregator types // correctly. func AddToScheme(scheme *runtime.Scheme) { + admissionregistrationv1alpha1.AddToScheme(scheme) corev1.AddToScheme(scheme) appsv1beta1.AddToScheme(scheme) authenticationv1.AddToScheme(scheme) @@ -77,6 +80,7 @@ func AddToScheme(scheme *runtime.Scheme) { batchv2alpha1.AddToScheme(scheme) certificatesv1beta1.AddToScheme(scheme) extensionsv1beta1.AddToScheme(scheme) + networkingv1.AddToScheme(scheme) policyv1beta1.AddToScheme(scheme) rbacv1beta1.AddToScheme(scheme) rbacv1alpha1.AddToScheme(scheme) diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/BUILD b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/BUILD new file mode 100644 index 0000000000000..e51dda3dfbe80 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/BUILD @@ -0,0 +1,29 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "admissionregistration_client.go", + "doc.go", + "externaladmissionhookconfiguration.go", + "generated_expansion.go", + "initializerconfiguration.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/admissionregistration_client.go b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/admissionregistration_client.go new file mode 100644 index 0000000000000..c1d11b69b6337 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/admissionregistration_client.go @@ -0,0 +1,93 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +import ( + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" + rest "k8s.io/client-go/rest" +) + +type AdmissionregistrationV1alpha1Interface interface { + RESTClient() rest.Interface + ExternalAdmissionHookConfigurationsGetter + InitializerConfigurationsGetter +} + +// AdmissionregistrationV1alpha1Client is used to interact with features provided by the admissionregistration.k8s.io group. +type AdmissionregistrationV1alpha1Client struct { + restClient rest.Interface +} + +func (c *AdmissionregistrationV1alpha1Client) ExternalAdmissionHookConfigurations(namespace string) ExternalAdmissionHookConfigurationInterface { + return newExternalAdmissionHookConfigurations(c, namespace) +} + +func (c *AdmissionregistrationV1alpha1Client) InitializerConfigurations(namespace string) InitializerConfigurationInterface { + return newInitializerConfigurations(c, namespace) +} + +// NewForConfig creates a new AdmissionregistrationV1alpha1Client for the given config. +func NewForConfig(c *rest.Config) (*AdmissionregistrationV1alpha1Client, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &AdmissionregistrationV1alpha1Client{client}, nil +} + +// NewForConfigOrDie creates a new AdmissionregistrationV1alpha1Client for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *AdmissionregistrationV1alpha1Client { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new AdmissionregistrationV1alpha1Client for the given RESTClient. +func New(c rest.Interface) *AdmissionregistrationV1alpha1Client { + return &AdmissionregistrationV1alpha1Client{c} +} + +func setConfigDefaults(config *rest.Config) error { + gv := v1alpha1.SchemeGroupVersion + config.GroupVersion = &gv + config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *AdmissionregistrationV1alpha1Client) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/doc.go b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/doc.go new file mode 100644 index 0000000000000..ba8d10d3b6664 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package has the automatically generated typed clients. +package v1alpha1 diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go new file mode 100644 index 0000000000000..277802c2ad66a --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" + rest "k8s.io/client-go/rest" +) + +// ExternalAdmissionHookConfigurationsGetter has a method to return a ExternalAdmissionHookConfigurationInterface. +// A group's client should implement this interface. +type ExternalAdmissionHookConfigurationsGetter interface { + ExternalAdmissionHookConfigurations(namespace string) ExternalAdmissionHookConfigurationInterface +} + +// ExternalAdmissionHookConfigurationInterface has methods to work with ExternalAdmissionHookConfiguration resources. +type ExternalAdmissionHookConfigurationInterface interface { + Create(*v1alpha1.ExternalAdmissionHookConfiguration) (*v1alpha1.ExternalAdmissionHookConfiguration, error) + Update(*v1alpha1.ExternalAdmissionHookConfiguration) (*v1alpha1.ExternalAdmissionHookConfiguration, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1alpha1.ExternalAdmissionHookConfiguration, error) + List(opts v1.ListOptions) (*v1alpha1.ExternalAdmissionHookConfigurationList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) + ExternalAdmissionHookConfigurationExpansion +} + +// externalAdmissionHookConfigurations implements ExternalAdmissionHookConfigurationInterface +type externalAdmissionHookConfigurations struct { + client rest.Interface + ns string +} + +// newExternalAdmissionHookConfigurations returns a ExternalAdmissionHookConfigurations +func newExternalAdmissionHookConfigurations(c *AdmissionregistrationV1alpha1Client, namespace string) *externalAdmissionHookConfigurations { + return &externalAdmissionHookConfigurations{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a externalAdmissionHookConfiguration and creates it. Returns the server's representation of the externalAdmissionHookConfiguration, and an error, if there is any. +func (c *externalAdmissionHookConfigurations) Create(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + result = &v1alpha1.ExternalAdmissionHookConfiguration{} + err = c.client.Post(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + Body(externalAdmissionHookConfiguration). + Do(). + Into(result) + return +} + +// Update takes the representation of a externalAdmissionHookConfiguration and updates it. Returns the server's representation of the externalAdmissionHookConfiguration, and an error, if there is any. +func (c *externalAdmissionHookConfigurations) Update(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + result = &v1alpha1.ExternalAdmissionHookConfiguration{} + err = c.client.Put(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + Name(externalAdmissionHookConfiguration.Name). + Body(externalAdmissionHookConfiguration). + Do(). + Into(result) + return +} + +// Delete takes name of the externalAdmissionHookConfiguration and deletes it. Returns an error if one occurs. +func (c *externalAdmissionHookConfigurations) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *externalAdmissionHookConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the externalAdmissionHookConfiguration, and returns the corresponding externalAdmissionHookConfiguration object, and an error if there is any. +func (c *externalAdmissionHookConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + result = &v1alpha1.ExternalAdmissionHookConfiguration{} + err = c.client.Get(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of ExternalAdmissionHookConfigurations that match those selectors. +func (c *externalAdmissionHookConfigurations) List(opts v1.ListOptions) (result *v1alpha1.ExternalAdmissionHookConfigurationList, err error) { + result = &v1alpha1.ExternalAdmissionHookConfigurationList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested externalAdmissionHookConfigurations. +func (c *externalAdmissionHookConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched externalAdmissionHookConfiguration. +func (c *externalAdmissionHookConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + result = &v1alpha1.ExternalAdmissionHookConfiguration{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("externaladmissionhookconfigurations"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/BUILD b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/BUILD new file mode 100644 index 0000000000000..5bb4d724b1b36 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/BUILD @@ -0,0 +1,30 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "fake_admissionregistration_client.go", + "fake_externaladmissionhookconfiguration.go", + "fake_initializerconfiguration.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + "//vendor/k8s.io/client-go/testing:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/doc.go b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/doc.go new file mode 100644 index 0000000000000..c6548330a0d0a --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This package is generated by client-gen with custom arguments. + +// Package fake has the automatically generated clients. +package fake diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/fake_admissionregistration_client.go b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/fake_admissionregistration_client.go new file mode 100644 index 0000000000000..f6460bb61d876 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/fake_admissionregistration_client.go @@ -0,0 +1,42 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + v1alpha1 "k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1" + rest "k8s.io/client-go/rest" + testing "k8s.io/client-go/testing" +) + +type FakeAdmissionregistrationV1alpha1 struct { + *testing.Fake +} + +func (c *FakeAdmissionregistrationV1alpha1) ExternalAdmissionHookConfigurations(namespace string) v1alpha1.ExternalAdmissionHookConfigurationInterface { + return &FakeExternalAdmissionHookConfigurations{c, namespace} +} + +func (c *FakeAdmissionregistrationV1alpha1) InitializerConfigurations(namespace string) v1alpha1.InitializerConfigurationInterface { + return &FakeInitializerConfigurations{c, namespace} +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *FakeAdmissionregistrationV1alpha1) RESTClient() rest.Interface { + var ret *rest.RESTClient + return ret +} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/fake_externaladmissionhookconfiguration.go b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/fake_externaladmissionhookconfiguration.go new file mode 100644 index 0000000000000..268ebadf19e51 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/fake_externaladmissionhookconfiguration.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + labels "k8s.io/apimachinery/pkg/labels" + schema "k8s.io/apimachinery/pkg/runtime/schema" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + v1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" + testing "k8s.io/client-go/testing" +) + +// FakeExternalAdmissionHookConfigurations implements ExternalAdmissionHookConfigurationInterface +type FakeExternalAdmissionHookConfigurations struct { + Fake *FakeAdmissionregistrationV1alpha1 + ns string +} + +var externaladmissionhookconfigurationsResource = schema.GroupVersionResource{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Resource: "externaladmissionhookconfigurations"} + +var externaladmissionhookconfigurationsKind = schema.GroupVersionKind{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Kind: "ExternalAdmissionHookConfiguration"} + +func (c *FakeExternalAdmissionHookConfigurations) Create(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewCreateAction(externaladmissionhookconfigurationsResource, c.ns, externalAdmissionHookConfiguration), &v1alpha1.ExternalAdmissionHookConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), err +} + +func (c *FakeExternalAdmissionHookConfigurations) Update(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewUpdateAction(externaladmissionhookconfigurationsResource, c.ns, externalAdmissionHookConfiguration), &v1alpha1.ExternalAdmissionHookConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), err +} + +func (c *FakeExternalAdmissionHookConfigurations) Delete(name string, options *v1.DeleteOptions) error { + _, err := c.Fake. + Invokes(testing.NewDeleteAction(externaladmissionhookconfigurationsResource, c.ns, name), &v1alpha1.ExternalAdmissionHookConfiguration{}) + + return err +} + +func (c *FakeExternalAdmissionHookConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + action := testing.NewDeleteCollectionAction(externaladmissionhookconfigurationsResource, c.ns, listOptions) + + _, err := c.Fake.Invokes(action, &v1alpha1.ExternalAdmissionHookConfigurationList{}) + return err +} + +func (c *FakeExternalAdmissionHookConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewGetAction(externaladmissionhookconfigurationsResource, c.ns, name), &v1alpha1.ExternalAdmissionHookConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), err +} + +func (c *FakeExternalAdmissionHookConfigurations) List(opts v1.ListOptions) (result *v1alpha1.ExternalAdmissionHookConfigurationList, err error) { + obj, err := c.Fake. + Invokes(testing.NewListAction(externaladmissionhookconfigurationsResource, externaladmissionhookconfigurationsKind, c.ns, opts), &v1alpha1.ExternalAdmissionHookConfigurationList{}) + + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &v1alpha1.ExternalAdmissionHookConfigurationList{} + for _, item := range obj.(*v1alpha1.ExternalAdmissionHookConfigurationList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested externalAdmissionHookConfigurations. +func (c *FakeExternalAdmissionHookConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + return c.Fake. + InvokesWatch(testing.NewWatchAction(externaladmissionhookconfigurationsResource, c.ns, opts)) + +} + +// Patch applies the patch and returns the patched externalAdmissionHookConfiguration. +func (c *FakeExternalAdmissionHookConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewPatchSubresourceAction(externaladmissionhookconfigurationsResource, c.ns, name, data, subresources...), &v1alpha1.ExternalAdmissionHookConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), err +} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/fake_initializerconfiguration.go b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/fake_initializerconfiguration.go new file mode 100644 index 0000000000000..b86a1f3412001 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/fake/fake_initializerconfiguration.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + labels "k8s.io/apimachinery/pkg/labels" + schema "k8s.io/apimachinery/pkg/runtime/schema" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + v1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" + testing "k8s.io/client-go/testing" +) + +// FakeInitializerConfigurations implements InitializerConfigurationInterface +type FakeInitializerConfigurations struct { + Fake *FakeAdmissionregistrationV1alpha1 + ns string +} + +var initializerconfigurationsResource = schema.GroupVersionResource{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Resource: "initializerconfigurations"} + +var initializerconfigurationsKind = schema.GroupVersionKind{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Kind: "InitializerConfiguration"} + +func (c *FakeInitializerConfigurations) Create(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewCreateAction(initializerconfigurationsResource, c.ns, initializerConfiguration), &v1alpha1.InitializerConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.InitializerConfiguration), err +} + +func (c *FakeInitializerConfigurations) Update(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewUpdateAction(initializerconfigurationsResource, c.ns, initializerConfiguration), &v1alpha1.InitializerConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.InitializerConfiguration), err +} + +func (c *FakeInitializerConfigurations) Delete(name string, options *v1.DeleteOptions) error { + _, err := c.Fake. + Invokes(testing.NewDeleteAction(initializerconfigurationsResource, c.ns, name), &v1alpha1.InitializerConfiguration{}) + + return err +} + +func (c *FakeInitializerConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + action := testing.NewDeleteCollectionAction(initializerconfigurationsResource, c.ns, listOptions) + + _, err := c.Fake.Invokes(action, &v1alpha1.InitializerConfigurationList{}) + return err +} + +func (c *FakeInitializerConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.InitializerConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewGetAction(initializerconfigurationsResource, c.ns, name), &v1alpha1.InitializerConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.InitializerConfiguration), err +} + +func (c *FakeInitializerConfigurations) List(opts v1.ListOptions) (result *v1alpha1.InitializerConfigurationList, err error) { + obj, err := c.Fake. + Invokes(testing.NewListAction(initializerconfigurationsResource, initializerconfigurationsKind, c.ns, opts), &v1alpha1.InitializerConfigurationList{}) + + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &v1alpha1.InitializerConfigurationList{} + for _, item := range obj.(*v1alpha1.InitializerConfigurationList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested initializerConfigurations. +func (c *FakeInitializerConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + return c.Fake. + InvokesWatch(testing.NewWatchAction(initializerconfigurationsResource, c.ns, opts)) + +} + +// Patch applies the patch and returns the patched initializerConfiguration. +func (c *FakeInitializerConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.InitializerConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewPatchSubresourceAction(initializerconfigurationsResource, c.ns, name, data, subresources...), &v1alpha1.InitializerConfiguration{}) + + if obj == nil { + return nil, err + } + return obj.(*v1alpha1.InitializerConfiguration), err +} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/generated_expansion.go b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/generated_expansion.go new file mode 100644 index 0000000000000..eef439ab4725a --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/generated_expansion.go @@ -0,0 +1,21 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +type ExternalAdmissionHookConfigurationExpansion interface{} + +type InitializerConfigurationExpansion interface{} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/initializerconfiguration.go b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/initializerconfiguration.go new file mode 100644 index 0000000000000..d8b75600c3a12 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/initializerconfiguration.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" + rest "k8s.io/client-go/rest" +) + +// InitializerConfigurationsGetter has a method to return a InitializerConfigurationInterface. +// A group's client should implement this interface. +type InitializerConfigurationsGetter interface { + InitializerConfigurations(namespace string) InitializerConfigurationInterface +} + +// InitializerConfigurationInterface has methods to work with InitializerConfiguration resources. +type InitializerConfigurationInterface interface { + Create(*v1alpha1.InitializerConfiguration) (*v1alpha1.InitializerConfiguration, error) + Update(*v1alpha1.InitializerConfiguration) (*v1alpha1.InitializerConfiguration, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1alpha1.InitializerConfiguration, error) + List(opts v1.ListOptions) (*v1alpha1.InitializerConfigurationList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.InitializerConfiguration, err error) + InitializerConfigurationExpansion +} + +// initializerConfigurations implements InitializerConfigurationInterface +type initializerConfigurations struct { + client rest.Interface + ns string +} + +// newInitializerConfigurations returns a InitializerConfigurations +func newInitializerConfigurations(c *AdmissionregistrationV1alpha1Client, namespace string) *initializerConfigurations { + return &initializerConfigurations{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a initializerConfiguration and creates it. Returns the server's representation of the initializerConfiguration, and an error, if there is any. +func (c *initializerConfigurations) Create(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) { + result = &v1alpha1.InitializerConfiguration{} + err = c.client.Post(). + Namespace(c.ns). + Resource("initializerconfigurations"). + Body(initializerConfiguration). + Do(). + Into(result) + return +} + +// Update takes the representation of a initializerConfiguration and updates it. Returns the server's representation of the initializerConfiguration, and an error, if there is any. +func (c *initializerConfigurations) Update(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) { + result = &v1alpha1.InitializerConfiguration{} + err = c.client.Put(). + Namespace(c.ns). + Resource("initializerconfigurations"). + Name(initializerConfiguration.Name). + Body(initializerConfiguration). + Do(). + Into(result) + return +} + +// Delete takes name of the initializerConfiguration and deletes it. Returns an error if one occurs. +func (c *initializerConfigurations) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("initializerconfigurations"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *initializerConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("initializerconfigurations"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the initializerConfiguration, and returns the corresponding initializerConfiguration object, and an error if there is any. +func (c *initializerConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.InitializerConfiguration, err error) { + result = &v1alpha1.InitializerConfiguration{} + err = c.client.Get(). + Namespace(c.ns). + Resource("initializerconfigurations"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of InitializerConfigurations that match those selectors. +func (c *initializerConfigurations) List(opts v1.ListOptions) (result *v1alpha1.InitializerConfigurationList, err error) { + result = &v1alpha1.InitializerConfigurationList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("initializerconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested initializerConfigurations. +func (c *initializerConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("initializerconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched initializerConfiguration. +func (c *initializerConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.InitializerConfiguration, err error) { + result = &v1alpha1.InitializerConfiguration{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("initializerconfigurations"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/BUILD b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/BUILD index c6ef2d6eb2aac..ba6ffd4217f63 100644 --- a/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/BUILD +++ b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/BUILD @@ -11,6 +11,7 @@ go_library( name = "go_default_library", srcs = [ "apps_client.go", + "controllerrevision.go", "deployment.go", "doc.go", "generated_expansion.go", diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/apps_client.go b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/apps_client.go index a520f87fce9dc..c18da39f6d25f 100644 --- a/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/apps_client.go +++ b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/apps_client.go @@ -25,6 +25,7 @@ import ( type AppsV1beta1Interface interface { RESTClient() rest.Interface + ControllerRevisionsGetter DeploymentsGetter ScalesGetter StatefulSetsGetter @@ -35,6 +36,10 @@ type AppsV1beta1Client struct { restClient rest.Interface } +func (c *AppsV1beta1Client) ControllerRevisions(namespace string) ControllerRevisionInterface { + return newControllerRevisions(c, namespace) +} + func (c *AppsV1beta1Client) Deployments(namespace string) DeploymentInterface { return newDeployments(c, namespace) } diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/controllerrevision.go b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/controllerrevision.go new file mode 100644 index 0000000000000..de24bbb582450 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/controllerrevision.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1beta1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" + rest "k8s.io/client-go/rest" +) + +// ControllerRevisionsGetter has a method to return a ControllerRevisionInterface. +// A group's client should implement this interface. +type ControllerRevisionsGetter interface { + ControllerRevisions(namespace string) ControllerRevisionInterface +} + +// ControllerRevisionInterface has methods to work with ControllerRevision resources. +type ControllerRevisionInterface interface { + Create(*v1beta1.ControllerRevision) (*v1beta1.ControllerRevision, error) + Update(*v1beta1.ControllerRevision) (*v1beta1.ControllerRevision, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1beta1.ControllerRevision, error) + List(opts v1.ListOptions) (*v1beta1.ControllerRevisionList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ControllerRevision, err error) + ControllerRevisionExpansion +} + +// controllerRevisions implements ControllerRevisionInterface +type controllerRevisions struct { + client rest.Interface + ns string +} + +// newControllerRevisions returns a ControllerRevisions +func newControllerRevisions(c *AppsV1beta1Client, namespace string) *controllerRevisions { + return &controllerRevisions{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a controllerRevision and creates it. Returns the server's representation of the controllerRevision, and an error, if there is any. +func (c *controllerRevisions) Create(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) { + result = &v1beta1.ControllerRevision{} + err = c.client.Post(). + Namespace(c.ns). + Resource("controllerrevisions"). + Body(controllerRevision). + Do(). + Into(result) + return +} + +// Update takes the representation of a controllerRevision and updates it. Returns the server's representation of the controllerRevision, and an error, if there is any. +func (c *controllerRevisions) Update(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) { + result = &v1beta1.ControllerRevision{} + err = c.client.Put(). + Namespace(c.ns). + Resource("controllerrevisions"). + Name(controllerRevision.Name). + Body(controllerRevision). + Do(). + Into(result) + return +} + +// Delete takes name of the controllerRevision and deletes it. Returns an error if one occurs. +func (c *controllerRevisions) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("controllerrevisions"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *controllerRevisions) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("controllerrevisions"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the controllerRevision, and returns the corresponding controllerRevision object, and an error if there is any. +func (c *controllerRevisions) Get(name string, options v1.GetOptions) (result *v1beta1.ControllerRevision, err error) { + result = &v1beta1.ControllerRevision{} + err = c.client.Get(). + Namespace(c.ns). + Resource("controllerrevisions"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of ControllerRevisions that match those selectors. +func (c *controllerRevisions) List(opts v1.ListOptions) (result *v1beta1.ControllerRevisionList, err error) { + result = &v1beta1.ControllerRevisionList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("controllerrevisions"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested controllerRevisions. +func (c *controllerRevisions) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("controllerrevisions"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched controllerRevision. +func (c *controllerRevisions) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ControllerRevision, err error) { + result = &v1beta1.ControllerRevision{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("controllerrevisions"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/fake/BUILD b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/fake/BUILD index 4c75b3273682d..0fcf337bc77f9 100644 --- a/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/fake/BUILD +++ b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/fake/BUILD @@ -12,6 +12,7 @@ go_library( srcs = [ "doc.go", "fake_apps_client.go", + "fake_controllerrevision.go", "fake_deployment.go", "fake_scale.go", "fake_statefulset.go", diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/fake/fake_apps_client.go b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/fake/fake_apps_client.go index 2a0bede6da995..f1280bc3f3662 100644 --- a/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/fake/fake_apps_client.go +++ b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/fake/fake_apps_client.go @@ -26,6 +26,10 @@ type FakeAppsV1beta1 struct { *testing.Fake } +func (c *FakeAppsV1beta1) ControllerRevisions(namespace string) v1beta1.ControllerRevisionInterface { + return &FakeControllerRevisions{c, namespace} +} + func (c *FakeAppsV1beta1) Deployments(namespace string) v1beta1.DeploymentInterface { return &FakeDeployments{c, namespace} } diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/fake/fake_controllerrevision.go b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/fake/fake_controllerrevision.go new file mode 100644 index 0000000000000..cdf9a27c52bb3 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/fake/fake_controllerrevision.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + labels "k8s.io/apimachinery/pkg/labels" + schema "k8s.io/apimachinery/pkg/runtime/schema" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + v1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" + testing "k8s.io/client-go/testing" +) + +// FakeControllerRevisions implements ControllerRevisionInterface +type FakeControllerRevisions struct { + Fake *FakeAppsV1beta1 + ns string +} + +var controllerrevisionsResource = schema.GroupVersionResource{Group: "apps", Version: "v1beta1", Resource: "controllerrevisions"} + +var controllerrevisionsKind = schema.GroupVersionKind{Group: "apps", Version: "v1beta1", Kind: "ControllerRevision"} + +func (c *FakeControllerRevisions) Create(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) { + obj, err := c.Fake. + Invokes(testing.NewCreateAction(controllerrevisionsResource, c.ns, controllerRevision), &v1beta1.ControllerRevision{}) + + if obj == nil { + return nil, err + } + return obj.(*v1beta1.ControllerRevision), err +} + +func (c *FakeControllerRevisions) Update(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) { + obj, err := c.Fake. + Invokes(testing.NewUpdateAction(controllerrevisionsResource, c.ns, controllerRevision), &v1beta1.ControllerRevision{}) + + if obj == nil { + return nil, err + } + return obj.(*v1beta1.ControllerRevision), err +} + +func (c *FakeControllerRevisions) Delete(name string, options *v1.DeleteOptions) error { + _, err := c.Fake. + Invokes(testing.NewDeleteAction(controllerrevisionsResource, c.ns, name), &v1beta1.ControllerRevision{}) + + return err +} + +func (c *FakeControllerRevisions) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + action := testing.NewDeleteCollectionAction(controllerrevisionsResource, c.ns, listOptions) + + _, err := c.Fake.Invokes(action, &v1beta1.ControllerRevisionList{}) + return err +} + +func (c *FakeControllerRevisions) Get(name string, options v1.GetOptions) (result *v1beta1.ControllerRevision, err error) { + obj, err := c.Fake. + Invokes(testing.NewGetAction(controllerrevisionsResource, c.ns, name), &v1beta1.ControllerRevision{}) + + if obj == nil { + return nil, err + } + return obj.(*v1beta1.ControllerRevision), err +} + +func (c *FakeControllerRevisions) List(opts v1.ListOptions) (result *v1beta1.ControllerRevisionList, err error) { + obj, err := c.Fake. + Invokes(testing.NewListAction(controllerrevisionsResource, controllerrevisionsKind, c.ns, opts), &v1beta1.ControllerRevisionList{}) + + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &v1beta1.ControllerRevisionList{} + for _, item := range obj.(*v1beta1.ControllerRevisionList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested controllerRevisions. +func (c *FakeControllerRevisions) Watch(opts v1.ListOptions) (watch.Interface, error) { + return c.Fake. + InvokesWatch(testing.NewWatchAction(controllerrevisionsResource, c.ns, opts)) + +} + +// Patch applies the patch and returns the patched controllerRevision. +func (c *FakeControllerRevisions) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ControllerRevision, err error) { + obj, err := c.Fake. + Invokes(testing.NewPatchSubresourceAction(controllerrevisionsResource, c.ns, name, data, subresources...), &v1beta1.ControllerRevision{}) + + if obj == nil { + return nil, err + } + return obj.(*v1beta1.ControllerRevision), err +} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/generated_expansion.go b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/generated_expansion.go index deca5c8663968..a091b902adfff 100644 --- a/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/generated_expansion.go +++ b/staging/src/k8s.io/client-go/kubernetes/typed/apps/v1beta1/generated_expansion.go @@ -16,6 +16,8 @@ limitations under the License. package v1beta1 +type ControllerRevisionExpansion interface{} + type DeploymentExpansion interface{} type ScaleExpansion interface{} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/BUILD b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/BUILD new file mode 100644 index 0000000000000..49ce9f31b06f2 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/BUILD @@ -0,0 +1,28 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "generated_expansion.go", + "networking_client.go", + "networkpolicy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/networking/v1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/doc.go b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/doc.go new file mode 100644 index 0000000000000..54673bfa73825 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package has the automatically generated typed clients. +package v1 diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/fake/BUILD b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/fake/BUILD new file mode 100644 index 0000000000000..39ed542892155 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/fake/BUILD @@ -0,0 +1,29 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "fake_networking_client.go", + "fake_networkpolicy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/networking/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/networking/v1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + "//vendor/k8s.io/client-go/testing:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/fake/doc.go b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/fake/doc.go new file mode 100644 index 0000000000000..c6548330a0d0a --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/fake/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This package is generated by client-gen with custom arguments. + +// Package fake has the automatically generated clients. +package fake diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/fake/fake_networking_client.go b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/fake/fake_networking_client.go new file mode 100644 index 0000000000000..d9733a0bffd8d --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/fake/fake_networking_client.go @@ -0,0 +1,38 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + v1 "k8s.io/client-go/kubernetes/typed/networking/v1" + rest "k8s.io/client-go/rest" + testing "k8s.io/client-go/testing" +) + +type FakeNetworkingV1 struct { + *testing.Fake +} + +func (c *FakeNetworkingV1) NetworkPolicies(namespace string) v1.NetworkPolicyInterface { + return &FakeNetworkPolicies{c, namespace} +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *FakeNetworkingV1) RESTClient() rest.Interface { + var ret *rest.RESTClient + return ret +} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/fake/fake_networkpolicy.go b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/fake/fake_networkpolicy.go new file mode 100644 index 0000000000000..a15f8673e795e --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/fake/fake_networkpolicy.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package fake + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + labels "k8s.io/apimachinery/pkg/labels" + schema "k8s.io/apimachinery/pkg/runtime/schema" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + v1 "k8s.io/client-go/pkg/apis/networking/v1" + testing "k8s.io/client-go/testing" +) + +// FakeNetworkPolicies implements NetworkPolicyInterface +type FakeNetworkPolicies struct { + Fake *FakeNetworkingV1 + ns string +} + +var networkpoliciesResource = schema.GroupVersionResource{Group: "networking.k8s.io", Version: "v1", Resource: "networkpolicies"} + +var networkpoliciesKind = schema.GroupVersionKind{Group: "networking.k8s.io", Version: "v1", Kind: "NetworkPolicy"} + +func (c *FakeNetworkPolicies) Create(networkPolicy *v1.NetworkPolicy) (result *v1.NetworkPolicy, err error) { + obj, err := c.Fake. + Invokes(testing.NewCreateAction(networkpoliciesResource, c.ns, networkPolicy), &v1.NetworkPolicy{}) + + if obj == nil { + return nil, err + } + return obj.(*v1.NetworkPolicy), err +} + +func (c *FakeNetworkPolicies) Update(networkPolicy *v1.NetworkPolicy) (result *v1.NetworkPolicy, err error) { + obj, err := c.Fake. + Invokes(testing.NewUpdateAction(networkpoliciesResource, c.ns, networkPolicy), &v1.NetworkPolicy{}) + + if obj == nil { + return nil, err + } + return obj.(*v1.NetworkPolicy), err +} + +func (c *FakeNetworkPolicies) Delete(name string, options *meta_v1.DeleteOptions) error { + _, err := c.Fake. + Invokes(testing.NewDeleteAction(networkpoliciesResource, c.ns, name), &v1.NetworkPolicy{}) + + return err +} + +func (c *FakeNetworkPolicies) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { + action := testing.NewDeleteCollectionAction(networkpoliciesResource, c.ns, listOptions) + + _, err := c.Fake.Invokes(action, &v1.NetworkPolicyList{}) + return err +} + +func (c *FakeNetworkPolicies) Get(name string, options meta_v1.GetOptions) (result *v1.NetworkPolicy, err error) { + obj, err := c.Fake. + Invokes(testing.NewGetAction(networkpoliciesResource, c.ns, name), &v1.NetworkPolicy{}) + + if obj == nil { + return nil, err + } + return obj.(*v1.NetworkPolicy), err +} + +func (c *FakeNetworkPolicies) List(opts meta_v1.ListOptions) (result *v1.NetworkPolicyList, err error) { + obj, err := c.Fake. + Invokes(testing.NewListAction(networkpoliciesResource, networkpoliciesKind, c.ns, opts), &v1.NetworkPolicyList{}) + + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &v1.NetworkPolicyList{} + for _, item := range obj.(*v1.NetworkPolicyList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested networkPolicies. +func (c *FakeNetworkPolicies) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + return c.Fake. + InvokesWatch(testing.NewWatchAction(networkpoliciesResource, c.ns, opts)) + +} + +// Patch applies the patch and returns the patched networkPolicy. +func (c *FakeNetworkPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.NetworkPolicy, err error) { + obj, err := c.Fake. + Invokes(testing.NewPatchSubresourceAction(networkpoliciesResource, c.ns, name, data, subresources...), &v1.NetworkPolicy{}) + + if obj == nil { + return nil, err + } + return obj.(*v1.NetworkPolicy), err +} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/generated_expansion.go b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/generated_expansion.go new file mode 100644 index 0000000000000..cdd70ae3536bd --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/generated_expansion.go @@ -0,0 +1,19 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +type NetworkPolicyExpansion interface{} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/networking_client.go b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/networking_client.go new file mode 100644 index 0000000000000..20429dd5d78ef --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/networking_client.go @@ -0,0 +1,88 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +import ( + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1 "k8s.io/client-go/pkg/apis/networking/v1" + rest "k8s.io/client-go/rest" +) + +type NetworkingV1Interface interface { + RESTClient() rest.Interface + NetworkPoliciesGetter +} + +// NetworkingV1Client is used to interact with features provided by the networking.k8s.io group. +type NetworkingV1Client struct { + restClient rest.Interface +} + +func (c *NetworkingV1Client) NetworkPolicies(namespace string) NetworkPolicyInterface { + return newNetworkPolicies(c, namespace) +} + +// NewForConfig creates a new NetworkingV1Client for the given config. +func NewForConfig(c *rest.Config) (*NetworkingV1Client, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &NetworkingV1Client{client}, nil +} + +// NewForConfigOrDie creates a new NetworkingV1Client for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *NetworkingV1Client { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new NetworkingV1Client for the given RESTClient. +func New(c rest.Interface) *NetworkingV1Client { + return &NetworkingV1Client{c} +} + +func setConfigDefaults(config *rest.Config) error { + gv := v1.SchemeGroupVersion + config.GroupVersion = &gv + config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *NetworkingV1Client) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/networkpolicy.go b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/networkpolicy.go new file mode 100644 index 0000000000000..14d1e669b1080 --- /dev/null +++ b/staging/src/k8s.io/client-go/kubernetes/typed/networking/v1/networkpolicy.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1 "k8s.io/client-go/pkg/apis/networking/v1" + rest "k8s.io/client-go/rest" +) + +// NetworkPoliciesGetter has a method to return a NetworkPolicyInterface. +// A group's client should implement this interface. +type NetworkPoliciesGetter interface { + NetworkPolicies(namespace string) NetworkPolicyInterface +} + +// NetworkPolicyInterface has methods to work with NetworkPolicy resources. +type NetworkPolicyInterface interface { + Create(*v1.NetworkPolicy) (*v1.NetworkPolicy, error) + Update(*v1.NetworkPolicy) (*v1.NetworkPolicy, error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.NetworkPolicy, error) + List(opts meta_v1.ListOptions) (*v1.NetworkPolicyList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.NetworkPolicy, err error) + NetworkPolicyExpansion +} + +// networkPolicies implements NetworkPolicyInterface +type networkPolicies struct { + client rest.Interface + ns string +} + +// newNetworkPolicies returns a NetworkPolicies +func newNetworkPolicies(c *NetworkingV1Client, namespace string) *networkPolicies { + return &networkPolicies{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a networkPolicy and creates it. Returns the server's representation of the networkPolicy, and an error, if there is any. +func (c *networkPolicies) Create(networkPolicy *v1.NetworkPolicy) (result *v1.NetworkPolicy, err error) { + result = &v1.NetworkPolicy{} + err = c.client.Post(). + Namespace(c.ns). + Resource("networkpolicies"). + Body(networkPolicy). + Do(). + Into(result) + return +} + +// Update takes the representation of a networkPolicy and updates it. Returns the server's representation of the networkPolicy, and an error, if there is any. +func (c *networkPolicies) Update(networkPolicy *v1.NetworkPolicy) (result *v1.NetworkPolicy, err error) { + result = &v1.NetworkPolicy{} + err = c.client.Put(). + Namespace(c.ns). + Resource("networkpolicies"). + Name(networkPolicy.Name). + Body(networkPolicy). + Do(). + Into(result) + return +} + +// Delete takes name of the networkPolicy and deletes it. Returns an error if one occurs. +func (c *networkPolicies) Delete(name string, options *meta_v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("networkpolicies"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *networkPolicies) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("networkpolicies"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the networkPolicy, and returns the corresponding networkPolicy object, and an error if there is any. +func (c *networkPolicies) Get(name string, options meta_v1.GetOptions) (result *v1.NetworkPolicy, err error) { + result = &v1.NetworkPolicy{} + err = c.client.Get(). + Namespace(c.ns). + Resource("networkpolicies"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of NetworkPolicies that match those selectors. +func (c *networkPolicies) List(opts meta_v1.ListOptions) (result *v1.NetworkPolicyList, err error) { + result = &v1.NetworkPolicyList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("networkpolicies"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested networkPolicies. +func (c *networkPolicies) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("networkpolicies"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched networkPolicy. +func (c *networkPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.NetworkPolicy, err error) { + result = &v1.NetworkPolicy{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("networkpolicies"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/staging/src/k8s.io/client-go/listers/admissionregistration/v1alpha1/BUILD b/staging/src/k8s.io/client-go/listers/admissionregistration/v1alpha1/BUILD new file mode 100644 index 0000000000000..02a14ccaf9947 --- /dev/null +++ b/staging/src/k8s.io/client-go/listers/admissionregistration/v1alpha1/BUILD @@ -0,0 +1,24 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "expansion_generated.go", + "externaladmissionhookconfiguration.go", + "initializerconfiguration.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/listers/admissionregistration/v1alpha1/expansion_generated.go b/staging/src/k8s.io/client-go/listers/admissionregistration/v1alpha1/expansion_generated.go new file mode 100644 index 0000000000000..3282a8bcfeb23 --- /dev/null +++ b/staging/src/k8s.io/client-go/listers/admissionregistration/v1alpha1/expansion_generated.go @@ -0,0 +1,35 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package v1alpha1 + +// ExternalAdmissionHookConfigurationListerExpansion allows custom methods to be added to +// ExternalAdmissionHookConfigurationLister. +type ExternalAdmissionHookConfigurationListerExpansion interface{} + +// ExternalAdmissionHookConfigurationNamespaceListerExpansion allows custom methods to be added to +// ExternalAdmissionHookConfigurationNamespaceLister. +type ExternalAdmissionHookConfigurationNamespaceListerExpansion interface{} + +// InitializerConfigurationListerExpansion allows custom methods to be added to +// InitializerConfigurationLister. +type InitializerConfigurationListerExpansion interface{} + +// InitializerConfigurationNamespaceListerExpansion allows custom methods to be added to +// InitializerConfigurationNamespaceLister. +type InitializerConfigurationNamespaceListerExpansion interface{} diff --git a/staging/src/k8s.io/client-go/listers/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go b/staging/src/k8s.io/client-go/listers/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go new file mode 100644 index 0000000000000..e0331f5477c56 --- /dev/null +++ b/staging/src/k8s.io/client-go/listers/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go @@ -0,0 +1,94 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package v1alpha1 + +import ( + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + v1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" + "k8s.io/client-go/tools/cache" +) + +// ExternalAdmissionHookConfigurationLister helps list ExternalAdmissionHookConfigurations. +type ExternalAdmissionHookConfigurationLister interface { + // List lists all ExternalAdmissionHookConfigurations in the indexer. + List(selector labels.Selector) (ret []*v1alpha1.ExternalAdmissionHookConfiguration, err error) + // ExternalAdmissionHookConfigurations returns an object that can list and get ExternalAdmissionHookConfigurations. + ExternalAdmissionHookConfigurations(namespace string) ExternalAdmissionHookConfigurationNamespaceLister + ExternalAdmissionHookConfigurationListerExpansion +} + +// externalAdmissionHookConfigurationLister implements the ExternalAdmissionHookConfigurationLister interface. +type externalAdmissionHookConfigurationLister struct { + indexer cache.Indexer +} + +// NewExternalAdmissionHookConfigurationLister returns a new ExternalAdmissionHookConfigurationLister. +func NewExternalAdmissionHookConfigurationLister(indexer cache.Indexer) ExternalAdmissionHookConfigurationLister { + return &externalAdmissionHookConfigurationLister{indexer: indexer} +} + +// List lists all ExternalAdmissionHookConfigurations in the indexer. +func (s *externalAdmissionHookConfigurationLister) List(selector labels.Selector) (ret []*v1alpha1.ExternalAdmissionHookConfiguration, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*v1alpha1.ExternalAdmissionHookConfiguration)) + }) + return ret, err +} + +// ExternalAdmissionHookConfigurations returns an object that can list and get ExternalAdmissionHookConfigurations. +func (s *externalAdmissionHookConfigurationLister) ExternalAdmissionHookConfigurations(namespace string) ExternalAdmissionHookConfigurationNamespaceLister { + return externalAdmissionHookConfigurationNamespaceLister{indexer: s.indexer, namespace: namespace} +} + +// ExternalAdmissionHookConfigurationNamespaceLister helps list and get ExternalAdmissionHookConfigurations. +type ExternalAdmissionHookConfigurationNamespaceLister interface { + // List lists all ExternalAdmissionHookConfigurations in the indexer for a given namespace. + List(selector labels.Selector) (ret []*v1alpha1.ExternalAdmissionHookConfiguration, err error) + // Get retrieves the ExternalAdmissionHookConfiguration from the indexer for a given namespace and name. + Get(name string) (*v1alpha1.ExternalAdmissionHookConfiguration, error) + ExternalAdmissionHookConfigurationNamespaceListerExpansion +} + +// externalAdmissionHookConfigurationNamespaceLister implements the ExternalAdmissionHookConfigurationNamespaceLister +// interface. +type externalAdmissionHookConfigurationNamespaceLister struct { + indexer cache.Indexer + namespace string +} + +// List lists all ExternalAdmissionHookConfigurations in the indexer for a given namespace. +func (s externalAdmissionHookConfigurationNamespaceLister) List(selector labels.Selector) (ret []*v1alpha1.ExternalAdmissionHookConfiguration, err error) { + err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { + ret = append(ret, m.(*v1alpha1.ExternalAdmissionHookConfiguration)) + }) + return ret, err +} + +// Get retrieves the ExternalAdmissionHookConfiguration from the indexer for a given namespace and name. +func (s externalAdmissionHookConfigurationNamespaceLister) Get(name string) (*v1alpha1.ExternalAdmissionHookConfiguration, error) { + obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(v1alpha1.Resource("externaladmissionhookconfiguration"), name) + } + return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), nil +} diff --git a/staging/src/k8s.io/client-go/listers/admissionregistration/v1alpha1/initializerconfiguration.go b/staging/src/k8s.io/client-go/listers/admissionregistration/v1alpha1/initializerconfiguration.go new file mode 100644 index 0000000000000..a2b1c3b3b1ede --- /dev/null +++ b/staging/src/k8s.io/client-go/listers/admissionregistration/v1alpha1/initializerconfiguration.go @@ -0,0 +1,94 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package v1alpha1 + +import ( + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + v1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" + "k8s.io/client-go/tools/cache" +) + +// InitializerConfigurationLister helps list InitializerConfigurations. +type InitializerConfigurationLister interface { + // List lists all InitializerConfigurations in the indexer. + List(selector labels.Selector) (ret []*v1alpha1.InitializerConfiguration, err error) + // InitializerConfigurations returns an object that can list and get InitializerConfigurations. + InitializerConfigurations(namespace string) InitializerConfigurationNamespaceLister + InitializerConfigurationListerExpansion +} + +// initializerConfigurationLister implements the InitializerConfigurationLister interface. +type initializerConfigurationLister struct { + indexer cache.Indexer +} + +// NewInitializerConfigurationLister returns a new InitializerConfigurationLister. +func NewInitializerConfigurationLister(indexer cache.Indexer) InitializerConfigurationLister { + return &initializerConfigurationLister{indexer: indexer} +} + +// List lists all InitializerConfigurations in the indexer. +func (s *initializerConfigurationLister) List(selector labels.Selector) (ret []*v1alpha1.InitializerConfiguration, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*v1alpha1.InitializerConfiguration)) + }) + return ret, err +} + +// InitializerConfigurations returns an object that can list and get InitializerConfigurations. +func (s *initializerConfigurationLister) InitializerConfigurations(namespace string) InitializerConfigurationNamespaceLister { + return initializerConfigurationNamespaceLister{indexer: s.indexer, namespace: namespace} +} + +// InitializerConfigurationNamespaceLister helps list and get InitializerConfigurations. +type InitializerConfigurationNamespaceLister interface { + // List lists all InitializerConfigurations in the indexer for a given namespace. + List(selector labels.Selector) (ret []*v1alpha1.InitializerConfiguration, err error) + // Get retrieves the InitializerConfiguration from the indexer for a given namespace and name. + Get(name string) (*v1alpha1.InitializerConfiguration, error) + InitializerConfigurationNamespaceListerExpansion +} + +// initializerConfigurationNamespaceLister implements the InitializerConfigurationNamespaceLister +// interface. +type initializerConfigurationNamespaceLister struct { + indexer cache.Indexer + namespace string +} + +// List lists all InitializerConfigurations in the indexer for a given namespace. +func (s initializerConfigurationNamespaceLister) List(selector labels.Selector) (ret []*v1alpha1.InitializerConfiguration, err error) { + err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { + ret = append(ret, m.(*v1alpha1.InitializerConfiguration)) + }) + return ret, err +} + +// Get retrieves the InitializerConfiguration from the indexer for a given namespace and name. +func (s initializerConfigurationNamespaceLister) Get(name string) (*v1alpha1.InitializerConfiguration, error) { + obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(v1alpha1.Resource("initializerconfiguration"), name) + } + return obj.(*v1alpha1.InitializerConfiguration), nil +} diff --git a/staging/src/k8s.io/client-go/listers/apps/v1beta1/BUILD b/staging/src/k8s.io/client-go/listers/apps/v1beta1/BUILD index f7b566c9420da..a2f327f85c23e 100644 --- a/staging/src/k8s.io/client-go/listers/apps/v1beta1/BUILD +++ b/staging/src/k8s.io/client-go/listers/apps/v1beta1/BUILD @@ -10,6 +10,7 @@ load( go_library( name = "go_default_library", srcs = [ + "controllerrevision.go", "deployment.go", "expansion_generated.go", "scale.go", diff --git a/staging/src/k8s.io/client-go/listers/apps/v1beta1/controllerrevision.go b/staging/src/k8s.io/client-go/listers/apps/v1beta1/controllerrevision.go new file mode 100644 index 0000000000000..f94ed93ebde9c --- /dev/null +++ b/staging/src/k8s.io/client-go/listers/apps/v1beta1/controllerrevision.go @@ -0,0 +1,94 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package v1beta1 + +import ( + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + v1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" + "k8s.io/client-go/tools/cache" +) + +// ControllerRevisionLister helps list ControllerRevisions. +type ControllerRevisionLister interface { + // List lists all ControllerRevisions in the indexer. + List(selector labels.Selector) (ret []*v1beta1.ControllerRevision, err error) + // ControllerRevisions returns an object that can list and get ControllerRevisions. + ControllerRevisions(namespace string) ControllerRevisionNamespaceLister + ControllerRevisionListerExpansion +} + +// controllerRevisionLister implements the ControllerRevisionLister interface. +type controllerRevisionLister struct { + indexer cache.Indexer +} + +// NewControllerRevisionLister returns a new ControllerRevisionLister. +func NewControllerRevisionLister(indexer cache.Indexer) ControllerRevisionLister { + return &controllerRevisionLister{indexer: indexer} +} + +// List lists all ControllerRevisions in the indexer. +func (s *controllerRevisionLister) List(selector labels.Selector) (ret []*v1beta1.ControllerRevision, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*v1beta1.ControllerRevision)) + }) + return ret, err +} + +// ControllerRevisions returns an object that can list and get ControllerRevisions. +func (s *controllerRevisionLister) ControllerRevisions(namespace string) ControllerRevisionNamespaceLister { + return controllerRevisionNamespaceLister{indexer: s.indexer, namespace: namespace} +} + +// ControllerRevisionNamespaceLister helps list and get ControllerRevisions. +type ControllerRevisionNamespaceLister interface { + // List lists all ControllerRevisions in the indexer for a given namespace. + List(selector labels.Selector) (ret []*v1beta1.ControllerRevision, err error) + // Get retrieves the ControllerRevision from the indexer for a given namespace and name. + Get(name string) (*v1beta1.ControllerRevision, error) + ControllerRevisionNamespaceListerExpansion +} + +// controllerRevisionNamespaceLister implements the ControllerRevisionNamespaceLister +// interface. +type controllerRevisionNamespaceLister struct { + indexer cache.Indexer + namespace string +} + +// List lists all ControllerRevisions in the indexer for a given namespace. +func (s controllerRevisionNamespaceLister) List(selector labels.Selector) (ret []*v1beta1.ControllerRevision, err error) { + err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { + ret = append(ret, m.(*v1beta1.ControllerRevision)) + }) + return ret, err +} + +// Get retrieves the ControllerRevision from the indexer for a given namespace and name. +func (s controllerRevisionNamespaceLister) Get(name string) (*v1beta1.ControllerRevision, error) { + obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(v1beta1.Resource("controllerrevision"), name) + } + return obj.(*v1beta1.ControllerRevision), nil +} diff --git a/staging/src/k8s.io/client-go/listers/apps/v1beta1/expansion_generated.go b/staging/src/k8s.io/client-go/listers/apps/v1beta1/expansion_generated.go index a648745f11a0e..441ceecdd43a6 100644 --- a/staging/src/k8s.io/client-go/listers/apps/v1beta1/expansion_generated.go +++ b/staging/src/k8s.io/client-go/listers/apps/v1beta1/expansion_generated.go @@ -18,6 +18,14 @@ limitations under the License. package v1beta1 +// ControllerRevisionListerExpansion allows custom methods to be added to +// ControllerRevisionLister. +type ControllerRevisionListerExpansion interface{} + +// ControllerRevisionNamespaceListerExpansion allows custom methods to be added to +// ControllerRevisionNamespaceLister. +type ControllerRevisionNamespaceListerExpansion interface{} + // DeploymentListerExpansion allows custom methods to be added to // DeploymentLister. type DeploymentListerExpansion interface{} diff --git a/staging/src/k8s.io/client-go/listers/networking/v1/BUILD b/staging/src/k8s.io/client-go/listers/networking/v1/BUILD new file mode 100644 index 0000000000000..0e72411f27fad --- /dev/null +++ b/staging/src/k8s.io/client-go/listers/networking/v1/BUILD @@ -0,0 +1,23 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "expansion_generated.go", + "networkpolicy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/networking/v1:go_default_library", + "//vendor/k8s.io/client-go/tools/cache:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/listers/networking/v1/expansion_generated.go b/staging/src/k8s.io/client-go/listers/networking/v1/expansion_generated.go new file mode 100644 index 0000000000000..91fe5e772f8c2 --- /dev/null +++ b/staging/src/k8s.io/client-go/listers/networking/v1/expansion_generated.go @@ -0,0 +1,27 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package v1 + +// NetworkPolicyListerExpansion allows custom methods to be added to +// NetworkPolicyLister. +type NetworkPolicyListerExpansion interface{} + +// NetworkPolicyNamespaceListerExpansion allows custom methods to be added to +// NetworkPolicyNamespaceLister. +type NetworkPolicyNamespaceListerExpansion interface{} diff --git a/staging/src/k8s.io/client-go/listers/networking/v1/networkpolicy.go b/staging/src/k8s.io/client-go/listers/networking/v1/networkpolicy.go new file mode 100644 index 0000000000000..315b34f2fce93 --- /dev/null +++ b/staging/src/k8s.io/client-go/listers/networking/v1/networkpolicy.go @@ -0,0 +1,94 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was automatically generated by lister-gen + +package v1 + +import ( + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + v1 "k8s.io/client-go/pkg/apis/networking/v1" + "k8s.io/client-go/tools/cache" +) + +// NetworkPolicyLister helps list NetworkPolicies. +type NetworkPolicyLister interface { + // List lists all NetworkPolicies in the indexer. + List(selector labels.Selector) (ret []*v1.NetworkPolicy, err error) + // NetworkPolicies returns an object that can list and get NetworkPolicies. + NetworkPolicies(namespace string) NetworkPolicyNamespaceLister + NetworkPolicyListerExpansion +} + +// networkPolicyLister implements the NetworkPolicyLister interface. +type networkPolicyLister struct { + indexer cache.Indexer +} + +// NewNetworkPolicyLister returns a new NetworkPolicyLister. +func NewNetworkPolicyLister(indexer cache.Indexer) NetworkPolicyLister { + return &networkPolicyLister{indexer: indexer} +} + +// List lists all NetworkPolicies in the indexer. +func (s *networkPolicyLister) List(selector labels.Selector) (ret []*v1.NetworkPolicy, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*v1.NetworkPolicy)) + }) + return ret, err +} + +// NetworkPolicies returns an object that can list and get NetworkPolicies. +func (s *networkPolicyLister) NetworkPolicies(namespace string) NetworkPolicyNamespaceLister { + return networkPolicyNamespaceLister{indexer: s.indexer, namespace: namespace} +} + +// NetworkPolicyNamespaceLister helps list and get NetworkPolicies. +type NetworkPolicyNamespaceLister interface { + // List lists all NetworkPolicies in the indexer for a given namespace. + List(selector labels.Selector) (ret []*v1.NetworkPolicy, err error) + // Get retrieves the NetworkPolicy from the indexer for a given namespace and name. + Get(name string) (*v1.NetworkPolicy, error) + NetworkPolicyNamespaceListerExpansion +} + +// networkPolicyNamespaceLister implements the NetworkPolicyNamespaceLister +// interface. +type networkPolicyNamespaceLister struct { + indexer cache.Indexer + namespace string +} + +// List lists all NetworkPolicies in the indexer for a given namespace. +func (s networkPolicyNamespaceLister) List(selector labels.Selector) (ret []*v1.NetworkPolicy, err error) { + err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { + ret = append(ret, m.(*v1.NetworkPolicy)) + }) + return ret, err +} + +// Get retrieves the NetworkPolicy from the indexer for a given namespace and name. +func (s networkPolicyNamespaceLister) Get(name string) (*v1.NetworkPolicy, error) { + obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(v1.Resource("networkpolicy"), name) + } + return obj.(*v1.NetworkPolicy), nil +} diff --git a/staging/src/k8s.io/client-go/pkg/api/BUILD b/staging/src/k8s.io/client-go/pkg/api/BUILD index f6d0e0315c663..8f4154d53c4d8 100644 --- a/staging/src/k8s.io/client-go/pkg/api/BUILD +++ b/staging/src/k8s.io/client-go/pkg/api/BUILD @@ -23,11 +23,6 @@ go_library( "zz_generated.deepcopy.go", ], tags = ["automanaged"], - visibility = [ - "//vendor/k8s.io/client-go/pkg/api:__subpackages__", - "//vendor/k8s.io/client-go/pkg/apis:__subpackages__", - "//vendor/k8s.io/metrics/pkg/client/clientset_generated/clientset/fake:__subpackages__", - ], deps = [ "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/api/helper/BUILD b/staging/src/k8s.io/client-go/pkg/api/helper/BUILD index 80f9cc2c191c3..a80762015a34a 100644 --- a/staging/src/k8s.io/client-go/pkg/api/helper/BUILD +++ b/staging/src/k8s.io/client-go/pkg/api/helper/BUILD @@ -8,31 +8,30 @@ load( "go_test", ) -go_library( - name = "go_default_library", - srcs = ["helpers.go"], +go_test( + name = "go_default_test", + srcs = ["helpers_test.go"], + library = ":go_default_library", tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", - "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", - "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", - "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", - "//vendor/k8s.io/apimachinery/pkg/selection:go_default_library", - "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", "//vendor/k8s.io/client-go/pkg/api:go_default_library", ], ) -go_test( - name = "go_default_test", - srcs = ["helpers_test.go"], - library = ":go_default_library", +go_library( + name = "go_default_library", + srcs = ["helpers.go"], tags = ["automanaged"], deps = [ "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/selection:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", "//vendor/k8s.io/client-go/pkg/api:go_default_library", ], ) diff --git a/staging/src/k8s.io/client-go/pkg/api/helper/helpers.go b/staging/src/k8s.io/client-go/pkg/api/helper/helpers.go index 3bce0e54be9ca..068877d5e2d22 100644 --- a/staging/src/k8s.io/client-go/pkg/api/helper/helpers.go +++ b/staging/src/k8s.io/client-go/pkg/api/helper/helpers.go @@ -590,6 +590,10 @@ func GetStorageNodeAffinityFromAnnotation(annotations map[string]string) (*api.N // Converts NodeAffinity type to Alpha annotation for use in PersistentVolumes // TODO: update when storage node affinity graduates to beta func StorageNodeAffinityToAlphaAnnotation(annotations map[string]string, affinity *api.NodeAffinity) error { + if affinity == nil { + return nil + } + json, err := json.Marshal(*affinity) if err != nil { return err diff --git a/staging/src/k8s.io/client-go/pkg/api/helper/qos/BUILD b/staging/src/k8s.io/client-go/pkg/api/helper/qos/BUILD index d3b18aacaeac0..2fe3b66df84fc 100644 --- a/staging/src/k8s.io/client-go/pkg/api/helper/qos/BUILD +++ b/staging/src/k8s.io/client-go/pkg/api/helper/qos/BUILD @@ -11,7 +11,6 @@ go_library( name = "go_default_library", srcs = ["qos.go"], tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/api/install/BUILD b/staging/src/k8s.io/client-go/pkg/api/install/BUILD index 6004f22ae8a17..8580df6f55b89 100644 --- a/staging/src/k8s.io/client-go/pkg/api/install/BUILD +++ b/staging/src/k8s.io/client-go/pkg/api/install/BUILD @@ -11,7 +11,6 @@ go_library( name = "go_default_library", srcs = ["install.go"], tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/api/types.go b/staging/src/k8s.io/client-go/pkg/api/types.go index b8897e17ef003..6d8943c36a0e4 100644 --- a/staging/src/k8s.io/client-go/pkg/api/types.go +++ b/staging/src/k8s.io/client-go/pkg/api/types.go @@ -601,6 +601,14 @@ type EmptyDirVolumeSource struct { // The default is "" which means to use the node's default medium. // +optional Medium StorageMedium + // Total amount of local storage required for this EmptyDir volume. + // The size limit is also applicable for memory medium. + // The maximum usage on memory medium EmptyDir would be the minimum value between + // the SizeLimit specified here and the sum of memory limits of all containers in a pod. + // The default is nil which means that the limit is undefined. + // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir + // +optional + SizeLimit resource.Quantity } // StorageMedium defines ways that storage can be allocated to a volume. @@ -3017,6 +3025,12 @@ const ( ResourceMemory ResourceName = "memory" // Volume size, in bytes (e,g. 5Gi = 5GiB = 5 * 1024 * 1024 * 1024) ResourceStorage ResourceName = "storage" + // Local Storage for overlay filesystem, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024) + // The resource name for ResourceStorageOverlay is alpha and it can change across releases. + ResourceStorageOverlay ResourceName = "storage.kubernetes.io/overlay" + // Local Storage for scratch space, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024) + // The resource name for ResourceStorageScratch is alpha and it can change across releases. + ResourceStorageScratch ResourceName = "storage.kubernetes.io/scratch" // NVIDIA GPU, in devices. Alpha, might change: although fractional and allowing values >1, only one whole device per node is assigned. ResourceNvidiaGPU ResourceName = "alpha.kubernetes.io/nvidia-gpu" // Number of Pods that may be running on this Node: see ResourcePods diff --git a/staging/src/k8s.io/client-go/pkg/api/v1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/api/v1/generated.pb.go index 05928c0f48726..550da43049a14 100644 --- a/staging/src/k8s.io/client-go/pkg/api/v1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/api/v1/generated.pb.go @@ -2571,6 +2571,14 @@ func (m *EmptyDirVolumeSource) MarshalTo(dAtA []byte) (int, error) { i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Medium))) i += copy(dAtA[i:], m.Medium) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.SizeLimit.Size())) + n31, err := m.SizeLimit.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n31 return i, nil } @@ -2597,11 +2605,11 @@ func (m *EndpointAddress) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.TargetRef.Size())) - n31, err := m.TargetRef.MarshalTo(dAtA[i:]) + n32, err := m.TargetRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n31 + i += n32 } dAtA[i] = 0x1a i++ @@ -2717,11 +2725,11 @@ func (m *Endpoints) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n32, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n33, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n32 + i += n33 if len(m.Subsets) > 0 { for _, msg := range m.Subsets { dAtA[i] = 0x12 @@ -2755,11 +2763,11 @@ func (m *EndpointsList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n33, err := m.ListMeta.MarshalTo(dAtA[i:]) + n34, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n33 + i += n34 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -2798,21 +2806,21 @@ func (m *EnvFromSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ConfigMapRef.Size())) - n34, err := m.ConfigMapRef.MarshalTo(dAtA[i:]) + n35, err := m.ConfigMapRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n34 + i += n35 } if m.SecretRef != nil { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) - n35, err := m.SecretRef.MarshalTo(dAtA[i:]) + n36, err := m.SecretRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n35 + i += n36 } return i, nil } @@ -2844,11 +2852,11 @@ func (m *EnvVar) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ValueFrom.Size())) - n36, err := m.ValueFrom.MarshalTo(dAtA[i:]) + n37, err := m.ValueFrom.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n36 + i += n37 } return i, nil } @@ -2872,41 +2880,41 @@ func (m *EnvVarSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.FieldRef.Size())) - n37, err := m.FieldRef.MarshalTo(dAtA[i:]) + n38, err := m.FieldRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n37 + i += n38 } if m.ResourceFieldRef != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ResourceFieldRef.Size())) - n38, err := m.ResourceFieldRef.MarshalTo(dAtA[i:]) + n39, err := m.ResourceFieldRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n38 + i += n39 } if m.ConfigMapKeyRef != nil { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ConfigMapKeyRef.Size())) - n39, err := m.ConfigMapKeyRef.MarshalTo(dAtA[i:]) + n40, err := m.ConfigMapKeyRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n39 + i += n40 } if m.SecretKeyRef != nil { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecretKeyRef.Size())) - n40, err := m.SecretKeyRef.MarshalTo(dAtA[i:]) + n41, err := m.SecretKeyRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n40 + i += n41 } return i, nil } @@ -2929,19 +2937,19 @@ func (m *Event) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n41, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n42, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n41 + i += n42 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.InvolvedObject.Size())) - n42, err := m.InvolvedObject.MarshalTo(dAtA[i:]) + n43, err := m.InvolvedObject.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n42 + i += n43 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) @@ -2953,27 +2961,27 @@ func (m *Event) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x2a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Source.Size())) - n43, err := m.Source.MarshalTo(dAtA[i:]) + n44, err := m.Source.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n43 + i += n44 dAtA[i] = 0x32 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.FirstTimestamp.Size())) - n44, err := m.FirstTimestamp.MarshalTo(dAtA[i:]) + n45, err := m.FirstTimestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n44 + i += n45 dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastTimestamp.Size())) - n45, err := m.LastTimestamp.MarshalTo(dAtA[i:]) + n46, err := m.LastTimestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n45 + i += n46 dAtA[i] = 0x40 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Count)) @@ -3002,11 +3010,11 @@ func (m *EventList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n46, err := m.ListMeta.MarshalTo(dAtA[i:]) + n47, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n46 + i += n47 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -3158,11 +3166,11 @@ func (m *FlexVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) - n47, err := m.SecretRef.MarshalTo(dAtA[i:]) + n48, err := m.SecretRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n47 + i += n48 } dAtA[i] = 0x20 i++ @@ -3341,11 +3349,11 @@ func (m *HTTPGetAction) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Port.Size())) - n48, err := m.Port.MarshalTo(dAtA[i:]) + n49, err := m.Port.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n48 + i += n49 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Host))) @@ -3414,31 +3422,31 @@ func (m *Handler) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Exec.Size())) - n49, err := m.Exec.MarshalTo(dAtA[i:]) + n50, err := m.Exec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n49 + i += n50 } if m.HTTPGet != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.HTTPGet.Size())) - n50, err := m.HTTPGet.MarshalTo(dAtA[i:]) + n51, err := m.HTTPGet.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n50 + i += n51 } if m.TCPSocket != nil { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.TCPSocket.Size())) - n51, err := m.TCPSocket.MarshalTo(dAtA[i:]) + n52, err := m.TCPSocket.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n51 + i += n52 } return i, nil } @@ -3571,11 +3579,11 @@ func (m *ISCSIVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x52 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) - n52, err := m.SecretRef.MarshalTo(dAtA[i:]) + n53, err := m.SecretRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n52 + i += n53 } dAtA[i] = 0x58 i++ @@ -3638,21 +3646,21 @@ func (m *Lifecycle) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PostStart.Size())) - n53, err := m.PostStart.MarshalTo(dAtA[i:]) + n54, err := m.PostStart.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n53 + i += n54 } if m.PreStop != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PreStop.Size())) - n54, err := m.PreStop.MarshalTo(dAtA[i:]) + n55, err := m.PreStop.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n54 + i += n55 } return i, nil } @@ -3675,19 +3683,19 @@ func (m *LimitRange) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n55, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n56, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n55 + i += n56 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n56, err := m.Spec.MarshalTo(dAtA[i:]) + n57, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n56 + i += n57 return i, nil } @@ -3729,11 +3737,11 @@ func (m *LimitRangeItem) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n57, err := (&v).MarshalTo(dAtA[i:]) + n58, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n57 + i += n58 } } if len(m.Min) > 0 { @@ -3755,11 +3763,11 @@ func (m *LimitRangeItem) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n58, err := (&v).MarshalTo(dAtA[i:]) + n59, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n58 + i += n59 } } if len(m.Default) > 0 { @@ -3781,11 +3789,11 @@ func (m *LimitRangeItem) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n59, err := (&v).MarshalTo(dAtA[i:]) + n60, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n59 + i += n60 } } if len(m.DefaultRequest) > 0 { @@ -3807,11 +3815,11 @@ func (m *LimitRangeItem) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n60, err := (&v).MarshalTo(dAtA[i:]) + n61, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n60 + i += n61 } } if len(m.MaxLimitRequestRatio) > 0 { @@ -3833,11 +3841,11 @@ func (m *LimitRangeItem) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n61, err := (&v).MarshalTo(dAtA[i:]) + n62, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n61 + i += n62 } } return i, nil @@ -3861,11 +3869,11 @@ func (m *LimitRangeList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n62, err := m.ListMeta.MarshalTo(dAtA[i:]) + n63, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n62 + i += n63 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -3929,11 +3937,11 @@ func (m *List) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n63, err := m.ListMeta.MarshalTo(dAtA[i:]) + n64, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n63 + i += n64 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -4152,27 +4160,27 @@ func (m *Namespace) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n64, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n65, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n64 + i += n65 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n65, err := m.Spec.MarshalTo(dAtA[i:]) + n66, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n65 + i += n66 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n66, err := m.Status.MarshalTo(dAtA[i:]) + n67, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n66 + i += n67 return i, nil } @@ -4194,11 +4202,11 @@ func (m *NamespaceList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n67, err := m.ListMeta.MarshalTo(dAtA[i:]) + n68, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n67 + i += n68 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -4287,27 +4295,27 @@ func (m *Node) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n68, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n69, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n68 + i += n69 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n69, err := m.Spec.MarshalTo(dAtA[i:]) + n70, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n69 + i += n70 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n70, err := m.Status.MarshalTo(dAtA[i:]) + n71, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n70 + i += n71 return i, nil } @@ -4356,11 +4364,11 @@ func (m *NodeAffinity) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.RequiredDuringSchedulingIgnoredDuringExecution.Size())) - n71, err := m.RequiredDuringSchedulingIgnoredDuringExecution.MarshalTo(dAtA[i:]) + n72, err := m.RequiredDuringSchedulingIgnoredDuringExecution.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n71 + i += n72 } if len(m.PreferredDuringSchedulingIgnoredDuringExecution) > 0 { for _, msg := range m.PreferredDuringSchedulingIgnoredDuringExecution { @@ -4403,19 +4411,19 @@ func (m *NodeCondition) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastHeartbeatTime.Size())) - n72, err := m.LastHeartbeatTime.MarshalTo(dAtA[i:]) + n73, err := m.LastHeartbeatTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n72 + i += n73 dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) - n73, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) + n74, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n73 + i += n74 dAtA[i] = 0x2a i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) @@ -4445,11 +4453,11 @@ func (m *NodeDaemonEndpoints) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.KubeletEndpoint.Size())) - n74, err := m.KubeletEndpoint.MarshalTo(dAtA[i:]) + n75, err := m.KubeletEndpoint.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n74 + i += n75 return i, nil } @@ -4471,11 +4479,11 @@ func (m *NodeList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n75, err := m.ListMeta.MarshalTo(dAtA[i:]) + n76, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n75 + i += n76 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -4547,11 +4555,11 @@ func (m *NodeResources) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n76, err := (&v).MarshalTo(dAtA[i:]) + n77, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n76 + i += n77 } } return i, nil @@ -4742,11 +4750,11 @@ func (m *NodeStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n77, err := (&v).MarshalTo(dAtA[i:]) + n78, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n77 + i += n78 } } if len(m.Allocatable) > 0 { @@ -4768,11 +4776,11 @@ func (m *NodeStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n78, err := (&v).MarshalTo(dAtA[i:]) + n79, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n78 + i += n79 } } dAtA[i] = 0x1a @@ -4806,19 +4814,19 @@ func (m *NodeStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x32 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.DaemonEndpoints.Size())) - n79, err := m.DaemonEndpoints.MarshalTo(dAtA[i:]) + n80, err := m.DaemonEndpoints.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n79 + i += n80 dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.NodeInfo.Size())) - n80, err := m.NodeInfo.MarshalTo(dAtA[i:]) + n81, err := m.NodeInfo.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n80 + i += n81 if len(m.Images) > 0 { for _, msg := range m.Images { dAtA[i] = 0x42 @@ -4990,20 +4998,20 @@ func (m *ObjectMeta) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x42 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.CreationTimestamp.Size())) - n81, err := m.CreationTimestamp.MarshalTo(dAtA[i:]) + n82, err := m.CreationTimestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n81 + i += n82 if m.DeletionTimestamp != nil { dAtA[i] = 0x4a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.DeletionTimestamp.Size())) - n82, err := m.DeletionTimestamp.MarshalTo(dAtA[i:]) + n83, err := m.DeletionTimestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n82 + i += n83 } if m.DeletionGracePeriodSeconds != nil { dAtA[i] = 0x50 @@ -5081,11 +5089,11 @@ func (m *ObjectMeta) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Initializers.Size())) - n83, err := m.Initializers.MarshalTo(dAtA[i:]) + n84, err := m.Initializers.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n83 + i += n84 } return i, nil } @@ -5154,27 +5162,27 @@ func (m *PersistentVolume) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n84, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n85, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n84 + i += n85 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n85, err := m.Spec.MarshalTo(dAtA[i:]) + n86, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n85 + i += n86 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n86, err := m.Status.MarshalTo(dAtA[i:]) + n87, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n86 + i += n87 return i, nil } @@ -5196,27 +5204,27 @@ func (m *PersistentVolumeClaim) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n87, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n88, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n87 + i += n88 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n88, err := m.Spec.MarshalTo(dAtA[i:]) + n89, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n88 + i += n89 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n89, err := m.Status.MarshalTo(dAtA[i:]) + n90, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n89 + i += n90 return i, nil } @@ -5238,11 +5246,11 @@ func (m *PersistentVolumeClaimList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n90, err := m.ListMeta.MarshalTo(dAtA[i:]) + n91, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n90 + i += n91 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -5291,11 +5299,11 @@ func (m *PersistentVolumeClaimSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Resources.Size())) - n91, err := m.Resources.MarshalTo(dAtA[i:]) + n92, err := m.Resources.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n91 + i += n92 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.VolumeName))) @@ -5304,11 +5312,11 @@ func (m *PersistentVolumeClaimSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) - n92, err := m.Selector.MarshalTo(dAtA[i:]) + n93, err := m.Selector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n92 + i += n93 } if m.StorageClassName != nil { dAtA[i] = 0x2a @@ -5372,11 +5380,11 @@ func (m *PersistentVolumeClaimStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n93, err := (&v).MarshalTo(dAtA[i:]) + n94, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n93 + i += n94 } } return i, nil @@ -5430,11 +5438,11 @@ func (m *PersistentVolumeList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n94, err := m.ListMeta.MarshalTo(dAtA[i:]) + n95, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n94 + i += n95 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -5469,151 +5477,151 @@ func (m *PersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.GCEPersistentDisk.Size())) - n95, err := m.GCEPersistentDisk.MarshalTo(dAtA[i:]) + n96, err := m.GCEPersistentDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n95 + i += n96 } if m.AWSElasticBlockStore != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.AWSElasticBlockStore.Size())) - n96, err := m.AWSElasticBlockStore.MarshalTo(dAtA[i:]) + n97, err := m.AWSElasticBlockStore.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n96 + i += n97 } if m.HostPath != nil { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.HostPath.Size())) - n97, err := m.HostPath.MarshalTo(dAtA[i:]) + n98, err := m.HostPath.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n97 + i += n98 } if m.Glusterfs != nil { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Glusterfs.Size())) - n98, err := m.Glusterfs.MarshalTo(dAtA[i:]) + n99, err := m.Glusterfs.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n98 + i += n99 } if m.NFS != nil { dAtA[i] = 0x2a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.NFS.Size())) - n99, err := m.NFS.MarshalTo(dAtA[i:]) + n100, err := m.NFS.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n99 + i += n100 } if m.RBD != nil { dAtA[i] = 0x32 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.RBD.Size())) - n100, err := m.RBD.MarshalTo(dAtA[i:]) + n101, err := m.RBD.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n100 + i += n101 } if m.ISCSI != nil { dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ISCSI.Size())) - n101, err := m.ISCSI.MarshalTo(dAtA[i:]) + n102, err := m.ISCSI.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n101 + i += n102 } if m.Cinder != nil { dAtA[i] = 0x42 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Cinder.Size())) - n102, err := m.Cinder.MarshalTo(dAtA[i:]) + n103, err := m.Cinder.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n102 + i += n103 } if m.CephFS != nil { dAtA[i] = 0x4a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.CephFS.Size())) - n103, err := m.CephFS.MarshalTo(dAtA[i:]) + n104, err := m.CephFS.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n103 + i += n104 } if m.FC != nil { dAtA[i] = 0x52 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.FC.Size())) - n104, err := m.FC.MarshalTo(dAtA[i:]) + n105, err := m.FC.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n104 + i += n105 } if m.Flocker != nil { dAtA[i] = 0x5a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Flocker.Size())) - n105, err := m.Flocker.MarshalTo(dAtA[i:]) + n106, err := m.Flocker.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n105 + i += n106 } if m.FlexVolume != nil { dAtA[i] = 0x62 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.FlexVolume.Size())) - n106, err := m.FlexVolume.MarshalTo(dAtA[i:]) + n107, err := m.FlexVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n106 + i += n107 } if m.AzureFile != nil { dAtA[i] = 0x6a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.AzureFile.Size())) - n107, err := m.AzureFile.MarshalTo(dAtA[i:]) + n108, err := m.AzureFile.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n107 + i += n108 } if m.VsphereVolume != nil { dAtA[i] = 0x72 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.VsphereVolume.Size())) - n108, err := m.VsphereVolume.MarshalTo(dAtA[i:]) + n109, err := m.VsphereVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n108 + i += n109 } if m.Quobyte != nil { dAtA[i] = 0x7a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Quobyte.Size())) - n109, err := m.Quobyte.MarshalTo(dAtA[i:]) + n110, err := m.Quobyte.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n109 + i += n110 } if m.AzureDisk != nil { dAtA[i] = 0x82 @@ -5621,11 +5629,11 @@ func (m *PersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.AzureDisk.Size())) - n110, err := m.AzureDisk.MarshalTo(dAtA[i:]) + n111, err := m.AzureDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n110 + i += n111 } if m.PhotonPersistentDisk != nil { dAtA[i] = 0x8a @@ -5633,11 +5641,11 @@ func (m *PersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PhotonPersistentDisk.Size())) - n111, err := m.PhotonPersistentDisk.MarshalTo(dAtA[i:]) + n112, err := m.PhotonPersistentDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n111 + i += n112 } if m.PortworxVolume != nil { dAtA[i] = 0x92 @@ -5645,11 +5653,11 @@ func (m *PersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PortworxVolume.Size())) - n112, err := m.PortworxVolume.MarshalTo(dAtA[i:]) + n113, err := m.PortworxVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n112 + i += n113 } if m.ScaleIO != nil { dAtA[i] = 0x9a @@ -5657,11 +5665,11 @@ func (m *PersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ScaleIO.Size())) - n113, err := m.ScaleIO.MarshalTo(dAtA[i:]) + n114, err := m.ScaleIO.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n113 + i += n114 } if m.Local != nil { dAtA[i] = 0xa2 @@ -5669,11 +5677,11 @@ func (m *PersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Local.Size())) - n114, err := m.Local.MarshalTo(dAtA[i:]) + n115, err := m.Local.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n114 + i += n115 } return i, nil } @@ -5712,21 +5720,21 @@ func (m *PersistentVolumeSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n115, err := (&v).MarshalTo(dAtA[i:]) + n116, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n115 + i += n116 } } dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PersistentVolumeSource.Size())) - n116, err := m.PersistentVolumeSource.MarshalTo(dAtA[i:]) + n117, err := m.PersistentVolumeSource.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n116 + i += n117 if len(m.AccessModes) > 0 { for _, s := range m.AccessModes { dAtA[i] = 0x1a @@ -5746,11 +5754,11 @@ func (m *PersistentVolumeSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ClaimRef.Size())) - n117, err := m.ClaimRef.MarshalTo(dAtA[i:]) + n118, err := m.ClaimRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n117 + i += n118 } dAtA[i] = 0x2a i++ @@ -5837,27 +5845,27 @@ func (m *Pod) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n118, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n119, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n118 + i += n119 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n119, err := m.Spec.MarshalTo(dAtA[i:]) + n120, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n119 + i += n120 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n120, err := m.Status.MarshalTo(dAtA[i:]) + n121, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n120 + i += n121 return i, nil } @@ -5922,11 +5930,11 @@ func (m *PodAffinityTerm) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LabelSelector.Size())) - n121, err := m.LabelSelector.MarshalTo(dAtA[i:]) + n122, err := m.LabelSelector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n121 + i += n122 } if len(m.Namespaces) > 0 { for _, s := range m.Namespaces { @@ -6072,19 +6080,19 @@ func (m *PodCondition) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastProbeTime.Size())) - n122, err := m.LastProbeTime.MarshalTo(dAtA[i:]) + n123, err := m.LastProbeTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n122 + i += n123 dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) - n123, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) + n124, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n123 + i += n124 dAtA[i] = 0x2a i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) @@ -6183,11 +6191,11 @@ func (m *PodList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n124, err := m.ListMeta.MarshalTo(dAtA[i:]) + n125, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n124 + i += n125 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -6247,11 +6255,11 @@ func (m *PodLogOptions) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x2a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SinceTime.Size())) - n125, err := m.SinceTime.MarshalTo(dAtA[i:]) + n126, err := m.SinceTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n125 + i += n126 } dAtA[i] = 0x30 i++ @@ -6340,11 +6348,11 @@ func (m *PodSecurityContext) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SELinuxOptions.Size())) - n126, err := m.SELinuxOptions.MarshalTo(dAtA[i:]) + n127, err := m.SELinuxOptions.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n126 + i += n127 } if m.RunAsUser != nil { dAtA[i] = 0x10 @@ -6395,11 +6403,11 @@ func (m *PodSignature) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PodController.Size())) - n127, err := m.PodController.MarshalTo(dAtA[i:]) + n128, err := m.PodController.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n127 + i += n128 } return i, nil } @@ -6518,11 +6526,11 @@ func (m *PodSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x72 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecurityContext.Size())) - n128, err := m.SecurityContext.MarshalTo(dAtA[i:]) + n129, err := m.SecurityContext.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n128 + i += n129 } if len(m.ImagePullSecrets) > 0 { for _, msg := range m.ImagePullSecrets { @@ -6554,11 +6562,11 @@ func (m *PodSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Affinity.Size())) - n129, err := m.Affinity.MarshalTo(dAtA[i:]) + n130, err := m.Affinity.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n129 + i += n130 } dAtA[i] = 0x9a i++ @@ -6674,11 +6682,11 @@ func (m *PodStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.StartTime.Size())) - n130, err := m.StartTime.MarshalTo(dAtA[i:]) + n131, err := m.StartTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n130 + i += n131 } if len(m.ContainerStatuses) > 0 { for _, msg := range m.ContainerStatuses { @@ -6729,19 +6737,19 @@ func (m *PodStatusResult) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n131, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n132, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n131 + i += n132 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n132, err := m.Status.MarshalTo(dAtA[i:]) + n133, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n132 + i += n133 return i, nil } @@ -6763,19 +6771,19 @@ func (m *PodTemplate) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n133, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n134, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n133 + i += n134 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) - n134, err := m.Template.MarshalTo(dAtA[i:]) + n135, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n134 + i += n135 return i, nil } @@ -6797,11 +6805,11 @@ func (m *PodTemplateList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n135, err := m.ListMeta.MarshalTo(dAtA[i:]) + n136, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n135 + i += n136 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -6835,19 +6843,19 @@ func (m *PodTemplateSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n136, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n137, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n136 + i += n137 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n137, err := m.Spec.MarshalTo(dAtA[i:]) + n138, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n137 + i += n138 return i, nil } @@ -6927,19 +6935,19 @@ func (m *PreferAvoidPodsEntry) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PodSignature.Size())) - n138, err := m.PodSignature.MarshalTo(dAtA[i:]) + n139, err := m.PodSignature.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n138 + i += n139 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.EvictionTime.Size())) - n139, err := m.EvictionTime.MarshalTo(dAtA[i:]) + n140, err := m.EvictionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n139 + i += n140 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) @@ -6972,11 +6980,11 @@ func (m *PreferredSchedulingTerm) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Preference.Size())) - n140, err := m.Preference.MarshalTo(dAtA[i:]) + n141, err := m.Preference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n140 + i += n141 return i, nil } @@ -6998,11 +7006,11 @@ func (m *Probe) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Handler.Size())) - n141, err := m.Handler.MarshalTo(dAtA[i:]) + n142, err := m.Handler.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n141 + i += n142 dAtA[i] = 0x10 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.InitialDelaySeconds)) @@ -7152,11 +7160,11 @@ func (m *RBDVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) - n142, err := m.SecretRef.MarshalTo(dAtA[i:]) + n143, err := m.SecretRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n142 + i += n143 } dAtA[i] = 0x40 i++ @@ -7187,11 +7195,11 @@ func (m *RangeAllocation) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n143, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n144, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n143 + i += n144 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Range))) @@ -7223,27 +7231,27 @@ func (m *ReplicationController) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n144, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n145, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n144 + i += n145 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n145, err := m.Spec.MarshalTo(dAtA[i:]) + n146, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n145 + i += n146 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n146, err := m.Status.MarshalTo(dAtA[i:]) + n147, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n146 + i += n147 return i, nil } @@ -7273,11 +7281,11 @@ func (m *ReplicationControllerCondition) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) - n147, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) + n148, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n147 + i += n148 dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) @@ -7307,11 +7315,11 @@ func (m *ReplicationControllerList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n148, err := m.ListMeta.MarshalTo(dAtA[i:]) + n149, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n148 + i += n149 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -7368,11 +7376,11 @@ func (m *ReplicationControllerSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) - n149, err := m.Template.MarshalTo(dAtA[i:]) + n150, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n149 + i += n150 } dAtA[i] = 0x20 i++ @@ -7451,11 +7459,11 @@ func (m *ResourceFieldSelector) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Divisor.Size())) - n150, err := m.Divisor.MarshalTo(dAtA[i:]) + n151, err := m.Divisor.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n150 + i += n151 return i, nil } @@ -7477,27 +7485,27 @@ func (m *ResourceQuota) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n151, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n152, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n151 + i += n152 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n152, err := m.Spec.MarshalTo(dAtA[i:]) + n153, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n152 + i += n153 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n153, err := m.Status.MarshalTo(dAtA[i:]) + n154, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n153 + i += n154 return i, nil } @@ -7519,11 +7527,11 @@ func (m *ResourceQuotaList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n154, err := m.ListMeta.MarshalTo(dAtA[i:]) + n155, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n154 + i += n155 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -7573,11 +7581,11 @@ func (m *ResourceQuotaSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n155, err := (&v).MarshalTo(dAtA[i:]) + n156, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n155 + i += n156 } } if len(m.Scopes) > 0 { @@ -7632,11 +7640,11 @@ func (m *ResourceQuotaStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n156, err := (&v).MarshalTo(dAtA[i:]) + n157, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n156 + i += n157 } } if len(m.Used) > 0 { @@ -7658,11 +7666,11 @@ func (m *ResourceQuotaStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n157, err := (&v).MarshalTo(dAtA[i:]) + n158, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n157 + i += n158 } } return i, nil @@ -7702,11 +7710,11 @@ func (m *ResourceRequirements) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n158, err := (&v).MarshalTo(dAtA[i:]) + n159, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n158 + i += n159 } } if len(m.Requests) > 0 { @@ -7728,11 +7736,11 @@ func (m *ResourceRequirements) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) - n159, err := (&v).MarshalTo(dAtA[i:]) + n160, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n159 + i += n160 } } return i, nil @@ -7799,11 +7807,11 @@ func (m *ScaleIOVolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) - n160, err := m.SecretRef.MarshalTo(dAtA[i:]) + n161, err := m.SecretRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n160 + i += n161 } dAtA[i] = 0x20 i++ @@ -7862,11 +7870,11 @@ func (m *Secret) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n161, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n162, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n161 + i += n162 if len(m.Data) > 0 { for k := range m.Data { dAtA[i] = 0x12 @@ -7932,11 +7940,11 @@ func (m *SecretEnvSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LocalObjectReference.Size())) - n162, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) + n163, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n162 + i += n163 if m.Optional != nil { dAtA[i] = 0x10 i++ @@ -7968,11 +7976,11 @@ func (m *SecretKeySelector) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LocalObjectReference.Size())) - n163, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) + n164, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n163 + i += n164 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Key))) @@ -8008,11 +8016,11 @@ func (m *SecretList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n164, err := m.ListMeta.MarshalTo(dAtA[i:]) + n165, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n164 + i += n165 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -8046,11 +8054,11 @@ func (m *SecretProjection) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LocalObjectReference.Size())) - n165, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) + n166, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n165 + i += n166 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -8144,11 +8152,11 @@ func (m *SecurityContext) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Capabilities.Size())) - n166, err := m.Capabilities.MarshalTo(dAtA[i:]) + n167, err := m.Capabilities.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n166 + i += n167 } if m.Privileged != nil { dAtA[i] = 0x10 @@ -8164,11 +8172,11 @@ func (m *SecurityContext) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.SELinuxOptions.Size())) - n167, err := m.SELinuxOptions.MarshalTo(dAtA[i:]) + n168, err := m.SELinuxOptions.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n167 + i += n168 } if m.RunAsUser != nil { dAtA[i] = 0x20 @@ -8216,11 +8224,11 @@ func (m *SerializedReference) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Reference.Size())) - n168, err := m.Reference.MarshalTo(dAtA[i:]) + n169, err := m.Reference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n168 + i += n169 return i, nil } @@ -8242,27 +8250,27 @@ func (m *Service) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n169, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n170, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n169 + i += n170 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n170, err := m.Spec.MarshalTo(dAtA[i:]) + n171, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n170 + i += n171 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n171, err := m.Status.MarshalTo(dAtA[i:]) + n172, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n171 + i += n172 return i, nil } @@ -8284,11 +8292,11 @@ func (m *ServiceAccount) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n172, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n173, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n172 + i += n173 if len(m.Secrets) > 0 { for _, msg := range m.Secrets { dAtA[i] = 0x12 @@ -8344,11 +8352,11 @@ func (m *ServiceAccountList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n173, err := m.ListMeta.MarshalTo(dAtA[i:]) + n174, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n173 + i += n174 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -8382,11 +8390,11 @@ func (m *ServiceList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n174, err := m.ListMeta.MarshalTo(dAtA[i:]) + n175, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n174 + i += n175 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -8431,11 +8439,11 @@ func (m *ServicePort) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.TargetPort.Size())) - n175, err := m.TargetPort.MarshalTo(dAtA[i:]) + n176, err := m.TargetPort.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n175 + i += n176 dAtA[i] = 0x28 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.NodePort)) @@ -8586,11 +8594,11 @@ func (m *ServiceStatus) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LoadBalancer.Size())) - n176, err := m.LoadBalancer.MarshalTo(dAtA[i:]) + n177, err := m.LoadBalancer.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n176 + i += n177 return i, nil } @@ -8638,11 +8646,11 @@ func (m *TCPSocketAction) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Port.Size())) - n177, err := m.Port.MarshalTo(dAtA[i:]) + n178, err := m.Port.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n177 + i += n178 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(len(m.Host))) @@ -8680,11 +8688,11 @@ func (m *Taint) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.TimeAdded.Size())) - n178, err := m.TimeAdded.MarshalTo(dAtA[i:]) + n179, err := m.TimeAdded.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n178 + i += n179 return i, nil } @@ -8749,11 +8757,11 @@ func (m *Volume) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.VolumeSource.Size())) - n179, err := m.VolumeSource.MarshalTo(dAtA[i:]) + n180, err := m.VolumeSource.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n179 + i += n180 return i, nil } @@ -8814,31 +8822,31 @@ func (m *VolumeProjection) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Secret.Size())) - n180, err := m.Secret.MarshalTo(dAtA[i:]) + n181, err := m.Secret.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n180 + i += n181 } if m.DownwardAPI != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.DownwardAPI.Size())) - n181, err := m.DownwardAPI.MarshalTo(dAtA[i:]) + n182, err := m.DownwardAPI.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n181 + i += n182 } if m.ConfigMap != nil { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ConfigMap.Size())) - n182, err := m.ConfigMap.MarshalTo(dAtA[i:]) + n183, err := m.ConfigMap.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n182 + i += n183 } return i, nil } @@ -8862,151 +8870,151 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.HostPath.Size())) - n183, err := m.HostPath.MarshalTo(dAtA[i:]) + n184, err := m.HostPath.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n183 + i += n184 } if m.EmptyDir != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.EmptyDir.Size())) - n184, err := m.EmptyDir.MarshalTo(dAtA[i:]) + n185, err := m.EmptyDir.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n184 + i += n185 } if m.GCEPersistentDisk != nil { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.GCEPersistentDisk.Size())) - n185, err := m.GCEPersistentDisk.MarshalTo(dAtA[i:]) + n186, err := m.GCEPersistentDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n185 + i += n186 } if m.AWSElasticBlockStore != nil { dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.AWSElasticBlockStore.Size())) - n186, err := m.AWSElasticBlockStore.MarshalTo(dAtA[i:]) + n187, err := m.AWSElasticBlockStore.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n186 + i += n187 } if m.GitRepo != nil { dAtA[i] = 0x2a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.GitRepo.Size())) - n187, err := m.GitRepo.MarshalTo(dAtA[i:]) + n188, err := m.GitRepo.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n187 + i += n188 } if m.Secret != nil { dAtA[i] = 0x32 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Secret.Size())) - n188, err := m.Secret.MarshalTo(dAtA[i:]) + n189, err := m.Secret.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n188 + i += n189 } if m.NFS != nil { dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.NFS.Size())) - n189, err := m.NFS.MarshalTo(dAtA[i:]) + n190, err := m.NFS.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n189 + i += n190 } if m.ISCSI != nil { dAtA[i] = 0x42 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ISCSI.Size())) - n190, err := m.ISCSI.MarshalTo(dAtA[i:]) + n191, err := m.ISCSI.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n190 + i += n191 } if m.Glusterfs != nil { dAtA[i] = 0x4a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Glusterfs.Size())) - n191, err := m.Glusterfs.MarshalTo(dAtA[i:]) + n192, err := m.Glusterfs.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n191 + i += n192 } if m.PersistentVolumeClaim != nil { dAtA[i] = 0x52 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PersistentVolumeClaim.Size())) - n192, err := m.PersistentVolumeClaim.MarshalTo(dAtA[i:]) + n193, err := m.PersistentVolumeClaim.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n192 + i += n193 } if m.RBD != nil { dAtA[i] = 0x5a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.RBD.Size())) - n193, err := m.RBD.MarshalTo(dAtA[i:]) + n194, err := m.RBD.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n193 + i += n194 } if m.FlexVolume != nil { dAtA[i] = 0x62 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.FlexVolume.Size())) - n194, err := m.FlexVolume.MarshalTo(dAtA[i:]) + n195, err := m.FlexVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n194 + i += n195 } if m.Cinder != nil { dAtA[i] = 0x6a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Cinder.Size())) - n195, err := m.Cinder.MarshalTo(dAtA[i:]) + n196, err := m.Cinder.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n195 + i += n196 } if m.CephFS != nil { dAtA[i] = 0x72 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.CephFS.Size())) - n196, err := m.CephFS.MarshalTo(dAtA[i:]) + n197, err := m.CephFS.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n196 + i += n197 } if m.Flocker != nil { dAtA[i] = 0x7a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Flocker.Size())) - n197, err := m.Flocker.MarshalTo(dAtA[i:]) + n198, err := m.Flocker.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n197 + i += n198 } if m.DownwardAPI != nil { dAtA[i] = 0x82 @@ -9014,11 +9022,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.DownwardAPI.Size())) - n198, err := m.DownwardAPI.MarshalTo(dAtA[i:]) + n199, err := m.DownwardAPI.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n198 + i += n199 } if m.FC != nil { dAtA[i] = 0x8a @@ -9026,11 +9034,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.FC.Size())) - n199, err := m.FC.MarshalTo(dAtA[i:]) + n200, err := m.FC.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n199 + i += n200 } if m.AzureFile != nil { dAtA[i] = 0x92 @@ -9038,11 +9046,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.AzureFile.Size())) - n200, err := m.AzureFile.MarshalTo(dAtA[i:]) + n201, err := m.AzureFile.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n200 + i += n201 } if m.ConfigMap != nil { dAtA[i] = 0x9a @@ -9050,11 +9058,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ConfigMap.Size())) - n201, err := m.ConfigMap.MarshalTo(dAtA[i:]) + n202, err := m.ConfigMap.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n201 + i += n202 } if m.VsphereVolume != nil { dAtA[i] = 0xa2 @@ -9062,11 +9070,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.VsphereVolume.Size())) - n202, err := m.VsphereVolume.MarshalTo(dAtA[i:]) + n203, err := m.VsphereVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n202 + i += n203 } if m.Quobyte != nil { dAtA[i] = 0xaa @@ -9074,11 +9082,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Quobyte.Size())) - n203, err := m.Quobyte.MarshalTo(dAtA[i:]) + n204, err := m.Quobyte.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n203 + i += n204 } if m.AzureDisk != nil { dAtA[i] = 0xb2 @@ -9086,11 +9094,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.AzureDisk.Size())) - n204, err := m.AzureDisk.MarshalTo(dAtA[i:]) + n205, err := m.AzureDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n204 + i += n205 } if m.PhotonPersistentDisk != nil { dAtA[i] = 0xba @@ -9098,11 +9106,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PhotonPersistentDisk.Size())) - n205, err := m.PhotonPersistentDisk.MarshalTo(dAtA[i:]) + n206, err := m.PhotonPersistentDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n205 + i += n206 } if m.PortworxVolume != nil { dAtA[i] = 0xc2 @@ -9110,11 +9118,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PortworxVolume.Size())) - n206, err := m.PortworxVolume.MarshalTo(dAtA[i:]) + n207, err := m.PortworxVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n206 + i += n207 } if m.ScaleIO != nil { dAtA[i] = 0xca @@ -9122,11 +9130,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ScaleIO.Size())) - n207, err := m.ScaleIO.MarshalTo(dAtA[i:]) + n208, err := m.ScaleIO.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n207 + i += n208 } if m.Projected != nil { dAtA[i] = 0xd2 @@ -9134,11 +9142,11 @@ func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Projected.Size())) - n208, err := m.Projected.MarshalTo(dAtA[i:]) + n209, err := m.Projected.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n208 + i += n209 } return i, nil } @@ -9198,11 +9206,11 @@ func (m *WeightedPodAffinityTerm) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.PodAffinityTerm.Size())) - n209, err := m.PodAffinityTerm.MarshalTo(dAtA[i:]) + n210, err := m.PodAffinityTerm.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n209 + i += n210 return i, nil } @@ -9770,6 +9778,8 @@ func (m *EmptyDirVolumeSource) Size() (n int) { _ = l l = len(m.Medium) n += 1 + l + sovGenerated(uint64(l)) + l = m.SizeLimit.Size() + n += 1 + l + sovGenerated(uint64(l)) return n } @@ -12642,6 +12652,7 @@ func (this *EmptyDirVolumeSource) String() string { } s := strings.Join([]string{`&EmptyDirVolumeSource{`, `Medium:` + fmt.Sprintf("%v", this.Medium) + `,`, + `SizeLimit:` + strings.Replace(strings.Replace(this.SizeLimit.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -19602,6 +19613,36 @@ func (m *EmptyDirVolumeSource) Unmarshal(dAtA []byte) error { } m.Medium = StorageMedium(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SizeLimit", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.SizeLimit.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -43577,715 +43618,715 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 11348 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0xbd, 0x7d, 0x8c, 0x24, 0xc7, - 0x75, 0x18, 0xae, 0x9e, 0xd9, 0xaf, 0x79, 0xfb, 0x5d, 0xb7, 0x77, 0x5c, 0xae, 0xc8, 0xdb, 0x63, - 0x53, 0xa4, 0x8f, 0xe4, 0x71, 0x4f, 0x77, 0x24, 0xc5, 0x93, 0xa8, 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ff, 0x55, 0xd7, 0x6f, 0xee, 0xef, 0xce, 0x4f, 0x1b, 0xdd, 0xa1, 0x85, 0x98, 0xa1, 0xda, 0xff, - 0xc8, 0x12, 0xd3, 0xb8, 0xea, 0x7a, 0x26, 0x47, 0xb9, 0x08, 0x10, 0x91, 0x46, 0x48, 0x62, 0x6d, - 0x22, 0xd5, 0xca, 0xa8, 0x2b, 0x08, 0xd6, 0xb0, 0x28, 0xbf, 0x88, 0x36, 0x9d, 0x90, 0x2d, 0x30, - 0x31, 0x9d, 0x8a, 0x5f, 0xd4, 0x25, 0x00, 0x27, 0x38, 0x06, 0xbf, 0x28, 0xe7, 0xf2, 0x8b, 0xdf, - 0xb2, 0x60, 0x78, 0xc9, 0xf5, 0x9b, 0xae, 0xdf, 0x42, 0x6f, 0xc3, 0x08, 0x3d, 0x04, 0x9a, 0x4e, - 0xec, 0x08, 0x56, 0xf1, 0x61, 0xb9, 0xde, 0x74, 0x9e, 0x2c, 0x57, 0x5c, 0xb4, 0x40, 0xb1, 0xe9, - 0xba, 0xbb, 0x79, 0xf7, 0x1d, 0xd2, 0x88, 0xaf, 0x93, 0xd8, 0x49, 0x86, 0x93, 0x94, 0x61, 0x45, - 0x15, 0xdd, 0x82, 0xa1, 0xd8, 0x09, 0x5b, 0x24, 0x16, 0x9c, 0x22, 0x67, 0x1f, 0x73, 0x1a, 0x98, - 0xae, 0x52, 0xe2, 0x37, 0x48, 0xc2, 0x53, 0xd7, 0x19, 0x11, 0x2c, 0x88, 0xd9, 0x0d, 0x18, 0x5b, - 0x76, 0xda, 0xce, 0x5d, 0xd7, 0x73, 0x63, 0x97, 0x44, 0xe8, 0xe7, 0xa0, 0xec, 0x34, 0x9b, 0x6c, - 0xcf, 0x54, 0x96, 0x4e, 0xee, 0xed, 0xce, 0x97, 0x17, 0x9b, 0xf4, 0x93, 0x81, 0xc2, 0xda, 0xc1, - 0x14, 0x03, 0x3d, 0x0b, 0x03, 0xcd, 0x30, 0x68, 0xcf, 0x96, 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, 0x90, 0x41, 0xae, 0x99, 0x56, - 0x93, 0x62, 0xac, 0xe3, 0xf4, 0x31, 0x97, 0xdf, 0x18, 0x65, 0xfc, 0x3c, 0x76, 0xe8, 0xaa, 0xa7, - 0x12, 0x9e, 0xa6, 0x51, 0x8e, 0xe9, 0x1a, 0xa5, 0xd0, 0x1e, 0x9f, 0x84, 0x41, 0x77, 0x8b, 0x9e, - 0xf9, 0x25, 0xf3, 0x28, 0x5f, 0xa3, 0x85, 0x98, 0xc3, 0xd0, 0x53, 0x30, 0xdc, 0x08, 0xb6, 0xb6, - 0x1c, 0xbf, 0x39, 0x5b, 0x66, 0x32, 0xe7, 0x28, 0x15, 0x0b, 0x96, 0x79, 0x11, 0x96, 0x30, 0xf4, - 0x18, 0x0c, 0x38, 0x61, 0x2b, 0x9a, 0x1d, 0x60, 0x38, 0x23, 0xb4, 0xa5, 0xc5, 0xb0, 0x15, 0x61, - 0x56, 0x4a, 0x65, 0xc9, 0xfb, 0x41, 0x78, 0xcf, 0xf5, 0x5b, 0x55, 0x37, 0x64, 0x82, 0xa1, 0x26, - 0x4b, 0xde, 0x51, 0x10, 0xac, 0x61, 0xa1, 0x1a, 0x0c, 0xb6, 0x83, 0x30, 0x8e, 0x66, 0x87, 0xd8, - 0xc4, 0x3f, 0x97, 0xbb, 0xfd, 0xf8, 0xb8, 0x6b, 0x41, 0x18, 0x27, 0x43, 0xa1, 0xff, 0x22, 0xcc, - 0x09, 0xa1, 0x65, 0x28, 0x13, 0x7f, 0x7b, 0x76, 0x98, 0xd1, 0xfb, 0xd0, 0xc1, 0xf4, 0x56, 0xfc, - 0xed, 0xdb, 0x4e, 0x98, 0xf0, 0xab, 0x15, 0x7f, 0x1b, 0xd3, 0xda, 0xa8, 0x01, 0x15, 0x69, 0xf5, - 0x8a, 0x66, 0x47, 0x8a, 0x2c, 0x45, 0x2c, 0xd0, 0x31, 0x79, 0xb7, 0xe3, 0x86, 0x64, 0x8b, 0xf8, - 0x71, 0x94, 0x28,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x93, 0x11, 0x69, 0x74, 0x42, 0x37, 0xde, 0xa1, 0x6b, - 0x9f, 0x3c, 0x88, 0x67, 0x27, 0x8b, 0x28, 0xba, 0x75, 0xb3, 0x12, 0x37, 0x58, 0xa5, 0x0a, 0x71, - 0x9a, 0x34, 0x65, 0x15, 0x51, 0xdc, 0x74, 0xfd, 0xd9, 0x29, 0xc6, 0x81, 0xd4, 0xfe, 0xaa, 0xd3, - 0x42, 0xcc, 0x61, 0xcc, 0x7e, 0x40, 0x7f, 0xdc, 0xa4, 0x5c, 0x7a, 0x9a, 0x21, 0x26, 0xf6, 0x03, - 0x09, 0xc0, 0x09, 0x0e, 0x15, 0x0d, 0xe2, 0x78, 0x67, 0x16, 0x31, 0x54, 0xb5, 0xd5, 0xd6, 0xd7, - 0x3f, 0x85, 0x69, 0x39, 0xba, 0x0d, 0xc3, 0xc4, 0xdf, 0x5e, 0x0d, 0x83, 0xad, 0xd9, 0x13, 0x45, - 0x78, 0xc0, 0x0a, 0x47, 0xe6, 0xe7, 0x47, 0xa2, 0xc2, 0x88, 0x62, 0x2c, 0x89, 0xa1, 0x07, 0x30, - 0x9b, 0xf1, 0x95, 0xf8, 0x47, 0x99, 0x61, 0x1f, 0xe5, 0xe3, 0xa2, 0xee, 0xec, 0x7a, 0x0f, 0xbc, - 0xfd, 0x03, 0x60, 0xb8, 0x27, 0x75, 0xfb, 0x2e, 0x4c, 0x28, 0x46, 0xc5, 0xbe, 0x37, 0x9a, 0x87, - 0x41, 0xca, 0x8b, 0xa5, 0x42, 0x5f, 0xa1, 0x93, 0x4a, 0x59, 0x74, 0x84, 0x79, 0x39, 0x9b, 0x54, - 0xf7, 0xb3, 0x64, 0x69, 0x27, 0x26, 0x5c, 0xb1, 0x2b, 0x6b, 0x93, 0x2a, 0x01, 0x38, 0xc1, 0xb1, - 0xff, 0x0f, 0x17, 0x93, 0x12, 0x6e, 0x58, 0xe0, 0x24, 0x38, 0x07, 0x23, 0x9b, 0x41, 0x14, 0x53, - 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 0x92, 0xe4, 0x81, 0x1b, 0x2f, 0x53, 0x31, 0xc9, 0x32, 0x97, - 0xe4, 0x8a, 0x28, 0xc7, 0x0a, 0x83, 0xae, 0x8d, 0xc8, 0x6d, 0x49, 0x65, 0x69, 0x30, 0x59, 0x1b, + // 11352 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x7d, 0x6d, 0x8c, 0x24, 0xc7, + 0x75, 0x98, 0x7a, 0x66, 0xbf, 0xe6, 0xed, 0x77, 0xdd, 0xde, 0x71, 0xb9, 0x22, 0x6f, 0x8f, 0x4d, + 0x91, 0x3e, 0x92, 0xc7, 0x3d, 0xdd, 0x91, 0x14, 0x4f, 0xa2, 0x42, 0x69, 0x77, 0x67, 0xf7, 0x6e, + 0x75, 0xb7, 0x77, 0xc3, 0x9a, 0xbd, 0x3b, 0x8a, 0x62, 0x44, 0xf6, 0x4d, 0xd7, 0xee, 0x36, 0x6f, + 0xb6, 0x7b, 0xd8, 0xdd, 0xb3, 0x77, 0x4b, 0x41, 0x80, 0xad, 0x08, 0x92, 0x02, 0x28, 0x89, 0x02, + 0x47, 0x40, 0xe0, 0x04, 0x50, 0x60, 0x20, 0x8e, 0xf2, 0x69, 0x2b, 0x82, 0x3e, 0x0c, 0xcb, 0x09, + 0xe2, 0x58, 0x8e, 0x0c, 0x24, 0x8e, 0x01, 0x23, 0xb6, 0x03, 0xc3, 0x6b, 0x6b, 0x85, 0xf8, 0x5f, + 0x82, 0x20, 0xf9, 0xb7, 0xf9, 0x40, 0x50, 0x9f, 0x5d, 0xd5, 0xd3, 0xb3, 0xdd, 0xb3, 0xbc, 0x5d, + 0x9f, 0x84, 0xfc, 0x9b, 0xa9, 0xf7, 0xea, 0x55, 0x75, 0x7d, 0xbc, 0x7a, 0xef, 0xd5, 0x7b, 0xaf, + 0xe0, 0xdc, 0xdd, 0x4b, 0xd1, 0x9c, 0x17, 0x9c, 0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, 0x36, 0xc3, 0x95, 0x85, 0xe7, 0x28, 0xfa, + 0x62, 0x52, 0xbc, 0xbf, 0x3b, 0x3b, 0xcd, 0xfb, 0x26, 0x48, 0x68, 0x30, 0xac, 0xd7, 0x47, 0xb6, + 0xda, 0x88, 0x7d, 0x8c, 0x12, 0x64, 0x6c, 0xc2, 0xb3, 0xda, 0x9e, 0xea, 0x67, 0x7b, 0x6a, 0x24, + 0x7b, 0x3f, 0xa1, 0x0b, 0xd0, 0x77, 0xd7, 0xf3, 0xdd, 0xe9, 0x01, 0x46, 0xeb, 0x71, 0x3a, 0xfd, + 0x57, 0x3d, 0xdf, 0xdd, 0xdf, 0x9d, 0x9d, 0x34, 0xba, 0x43, 0x0b, 0x31, 0x43, 0xb5, 0xff, 0x89, + 0x25, 0x86, 0x71, 0xd9, 0x6b, 0x9a, 0x1c, 0xe5, 0x22, 0x40, 0x44, 0x1a, 0x21, 0x89, 0xb5, 0x81, + 0x54, 0x2b, 0xa3, 0xae, 0x20, 0x58, 0xc3, 0xa2, 0xfc, 0x22, 0xda, 0x74, 0x42, 0xb6, 0xc0, 0xc4, + 0x70, 0x2a, 0x7e, 0x51, 0x97, 0x00, 0x9c, 0xe0, 0x18, 0xfc, 0xa2, 0x9c, 0xcb, 0x2f, 0x7e, 0xcb, + 0x82, 0xc1, 0x05, 0xcf, 0x77, 0x3d, 0x7f, 0x03, 0xbd, 0x0d, 0x43, 0x94, 0x9d, 0xbb, 0x4e, 0xec, + 0x08, 0x56, 0xf1, 0x61, 0xb9, 0xde, 0x74, 0xee, 0x2a, 0x57, 0x5c, 0x34, 0x47, 0xb1, 0xe9, 0xba, + 0xbb, 0x71, 0xe7, 0x1d, 0xd2, 0x88, 0x57, 0x49, 0xec, 0x24, 0x9f, 0x93, 0x94, 0x61, 0x45, 0x15, + 0xdd, 0x84, 0x81, 0xd8, 0x09, 0x37, 0x48, 0x2c, 0x38, 0x45, 0xce, 0x3e, 0xe6, 0x34, 0x30, 0x5d, + 0xa5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 0xed, 0x3b, 0x30, 0xa6, 0x18, 0x15, 0x9b, 0x6f, 0x34, 0x0b, + 0xfd, 0x94, 0x17, 0x4b, 0x85, 0xbe, 0x42, 0x07, 0x95, 0xb2, 0xe8, 0x08, 0xf3, 0x72, 0x36, 0xa8, + 0xde, 0x7b, 0x64, 0x61, 0x27, 0x26, 0x5c, 0xb1, 0x2b, 0x6b, 0x83, 0x2a, 0x01, 0x38, 0xc1, 0xb1, + 0xff, 0x2f, 0x17, 0x93, 0x12, 0x6e, 0x58, 0xe0, 0x24, 0x38, 0x07, 0x43, 0x9b, 0x41, 0x14, 0x53, + 0x6c, 0xd6, 0x46, 0x7f, 0x22, 0x18, 0x5d, 0x11, 0xe5, 0x58, 0x61, 0xa0, 0x57, 0x60, 0xb4, 0xa1, + 0x37, 0x20, 0x8e, 0xb1, 0x93, 0xa2, 0x8a, 0xd9, 0x3a, 0x36, 0x71, 0xd1, 0x25, 0x18, 0x62, 0x86, + 0xf1, 0x46, 0xd0, 0x14, 0x2a, 0xa4, 0x3c, 0x95, 0x87, 0x6a, 0xa2, 0x7c, 0x5f, 0xfb, 0x8d, 0x15, + 0x36, 0x55, 0xc4, 0x69, 0x17, 0x56, 0x6a, 0xe2, 0x00, 0x51, 0x8a, 0xf8, 0x15, 0x56, 0x8a, 0x05, + 0xd4, 0xfe, 0xb5, 0x92, 0x36, 0xca, 0x54, 0x01, 0x22, 0xe8, 0x0d, 0x18, 0xbc, 0xe7, 0x78, 0xb1, + 0xe7, 0x6f, 0x08, 0xe9, 0xe1, 0x85, 0x82, 0xa7, 0x09, 0xab, 0x7e, 0x9b, 0x57, 0xe5, 0x27, 0x9f, + 0xf8, 0x83, 0x25, 0x41, 0x4a, 0x3b, 0x6c, 0xfb, 0x3e, 0xa5, 0x5d, 0xea, 0x9d, 0x36, 0xe6, 0x55, + 0x39, 0x6d, 0xf1, 0x07, 0x4b, 0x82, 0x68, 0x1d, 0x40, 0xae, 0x25, 0xe2, 0x0a, 0x83, 0xf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xfa, 0x33, 0x33, 0x05, 0xb0, 0x52, 0xfb, 0x57, 0x2d, 0x78, 0xa4, 0x6b, 0xb6, 0x84, - 0x9d, 0xe4, 0xc8, 0xbe, 0x51, 0xda, 0x58, 0x51, 0xca, 0x37, 0x56, 0xd8, 0x37, 0x61, 0x66, 0x65, - 0xab, 0x1d, 0xef, 0x54, 0x5d, 0xf3, 0xca, 0xe5, 0x65, 0x18, 0xda, 0x22, 0x4d, 0xb7, 0xb3, 0x25, - 0x3e, 0xeb, 0xbc, 0x3c, 0x17, 0xae, 0xb3, 0xd2, 0xfd, 0xdd, 0xf9, 0xf1, 0x7a, 0x1c, 0x84, 0x4e, - 0x8b, 0xf0, 0x02, 0x2c, 0xd0, 0xed, 0x1f, 0x5b, 0x30, 0x29, 0xf9, 0xc3, 0x62, 0xb3, 0x19, 0x92, - 0x28, 0x42, 0x73, 0x50, 0x72, 0xdb, 0x82, 0x10, 0x08, 0x42, 0xa5, 0xb5, 0x1a, 0x2e, 0xb9, 0x6d, - 0xf4, 0x06, 0x54, 0xf8, 0x4d, 0x5d, 0xb2, 0x38, 0xfa, 0xbc, 0xf9, 0x63, 0xba, 0xe1, 0xba, 0xa4, - 0x81, 0x13, 0x72, 0x52, 0x4a, 0x66, 0x27, 0x4f, 0xd9, 0xbc, 0x37, 0xba, 0x22, 0xca, 0xb1, 0xc2, - 0x40, 0x67, 0x61, 0xc4, 0x0f, 0x9a, 0xfc, 0x32, 0x95, 0xef, 0x53, 0xb6, 0xe4, 0x6e, 0x88, 0x32, - 0xac, 0xa0, 0xf6, 0x57, 0x2d, 0x18, 0x93, 0x63, 0x2c, 0x28, 0xb0, 0xd3, 0x4d, 0x92, 0x08, 0xeb, - 0xc9, 0x26, 0xa1, 0x02, 0x37, 0x83, 0x18, 0x72, 0x76, 0xb9, 0x1f, 0x39, 0xdb, 0xfe, 0xf5, 0x12, - 0x4c, 0xc8, 0xee, 0xd4, 0x3b, 0x77, 0x23, 0x42, 0xc5, 0x90, 0x8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3f, 0x97, 0x3f, 0x0b, 0x6a, 0x51, 0xf0, - 0x93, 0x52, 0x14, 0x61, 0x49, 0x88, 0x59, 0xa0, 0x1a, 0xed, 0x3a, 0x65, 0x6f, 0x71, 0x31, 0xcd, - 0x6e, 0x7d, 0xb9, 0xc6, 0xd1, 0x05, 0x5d, 0x6e, 0x81, 0x92, 0x85, 0x38, 0x21, 0x67, 0xaf, 0x43, - 0x85, 0x7e, 0xfc, 0x45, 0xcf, 0x75, 0x0e, 0x36, 0x83, 0x3d, 0x07, 0x15, 0x69, 0x88, 0x8a, 0x84, - 0xcb, 0x39, 0xa3, 0x2a, 0xed, 0x54, 0x11, 0x4e, 0xe0, 0xf6, 0x25, 0x98, 0x61, 0xb7, 0xbc, 0x4e, - 0xbc, 0x69, 0xec, 0xc5, 0xdc, 0x45, 0x6f, 0x7f, 0x67, 0x00, 0xa6, 0xd7, 0xea, 0xcb, 0x75, 0xd3, - 0x22, 0x79, 0x09, 0xc6, 0xf8, 0xb1, 0x4f, 0x97, 0xb2, 0xe3, 0x89, 0xfa, 0xea, 0x66, 0x62, 0x5d, - 0x83, 0x61, 0x03, 0x13, 0x3d, 0x0e, 0x65, 0xf7, 0x5d, 0x3f, 0xed, 0x2b, 0xb8, 0xf6, 0xda, 0x0d, - 0x4c, 0xcb, 0x29, 0x98, 0x4a, 0x10, 0x9c, 0x75, 0x2a, 0xb0, 0x92, 0x22, 0x5e, 0x85, 0x09, 0x37, - 0x6a, 0x44, 0xee, 0x9a, 0x4f, 0xf9, 0x8a, 0xd3, 0x90, 0x9b, 0x22, 0x11, 0xf9, 0x69, 0x57, 0x15, - 0x14, 0xa7, 0xb0, 0x35, 0x3e, 0x3e, 0x58, 0x58, 0x0a, 0xc9, 0x75, 0x42, 0xa7, 0x02, 0x56, 0x9b, - 0x8d, 0x2e, 0x62, 0x9e, 0x47, 0x42, 0xc0, 0xe2, 0x03, 0x8e, 0xb0, 0x84, 0xa1, 0xcb, 0x30, 0xdd, - 0xd8, 0x74, 0xda, 0x8b, 0x9d, 0x78, 0xb3, 0xea, 0x46, 0x8d, 0x60, 0x9b, 0x84, 0x3b, 0x4c, 0x00, - 0x1e, 0x49, 0x6c, 0x5a, 0x0a, 0xb0, 0x7c, 0x65, 0xb1, 0x46, 0x31, 0x71, 0x77, 0x1d, 0x53, 0x20, - 0x81, 0x23, 0x10, 0x48, 0x16, 0x61, 0x52, 0xb6, 0x5a, 0x27, 0x11, 0x3b, 0x22, 0x46, 0x59, 0x3f, - 0x55, 0xf8, 0x8f, 0x28, 0x56, 0xbd, 0x4c, 0xe3, 0xdb, 0xef, 0x40, 0x45, 0x79, 0xca, 0x49, 0x07, - 0x51, 0xab, 0x87, 0x83, 0x68, 0x3e, 0x73, 0x97, 0xb6, 0xf3, 0x72, 0xa6, 0xed, 0xfc, 0x9f, 0x5a, - 0x90, 0xb8, 0xfa, 0x20, 0x0c, 0x95, 0x76, 0xc0, 0xee, 0xd9, 0x42, 0x79, 0xa1, 0xfd, 0x54, 0xce, - 0x9e, 0xe7, 0x3c, 0x87, 0x4f, 0x48, 0x4d, 0xd6, 0xc5, 0x09, 0x19, 0x74, 0x0d, 0x86, 0xdb, 0x21, - 0xa9, 0xc7, 0x2c, 0xba, 0xa3, 0x0f, 0x8a, 0x7c, 0x21, 0xf0, 0x9a, 0x58, 0x92, 0xb0, 0xff, 0xa5, - 0x05, 0x70, 0xcd, 0xdd, 0x72, 0x63, 0xec, 0xf8, 0x2d, 0x72, 0x0c, 0x8a, 0xf5, 0x0d, 0x18, 0x88, - 0xda, 0xa4, 0x51, 0xec, 0xa6, 0x34, 0xe9, 0x59, 0xbd, 0x4d, 0x1a, 0xc9, 0xe7, 0xa0, 0xff, 0x30, - 0xa3, 0x63, 0x7f, 0x1f, 0x60, 0x22, 0x41, 0xa3, 0xca, 0x0d, 0x7a, 0xde, 0x08, 0x6b, 0x78, 0x34, - 0x15, 0xd6, 0x50, 0x61, 0xd8, 0x5a, 0x24, 0x43, 0x0c, 0xe5, 0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, 0xaf, 0x24, 0x15, 0x9d, 0x82, 0x60, 0x0d, - 0x8b, 0x4a, 0xc2, 0x77, 0x83, 0x20, 0x56, 0x27, 0x81, 0x5a, 0x37, 0x4b, 0xac, 0x14, 0x0b, 0x28, - 0x3d, 0x01, 0xee, 0xd1, 0x8f, 0xe9, 0x99, 0xe6, 0x4d, 0x75, 0x02, 0x5c, 0xd5, 0x81, 0xd8, 0xc4, - 0xa5, 0x27, 0x5a, 0x10, 0xb1, 0x85, 0x28, 0xe4, 0xed, 0xc4, 0x61, 0xae, 0xce, 0xa3, 0x29, 0x25, - 0x1c, 0x7d, 0x0a, 0x1e, 0x51, 0xc1, 0x8f, 0x98, 0x9b, 0x8b, 0x65, 0x8b, 0x43, 0x86, 0xca, 0xfc, - 0xc8, 0x72, 0x36, 0x1a, 0xee, 0x55, 0x1f, 0xbd, 0x0a, 0x13, 0x42, 0x56, 0x96, 0x14, 0x87, 0x4d, - 0xbf, 0x87, 0xab, 0x06, 0x14, 0xa7, 0xb0, 0x51, 0x15, 0xa6, 0x68, 0x09, 0x13, 0x52, 0x25, 0x05, - 0x1e, 0xc4, 0xa9, 0x8e, 0xfa, 0xab, 0x29, 0x38, 0xee, 0xaa, 0x81, 0x16, 0x61, 0x92, 0x0b, 0x2b, - 0x54, 0x31, 0x64, 0xdf, 0x41, 0xf8, 0xe6, 0xaa, 0x8d, 0x70, 0xd3, 0x04, 0xe3, 0x34, 0x3e, 0xba, - 0x04, 0x63, 0x4e, 0xd8, 0xd8, 0x74, 0x63, 0xd2, 0x88, 0x3b, 0x21, 0x4f, 0x48, 0xa2, 0x39, 0x8e, - 0x2c, 0x6a, 0x30, 0x6c, 0x60, 0xda, 0x9f, 0x85, 0x13, 0x19, 0x81, 0x00, 0x74, 0xe1, 0x38, 0x6d, - 0x57, 0x8e, 0x29, 0xe5, 0xfa, 0xb6, 0x58, 0x5b, 0x93, 0xa3, 0xd1, 0xb0, 0xe8, 0xea, 0x64, 0x76, - 0x72, 0x2d, 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, 0x43, 0xec, 0x82, 0x29, 0x9a, 0x1d, 0x65, - 0x27, 0xde, 0x8b, 0x45, 0x62, 0x2b, 0xe8, 0xaa, 0x5f, 0x60, 0xd7, 0x54, 0xc2, 0x6b, 0x38, 0xb9, - 0xb5, 0x63, 0x85, 0x58, 0xd0, 0x44, 0x6d, 0x18, 0x75, 0x7c, 0x3f, 0x88, 0x1d, 0x2e, 0x88, 0x8d, - 0x15, 0x91, 0x25, 0xb5, 0x26, 0x16, 0x93, 0xba, 0xbc, 0x1d, 0xe5, 0x88, 0xa8, 0x41, 0xb0, 0xde, - 0x04, 0xba, 0x0f, 0x93, 0xc1, 0x7d, 0xca, 0x30, 0xe5, 0x8d, 0x48, 0x34, 0x3b, 0x6e, 0x0e, 0x2c, - 0xc7, 0x50, 0x6b, 0x54, 0xd6, 0x38, 0x99, 0x49, 0x14, 0xa7, 0x5b, 0x41, 0x0b, 0x86, 0xb9, 0x7a, - 0x22, 0xf1, 0x8d, 0x4f, 0xcc, 0xd5, 0xba, 0x75, 0x9a, 0x85, 0xd0, 0x73, 0x7f, 0x58, 0xc6, 0x11, - 0x26, 0x53, 0x21, 0xf4, 0x09, 0x08, 0xeb, 0x78, 0x68, 0x13, 0xc6, 0x92, 0xbb, 0xad, 0x30, 0x62, - 0xd9, 0x79, 0x34, 0x77, 0xaf, 0x83, 0x07, 0xb7, 0xa6, 0xd5, 0xe4, 0x91, 0x3e, 0x7a, 0x09, 0x36, - 0x28, 0xcf, 0x7d, 0x14, 0x46, 0xb5, 0x4f, 0xdc, 0x8f, 0xbb, 0xf7, 0xdc, 0xab, 0x30, 0x95, 0xfe, - 0x74, 0x7d, 0xb9, 0x8b, 0xff, 0xf7, 0x12, 0x4c, 0x66, 0x5c, 0x6c, 0xb1, 0x5c, 0xc9, 0x29, 0x26, - 0x9b, 0xa4, 0x46, 0x36, 0x59, 0x65, 0xa9, 0x00, 0xab, 0x94, 0x7c, 0xbb, 0xdc, 0x93, 0x6f, 0x0b, - 0xf6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 0x66, 0xf7, 0x76, 0xe7, 0x67, 0xb2, - 0xb0, 0x70, 0x66, 0xab, 0xf4, 0xfb, 0x6e, 0x8a, 0x70, 0x99, 0x62, 0x01, 0x9f, 0x59, 0xc1, 0x35, - 0x9c, 0xad, 0x49, 0x08, 0x56, 0x14, 0xd1, 0xdb, 0x50, 0x69, 0xc9, 0xc8, 0xb8, 0x34, 0xdb, 0xec, - 0x31, 0xcd, 0x59, 0x81, 0x74, 0x3c, 0x5c, 0x41, 0x81, 0x70, 0x42, 0x14, 0x5d, 0x81, 0xb2, 0xbf, - 0x11, 0x89, 0x18, 0xf4, 0x3c, 0x6f, 0x23, 0xd3, 0xc7, 0x8b, 0x87, 0xed, 0xde, 0x58, 0xad, 0x63, - 0x4a, 0x82, 0x52, 0x0a, 0xef, 0x36, 0x85, 0x3d, 0x3a, 0x87, 0x12, 0x5e, 0xaa, 0x76, 0x53, 0xc2, - 0x4b, 0x55, 0x4c, 0x49, 0xa0, 0x1a, 0x0c, 0xb2, 0x60, 0x1c, 0x61, 0x6c, 0xce, 0x49, 0x54, 0xd0, - 0x15, 0x72, 0xc4, 0xf3, 0x66, 0xb2, 0x62, 0xcc, 0x09, 0xa1, 0x75, 0x18, 0x6a, 0xb0, 0xa7, 0x1f, - 0x84, 0x15, 0x20, 0x2f, 0x85, 0x47, 0xd7, 0x33, 0x11, 0xfc, 0x86, 0x8d, 0x97, 0x63, 0x41, 0x8b, - 0x51, 0x25, 0xed, 0xcd, 0x8d, 0x48, 0xa8, 0xf9, 0x79, 0x54, 0xbb, 0x1e, 0xf1, 0x10, 0x54, 0x59, - 0x39, 0x16, 0xb4, 0x50, 0x15, 0x4a, 0x1b, 0x0d, 0x11, 0xab, 0x93, 0x63, 0x64, 0x36, 0x63, 0xb0, - 0x97, 0x86, 0xf6, 0x76, 0xe7, 0x4b, 0xab, 0xcb, 0xb8, 0xb4, 0xd1, 0x40, 0xaf, 0xc3, 0xf0, 0x06, - 0x8f, 0xaa, 0x15, 0xa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x4b, 0x69, 0x4c, 0x8c, 0x96, 0x62, 0x01, 0x15, 0x78, - 0x24, 0x0c, 0x45, 0xd4, 0x94, 0x8e, 0x47, 0xc2, 0x10, 0x0b, 0xa8, 0x7c, 0x77, 0x63, 0xa0, 0xc7, - 0xbb, 0x1b, 0x2c, 0xe7, 0x98, 0x70, 0x35, 0x11, 0x62, 0x85, 0x96, 0x73, 0x4c, 0xfa, 0xa0, 0x24, - 0x38, 0xf6, 0xb7, 0xcb, 0x30, 0x56, 0x0b, 0x9a, 0x89, 0x97, 0xff, 0x8b, 0x86, 0x97, 0xff, 0x99, - 0x94, 0x97, 0xff, 0x94, 0x8e, 0xfb, 0x70, 0x9c, 0xfc, 0x45, 0x6e, 0x3a, 0xf6, 0x32, 0xcc, 0x21, - 0x1d, 0xfc, 0x8d, 0xdc, 0x74, 0x8a, 0x10, 0x36, 0xe9, 0xfe, 0x2c, 0x39, 0xf6, 0xff, 0x2f, 0x0b, - 0x26, 0x6a, 0x41, 0x93, 0x2e, 0xd0, 0x9f, 0xa5, 0xd5, 0xa8, 0x67, 0xb4, 0x1b, 0x3a, 0x20, 0xa3, - 0xdd, 0xaf, 0x59, 0x30, 0x5c, 0x0b, 0x9a, 0xc7, 0x60, 0xb2, 0x5d, 0x35, 0x4d, 0xb6, 0x4f, 0xe4, - 0x72, 0xde, 0x1e, 0x56, 0xda, 0xef, 0x96, 0x61, 0x9c, 0xf6, 0x38, 0x68, 0xc9, 0xef, 0x65, 0xcc, - 0x8d, 0x55, 0x60, 0x6e, 0xa8, 0x48, 0x18, 0x78, 0x5e, 0x70, 0x3f, 0xfd, 0xed, 0x56, 0x59, 0x29, - 0x16, 0x50, 0x74, 0x0e, 0x46, 0xda, 0x21, 0xd9, 0x76, 0x83, 0x4e, 0x94, 0x8e, 0xc0, 0xac, 0x89, - 0x72, 0xac, 0x30, 0xd0, 0x8b, 0x30, 0x16, 0xb9, 0x7e, 0x83, 0x48, 0x47, 0x94, 0x01, 0xe6, 0x88, - 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x5e, 0xf8, 0xca, - 0x70, 0xc4, 0xe3, 0xfc, 0xef, 0x89, 0xbd, 0xdd, 0xf9, 0xc7, 0xd7, 0x0f, 0x42, 0xc4, 0x07, 0xd3, - 0x41, 0x37, 0xe1, 0xa4, 0xd3, 0x88, 0xdd, 0x6d, 0x52, 0x25, 0x4e, 0xd3, 0x73, 0x7d, 0x62, 0x26, - 0x50, 0x78, 0x74, 0x6f, 0x77, 0xfe, 0xe4, 0x62, 0x16, 0x02, 0xce, 0xae, 0x87, 0x3e, 0x0e, 0x95, - 0xa6, 0x1f, 0x89, 0x39, 0x18, 0x32, 0x1e, 0xb4, 0xab, 0x54, 0x6f, 0xd4, 0xd5, 0xf8, 0x93, 0x3f, - 0x38, 0xa9, 0x80, 0xde, 0x85, 0x31, 0x3d, 0x30, 0x4a, 0x3c, 0xa4, 0xf8, 0x72, 0x21, 0x2d, 0xde, - 0x88, 0x26, 0xe2, 0x76, 0x44, 0xe5, 0xf0, 0x6a, 0x04, 0x1a, 0x19, 0x4d, 0xa0, 0x4f, 0x02, 0x8a, - 0x48, 0xb8, 0xed, 0x36, 0xc8, 0x62, 0x83, 0xe5, 0xfd, 0x65, 0x96, 0xa6, 0x11, 0x23, 0xf2, 0x03, - 0xd5, 0xbb, 0x30, 0x70, 0x46, 0x2d, 0x74, 0x85, 0xf2, 0x3f, 0xbd, 0x54, 0xf8, 0x27, 0x4b, 0xf1, - 0x74, 0xb6, 0x4a, 0xda, 0x21, 0x69, 0x38, 0x31, 0x69, 0x9a, 0x14, 0x71, 0xaa, 0x1e, 0x3d, 0x1d, - 0xd5, 0xd3, 0x0e, 0x60, 0x7a, 0xd5, 0x76, 0x3f, 0xef, 0x40, 0xb5, 0xbd, 0xcd, 0x20, 0x8a, 0x6f, - 0x90, 0xf8, 0x7e, 0x10, 0xde, 0x13, 0xb9, 0xd2, 0x92, 0x24, 0x8a, 0x09, 0x08, 0xeb, 0x78, 0x54, - 0x92, 0x63, 0x97, 0x82, 0x6b, 0x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, - 0x27, 0xd7, 0x4b, 0x99, 0xae, 0x44, 0x4e, 0x3d, 0x01, 0x3d, 0xfa, 0x67, 0x89, 0x2f, 0x02, 0x44, - 0x91, 0xb7, 0xe2, 0x53, 0x09, 0xaf, 0x29, 0x9c, 0x77, 0x93, 0x9c, 0x8c, 0xf5, 0x6b, 0x02, 0x82, - 0x35, 0x2c, 0x54, 0x85, 0xa9, 0x76, 0x18, 0xc4, 0xdc, 0x30, 0x58, 0xe5, 0xae, 0x16, 0x83, 0x66, - 0xd4, 0x58, 0x2d, 0x05, 0xc7, 0x5d, 0x35, 0xd0, 0x4b, 0x30, 0x2a, 0x22, 0xc9, 0x6a, 0x41, 0xe0, - 0x09, 0x33, 0x92, 0xba, 0x8f, 0xaf, 0x27, 0x20, 0xac, 0xe3, 0x69, 0xd5, 0x98, 0xb5, 0x71, 0x38, - 0xb3, 0x1a, 0xb7, 0x38, 0x6a, 0x78, 0xa9, 0xcc, 0x27, 0x23, 0x85, 0x32, 0x9f, 0x24, 0x86, 0xb5, - 0x4a, 0xe1, 0x8b, 0x18, 0xc8, 0x35, 0x40, 0xfd, 0x5e, 0x19, 0x86, 0xf8, 0xa7, 0x38, 0x06, 0x29, - 0xaf, 0x26, 0x4c, 0x4a, 0x85, 0xb2, 0x4c, 0xf0, 0x5e, 0x2d, 0x54, 0x9d, 0xd8, 0xe1, 0xac, 0x49, - 0xed, 0x90, 0xc4, 0x0c, 0x85, 0x16, 0x8c, 0x3d, 0x34, 0x97, 0xb2, 0x94, 0x00, 0xa7, 0xa1, 0xed, - 0xa8, 0x4d, 0x80, 0x88, 0x3d, 0x8d, 0x4b, 0x69, 0x88, 0xac, 0xbd, 0x2f, 0x16, 0xea, 0x47, 0x5d, - 0x55, 0xe3, 0xbd, 0x49, 0x96, 0xa5, 0x02, 0x60, 0x8d, 0xf6, 0xdc, 0xcb, 0x50, 0x51, 0xc8, 0x79, - 0x2a, 0xe4, 0x98, 0xce, 0xda, 0xfe, 0x3f, 0x98, 0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 0xa1, 0xa9, 0x1a, 0xe8, 0x67, 0xaa, 0x96, 0x61, 0x3a, 0x89, - 0xcb, 0x32, 0x03, 0x5c, 0x59, 0x8a, 0xd8, 0xf5, 0x34, 0x10, 0x77, 0xe3, 0xdb, 0x5f, 0xb3, 0x40, - 0x38, 0x6f, 0x16, 0x58, 0xd0, 0x4d, 0xf9, 0x54, 0x94, 0x91, 0x79, 0xee, 0xd9, 0x22, 0x7e, 0xad, - 0x22, 0xdf, 0x9c, 0xda, 0x62, 0x46, 0x96, 0x39, 0x83, 0xaa, 0xfd, 0xeb, 0x16, 0x8c, 0x72, 0xf0, - 0x75, 0x26, 0xf3, 0xe7, 0xf7, 0xab, 0xaf, 0xfc, 0xc3, 0xec, 0x15, 0x25, 0x4a, 0x58, 0xe5, 0xa1, - 0xd5, 0x5f, 0x51, 0x92, 0x00, 0x9c, 0xe0, 0xa0, 0x67, 0x60, 0x38, 0xea, 0xdc, 0x65, 0xe8, 0x29, - 0x4f, 0xce, 0x3a, 0x2f, 0xc6, 0x12, 0x6e, 0xff, 0xb3, 0x12, 0x4c, 0xa5, 0x1d, 0x79, 0x11, 0x86, - 0x21, 0xae, 0x03, 0xa4, 0xc5, 0xc7, 0x83, 0xec, 0x52, 0x9a, 0x23, 0x30, 0xf0, 0xb7, 0xc0, 0xd9, - 0x05, 0x82, 0xa0, 0x84, 0x36, 0x60, 0xb4, 0x19, 0xdc, 0xf7, 0xef, 0x3b, 0x61, 0x73, 0xb1, 0xb6, - 0x26, 0xbe, 0x44, 0x8e, 0xeb, 0x55, 0x35, 0xa9, 0xa0, 0xbb, 0x19, 0x33, 0x3b, 0x49, 0x02, 0xc2, - 0x3a, 0x61, 0xaa, 0xf3, 0x36, 0x02, 0x7f, 0xc3, 0x6d, 0x5d, 0x77, 0xda, 0xc5, 0x9c, 0x0c, 0x96, - 0x25, 0xba, 0xd6, 0xc6, 0xb8, 0xc8, 0xab, 0xc1, 0x01, 0x38, 0x21, 0x69, 0xff, 0xda, 0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0xc1, 0xb0, 0xca, 0x4a, 0xf7, 0x77, 0x67, 0x47, 0xeb, 0x71, 0x10, 0x3a, + 0x1b, 0x84, 0x17, 0x60, 0x81, 0xce, 0xae, 0x94, 0xbc, 0xf7, 0xc8, 0x35, 0x6f, 0xcb, 0x93, 0x57, + 0x79, 0x07, 0x1a, 0xf9, 0xe6, 0xe4, 0xd0, 0xce, 0xbd, 0xd6, 0x76, 0xfc, 0xd8, 0x8b, 0x77, 0x4c, + 0x79, 0x99, 0x11, 0xc2, 0x09, 0x4d, 0xfb, 0xc7, 0x16, 0x8c, 0x4b, 0x0e, 0x34, 0xef, 0xba, 0x21, + 0x89, 0x22, 0x34, 0x03, 0x25, 0xaf, 0x25, 0x7a, 0x0a, 0xa2, 0x76, 0x69, 0xa5, 0x86, 0x4b, 0x5e, + 0x0b, 0xbd, 0x01, 0x15, 0x7e, 0x17, 0x98, 0x2c, 0xbf, 0x1e, 0xef, 0x16, 0x99, 0xf6, 0xb9, 0x26, + 0x69, 0xe0, 0x84, 0x9c, 0x94, 0xc3, 0xd9, 0xd9, 0x56, 0x36, 0x6f, 0xa6, 0xae, 0x88, 0x72, 0xac, + 0x30, 0xd0, 0x59, 0x18, 0xf2, 0x03, 0x97, 0x5f, 0xd7, 0x72, 0x4e, 0xc0, 0x16, 0xf5, 0x75, 0x51, + 0x86, 0x15, 0xd4, 0xfe, 0xaa, 0x05, 0x23, 0xf2, 0x1b, 0x0b, 0xaa, 0x04, 0x74, 0x1b, 0x26, 0xea, + 0x40, 0xb2, 0x0d, 0xa9, 0x48, 0xcf, 0x20, 0x86, 0x24, 0x5f, 0xee, 0x45, 0x92, 0xb7, 0x7f, 0xbd, + 0x04, 0x63, 0xb2, 0x3b, 0xf5, 0xf6, 0x9d, 0x88, 0x50, 0x41, 0xa7, 0xe2, 0xf0, 0xc1, 0x27, 0x72, + 0x25, 0x3f, 0x9f, 0xa7, 0xed, 0x19, 0x73, 0x96, 0xcc, 0xf2, 0xbc, 0xa4, 0x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1, 0x65, 0xff, 0xa0, 0x4c, 0x59, 0x5f, 0x82, 0x6a, 0x48, 0x0f, 0xd6, 0x71, + 0x48, 0x0f, 0xa5, 0xa3, 0x97, 0x1e, 0xde, 0x85, 0xf1, 0x86, 0x76, 0x05, 0x98, 0xcc, 0xf8, 0xc5, + 0x82, 0xcb, 0x4a, 0xbb, 0x37, 0xe4, 0x16, 0xc1, 0x45, 0x93, 0x1c, 0x4e, 0xd3, 0x47, 0x04, 0x46, + 0xf8, 0x7a, 0x10, 0xed, 0xf5, 0xb1, 0xf6, 0xce, 0x17, 0x59, 0x61, 0x7a, 0x63, 0x6c, 0x15, 0xd7, + 0x35, 0x42, 0xd8, 0x20, 0x6b, 0xff, 0x52, 0x3f, 0xf4, 0x2f, 0x6d, 0x13, 0x3f, 0x3e, 0x06, 0x56, + 0xb7, 0x05, 0x63, 0x9e, 0xbf, 0x1d, 0x34, 0xb7, 0x89, 0xcb, 0xe1, 0x87, 0x3b, 0xde, 0x4f, 0x89, + 0x46, 0xc6, 0x56, 0x0c, 0x62, 0x38, 0x45, 0xfc, 0x28, 0x6c, 0x11, 0xaf, 0xc1, 0x00, 0x5f, 0x19, + 0xc2, 0x10, 0x91, 0x73, 0x63, 0xc0, 0x06, 0x56, 0xec, 0xa0, 0xc4, 0x62, 0xc2, 0x2f, 0x2b, 0x04, + 0x21, 0xf4, 0x0e, 0x8c, 0xad, 0x7b, 0x61, 0x14, 0xaf, 0x79, 0x5b, 0x54, 0x87, 0xdc, 0x6a, 0x1d, + 0xc2, 0x0a, 0xa1, 0x46, 0x64, 0xd9, 0xa0, 0x84, 0x53, 0x94, 0xd1, 0x06, 0x8c, 0x52, 0x25, 0x38, + 0x69, 0x6a, 0xb0, 0xe7, 0xa6, 0x94, 0x11, 0xf2, 0x9a, 0x4e, 0x08, 0x9b, 0x74, 0x29, 0x4b, 0x6a, + 0x30, 0xa5, 0x79, 0x88, 0x49, 0x37, 0x8a, 0x25, 0x71, 0x6d, 0x99, 0xc3,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0x95, 0x62, 0x3a, 0x35, 0x5e, + 0x8c, 0x25, 0x1c, 0x5d, 0x04, 0x20, 0xf7, 0x63, 0x12, 0xfa, 0x4e, 0x53, 0x5d, 0xe9, 0x2b, 0x51, + 0x69, 0x49, 0x41, 0xb0, 0x86, 0x45, 0xeb, 0xb4, 0xc2, 0x60, 0xdb, 0x73, 0x59, 0x9c, 0x4b, 0xd9, + 0xac, 0x53, 0x53, 0x10, 0xac, 0x61, 0x51, 0x05, 0xba, 0xed, 0x47, 0xfc, 0x18, 0x73, 0xee, 0x88, + 0x4c, 0x4a, 0x43, 0x89, 0x02, 0x7d, 0x53, 0x07, 0x62, 0x13, 0x17, 0x5d, 0x85, 0x81, 0xd8, 0x61, + 0x17, 0xd5, 0xfd, 0x45, 0xbc, 0x7e, 0xd6, 0x28, 0xae, 0x9e, 0xba, 0x8a, 0x56, 0xc5, 0x82, 0x84, + 0xfd, 0x9f, 0x2a, 0x00, 0x89, 0xd4, 0x85, 0xbe, 0xd8, 0xb9, 0xe1, 0x3f, 0x52, 0x54, 0x64, 0x7b, + 0x70, 0xbb, 0x1d, 0x7d, 0xcd, 0x82, 0x61, 0xa7, 0xd9, 0x0c, 0x1a, 0x4e, 0xcc, 0x86, 0xa7, 0x54, + 0x94, 0xf5, 0x88, 0x9e, 0xcc, 0x27, 0x75, 0x79, 0x67, 0x5e, 0x90, 0x97, 0xc7, 0x1a, 0x24, 0xb7, + 0x3f, 0x7a, 0x17, 0xd0, 0x87, 0xa5, 0xd4, 0xce, 0x67, 0x78, 0x26, 0x2d, 0xb5, 0x57, 0x18, 0xc3, + 0xd5, 0x04, 0x76, 0xf4, 0x96, 0x91, 0x79, 0xa8, 0xaf, 0x48, 0xb0, 0xb2, 0x21, 0x87, 0xe4, 0x25, + 0x1d, 0x42, 0x6f, 0xe8, 0xee, 0xf1, 0xfd, 0x45, 0xb2, 0x01, 0x68, 0xe2, 0x70, 0x8e, 0x6b, 0x7c, + 0x0c, 0xe3, 0xae, 0x79, 0xf2, 0x0a, 0x17, 0xbf, 0x0b, 0xf9, 0x2d, 0xa4, 0x8e, 0xec, 0xe4, 0xac, + 0x4d, 0x01, 0x70, 0xba, 0x09, 0xf4, 0x06, 0x0f, 0x5e, 0x58, 0xf1, 0xd7, 0x03, 0xe1, 0xe6, 0x77, + 0xae, 0xc0, 0x9c, 0xef, 0x44, 0x31, 0xd9, 0xa2, 0x75, 0x92, 0xc3, 0xf5, 0xba, 0xa0, 0x82, 0x15, + 0x3d, 0xb4, 0x06, 0x03, 0x2c, 0x36, 0x2d, 0x9a, 0x1e, 0x2a, 0x62, 0x12, 0x34, 0x43, 0xb2, 0x93, + 0xfd, 0xc3, 0xfe, 0x46, 0x58, 0xd0, 0x42, 0x57, 0x64, 0x52, 0x86, 0x68, 0xc5, 0xbf, 0x19, 0x11, + 0x96, 0x94, 0xa1, 0xb2, 0xf0, 0xa1, 0x24, 0xcb, 0x02, 0x2f, 0xcf, 0x4c, 0xd7, 0x68, 0xd4, 0xa4, + 0x82, 0x8d, 0xf8, 0x2f, 0xb3, 0x40, 0x4e, 0x43, 0x91, 0x8e, 0x9a, 0x39, 0x23, 0x93, 0xc1, 0xbe, + 0x65, 0x12, 0xc3, 0x69, 0xea, 0xc7, 0x7a, 0xa4, 0xce, 0xf8, 0x30, 0x91, 0xde, 0x94, 0x47, 0x7a, + 0x84, 0xff, 0xa4, 0x0f, 0xc6, 0xcc, 0xc5, 0x81, 0xce, 0x43, 0x45, 0x10, 0x51, 0x29, 0xde, 0xd4, + 0x1e, 0x58, 0x95, 0x00, 0x9c, 0xe0, 0xb0, 0x64, 0x77, 0xac, 0xba, 0xe6, 0xe0, 0x95, 0x24, 0xbb, + 0x53, 0x10, 0xac, 0x61, 0x51, 0x49, 0xf8, 0x4e, 0x10, 0xc4, 0xea, 0x24, 0x50, 0xeb, 0x66, 0x81, + 0x95, 0x62, 0x01, 0xa5, 0x27, 0xc0, 0x5d, 0x3a, 0x99, 0x4d, 0xd3, 0xbc, 0xa9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 0x7b, 0xa7, 0xad, 0xdf, 0xdf, 0x3b, 0x6d, 0xfd, 0xf9, 0xde, 0x69, 0xeb, + 0x6b, 0x3f, 0x39, 0xfd, 0x81, 0x37, 0x4a, 0xdb, 0x17, 0xfe, 0x5f, 0x00, 0x00, 0x00, 0xff, 0xff, + 0x8d, 0xa0, 0x5a, 0x64, 0xe6, 0xcd, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/api/v1/generated.proto b/staging/src/k8s.io/client-go/pkg/api/v1/generated.proto index a1e069f916733..a84f642d16b01 100644 --- a/staging/src/k8s.io/client-go/pkg/api/v1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/api/v1/generated.proto @@ -19,14 +19,13 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.api.v1; +package k8s.io.client_go.pkg.api.v1; import "k8s.io/apimachinery/pkg/api/resource/generated.proto"; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1"; @@ -762,6 +761,15 @@ message EmptyDirVolumeSource { // More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir // +optional optional string medium = 1; + + // Total amount of local storage required for this EmptyDir volume. + // The size limit is also applicable for memory medium. + // The maximum usage on memory medium EmptyDir would be the minimum value between + // the SizeLimit specified here and the sum of memory limits of all containers in a pod. + // The default is nil which means that the limit is undefined. + // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir + // +optional + optional k8s.io.apimachinery.pkg.api.resource.Quantity sizeLimit = 2; } // EndpointAddress is a tuple that describes single IP address. diff --git a/staging/src/k8s.io/client-go/pkg/api/v1/types.generated.go b/staging/src/k8s.io/client-go/pkg/api/v1/types.generated.go index a0fa0cf225dc6..333b12aceced0 100644 --- a/staging/src/k8s.io/client-go/pkg/api/v1/types.generated.go +++ b/staging/src/k8s.io/client-go/pkg/api/v1/types.generated.go @@ -11220,13 +11220,14 @@ func (x *EmptyDirVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } else { yysep2 := !z.EncBinary() yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [1]bool + var yyq2 [2]bool _, _, _ = yysep2, yyq2, yy2arr2 const yyr2 bool = false yyq2[0] = x.Medium != "" + yyq2[1] = true var yynn2 int if yyr2 || yy2arr2 { - r.EncodeArrayStart(1) + r.EncodeArrayStart(2) } else { yynn2 = 0 for _, b := range yyq2 { @@ -11252,6 +11253,39 @@ func (x *EmptyDirVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { x.Medium.CodecEncodeSelf(e) } } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yy7 := &x.SizeLimit + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(yy7) { + } else if !yym8 && z.IsJSONHandle() { + z.EncJSONMarshal(yy7) + } else { + z.EncFallback(yy7) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("sizeLimit")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy9 := &x.SizeLimit + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(yy9) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(yy9) + } else { + z.EncFallback(yy9) + } + } + } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { @@ -11320,6 +11354,21 @@ func (x *EmptyDirVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decode yyv4 := &x.Medium yyv4.CodecDecodeSelf(d) } + case "sizeLimit": + if r.TryDecodeAsNil() { + x.SizeLimit = pkg3_resource.Quantity{} + } else { + yyv5 := &x.SizeLimit + yym6 := z.DecBinary() + _ = yym6 + if false { + } else if z.HasExtensions() && z.DecExt(yyv5) { + } else if !yym6 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv5) + } else { + z.DecFallback(yyv5, false) + } + } default: z.DecStructFieldNotFound(-1, yys3) } // end switch yys3 @@ -11331,16 +11380,16 @@ func (x *EmptyDirVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj5 int - var yyb5 bool - var yyhl5 bool = l >= 0 - yyj5++ - if yyhl5 { - yyb5 = yyj5 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb5 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb5 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11348,21 +11397,46 @@ func (x *EmptyDirVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Medium = "" } else { - yyv6 := &x.Medium - yyv6.CodecDecodeSelf(d) + yyv8 := &x.Medium + yyv8.CodecDecodeSelf(d) + } + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.SizeLimit = pkg3_resource.Quantity{} + } else { + yyv9 := &x.SizeLimit + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(yyv9) { + } else if !yym10 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv9) + } else { + z.DecFallback(yyv9, false) + } } for { - yyj5++ - if yyhl5 { - yyb5 = yyj5 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb5 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb5 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj5-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } diff --git a/staging/src/k8s.io/client-go/pkg/api/v1/types.go b/staging/src/k8s.io/client-go/pkg/api/v1/types.go index b8e787091e120..93caed774e422 100644 --- a/staging/src/k8s.io/client-go/pkg/api/v1/types.go +++ b/staging/src/k8s.io/client-go/pkg/api/v1/types.go @@ -686,6 +686,14 @@ type EmptyDirVolumeSource struct { // More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir // +optional Medium StorageMedium `json:"medium,omitempty" protobuf:"bytes,1,opt,name=medium,casttype=StorageMedium"` + // Total amount of local storage required for this EmptyDir volume. + // The size limit is also applicable for memory medium. + // The maximum usage on memory medium EmptyDir would be the minimum value between + // the SizeLimit specified here and the sum of memory limits of all containers in a pod. + // The default is nil which means that the limit is undefined. + // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir + // +optional + SizeLimit resource.Quantity `json:"sizeLimit,omitempty" protobuf:"bytes,2,opt,name=sizeLimit"` } // Represents a Glusterfs mount that lasts the lifetime of a pod. @@ -3455,6 +3463,12 @@ const ( ResourceMemory ResourceName = "memory" // Volume size, in bytes (e,g. 5Gi = 5GiB = 5 * 1024 * 1024 * 1024) ResourceStorage ResourceName = "storage" + // Local Storage for container overlay filesystem, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024) + // The resource name for ResourceStorageOverlay is alpha and it can change across releases. + ResourceStorageOverlay ResourceName = "storage.kubernetes.io/overlay" + // Local Storage for scratch space, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024) + // The resource name for ResourceStorageScratch is alpha and it can change across releases. + ResourceStorageScratch ResourceName = "storage.kubernetes.io/scratch" // NVIDIA GPU, in devices. Alpha, might change: although fractional and allowing values >1, only one whole device per node is assigned. ResourceNvidiaGPU ResourceName = "alpha.kubernetes.io/nvidia-gpu" // Number of Pods that may be running on this Node: see ResourcePods diff --git a/staging/src/k8s.io/client-go/pkg/api/v1/types_swagger_doc_generated.go b/staging/src/k8s.io/client-go/pkg/api/v1/types_swagger_doc_generated.go index 3ffc43306702d..7b2a450245783 100644 --- a/staging/src/k8s.io/client-go/pkg/api/v1/types_swagger_doc_generated.go +++ b/staging/src/k8s.io/client-go/pkg/api/v1/types_swagger_doc_generated.go @@ -396,8 +396,9 @@ func (DownwardAPIVolumeSource) SwaggerDoc() map[string]string { } var map_EmptyDirVolumeSource = map[string]string{ - "": "Represents an empty directory for a pod. Empty directory volumes support ownership management and SELinux relabeling.", - "medium": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", + "": "Represents an empty directory for a pod. Empty directory volumes support ownership management and SELinux relabeling.", + "medium": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", + "sizeLimit": "Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir", } func (EmptyDirVolumeSource) SwaggerDoc() map[string]string { diff --git a/staging/src/k8s.io/client-go/pkg/api/v1/zz_generated.conversion.go b/staging/src/k8s.io/client-go/pkg/api/v1/zz_generated.conversion.go index 7dae9e06b857a..273bd043c8034 100644 --- a/staging/src/k8s.io/client-go/pkg/api/v1/zz_generated.conversion.go +++ b/staging/src/k8s.io/client-go/pkg/api/v1/zz_generated.conversion.go @@ -1236,6 +1236,7 @@ func Convert_api_DownwardAPIVolumeSource_To_v1_DownwardAPIVolumeSource(in *api.D func autoConvert_v1_EmptyDirVolumeSource_To_api_EmptyDirVolumeSource(in *EmptyDirVolumeSource, out *api.EmptyDirVolumeSource, s conversion.Scope) error { out.Medium = api.StorageMedium(in.Medium) + out.SizeLimit = in.SizeLimit return nil } @@ -1246,6 +1247,7 @@ func Convert_v1_EmptyDirVolumeSource_To_api_EmptyDirVolumeSource(in *EmptyDirVol func autoConvert_api_EmptyDirVolumeSource_To_v1_EmptyDirVolumeSource(in *api.EmptyDirVolumeSource, out *EmptyDirVolumeSource, s conversion.Scope) error { out.Medium = StorageMedium(in.Medium) + out.SizeLimit = in.SizeLimit return nil } diff --git a/staging/src/k8s.io/client-go/pkg/api/v1/zz_generated.deepcopy.go b/staging/src/k8s.io/client-go/pkg/api/v1/zz_generated.deepcopy.go index f6d5d9b4acd27..4f69f1f510809 100644 --- a/staging/src/k8s.io/client-go/pkg/api/v1/zz_generated.deepcopy.go +++ b/staging/src/k8s.io/client-go/pkg/api/v1/zz_generated.deepcopy.go @@ -856,6 +856,7 @@ func DeepCopy_v1_EmptyDirVolumeSource(in interface{}, out interface{}, c *conver in := in.(*EmptyDirVolumeSource) out := out.(*EmptyDirVolumeSource) *out = *in + out.SizeLimit = in.SizeLimit.DeepCopy() return nil } } @@ -3549,7 +3550,9 @@ func DeepCopy_v1_VolumeSource(in interface{}, out interface{}, c *conversion.Clo if in.EmptyDir != nil { in, out := &in.EmptyDir, &out.EmptyDir *out = new(EmptyDirVolumeSource) - **out = **in + if err := DeepCopy_v1_EmptyDirVolumeSource(*in, *out, c); err != nil { + return err + } } if in.GCEPersistentDisk != nil { in, out := &in.GCEPersistentDisk, &out.GCEPersistentDisk diff --git a/staging/src/k8s.io/client-go/pkg/api/zz_generated.deepcopy.go b/staging/src/k8s.io/client-go/pkg/api/zz_generated.deepcopy.go index ab50cbb194c3f..7f8adc35d3d8e 100644 --- a/staging/src/k8s.io/client-go/pkg/api/zz_generated.deepcopy.go +++ b/staging/src/k8s.io/client-go/pkg/api/zz_generated.deepcopy.go @@ -858,6 +858,7 @@ func DeepCopy_api_EmptyDirVolumeSource(in interface{}, out interface{}, c *conve in := in.(*EmptyDirVolumeSource) out := out.(*EmptyDirVolumeSource) *out = *in + out.SizeLimit = in.SizeLimit.DeepCopy() return nil } } @@ -3555,7 +3556,9 @@ func DeepCopy_api_VolumeSource(in interface{}, out interface{}, c *conversion.Cl if in.EmptyDir != nil { in, out := &in.EmptyDir, &out.EmptyDir *out = new(EmptyDirVolumeSource) - **out = **in + if err := DeepCopy_api_EmptyDirVolumeSource(*in, *out, c); err != nil { + return err + } } if in.GCEPersistentDisk != nil { in, out := &in.GCEPersistentDisk, &out.GCEPersistentDisk diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/BUILD b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/BUILD new file mode 100644 index 0000000000000..6e2604388adbe --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/BUILD @@ -0,0 +1,25 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/doc.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/doc.go new file mode 100644 index 0000000000000..492dad7b546f1 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/doc.go @@ -0,0 +1,22 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// Package admissionregistration is the internal version of the API. +// AdmissionConfiguration and AdmissionPluginConfiguration are legacy static admission plugin configuration +// InitializerConfiguration and ExternalAdmissionHookConfiguration is for the +// new dynamic admission controller configuration. +// +groupName=admissionregistration.k8s.io +package admissionregistration diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/register.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/register.go new file mode 100644 index 0000000000000..1fe291a8f23f0 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/register.go @@ -0,0 +1,53 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package admissionregistration + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +const GroupName = "admissionregistration.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} + +// Kind takes an unqualified kind and returns back a Group qualified GroupKind +func Kind(kind string) schema.GroupKind { + return SchemeGroupVersion.WithKind(kind).GroupKind() +} + +// Resource takes an unqualified resource and returns back a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) + AddToScheme = SchemeBuilder.AddToScheme +) + +// Adds the list of known types to scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &InitializerConfiguration{}, + &InitializerConfigurationList{}, + &ExternalAdmissionHookConfiguration{}, + &ExternalAdmissionHookConfigurationList{}, + ) + return nil +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/types.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/types.go new file mode 100644 index 0000000000000..037c075770928 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/types.go @@ -0,0 +1,210 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package admissionregistration + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// +genclient=true + +// InitializerConfiguration describes the configuration of initializers. +type InitializerConfiguration struct { + metav1.TypeMeta + // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // +optional + metav1.ObjectMeta + + // Initializers is a list of resources and their default initializers + // Order-sensitive. + // When merging multiple InitializerConfigurations, we sort the initializers + // from different InitializerConfigurations by the name of the + // InitializerConfigurations; the order of the initializers from the same + // InitializerConfiguration is preserved. + // +optional + Initializers []Initializer +} + +// InitializerConfigurationList is a list of InitializerConfiguration. +type InitializerConfigurationList struct { + metav1.TypeMeta + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // +optional + metav1.ListMeta + + // List of InitializerConfiguration. + Items []InitializerConfiguration +} + +// Initializer describes the name and the failure policy of an initializer, and +// what resources it applies to. +type Initializer struct { + // Name is the identifier of the initializer. It will be added to the + // object that needs to be initialized. + // Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where + // "alwayspullimages" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required + Name string + + // Rules describes what resources/subresources the initializer cares about. + // The initializer cares about an operation if it matches _any_ Rule. + Rules []Rule + + // FailurePolicy defines what happens if the responsible initializer controller + // fails to takes action. Allowed values are Ignore, or Fail. If "Ignore" is + // set, initializer is removed from the initializers list of an object if + // the timeout is reached; If "Fail" is set, admissionregistration returns timeout error + // if the timeout is reached. + FailurePolicy *FailurePolicyType +} + +// Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended +// to make sure that all the tuple expansions are valid. +type Rule struct { + // APIGroups is the API groups the resources belong to. '*' is all groups. + // If '*' is present, the length of the slice must be one. + // Required. + APIGroups []string + + // APIVersions is the API versions the resources belong to. '*' is all versions. + // If '*' is present, the length of the slice must be one. + // Required. + APIVersions []string + + // Resources is a list of resources this rule applies to. + // + // For example: + // 'pods' means pods. + // 'pods/log' means the log subresource of pods. + // '*' means all resources, but not subresources. + // 'pods/*' means all subresources of pods. + // '*/scale' means all scale subresources. + // '*/*' means all resources and their subresources. + // + // If '*' or '*/*' is present, the length of the slice must be one. + // Required. + Resources []string +} + +type FailurePolicyType string + +const ( + // Ignore means the initilizer is removed from the initializers list of an + // object if the initializer is timed out. + Ignore FailurePolicyType = "Ignore" + // For 1.7, only "Ignore" is allowed. "Fail" will be allowed when the + // extensible admission feature is beta. + Fail FailurePolicyType = "Fail" +) + +// +genclient=true + +// ExternalAdmissionHookConfiguration describes the configuration of initializers. +type ExternalAdmissionHookConfiguration struct { + metav1.TypeMeta + // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // +optional + metav1.ObjectMeta + // ExternalAdmissionHooks is a list of external admission webhooks and the + // affected resources and operations. + // +optional + ExternalAdmissionHooks []ExternalAdmissionHook +} + +// ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration. +type ExternalAdmissionHookConfigurationList struct { + metav1.TypeMeta + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // +optional + metav1.ListMeta + // List of ExternalAdmissionHookConfiguration. + Items []ExternalAdmissionHookConfiguration +} + +// ExternalAdmissionHook describes an external admission webhook and the +// resources and operations it applies to. +type ExternalAdmissionHook struct { + // The name of the external admission webhook. + // Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where + // "imagepolicy" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required. + Name string + + // ClientConfig defines how to communicate with the hook. + // Required + ClientConfig AdmissionHookClientConfig + + // Rules describes what operations on what resources/subresources the webhook cares about. + // The webhook cares about an operation if it matches _any_ Rule. + Rules []RuleWithOperations + + // FailurePolicy defines how unrecognized errors from the admission endpoint are handled - + // allowed values are Ignore or Fail. Defaults to Ignore. + // +optional + FailurePolicy *FailurePolicyType +} + +// RuleWithOperations is a tuple of Operations and Resources. It is recommended to make +// sure that all the tuple expansions are valid. +type RuleWithOperations struct { + // Operations is the operations the admission hook cares about - CREATE, UPDATE, or * + // for all operations. + // If '*' is present, the length of the slice must be one. + // Required. + Operations []OperationType + // Rule is embedded, it describes other criteria of the rule, like + // APIGroups, APIVersions, Resources, etc. + Rule +} + +type OperationType string + +// The constants should be kept in sync with those defined in k8s.io/kubernetes/pkg/admission/interface.go. +const ( + OperationAll OperationType = "*" + Create OperationType = "CREATE" + Update OperationType = "UPDATE" + Delete OperationType = "DELETE" + Connect OperationType = "CONNECT" +) + +// AdmissionHookClientConfig contains the information to make a TLS +// connection with the webhook +type AdmissionHookClientConfig struct { + // Service is a reference to the service for this webhook. If there is only + // one port open for the service, that port will be used. If there are multiple + // ports open, port 443 will be used if it is open, otherwise it is an error. + // Required + Service ServiceReference + // CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. + // Required + CABundle []byte +} + +// ServiceReference holds a reference to Service.legacy.k8s.io +type ServiceReference struct { + // Namespace is the namespace of the service + // Required + Namespace string + // Name is the name of the service + // Required + Name string +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/BUILD b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/BUILD new file mode 100644 index 0000000000000..2af11423b546b --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/BUILD @@ -0,0 +1,35 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/admissionregistration:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/defaults.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/defaults.go new file mode 100644 index 0000000000000..5aed8f1d78716 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/defaults.go @@ -0,0 +1,39 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +import ( + "k8s.io/apimachinery/pkg/runtime" +) + +func addDefaultingFuncs(scheme *runtime.Scheme) error { + return RegisterDefaults(scheme) +} + +func SetDefaults_Initializer(obj *Initializer) { + if obj.FailurePolicy == nil { + policy := Ignore + obj.FailurePolicy = &policy + } +} + +func SetDefaults_ExternalAdmissionHook(obj *ExternalAdmissionHook) { + if obj.FailurePolicy == nil { + policy := Ignore + obj.FailurePolicy = &policy + } +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/doc.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/doc.go new file mode 100644 index 0000000000000..a848f3e928d83 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/doc.go @@ -0,0 +1,22 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// Package v1alpha1 is the v1alpha1 version of the API. +// AdmissionConfiguration and AdmissionPluginConfiguration are legacy static admission plugin configuration +// InitializerConfiguration and ExternalAdmissionHookConfiguration is for the +// new dynamic admission controller configuration. +// +groupName=admissionregistration.k8s.io +package v1alpha1 diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.pb.go new file mode 100644 index 0000000000000..5759fbc6d1793 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.pb.go @@ -0,0 +1,2228 @@ +/* +Copyright 2017 The Kubernetes 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 protoc-gen-gogo. +// source: k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1/generated.proto +// DO NOT EDIT! + +/* + Package v1alpha1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1/generated.proto + + It has these top-level messages: + AdmissionHookClientConfig + ExternalAdmissionHook + ExternalAdmissionHookConfiguration + ExternalAdmissionHookConfigurationList + Initializer + InitializerConfiguration + InitializerConfigurationList + Rule + RuleWithOperations + ServiceReference +*/ +package v1alpha1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *AdmissionHookClientConfig) Reset() { *m = AdmissionHookClientConfig{} } +func (*AdmissionHookClientConfig) ProtoMessage() {} +func (*AdmissionHookClientConfig) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{0} +} + +func (m *ExternalAdmissionHook) Reset() { *m = ExternalAdmissionHook{} } +func (*ExternalAdmissionHook) ProtoMessage() {} +func (*ExternalAdmissionHook) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } + +func (m *ExternalAdmissionHookConfiguration) Reset() { *m = ExternalAdmissionHookConfiguration{} } +func (*ExternalAdmissionHookConfiguration) ProtoMessage() {} +func (*ExternalAdmissionHookConfiguration) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{2} +} + +func (m *ExternalAdmissionHookConfigurationList) Reset() { + *m = ExternalAdmissionHookConfigurationList{} +} +func (*ExternalAdmissionHookConfigurationList) ProtoMessage() {} +func (*ExternalAdmissionHookConfigurationList) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{3} +} + +func (m *Initializer) Reset() { *m = Initializer{} } +func (*Initializer) ProtoMessage() {} +func (*Initializer) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } + +func (m *InitializerConfiguration) Reset() { *m = InitializerConfiguration{} } +func (*InitializerConfiguration) ProtoMessage() {} +func (*InitializerConfiguration) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{5} +} + +func (m *InitializerConfigurationList) Reset() { *m = InitializerConfigurationList{} } +func (*InitializerConfigurationList) ProtoMessage() {} +func (*InitializerConfigurationList) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{6} +} + +func (m *Rule) Reset() { *m = Rule{} } +func (*Rule) ProtoMessage() {} +func (*Rule) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } + +func (m *RuleWithOperations) Reset() { *m = RuleWithOperations{} } +func (*RuleWithOperations) ProtoMessage() {} +func (*RuleWithOperations) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } + +func (m *ServiceReference) Reset() { *m = ServiceReference{} } +func (*ServiceReference) ProtoMessage() {} +func (*ServiceReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } + +func init() { + proto.RegisterType((*AdmissionHookClientConfig)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.AdmissionHookClientConfig") + proto.RegisterType((*ExternalAdmissionHook)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHook") + proto.RegisterType((*ExternalAdmissionHookConfiguration)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfiguration") + proto.RegisterType((*ExternalAdmissionHookConfigurationList)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfigurationList") + proto.RegisterType((*Initializer)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.Initializer") + proto.RegisterType((*InitializerConfiguration)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.InitializerConfiguration") + proto.RegisterType((*InitializerConfigurationList)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.InitializerConfigurationList") + proto.RegisterType((*Rule)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.Rule") + proto.RegisterType((*RuleWithOperations)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.RuleWithOperations") + proto.RegisterType((*ServiceReference)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.ServiceReference") +} +func (m *AdmissionHookClientConfig) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *AdmissionHookClientConfig) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Service.Size())) + n1, err := m.Service.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + if m.CABundle != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.CABundle))) + i += copy(dAtA[i:], m.CABundle) + } + return i, nil +} + +func (m *ExternalAdmissionHook) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ExternalAdmissionHook) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ClientConfig.Size())) + n2, err := m.ClientConfig.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n2 + if len(m.Rules) > 0 { + for _, msg := range m.Rules { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if m.FailurePolicy != nil { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.FailurePolicy))) + i += copy(dAtA[i:], *m.FailurePolicy) + } + return i, nil +} + +func (m *ExternalAdmissionHookConfiguration) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ExternalAdmissionHookConfiguration) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n3, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + if len(m.ExternalAdmissionHooks) > 0 { + for _, msg := range m.ExternalAdmissionHooks { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *ExternalAdmissionHookConfigurationList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ExternalAdmissionHookConfigurationList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n4, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *Initializer) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Initializer) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + if len(m.Rules) > 0 { + for _, msg := range m.Rules { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if m.FailurePolicy != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.FailurePolicy))) + i += copy(dAtA[i:], *m.FailurePolicy) + } + return i, nil +} + +func (m *InitializerConfiguration) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *InitializerConfiguration) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n5, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 + if len(m.Initializers) > 0 { + for _, msg := range m.Initializers { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *InitializerConfigurationList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *InitializerConfigurationList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n6, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n6 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *Rule) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Rule) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.APIGroups) > 0 { + for _, s := range m.APIGroups { + dAtA[i] = 0xa + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.APIVersions) > 0 { + for _, s := range m.APIVersions { + dAtA[i] = 0x12 + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.Resources) > 0 { + for _, s := range m.Resources { + dAtA[i] = 0x1a + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + return i, nil +} + +func (m *RuleWithOperations) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *RuleWithOperations) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Operations) > 0 { + for _, s := range m.Operations { + dAtA[i] = 0xa + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Rule.Size())) + n7, err := m.Rule.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n7 + return i, nil +} + +func (m *ServiceReference) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ServiceReference) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Namespace))) + i += copy(dAtA[i:], m.Namespace) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *AdmissionHookClientConfig) Size() (n int) { + var l int + _ = l + l = m.Service.Size() + n += 1 + l + sovGenerated(uint64(l)) + if m.CABundle != nil { + l = len(m.CABundle) + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *ExternalAdmissionHook) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + l = m.ClientConfig.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Rules) > 0 { + for _, e := range m.Rules { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if m.FailurePolicy != nil { + l = len(*m.FailurePolicy) + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *ExternalAdmissionHookConfiguration) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.ExternalAdmissionHooks) > 0 { + for _, e := range m.ExternalAdmissionHooks { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *ExternalAdmissionHookConfigurationList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *Initializer) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Rules) > 0 { + for _, e := range m.Rules { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if m.FailurePolicy != nil { + l = len(*m.FailurePolicy) + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *InitializerConfiguration) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Initializers) > 0 { + for _, e := range m.Initializers { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *InitializerConfigurationList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *Rule) Size() (n int) { + var l int + _ = l + if len(m.APIGroups) > 0 { + for _, s := range m.APIGroups { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.APIVersions) > 0 { + for _, s := range m.APIVersions { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.Resources) > 0 { + for _, s := range m.Resources { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *RuleWithOperations) Size() (n int) { + var l int + _ = l + if len(m.Operations) > 0 { + for _, s := range m.Operations { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + l = m.Rule.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *ServiceReference) Size() (n int) { + var l int + _ = l + l = len(m.Namespace) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *AdmissionHookClientConfig) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&AdmissionHookClientConfig{`, + `Service:` + strings.Replace(strings.Replace(this.Service.String(), "ServiceReference", "ServiceReference", 1), `&`, ``, 1) + `,`, + `CABundle:` + valueToStringGenerated(this.CABundle) + `,`, + `}`, + }, "") + return s +} +func (this *ExternalAdmissionHook) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ExternalAdmissionHook{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `ClientConfig:` + strings.Replace(strings.Replace(this.ClientConfig.String(), "AdmissionHookClientConfig", "AdmissionHookClientConfig", 1), `&`, ``, 1) + `,`, + `Rules:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Rules), "RuleWithOperations", "RuleWithOperations", 1), `&`, ``, 1) + `,`, + `FailurePolicy:` + valueToStringGenerated(this.FailurePolicy) + `,`, + `}`, + }, "") + return s +} +func (this *ExternalAdmissionHookConfiguration) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ExternalAdmissionHookConfiguration{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ExternalAdmissionHooks:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ExternalAdmissionHooks), "ExternalAdmissionHook", "ExternalAdmissionHook", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ExternalAdmissionHookConfigurationList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ExternalAdmissionHookConfigurationList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ExternalAdmissionHookConfiguration", "ExternalAdmissionHookConfiguration", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *Initializer) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Initializer{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `Rules:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Rules), "Rule", "Rule", 1), `&`, ``, 1) + `,`, + `FailurePolicy:` + valueToStringGenerated(this.FailurePolicy) + `,`, + `}`, + }, "") + return s +} +func (this *InitializerConfiguration) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&InitializerConfiguration{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Initializers:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Initializers), "Initializer", "Initializer", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *InitializerConfigurationList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&InitializerConfigurationList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "InitializerConfiguration", "InitializerConfiguration", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *Rule) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Rule{`, + `APIGroups:` + fmt.Sprintf("%v", this.APIGroups) + `,`, + `APIVersions:` + fmt.Sprintf("%v", this.APIVersions) + `,`, + `Resources:` + fmt.Sprintf("%v", this.Resources) + `,`, + `}`, + }, "") + return s +} +func (this *RuleWithOperations) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RuleWithOperations{`, + `Operations:` + fmt.Sprintf("%v", this.Operations) + `,`, + `Rule:` + strings.Replace(strings.Replace(this.Rule.String(), "Rule", "Rule", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ServiceReference) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ServiceReference{`, + `Namespace:` + fmt.Sprintf("%v", this.Namespace) + `,`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *AdmissionHookClientConfig) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: AdmissionHookClientConfig: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: AdmissionHookClientConfig: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Service", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Service.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field CABundle", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + byteLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.CABundle = append(m.CABundle[:0], dAtA[iNdEx:postIndex]...) + if m.CABundle == nil { + m.CABundle = []byte{} + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ExternalAdmissionHook) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExternalAdmissionHook: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExternalAdmissionHook: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClientConfig", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ClientConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Rules", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Rules = append(m.Rules, RuleWithOperations{}) + if err := m.Rules[len(m.Rules)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FailurePolicy", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := FailurePolicyType(dAtA[iNdEx:postIndex]) + m.FailurePolicy = &s + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ExternalAdmissionHookConfiguration) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExternalAdmissionHookConfiguration: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExternalAdmissionHookConfiguration: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ExternalAdmissionHooks", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ExternalAdmissionHooks = append(m.ExternalAdmissionHooks, ExternalAdmissionHook{}) + if err := m.ExternalAdmissionHooks[len(m.ExternalAdmissionHooks)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ExternalAdmissionHookConfigurationList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExternalAdmissionHookConfigurationList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExternalAdmissionHookConfigurationList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, ExternalAdmissionHookConfiguration{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Initializer) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Initializer: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Initializer: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Rules", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Rules = append(m.Rules, Rule{}) + if err := m.Rules[len(m.Rules)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FailurePolicy", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := FailurePolicyType(dAtA[iNdEx:postIndex]) + m.FailurePolicy = &s + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *InitializerConfiguration) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: InitializerConfiguration: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: InitializerConfiguration: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Initializers", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Initializers = append(m.Initializers, Initializer{}) + if err := m.Initializers[len(m.Initializers)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *InitializerConfigurationList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: InitializerConfigurationList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: InitializerConfigurationList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, InitializerConfiguration{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Rule) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Rule: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Rule: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIGroups", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIGroups = append(m.APIGroups, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIVersions", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIVersions = append(m.APIVersions, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Resources", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Resources = append(m.Resources, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RuleWithOperations) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RuleWithOperations: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RuleWithOperations: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Operations", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Operations = append(m.Operations, OperationType(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Rule", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Rule.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ServiceReference) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ServiceReference: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ServiceReference: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Namespace", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Namespace = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 874 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x56, 0xcf, 0x6f, 0x1b, 0x45, + 0x14, 0xce, 0xd8, 0x8e, 0x6a, 0x8f, 0x6d, 0xb5, 0x1d, 0x41, 0x65, 0x22, 0xb4, 0x6b, 0xed, 0xa1, + 0xb2, 0x40, 0xec, 0x92, 0x80, 0x10, 0x9c, 0xaa, 0x6c, 0x44, 0xc1, 0xa2, 0x3f, 0xa2, 0x69, 0x05, + 0x12, 0x02, 0x89, 0xc9, 0xfa, 0xc5, 0x1e, 0xbc, 0xbf, 0x34, 0x33, 0x6b, 0x35, 0x9c, 0x2a, 0xae, + 0x20, 0x84, 0xc4, 0x3f, 0xc1, 0x95, 0x1b, 0x17, 0xee, 0x39, 0xf6, 0xc8, 0xc9, 0x22, 0xdb, 0xff, + 0x81, 0x43, 0x2f, 0xa0, 0xfd, 0xe5, 0x5d, 0xd7, 0xb6, 0x1a, 0xd5, 0x55, 0x6f, 0x99, 0xf7, 0xf6, + 0x7d, 0xef, 0xfb, 0xbe, 0xbc, 0x37, 0x63, 0x3c, 0x9c, 0x7e, 0x2c, 0x4d, 0x1e, 0x58, 0xd3, 0xe8, + 0x04, 0x84, 0x0f, 0x0a, 0xa4, 0x15, 0x4e, 0xc7, 0x16, 0x0b, 0xb9, 0xb4, 0xd8, 0xc8, 0xe3, 0x52, + 0xf2, 0xc0, 0x17, 0x30, 0xe6, 0x52, 0x09, 0xa6, 0x78, 0xe0, 0x5b, 0xb3, 0x7d, 0xe6, 0x86, 0x13, + 0xb6, 0x6f, 0x8d, 0xc1, 0x07, 0xc1, 0x14, 0x8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ging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.proto new file mode 100644 index 0000000000000..da82fb54a52d9 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.proto @@ -0,0 +1,199 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.client_go.pkg.apis.admissionregistration.v1alpha1; + +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v1alpha1"; + +// AdmissionHookClientConfig contains the information to make a TLS +// connection with the webhook +message AdmissionHookClientConfig { + // Service is a reference to the service for this webhook. If there is only + // one port open for the service, that port will be used. If there are multiple + // ports open, port 443 will be used if it is open, otherwise it is an error. + // Required + optional ServiceReference service = 1; + + // CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. + // Required + optional bytes caBundle = 2; +} + +// ExternalAdmissionHook describes an external admission webhook and the +// resources and operations it applies to. +message ExternalAdmissionHook { + // The name of the external admission webhook. + // Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where + // "imagepolicy" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required. + optional string name = 1; + + // ClientConfig defines how to communicate with the hook. + // Required + optional AdmissionHookClientConfig clientConfig = 2; + + // Rules describes what operations on what resources/subresources the webhook cares about. + // The webhook cares about an operation if it matches _any_ Rule. + repeated RuleWithOperations rules = 3; + + // FailurePolicy defines how unrecognized errors from the admission endpoint are handled - + // allowed values are Ignore or Fail. Defaults to Ignore. + // +optional + optional string failurePolicy = 4; +} + +// ExternalAdmissionHookConfiguration describes the configuration of initializers. +message ExternalAdmissionHookConfiguration { + // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // ExternalAdmissionHooks is a list of external admission webhooks and the + // affected resources and operations. + // +optional + // +patchMergeKey=name + // +patchStrategy=merge + repeated ExternalAdmissionHook externalAdmissionHooks = 2; +} + +// ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration. +message ExternalAdmissionHookConfigurationList { + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // List of ExternalAdmissionHookConfiguration. + repeated ExternalAdmissionHookConfiguration items = 2; +} + +// Initializer describes the name and the failure policy of an initializer, and +// what resources it applies to. +message Initializer { + // Name is the identifier of the initializer. It will be added to the + // object that needs to be initialized. + // Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where + // "alwayspullimages" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required + optional string name = 1; + + // Rules describes what resources/subresources the initializer cares about. + // The initializer cares about an operation if it matches _any_ Rule. + repeated Rule rules = 2; + + // FailurePolicy defines what happens if the responsible initializer controller + // fails to takes action. Allowed values are Ignore, or Fail. If "Ignore" is + // set, initializer is removed from the initializers list of an object if + // the timeout is reached; If "Fail" is set, admissionregistration returns timeout error + // if the timeout is reached. + optional string failurePolicy = 3; +} + +// InitializerConfiguration describes the configuration of initializers. +message InitializerConfiguration { + // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Initializers is a list of resources and their default initializers + // Order-sensitive. + // When merging multiple InitializerConfigurations, we sort the initializers + // from different InitializerConfigurations by the name of the + // InitializerConfigurations; the order of the initializers from the same + // InitializerConfiguration is preserved. + // +patchMergeKey=name + // +patchStrategy=merge + // +optional + repeated Initializer initializers = 2; +} + +// InitializerConfigurationList is a list of InitializerConfiguration. +message InitializerConfigurationList { + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // List of InitializerConfiguration. + repeated InitializerConfiguration items = 2; +} + +// Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended +// to make sure that all the tuple expansions are valid. +message Rule { + // APIGroups is the API groups the resources belong to. '*' is all groups. + // If '*' is present, the length of the slice must be one. + // Required. + repeated string apiGroups = 1; + + // APIVersions is the API versions the resources belong to. '*' is all versions. + // If '*' is present, the length of the slice must be one. + // Required. + repeated string apiVersions = 2; + + // Resources is a list of resources this rule applies to. + // + // For example: + // 'pods' means pods. + // 'pods/log' means the log subresource of pods. + // '*' means all resources, but not subresources. + // 'pods/*' means all subresources of pods. + // '*/scale' means all scale subresources. + // '*/*' means all resources and their subresources. + // + // If '*' or '*/*' is present, the length of the slice must be one. + // Required. + repeated string resources = 3; +} + +// RuleWithOperations is a tuple of Operations and Resources. It is recommended to make +// sure that all the tuple expansions are valid. +message RuleWithOperations { + // Operations is the operations the admission hook cares about - CREATE, UPDATE, or * + // for all operations. + // If '*' is present, the length of the slice must be one. + // Required. + repeated string operations = 1; + + // Rule is embedded, it describes other criteria of the rule, like + // APIGroups, APIVersions, Resources, etc. + optional Rule rule = 2; +} + +// ServiceReference holds a reference to Service.legacy.k8s.io +message ServiceReference { + // Namespace is the namespace of the service + // Required + optional string namespace = 1; + + // Name is the name of the service + // Required + optional string name = 2; +} + diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/register.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/register.go new file mode 100644 index 0000000000000..10fa4a161b5bb --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/register.go @@ -0,0 +1,60 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +const GroupName = "admissionregistration.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme +) + +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs) +} + +// Adds the list of known types to scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &InitializerConfiguration{}, + &InitializerConfigurationList{}, + &ExternalAdmissionHookConfiguration{}, + &ExternalAdmissionHookConfigurationList{}, + ) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) + return nil +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.generated.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.generated.go new file mode 100644 index 0000000000000..8a6563730bc40 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.generated.go @@ -0,0 +1,4232 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +// ************************************************************ +// DO NOT EDIT. +// THIS FILE IS AUTO-GENERATED BY codecgen. +// ************************************************************ + +package v1alpha1 + +import ( + "errors" + "fmt" + codec1978 "github.com/ugorji/go/codec" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" + "reflect" + "runtime" + time "time" +) + +const ( + // ----- content types ---- + codecSelferC_UTF81234 = 1 + codecSelferC_RAW1234 = 0 + // ----- value types used ---- + codecSelferValueTypeArray1234 = 10 + codecSelferValueTypeMap1234 = 9 + // ----- containerStateValues ---- + codecSelfer_containerMapKey1234 = 2 + codecSelfer_containerMapValue1234 = 3 + codecSelfer_containerMapEnd1234 = 4 + codecSelfer_containerArrayElem1234 = 6 + codecSelfer_containerArrayEnd1234 = 7 +) + +var ( + codecSelferBitsize1234 = uint8(reflect.TypeOf(uint(0)).Bits()) + codecSelferOnlyMapOrArrayEncodeToStructErr1234 = errors.New(`only encoded map or array can be decoded into a struct`) +) + +type codecSelfer1234 struct{} + +func init() { + if codec1978.GenVersion != 5 { + _, file, _, _ := runtime.Caller(0) + err := fmt.Errorf("codecgen version mismatch: current: %v, need %v. Re-generate file: %v", + 5, codec1978.GenVersion, file) + panic(err) + } + if false { // reference the types, but skip this branch at build/run time + var v0 pkg1_v1.TypeMeta + var v1 pkg2_types.UID + var v2 time.Time + _, _, _ = v0, v1, v2 + } +} + +func (x *InitializerConfiguration) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = len(x.Initializers) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Initializers == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceInitializer(([]Initializer)(x.Initializers), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("initializers")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Initializers == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceInitializer(([]Initializer)(x.Initializers), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *InitializerConfiguration) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *InitializerConfiguration) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "initializers": + if r.TryDecodeAsNil() { + x.Initializers = nil + } else { + yyv10 := &x.Initializers + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceInitializer((*[]Initializer)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *InitializerConfiguration) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Initializers = nil + } else { + yyv19 := &x.Initializers + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceInitializer((*[]Initializer)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *InitializerConfigurationList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceInitializerConfiguration(([]InitializerConfiguration)(x.Items), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceInitializerConfiguration(([]InitializerConfiguration)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *InitializerConfigurationList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *InitializerConfigurationList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceInitializerConfiguration((*[]InitializerConfiguration)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *InitializerConfigurationList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceInitializerConfiguration((*[]InitializerConfiguration)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *Initializer) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = len(x.Rules) != 0 + yyq2[2] = x.FailurePolicy != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Rules == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encSliceRule(([]Rule)(x.Rules), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rules")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Rules == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encSliceRule(([]Rule)(x.Rules), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.FailurePolicy == nil { + r.EncodeNil() + } else { + yy10 := *x.FailurePolicy + yy10.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("failurePolicy")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.FailurePolicy == nil { + r.EncodeNil() + } else { + yy12 := *x.FailurePolicy + yy12.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *Initializer) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *Initializer) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "rules": + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv6 := &x.Rules + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSliceRule((*[]Rule)(yyv6), d) + } + } + case "failurePolicy": + if r.TryDecodeAsNil() { + if x.FailurePolicy != nil { + x.FailurePolicy = nil + } + } else { + if x.FailurePolicy == nil { + x.FailurePolicy = new(FailurePolicyType) + } + x.FailurePolicy.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *Initializer) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv10 := &x.Name + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv12 := &x.Rules + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + h.decSliceRule((*[]Rule)(yyv12), d) + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.FailurePolicy != nil { + x.FailurePolicy = nil + } + } else { + if x.FailurePolicy == nil { + x.FailurePolicy = new(FailurePolicyType) + } + x.FailurePolicy.CodecDecodeSelf(d) + } + for { + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj9-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *Rule) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.APIGroups) != 0 + yyq2[1] = len(x.APIVersions) != 0 + yyq2[2] = len(x.Resources) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiGroups")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.APIVersions == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.APIVersions, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersions")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.APIVersions == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.APIVersions, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Resources == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resources")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Resources == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *Rule) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *Rule) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "apiGroups": + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv4 := &x.APIGroups + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "apiVersions": + if r.TryDecodeAsNil() { + x.APIVersions = nil + } else { + yyv6 := &x.APIVersions + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + case "resources": + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv8 := &x.Resources + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *Rule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv11 := &x.APIGroups + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + z.F.DecSliceStringX(yyv11, false, d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersions = nil + } else { + yyv13 := &x.APIVersions + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + z.F.DecSliceStringX(yyv13, false, d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv15 := &x.Resources + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + z.F.DecSliceStringX(yyv15, false, d) + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x FailurePolicyType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *FailurePolicyType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *ExternalAdmissionHookConfiguration) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = len(x.ExternalAdmissionHooks) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.ExternalAdmissionHooks == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceExternalAdmissionHook(([]ExternalAdmissionHook)(x.ExternalAdmissionHooks), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("externalAdmissionHooks")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ExternalAdmissionHooks == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceExternalAdmissionHook(([]ExternalAdmissionHook)(x.ExternalAdmissionHooks), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ExternalAdmissionHookConfiguration) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ExternalAdmissionHookConfiguration) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "externalAdmissionHooks": + if r.TryDecodeAsNil() { + x.ExternalAdmissionHooks = nil + } else { + yyv10 := &x.ExternalAdmissionHooks + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceExternalAdmissionHook((*[]ExternalAdmissionHook)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ExternalAdmissionHookConfiguration) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ExternalAdmissionHooks = nil + } else { + yyv19 := &x.ExternalAdmissionHooks + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceExternalAdmissionHook((*[]ExternalAdmissionHook)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ExternalAdmissionHookConfigurationList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceExternalAdmissionHookConfiguration(([]ExternalAdmissionHookConfiguration)(x.Items), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceExternalAdmissionHookConfiguration(([]ExternalAdmissionHookConfiguration)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ExternalAdmissionHookConfigurationList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ExternalAdmissionHookConfigurationList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceExternalAdmissionHookConfiguration((*[]ExternalAdmissionHookConfiguration)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ExternalAdmissionHookConfigurationList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceExternalAdmissionHookConfiguration((*[]ExternalAdmissionHookConfiguration)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ExternalAdmissionHook) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = len(x.Rules) != 0 + yyq2[3] = x.FailurePolicy != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy7 := &x.ClientConfig + yy7.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("clientConfig")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy9 := &x.ClientConfig + yy9.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Rules == nil { + r.EncodeNil() + } else { + yym12 := z.EncBinary() + _ = yym12 + if false { + } else { + h.encSliceRuleWithOperations(([]RuleWithOperations)(x.Rules), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rules")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Rules == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + h.encSliceRuleWithOperations(([]RuleWithOperations)(x.Rules), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.FailurePolicy == nil { + r.EncodeNil() + } else { + yy15 := *x.FailurePolicy + yy15.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("failurePolicy")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.FailurePolicy == nil { + r.EncodeNil() + } else { + yy17 := *x.FailurePolicy + yy17.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ExternalAdmissionHook) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ExternalAdmissionHook) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "clientConfig": + if r.TryDecodeAsNil() { + x.ClientConfig = AdmissionHookClientConfig{} + } else { + yyv6 := &x.ClientConfig + yyv6.CodecDecodeSelf(d) + } + case "rules": + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv7 := &x.Rules + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + h.decSliceRuleWithOperations((*[]RuleWithOperations)(yyv7), d) + } + } + case "failurePolicy": + if r.TryDecodeAsNil() { + if x.FailurePolicy != nil { + x.FailurePolicy = nil + } + } else { + if x.FailurePolicy == nil { + x.FailurePolicy = new(FailurePolicyType) + } + x.FailurePolicy.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ExternalAdmissionHook) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv11 := &x.Name + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ClientConfig = AdmissionHookClientConfig{} + } else { + yyv13 := &x.ClientConfig + yyv13.CodecDecodeSelf(d) + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv14 := &x.Rules + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + h.decSliceRuleWithOperations((*[]RuleWithOperations)(yyv14), d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.FailurePolicy != nil { + x.FailurePolicy = nil + } + } else { + if x.FailurePolicy == nil { + x.FailurePolicy = new(FailurePolicyType) + } + x.FailurePolicy.CodecDecodeSelf(d) + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *RuleWithOperations) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Operations) != 0 + yyq2[1] = len(x.APIGroups) != 0 + yyq2[2] = len(x.APIVersions) != 0 + yyq2[3] = len(x.Resources) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Operations == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSliceOperationType(([]OperationType)(x.Operations), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("operations")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Operations == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSliceOperationType(([]OperationType)(x.Operations), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiGroups")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.APIVersions == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceStringV(x.APIVersions, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersions")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.APIVersions == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceStringV(x.APIVersions, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Resources == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resources")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Resources == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *RuleWithOperations) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *RuleWithOperations) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "operations": + if r.TryDecodeAsNil() { + x.Operations = nil + } else { + yyv4 := &x.Operations + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSliceOperationType((*[]OperationType)(yyv4), d) + } + } + case "apiGroups": + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv6 := &x.APIGroups + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + case "apiVersions": + if r.TryDecodeAsNil() { + x.APIVersions = nil + } else { + yyv8 := &x.APIVersions + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + case "resources": + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv10 := &x.Resources + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + z.F.DecSliceStringX(yyv10, false, d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *RuleWithOperations) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Operations = nil + } else { + yyv13 := &x.Operations + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSliceOperationType((*[]OperationType)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv15 := &x.APIGroups + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + z.F.DecSliceStringX(yyv15, false, d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersions = nil + } else { + yyv17 := &x.APIVersions + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + z.F.DecSliceStringX(yyv17, false, d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv19 := &x.Resources + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + z.F.DecSliceStringX(yyv19, false, d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x OperationType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *OperationType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *AdmissionHookClientConfig) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy4 := &x.Service + yy4.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("service")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy6 := &x.Service + yy6.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.CABundle == nil { + r.EncodeNil() + } else { + yym9 := z.EncBinary() + _ = yym9 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.CABundle)) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("caBundle")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.CABundle == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.CABundle)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *AdmissionHookClientConfig) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *AdmissionHookClientConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "service": + if r.TryDecodeAsNil() { + x.Service = ServiceReference{} + } else { + yyv4 := &x.Service + yyv4.CodecDecodeSelf(d) + } + case "caBundle": + if r.TryDecodeAsNil() { + x.CABundle = nil + } else { + yyv5 := &x.CABundle + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *yyv5 = r.DecodeBytes(*(*[]byte)(yyv5), false, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *AdmissionHookClientConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Service = ServiceReference{} + } else { + yyv8 := &x.Service + yyv8.CodecDecodeSelf(d) + } + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CABundle = nil + } else { + yyv9 := &x.CABundle + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *yyv9 = r.DecodeBytes(*(*[]byte)(yyv9), false, false) + } + } + for { + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj7-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ServiceReference) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ServiceReference) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ServiceReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv4 := &x.Namespace + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv6 := &x.Name + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ServiceReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv9 := &x.Namespace + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv11 := &x.Name + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) encSliceInitializer(v []Initializer, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceInitializer(v *[]Initializer, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Initializer{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 48) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]Initializer, yyrl1) + } + } else { + yyv1 = make([]Initializer, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Initializer{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Initializer{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Initializer{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Initializer{}) // var yyz1 Initializer + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = Initializer{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Initializer{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceInitializerConfiguration(v []InitializerConfiguration, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceInitializerConfiguration(v *[]InitializerConfiguration, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []InitializerConfiguration{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]InitializerConfiguration, yyrl1) + } + } else { + yyv1 = make([]InitializerConfiguration, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = InitializerConfiguration{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, InitializerConfiguration{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = InitializerConfiguration{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, InitializerConfiguration{}) // var yyz1 InitializerConfiguration + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = InitializerConfiguration{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []InitializerConfiguration{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceRule(v []Rule, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceRule(v *[]Rule, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Rule{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 72) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]Rule, yyrl1) + } + } else { + yyv1 = make([]Rule, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Rule{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Rule{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Rule{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Rule{}) // var yyz1 Rule + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = Rule{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Rule{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceExternalAdmissionHook(v []ExternalAdmissionHook, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceExternalAdmissionHook(v *[]ExternalAdmissionHook, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ExternalAdmissionHook{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 104) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]ExternalAdmissionHook, yyrl1) + } + } else { + yyv1 = make([]ExternalAdmissionHook, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHook{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ExternalAdmissionHook{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHook{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ExternalAdmissionHook{}) // var yyz1 ExternalAdmissionHook + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHook{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ExternalAdmissionHook{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceExternalAdmissionHookConfiguration(v []ExternalAdmissionHookConfiguration, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceExternalAdmissionHookConfiguration(v *[]ExternalAdmissionHookConfiguration, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ExternalAdmissionHookConfiguration{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]ExternalAdmissionHookConfiguration, yyrl1) + } + } else { + yyv1 = make([]ExternalAdmissionHookConfiguration, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHookConfiguration{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ExternalAdmissionHookConfiguration{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHookConfiguration{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ExternalAdmissionHookConfiguration{}) // var yyz1 ExternalAdmissionHookConfiguration + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHookConfiguration{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ExternalAdmissionHookConfiguration{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceRuleWithOperations(v []RuleWithOperations, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceRuleWithOperations(v *[]RuleWithOperations, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []RuleWithOperations{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 96) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]RuleWithOperations, yyrl1) + } + } else { + yyv1 = make([]RuleWithOperations, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = RuleWithOperations{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, RuleWithOperations{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = RuleWithOperations{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, RuleWithOperations{}) // var yyz1 RuleWithOperations + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = RuleWithOperations{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []RuleWithOperations{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceOperationType(v []OperationType, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yyv1.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceOperationType(v *[]OperationType, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []OperationType{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]OperationType, yyrl1) + } + } else { + yyv1 = make([]OperationType, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 OperationType + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []OperationType{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.go new file mode 100644 index 0000000000000..67a76dff98144 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.go @@ -0,0 +1,214 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// +genclient=true + +// InitializerConfiguration describes the configuration of initializers. +type InitializerConfiguration struct { + metav1.TypeMeta `json:",inline"` + // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Initializers is a list of resources and their default initializers + // Order-sensitive. + // When merging multiple InitializerConfigurations, we sort the initializers + // from different InitializerConfigurations by the name of the + // InitializerConfigurations; the order of the initializers from the same + // InitializerConfiguration is preserved. + // +patchMergeKey=name + // +patchStrategy=merge + // +optional + Initializers []Initializer `json:"initializers,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,2,rep,name=initializers"` +} + +// InitializerConfigurationList is a list of InitializerConfiguration. +type InitializerConfigurationList struct { + metav1.TypeMeta `json:",inline"` + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // List of InitializerConfiguration. + Items []InitializerConfiguration `json:"items" protobuf:"bytes,2,rep,name=items"` +} + +// Initializer describes the name and the failure policy of an initializer, and +// what resources it applies to. +type Initializer struct { + // Name is the identifier of the initializer. It will be added to the + // object that needs to be initialized. + // Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where + // "alwayspullimages" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required + Name string `json:"name" protobuf:"bytes,1,opt,name=name"` + + // Rules describes what resources/subresources the initializer cares about. + // The initializer cares about an operation if it matches _any_ Rule. + Rules []Rule `json:"rules,omitempty" protobuf:"bytes,2,rep,name=rules"` + + // FailurePolicy defines what happens if the responsible initializer controller + // fails to takes action. Allowed values are Ignore, or Fail. If "Ignore" is + // set, initializer is removed from the initializers list of an object if + // the timeout is reached; If "Fail" is set, admissionregistration returns timeout error + // if the timeout is reached. + FailurePolicy *FailurePolicyType `json:"failurePolicy,omitempty" protobuf:"bytes,3,opt,name=failurePolicy,casttype=FailurePolicyType"` +} + +// Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended +// to make sure that all the tuple expansions are valid. +type Rule struct { + // APIGroups is the API groups the resources belong to. '*' is all groups. + // If '*' is present, the length of the slice must be one. + // Required. + APIGroups []string `json:"apiGroups,omitempty" protobuf:"bytes,1,rep,name=apiGroups"` + + // APIVersions is the API versions the resources belong to. '*' is all versions. + // If '*' is present, the length of the slice must be one. + // Required. + APIVersions []string `json:"apiVersions,omitempty" protobuf:"bytes,2,rep,name=apiVersions"` + + // Resources is a list of resources this rule applies to. + // + // For example: + // 'pods' means pods. + // 'pods/log' means the log subresource of pods. + // '*' means all resources, but not subresources. + // 'pods/*' means all subresources of pods. + // '*/scale' means all scale subresources. + // '*/*' means all resources and their subresources. + // + // If '*' or '*/*' is present, the length of the slice must be one. + // Required. + Resources []string `json:"resources,omitempty" protobuf:"bytes,3,rep,name=resources"` +} + +type FailurePolicyType string + +const ( + // Ignore means the initilizer is removed from the initializers list of an + // object if the initializer is timed out. + Ignore FailurePolicyType = "Ignore" + // For 1.7, only "Ignore" is allowed. "Fail" will be allowed when the + // extensible admission feature is beta. + Fail FailurePolicyType = "Fail" +) + +// +genclient=true + +// ExternalAdmissionHookConfiguration describes the configuration of initializers. +type ExternalAdmissionHookConfiguration struct { + metav1.TypeMeta `json:",inline"` + // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + // ExternalAdmissionHooks is a list of external admission webhooks and the + // affected resources and operations. + // +optional + // +patchMergeKey=name + // +patchStrategy=merge + ExternalAdmissionHooks []ExternalAdmissionHook `json:"externalAdmissionHooks,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,2,rep,name=externalAdmissionHooks"` +} + +// ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration. +type ExternalAdmissionHookConfigurationList struct { + metav1.TypeMeta `json:",inline"` + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + // List of ExternalAdmissionHookConfiguration. + Items []ExternalAdmissionHookConfiguration `json:"items" protobuf:"bytes,2,rep,name=items"` +} + +// ExternalAdmissionHook describes an external admission webhook and the +// resources and operations it applies to. +type ExternalAdmissionHook struct { + // The name of the external admission webhook. + // Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where + // "imagepolicy" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required. + Name string `json:"name" protobuf:"bytes,1,opt,name=name"` + + // ClientConfig defines how to communicate with the hook. + // Required + ClientConfig AdmissionHookClientConfig `json:"clientConfig" protobuf:"bytes,2,opt,name=clientConfig"` + + // Rules describes what operations on what resources/subresources the webhook cares about. + // The webhook cares about an operation if it matches _any_ Rule. + Rules []RuleWithOperations `json:"rules,omitempty" protobuf:"bytes,3,rep,name=rules"` + + // FailurePolicy defines how unrecognized errors from the admission endpoint are handled - + // allowed values are Ignore or Fail. Defaults to Ignore. + // +optional + FailurePolicy *FailurePolicyType `json:"failurePolicy,omitempty" protobuf:"bytes,4,opt,name=failurePolicy,casttype=FailurePolicyType"` +} + +// RuleWithOperations is a tuple of Operations and Resources. It is recommended to make +// sure that all the tuple expansions are valid. +type RuleWithOperations struct { + // Operations is the operations the admission hook cares about - CREATE, UPDATE, or * + // for all operations. + // If '*' is present, the length of the slice must be one. + // Required. + Operations []OperationType `json:"operations,omitempty" protobuf:"bytes,1,rep,name=operations,casttype=OperationType"` + // Rule is embedded, it describes other criteria of the rule, like + // APIGroups, APIVersions, Resources, etc. + Rule `json:",inline" protobuf:"bytes,2,opt,name=rule"` +} + +type OperationType string + +// The constants should be kept in sync with those defined in k8s.io/kubernetes/pkg/admission/interface.go. +const ( + OperationAll OperationType = "*" + Create OperationType = "CREATE" + Update OperationType = "UPDATE" + Delete OperationType = "DELETE" + Connect OperationType = "CONNECT" +) + +// AdmissionHookClientConfig contains the information to make a TLS +// connection with the webhook +type AdmissionHookClientConfig struct { + // Service is a reference to the service for this webhook. If there is only + // one port open for the service, that port will be used. If there are multiple + // ports open, port 443 will be used if it is open, otherwise it is an error. + // Required + Service ServiceReference `json:"service" protobuf:"bytes,1,opt,name=service"` + // CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. + // Required + CABundle []byte `json:"caBundle" protobuf:"bytes,2,opt,name=caBundle"` +} + +// ServiceReference holds a reference to Service.legacy.k8s.io +type ServiceReference struct { + // Namespace is the namespace of the service + // Required + Namespace string `json:"namespace" protobuf:"bytes,1,opt,name=namespace"` + // Name is the name of the service + // Required + Name string `json:"name" protobuf:"bytes,2,opt,name=name"` +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types_swagger_doc_generated.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types_swagger_doc_generated.go new file mode 100644 index 0000000000000..80f9120b37b20 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types_swagger_doc_generated.go @@ -0,0 +1,133 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +package v1alpha1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_AdmissionHookClientConfig = map[string]string{ + "": "AdmissionHookClientConfig contains the information to make a TLS connection with the webhook", + "service": "Service is a reference to the service for this webhook. If there is only one port open for the service, that port will be used. If there are multiple ports open, port 443 will be used if it is open, otherwise it is an error. Required", + "caBundle": "CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. Required", +} + +func (AdmissionHookClientConfig) SwaggerDoc() map[string]string { + return map_AdmissionHookClientConfig +} + +var map_ExternalAdmissionHook = map[string]string{ + "": "ExternalAdmissionHook describes an external admission webhook and the resources and operations it applies to.", + "name": "The name of the external admission webhook. Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where \"imagepolicy\" is the name of the webhook, and kubernetes.io is the name of the organization. Required.", + "clientConfig": "ClientConfig defines how to communicate with the hook. Required", + "rules": "Rules describes what operations on what resources/subresources the webhook cares about. The webhook cares about an operation if it matches _any_ Rule.", + "failurePolicy": "FailurePolicy defines how unrecognized errors from the admission endpoint are handled - allowed values are Ignore or Fail. Defaults to Ignore.", +} + +func (ExternalAdmissionHook) SwaggerDoc() map[string]string { + return map_ExternalAdmissionHook +} + +var map_ExternalAdmissionHookConfiguration = map[string]string{ + "": "ExternalAdmissionHookConfiguration describes the configuration of initializers.", + "metadata": "Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.", + "externalAdmissionHooks": "ExternalAdmissionHooks is a list of external admission webhooks and the affected resources and operations.", +} + +func (ExternalAdmissionHookConfiguration) SwaggerDoc() map[string]string { + return map_ExternalAdmissionHookConfiguration +} + +var map_ExternalAdmissionHookConfigurationList = map[string]string{ + "": "ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration.", + "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "items": "List of ExternalAdmissionHookConfiguration.", +} + +func (ExternalAdmissionHookConfigurationList) SwaggerDoc() map[string]string { + return map_ExternalAdmissionHookConfigurationList +} + +var map_Initializer = map[string]string{ + "": "Initializer describes the name and the failure policy of an initializer, and what resources it applies to.", + "name": "Name is the identifier of the initializer. It will be added to the object that needs to be initialized. Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where \"alwayspullimages\" is the name of the webhook, and kubernetes.io is the name of the organization. Required", + "rules": "Rules describes what resources/subresources the initializer cares about. The initializer cares about an operation if it matches _any_ Rule.", + "failurePolicy": "FailurePolicy defines what happens if the responsible initializer controller fails to takes action. Allowed values are Ignore, or Fail. If \"Ignore\" is set, initializer is removed from the initializers list of an object if the timeout is reached; If \"Fail\" is set, admissionregistration returns timeout error if the timeout is reached.", +} + +func (Initializer) SwaggerDoc() map[string]string { + return map_Initializer +} + +var map_InitializerConfiguration = map[string]string{ + "": "InitializerConfiguration describes the configuration of initializers.", + "metadata": "Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.", + "initializers": "Initializers is a list of resources and their default initializers Order-sensitive. When merging multiple InitializerConfigurations, we sort the initializers from different InitializerConfigurations by the name of the InitializerConfigurations; the order of the initializers from the same InitializerConfiguration is preserved.", +} + +func (InitializerConfiguration) SwaggerDoc() map[string]string { + return map_InitializerConfiguration +} + +var map_InitializerConfigurationList = map[string]string{ + "": "InitializerConfigurationList is a list of InitializerConfiguration.", + "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "items": "List of InitializerConfiguration.", +} + +func (InitializerConfigurationList) SwaggerDoc() map[string]string { + return map_InitializerConfigurationList +} + +var map_Rule = map[string]string{ + "": "Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended to make sure that all the tuple expansions are valid.", + "apiGroups": "APIGroups is the API groups the resources belong to. '*' is all groups. If '*' is present, the length of the slice must be one. Required.", + "apiVersions": "APIVersions is the API versions the resources belong to. '*' is all versions. If '*' is present, the length of the slice must be one. Required.", + "resources": "Resources is a list of resources this rule applies to.\n\nFor example: 'pods' means pods. 'pods/log' means the log subresource of pods. '*' means all resources, but not subresources. 'pods/*' means all subresources of pods. '*/scale' means all scale subresources. '*/*' means all resources and their subresources.\n\nIf '*' or '*/*' is present, the length of the slice must be one. Required.", +} + +func (Rule) SwaggerDoc() map[string]string { + return map_Rule +} + +var map_RuleWithOperations = map[string]string{ + "": "RuleWithOperations is a tuple of Operations and Resources. It is recommended to make sure that all the tuple expansions are valid.", + "operations": "Operations is the operations the admission hook cares about - CREATE, UPDATE, or * for all operations. If '*' is present, the length of the slice must be one. Required.", +} + +func (RuleWithOperations) SwaggerDoc() map[string]string { + return map_RuleWithOperations +} + +var map_ServiceReference = map[string]string{ + "": "ServiceReference holds a reference to Service.legacy.k8s.io", + "namespace": "Namespace is the namespace of the service Required", + "name": "Name is the name of the service Required", +} + +func (ServiceReference) SwaggerDoc() map[string]string { + return map_ServiceReference +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.conversion.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.conversion.go new file mode 100644 index 0000000000000..34c645df47ca7 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.conversion.go @@ -0,0 +1,311 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v1alpha1 + +import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + admissionregistration "k8s.io/client-go/pkg/apis/admissionregistration" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig, + Convert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig, + Convert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook, + Convert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook, + Convert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration, + Convert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration, + Convert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList, + Convert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList, + Convert_v1alpha1_Initializer_To_admissionregistration_Initializer, + Convert_admissionregistration_Initializer_To_v1alpha1_Initializer, + Convert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration, + Convert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration, + Convert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList, + Convert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList, + Convert_v1alpha1_Rule_To_admissionregistration_Rule, + Convert_admissionregistration_Rule_To_v1alpha1_Rule, + Convert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations, + Convert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations, + Convert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference, + Convert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference, + ) +} + +func autoConvert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig(in *AdmissionHookClientConfig, out *admissionregistration.AdmissionHookClientConfig, s conversion.Scope) error { + if err := Convert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference(&in.Service, &out.Service, s); err != nil { + return err + } + out.CABundle = *(*[]byte)(unsafe.Pointer(&in.CABundle)) + return nil +} + +// Convert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig is an autogenerated conversion function. +func Convert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig(in *AdmissionHookClientConfig, out *admissionregistration.AdmissionHookClientConfig, s conversion.Scope) error { + return autoConvert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig(in, out, s) +} + +func autoConvert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig(in *admissionregistration.AdmissionHookClientConfig, out *AdmissionHookClientConfig, s conversion.Scope) error { + if err := Convert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference(&in.Service, &out.Service, s); err != nil { + return err + } + if in.CABundle == nil { + out.CABundle = make([]byte, 0) + } else { + out.CABundle = *(*[]byte)(unsafe.Pointer(&in.CABundle)) + } + return nil +} + +// Convert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig is an autogenerated conversion function. +func Convert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig(in *admissionregistration.AdmissionHookClientConfig, out *AdmissionHookClientConfig, s conversion.Scope) error { + return autoConvert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig(in, out, s) +} + +func autoConvert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook(in *ExternalAdmissionHook, out *admissionregistration.ExternalAdmissionHook, s conversion.Scope) error { + out.Name = in.Name + if err := Convert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig(&in.ClientConfig, &out.ClientConfig, s); err != nil { + return err + } + out.Rules = *(*[]admissionregistration.RuleWithOperations)(unsafe.Pointer(&in.Rules)) + out.FailurePolicy = (*admissionregistration.FailurePolicyType)(unsafe.Pointer(in.FailurePolicy)) + return nil +} + +// Convert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook is an autogenerated conversion function. +func Convert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook(in *ExternalAdmissionHook, out *admissionregistration.ExternalAdmissionHook, s conversion.Scope) error { + return autoConvert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook(in, out, s) +} + +func autoConvert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook(in *admissionregistration.ExternalAdmissionHook, out *ExternalAdmissionHook, s conversion.Scope) error { + out.Name = in.Name + if err := Convert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig(&in.ClientConfig, &out.ClientConfig, s); err != nil { + return err + } + out.Rules = *(*[]RuleWithOperations)(unsafe.Pointer(&in.Rules)) + out.FailurePolicy = (*FailurePolicyType)(unsafe.Pointer(in.FailurePolicy)) + return nil +} + +// Convert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook is an autogenerated conversion function. +func Convert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook(in *admissionregistration.ExternalAdmissionHook, out *ExternalAdmissionHook, s conversion.Scope) error { + return autoConvert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook(in, out, s) +} + +func autoConvert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration(in *ExternalAdmissionHookConfiguration, out *admissionregistration.ExternalAdmissionHookConfiguration, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.ExternalAdmissionHooks = *(*[]admissionregistration.ExternalAdmissionHook)(unsafe.Pointer(&in.ExternalAdmissionHooks)) + return nil +} + +// Convert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration is an autogenerated conversion function. +func Convert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration(in *ExternalAdmissionHookConfiguration, out *admissionregistration.ExternalAdmissionHookConfiguration, s conversion.Scope) error { + return autoConvert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration(in, out, s) +} + +func autoConvert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration(in *admissionregistration.ExternalAdmissionHookConfiguration, out *ExternalAdmissionHookConfiguration, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.ExternalAdmissionHooks = *(*[]ExternalAdmissionHook)(unsafe.Pointer(&in.ExternalAdmissionHooks)) + return nil +} + +// Convert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration is an autogenerated conversion function. +func Convert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration(in *admissionregistration.ExternalAdmissionHookConfiguration, out *ExternalAdmissionHookConfiguration, s conversion.Scope) error { + return autoConvert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration(in, out, s) +} + +func autoConvert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList(in *ExternalAdmissionHookConfigurationList, out *admissionregistration.ExternalAdmissionHookConfigurationList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]admissionregistration.ExternalAdmissionHookConfiguration)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList is an autogenerated conversion function. +func Convert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList(in *ExternalAdmissionHookConfigurationList, out *admissionregistration.ExternalAdmissionHookConfigurationList, s conversion.Scope) error { + return autoConvert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList(in, out, s) +} + +func autoConvert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList(in *admissionregistration.ExternalAdmissionHookConfigurationList, out *ExternalAdmissionHookConfigurationList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]ExternalAdmissionHookConfiguration, 0) + } else { + out.Items = *(*[]ExternalAdmissionHookConfiguration)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList is an autogenerated conversion function. +func Convert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList(in *admissionregistration.ExternalAdmissionHookConfigurationList, out *ExternalAdmissionHookConfigurationList, s conversion.Scope) error { + return autoConvert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList(in, out, s) +} + +func autoConvert_v1alpha1_Initializer_To_admissionregistration_Initializer(in *Initializer, out *admissionregistration.Initializer, s conversion.Scope) error { + out.Name = in.Name + out.Rules = *(*[]admissionregistration.Rule)(unsafe.Pointer(&in.Rules)) + out.FailurePolicy = (*admissionregistration.FailurePolicyType)(unsafe.Pointer(in.FailurePolicy)) + return nil +} + +// Convert_v1alpha1_Initializer_To_admissionregistration_Initializer is an autogenerated conversion function. +func Convert_v1alpha1_Initializer_To_admissionregistration_Initializer(in *Initializer, out *admissionregistration.Initializer, s conversion.Scope) error { + return autoConvert_v1alpha1_Initializer_To_admissionregistration_Initializer(in, out, s) +} + +func autoConvert_admissionregistration_Initializer_To_v1alpha1_Initializer(in *admissionregistration.Initializer, out *Initializer, s conversion.Scope) error { + out.Name = in.Name + out.Rules = *(*[]Rule)(unsafe.Pointer(&in.Rules)) + out.FailurePolicy = (*FailurePolicyType)(unsafe.Pointer(in.FailurePolicy)) + return nil +} + +// Convert_admissionregistration_Initializer_To_v1alpha1_Initializer is an autogenerated conversion function. +func Convert_admissionregistration_Initializer_To_v1alpha1_Initializer(in *admissionregistration.Initializer, out *Initializer, s conversion.Scope) error { + return autoConvert_admissionregistration_Initializer_To_v1alpha1_Initializer(in, out, s) +} + +func autoConvert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration(in *InitializerConfiguration, out *admissionregistration.InitializerConfiguration, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Initializers = *(*[]admissionregistration.Initializer)(unsafe.Pointer(&in.Initializers)) + return nil +} + +// Convert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration is an autogenerated conversion function. +func Convert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration(in *InitializerConfiguration, out *admissionregistration.InitializerConfiguration, s conversion.Scope) error { + return autoConvert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration(in, out, s) +} + +func autoConvert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration(in *admissionregistration.InitializerConfiguration, out *InitializerConfiguration, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Initializers = *(*[]Initializer)(unsafe.Pointer(&in.Initializers)) + return nil +} + +// Convert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration is an autogenerated conversion function. +func Convert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration(in *admissionregistration.InitializerConfiguration, out *InitializerConfiguration, s conversion.Scope) error { + return autoConvert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration(in, out, s) +} + +func autoConvert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList(in *InitializerConfigurationList, out *admissionregistration.InitializerConfigurationList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]admissionregistration.InitializerConfiguration)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList is an autogenerated conversion function. +func Convert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList(in *InitializerConfigurationList, out *admissionregistration.InitializerConfigurationList, s conversion.Scope) error { + return autoConvert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList(in, out, s) +} + +func autoConvert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList(in *admissionregistration.InitializerConfigurationList, out *InitializerConfigurationList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]InitializerConfiguration, 0) + } else { + out.Items = *(*[]InitializerConfiguration)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList is an autogenerated conversion function. +func Convert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList(in *admissionregistration.InitializerConfigurationList, out *InitializerConfigurationList, s conversion.Scope) error { + return autoConvert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList(in, out, s) +} + +func autoConvert_v1alpha1_Rule_To_admissionregistration_Rule(in *Rule, out *admissionregistration.Rule, s conversion.Scope) error { + out.APIGroups = *(*[]string)(unsafe.Pointer(&in.APIGroups)) + out.APIVersions = *(*[]string)(unsafe.Pointer(&in.APIVersions)) + out.Resources = *(*[]string)(unsafe.Pointer(&in.Resources)) + return nil +} + +// Convert_v1alpha1_Rule_To_admissionregistration_Rule is an autogenerated conversion function. +func Convert_v1alpha1_Rule_To_admissionregistration_Rule(in *Rule, out *admissionregistration.Rule, s conversion.Scope) error { + return autoConvert_v1alpha1_Rule_To_admissionregistration_Rule(in, out, s) +} + +func autoConvert_admissionregistration_Rule_To_v1alpha1_Rule(in *admissionregistration.Rule, out *Rule, s conversion.Scope) error { + out.APIGroups = *(*[]string)(unsafe.Pointer(&in.APIGroups)) + out.APIVersions = *(*[]string)(unsafe.Pointer(&in.APIVersions)) + out.Resources = *(*[]string)(unsafe.Pointer(&in.Resources)) + return nil +} + +// Convert_admissionregistration_Rule_To_v1alpha1_Rule is an autogenerated conversion function. +func Convert_admissionregistration_Rule_To_v1alpha1_Rule(in *admissionregistration.Rule, out *Rule, s conversion.Scope) error { + return autoConvert_admissionregistration_Rule_To_v1alpha1_Rule(in, out, s) +} + +func autoConvert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations(in *RuleWithOperations, out *admissionregistration.RuleWithOperations, s conversion.Scope) error { + out.Operations = *(*[]admissionregistration.OperationType)(unsafe.Pointer(&in.Operations)) + if err := Convert_v1alpha1_Rule_To_admissionregistration_Rule(&in.Rule, &out.Rule, s); err != nil { + return err + } + return nil +} + +// Convert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations is an autogenerated conversion function. +func Convert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations(in *RuleWithOperations, out *admissionregistration.RuleWithOperations, s conversion.Scope) error { + return autoConvert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations(in, out, s) +} + +func autoConvert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations(in *admissionregistration.RuleWithOperations, out *RuleWithOperations, s conversion.Scope) error { + out.Operations = *(*[]OperationType)(unsafe.Pointer(&in.Operations)) + if err := Convert_admissionregistration_Rule_To_v1alpha1_Rule(&in.Rule, &out.Rule, s); err != nil { + return err + } + return nil +} + +// Convert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations is an autogenerated conversion function. +func Convert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations(in *admissionregistration.RuleWithOperations, out *RuleWithOperations, s conversion.Scope) error { + return autoConvert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations(in, out, s) +} + +func autoConvert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference(in *ServiceReference, out *admissionregistration.ServiceReference, s conversion.Scope) error { + out.Namespace = in.Namespace + out.Name = in.Name + return nil +} + +// Convert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference is an autogenerated conversion function. +func Convert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference(in *ServiceReference, out *admissionregistration.ServiceReference, s conversion.Scope) error { + return autoConvert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference(in, out, s) +} + +func autoConvert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference(in *admissionregistration.ServiceReference, out *ServiceReference, s conversion.Scope) error { + out.Namespace = in.Namespace + out.Name = in.Name + return nil +} + +// Convert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference is an autogenerated conversion function. +func Convert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference(in *admissionregistration.ServiceReference, out *ServiceReference, s conversion.Scope) error { + return autoConvert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference(in, out, s) +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.deepcopy.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.deepcopy.go new file mode 100644 index 0000000000000..526dbe3a2202e --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.deepcopy.go @@ -0,0 +1,254 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_AdmissionHookClientConfig, InType: reflect.TypeOf(&AdmissionHookClientConfig{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_ExternalAdmissionHook, InType: reflect.TypeOf(&ExternalAdmissionHook{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_ExternalAdmissionHookConfiguration, InType: reflect.TypeOf(&ExternalAdmissionHookConfiguration{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_ExternalAdmissionHookConfigurationList, InType: reflect.TypeOf(&ExternalAdmissionHookConfigurationList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_Initializer, InType: reflect.TypeOf(&Initializer{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_InitializerConfiguration, InType: reflect.TypeOf(&InitializerConfiguration{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_InitializerConfigurationList, InType: reflect.TypeOf(&InitializerConfigurationList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_Rule, InType: reflect.TypeOf(&Rule{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_RuleWithOperations, InType: reflect.TypeOf(&RuleWithOperations{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_ServiceReference, InType: reflect.TypeOf(&ServiceReference{})}, + ) +} + +// DeepCopy_v1alpha1_AdmissionHookClientConfig is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_AdmissionHookClientConfig(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*AdmissionHookClientConfig) + out := out.(*AdmissionHookClientConfig) + *out = *in + if in.CABundle != nil { + in, out := &in.CABundle, &out.CABundle + *out = make([]byte, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1alpha1_ExternalAdmissionHook is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_ExternalAdmissionHook(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHook) + out := out.(*ExternalAdmissionHook) + *out = *in + if err := DeepCopy_v1alpha1_AdmissionHookClientConfig(&in.ClientConfig, &out.ClientConfig, c); err != nil { + return err + } + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]RuleWithOperations, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_RuleWithOperations(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.FailurePolicy != nil { + in, out := &in.FailurePolicy, &out.FailurePolicy + *out = new(FailurePolicyType) + **out = **in + } + return nil + } +} + +// DeepCopy_v1alpha1_ExternalAdmissionHookConfiguration is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_ExternalAdmissionHookConfiguration(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHookConfiguration) + out := out.(*ExternalAdmissionHookConfiguration) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.ExternalAdmissionHooks != nil { + in, out := &in.ExternalAdmissionHooks, &out.ExternalAdmissionHooks + *out = make([]ExternalAdmissionHook, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_ExternalAdmissionHook(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_ExternalAdmissionHookConfigurationList is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_ExternalAdmissionHookConfigurationList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHookConfigurationList) + out := out.(*ExternalAdmissionHookConfigurationList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ExternalAdmissionHookConfiguration, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_ExternalAdmissionHookConfiguration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_Initializer is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_Initializer(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Initializer) + out := out.(*Initializer) + *out = *in + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]Rule, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_Rule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.FailurePolicy != nil { + in, out := &in.FailurePolicy, &out.FailurePolicy + *out = new(FailurePolicyType) + **out = **in + } + return nil + } +} + +// DeepCopy_v1alpha1_InitializerConfiguration is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_InitializerConfiguration(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*InitializerConfiguration) + out := out.(*InitializerConfiguration) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.Initializers != nil { + in, out := &in.Initializers, &out.Initializers + *out = make([]Initializer, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_Initializer(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_InitializerConfigurationList is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_InitializerConfigurationList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*InitializerConfigurationList) + out := out.(*InitializerConfigurationList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]InitializerConfiguration, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_InitializerConfiguration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_Rule is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_Rule(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Rule) + out := out.(*Rule) + *out = *in + if in.APIGroups != nil { + in, out := &in.APIGroups, &out.APIGroups + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.APIVersions != nil { + in, out := &in.APIVersions, &out.APIVersions + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Resources != nil { + in, out := &in.Resources, &out.Resources + *out = make([]string, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1alpha1_RuleWithOperations is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_RuleWithOperations(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RuleWithOperations) + out := out.(*RuleWithOperations) + *out = *in + if in.Operations != nil { + in, out := &in.Operations, &out.Operations + *out = make([]OperationType, len(*in)) + copy(*out, *in) + } + if err := DeepCopy_v1alpha1_Rule(&in.Rule, &out.Rule, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1alpha1_ServiceReference is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_ServiceReference(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ServiceReference) + out := out.(*ServiceReference) + *out = *in + return nil + } +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.defaults.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.defaults.go new file mode 100644 index 0000000000000..74fea7f418913 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.defaults.go @@ -0,0 +1,70 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1alpha1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + scheme.AddTypeDefaultingFunc(&ExternalAdmissionHookConfiguration{}, func(obj interface{}) { + SetObjectDefaults_ExternalAdmissionHookConfiguration(obj.(*ExternalAdmissionHookConfiguration)) + }) + scheme.AddTypeDefaultingFunc(&ExternalAdmissionHookConfigurationList{}, func(obj interface{}) { + SetObjectDefaults_ExternalAdmissionHookConfigurationList(obj.(*ExternalAdmissionHookConfigurationList)) + }) + scheme.AddTypeDefaultingFunc(&InitializerConfiguration{}, func(obj interface{}) { SetObjectDefaults_InitializerConfiguration(obj.(*InitializerConfiguration)) }) + scheme.AddTypeDefaultingFunc(&InitializerConfigurationList{}, func(obj interface{}) { + SetObjectDefaults_InitializerConfigurationList(obj.(*InitializerConfigurationList)) + }) + return nil +} + +func SetObjectDefaults_ExternalAdmissionHookConfiguration(in *ExternalAdmissionHookConfiguration) { + for i := range in.ExternalAdmissionHooks { + a := &in.ExternalAdmissionHooks[i] + SetDefaults_ExternalAdmissionHook(a) + } +} + +func SetObjectDefaults_ExternalAdmissionHookConfigurationList(in *ExternalAdmissionHookConfigurationList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_ExternalAdmissionHookConfiguration(a) + } +} + +func SetObjectDefaults_InitializerConfiguration(in *InitializerConfiguration) { + for i := range in.Initializers { + a := &in.Initializers[i] + SetDefaults_Initializer(a) + } +} + +func SetObjectDefaults_InitializerConfigurationList(in *InitializerConfigurationList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_InitializerConfiguration(a) + } +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/zz_generated.deepcopy.go b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/zz_generated.deepcopy.go new file mode 100644 index 0000000000000..e41f28efa1eb2 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/admissionregistration/zz_generated.deepcopy.go @@ -0,0 +1,254 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package admissionregistration + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_AdmissionHookClientConfig, InType: reflect.TypeOf(&AdmissionHookClientConfig{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_ExternalAdmissionHook, InType: reflect.TypeOf(&ExternalAdmissionHook{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_ExternalAdmissionHookConfiguration, InType: reflect.TypeOf(&ExternalAdmissionHookConfiguration{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_ExternalAdmissionHookConfigurationList, InType: reflect.TypeOf(&ExternalAdmissionHookConfigurationList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_Initializer, InType: reflect.TypeOf(&Initializer{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_InitializerConfiguration, InType: reflect.TypeOf(&InitializerConfiguration{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_InitializerConfigurationList, InType: reflect.TypeOf(&InitializerConfigurationList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_Rule, InType: reflect.TypeOf(&Rule{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_RuleWithOperations, InType: reflect.TypeOf(&RuleWithOperations{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_ServiceReference, InType: reflect.TypeOf(&ServiceReference{})}, + ) +} + +// DeepCopy_admissionregistration_AdmissionHookClientConfig is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_AdmissionHookClientConfig(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*AdmissionHookClientConfig) + out := out.(*AdmissionHookClientConfig) + *out = *in + if in.CABundle != nil { + in, out := &in.CABundle, &out.CABundle + *out = make([]byte, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_admissionregistration_ExternalAdmissionHook is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_ExternalAdmissionHook(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHook) + out := out.(*ExternalAdmissionHook) + *out = *in + if err := DeepCopy_admissionregistration_AdmissionHookClientConfig(&in.ClientConfig, &out.ClientConfig, c); err != nil { + return err + } + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]RuleWithOperations, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_RuleWithOperations(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.FailurePolicy != nil { + in, out := &in.FailurePolicy, &out.FailurePolicy + *out = new(FailurePolicyType) + **out = **in + } + return nil + } +} + +// DeepCopy_admissionregistration_ExternalAdmissionHookConfiguration is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_ExternalAdmissionHookConfiguration(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHookConfiguration) + out := out.(*ExternalAdmissionHookConfiguration) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.ExternalAdmissionHooks != nil { + in, out := &in.ExternalAdmissionHooks, &out.ExternalAdmissionHooks + *out = make([]ExternalAdmissionHook, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_ExternalAdmissionHook(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_admissionregistration_ExternalAdmissionHookConfigurationList is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_ExternalAdmissionHookConfigurationList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHookConfigurationList) + out := out.(*ExternalAdmissionHookConfigurationList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ExternalAdmissionHookConfiguration, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_ExternalAdmissionHookConfiguration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_admissionregistration_Initializer is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_Initializer(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Initializer) + out := out.(*Initializer) + *out = *in + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]Rule, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_Rule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.FailurePolicy != nil { + in, out := &in.FailurePolicy, &out.FailurePolicy + *out = new(FailurePolicyType) + **out = **in + } + return nil + } +} + +// DeepCopy_admissionregistration_InitializerConfiguration is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_InitializerConfiguration(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*InitializerConfiguration) + out := out.(*InitializerConfiguration) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.Initializers != nil { + in, out := &in.Initializers, &out.Initializers + *out = make([]Initializer, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_Initializer(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_admissionregistration_InitializerConfigurationList is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_InitializerConfigurationList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*InitializerConfigurationList) + out := out.(*InitializerConfigurationList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]InitializerConfiguration, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_InitializerConfiguration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_admissionregistration_Rule is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_Rule(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Rule) + out := out.(*Rule) + *out = *in + if in.APIGroups != nil { + in, out := &in.APIGroups, &out.APIGroups + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.APIVersions != nil { + in, out := &in.APIVersions, &out.APIVersions + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Resources != nil { + in, out := &in.Resources, &out.Resources + *out = make([]string, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_admissionregistration_RuleWithOperations is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_RuleWithOperations(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RuleWithOperations) + out := out.(*RuleWithOperations) + *out = *in + if in.Operations != nil { + in, out := &in.Operations, &out.Operations + *out = make([]OperationType, len(*in)) + copy(*out, *in) + } + if err := DeepCopy_admissionregistration_Rule(&in.Rule, &out.Rule, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_admissionregistration_ServiceReference is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_ServiceReference(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ServiceReference) + out := out.(*ServiceReference) + *out = *in + return nil + } +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/apps/BUILD b/staging/src/k8s.io/client-go/pkg/apis/apps/BUILD index 6a06bd1a8948d..0e23b5a0e6159 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/apps/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/apps/BUILD @@ -16,10 +16,6 @@ go_library( "zz_generated.deepcopy.go", ], tags = ["automanaged"], - visibility = [ - "//vendor/k8s.io/client-go/pkg/api/v1:__pkg__", - "//vendor/k8s.io/client-go/pkg/apis:__subpackages__", - ], deps = [ "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/apps/install/BUILD b/staging/src/k8s.io/client-go/pkg/apis/apps/install/BUILD index 06a5ccfa79b32..8cc38c50622d1 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/apps/install/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/apps/install/BUILD @@ -11,7 +11,6 @@ go_library( name = "go_default_library", srcs = ["install.go"], tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/apps/register.go b/staging/src/k8s.io/client-go/pkg/apis/apps/register.go index d1d3bab26a08a..1098ce0a3e646 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/apps/register.go +++ b/staging/src/k8s.io/client-go/pkg/apis/apps/register.go @@ -53,6 +53,8 @@ func addKnownTypes(scheme *runtime.Scheme) error { &extensions.Scale{}, &StatefulSet{}, &StatefulSetList{}, + &ControllerRevision{}, + &ControllerRevisionList{}, ) return nil } diff --git a/staging/src/k8s.io/client-go/pkg/apis/apps/types.go b/staging/src/k8s.io/client-go/pkg/apis/apps/types.go index 08a0d9a39708e..43d80cf6d8927 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/apps/types.go +++ b/staging/src/k8s.io/client-go/pkg/apis/apps/types.go @@ -18,6 +18,7 @@ package apps import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/client-go/pkg/api" ) @@ -127,3 +128,35 @@ type StatefulSetList struct { metav1.ListMeta Items []StatefulSet } + +// +genclient=true + +// ControllerRevision implements an immutable snapshot of state data. Clients +// are responsible for serializing and deserializing the objects that contain +// their internal state. +// Once a ControllerRevision has been successfully created, it can not be updated. +// The API Server will fail validation of all requests that attempt to mutate +// the Data field. ControllerRevisions may, however, be deleted. +type ControllerRevision struct { + metav1.TypeMeta + // Standard object's metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta + + // Data is the Object representing the state. + Data runtime.Object + + // Revision indicates the revision of the state represented by Data. + Revision int64 +} + +// ControllerRevisionList is a resource containing a list of ControllerRevision objects. +type ControllerRevisionList struct { + metav1.TypeMeta + // +optional + metav1.ListMeta + + // Items is the list of ControllerRevision objects. + Items []ControllerRevision +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.pb.go index 19ee88edcdbf1..40cee7e11d9a5 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.pb.go @@ -25,6 +25,8 @@ limitations under the License. k8s.io/kubernetes/pkg/apis/apps/v1beta1/generated.proto It has these top-level messages: + ControllerRevision + ControllerRevisionList Deployment DeploymentCondition DeploymentList @@ -51,7 +53,6 @@ import math "math" import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" import k8s_io_apimachinery_pkg_util_intstr "k8s.io/apimachinery/pkg/util/intstr" - import k8s_io_kubernetes_pkg_api_v1 "k8s.io/client-go/pkg/api/v1" import strings "strings" @@ -71,71 +72,83 @@ var _ = math.Inf // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package +func (m *ControllerRevision) Reset() { *m = ControllerRevision{} } +func (*ControllerRevision) ProtoMessage() {} +func (*ControllerRevision) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func (m *ControllerRevisionList) Reset() { *m = ControllerRevisionList{} } +func (*ControllerRevisionList) ProtoMessage() {} +func (*ControllerRevisionList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } + func (m *Deployment) Reset() { *m = Deployment{} } func (*Deployment) ProtoMessage() {} -func (*Deployment) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } +func (*Deployment) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } func (m *DeploymentCondition) Reset() { *m = DeploymentCondition{} } func (*DeploymentCondition) ProtoMessage() {} -func (*DeploymentCondition) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } +func (*DeploymentCondition) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } func (m *DeploymentList) Reset() { *m = DeploymentList{} } func (*DeploymentList) ProtoMessage() {} -func (*DeploymentList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } +func (*DeploymentList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } func (m *DeploymentRollback) Reset() { *m = DeploymentRollback{} } func (*DeploymentRollback) ProtoMessage() {} -func (*DeploymentRollback) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } +func (*DeploymentRollback) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } func (m *DeploymentSpec) Reset() { *m = DeploymentSpec{} } func (*DeploymentSpec) ProtoMessage() {} -func (*DeploymentSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } +func (*DeploymentSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } func (m *DeploymentStatus) Reset() { *m = DeploymentStatus{} } func (*DeploymentStatus) ProtoMessage() {} -func (*DeploymentStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } +func (*DeploymentStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } func (m *DeploymentStrategy) Reset() { *m = DeploymentStrategy{} } func (*DeploymentStrategy) ProtoMessage() {} -func (*DeploymentStrategy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } +func (*DeploymentStrategy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } func (m *RollbackConfig) Reset() { *m = RollbackConfig{} } func (*RollbackConfig) ProtoMessage() {} -func (*RollbackConfig) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } +func (*RollbackConfig) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } -func (m *RollingUpdateDeployment) Reset() { *m = RollingUpdateDeployment{} } -func (*RollingUpdateDeployment) ProtoMessage() {} -func (*RollingUpdateDeployment) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } +func (m *RollingUpdateDeployment) Reset() { *m = RollingUpdateDeployment{} } +func (*RollingUpdateDeployment) ProtoMessage() {} +func (*RollingUpdateDeployment) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{10} +} func (m *Scale) Reset() { *m = Scale{} } func (*Scale) ProtoMessage() {} -func (*Scale) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } +func (*Scale) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{11} } func (m *ScaleSpec) Reset() { *m = ScaleSpec{} } func (*ScaleSpec) ProtoMessage() {} -func (*ScaleSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{10} } +func (*ScaleSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{12} } func (m *ScaleStatus) Reset() { *m = ScaleStatus{} } func (*ScaleStatus) ProtoMessage() {} -func (*ScaleStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{11} } +func (*ScaleStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{13} } func (m *StatefulSet) Reset() { *m = StatefulSet{} } func (*StatefulSet) ProtoMessage() {} -func (*StatefulSet) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{12} } +func (*StatefulSet) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{14} } func (m *StatefulSetList) Reset() { *m = StatefulSetList{} } func (*StatefulSetList) ProtoMessage() {} -func (*StatefulSetList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{13} } +func (*StatefulSetList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{15} } func (m *StatefulSetSpec) Reset() { *m = StatefulSetSpec{} } func (*StatefulSetSpec) ProtoMessage() {} -func (*StatefulSetSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{14} } +func (*StatefulSetSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{16} } func (m *StatefulSetStatus) Reset() { *m = StatefulSetStatus{} } func (*StatefulSetStatus) ProtoMessage() {} -func (*StatefulSetStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{15} } +func (*StatefulSetStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{17} } func init() { + proto.RegisterType((*ControllerRevision)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.ControllerRevision") + proto.RegisterType((*ControllerRevisionList)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.ControllerRevisionList") proto.RegisterType((*Deployment)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.Deployment") proto.RegisterType((*DeploymentCondition)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.DeploymentCondition") proto.RegisterType((*DeploymentList)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.DeploymentList") @@ -153,7 +166,7 @@ func init() { proto.RegisterType((*StatefulSetSpec)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.StatefulSetSpec") proto.RegisterType((*StatefulSetStatus)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.StatefulSetStatus") } -func (m *Deployment) Marshal() (dAtA []byte, err error) { +func (m *ControllerRevision) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalTo(dAtA) @@ -163,7 +176,7 @@ func (m *Deployment) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *Deployment) MarshalTo(dAtA []byte) (int, error) { +func (m *ControllerRevision) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int @@ -178,20 +191,95 @@ func (m *Deployment) MarshalTo(dAtA []byte) (int, error) { i += n1 dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n2, err := m.Spec.MarshalTo(dAtA[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Data.Size())) + n2, err := m.Data.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 + dAtA[i] = 0x18 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Revision)) + return i, nil +} + +func (m *ControllerRevisionList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ControllerRevisionList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n3, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *Deployment) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Deployment) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n4, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n5, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n3, err := m.Status.MarshalTo(dAtA[i:]) + n6, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n3 + i += n6 return i, nil } @@ -229,19 +317,19 @@ func (m *DeploymentCondition) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x32 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastUpdateTime.Size())) - n4, err := m.LastUpdateTime.MarshalTo(dAtA[i:]) + n7, err := m.LastUpdateTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n4 + i += n7 dAtA[i] = 0x3a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) - n5, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) + n8, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n5 + i += n8 return i, nil } @@ -263,11 +351,11 @@ func (m *DeploymentList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n6, err := m.ListMeta.MarshalTo(dAtA[i:]) + n9, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n6 + i += n9 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -322,11 +410,11 @@ func (m *DeploymentRollback) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.RollbackTo.Size())) - n7, err := m.RollbackTo.MarshalTo(dAtA[i:]) + n10, err := m.RollbackTo.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n7 + i += n10 return i, nil } @@ -354,28 +442,28 @@ func (m *DeploymentSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) - n8, err := m.Selector.MarshalTo(dAtA[i:]) + n11, err := m.Selector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n8 + i += n11 } dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) - n9, err := m.Template.MarshalTo(dAtA[i:]) + n12, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n9 + i += n12 dAtA[i] = 0x22 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Strategy.Size())) - n10, err := m.Strategy.MarshalTo(dAtA[i:]) + n13, err := m.Strategy.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n10 + i += n13 dAtA[i] = 0x28 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.MinReadySeconds)) @@ -396,11 +484,11 @@ func (m *DeploymentSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x42 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.RollbackTo.Size())) - n11, err := m.RollbackTo.MarshalTo(dAtA[i:]) + n14, err := m.RollbackTo.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n11 + i += n14 } if m.ProgressDeadlineSeconds != nil { dAtA[i] = 0x48 @@ -486,11 +574,11 @@ func (m *DeploymentStrategy) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.RollingUpdate.Size())) - n12, err := m.RollingUpdate.MarshalTo(dAtA[i:]) + n15, err := m.RollingUpdate.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n12 + i += n15 } return i, nil } @@ -535,21 +623,21 @@ func (m *RollingUpdateDeployment) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.MaxUnavailable.Size())) - n13, err := m.MaxUnavailable.MarshalTo(dAtA[i:]) + n16, err := m.MaxUnavailable.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n13 + i += n16 } if m.MaxSurge != nil { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.MaxSurge.Size())) - n14, err := m.MaxSurge.MarshalTo(dAtA[i:]) + n17, err := m.MaxSurge.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n14 + i += n17 } return i, nil } @@ -572,27 +660,27 @@ func (m *Scale) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n15, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n18, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n15 + i += n18 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n16, err := m.Spec.MarshalTo(dAtA[i:]) + n19, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n16 + i += n19 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n17, err := m.Status.MarshalTo(dAtA[i:]) + n20, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n17 + i += n20 return i, nil } @@ -677,27 +765,27 @@ func (m *StatefulSet) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) - n18, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + n21, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n18 + i += n21 dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) - n19, err := m.Spec.MarshalTo(dAtA[i:]) + n22, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n19 + i += n22 dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) - n20, err := m.Status.MarshalTo(dAtA[i:]) + n23, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n20 + i += n23 return i, nil } @@ -719,11 +807,11 @@ func (m *StatefulSetList) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0xa i++ i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) - n21, err := m.ListMeta.MarshalTo(dAtA[i:]) + n24, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n21 + i += n24 if len(m.Items) > 0 { for _, msg := range m.Items { dAtA[i] = 0x12 @@ -763,20 +851,20 @@ func (m *StatefulSetSpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0x12 i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) - n22, err := m.Selector.MarshalTo(dAtA[i:]) + n25, err := m.Selector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n22 + i += n25 } dAtA[i] = 0x1a i++ i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) - n23, err := m.Template.MarshalTo(dAtA[i:]) + n26, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n23 + i += n26 if len(m.VolumeClaimTemplates) > 0 { for _, msg := range m.VolumeClaimTemplates { dAtA[i] = 0x22 @@ -853,6 +941,31 @@ func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { dAtA[offset] = uint8(v) return offset + 1 } +func (m *ControllerRevision) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Data.Size() + n += 1 + l + sovGenerated(uint64(l)) + n += 1 + sovGenerated(uint64(m.Revision)) + return n +} + +func (m *ControllerRevisionList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + func (m *Deployment) Size() (n int) { var l int _ = l @@ -1108,6 +1221,29 @@ func sovGenerated(x uint64) (n int) { func sozGenerated(x uint64) (n int) { return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } +func (this *ControllerRevision) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ControllerRevision{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Data:` + strings.Replace(strings.Replace(this.Data.String(), "RawExtension", "k8s_io_apimachinery_pkg_runtime.RawExtension", 1), `&`, ``, 1) + `,`, + `Revision:` + fmt.Sprintf("%v", this.Revision) + `,`, + `}`, + }, "") + return s +} +func (this *ControllerRevisionList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ControllerRevisionList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ControllerRevision", "ControllerRevision", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} func (this *Deployment) String() string { if this == nil { return "nil" @@ -1336,6 +1472,246 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } +func (m *ControllerRevision) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ControllerRevision: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ControllerRevision: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Data.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Revision", wireType) + } + m.Revision = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Revision |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ControllerRevisionList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ControllerRevisionList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ControllerRevisionList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, ControllerRevision{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *Deployment) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 @@ -3920,105 +4296,108 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 1585 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x58, 0xcd, 0x6f, 0x1b, 0xb7, - 0x12, 0xf7, 0xda, 0x92, 0x2d, 0xd3, 0xb1, 0x1c, 0xd3, 0x7e, 0xb1, 0x9e, 0xf3, 0x20, 0x07, 0x3a, - 0xe4, 0xe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c3, 0x31, - 0x30, 0x17, 0x2b, 0xaf, 0xbb, 0x4e, 0x93, 0x72, 0xea, 0x3a, 0x70, 0x15, 0xe4, 0x78, 0xc7, 0x23, - 0xf2, 0xcc, 0x26, 0x6b, 0x97, 0x42, 0xe7, 0xb6, 0x3b, 0x1e, 0x79, 0x7b, 0xb0, 0xb4, 0xd0, 0x03, - 0x22, 0x44, 0x48, 0x82, 0xe0, 0x93, 0xc8, 0xef, 0x51, 0x09, 0xbf, 0x97, 0x36, 0xfe, 0xf6, 0x60, - 0xe9, 0xd8, 0x70, 0xd0, 0x23, 0xce, 0xb4, 0xb3, 0xf0, 0x22, 0x18, 0xf7, 0x09, 0x66, 0xae, 0x53, - 0xca, 0x49, 0xde, 0x68, 0x53, 0x48, 0xae, 0x22, 0x25, 0x85, 0x57, 0xc0, 0x84, 0x4d, 0x18, 0xc3, - 0x26, 0x29, 0xe5, 0xa5, 0xe2, 0x8c, 0x52, 0x9c, 0xd8, 0x0c, 0x96, 0x51, 0x28, 0x87, 0x2f, 0x41, - 0xd1, 0xc2, 0x8c, 0xef, 0x78, 0x4d, 0xcc, 0xc9, 0x36, 0xb5, 0x49, 0x69, 0x5c, 0x1e, 0xf5, 0x7f, - 0x07, 0x8b, 0x12, 0x81, 0xa8, 0x9d, 0x53, 0xec, 0xc5, 0x8d, 0x14, 0x13, 0xea, 0x62, 0x86, 0x6d, - 0x00, 0xc5, 0xca, 0xb6, 0x8f, 0x1d, 0x16, 0x1c, 0x99, 0xb0, 0x37, 0x71, 0x6a, 0x7b, 0x8b, 0xca, - 0x1e, 0xdc, 0xc8, 0xb0, 0xa1, 0x1e, 0x16, 0x2a, 0xfb, 0x1a, 0x28, 0xc6, 0x17, 0xb6, 0x41, 0x19, - 0x87, 0xcf, 0x33, 0x69, 0xa1, 0x0f, 0xe6, 0x80, 0x40, 0xcb, 0xa4, 0x38, 0xab, 0x9c, 0x28, 0x84, - 0x2b, 0x89, 0x94, 0xf8, 0x04, 0xe4, 0x29, 0x27, 0xb6, 0xb8, 0xfe, 0xb1, 0xcb, 0x53, 0xcb, 0x37, - 0x86, 0x08, 0xdb, 0xda, 0xb4, 0xe2, 0xcf, 0x3f, 0x12, 0x4c, 0x28, 0x20, 0xac, 0x7c, 0x3d, 0x06, - 0x60, 0xac, 0x84, 0x5c, 0xcb, 0x6a, 0x60, 0x63, 0x0f, 0x5e, 0x00, 0x39, 0x07, 0xdb, 0x61, 0xb4, - 0x46, 0xa9, 0xf4, 0x31, 0xb6, 0x09, 0x92, 0x12, 0xf8, 0x9d, 0x06, 0x60, 0x4b, 0x5e, 0x45, 0x73, - 0xcd, 0x71, 0x5c, 0x8e, 0xc5, 0xe9, 0x84, 0x0e, 0xd6, 0x87, 0x70, 0x30, 0xb4, 0xad, 0xef, 0x64, - 0x58, 0x1f, 0x38, 0xdc, 0xef, 0xc4, 0xb7, 0x94, 0x55, 0x40, 0x3d, 0x5c, 0x81, 0x7b, 0x00, 0xf8, - 0x8a, 0x73, 0xdb, 0x55, 0x09, 0x3f, 0x78, 0x35, 0x09, 0xdd, 0x59, 0x77, 0x9d, 0x17, 0xd4, 0x8c, - 0x4b, 0x16, 0x8a, 0x28, 0x51, 0x82, 0x7e, 0xf1, 0x01, 0x58, 0xe8, 0xe3, 0x37, 0x3c, 0x0b, 0xc6, - 0xf6, 0x48, 0x27, 0x38, 0x4a, 0x24, 0x7e, 0xc2, 0x79, 0x90, 0x6f, 0x63, 0xab, 0x45, 0x82, 0x6c, - 0x46, 0xc1, 0xc7, 0xca, 0xe8, 0x1d, 0xad, 0xf2, 0x7b, 0x3e, 0x19, 0x59, 0xa2, 0x72, 0xc1, 0xcb, - 0xa0, 0xe0, 0x13, 0xcf, 0xa2, 0x06, 0x66, 0x92, 0x23, 0x5f, 0x3b, 0x23, 0xa2, 0x04, 0xa9, 0x35, - 0x14, 0x49, 0xe1, 0x67, 0xa0, 0xc0, 0x88, 0x45, 0x0c, 0xee, 0xfa, 0xaa, 0x78, 0xde, 0x18, 0x30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, 0x0f, 0x5b, 0xf9, 0x35, 0x07, 0xce, 0x76, 0xbf, 0xa3, - 0xf0, 0x23, 0x00, 0xdd, 0x86, 0xec, 0x7b, 0x9a, 0x0f, 0x83, 0xce, 0x83, 0xba, 0x8e, 0x0c, 0xf4, - 0xb1, 0x38, 0xe3, 0x1f, 0x67, 0x34, 0x50, 0x0f, 0x14, 0xbc, 0x9a, 0x48, 0x95, 0x51, 0xe9, 0x68, - 0x14, 0x07, 0x3d, 0xd2, 0x65, 0x0d, 0xcc, 0xa8, 0xaa, 0x11, 0x0a, 0x65, 0x58, 0x27, 0xe2, 0x60, - 0x27, 0x2d, 0x46, 0xdd, 0xfa, 0xf0, 0x21, 0x98, 0xc5, 0x6d, 0x4c, 0x2d, 0xdc, 0xb0, 0x48, 0x44, - 0x92, 0x93, 0x24, 0xff, 0x56, 0x24, 0xb3, 0x6b, 0xdd, 0x0a, 0x28, 0x8b, 0x81, 0x9b, 0x60, 0xae, - 0xe5, 0x64, 0xa9, 0x82, 0xb8, 0x3c, 0xaf, 0xa8, 0xe6, 0x76, 0xb2, 0x2a, 0xa8, 0x17, 0x0e, 0x7a, - 0x00, 0x18, 0xe1, 0x93, 0xcf, 0x4a, 0xe3, 0xb2, 0x26, 0xbf, 0x37, 0x44, 0x3e, 0x45, 0x7d, 0x43, - 0x5c, 0xff, 0xa2, 0x25, 0x86, 0x12, 0x36, 0xe0, 0x2a, 0x98, 0xf6, 0x45, 0x86, 0x44, 0xae, 0x4f, - 0x48, 0xd7, 0xff, 0xa5, 0x60, 0xd3, 0x28, 0x29, 0x44, 0x69, 0x5d, 0xb8, 0x02, 0x8a, 0x86, 0x6b, - 0x59, 0x32, 0x33, 0xd6, 0xdd, 0x96, 0xc3, 0x65, 0x70, 0x8f, 0xd5, 0xa0, 0xe8, 0x01, 0xd6, 0x53, - 0x12, 0xd4, 0xa5, 0x59, 0xf9, 0x45, 0x4b, 0x3e, 0x60, 0x61, 0xba, 0xc3, 0x95, 0x54, 0xbb,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9f, 0xac, 0xdd, 0x0a, 0xbb, 0xad, - 0xad, 0xac, 0xca, 0x5b, 0xd1, 0xf6, 0x66, 0x97, 0x65, 0xef, 0xd0, 0x8b, 0xb2, 0xf2, 0x95, 0x06, - 0x66, 0x33, 0xd9, 0x01, 0x3f, 0x38, 0xa6, 0xe7, 0x3d, 0xf7, 0x77, 0xf5, 0xbb, 0xb5, 0x2b, 0xfb, - 0x87, 0xe5, 0x91, 0xd7, 0x87, 0xe5, 0x91, 0xdf, 0x0e, 0xcb, 0x23, 0x5f, 0x1c, 0x95, 0xb5, 0xfd, - 0xa3, 0xb2, 0xf6, 0xfa, 0xa8, 0xac, 0xfd, 0x71, 0x54, 0xd6, 0xbe, 0x79, 0x53, 0x1e, 0x79, 0x36, - 0xa1, 0x62, 0xff, 0xcf, 0x00, 0x00, 0x00, 0xff, 0xff, 0xf2, 0xdb, 0x2f, 0x40, 0xf8, 0x15, 0x00, - 0x00, + // 1647 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x58, 0xcf, 0x4f, 0x1b, 0xc7, + 0x17, 0x67, 0x8d, 0x0d, 0x66, 0x08, 0x26, 0x0c, 0x7c, 0xc1, 0x5f, 0x52, 0x19, 0xe4, 0x43, 0x42, + 0xaa, 0x64, 0xdd, 0x90, 0x34, 0x3f, 0xa0, 0x8a, 0x8a, 0x49, 0x9a, 0xa6, 0x82, 0x82, 0xc6, 0x10, + 0x35, 0x69, 0x2a, 0x65, 0xbc, 0x9e, 0x2c, 0x1b, 0xf6, 0x97, 0x76, 0xc6, 0x6e, 0x7c, 0xeb, 0xa5, + 0x87, 0x4a, 0x3d, 0xf4, 0x1f, 0xa8, 0xda, 0x73, 0x55, 0xa9, 0xff, 0x06, 0x6a, 0x2f, 0x51, 0x4f, + 0x51, 0x0f, 0xa8, 0x90, 0xbf, 0xa1, 0x97, 0x9c, 0xaa, 0x99, 0x9d, 0xf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70, 0x95, 0x8f, 0x41, 0x96, 0xba, 0x44, 0x93, 0x57, + 0x79, 0xab, 0x6f, 0x8f, 0x22, 0x23, 0x6b, 0x2e, 0xd1, 0xa2, 0x4b, 0xe5, 0x5f, 0x48, 0x40, 0x42, + 0x0c, 0x86, 0x28, 0xc3, 0xac, 0x49, 0xc5, 0x95, 0x8e, 0x2e, 0xde, 0x39, 0x0d, 0xb8, 0x00, 0xa8, + 0x16, 0x24, 0xfc, 0x90, 0xff, 0x8d, 0x24, 0x70, 0xf9, 0x60, 0x10, 0x4c, 0x46, 0xcc, 0xab, 0x8e, + 0xdd, 0x30, 0x18, 0x2f, 0x81, 0x65, 0x90, 0x65, 0x6d, 0x97, 0x88, 0x98, 0x8d, 0x54, 0x2f, 0x05, + 0xc6, 0x6d, 0xb5, 0x5d, 0xf2, 0x76, 0x7f, 0x6e, 0xa6, 0x8b, 0x08, 0x27, 0x21, 0x21, 0x04, 0x1f, + 0x85, 0x76, 0x67, 0x84, 0xf8, 0xdd, 0xa4, 0xf2, 0xb7, 0xfb, 0x73, 0x47, 0x56, 0xb8, 0x1a, 0x62, + 0x26, 0x8d, 0x85, 0x17, 0xc1, 0x90, 0x47, 0x30, 0x75, 0xec, 0x62, 0x56, 0xe0, 0x86, 0x4e, 0x21, + 0x71, 0x8a, 0x24, 0x15, 0x5e, 0x06, 0xc3, 0x16, 0xa1, 0x14, 0xeb, 0xa4, 0x98, 0x13, 0x8c, 0xe3, + 0x92, 0x71, 0x78, 0xdd, 0x3f, 0x46, 0x01, 0x1d, 0xbe, 0x00, 0x05, 0x13, 0x53, 0xb6, 0xed, 0x36, + 0x30, 0x23, 0x5b, 0x86, 0x45, 0x8a, 0x43, 0x22, 0xd4, 0xef, 0xf6, 0x97, 0x25, 0x5c, 0xa2, 0x3a, + 0x2d, 0xd1, 0x0b, 0x6b, 0x09, 0x24, 0xd4, 0x81, 0x0c, 0x5b, 0x00, 0xf2, 0x93, 0x2d, 0x0f, 0xdb, + 0xd4, 0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, 0x3f, 0x35, 0xc5, 0xf4, 0x3e, 0x52, 0xbd, 0x19, 0x4c, 0x5b, 0x9b, 0x69, + 0x96, 0xb7, 0x7c, 0xec, 0x4d, 0x1f, 0x8b, 0xd9, 0xa1, 0x1b, 0x64, 0xf9, 0x1b, 0x05, 0x4c, 0xa4, + 0xaa, 0x03, 0x7e, 0x74, 0xc4, 0xcc, 0x3b, 0xfd, 0x6f, 0xcd, 0xbb, 0xd5, 0xcb, 0x7b, 0x07, 0xa5, + 0x81, 0x57, 0x07, 0xa5, 0x81, 0xd7, 0x07, 0xa5, 0x81, 0xaf, 0x0e, 0x4b, 0xca, 0xde, 0x61, 0x49, + 0x79, 0x75, 0x58, 0x52, 0xfe, 0x3c, 0x2c, 0x29, 0xdf, 0xbd, 0x29, 0x0d, 0x3c, 0x19, 0x96, 0xb9, + 0xff, 0x77, 0x00, 0x00, 0x00, 0xff, 0xff, 0x5d, 0x5b, 0xd8, 0xe7, 0x95, 0x17, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.proto index 5e3d4b99fe2de..61b82890ccb74 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.proto @@ -19,19 +19,50 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.apps.v1beta1; +package k8s.io.client_go.pkg.apis.apps.v1beta1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; import "k8s.io/kubernetes/pkg/apis/policy/v1beta1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; +// ControllerRevision implements an immutable snapshot of state data. Clients +// are responsible for serializing and deserializing the objects that contain +// their internal state. +// Once a ControllerRevision has been successfully created, it can not be updated. +// The API Server will fail validation of all requests that attempt to mutate +// the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both +// the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, +// it may be subject to name and representation changes in future releases, and clients should not +// depend on its stability. It is primarily for internal use by controllers. +message ControllerRevision { + // Standard object's metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Data is the serialized representation of the state. + optional k8s.io.apimachinery.pkg.runtime.RawExtension data = 2; + + // Revision indicates the revision of the state represented by Data. + optional int64 revision = 3; +} + +// ControllerRevisionList is a resource containing a list of ControllerRevision objects. +message ControllerRevisionList { + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // Items is the list of ControllerRevisions + repeated ControllerRevision items = 2; +} + // Deployment enables declarative updates for Pods and ReplicaSets. message Deployment { // Standard object metadata. @@ -104,7 +135,7 @@ message DeploymentSpec { optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector selector = 2; // Template describes the pods that will be created. - optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 3; + optional k8s.io.client_go.pkg.api.v1.PodTemplateSpec template = 3; // The deployment strategy to use to replace existing pods with new ones. // +optional @@ -194,7 +225,7 @@ message DeploymentStrategy { } message RollbackConfig { - // The revision to rollback to. If set to 0, rollbck to the last revision. + // The revision to rollback to. If set to 0, rollback to the last revision. // +optional optional int64 revision = 1; } @@ -318,7 +349,7 @@ message StatefulSetSpec { // insufficient replicas are detected. Each pod stamped out by the StatefulSet // will fulfill this Template, but have a unique identity from the rest // of the StatefulSet. - optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 3; + optional k8s.io.client_go.pkg.api.v1.PodTemplateSpec template = 3; // volumeClaimTemplates is a list of claims that pods are allowed to reference. // The StatefulSet controller is responsible for mapping network identities to @@ -328,7 +359,7 @@ message StatefulSetSpec { // any volumes in the template, with the same name. // TODO: Define the behavior if a claim already exists with the same name. // +optional - repeated k8s.io.kubernetes.pkg.api.v1.PersistentVolumeClaim volumeClaimTemplates = 4; + repeated k8s.io.client_go.pkg.api.v1.PersistentVolumeClaim volumeClaimTemplates = 4; // serviceName is the name of the service that governs this StatefulSet. // This service must exist before the StatefulSet, and is responsible for diff --git a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/register.go b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/register.go index 077809652895b..5a4fd5bc3bb5f 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/register.go +++ b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/register.go @@ -57,6 +57,8 @@ func addKnownTypes(scheme *runtime.Scheme) error { &Scale{}, &StatefulSet{}, &StatefulSetList{}, + &ControllerRevision{}, + &ControllerRevisionList{}, ) metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil diff --git a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/types.generated.go b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/types.generated.go index 7e8b15f174fb1..c7ddf6f4169b3 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/types.generated.go +++ b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/types.generated.go @@ -27,6 +27,7 @@ import ( codec1978 "github.com/ugorji/go/codec" pkg4_resource "k8s.io/apimachinery/pkg/api/resource" pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg6_runtime "k8s.io/apimachinery/pkg/runtime" pkg2_types "k8s.io/apimachinery/pkg/types" pkg5_intstr "k8s.io/apimachinery/pkg/util/intstr" pkg3_v1 "k8s.io/client-go/pkg/api/v1" @@ -67,11 +68,12 @@ func init() { if false { // reference the types, but skip this branch at build/run time var v0 pkg4_resource.Quantity var v1 pkg1_v1.TypeMeta - var v2 pkg2_types.UID - var v3 pkg5_intstr.IntOrString - var v4 pkg3_v1.PodTemplateSpec - var v5 time.Time - _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5 + var v2 pkg6_runtime.RawExtension + var v3 pkg2_types.UID + var v4 pkg5_intstr.IntOrString + var v5 pkg3_v1.PodTemplateSpec + var v6 time.Time + _, _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5, v6 } } @@ -6152,6 +6154,808 @@ func (x *DeploymentList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } +func (x *ControllerRevision) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy15 := &x.Data + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(yy15) { + } else if !yym16 && z.IsJSONHandle() { + z.EncJSONMarshal(yy15) + } else { + z.EncFallback(yy15) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("data")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Data + yym18 := z.EncBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.EncExt(yy17) { + } else if !yym18 && z.IsJSONHandle() { + z.EncJSONMarshal(yy17) + } else { + z.EncFallback(yy17) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeInt(int64(x.Revision)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("revision")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym21 := z.EncBinary() + _ = yym21 + if false { + } else { + r.EncodeInt(int64(x.Revision)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ControllerRevision) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ControllerRevision) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "data": + if r.TryDecodeAsNil() { + x.Data = pkg6_runtime.RawExtension{} + } else { + yyv10 := &x.Data + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else if !yym11 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv10) + } else { + z.DecFallback(yyv10, false) + } + } + case "revision": + if r.TryDecodeAsNil() { + x.Revision = 0 + } else { + yyv12 := &x.Revision + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ControllerRevision) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv15 := &x.Kind + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv17 := &x.APIVersion + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv19 := &x.ObjectMeta + yym20 := z.DecBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else { + z.DecFallback(yyv19, false) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Data = pkg6_runtime.RawExtension{} + } else { + yyv21 := &x.Data + yym22 := z.DecBinary() + _ = yym22 + if false { + } else if z.HasExtensions() && z.DecExt(yyv21) { + } else if !yym22 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv21) + } else { + z.DecFallback(yyv21, false) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Revision = 0 + } else { + yyv23 := &x.Revision + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int64)(yyv23)) = int64(r.DecodeInt(64)) + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ControllerRevisionList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceControllerRevision(([]ControllerRevision)(x.Items), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceControllerRevision(([]ControllerRevision)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ControllerRevisionList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ControllerRevisionList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceControllerRevision((*[]ControllerRevision)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ControllerRevisionList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceControllerRevision((*[]ControllerRevision)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + func (x codecSelfer1234) encSlicev1_PersistentVolumeClaim(v []pkg3_v1.PersistentVolumeClaim, e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) @@ -6627,3 +7431,122 @@ func (x codecSelfer1234) decSliceDeployment(v *[]Deployment, d *codec1978.Decode *v = yyv1 } } + +func (x codecSelfer1234) encSliceControllerRevision(v []ControllerRevision, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceControllerRevision(v *[]ControllerRevision, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ControllerRevision{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 312) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]ControllerRevision, yyrl1) + } + } else { + yyv1 = make([]ControllerRevision, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ControllerRevision{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ControllerRevision{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ControllerRevision{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ControllerRevision{}) // var yyz1 ControllerRevision + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = ControllerRevision{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ControllerRevision{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/types.go b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/types.go index ef76205acdb33..575a63baaca45 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/types.go +++ b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/types.go @@ -18,6 +18,7 @@ package v1beta1 import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/util/intstr" "k8s.io/client-go/pkg/api/v1" ) @@ -259,7 +260,7 @@ type DeploymentRollback struct { } type RollbackConfig struct { - // The revision to rollback to. If set to 0, rollbck to the last revision. + // The revision to rollback to. If set to 0, rollback to the last revision. // +optional Revision int64 `json:"revision,omitempty" protobuf:"varint,1,opt,name=revision"` } @@ -407,3 +408,40 @@ type DeploymentList struct { // Items is the list of Deployments. Items []Deployment `json:"items" protobuf:"bytes,2,rep,name=items"` } + +// +genclient=true + +// ControllerRevision implements an immutable snapshot of state data. Clients +// are responsible for serializing and deserializing the objects that contain +// their internal state. +// Once a ControllerRevision has been successfully created, it can not be updated. +// The API Server will fail validation of all requests that attempt to mutate +// the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both +// the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, +// it may be subject to name and representation changes in future releases, and clients should not +// depend on its stability. It is primarily for internal use by controllers. +type ControllerRevision struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Data is the serialized representation of the state. + Data runtime.RawExtension `json:"data,omitempty" protobuf:"bytes,2,opt,name=data"` + + // Revision indicates the revision of the state represented by Data. + Revision int64 `json:"revision" protobuf:"varint,3,opt,name=revision"` +} + +// ControllerRevisionList is a resource containing a list of ControllerRevision objects. +type ControllerRevisionList struct { + metav1.TypeMeta `json:",inline"` + + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Items is the list of ControllerRevisions + Items []ControllerRevision `json:"items" protobuf:"bytes,2,rep,name=items"` +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/types_swagger_doc_generated.go b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/types_swagger_doc_generated.go index fffd81c31681e..b63d0d266dbbe 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/types_swagger_doc_generated.go +++ b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/types_swagger_doc_generated.go @@ -27,6 +27,27 @@ package v1beta1 // Those methods can be generated by using hack/update-generated-swagger-docs.sh // AUTO-GENERATED FUNCTIONS START HERE +var map_ControllerRevision = map[string]string{ + "": "ControllerRevision implements an immutable snapshot of state data. Clients are responsible for serializing and deserializing the objects that contain their internal state. Once a ControllerRevision has been successfully created, it can not be updated. The API Server will fail validation of all requests that attempt to mutate the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, it may be subject to name and representation changes in future releases, and clients should not depend on its stability. It is primarily for internal use by controllers.", + "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "data": "Data is the serialized representation of the state.", + "revision": "Revision indicates the revision of the state represented by Data.", +} + +func (ControllerRevision) SwaggerDoc() map[string]string { + return map_ControllerRevision +} + +var map_ControllerRevisionList = map[string]string{ + "": "ControllerRevisionList is a resource containing a list of ControllerRevision objects.", + "metadata": "More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "items": "Items is the list of ControllerRevisions", +} + +func (ControllerRevisionList) SwaggerDoc() map[string]string { + return map_ControllerRevisionList +} + var map_Deployment = map[string]string{ "": "Deployment enables declarative updates for Pods and ReplicaSets.", "metadata": "Standard object metadata.", @@ -117,7 +138,7 @@ func (DeploymentStrategy) SwaggerDoc() map[string]string { } var map_RollbackConfig = map[string]string{ - "revision": "The revision to rollback to. If set to 0, rollbck to the last revision.", + "revision": "The revision to rollback to. If set to 0, rollback to the last revision.", } func (RollbackConfig) SwaggerDoc() map[string]string { diff --git a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.conversion.go b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.conversion.go index 87ce6d4c01094..5b39d12f100ea 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.conversion.go +++ b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.conversion.go @@ -38,6 +38,10 @@ func init() { // Public to allow building arbitrary schemes. func RegisterConversions(scheme *runtime.Scheme) error { return scheme.AddGeneratedConversionFuncs( + Convert_v1beta1_ControllerRevision_To_apps_ControllerRevision, + Convert_apps_ControllerRevision_To_v1beta1_ControllerRevision, + Convert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList, + Convert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList, Convert_v1beta1_StatefulSet_To_apps_StatefulSet, Convert_apps_StatefulSet_To_v1beta1_StatefulSet, Convert_v1beta1_StatefulSetList_To_apps_StatefulSetList, @@ -49,6 +53,76 @@ func RegisterConversions(scheme *runtime.Scheme) error { ) } +func autoConvert_v1beta1_ControllerRevision_To_apps_ControllerRevision(in *ControllerRevision, out *apps.ControllerRevision, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := runtime.Convert_runtime_RawExtension_To_runtime_Object(&in.Data, &out.Data, s); err != nil { + return err + } + out.Revision = in.Revision + return nil +} + +// Convert_v1beta1_ControllerRevision_To_apps_ControllerRevision is an autogenerated conversion function. +func Convert_v1beta1_ControllerRevision_To_apps_ControllerRevision(in *ControllerRevision, out *apps.ControllerRevision, s conversion.Scope) error { + return autoConvert_v1beta1_ControllerRevision_To_apps_ControllerRevision(in, out, s) +} + +func autoConvert_apps_ControllerRevision_To_v1beta1_ControllerRevision(in *apps.ControllerRevision, out *ControllerRevision, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := runtime.Convert_runtime_Object_To_runtime_RawExtension(&in.Data, &out.Data, s); err != nil { + return err + } + out.Revision = in.Revision + return nil +} + +// Convert_apps_ControllerRevision_To_v1beta1_ControllerRevision is an autogenerated conversion function. +func Convert_apps_ControllerRevision_To_v1beta1_ControllerRevision(in *apps.ControllerRevision, out *ControllerRevision, s conversion.Scope) error { + return autoConvert_apps_ControllerRevision_To_v1beta1_ControllerRevision(in, out, s) +} + +func autoConvert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList(in *ControllerRevisionList, out *apps.ControllerRevisionList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]apps.ControllerRevision, len(*in)) + for i := range *in { + if err := Convert_v1beta1_ControllerRevision_To_apps_ControllerRevision(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = nil + } + return nil +} + +// Convert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList is an autogenerated conversion function. +func Convert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList(in *ControllerRevisionList, out *apps.ControllerRevisionList, s conversion.Scope) error { + return autoConvert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList(in, out, s) +} + +func autoConvert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList(in *apps.ControllerRevisionList, out *ControllerRevisionList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ControllerRevision, len(*in)) + for i := range *in { + if err := Convert_apps_ControllerRevision_To_v1beta1_ControllerRevision(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = make([]ControllerRevision, 0) + } + return nil +} + +// Convert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList is an autogenerated conversion function. +func Convert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList(in *apps.ControllerRevisionList, out *ControllerRevisionList, s conversion.Scope) error { + return autoConvert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList(in, out, s) +} + func autoConvert_v1beta1_StatefulSet_To_apps_StatefulSet(in *StatefulSet, out *apps.StatefulSet, s conversion.Scope) error { out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_StatefulSetSpec_To_apps_StatefulSetSpec(&in.Spec, &out.Spec, s); err != nil { diff --git a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.deepcopy.go b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.deepcopy.go index 5d9bbf1c273b4..a7feb4a82fe21 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.deepcopy.go +++ b/staging/src/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.deepcopy.go @@ -37,6 +37,8 @@ func init() { // to allow building arbitrary schemes. func RegisterDeepCopies(scheme *runtime.Scheme) error { return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ControllerRevision, InType: reflect.TypeOf(&ControllerRevision{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ControllerRevisionList, InType: reflect.TypeOf(&ControllerRevisionList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_Deployment, InType: reflect.TypeOf(&Deployment{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentCondition, InType: reflect.TypeOf(&DeploymentCondition{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentList, InType: reflect.TypeOf(&DeploymentList{})}, @@ -56,6 +58,45 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_v1beta1_ControllerRevision is an autogenerated deepcopy function. +func DeepCopy_v1beta1_ControllerRevision(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ControllerRevision) + out := out.(*ControllerRevision) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if newVal, err := c.DeepCopy(&in.Data); err != nil { + return err + } else { + out.Data = *newVal.(*runtime.RawExtension) + } + return nil + } +} + +// DeepCopy_v1beta1_ControllerRevisionList is an autogenerated deepcopy function. +func DeepCopy_v1beta1_ControllerRevisionList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ControllerRevisionList) + out := out.(*ControllerRevisionList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ControllerRevision, len(*in)) + for i := range *in { + if err := DeepCopy_v1beta1_ControllerRevision(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + // DeepCopy_v1beta1_Deployment is an autogenerated deepcopy function. func DeepCopy_v1beta1_Deployment(in interface{}, out interface{}, c *conversion.Cloner) error { { diff --git a/staging/src/k8s.io/client-go/pkg/apis/apps/zz_generated.deepcopy.go b/staging/src/k8s.io/client-go/pkg/apis/apps/zz_generated.deepcopy.go index 4ad88dc272130..9e2bf52449ce1 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/apps/zz_generated.deepcopy.go +++ b/staging/src/k8s.io/client-go/pkg/apis/apps/zz_generated.deepcopy.go @@ -36,6 +36,8 @@ func init() { // to allow building arbitrary schemes. func RegisterDeepCopies(scheme *runtime.Scheme) error { return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_ControllerRevision, InType: reflect.TypeOf(&ControllerRevision{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_ControllerRevisionList, InType: reflect.TypeOf(&ControllerRevisionList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_StatefulSet, InType: reflect.TypeOf(&StatefulSet{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_StatefulSetList, InType: reflect.TypeOf(&StatefulSetList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_StatefulSetSpec, InType: reflect.TypeOf(&StatefulSetSpec{})}, @@ -43,6 +45,48 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_apps_ControllerRevision is an autogenerated deepcopy function. +func DeepCopy_apps_ControllerRevision(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ControllerRevision) + out := out.(*ControllerRevision) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + // in.Data is kind 'Interface' + if in.Data != nil { + if newVal, err := c.DeepCopy(&in.Data); err != nil { + return err + } else { + out.Data = *newVal.(*runtime.Object) + } + } + return nil + } +} + +// DeepCopy_apps_ControllerRevisionList is an autogenerated deepcopy function. +func DeepCopy_apps_ControllerRevisionList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ControllerRevisionList) + out := out.(*ControllerRevisionList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ControllerRevision, len(*in)) + for i := range *in { + if err := DeepCopy_apps_ControllerRevision(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + // DeepCopy_apps_StatefulSet is an autogenerated deepcopy function. func DeepCopy_apps_StatefulSet(in interface{}, out interface{}, c *conversion.Cloner) error { { diff --git a/staging/src/k8s.io/client-go/pkg/apis/authentication/BUILD b/staging/src/k8s.io/client-go/pkg/apis/authentication/BUILD index c6619824914a5..6e2604388adbe 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/authentication/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/authentication/BUILD @@ -16,10 +16,6 @@ go_library( "zz_generated.deepcopy.go", ], tags = ["automanaged"], - visibility = [ - "//vendor/k8s.io/client-go/pkg/api/v1:__pkg__", - "//vendor/k8s.io/client-go/pkg/apis:__subpackages__", - ], deps = [ "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/authentication/install/BUILD b/staging/src/k8s.io/client-go/pkg/apis/authentication/install/BUILD index a06cbfb8369dd..359bb31b98bcb 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/authentication/install/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/authentication/install/BUILD @@ -11,7 +11,6 @@ go_library( name = "go_default_library", srcs = ["install.go"], tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/authentication/v1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/authentication/v1/generated.pb.go index 5c7149b4dbdc5..67948103608b9 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/authentication/v1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/authentication/v1/generated.pb.go @@ -1251,46 +1251,45 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 655 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x53, 0xcd, 0x6e, 0xd3, 0x4c, - 0x14, 0xb5, 0xf3, 0x53, 0x25, 0x93, 0xaf, 0x1f, 0x65, 0x24, 0xa4, 0x28, 0x12, 0x4e, 0x14, 0x58, - 0x74, 0x51, 0xc6, 0xa4, 0xa0, 0x52, 0x15, 0x10, 0xaa, 0x45, 0x85, 0xba, 0x00, 0xa4, 0x81, 0x22, - 0xc4, 0x06, 0x26, 0xce, 0xad, 0x63, 0x52, 0xff, 0x68, 0x3c, 0x36, 0xed, 0xae, 0x8f, 0xc0, 0x92, - 0x25, 0xaf, 0xc1, 0x1b, 0x74, 0x47, 0x77, 0xb0, 0x40, 0x15, 0x0d, 0x2f, 0x82, 0x66, 0x3c, 0xd4, - 0x2e, 0x69, 0x85, 0xda, 0xdd, 0xcc, 0x99, 0x7b, 0xce, 0xbd, 0xe7, 0xde, 0xb9, 0xe8, 0xc1, 0x64, - 0x35, 0x21, 0x7e, 0x64, 0x4f, 0xd2, 0x21, 0xf0, 0x10, 0x04, 0x24, 0x76, 0x3c, 0xf1, 0x6c, 0x16, - 0xfb, 0x89, 0xcd, 0x52, 0x31, 0x86, 0x50, 0xf8, 0x2e, 0x13, 0x7e, 0x14, 0xda, 0xd9, 0xc0, 0xf6, - 0x20, 0x04, 0xce, 0x04, 0x8c, 0x48, 0xcc, 0x23, 0x11, 0xe1, 0xa5, 0x9c, 0x4d, 0x0a, 0x36, 0x89, - 0x27, 0x1e, 0x91, 0x6c, 0x72, 0x9a, 0x4d, 0xb2, 0x41, 0xe7, 0x96, 0xe7, 0x8b, 0x71, 0x3a, 0x24, - 0x6e, 0x14, 0xd8, 0x5e, 0xe4, 0x45, 0xb6, 0x12, 0x19, 0xa6, 0xdb, 0xea, 0xa6, 0x2e, 0xea, 0x94, - 0x8b, 0x77, 0xee, 0xea, 0xd2, 0x58, 0xec, 0x07, 0xcc, 0x1d, 0xfb, 0x21, 0xf0, 0xbd, 0xa2, 0xb8, - 0x00, 0x04, 0x3b, 0xa3, 0xa4, 0x8e, 0x7d, 0x1e, 0x8b, 0xa7, 0xa1, 0xf0, 0x03, 0x98, 0x21, 0xac, - 0xfc, 0x8b, 0x90, 0xb8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, 0x0c, 0x5e, 0x40, 0xd5, 0x09, 0xec, 0xe5, 0x0e, 0xa9, 0x3c, 0xe2, 0x67, 0xa8, 0x9e, 0xc9, - 0xfd, 0xd3, 0x53, 0x58, 0xbd, 0x58, 0x1d, 0xc5, 0xfe, 0xd2, 0x5c, 0x66, 0xad, 0xb2, 0x6a, 0x3a, - 0x37, 0x0f, 0x8e, 0x2d, 0xe3, 0xf0, 0xd8, 0x32, 0xbe, 0x1f, 0x5b, 0xc6, 0xfe, 0xd4, 0x32, 0x0f, - 0xa6, 0x96, 0x79, 0x38, 0xb5, 0xcc, 0x9f, 0x53, 0xcb, 0xfc, 0xf8, 0xcb, 0x32, 0xde, 0x54, 0xb2, - 0xc1, 0xef, 0x00, 0x00, 0x00, 0xff, 0xff, 0xbb, 0x6b, 0x11, 0x20, 0xa4, 0x05, 0x00, 0x00, + // 637 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x53, 0xcd, 0x6e, 0xd3, 0x40, + 0x10, 0xb6, 0xf3, 0x53, 0x25, 0x1b, 0x0a, 0x65, 0x25, 0xa4, 0x28, 0x12, 0x4e, 0x14, 0x38, 0xf4, + 0x50, 0xd6, 0xa4, 0xa0, 0x52, 0x15, 0x10, 0xaa, 0x45, 0x85, 0x7a, 0x00, 0xa4, 0x85, 0x22, 0xc4, + 0x05, 0x36, 0xce, 0xd4, 0x59, 0x52, 0xff, 0x68, 0xbd, 0x0e, 0xf4, 0xd6, 0x47, 0xe0, 0xc8, 0x91, + 0xd7, 0xe0, 0x0d, 0x7a, 0xa3, 0x37, 0x38, 0xa0, 0x8a, 0x86, 0x17, 0x41, 0xbb, 0x5e, 0x1a, 0xb7, + 0xa5, 0x42, 0xe9, 0xcd, 0xfb, 0xcd, 0x7c, 0xdf, 0x7c, 0x33, 0xe3, 0x41, 0x0f, 0x46, 0xab, 0x29, + 0xe1, 0xb1, 0x3b, 0xca,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0x3c, 0xd6, 0xfd, 0x5e, 0x42, 0xb5, 0xbf, 0x2a, 0x78, 0x09, 0xd5, 0x14, 0x33, 0x62, 0x21, + 0x98, 0x31, 0x2c, 0x18, 0x92, 0xce, 0x51, 0x38, 0x3d, 0xce, 0xc0, 0xd7, 0x51, 0x39, 0xe3, 0x03, + 0x6d, 0xbc, 0xee, 0x35, 0x4c, 0x62, 0x79, 0x6b, 0xf3, 0x31, 0x55, 0x38, 0xee, 0xa2, 0xb9, 0x40, + 0xc4, 0x59, 0xa2, 0x96, 0xa9, 0xfe, 0x65, 0xa4, 0xf6, 0xf0, 0x44, 0x23, 0xd4, 0x44, 0xf0, 0x36, + 0xaa, 0x82, 0xfa, 0xf9, 0x9b, 0x95, 0x4e, 0x79, 0xb1, 0xb1, 0xbc, 0x7e, 0xb1, 0xee, 0x89, 0x3e, + 0xa0, 0x8d, 0x48, 0x8a, 0xdd, 0x42, 0x97, 0x0a, 0xa3, 0xb9, 0x7c, 0x4b, 0x98, 0x23, 0xd3, 0x39, + 0x78, 0x01, 0x95, 0x47, 0xb0, 0x9b, 0x77, 0x48, 0xd5, 0x27, 0x7e, 0x86, 0xaa, 0x63, 0x75, 0x7f, + 0x66, 0x0b, 0xab, 0xb3, 0xf9, 0x98, 0xde, 0x2f, 0xcd, 0x65, 0xd6, 0x4a, 0xab, 0xb6, 0x77, 0x73, + 0xff, 0xc8, 0xb1, 0x0e, 0x8e, 0x1c, 0xeb, 0xc7, 0x91, 0x63, 0xed, 0x4d, 0x1c, 0x7b, 0x7f, 0xe2, + 0xd8, 0x07, 0x13, 0xc7, 0xfe, 0x35, 0x71, 0xec, 0x4f, 0xbf, 0x1d, 0xeb, 0x4d, 0x69, 0xdc, 0xfb, + 0x13, 0x00, 0x00, 0xff, 0xff, 0x80, 0xcb, 0xcb, 0x29, 0x6e, 0x05, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/authentication/v1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/authentication/v1/generated.proto index ea5203d37be16..411065848afb1 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/authentication/v1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/authentication/v1/generated.proto @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.authentication.v1; +package k8s.io.client_go.pkg.apis.authentication.v1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1"; diff --git a/staging/src/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.pb.go index 6363a7c4fffd6..5d3b8e8a05218 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.pb.go @@ -1251,47 +1251,46 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 660 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x53, 0x4f, 0x6f, 0xd3, 0x4e, - 0x10, 0x8d, 0xf3, 0xa7, 0xbf, 0x64, 0xf3, 0x2b, 0x94, 0x95, 0x90, 0xa2, 0x48, 0x38, 0x51, 0xb8, - 0x14, 0x09, 0xd6, 0xa4, 0xa0, 0x52, 0xb5, 0xe2, 0x50, 0xab, 0x05, 0xf5, 0x80, 0x90, 0xb6, 0x94, - 0x03, 0x12, 0x12, 0x1b, 0x67, 0xea, 0x18, 0xc7, 0x7f, 0xb4, 0x5e, 0xa7, 0xed, 0xad, 0x1f, 0x81, - 0x23, 0x47, 0xbe, 0x0b, 0x97, 0x1e, 0x7b, 0xe0, 0xc0, 0x01, 0x55, 0x24, 0x7c, 0x11, 0xb4, 0xeb, - 0xa5, 0x76, 0x09, 0x15, 0xa2, 0xbd, 0x79, 0xdf, 0xcc, 0x7b, 0x33, 0x6f, 0xc6, 0x83, 0x36, 0xfd, - 0xb5, 0x84, 0x78, 0x91, 0xe5, 0xa7, 0x03, 0xe0, 0x21, 0x08, 0x48, 0xac, 0xd8, 0x77, 0x2d, 0x16, - 0x7b, 0x89, 0xc5, 0x52, 0x31, 0x82, 0x50, 0x78, 0x0e, 0x13, 0x5e, 0x14, 0x5a, 0x93, 0xfe, 0x00, - 0x04, 0xeb, 0x5b, 0x2e, 0x84, 0xc0, 0x99, 0x80, 0x21, 0x89, 0x79, 0x24, 0x22, 0xdc, 0xcf, 0x24, - 0x48, 0x2e, 0x41, 0x62, 0xdf, 0x25, 0x52, 0x82, 0x5c, 0x94, 0x20, 0x5a, 0xa2, 0xfd, 0xc0, 0xf5, - 0xc4, 0x28, 0x1d, 0x10, 0x27, 0x0a, 0x2c, 0x37, 0x72, 0x23, 0x4b, 0x29, 0x0d, 0xd2, 0x7d, 0xf5, - 0x52, 0x0f, 0xf5, 0x95, 0x55, 0x68, 0x3f, 0xd6, 0x4d, 0xb2, 0xd8, 0x0b, 0x98, 0x33, 0xf2, 0x42, - 0xe0, 0x47, 0x79, 0x9b, 0x01, 0x08, 0x66, 0x4d, 0xe6, 0xfa, 0x6a, 0x5b, 0x97, 0xb1, 0x78, 0x1a, - 0x0a, 0x2f, 0x80, 0x39, 0xc2, 0xea, 0xdf, 0x08, 0x89, 0x33, 0x82, 0x80, 0xcd, 0xf1, 0x1e, 0x5d, - 0xc6, 0x4b, 0x85, 0x37, 0xb6, 0xbc, 0x50, 0x24, 0x82, 0xcf, 0x91, 0x0a, 0x9e, 0x12, 0xe0, 0x13, - 0xe0, 0xb9, 0x21, 0x38, 0x64, 0x41, 0x3c, 0x86, 0x3f, 0x78, 0xea, 0x3d, 0x41, 0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 0xd2, 0xe9, 0xd4, 0x2c, 0x7d, 0x9d, 0x9a, - 0xa5, 0xe3, 0x99, 0x69, 0x9c, 0xcc, 0x4c, 0xe3, 0x74, 0x66, 0x1a, 0xdf, 0x67, 0xa6, 0xf1, 0xe1, - 0x87, 0x59, 0x7a, 0xf3, 0x9f, 0x16, 0xf8, 0x19, 0x00, 0x00, 0xff, 0xff, 0xc6, 0x0a, 0xc4, 0x2e, - 0xcc, 0x05, 0x00, 0x00, + // 645 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x53, 0x4d, 0x6f, 0xd3, 0x4c, + 0x10, 0xb6, 0xf3, 0xd1, 0x37, 0xd9, 0xbc, 0x7d, 0xdf, 0xb2, 0x12, 0x52, 0x14, 0x09, 0x27, 0x0a, + 0x97, 0x22, 0xc1, 0x9a, 0x14, 0x54, 0xaa, 0x56, 0x1c, 0x6a, 0xb5, 0xa0, 0x1e, 0x10, 0xd2, 0x96, + 0x72, 0x40, 0x42, 0x62, 0xe3, 0x4c, 0x9d, 0xc5, 0xf5, 0x87, 0xd6, 0xeb, 0x94, 0xde, 0xfa, 0x13, + 0x38, 0x72, 0xe4, 0xbf, 0x70, 0xe9, 0xb1, 0x07, 0x0e, 0x1c, 0x50, 0x45, 0xc2, 0x1f, 0x41, 0xbb, + 0x5e, 0x9a, 0xb4, 0x51, 0x85, 0x68, 0x6f, 0xde, 0x67, 0xe6, 0x79, 0xe6, 0x99, 0x19, 0x0f, 0xda, + 0x0c, 0xd7, 0x32, 0xc2, 0x13, 0x37, 0xcc, 0xfb, 0x20, 0x62, 0x90, 0x90, 0xb9, 0x69, 0x18, 0xb8, + 0x2c, 0xe5, 0x99, 0xcb, 0x72, 0x39, 0x84, 0x58, 0x72, 0x9f, 0x49, 0x9e, 0xc4, 0xee, 0xa8, 0xd7, + 0x07, 0xc9, 0x7a, 0x6e, 0x00, 0x31, 0x08, 0x26, 0x61, 0x40, 0x52, 0x91, 0xc8, 0x04, 0xf7, 0x0a, + 0x09, 0x32, 0x95, 0x20, 0x69, 0x18, 0x10, 0x25, 0x41, 0x2e, 0x4a, 0x10, 0x23, 0xd1, 0x7a, 0x10, + 0x70, 0x39, 0xcc, 0xfb, 0xc4, 0x4f, 0x22, 0x37, 0x48, 0x82, 0xc4, 0xd5, 0x4a, 0xfd, 0x7c, 0x5f, + 0xbf, 0xf4, 0x43, 0x7f, 0x15, 0x15, 0x5a, 0x8f, 0x8d, 0x49, 0x96, 0xf2, 0x88, 0xf9, 0x43, 0x1e, + 0x83, 0x38, 0x9a, 0xda, 0x8c, 0x40, 0x32, 0x77, 0x34, 0xe7, 0xab, 0xe5, 0x5e, 0xc5, 0x12, 0x79, + 0x2c, 0x79, 0x04, 0x73, 0x84, 0xd5, 0x3f, 0x11, 0x32, 0x7f, 0x08, 0x11, 0x9b, 0xe3, 0x3d, 0xba, + 0x8a, 0x97, 0x4b, 0x7e, 0xe0, 0xf2, 0x58, 0x66, 0x52, 0x5c, 0x26, 0x75, 0x9f, 0x20, 0xb4, 0xfd, + 0x41, 0x0a, 0xf6, 0x9a, 0x1d, 0xe4, 0x80, 0xdb, 0xa8, 0xca, 0x25, 0x44, 0x59, 0xd3, 0xee, 0x94, + 0x97, 0xeb, 0x5e, 0x7d, 0x72, 0xd6, 0xae, 0xee, 0x28, 0x80, 0x16, 0xf8, 0x7a, 0xed, 0xd3, 0xe7, + 0xb6, 0x75, 0xfc, 0xbd, 0x63, 0x75, 0xbf, 0x94, 0x50, 0xe3, 0x55, 0x12, 0x42, 0x4c, 0x61, 0xc4, + 0xe1, 0x10, 0xbf, 0x43, 0x35, 0x35, 0x81, 0x01, 0x93, 0xac, 0x69, 0x77, 0xec, 0xe5, 0xc6, 0xca, + 0x43, 0x62, 0x36, 0x32, 0x6b, 0x68, 0xba, 0x13, 0x95, 0x4d, 0x46, 0x3d, 0xf2, 0xb2, 0xff, 0x1e, + 0x7c, 0xf9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 0x81, 0x76, 0x5f, 0xf7, 0x1a, 0x26, 0xb1, 0xbc, 0xb7, + 0xb3, 0x45, 0x15, 0x8e, 0xbb, 0x68, 0x21, 0x10, 0x49, 0x9e, 0xaa, 0xb5, 0xaa, 0x5f, 0x1b, 0xa9, + 0x65, 0x3c, 0xd7, 0x08, 0x35, 0x11, 0x1c, 0xa2, 0x2a, 0xa8, 0x5b, 0x68, 0x56, 0x3a, 0xe5, 0xe5, + 0xc6, 0xca, 0xb3, 0x1b, 0x8c, 0x80, 0xe8, 0xa3, 0xda, 0x8e, 0xa5, 0x38, 0x9a, 0x69, 0x55, 0x61, + 0xb4, 0xa8, 0xd1, 0x3a, 0x34, 0x87, 0xa7, 0x73, 0xf0, 0x12, 0x2a, 0x87, 0x70, 0x54, 0xb4, 0x49, + 0xd5, 0x27, 0xde, 0x45, 0xd5, 0x91, 0xba, 0x49, 0xb3, 0x8f, 0xa7, 0xd7, 0x30, 0x33, 0x3d, 0x6c, + 0x5a, 0x68, 0xad, 0x97, 0xd6, 0x6c, 0xef, 0xde, 0xc9, 0xd8, 0xb1, 0x4e, 0xc7, 0x8e, 0xf5, 0x6d, + 0xec, 0x58, 0xc7, 0x13, 0xc7, 0x3e, 0x99, 0x38, 0xf6, 0xe9, 0xc4, 0xb1, 0x7f, 0x4c, 0x1c, 0xfb, + 0xe3, 0x4f, 0xc7, 0x7a, 0xf3, 0x8f, 0x11, 0xf8, 0x15, 0x00, 0x00, 0xff, 0xff, 0x45, 0x22, 0xbd, + 0x60, 0x96, 0x05, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.proto index e0d3f0ddffeb4..316a62e8e549f 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.proto @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.authentication.v1beta1; +package k8s.io.client_go.pkg.apis.authentication.v1beta1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; diff --git a/staging/src/k8s.io/client-go/pkg/apis/authorization/BUILD b/staging/src/k8s.io/client-go/pkg/apis/authorization/BUILD index c6619824914a5..6e2604388adbe 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/authorization/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/authorization/BUILD @@ -16,10 +16,6 @@ go_library( "zz_generated.deepcopy.go", ], tags = ["automanaged"], - visibility = [ - "//vendor/k8s.io/client-go/pkg/api/v1:__pkg__", - "//vendor/k8s.io/client-go/pkg/apis:__subpackages__", - ], deps = [ "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/authorization/install/BUILD b/staging/src/k8s.io/client-go/pkg/apis/authorization/install/BUILD index 61e7d8fc099bd..e56e44fb45834 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/authorization/install/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/authorization/install/BUILD @@ -11,7 +11,6 @@ go_library( name = "go_default_library", srcs = ["install.go"], tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/authorization/v1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/authorization/v1/generated.pb.go index 937d6b8ea7a72..b4603d281097b 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/authorization/v1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/authorization/v1/generated.pb.go @@ -2298,62 +2298,61 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 898 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x56, 0x4f, 0x6f, 0x1b, 0x45, - 0x14, 0xf7, 0xfa, 0x5f, 0xec, 0x09, 0x90, 0x32, 0x55, 0xc9, 0x36, 0x48, 0xb6, 0x65, 0x10, 0x0a, - 0x02, 0x76, 0x49, 0xf9, 0xd3, 0xaa, 0x1c, 0x50, 0x56, 0x84, 0x3f, 0x12, 0x6d, 0xd1, 0x44, 0xe4, - 0x00, 0x17, 0xc6, 0x9b, 0x17, 0x7b, 0x6b, 0xef, 0xce, 0x32, 0x33, 0xbb, 0x6d, 0x38, 0xf5, 0xc6, - 0x15, 0x89, 0x0b, 0x47, 0xbe, 0x02, 0x1f, 0x00, 0xce, 0xb9, 0xd1, 0x03, 0x12, 0x1c, 0x90, 0x45, - 0x96, 0x0b, 0x1f, 0x03, 0xcd, 0xec, 0xc4, 0x6b, 0xe3, 0x0d, 0x95, 0xa1, 0x12, 0x1c, 0x72, 0xdb, - 0x79, 0xef, 0xf7, 0x7b, 0xef, 0xf7, 0x66, 0xde, 0xec, 0x1b, 0xf4, 0xd6, 0xf8, 0x86, 0x70, 0x02, - 0xe6, 0x8e, 0x93, 0x01, 0xf0, 0x08, 0x24, 0x08, 0x37, 0x1e, 0x0f, 0x5d, 0x1a, 0x07, 0xc2, 0xa5, - 0x89, 0x1c, 0x31, 0x1e, 0x7c, 0x41, 0x65, 0xc0, 0x22, 0x37, 0xdd, 0x71, 0x87, 0x10, 0x01, 0xa7, - 0x12, 0x0e, 0x9d, 0x98, 0x33, 0xc9, 0xf0, 0x4b, 0x39, 0xd9, 0x29, 0xc8, 0x4e, 0x3c, 0x1e, 0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 0xc7, 0x39, 0x5f, 0x53, 0x71, 0xa0, 0x0a, 0xed, 0xa4, 0x3b, - 0xce, 0x1d, 0x1d, 0xeb, 0x16, 0x48, 0xea, 0xe1, 0x93, 0x69, 0xb7, 0x92, 0x4d, 0xbb, 0xa8, 0xb0, - 0x91, 0x59, 0x54, 0x7c, 0x84, 0xea, 0x22, 0x06, 0xdf, 0xae, 0xea, 0xe8, 0xef, 0x38, 0x2b, 0x34, - 0x8b, 0x53, 0xa2, 0x78, 0x3f, 0x06, 0xdf, 0x7b, 0xc2, 0x64, 0xac, 0xab, 0x15, 0xd1, 0xf1, 0x71, - 0x84, 0x9a, 0x42, 0x52, 0x99, 0x08, 0xbb, 0xa6, 0x33, 0xbd, 0xfb, 0xaf, 0x33, 0xe9, 0x68, 0xde, - 0x53, 0x26, 0x57, 0x33, 0x5f, 0x13, 0x93, 0xa5, 0xff, 0x29, 0xba, 0x72, 0x9b, 0x45, 0x04, 0x04, - 0x4b, 0xb8, 0x0f, 0xbb, 0x52, 0xf2, 0x60, 0x90, 0x48, 0x10, 0xb8, 0x87, 0xea, 0x31, 0x95, 0x23, - 0xbd, 0x9d, 0xed, 0x42, 0xea, 0x47, 0x54, 0x8e, 0x88, 0xf6, 0x28, 0x44, 0x0a, 0x7c, 0xa0, 0xb7, - 0x64, 0x0e, 0x71, 0x00, 0x7c, 0x40, 0xb4, 0xa7, 0xff, 0x43, 0x15, 0xe1, 0x92, 0xd0, 0x2e, 0x6a, - 0x47, 0x34, 0x04, 0x11, 0x53, 0x1f, 0x4c, 0xfc, 0xa7, 0x0d, 0xbb, 0x7d, 0xfb, 0xcc, 0x41, 0x0a, - 0xcc, 0xa3, 0x33, 0xe1, 0xe7, 0x50, 0x63, 0xc8, 0x59, 0x12, 0xeb, 0x5d, 0x6b, 0x7b, 0x4f, 0x1a, - 0x48, 0xe3, 0x3d, 0x65, 0x24, 0xb9, 0x0f, 0xbf, 0x88, 0xd6, 0x52, 0xe0, 0x22, 0x60, 0x91, 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0xff, 0xff, 0x43, 0x53, 0x67, 0x22, 0x02, 0x0c, + // 882 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x56, 0x4f, 0x6f, 0xdc, 0x44, + 0x14, 0x5f, 0xef, 0xbf, 0xec, 0x4e, 0x80, 0x94, 0xa9, 0x4a, 0xdc, 0x20, 0xed, 0xae, 0x0c, 0x42, + 0x41, 0x80, 0x4d, 0xca, 0x9f, 0x56, 0xe5, 0x80, 0x62, 0x11, 0xfe, 0x48, 0xb4, 0x45, 0x13, 0x91, + 0x03, 0x5c, 0x18, 0x3b, 0x2f, 0xbb, 0xee, 0xee, 0x7a, 0xcc, 0xcc, 0xd8, 0x25, 0x9c, 0x7a, 0xe3, + 0x8a, 0xc4, 0x85, 0x23, 0x5f, 0x81, 0x0f, 0x00, 0xe7, 0xdc, 0xe8, 0x01, 0x09, 0x0e, 0x68, 0x45, + 0xcc, 0x85, 0x8f, 0x81, 0x66, 0x3c, 0x59, 0x67, 0x1b, 0x87, 0x6a, 0xa1, 0x12, 0x1c, 0x72, 0xf3, + 0xbc, 0xf7, 0xfb, 0xbd, 0xf7, 0x9b, 0x37, 0x6f, 0xfc, 0x06, 0xbd, 0x35, 0xbe, 0x21, 0xdc, 0x88, + 0x79, 0xe3, 0x34, 0x00, 0x1e, 0x83, 0x04, 0xe1, 0x25, 0xe3, 0xa1, 0x47, 0x93, 0x48, 0x78, 0x34, + 0x95, 0x23, 0xc6, 0xa3, 0x2f, 0xa9, 0x8c, 0x58, 0xec, 0x65, 0x5b, 0xde, 0x10, 0x62, 0xe0, 0x54, + 0xc2, 0xbe, 0x9b, 0x70, 0x26, 0x19, 0x7e, 0xa9, 0x20, 0xbb, 0x25, 0xd9, 0x4d, 0xc6, 0x43, 0x57, + 0x91, 0xdd, 0x05, 0xb2, 0x9b, 0x6d, 0x6d, 0xbc, 0x32, 0x8c, 0xe4, 0x28, 0x0d,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x9d, 0x9d, 0x58, 0xf2, 0xc3, 0x72, 0x2a, 0x69, 0x1b, 0x29, 0x92, 0x6d, 0x7c, 0x6e, 0x5e, 0x44, + 0x1a, 0x83, 0x2f, 0xa1, 0xc6, 0x18, 0x0e, 0x8b, 0xa9, 0x48, 0xd4, 0x27, 0xbe, 0x85, 0x5a, 0x99, + 0x7a, 0x2c, 0x99, 0x02, 0x5f, 0x5f, 0x4a, 0x55, 0xf9, 0xd6, 0x22, 0x45, 0x94, 0x9b, 0xf5, 0x1b, + 0x96, 0xf3, 0xbd, 0x85, 0xae, 0x9e, 0xdb, 0xa0, 0x6a, 0x4c, 0xd2, 0xc9, 0x84, 0xdd, 0x83, 0x7d, + 0x2d, 0xa3, 0x53, 0x8e, 0xc9, 0xed, 0xc2, 0x4c, 0x4e, 0xfc, 0xf8, 0x05, 0xd4, 0xe6, 0x40, 0x05, + 0x8b, 0xcd, 0x68, 0x9e, 0xf7, 0x36, 0xd1, 0x56, 0x62, 0xbc, 0x78, 0x1b, 0xad, 0x81, 0x4a, 0xaf, + 0x75, 0xed, 0x70, 0xce, 0xb8, 0x39, 0xaa, 0x75, 0x43, 0x58, 0xdb, 0x59, 0x74, 0x93, 0x87, 0xf1, + 0xfe, 0xf3, 0x47, 0xc7, 0xbd, 0xda, 0x83, 0xe3, 0x5e, 0xed, 0xd7, 0xe3, 0x5e, 0xed, 0x7e, 0xde, + 0xb3, 0x8e, 0xf2, 0x9e, 0xf5, 0x20, 0xef, 0x59, 0xbf, 0xe7, 0x3d, 0xeb, 0xeb, 0x3f, 0x7a, 0xb5, + 0x4f, 0xea, 0xd9, 0xd6, 0x5f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x75, 0x52, 0x96, 0xf3, 0xcc, 0x0b, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/authorization/v1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/authorization/v1/generated.proto index 334e6a375161c..9048e4fa40d37 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/authorization/v1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/authorization/v1/generated.proto @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.authorization.v1; +package k8s.io.client_go.pkg.apis.authorization.v1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1"; diff --git a/staging/src/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.pb.go index 725e9559fac5d..55142031f421d 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.pb.go @@ -2298,62 +2298,61 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 898 bytes of a gzipped FileDescriptorProto + // 882 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x56, 0x4f, 0x6f, 0xdc, 0x44, - 0x14, 0x5f, 0xef, 0x9f, 0x64, 0x77, 0x02, 0xa4, 0x4c, 0x55, 0xe2, 0x06, 0x69, 0x77, 0xb5, 0x48, - 0x28, 0x95, 0xc0, 0x6e, 0xca, 0xbf, 0xaa, 0xe2, 0x40, 0x2c, 0xa2, 0xaa, 0x82, 0x16, 0x34, 0x81, - 0x1c, 0xe0, 0xc2, 0xd8, 0x79, 0xdd, 0x35, 0xbb, 0xf6, 0x58, 0x33, 0x63, 0xb7, 0xe1, 0xd4, 0x0f, - 0xc0, 0x81, 0x63, 0x8f, 0x7c, 0x05, 0xbe, 0x00, 0x57, 0x72, 0xec, 0x11, 0x24, 0xb4, 0x22, 0xe6, - 0x5b, 0x70, 0x42, 0x33, 0x9e, 0x5d, 0x67, 0x59, 0x87, 0x6a, 0xa1, 0x88, 0x1e, 0x72, 0xb3, 0xdf, - 0xfb, 0xbd, 0xdf, 0xfb, 0xbd, 0x99, 0x37, 0xf3, 0x06, 0x7d, 0x30, 0xbe, 0x29, 0x9c, 0x90, 0xb9, - 0xe3, 0xd4, 0x07, 0x1e, 0x83, 0x04, 0xe1, 0x26, 0xe3, 0xa1, 0x4b, 0x93, 0x50, 0xb8, 0x34, 0x95, - 0x23, 0xc6, 0xc3, 0x6f, 0xa8, 0x0c, 0x59, 0xec, 0x66, 0xbb, 0x3e, 0x48, 0xba, 0xeb, 0x0e, 0x21, - 0x06, 0x4e, 0x25, 0x1c, 0x39, 0x09, 0x67, 0x92, 0xe1, 0xeb, 0x05, 0x83, 0x53, 0x32, 0x38, 0xc9, - 0x78, 0xe8, 0x28, 0x06, 0x67, 0x81, 0xc1, 0x31, 0x0c, 0xdb, 0x6f, 0x0e, 0x43, 0x39, 0x4a, 0x7d, - 0x27, 0x60, 0x91, 0x3b, 0x64, 0x43, 0xe6, 0x6a, 0x22, 0x3f, 0xbd, 0xaf, 0xff, 0xf4, 0x8f, 0xfe, - 0x2a, 0x12, 0x6c, 0xbf, 0x6d, 0x24, 0xd2, 0x24, 0x8c, 0x68, 0x30, 0x0a, 0x63, 0xe0, 0xc7, 0xa5, - 0xc8, 0x08, 0x24, 0x75, 0xb3, 0x25, 0x59, 0xdb, 0xee, 0x79, 0x51, 0x3c, 0x8d, 0x65, 0x18, 0xc1, - 0x52, 0xc0, 0xbb, 0x4f, 0x0b, 0x10, 0xc1, 0x08, 0x22, 0xba, 0x14, 0xf7, 0xd6, 0x79, 0x71, 0xa9, - 0x0c, 0x27, 0x6e, 0x18, 0x4b, 0x21, 0xf9, 0x52, 0xd0, 0x99, 0x9a, 0x04, 0xf0, 0x0c, 0x78, 0x59, - 0x10, 0x3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 0x4e, 0x9d, 0xda, 0xe3, 0x53, 0xa7, 0xf6, 0xcb, 0xa9, 0x53, 0x7b, 0x98, + 0x3b, 0xd6, 0x49, 0xee, 0x58, 0x8f, 0x73, 0xc7, 0xfa, 0x3d, 0x77, 0xac, 0xef, 0xff, 0x70, 0x6a, + 0x5f, 0xac, 0x9b, 0x45, 0xff, 0x15, 0x00, 0x00, 0xff, 0xff, 0x6e, 0x0d, 0x81, 0xe2, 0x15, 0x0c, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.proto index 9258e4e06bbae..104e3573c9350 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.proto @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.authorization.v1beta1; +package k8s.io.client_go.pkg.apis.authorization.v1beta1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; diff --git a/staging/src/k8s.io/client-go/pkg/apis/autoscaling/BUILD b/staging/src/k8s.io/client-go/pkg/apis/autoscaling/BUILD index 7587ba8d79299..f2d4141e705c0 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/autoscaling/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/autoscaling/BUILD @@ -17,10 +17,6 @@ go_library( "zz_generated.deepcopy.go", ], tags = ["automanaged"], - visibility = [ - "//vendor/k8s.io/client-go/pkg/api/v1:__pkg__", - "//vendor/k8s.io/client-go/pkg/apis:__subpackages__", - ], deps = [ "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/autoscaling/install/BUILD b/staging/src/k8s.io/client-go/pkg/apis/autoscaling/install/BUILD index 600c33347e9d2..eb0f54888fdec 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/autoscaling/install/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/autoscaling/install/BUILD @@ -11,7 +11,6 @@ go_library( name = "go_default_library", srcs = ["install.go"], tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.pb.go index 4c9d293839ea6..323d43322e7c7 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.pb.go @@ -3420,85 +3420,85 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 1279 bytes of a gzipped FileDescriptorProto + // 1266 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x57, 0xcd, 0x6f, 0x1b, 0x45, - 0x14, 0xcf, 0xda, 0x4e, 0x94, 0xce, 0xa6, 0x1f, 0x4c, 0xaa, 0xd4, 0x4d, 0xa8, 0x37, 0x5a, 0x38, - 0xb4, 0xa8, 0xec, 0x12, 0x13, 0x2a, 0x22, 0x84, 0x50, 0x6c, 0x54, 0x5a, 0x51, 0xb7, 0x61, 0xe2, - 0x46, 0x7c, 0x09, 0x31, 0x59, 0x4f, 0x9d, 0x69, 0xbc, 0x1f, 0x9a, 0x1d, 0x5b, 0x4d, 0x24, 0x24, -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xda, 0x05, 0x69, 0x29, 0x8e, 0xe7, 0x70, - 0x0c, 0x09, 0x6b, 0x88, 0xc1, 0x8c, 0x2b, 0x76, 0x86, 0x5c, 0x97, 0x77, 0x27, 0xd8, 0x5e, 0x71, - 0x6f, 0x8e, 0x81, 0x2b, 0x20, 0xec, 0x68, 0x72, 0xab, 0x49, 0x60, 0xf8, 0x09, 0x28, 0x78, 0x6e, - 0xa3, 0xd7, 0x41, 0xdf, 0x99, 0x80, 0x60, 0xc3, 0x6d, 0xf8, 0x29, 0xf8, 0xd9, 0x30, 0xa3, 0x70, - 0x14, 0x09, 0x48, 0x48, 0xc1, 0x6c, 0xef, 0xca, 0x21, 0x56, 0x4b, 0x2d, 0xbf, 0x37, 0x01, 0x3c, - 0x92, 0xae, 0x29, 0x8a, 0xb9, 0xb0, 0x33, 0xf6, 0x66, 0x50, 0x0c, 0xaf, 0xff, 0x9d, 0x03, 0x73, - 0xd2, 0x30, 0xda, 0x20, 0xff, 0xb1, 0xde, 0xd1, 0x29, 0xf2, 0xdc, 0xf4, 0x8e, 0xe0, 0x9f, 0xab, - 0xde, 0x11, 0x45, 0x96, 0xde, 0xdf, 0xe7, 0x00, 0x1c, 0x2e, 0x30, 0xe8, 0x80, 0x99, 0xa8, 0xb5, - 0x9d, 0xf2, 0x71, 0x10, 0x1f, 0xc7, 0xb2, 0xf3, 0x4b, 0x96, 0xf0, 0x72, 0x64, 0x0b, 0xfe, 0xbb, - 0xfd, 0x4b, 0x54, 0x7c, 0x39, 0xa9, 0xc5, 0x33, 0x28, 0x61, 0x05, 0x09, 0x50, 0x23, 0xef, 0x2d, - 0xdc, 0x6a, 0x13, 0xb9, 0x0e, 0x63, 0x4f, 0x69, 0xa3, 0x97, 0xb6, 0xf1, 0x51, 0x1b, 0x3b, 0x9c, - 0xf2, 0xbd, 0xfe, 0x79, 0x51, 0xef, 0x43, 0xa1, 0x24, 0xae, 0xfe, 0xe3, 0xa0, 0x42, 0x51, 0x5d, - 0xfe, 0x1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x75, 0x2b, 0xf5, 0x42, 0x5d, 0x9d, 0xa0, 0x05, - 0x8b, 0x08, 0x33, 0xdf, 0xa3, 0x5f, 0x0c, 0xbc, 0x47, 0x6f, 0x4c, 0x8c, 0x3c, 0xfe, 0xf5, 0xb9, - 0x06, 0xce, 0xc4, 0x01, 0xc0, 0xeb, 0xe1, 0x69, 0x2f, 0xef, 0xc2, 0x8a, 0x58, 0xfb, 0xf8, 0xe9, - 0x18, 0x5f, 0x82, 0x63, 0x0b, 0x9d, 0x02, 0x35, 0xc1, 0x30, 0x99, 0x73, 0x68, 0xed, 0x93, 0x16, - 0xb1, 0xb8, 0xcb, 0xe4, 0x11, 0x12, 0x5b, 0x6f, 0xca, 0x71, 0x14, 0x5b, 0x54, 0x5e, 0x3d, 0x38, - 0x2c, 0x4d, 0x3d, 0x39, 0x2c, 0x4d, 0xfd, 0x76, 0x58, 0x9a, 0xfa, 0x3a, 0x28, 0x29, 0x07, 0x41, - 0x49, 0x79, 0x12, 0x94, 0x94, 0xdf, 0x83, 0x92, 0xf2, 0xed, 0x1f, 0xa5, 0xa9, 0x4f, 0x73, 0x9d, - 0x95, 0x7f, 0x03, 0x00, 0x00, 0xff, 0xff, 0x61, 0xfc, 0xd4, 0x31, 0x3f, 0x13, 0x00, 0x00, + 0x14, 0xcf, 0xda, 0x4e, 0x94, 0xce, 0xe6, 0x8b, 0x49, 0x95, 0xba, 0x09, 0xf5, 0x46, 0x0b, 0x87, + 0x16, 0x95, 0x5d, 0x62, 0x42, 0x45, 0x84, 0x10, 0x8a, 0x8d, 0x4a, 0x2b, 0xea, 0x36, 0x4c, 0xdc, + 0x88, 0x2f, 0x21, 0x26, 0xeb, 0xa9, 0x33, 0x8d, 0xf7, 0x43, 0xbb, 0x63, 0x8b, 0x44, 0x42, 0xe2, + 0xc4, 0x99, 0x0b, 0x67, 0x04, 0xff, 0x04, 0xe7, 0x22, 0x21, 0xe5, 0xd8, 0x1b, 0x9c, 0x56, 0x64, + 0xe1, 0x86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0x56, 0x13, 0xc0, 0xf0, 0x13, + 0x50, 0x70, 0xec, 0x46, 0xb7, 0x83, 0xbe, 0x33, 0x06, 0xc1, 0x96, 0xdd, 0xf0, 0x52, 0xf0, 0xd3, + 0x61, 0x46, 0xe1, 0x28, 0xe2, 0x90, 0x90, 0x82, 0xe9, 0xee, 0xe5, 0x81, 0xaf, 0x96, 0x5c, 0x7e, + 0x6f, 0x0c, 0x78, 0x24, 0x5c, 0x53, 0x14, 0x33, 0x61, 0x67, 0xec, 0xce, 0xa0, 0x18, 0x5e, 0xfd, + 0x27, 0x07, 0x66, 0x84, 0x61, 0xb4, 0x41, 0xfe, 0x67, 0xbd, 0xa3, 0x53, 0xe4, 0x99, 0xe9, 0x1d, + 0xc1, 0x3f, 0x53, 0xbd, 0x23, 0x8a, 0x2c, 0xbd, 0x7f, 0xc8, 0x01, 0x38, 0x58, 0x60, 0xd0, 0x02, + 0x53, 0x51, 0x6b, 0x3b, 0xe7, 0xe3, 0x20, 0x3e, 0x8e, 0x45, 0xe7, 0x17, 0x2c, 0xe1, 0xe5, 0xc8, + 0xe4, 0xfc, 0x77, 0x7b, 0x97, 0xa8, 0xf8, 0x72, 0x52, 0x8b, 0x67, 0x50, 0xc2, 0x0a, 0x12, 0x20, + 0x47, 0xde, 0x3b, 0xb8, 0xd5, 0x26, 0x62, 0x1d, 0x46, 0x9e, 0xd2, 0x5a, 0x37, 0x6d, 0xed, 0xa3, + 0x36, 0xb6, 0x18, 0x65, 0x07, 0xbd, 0xf3, 0xa2, 0xde, 0x83, 0x42, 0x49, 0x5c, 0xf5, 0xa7, 0x7e, + 0x85, 0xa2, 0xba, 0x7c, 0x11, 0x14, 0xda, 0x03, 0x33, 0xa2, 0xbb, 0x3d, 0x8d, 0x44, 0x17, 0x05, + 0xcb, 0x4c, 0x35, 0x81, 0x85, 0x52, 0xc8, 0xea, 0x2f, 0x12, 0x58, 0xe8, 0x6f, 0x23, 0x7d, 0x21, + 0x4b, 0xa7, 0x0a, 0x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 0xed, 0xc5, 0x5d, 0x58, 0xe2, 0x6b, + 0x1f, 0x3f, 0x1d, 0xe3, 0x4b, 0x70, 0x6c, 0xa1, 0x52, 0x20, 0x27, 0x18, 0xc6, 0x73, 0x0e, 0xad, + 0x3d, 0xd2, 0x22, 0x06, 0xb3, 0x5d, 0x71, 0x84, 0xc4, 0xd6, 0xdb, 0x62, 0x1c, 0xc5, 0x16, 0x95, + 0x57, 0x8f, 0x8e, 0x4b, 0x13, 0x8f, 0x8f, 0x4b, 0x13, 0xbf, 0x1f, 0x97, 0x26, 0xbe, 0x09, 0x4a, + 0xd2, 0x51, 0x50, 0x92, 0x1e, 0x07, 0x25, 0xe9, 0x8f, 0xa0, 0x24, 0x7d, 0xf7, 0x67, 0x69, 0xe2, + 0xd3, 0x5c, 0x67, 0xed, 0xbf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x83, 0xac, 0x71, 0x0f, 0x09, 0x13, + 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.proto index 4953624af6879..d0a3d85f8d53e 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.proto @@ -19,14 +19,13 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.autoscaling.v1; +package k8s.io.client_go.pkg.apis.autoscaling.v1; import "k8s.io/apimachinery/pkg/api/resource/generated.proto"; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; // Package-wide variables from generator "generated". diff --git a/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.pb.go index 87b1faa62aa6a..086117d5b0fad 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.pb.go @@ -2988,81 +2988,80 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 1208 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x57, 0x5b, 0x6f, 0x1b, 0x45, - 0x14, 0x8e, 0x2f, 0x49, 0xc3, 0x38, 0x37, 0x26, 0x55, 0xea, 0x26, 0xd4, 0x8e, 0xf6, 0xa9, 0x54, - 0xb0, 0x4b, 0x4c, 0x41, 0x54, 0x08, 0xa1, 0xd8, 0x5c, 0x5a, 0x11, 0xa7, 0x61, 0x1a, 0x2a, 0x04, - 0x48, 0x30, 0x59, 0x4f, 0x9c, 0x21, 0xde, 0x8b, 0x76, 0x66, 0xad, 0x26, 0x52, 0x25, 0x7e, 0x00, - 0x0f, 0xbc, 0xf0, 0x13, 0x90, 0xf8, 0x07, 0x3c, 0x83, 0x84, 0x94, 0xc7, 0xf2, 0xc6, 0x93, 0x45, - 0xdc, 0x37, 0x7e, 0x42, 0x25, 0x2e, 0xda, 0x99, 0xf1, 0x5e, 0xbc, 0x5e, 0x13, 0x87, 0xb4, 0x82, - 0x37, 0xef, 0xcc, 0x39, 0xdf, 0x77, 0xce, 0xf9, 0xce, 0x9c, 0x19, 0x83, 0xb7, 0x0f, 0xdf, 0x60, - 0x3a, 0x75, 0x8c, 0x43, 0x7f, 0x8f, 0x78, 0x36, 0xe1, 0x84, 0x19, 0xee, 0x61, 0xdb, 0xc0, 0x2e, - 0x65, 0x06, 0xf6, 0xb9, 0xc3, 0x4c, 0xdc, 0xa1, 0x76, 0xdb, 0xe8, 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0x60, 0xc6, 0x65, 0x85, - 0xa9, 0x1a, 0x4e, 0xa5, 0xda, 0x8d, 0xb3, 0x35, 0x6f, 0xe0, 0x51, 0x7f, 0xbe, 0xdf, 0xab, 0xce, - 0x6f, 0xc5, 0x41, 0x50, 0x12, 0x13, 0x6e, 0x82, 0x45, 0xd3, 0xf7, 0x3c, 0x62, 0xf3, 0xa1, 0x8a, - 0x5f, 0x51, 0x15, 0x58, 0x6c, 0x24, 0xb7, 0xd1, 0xb0, 0x7d, 0x00, 0xd1, 0x22, 0x8c, 0x7a, 0xa4, - 0x15, 0x42, 0x14, 0x93, 0x10, 0xef, 0x24, 0xb7, 0xd1, 0xb0, 0x3d, 0x7c, 0x08, 0x16, 0x14, 0xaa, - 0xaa, 0x77, 0x79, 0x5a, 0x68, 0xf8, 0xd6, 0x79, 0x35, 0x94, 0x13, 0x23, 0xec, 0xd2, 0x46, 0x02, - 0x1c, 0x0d, 0x91, 0x69, 0x7f, 0xe4, 0x01, 0x88, 0xc4, 0x87, 0x37, 0x41, 0x91, 0x1f, 0xb9, 0x44, - 0x5d, 0x17, 0xeb, 0x83, 0x51, 0xb7, 0x7b, 0xe4, 0x92, 0x27, 0xbd, 0xea, 0x92, 0xb2, 0x14, 0xb7, - 0x7f, 0xb0, 0x86, 0x84, 0x35, 0x6c, 0x83, 0x19, 0x47, 0x9c, 0x12, 0xa5, 0x53, 0x63, 0xe2, 0xd8, - 0xc3, 0x29, 0x1e, 0xc2, 0xd7, 0x41, 0x30, 0xef, 0xd4, 0xe1, 0x53, 0xf0, 0xf0, 0x73, 0x50, 0x74, - 0x9d, 0xd6, 0x60, 0xca, 0x6e, 0x4e, 0x4c, 0xb3, 0xe3, 0xb4, 0x58, 0x82, 0x64, 0x36, 0xc8, 0x2e, - 0x58, 0x45, 0x02, 0x18, 0x3a, 0x60, 0x76, 0xf0, 0xba, 0x11, 0x4a, 0x96, 0x6a, 0xef, 0x4e, 0x4c, - 0x82, 0x14, 0x40, 0x82, 0x68, 0x2e, 0x98, 0xa1, 0x83, 0x1d, 0x14, 0x92, 0x68, 0x7f, 0xe5, 0xc1, - 0x5c, 0x5c, 0xb8, 0xff, 0x86, 0x02, 0xb2, 0x87, 0x9e, 0xb2, 0x02, 0x92, 0xe4, 0x19, 0x28, 0x20, - 0x89, 0xb2, 0x14, 0xf8, 0x2e, 0x0f, 0x60, 0xba, 0xfd, 0x20, 0x07, 0x33, 0x5c, 0xcc, 0xf2, 0xa7, - 0x72, 0x89, 0x84, 0x17, 0xba, 0xba, 0x2f, 0x14, 0x57, 0xf0, 0xd4, 0x92, 0xd3, 0x76, 0x3b, 0x7a, - 0x92, 0x85, 0x4f, 0x9d, 0x66, 0xb8, 0x83, 0x62, 0x56, 0x90, 0x80, 0x92, 0xf4, 0xbe, 0x8f, 0x3b, - 0x3e, 0x51, 0xca, 0x8c, 0xbd, 0xe7, 0xf5, 0x41, 0xf2, 0xfa, 0x87, 0x3e, 0xb6, 0x39, 0xe5, 0x47, - 0xd1, 0x2d, 0xb3, 0x1b, 0x41, 0xa1, 0x38, 0xae, 0xf6, 0xfd, 0x70, 0x9d, 0x64, 0xbf, 0xfe, 0x7f, - 0xea, 0x74, 0x00, 0xe6, 0xd4, 0xf0, 0xfb, 0x37, 0x85, 0xba, 0xac, 0x58, 0xe6, 0x1a, 0x31, 0x2c, - 0x94, 0x40, 0xd6, 0x7e, 0xca, 0x81, 0xa5, 0xe1, 0x51, 0x33, 0x14, 0x72, 0xee, 0x4c, 0x21, 0x1f, - 0x03, 0x28, 0x13, 0xde, 0xec, 0x12, 0x0f, 0xb7, 0x89, 0x0c, 0x3c, 0x7f, 0xae, 0xc0, 0x57, 0x15, - 0x17, 0xdc, 0x4d, 0x21, 0xa2, 0x11, 0x2c, 0xda, 0xcf, 0xc9, 0x24, 0xa4, 0xda, 0xe7, 0x49, 0xe2, - 0x21, 0x58, 0x56, 0xd5, 0xb9, 0x80, 0x2c, 0xd6, 0x14, 0xd9, 0x72, 0x23, 0x0d, 0x89, 0x46, 0xf1, - 0x68, 0x3f, 0xe4, 0xc1, 0xe5, 0x51, 0x23, 0x19, 0x36, 0xd5, 0x1f, 0x1f, 0x99, 0xc5, 0xad, 0xf8, - 0x1f, 0x9f, 0x27, 0xbd, 0xea, 0x8b, 0xe3, 0xfe, 0xc1, 0x85, 0x13, 0x26, 0xf6, 0x2f, 0xe9, 0x63, - 0x50, 0x4e, 0x54, 0xf1, 0x23, 0x4e, 0x3b, 0xf4, 0x58, 0xbe, 0x80, 0xe4, 0xe3, 0xef, 0x85, 0x7e, - 0xaf, 0x5a, 0xde, 0xcd, 0xb0, 0x41, 0x99, 0xde, 0xb0, 0x3b, 0xb2, 0x0b, 0xce, 0xd7, 0xbe, 0x2b, - 0x13, 0x74, 0xc0, 0x8f, 0xe9, 0xca, 0xc9, 0x2e, 0xb8, 0xe0, 0xca, 0x7d, 0x0a, 0xae, 0x26, 0x85, - 0x4b, 0x97, 0xee, 0x5a, 0xbf, 0x57, 0xbd, 0xda, 0xc8, 0x32, 0x42, 0xd9, 0xfe, 0x59, 0xdd, 0x57, - 0x78, 0x36, 0xdd, 0x57, 0xbf, 0x71, 0x72, 0x5a, 0x99, 0x7a, 0x74, 0x5a, 0x99, 0xfa, 0xf5, 0xb4, - 0x32, 0xf5, 0x55, 0xbf, 0x92, 0x3b, 0xe9, 0x57, 0x72, 0x8f, 0xfa, 0x95, 0xdc, 0x6f, 0xfd, 0x4a, - 0xee, 0x9b, 0xc7, 0x95, 0xa9, 0x4f, 0x66, 0x07, 0x83, 0xf0, 0xef, 0x00, 0x00, 0x00, 0xff, 0xff, - 0x95, 0xf2, 0xec, 0x8a, 0x16, 0x12, 0x00, 0x00, + // 1196 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x57, 0x5b, 0x6f, 0x1b, 0xc5, + 0x17, 0x8f, 0x2f, 0x49, 0xf3, 0x9f, 0x4d, 0x93, 0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+ 0x8f, 0xc1, 0xb5, 0xb4, 0x70, 0xd9, 0xd2, 0x5d, 0x1f, 0xf4, 0x6b, 0xd7, 0x9a, 0x79, 0x46, 0x28, + 0xdf, 0x3f, 0xaf, 0xfb, 0x4a, 0xcf, 0xa6, 0xfb, 0x1a, 0x37, 0x8f, 0x4f, 0xaa, 0x53, 0x8f, 0x4e, + 0xaa, 0x53, 0xbf, 0x9c, 0x54, 0xa7, 0xbe, 0x1c, 0x54, 0x0b, 0xc7, 0x83, 0x6a, 0xe1, 0xd1, 0xa0, + 0x5a, 0xf8, 0x75, 0x50, 0x2d, 0x7c, 0xfd, 0xb8, 0x3a, 0xf5, 0xd1, 0xec, 0x70, 0x10, 0xfe, 0x15, + 0x00, 0x00, 0xff, 0xff, 0x08, 0xe1, 0xc3, 0x12, 0xe0, 0x11, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.proto index 5dffa59979f25..ec5bf3bf910ab 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.proto @@ -19,14 +19,13 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.autoscaling.v2alpha1; +package k8s.io.client_go.pkg.apis.autoscaling.v2alpha1; import "k8s.io/apimachinery/pkg/api/resource/generated.proto"; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; import "k8s.io/kubernetes/pkg/apis/autoscaling/v1/generated.proto"; diff --git a/staging/src/k8s.io/client-go/pkg/apis/batch/BUILD b/staging/src/k8s.io/client-go/pkg/apis/batch/BUILD index b896f3531ff23..f0ff3f2ce1f4a 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/batch/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/batch/BUILD @@ -16,10 +16,6 @@ go_library( "zz_generated.deepcopy.go", ], tags = ["automanaged"], - visibility = [ - "//vendor/k8s.io/client-go/pkg/api/v1:__pkg__", - "//vendor/k8s.io/client-go/pkg/apis:__subpackages__", - ], deps = [ "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/batch/install/BUILD b/staging/src/k8s.io/client-go/pkg/apis/batch/install/BUILD index 8e73fd8896de9..0902b80710a31 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/batch/install/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/batch/install/BUILD @@ -11,7 +11,6 @@ go_library( name = "go_default_library", srcs = ["install.go"], tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/batch/v1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/batch/v1/generated.pb.go index c5cf434dc07fe..b1e86d5bd58fe 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/batch/v1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/batch/v1/generated.pb.go @@ -1526,61 +1526,60 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 885 bytes of a gzipped FileDescriptorProto + // 870 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x54, 0xdd, 0x6e, 0xe3, 0x44, 0x14, 0xce, 0x4f, 0xd3, 0x26, 0x93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xde, 0xbd, 0xbd, 0xef, 0xd7, 0xee, 0xee, 0xfb, 0xb5, 0x3f, 0xef, 0xfb, + 0xb5, 0x9f, 0xd3, 0x7e, 0xfd, 0x36, 0xed, 0xd7, 0xef, 0xd2, 0x7e, 0xfd, 0xaf, 0xb4, 0x5f, 0xff, + 0xf5, 0xef, 0x7e, 0xed, 0xdb, 0xc6, 0x6c, 0xf4, 0x4f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3b, 0xa8, + 0x29, 0x00, 0xc1, 0x08, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/batch/v1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/batch/v1/generated.proto index fe946b2631983..45e17a70dd7fa 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/batch/v1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/batch/v1/generated.proto @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.batch.v1; +package k8s.io.client_go.pkg.apis.batch.v1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; // Package-wide variables from generator "generated". @@ -130,7 +129,7 @@ message JobSpec { // Describes the pod that will be created when executing a job. // More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ - optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 6; + optional k8s.io.client_go.pkg.api.v1.PodTemplateSpec template = 6; } // JobStatus represents the current state of a Job. diff --git a/staging/src/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.pb.go index c1f4305bb750a..e08f7bcae8b61 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.pb.go @@ -1457,55 +1457,54 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 799 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x94, 0x4d, 0x4f, 0xe3, 0x46, - 0x18, 0xc7, 0xe3, 0x90, 0x37, 0x26, 0xa5, 0x05, 0xb7, 0x82, 0x28, 0x95, 0x9c, 0x28, 0x52, 0xa5, - 0x14, 0x81, 0x5d, 0x42, 0x85, 0x68, 0x6f, 0x35, 0x55, 0xd5, 0x22, 0xfa, 0x22, 0x07, 0xd4, 0xaa, - 0x42, 0x15, 0x63, 0xe7, 0x49, 0x32, 0xc4, 0x6f, 0xf5, 0x8c, 0xa3, 0xe6, 0xd6, 0x8f, 0xd0, 0x6f, - 0xd1, 0x6f, 0xb1, 0x97, 0xdd, 0x03, 0x47, 0x0e, 0x7b, 0xd8, 0xbd, 0x44, 0x8b, 0xf7, 0x5b, 0xec, - 0x69, 0xe5, 0x89, 0x13, 0x07, 0x1c, 0x2f, 0x61, 0x57, 0xe2, 0xe6, 0x19, 0x3f, 0xff, 0xdf, 0x3c, - 0xcf, 0xf3, 0x7f, 0x66, 0xd0, 0x37, 0x83, 0x43, 0x2a, 0x13, 0x47, 0x19, 0xf8, 0x3a, 0x78, 0x36, - 0x30, 0xa0, 0x8a, 0x3b, 0xe8, 0x29, 0xd8, 0x25, 0x54, 0xd1, 0x31, 0x33, 0xfa, 0xca, 0xb0, 0x85, - 0x4d, 0xb7, 0x8f, 0xf7, 0x94, 0x1e, 0xd8, 0xe0, 0x61, 0x06, 0x1d, 0xd9, 0xf5, 0x1c, 0xe6, 0x88, - 0x5f, 0x4e, 0xa4, 0x72, 0x2c, 0x95, 0xdd, 0x41, 0x4f, 0x0e, 0xa5, 0x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 0xd1, 0x12, 0xe4, - 0xc6, 0x4b, 0x01, 0xcd, 0xfb, 0xf4, 0x08, 0x8f, 0x61, 0x1f, 0x95, 0xd8, 0x74, 0xd8, 0xb2, 0x1f, - 0x3c, 0x6c, 0xb3, 0x5b, 0x3b, 0x9b, 0xb4, 0x19, 0xbd, 0xf1, 0x54, 0x40, 0x9f, 0xdc, 0x89, 0x7f, - 0x84, 0xfa, 0x7e, 0xb9, 0xf5, 0xd8, 0xef, 0x2c, 0x51, 0x1b, 0xaf, 0x2a, 0xed, 0x89, 0x57, 0xb7, - 0xaf, 0x6e, 0xa4, 0xcc, 0xf5, 0x8d, 0x94, 0x79, 0x71, 0x23, 0x65, 0xfe, 0x0d, 0x24, 0xe1, 0x2a, - 0x90, 0x84, 0xeb, 0x40, 0x12, 0x5e, 0x05, 0x92, 0xf0, 0xdf, 0x6b, 0x29, 0xf3, 0x67, 0x69, 0xda, - 0x9d, 0xb7, 0x01, 0x00, 0x00, 0xff, 0xff, 0x32, 0x5e, 0xac, 0x56, 0xd9, 0x08, 0x00, 0x00, + // 783 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x94, 0x4d, 0x4f, 0xdb, 0x48, + 0x18, 0xc7, 0xe3, 0x90, 0x37, 0x26, 0xcb, 0x2e, 0x78, 0x57, 0x10, 0x65, 0x25, 0x27, 0x8a, 0xb4, + 0x52, 0x16, 0x81, 0xbd, 0x84, 0x15, 0x62, 0xf7, 0x56, 0x53, 0x55, 0x2d, 0xa2, 0x2f, 0x72, 0x40, + 0xad, 0x2a, 0x54, 0x31, 0x9e, 0x4c, 0x92, 0x21, 0x7e, 0xab, 0x67, 0x1c, 0x29, 0xb7, 0x7e, 0x84, + 0x7e, 0x8b, 0x7e, 0x8b, 0x5e, 0xda, 0x03, 0x47, 0x0e, 0x3d, 0xb4, 0x97, 0xa8, 0xb8, 0xdf, 0xa2, + 0xa7, 0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, 0xc8, 0x60, 0x49, 0xa8, 0x0a, 0xf5, 0x62, 0xe3, + 0x1f, 0x39, 0xec, 0xd7, 0x74, 0xda, 0x51, 0xc7, 0x82, 0x68, 0xb9, 0xbf, 0x25, 0x3f, 0xd6, 0x4f, + 0x31, 0x62, 0x0f, 0x31, 0x83, 0xaa, 0x78, 0x36, 0xac, 0xa4, 0xfc, 0x61, 0x05, 0x44, 0x7b, 0xda, + 0x84, 0x2a, 0x3e, 0x03, 0x19, 0xea, 0x60, 0x54, 0x4a, 0x73, 0xfa, 0x8e, 0x3c, 0xf7, 0x34, 0xc8, + 0x61, 0x8e, 0x4d, 0x07, 0x23, 0xf5, 0x97, 0xf0, 0x8c, 0x4c, 0xb0, 0xd2, 0x38, 0x51, 0x3c, 0x01, + 0x39, 0xca, 0x20, 0xf3, 0x68, 0x69, 0x81, 0xb3, 0x77, 0x7f, 0x80, 0xcd, 0xf5, 0xea, 0xaf, 0x21, + 0x3d, 0x37, 0x5a, 0x6b, 0x21, 0xb7, 0xf6, 0x5e, 0x00, 0xc5, 0x30, 0xf2, 0x80, 0x50, 0x26, 0x1e, + 0xc7, 0xdc, 0x92, 0xe7, 0x73, 0x2b, 0x50, 0x73, 0xaf, 0x96, 0xc3, 0x93, 0x0a, 0xe3, 0x9d, 0x29, + 0xa7, 0x9e, 0x82, 0x2c, 0x61, 0xd8, 0xa4, 0xa5, 0x74, 0x75, 0xa1, 0x5e, 0x6c, 0x34, 0x6e, 0x5e, + 0x8e, 0xba, 0x14, 0xe2, 0xb3, 0x0f, 0x02, 0x90, 0x36, 0xe2, 0xd5, 0xde, 0x66, 0x26, 0x65, 0x04, + 0xf6, 0x89, 0x1b, 0xa0, 0x10, 0x8c, 0x6c, 0xcb, 0x33, 0x30, 0x2f, 0x63, 0x31, 0x4a, 0xab, 0x19, + 0xee, 0x6b, 0x93, 0x08, 0xf1, 0x08, 0xac, 0x51, 0x06, 0x5d, 0x46, 0xac, 0xce, 0x5d, 0x0c, 0x5b, + 0x06, 0xb1, 0x70, 0x13, 0x23, 0xdb, 0x6a, 0x51, 0xde, 0xd3, 0x05, 0xf5, 0x4f, 0x7f, 0x58, 0x59, + 0x6b, 0xce, 0x0e, 0xd1, 0x92, 0xb4, 0xe2, 0x31, 0x58, 0x41, 0xb6, 0x85, 0x3c, 0xd7, 0xc5, 0x16, + 0x1a, 0x3c, 0xb1, 0x0d, 0x82, 0x06, 0xbc, 0x91, 0x8b, 0xaa, 0x1c, 0x66, 0xb3, 0xb2, 0x77, 0x35, + 0xe0, 0xeb, 0xac, 0x4d, 0x2d, 0x0e, 0x12, 0xff, 0x02, 0x79, 0xea, 0x51, 0x07, 0x5b, 0xad, 0x52, + 0xa6, 0x2a, 0xd4, 0x0b, 0x6a, 0xd1, 0x1f, 0x56, 0xf2, 0xcd, 0xd1, 0x96, 0x36, 0xfe, 0x27, 0xbe, + 0x04, 0xc5, 0x53, 0x5b, 0x3f, 0xc4, 0xa6, 0x63, 0x40, 0x86, 0x4b, 0x59, 0xde, 0xd3, 0xff, 0x6f, + 0x60, 0xfc, 0x7e, 0xa4, 0xe6, 0x73, 0xfa, 0x7b, 0x98, 0x7a, 0x71, 0xea, 0x87, 0x36, 0x7d, 0x86, + 0xf8, 0x02, 0x94, 0xa9, 0x87, 0x10, 0xa6, 0xb4, 0xed, 0x19, 0xfb, 0xb6, 0x4e, 0xef, 0x13, 0xca, + 0x6c, 0x77, 0x70, 0x40, 0x4c, 0xc2, 0x4a, 0xb9, 0xaa, 0x50, 0xcf, 0xaa, 0x92, 0x3f, 0xac, 0x94, + 0x9b, 0x89, 0x51, 0xda, 0x77, 0x08, 0xa2, 0x06, 0x56, 0xdb, 0x90, 0x18, 0xb8, 0x15, 0x63, 0xe7, + 0x39, 0xbb, 0xec, 0x0f, 0x2b, 0xab, 0xf7, 0x66, 0x46, 0x68, 0x09, 0xca, 0xda, 0x07, 0x01, 0x2c, + 0x5d, 0xba, 0x31, 0xe2, 0x11, 0xc8, 0x41, 0xc4, 0x48, 0x3f, 0x18, 0xa0, 0x60, 0x58, 0x37, 0x93, + 0x3d, 0x8b, 0x5e, 0x0b, 0x0d, 0xb7, 0x71, 0xd0, 0x24, 0x1c, 0x5d, 0xb8, 0x3b, 0x1c, 0xa2, 0x85, + 0x30, 0xd1, 0x00, 0xcb, 0x06, 0xa4, 0x6c, 0x3c, 0x85, 0x87, 0xc4, 0xc4, 0xbc, 0x7f, 0xc5, 0xc6, + 0xfa, 0x7c, 0x17, 0x2d, 0x50, 0xa8, 0x7f, 0xf8, 0xc3, 0xca, 0xf2, 0xc1, 0x15, 0x8e, 0x16, 0x23, + 0xd7, 0x3e, 0x09, 0x60, 0xba, 0x4f, 0xb7, 0xf0, 0x18, 0x76, 0x41, 0x81, 0x8d, 0x87, 0x2d, 0xfd, + 0xd3, 0xc3, 0x36, 0xb9, 0xb5, 0x93, 0x49, 0x9b, 0xd0, 0x6b, 0xef, 0x04, 0xf0, 0xdb, 0x95, 0xf8, + 0x5b, 0xa8, 0xef, 0xd1, 0xa5, 0xc7, 0x7e, 0x63, 0x8e, 0xda, 0x78, 0x55, 0x49, 0x4f, 0xbc, 0xba, + 0x7e, 0x76, 0x21, 0xa5, 0xce, 0x2f, 0xa4, 0xd4, 0xc7, 0x0b, 0x29, 0xf5, 0xca, 0x97, 0x84, 0x33, + 0x5f, 0x12, 0xce, 0x7d, 0x49, 0xf8, 0xec, 0x4b, 0xc2, 0xeb, 0x2f, 0x52, 0xea, 0x79, 0x61, 0xec, + 0xce, 0xb7, 0x00, 0x00, 0x00, 0xff, 0xff, 0x09, 0x9b, 0x4c, 0x2b, 0xa3, 0x08, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.proto index a5230d9c0e161..d4aaf1f186fce 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.proto @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.batch.v2alpha1; +package k8s.io.client_go.pkg.apis.batch.v2alpha1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; import "k8s.io/kubernetes/pkg/apis/batch/v1/generated.proto"; @@ -99,7 +98,7 @@ message CronJobSpec { message CronJobStatus { // A list of pointers to currently running jobs. // +optional - repeated k8s.io.kubernetes.pkg.api.v1.ObjectReference active = 1; + repeated k8s.io.client_go.pkg.api.v1.ObjectReference active = 1; // Information when was the last time the job was successfully scheduled. // +optional @@ -129,6 +128,6 @@ message JobTemplateSpec { // Specification of the desired behavior of the job. // More info: https://github.com/kubernetes/community/blob/master/contributors/devel/api-conventions.md#spec-and-status // +optional - optional k8s.io.kubernetes.pkg.apis.batch.v1.JobSpec spec = 2; + optional k8s.io.client_go.pkg.apis.batch.v1.JobSpec spec = 2; } diff --git a/staging/src/k8s.io/client-go/pkg/apis/certificates/BUILD b/staging/src/k8s.io/client-go/pkg/apis/certificates/BUILD index ce702b72221e0..0e128d1a316ce 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/certificates/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/certificates/BUILD @@ -17,10 +17,6 @@ go_library( "zz_generated.deepcopy.go", ], tags = ["automanaged"], - visibility = [ - "//vendor/k8s.io/client-go/pkg/api/v1:__pkg__", - "//vendor/k8s.io/client-go/pkg/apis:__subpackages__", - ], deps = [ "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/certificates/install/BUILD b/staging/src/k8s.io/client-go/pkg/apis/certificates/install/BUILD index d228bd90e6ca1..97eb19640a835 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/certificates/install/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/certificates/install/BUILD @@ -11,7 +11,6 @@ go_library( name = "go_default_library", srcs = ["install.go"], tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.pb.go index b0336e5f36616..2d628659d3e59 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.pb.go @@ -1632,58 +1632,56 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 833 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0xcf, 0x8f, 0xdb, 0x44, - 0x14, 0x8e, 0xf3, 0x6b, 0x93, 0xc9, 0xb2, 0xad, 0x46, 0xa8, 0x32, 0x2b, 0xd5, 0x5e, 0x59, 0x80, - 0xb6, 0x08, 0x6c, 0xb2, 0x20, 0x58, 0x95, 0x03, 0x92, 0x4b, 0x85, 0x0a, 0x2d, 0x3f, 0x66, 0x1b, - 0x24, 0x10, 0x07, 0x26, 0xce, 0xab, 0x77, 0x9a, 0xf8, 0x07, 0x9e, 0x71, 0xb4, 0xb9, 0xa0, 0xde, - 0xb8, 0x72, 0xe4, 0x82, 0xc4, 0x9f, 0xb3, 0xc7, 0x1e, 0x39, 0xa0, 0x88, 0x0d, 0x27, 0x2e, 0xfc, - 0x01, 0x3d, 0xa1, 0x19, 0x4f, 0x62, 0x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- 0x3b, 0xba, 0xb3, 0x7f, 0x02, 0x00, 0x00, 0xff, 0xff, 0xc5, 0x92, 0xb9, 0x6f, 0x52, 0x08, 0x00, - 0x00, + // 815 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0xcd, 0x8f, 0x1b, 0x35, + 0x14, 0xcf, 0xe4, 0x3b, 0xce, 0xb2, 0xad, 0x2c, 0x54, 0x0d, 0x91, 0x3a, 0x13, 0x8d, 0x00, 0x6d, + 0x11, 0xcc, 0x90, 0x05, 0xc1, 0xaa, 0x1c, 0x90, 0xa6, 0x54, 0xa8, 0xd0, 0xf2, 0xe1, 0x6d, 0x90, + 0x40, 0x1c, 0x70, 0x26, 0xaf, 0xb3, 0x6e, 0x76, 0x3e, 0x18, 0x7b, 0xa2, 0xe6, 0x82, 0x7a, 0xe3, + 0xca, 0x91, 0x0b, 0x12, 0x7f, 0xce, 0x1e, 0x7b, 0xe4, 0x80, 0x22, 0x36, 0x9c, 0xb8, 0xf0, 0x07, + 0xf4, 0x84, 0xec, 0x71, 0x32, 0x21, 0x51, 0xfa, 0x21, 0xe5, 0x66, 0xff, 0xfc, 0xde, 0xef, 0xf7, + 0xde, 0xcf, 0xcf, 0x46, 0x1f, 0x4f, 0x4e, 0xb8, 0xcb, 0x12, 0x6f, 0x92, 0x8f, 0x20, 0x8b, 0x41, + 0x00, 0xf7, 0xd2, 0x49, 0xe8, 0xd1, 0x94, 0x71, 0x2f, 0x80, 0x4c, 0xb0, 0x07, 0x2c, 0xa0, 0x12, + 0x9d, 0x0e, 0x46, 0x20, 0xe8, 0xc0, 0x0b, 0x21, 0x86, 0x8c, 0x0a, 0x18, 0xbb, 0x69, 0x96, 0x88, + 0x04, 0x7b, 0x05, 0x81, 0x5b, 0x12, 0xb8, 0xe9, 0x24, 0x74, 0x25, 0x81, 0xbb, 0x4e, 0xe0, 0x6a, + 0x82, 0xde, 0x3b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x67, 0xd0, 0xea, 0xb3, 0x28, 0x7f, 0xe3, 0x15, 0xc4, 0xc9, + 0x9a, 0x34, 0x1e, 0xa0, 0xee, 0x1a, 0xb5, 0xb2, 0xe2, 0xc0, 0xbf, 0xb2, 0x98, 0xdb, 0xdd, 0x35, + 0x72, 0xb2, 0x1e, 0xe3, 0x7c, 0xa8, 0x7d, 0x55, 0x9d, 0x63, 0x7b, 0xf9, 0x88, 0x0c, 0x35, 0x16, + 0x9d, 0xcd, 0xa1, 0xbf, 0xd9, 0xfe, 0xf5, 0x77, 0xbb, 0xf2, 0xf8, 0xcf, 0x7e, 0xc5, 0xbf, 0x71, + 0x71, 0x69, 0x55, 0x9e, 0x5c, 0x5a, 0x95, 0x3f, 0x2e, 0xad, 0xca, 0xe3, 0x85, 0x65, 0x5c, 0x2c, + 0x2c, 0xe3, 0xc9, 0xc2, 0x32, 0xfe, 0x5a, 0x58, 0xc6, 0x2f, 0x7f, 0x5b, 0x95, 0xef, 0x5a, 0xba, + 0xb3, 0xff, 0x02, 0x00, 0x00, 0xff, 0xff, 0x5b, 0xd3, 0xf0, 0x05, 0x1c, 0x08, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.proto index 6d58d71614110..e62bd5724d670 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.proto @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.certificates.v1beta1; +package k8s.io.client_go.pkg.apis.certificates.v1beta1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; diff --git a/staging/src/k8s.io/client-go/pkg/apis/extensions/BUILD b/staging/src/k8s.io/client-go/pkg/apis/extensions/BUILD index e64293306e436..529181ac2409b 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/extensions/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/extensions/BUILD @@ -17,10 +17,6 @@ go_library( "zz_generated.deepcopy.go", ], tags = ["automanaged"], - visibility = [ - "//vendor/k8s.io/client-go/pkg/api/v1:__pkg__", - "//vendor/k8s.io/client-go/pkg/apis:__subpackages__", - ], deps = [ "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/extensions/install/BUILD b/staging/src/k8s.io/client-go/pkg/apis/extensions/install/BUILD index edc6657600e1e..bc197170be34d 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/extensions/install/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/extensions/install/BUILD @@ -11,7 +11,6 @@ go_library( name = "go_default_library", srcs = ["install.go"], tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/extensions/types.go b/staging/src/k8s.io/client-go/pkg/apis/extensions/types.go index 8cfbb3c7849fd..3b86ce7ccc641 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/extensions/types.go +++ b/staging/src/k8s.io/client-go/pkg/apis/extensions/types.go @@ -235,7 +235,7 @@ type DeploymentRollback struct { } type RollbackConfig struct { - // The revision to rollback to. If set to 0, rollbck to the last revision. + // The revision to rollback to. If set to 0, rollback to the last revision. // +optional Revision int64 } @@ -884,6 +884,10 @@ type PodSecurityPolicySpec struct { // will not be forced to. // +optional ReadOnlyRootFilesystem bool + // AllowedHostPaths is a white list of allowed host path prefixes. Empty indicates that all + // host paths may be used. + // +optional + AllowedHostPaths []string } // HostPortRange defines a range of host ports that will be enabled by a policy @@ -1042,6 +1046,7 @@ type PodSecurityPolicyList struct { // +genclient=true +// NetworkPolicy describes what network traffic is allowed for a set of Pods type NetworkPolicy struct { metav1.TypeMeta // +optional @@ -1061,13 +1066,12 @@ type NetworkPolicySpec struct { PodSelector metav1.LabelSelector // List of ingress rules to be applied to the selected pods. - // Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, + // Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod // OR if the traffic source is the pod's local node, // OR if the traffic matches at least one ingress rule across all of the NetworkPolicy // objects whose podSelector matches the pod. - // If this field is empty then this NetworkPolicy does not affect ingress isolation. - // If this field is present and contains at least one rule, this policy allows any traffic - // which matches at least one of the ingress rules in this list. + // If this field is empty then this NetworkPolicy does not allow any traffic + // (and serves solely to ensure that the pods it selects are isolated by default). // +optional Ingress []NetworkPolicyIngressRule } diff --git a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/BUILD b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/BUILD index 4e6dabbff244c..078937352b55e 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/BUILD @@ -37,5 +37,6 @@ go_library( "//vendor/k8s.io/client-go/pkg/api:go_default_library", "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", "//vendor/k8s.io/client-go/pkg/apis/extensions:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/networking:go_default_library", ], ) diff --git a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/conversion.go b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/conversion.go index d53dbc47ae6ba..cec1e5e4354f6 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/conversion.go +++ b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/conversion.go @@ -23,8 +23,10 @@ import ( "k8s.io/apimachinery/pkg/conversion" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/util/intstr" + "k8s.io/client-go/pkg/api" v1 "k8s.io/client-go/pkg/api/v1" "k8s.io/client-go/pkg/apis/extensions" + "k8s.io/client-go/pkg/apis/networking" ) func addConversionFuncs(scheme *runtime.Scheme) error { @@ -42,6 +44,18 @@ func addConversionFuncs(scheme *runtime.Scheme) error { Convert_v1beta1_RollingUpdateDaemonSet_To_extensions_RollingUpdateDaemonSet, Convert_extensions_ReplicaSetSpec_To_v1beta1_ReplicaSetSpec, Convert_v1beta1_ReplicaSetSpec_To_extensions_ReplicaSetSpec, + Convert_v1beta1_NetworkPolicy_To_networking_NetworkPolicy, + Convert_networking_NetworkPolicy_To_v1beta1_NetworkPolicy, + Convert_v1beta1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule, + Convert_networking_NetworkPolicyIngressRule_To_v1beta1_NetworkPolicyIngressRule, + Convert_v1beta1_NetworkPolicyList_To_networking_NetworkPolicyList, + Convert_networking_NetworkPolicyList_To_v1beta1_NetworkPolicyList, + Convert_v1beta1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer, + Convert_networking_NetworkPolicyPeer_To_v1beta1_NetworkPolicyPeer, + Convert_v1beta1_NetworkPolicyPort_To_networking_NetworkPolicyPort, + Convert_networking_NetworkPolicyPort_To_v1beta1_NetworkPolicyPort, + Convert_v1beta1_NetworkPolicySpec_To_networking_NetworkPolicySpec, + Convert_networking_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec, ) if err != nil { return err @@ -260,3 +274,155 @@ func Convert_v1beta1_ReplicaSetSpec_To_extensions_ReplicaSetSpec(in *ReplicaSetS } return nil } + +func Convert_v1beta1_NetworkPolicy_To_networking_NetworkPolicy(in *NetworkPolicy, out *networking.NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + return Convert_v1beta1_NetworkPolicySpec_To_networking_NetworkPolicySpec(&in.Spec, &out.Spec, s) +} + +func Convert_networking_NetworkPolicy_To_v1beta1_NetworkPolicy(in *networking.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + return Convert_networking_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec(&in.Spec, &out.Spec, s) +} + +func Convert_v1beta1_NetworkPolicySpec_To_networking_NetworkPolicySpec(in *NetworkPolicySpec, out *networking.NetworkPolicySpec, s conversion.Scope) error { + if err := s.Convert(&in.PodSelector, &out.PodSelector, 0); err != nil { + return err + } + out.Ingress = make([]networking.NetworkPolicyIngressRule, len(in.Ingress)) + for i := range in.Ingress { + if err := Convert_v1beta1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(&in.Ingress[i], &out.Ingress[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_networking_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec(in *networking.NetworkPolicySpec, out *NetworkPolicySpec, s conversion.Scope) error { + if err := s.Convert(&in.PodSelector, &out.PodSelector, 0); err != nil { + return err + } + out.Ingress = make([]NetworkPolicyIngressRule, len(in.Ingress)) + for i := range in.Ingress { + if err := Convert_networking_NetworkPolicyIngressRule_To_v1beta1_NetworkPolicyIngressRule(&in.Ingress[i], &out.Ingress[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_v1beta1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(in *NetworkPolicyIngressRule, out *networking.NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = make([]networking.NetworkPolicyPort, len(in.Ports)) + for i := range in.Ports { + if err := Convert_v1beta1_NetworkPolicyPort_To_networking_NetworkPolicyPort(&in.Ports[i], &out.Ports[i], s); err != nil { + return err + } + } + out.From = make([]networking.NetworkPolicyPeer, len(in.From)) + for i := range in.From { + if err := Convert_v1beta1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(&in.From[i], &out.From[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_networking_NetworkPolicyIngressRule_To_v1beta1_NetworkPolicyIngressRule(in *networking.NetworkPolicyIngressRule, out *NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = make([]NetworkPolicyPort, len(in.Ports)) + for i := range in.Ports { + if err := Convert_networking_NetworkPolicyPort_To_v1beta1_NetworkPolicyPort(&in.Ports[i], &out.Ports[i], s); err != nil { + return err + } + } + out.From = make([]NetworkPolicyPeer, len(in.From)) + for i := range in.From { + if err := Convert_networking_NetworkPolicyPeer_To_v1beta1_NetworkPolicyPeer(&in.From[i], &out.From[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_v1beta1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(in *NetworkPolicyPeer, out *networking.NetworkPolicyPeer, s conversion.Scope) error { + if in.PodSelector != nil { + out.PodSelector = new(metav1.LabelSelector) + if err := s.Convert(in.PodSelector, out.PodSelector, 0); err != nil { + return err + } + } else { + out.PodSelector = nil + } + if in.NamespaceSelector != nil { + out.NamespaceSelector = new(metav1.LabelSelector) + if err := s.Convert(in.NamespaceSelector, out.NamespaceSelector, 0); err != nil { + return err + } + } else { + out.NamespaceSelector = nil + } + return nil +} + +func Convert_networking_NetworkPolicyPeer_To_v1beta1_NetworkPolicyPeer(in *networking.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { + if in.PodSelector != nil { + out.PodSelector = new(metav1.LabelSelector) + if err := s.Convert(in.PodSelector, out.PodSelector, 0); err != nil { + return err + } + } else { + out.PodSelector = nil + } + if in.NamespaceSelector != nil { + out.NamespaceSelector = new(metav1.LabelSelector) + if err := s.Convert(in.NamespaceSelector, out.NamespaceSelector, 0); err != nil { + return err + } + } else { + out.NamespaceSelector = nil + } + return nil +} + +func Convert_v1beta1_NetworkPolicyPort_To_networking_NetworkPolicyPort(in *NetworkPolicyPort, out *networking.NetworkPolicyPort, s conversion.Scope) error { + if in.Protocol != nil { + out.Protocol = new(api.Protocol) + *out.Protocol = api.Protocol(*in.Protocol) + } else { + out.Protocol = nil + } + out.Port = in.Port + return nil +} + +func Convert_networking_NetworkPolicyPort_To_v1beta1_NetworkPolicyPort(in *networking.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { + if in.Protocol != nil { + out.Protocol = new(v1.Protocol) + *out.Protocol = v1.Protocol(*in.Protocol) + } else { + out.Protocol = nil + } + out.Port = in.Port + return nil +} + +func Convert_v1beta1_NetworkPolicyList_To_networking_NetworkPolicyList(in *NetworkPolicyList, out *networking.NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = make([]networking.NetworkPolicy, len(in.Items)) + for i := range in.Items { + if err := Convert_v1beta1_NetworkPolicy_To_networking_NetworkPolicy(&in.Items[i], &out.Items[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_networking_NetworkPolicyList_To_v1beta1_NetworkPolicyList(in *networking.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = make([]NetworkPolicy, len(in.Items)) + for i := range in.Items { + if err := Convert_networking_NetworkPolicy_To_v1beta1_NetworkPolicy(&in.Items[i], &out.Items[i], s); err != nil { + return err + } + } + return nil +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.pb.go index d8a4effd128cf..4152966113a63 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.pb.go @@ -93,7 +93,6 @@ import math "math" import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" import k8s_io_apimachinery_pkg_util_intstr "k8s.io/apimachinery/pkg/util/intstr" - import k8s_io_kubernetes_pkg_api_v1 "k8s.io/client-go/pkg/api/v1" import strings "strings" @@ -1989,6 +1988,21 @@ func (m *PodSecurityPolicySpec) MarshalTo(dAtA []byte) (int, error) { dAtA[i] = 0 } i++ + if len(m.AllowedHostPaths) > 0 { + for _, s := range m.AllowedHostPaths { + dAtA[i] = 0x7a + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } return i, nil } @@ -3240,6 +3254,12 @@ func (m *PodSecurityPolicySpec) Size() (n int) { l = m.FSGroup.Size() n += 1 + l + sovGenerated(uint64(l)) n += 2 + if len(m.AllowedHostPaths) > 0 { + for _, s := range m.AllowedHostPaths { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } return n } @@ -3972,6 +3992,7 @@ func (this *PodSecurityPolicySpec) String() string { `SupplementalGroups:` + strings.Replace(strings.Replace(this.SupplementalGroups.String(), "SupplementalGroupsStrategyOptions", "SupplementalGroupsStrategyOptions", 1), `&`, ``, 1) + `,`, `FSGroup:` + strings.Replace(strings.Replace(this.FSGroup.String(), "FSGroupStrategyOptions", "FSGroupStrategyOptions", 1), `&`, ``, 1) + `,`, `ReadOnlyRootFilesystem:` + fmt.Sprintf("%v", this.ReadOnlyRootFilesystem) + `,`, + `AllowedHostPaths:` + fmt.Sprintf("%v", this.AllowedHostPaths) + `,`, `}`, }, "") return s @@ -9371,6 +9392,35 @@ func (m *PodSecurityPolicySpec) Unmarshal(dAtA []byte) error { } } m.ReadOnlyRootFilesystem = bool(v != 0) + case 15: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field AllowedHostPaths", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.AllowedHostPaths = append(m.AllowedHostPaths, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -11823,218 +11873,219 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 3402 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x5b, 0x4b, 0x6f, 0x1c, 0xc7, - 0xb5, 0x56, 0xcf, 0x43, 0x1c, 0x1e, 0x8a, 0xa4, 0x58, 0x94, 0xa9, 0x31, 0x6d, 0x93, 0x72, 0x5f, - 0x5c, 0x5b, 0xbe, 0xd7, 0x1e, 0x5e, 0xcb, 0x57, 0x8e, 0x2d, 0xdb, 0xb2, 0x39, 0xa4, 0x1e, 0x0c, - 0x48, 0x6a, 0x5c, 0x33, 0x14, 0x62, 0xf9, 0x95, 0xe6, 0x4c, 0x71, 0xd8, 0x52, 0xbf, 0xdc, 0x5d, - 0x4d, 0x73, 0x60, 0x24, 0x31, 0x10, 0xc4, 0xcb, 0x20, 0xd9, 0x04, 0x0e, 0x90, 0x2c, 0xb3, 0xc8, - 0x26, 0xb1, 0x17, 0x89, 0x93, 0x5f, 0x10, 0x2d, 0x82, 0xc0, 0x01, 0x12, 0xc0, 0x08, 0x1c, 0x22, - 0xa2, 0x11, 0xff, 0x81, 0xc4, 0x1b, 0xad, 0x82, 0xaa, 0xae, 0x7e, 0x77, 0x53, 0x9a, 0xa1, 0x34, - 0x08, 0x90, 0x1d, 0xa7, 0xea, 0x9c, 0xef, 0x3c, 0xea, 0xd4, 0xa9, 0x53, 0x75, 0x9a, 0xf0, 0xd2, - 0x8d, 0xe7, 0x9c, 0x9a, 0x6a, 0x2e, 0xdc, 0x70, 0x37, 0x89, 0x6d, 0x10, 0x4a, 0x9c, 0x05, 0xeb, - 0x46, 0x77, 0x41, 0xb1, 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0xe7, 0xb7, 0x84, - 0xc9, 0x61, 0x0d, 0xc6, 0x7e, 0x39, 0xd8, 0xc3, 0x96, 0xd7, 0x60, 0xfc, 0xb2, 0xe9, 0xd0, 0x86, - 0x69, 0x53, 0xee, 0x36, 0xf4, 0x08, 0x14, 0x75, 0xd5, 0x10, 0x27, 0xfc, 0x98, 0xe0, 0x29, 0xb2, - 0x33, 0x88, 0x8d, 0xf3, 0x69, 0x65, 0x57, 0x64, 0xb2, 0x70, 0x5a, 0xd9, 0xc5, 0x6c, 0x5c, 0xbe, - 0x04, 0x23, 0x62, 0x39, 0xa2, 0x40, 0xc5, 0x83, 0x81, 0x8a, 0x19, 0x40, 0xbf, 0x2c, 0xc0, 0x88, - 0xd0, 0x7e, 0x08, 0x17, 0xc1, 0x37, 0x62, 0x17, 0xc1, 0x73, 0x83, 0xad, 0x74, 0xee, 0x2d, 0xb0, - 0x93, 0xb8, 0x05, 0xbe, 0x38, 0x20, 0xfe, 0xc1, 0x57, 0xc0, 0x8f, 0x24, 0x98, 0x88, 0xc7, 0x1c, - 0x3a, 0x0b, 0x63, 0xec, 0x3c, 0x52, 0xdb, 0x64, 0x3d, 0x2c, 0xa8, 0x83, 0x47, 0x99, 0x66, 0x38, - 0x85, 0xa3, 0x74, 0xa8, 0x1b, 0xb0, 0xb1, 0xb0, 0x10, 0x4e, 0xc9, 0x77, 0xb9, 0x4b, 0x55, 0xad, - 0xe6, 0xb5, 0x89, 0x6a, 0x2b, 0x06, 0xbd, 0x62, 0x37, 0xa9, 0xad, 0x1a, 0xdd, 0x94, 0x20, 0x1e, - 0x63, 0x51, 0x64, 0xf9, 0xa6, 0x04, 0x63, 0x42, 0xe5, 0x21, 0x5c, 0x67, 0x5e, 0x8f, 0x5f, 0x67, - 0x9e, 0x1d, 0x70, 0x3f, 0x67, 0xdf, 0x65, 0x3e, 0x09, 0x4d, 0x61, 0x3b, 0x98, 0x25, 0x98, 0x6d, - 0xd3, 0xa1, 0xc9, 0x04, 0xc3, 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x67, 0x61, 0xac, 0x43, 0x9c, 0xb6, 0xad, - 0x72, 0x67, 0x89, 0xbb, 0x42, 0xf0, 0x0e, 0xb2, 0x1c, 0x4e, 0xe1, 0x28, 0x1d, 0xea, 0x42, 0x65, - 0xc7, 0xfb, 0x2f, 0x3f, 0xbf, 0xf3, 0xd6, 0x6f, 0x31, 0x1b, 0xfe, 0x9f, 0x60, 0x18, 0x5f, 0x62, - 0xc0, 0xc1, 0x01, 0xb8, 0xfc, 0xa1, 0x04, 0x33, 0x69, 0xc7, 0x2c, 0x33, 0xd5, 0xef, 0xbf, 0x73, - 0x1e, 0x86, 0x12, 0x47, 0x67, 0x5e, 0x39, 0xe6, 0xbd, 0x78, 0x33, 0xc9, 0x98, 0x8f, 0xca, 0x5f, - 0x4a, 0x30, 0x9b, 0xad, 0xda, 0x10, 0xae, 0x12, 0xd7, 0xe3, 0x57, 0x89, 0x7e, 0x9f, 0x0d, 0xb2, - 0xf5, 0xce, 0xb9, 0x56, 0xec, 0x65, 0xae, 0xc1, 0x10, 0x8c, 0xdc, 0x8a, 0x1b, 0xb9, 0x78, 0x68, - 0x23, 0xb3, 0x0d, 0xac, 0x3f, 0x71, 0xf3, 0xd6, 0xdc, 0x91, 0x4f, 0x6f, 0xcd, 0x1d, 0xf9, 0xec, - 0xd6, 0xdc, 0x91, 0xf7, 0xf7, 0xe7, 0xa4, 0x9b, 0xfb, 0x73, 0xd2, 0xa7, 0xfb, 0x73, 0xd2, 0xdf, - 0xf6, 0xe7, 0xa4, 0x1f, 0x7c, 0x31, 0x77, 0xe4, 0xda, 0x88, 0xc0, 0xfc, 0x57, 0x00, 0x00, 0x00, - 0xff, 0xff, 0x5a, 0xe3, 0x5a, 0x1b, 0x28, 0x3d, 0x00, 0x00, + // 3412 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x5b, 0xdd, 0x6f, 0x1c, 0x57, + 0x15, 0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15, 0x8b, 0x5e, 0xf4, 0x18, 0x8c, 0xe8, 0xc4, + 0x71, 0x94, 0x0e, 0xe1, 0x19, 0x61, 0xb4, 0x36, 0x21, 0x08, 0x47, 0xd6, 0xbc, 0x66, 0xec, 0xf7, + 0xa3, 0x6b, 0x30, 0xae, 0x29, 0x8e, 0x08, 0xed, 0xa6, 0xaa, 0x13, 0x3e, 0xe7, 0xcb, 0xa7, 0xbf, + 0x72, 0x67, 0x11, 0xc3, 0x38, 0xc2, 0x95, 0x68, 0x35, 0x86, 0x84, 0x13, 0xc8, 0x68, 0x07, 0x10, + 0x6b, 0x69, 0xda, 0x8a, 0xe1, 0x78, 0x2e, 0x63, 0xf2, 0x46, 0x7a, 0x96, 0x17, 0xe4, 0xb7, 0xd5, + 0x14, 0x1a, 0xce, 0x90, 0x20, 0xff, 0x59, 0x82, 0xf1, 0x70, 0xc0, 0x06, 0x50, 0x28, 0xbd, 0x11, + 0x2f, 0x94, 0x9e, 0xed, 0x3b, 0x78, 0x73, 0x2a, 0xa5, 0xf7, 0x0b, 0x80, 0x42, 0x22, 0x96, 0x1a, + 0x36, 0x95, 0xd6, 0xf5, 0x3b, 0xd8, 0x47, 0xfc, 0x52, 0x02, 0x24, 0x92, 0xf5, 0xa2, 0x61, 0x98, + 0x94, 0xe7, 0x7f, 0x5f, 0xcd, 0x57, 0xfa, 0x56, 0xd3, 0xd7, 0xa0, 0xba, 0x91, 0xc2, 0x3e, 0x6f, + 0x50, 0xbb, 0x1b, 0x8e, 0x58, 0x9a, 0x00, 0x67, 0x28, 0x84, 0xde, 0x02, 0xb0, 0x05, 0x66, 0xd3, + 0x14, 0x29, 0xe0, 0x85, 0x3e, 0xb2, 0x29, 0x03, 0x58, 0x32, 0x8d, 0x2d, 0xb5, 0x13, 0x26, 0x34, + 0x1c, 0x00, 0xe3, 0x88, 0x90, 0xd9, 0xf3, 0x70, 0x22, 0x47, 0x7b, 0x74, 0x1c, 0x0a, 0xd7, 0x49, + 0xd7, 0x73,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 0x86, + 0x6d, 0x57, 0xf3, 0xed, 0xfa, 0x92, 0x6f, 0x17, 0x76, 0x35, 0x66, 0xd7, 0x54, 0x82, 0xcb, 0x33, + 0x8a, 0x31, 0xa0, 0x37, 0xe0, 0xa8, 0xad, 0x18, 0x1d, 0xe2, 0x2f, 0xe0, 0x4f, 0xf7, 0x68, 0xcd, + 0xca, 0x32, 0x66, 0xec, 0x91, 0x32, 0x92, 0xa3, 0x61, 0x81, 0x2a, 0xff, 0x42, 0x82, 0x89, 0x4b, + 0xcd, 0x66, 0x7d, 0xc5, 0xe0, 0x19, 0xa0, 0xae, 0xd0, 0x6d, 0x56, 0x63, 0x58, 0x0a, 0xdd, 0x4e, + 0xd6, 0x18, 0xac, 0x0f, 0xf3, 0x1e, 0xb4, 0x0d, 0x23, 0x2c, 0xf3, 0x10, 0xa3, 0xdd, 0xe7, 0xf6, + 0x40, 0x88, 0xab, 0x79, 0x20, 0x61, 0xed, 0x2a, 0x1a, 0xb0, 0x0f, 0x2f, 0xbf, 0x03, 0xd3, 0x11, + 0xf5, 0x98, 0xbf, 0xf8, 0xc9, 0x26, 0x6a, 0x41, 0x91, 0x69, 0xe2, 0x9f, 0x5b, 0xf6, 0x7a, 0xfc, + 0x96, 0x30, 0x39, 0xac, 0xc1, 0xd8, 0x97, 0x83, 0x3d, 0x6c, 0x79, 0x0d, 0xc6, 0x2e, 0x99, 0x0e, + 0xad, 0x9b, 0x36, 0xe5, 0x6e, 0x43, 0x0f, 0x41, 0x41, 0x57, 0x0d, 0xb1, 0xc2, 0x97, 0x05, 0x4f, + 0x81, 0xad, 0x41, 0xac, 0x9d, 0x77, 0x2b, 0xbb, 0x22, 0x93, 0x85, 0xdd, 0xca, 0x2e, 0x66, 0xed, + 0xf2, 0x45, 0x18, 0x11, 0xc3, 0x11, 0x05, 0x2a, 0x1c, 0x0c, 0x54, 0xc8, 0x00, 0xfa, 0xcd, 0x10, + 0x8c, 0x08, 0xed, 0x07, 0xb0, 0x11, 0x7c,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0x70, 0x52, 0x08, 0xb1, 0x43, 0x3b, 0x2f, 0xd8, 0xa6, 0x8e, 0x39, + 0xb6, 0xfc, 0x57, 0x09, 0x26, 0x63, 0x94, 0x03, 0x48, 0xe9, 0x4a, 0x3c, 0xa5, 0x3f, 0x7f, 0x18, + 0xc3, 0x72, 0x12, 0xfb, 0x17, 0x49, 0xb3, 0x98, 0x03, 0xd0, 0x16, 0x94, 0x2d, 0xb3, 0xdd, 0xb8, + 0x0b, 0xb7, 0x7a, 0x13, 0x6c, 0x85, 0xac, 0x87, 0x58, 0x38, 0x0a, 0x8c, 0x76, 0x61, 0xd2, 0x50, + 0x74, 0xe2, 0x58, 0x4a, 0x8b, 0x34, 0xee, 0xc2, 0x99, 0xca, 0x7d, 0xfc, 0xa6, 0x21, 0x89, 0x88, + 0xd3, 0x42, 0xe4, 0xdf, 0xa5, 0xec, 0x36, 0x6d, 0x8a, 0x5e, 0x86, 0x12, 0x7f, 0x60, 0xd1, 0x32, + 0x35, 0xb1, 0xb4, 0x9d, 0x61, 0x43, 0x53, 0x17, 0x6d, 0xb7, 0xf6, 0xe6, 0xbf, 0x7c, 0xe0, 0x91, + 0xb0, 0x4f, 0x88, 0x03, 0x18, 0xb4, 0x0e, 0xc3, 0xd6, 0x61, 0xca, 0x0c, 0xbe, 0xb0, 0xf0, 0xda, + 0x82, 0xe3, 0xc8, 0xff, 0x4e, 0x2a, 0xce, 0x97, 0x97, 0x6b, 0x77, 0x6d, 0xc0, 0x82, 0xb2, 0x26, + 0x77, 0xd0, 0x6c, 0x18, 0x11, 0xab, 0xac, 0x88, 0xcb, 0x8b, 0x87, 0x89, 0xcb, 0xe8, 0xca, 0x10, + 0x6c, 0x22, 0xfc, 0x46, 0x5f, 0x90, 0xfc, 0x0f, 0x09, 0x26, 0xb9, 0x42, 0x2d, 0xd7, 0x56, 0x69, + 0x77, 0x60, 0x19, 0x74, 0x2b, 0x96, 0x41, 0x97, 0x7b, 0x34, 0x34, 0xa5, 0x71, 0x6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0x68, 0x5d, 0x6c, 0x9a, 0xf4, 0x82, 0xaa, + 0x11, 0xa7, 0xeb, 0x50, 0xa2, 0x57, 0xc6, 0x79, 0xd8, 0x04, 0xcf, 0x35, 0x70, 0x26, 0x15, 0xce, + 0xe1, 0x46, 0x2f, 0xc1, 0x71, 0x31, 0x31, 0x79, 0x68, 0xf2, 0x13, 0xb4, 0x09, 0x3e, 0x15, 0xa7, + 0xd9, 0x8e, 0x78, 0x31, 0xd1, 0x87, 0x53, 0xd4, 0xfc, 0x1d, 0x82, 0x38, 0x01, 0x1e, 0xcc, 0x4b, + 0xbe, 0xc3, 0xbd, 0x43, 0x08, 0x55, 0xbd, 0x67, 0xef, 0x10, 0x22, 0x22, 0x0e, 0x3e, 0x84, 0xfa, + 0x62, 0x08, 0xa6, 0x42, 0xe2, 0x3b, 0x7e, 0x87, 0x90, 0xc1, 0x32, 0x80, 0x77, 0x08, 0xd9, 0x17, + 0xf9, 0x85, 0x7b, 0x7d, 0x91, 0x7f, 0x0f, 0xde, 0x3f, 0xf0, 0xb7, 0x01, 0xa1, 0x13, 0xff, 0xf7, + 0xdf, 0x06, 0x84, 0xba, 0xe6, 0x14, 0x44, 0x7f, 0x18, 0x8a, 0x1a, 0xf4, 0x7f, 0x74, 0x01, 0x7d, + 0xf8, 0x77, 0x8e, 0xf2, 0xa7, 0x05, 0x38, 0x9e, 0x9c, 0xb1, 0xb1, 0x7b, 0x48, 0xe9, 0xb6, 0xf7, + 0x90, 0x75, 0x98, 0xde, 0x72, 0x35, 0xad, 0xcb, 0x1d, 0x12, 0xb9, 0x8c, 0xf4, 0xce, 0xfd, 0x1f, + 0x14, 0x9c, 0xd3, 0x17, 0x32, 0x68, 0x70, 0x26, 0x67, 0xce, 0x9d, 0x6a, 0xa1, 0xaf, 0x3b, 0xd5, + 0xd4, 0x95, 0xde, 0x70, 0x0f, 0x57, 0x7a, 0x99, 0xf7, 0xa3, 0xc5, 0x3e, 0xee, 0x47, 0xef, 0xc6, + 0x85,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 0xc3, 0x1c, 0x9d, 0x79, + 0xe5, 0x98, 0x77, 0x66, 0xce, 0x24, 0x63, 0xde, 0x2a, 0x7f, 0x2e, 0xc1, 0x6c, 0xb6, 0x6a, 0x03, + 0xd8, 0x4a, 0x5c, 0x8b, 0x6f, 0x25, 0x7a, 0x3d, 0x78, 0xc8, 0xd6, 0x3b, 0x67, 0x5b, 0xb1, 0x97, + 0x39, 0x06, 0x03, 0x30, 0x72, 0x2b, 0x6e, 0xe4, 0xe2, 0xa1, 0x8d, 0xcc, 0x36, 0xb0, 0xf6, 0xd8, + 0x8d, 0x9b, 0x73, 0x47, 0x3e, 0xbe, 0x39, 0x77, 0xe4, 0x93, 0x9b, 0x73, 0x47, 0xde, 0xdd, 0x9f, + 0x93, 0x6e, 0xec, 0xcf, 0x49, 0x1f, 0xef, 0xcf, 0x49, 0xff, 0xdc, 0x9f, 0x93, 0x7e, 0xfc, 0xd9, + 0xdc, 0x91, 0xab, 0x23, 0x02, 0xf3, 0xbf, 0x01, 0x00, 0x00, 0xff, 0xff, 0x6d, 0x3f, 0x0c, 0xbe, + 0x34, 0x3d, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.proto index 6e12f519eef76..7a95c4ae16b8d 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.proto @@ -19,14 +19,13 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.extensions.v1beta1; +package k8s.io.client_go.pkg.apis.extensions.v1beta1; import "k8s.io/apimachinery/pkg/api/resource/generated.proto"; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; import "k8s.io/kubernetes/pkg/apis/policy/v1beta1/generated.proto"; @@ -111,7 +110,7 @@ message DaemonSetSpec { // that matches the template's node selector (or on every node if no node // selector is specified). // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template - optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 2; + optional k8s.io.client_go.pkg.api.v1.PodTemplateSpec template = 2; // An update strategy to replace existing DaemonSet pods with new pods. // +optional @@ -259,7 +258,7 @@ message DeploymentSpec { optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector selector = 2; // Template describes the pods that will be created. - optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 3; + optional k8s.io.client_go.pkg.api.v1.PodTemplateSpec template = 3; // The deployment strategy to use to replace existing pods with new ones. // +optional @@ -512,7 +511,7 @@ message IngressSpec { message IngressStatus { // LoadBalancer contains the current status of the load-balancer. // +optional - optional k8s.io.kubernetes.pkg.api.v1.LoadBalancerStatus loadBalancer = 1; + optional k8s.io.client_go.pkg.api.v1.LoadBalancerStatus loadBalancer = 1; } // IngressTLS describes the transport layer security associated with an Ingress. @@ -533,6 +532,7 @@ message IngressTLS { optional string secretName = 2; } +// NetworkPolicy describes what network traffic is allowed for a set of Pods message NetworkPolicy { // Standard object's metadata. // More info: https://github.com/kubernetes/community/blob/master/contributors/devel/api-conventions.md#metadata @@ -613,13 +613,12 @@ message NetworkPolicySpec { optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector podSelector = 1; // List of ingress rules to be applied to the selected pods. - // Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, + // Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod // OR if the traffic source is the pod's local node, // OR if the traffic matches at least one ingress rule across all of the NetworkPolicy // objects whose podSelector matches the pod. - // If this field is empty then this NetworkPolicy does not affect ingress isolation. - // If this field is present and contains at least one rule, this policy allows any traffic - // which matches at least one of the ingress rules in this list. + // If this field is empty then this NetworkPolicy does not allow any traffic + // (and serves solely to ensure that the pods it selects are isolated by default). // +optional repeated NetworkPolicyIngressRule ingress = 2; } @@ -711,6 +710,11 @@ message PodSecurityPolicySpec { // will not be forced to. // +optional optional bool readOnlyRootFilesystem = 14; + + // AllowedHostPaths is a white list of allowed host path prefixes. Empty indicates that all + // host paths may be used. + // +optional + repeated string allowedHostPaths = 15; } // ReplicaSet represents the configuration of a ReplicaSet. @@ -794,7 +798,7 @@ message ReplicaSetSpec { // insufficient replicas are detected. // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template // +optional - optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 3; + optional k8s.io.client_go.pkg.api.v1.PodTemplateSpec template = 3; } // ReplicaSetStatus represents the current status of a ReplicaSet. @@ -831,7 +835,7 @@ message ReplicationControllerDummy { } message RollbackConfig { - // The revision to rollback to. If set to 0, rollbck to the last revision. + // The revision to rollback to. If set to 0, rollback to the last revision. // +optional optional int64 revision = 1; } @@ -904,7 +908,7 @@ message SELinuxStrategyOptions { // seLinuxOptions required to run as; required for MustRunAs // More info: https://github.com/kubernetes/community/blob/master/contributors/design-proposals/security_context.md // +optional - optional k8s.io.kubernetes.pkg.api.v1.SELinuxOptions seLinuxOptions = 2; + optional k8s.io.client_go.pkg.api.v1.SELinuxOptions seLinuxOptions = 2; } // represents a scaling request for a resource. diff --git a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.generated.go b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.generated.go index 633862633f7d1..b7459aa3f7c3c 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.generated.go +++ b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.generated.go @@ -14595,7 +14595,7 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { } else { yysep2 := !z.EncBinary() yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [14]bool + var yyq2 [15]bool _, _, _ = yysep2, yyq2, yy2arr2 const yyr2 bool = false yyq2[0] = x.Privileged != false @@ -14608,9 +14608,10 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { yyq2[7] = x.HostPID != false yyq2[8] = x.HostIPC != false yyq2[13] = x.ReadOnlyRootFilesystem != false + yyq2[14] = len(x.AllowedHostPaths) != 0 var yynn2 int if yyr2 || yy2arr2 { - r.EncodeArrayStart(14) + r.EncodeArrayStart(15) } else { yynn2 = 4 for _, b := range yyq2 { @@ -14955,6 +14956,39 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[14] { + if x.AllowedHostPaths == nil { + r.EncodeNil() + } else { + yym54 := z.EncBinary() + _ = yym54 + if false { + } else { + z.F.EncSliceStringV(x.AllowedHostPaths, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[14] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("allowedHostPaths")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.AllowedHostPaths == nil { + r.EncodeNil() + } else { + yym55 := z.EncBinary() + _ = yym55 + if false { + } else { + z.F.EncSliceStringV(x.AllowedHostPaths, false, e) + } + } + } + } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { @@ -15164,6 +15198,18 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromMap(l int, d *codec1978.Decod *((*bool)(yyv26)) = r.DecodeBool() } } + case "allowedHostPaths": + if r.TryDecodeAsNil() { + x.AllowedHostPaths = nil + } else { + yyv28 := &x.AllowedHostPaths + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + z.F.DecSliceStringX(yyv28, false, d) + } + } default: z.DecStructFieldNotFound(-1, yys3) } // end switch yys3 @@ -15175,16 +15221,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj28 int - var yyb28 bool - var yyhl28 bool = l >= 0 - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + var yyj30 int + var yyb30 bool + var yyhl30 bool = l >= 0 + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15192,21 +15238,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Privileged = false } else { - yyv29 := &x.Privileged - yym30 := z.DecBinary() - _ = yym30 + yyv31 := &x.Privileged + yym32 := z.DecBinary() + _ = yym32 if false { } else { - *((*bool)(yyv29)) = r.DecodeBool() + *((*bool)(yyv31)) = r.DecodeBool() } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15214,21 +15260,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.DefaultAddCapabilities = nil } else { - yyv31 := &x.DefaultAddCapabilities - yym32 := z.DecBinary() - _ = yym32 + yyv33 := &x.DefaultAddCapabilities + yym34 := z.DecBinary() + _ = yym34 if false { } else { - h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv31), d) + h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv33), d) } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15236,21 +15282,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.RequiredDropCapabilities = nil } else { - yyv33 := &x.RequiredDropCapabilities - yym34 := z.DecBinary() - _ = yym34 + yyv35 := &x.RequiredDropCapabilities + yym36 := z.DecBinary() + _ = yym36 if false { } else { - h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv33), d) + h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv35), d) } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15258,21 +15304,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.AllowedCapabilities = nil } else { - yyv35 := &x.AllowedCapabilities - yym36 := z.DecBinary() - _ = yym36 + yyv37 := &x.AllowedCapabilities + yym38 := z.DecBinary() + _ = yym38 if false { } else { - h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv35), d) + h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv37), d) } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15280,21 +15326,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Volumes = nil } else { - yyv37 := &x.Volumes - yym38 := z.DecBinary() - _ = yym38 + yyv39 := &x.Volumes + yym40 := z.DecBinary() + _ = yym40 if false { } else { - h.decSliceFSType((*[]FSType)(yyv37), d) + h.decSliceFSType((*[]FSType)(yyv39), d) } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15302,21 +15348,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.HostNetwork = false } else { - yyv39 := &x.HostNetwork - yym40 := z.DecBinary() - _ = yym40 + yyv41 := &x.HostNetwork + yym42 := z.DecBinary() + _ = yym42 if false { } else { - *((*bool)(yyv39)) = r.DecodeBool() + *((*bool)(yyv41)) = r.DecodeBool() } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15324,21 +15370,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.HostPorts = nil } else { - yyv41 := &x.HostPorts - yym42 := z.DecBinary() - _ = yym42 + yyv43 := &x.HostPorts + yym44 := z.DecBinary() + _ = yym44 if false { } else { - h.decSliceHostPortRange((*[]HostPortRange)(yyv41), d) + h.decSliceHostPortRange((*[]HostPortRange)(yyv43), d) } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15346,21 +15392,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.HostPID = false } else { - yyv43 := &x.HostPID - yym44 := z.DecBinary() - _ = yym44 + yyv45 := &x.HostPID + yym46 := z.DecBinary() + _ = yym46 if false { } else { - *((*bool)(yyv43)) = r.DecodeBool() + *((*bool)(yyv45)) = r.DecodeBool() } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15368,21 +15414,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.HostIPC = false } else { - yyv45 := &x.HostIPC - yym46 := z.DecBinary() - _ = yym46 + yyv47 := &x.HostIPC + yym48 := z.DecBinary() + _ = yym48 if false { } else { - *((*bool)(yyv45)) = r.DecodeBool() + *((*bool)(yyv47)) = r.DecodeBool() } } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15390,16 +15436,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.SELinux = SELinuxStrategyOptions{} } else { - yyv47 := &x.SELinux - yyv47.CodecDecodeSelf(d) + yyv49 := &x.SELinux + yyv49.CodecDecodeSelf(d) } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15407,16 +15453,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.RunAsUser = RunAsUserStrategyOptions{} } else { - yyv48 := &x.RunAsUser - yyv48.CodecDecodeSelf(d) + yyv50 := &x.RunAsUser + yyv50.CodecDecodeSelf(d) } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15424,16 +15470,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.SupplementalGroups = SupplementalGroupsStrategyOptions{} } else { - yyv49 := &x.SupplementalGroups - yyv49.CodecDecodeSelf(d) + yyv51 := &x.SupplementalGroups + yyv51.CodecDecodeSelf(d) } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15441,16 +15487,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.FSGroup = FSGroupStrategyOptions{} } else { - yyv50 := &x.FSGroup - yyv50.CodecDecodeSelf(d) + yyv52 := &x.FSGroup + yyv52.CodecDecodeSelf(d) } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15458,26 +15504,48 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.ReadOnlyRootFilesystem = false } else { - yyv51 := &x.ReadOnlyRootFilesystem - yym52 := z.DecBinary() - _ = yym52 + yyv53 := &x.ReadOnlyRootFilesystem + yym54 := z.DecBinary() + _ = yym54 + if false { + } else { + *((*bool)(yyv53)) = r.DecodeBool() + } + } + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l + } else { + yyb30 = r.CheckBreak() + } + if yyb30 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.AllowedHostPaths = nil + } else { + yyv55 := &x.AllowedHostPaths + yym56 := z.DecBinary() + _ = yym56 if false { } else { - *((*bool)(yyv51)) = r.DecodeBool() + z.F.DecSliceStringX(yyv55, false, d) } } for { - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l + yyj30++ + if yyhl30 { + yyb30 = yyj30 > l } else { - yyb28 = r.CheckBreak() + yyb30 = r.CheckBreak() } - if yyb28 { + if yyb30 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj28-1, "") + z.DecStructFieldNotFound(yyj30-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -21266,7 +21334,7 @@ func (x codecSelfer1234) decSlicePodSecurityPolicy(v *[]PodSecurityPolicy, d *co yyrg1 := len(yyv1) > 0 yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 560) + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 584) if yyrt1 { if yyrl1 <= cap(yyv1) { yyv1 = yyv1[:yyrl1] diff --git a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.go b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.go index 75bd7505aed7e..800f4544f9551 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.go +++ b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.go @@ -228,7 +228,7 @@ type DeploymentRollback struct { } type RollbackConfig struct { - // The revision to rollback to. If set to 0, rollbck to the last revision. + // The revision to rollback to. If set to 0, rollback to the last revision. // +optional Revision int64 `json:"revision,omitempty" protobuf:"varint,1,opt,name=revision"` } @@ -909,6 +909,10 @@ type PodSecurityPolicySpec struct { // will not be forced to. // +optional ReadOnlyRootFilesystem bool `json:"readOnlyRootFilesystem,omitempty" protobuf:"varint,14,opt,name=readOnlyRootFilesystem"` + // AllowedHostPaths is a white list of allowed host path prefixes. Empty indicates that all + // host paths may be used. + // +optional + AllowedHostPaths []string `json:"allowedHostPaths,omitempty" protobuf:"bytes,15,opt,name=allowedHostPaths"` } // FS Type gives strong typing to different file systems that are used by volumes. @@ -1055,6 +1059,7 @@ type PodSecurityPolicyList struct { Items []PodSecurityPolicy `json:"items" protobuf:"bytes,2,rep,name=items"` } +// NetworkPolicy describes what network traffic is allowed for a set of Pods type NetworkPolicy struct { metav1.TypeMeta `json:",inline"` // Standard object's metadata. @@ -1076,13 +1081,12 @@ type NetworkPolicySpec struct { PodSelector metav1.LabelSelector `json:"podSelector" protobuf:"bytes,1,opt,name=podSelector"` // List of ingress rules to be applied to the selected pods. - // Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, + // Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod // OR if the traffic source is the pod's local node, // OR if the traffic matches at least one ingress rule across all of the NetworkPolicy // objects whose podSelector matches the pod. - // If this field is empty then this NetworkPolicy does not affect ingress isolation. - // If this field is present and contains at least one rule, this policy allows any traffic - // which matches at least one of the ingress rules in this list. + // If this field is empty then this NetworkPolicy does not allow any traffic + // (and serves solely to ensure that the pods it selects are isolated by default). // +optional Ingress []NetworkPolicyIngressRule `json:"ingress,omitempty" protobuf:"bytes,2,rep,name=ingress"` } diff --git a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go index d94bc009e9d42..213f8494ad06c 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go +++ b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go @@ -331,6 +331,7 @@ func (IngressTLS) SwaggerDoc() map[string]string { } var map_NetworkPolicy = map[string]string{ + "": "NetworkPolicy describes what network traffic is allowed for a set of Pods", "metadata": "Standard object's metadata. More info: https://github.com/kubernetes/community/blob/master/contributors/devel/api-conventions.md#metadata", "spec": "Specification of the desired behavior for this NetworkPolicy.", } @@ -379,7 +380,7 @@ func (NetworkPolicyPort) SwaggerDoc() map[string]string { var map_NetworkPolicySpec = map[string]string{ "podSelector": "Selects the pods to which this NetworkPolicy object applies. The array of ingress rules is applied to any pods selected by this field. Multiple network policies can select the same set of pods. In this case, the ingress rules for each are combined additively. This field is NOT optional and follows standard label selector semantics. An empty podSelector matches all pods in this namespace.", - "ingress": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not affect ingress isolation. If this field is present and contains at least one rule, this policy allows any traffic which matches at least one of the ingress rules in this list.", + "ingress": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default).", } func (NetworkPolicySpec) SwaggerDoc() map[string]string { @@ -422,6 +423,7 @@ var map_PodSecurityPolicySpec = map[string]string{ "supplementalGroups": "SupplementalGroups is the strategy that will dictate what supplemental groups are used by the SecurityContext.", "fsGroup": "FSGroup is the strategy that will dictate what fs group is used by the SecurityContext.", "readOnlyRootFilesystem": "ReadOnlyRootFilesystem when set to true will force containers to run with a read only root file system. If the container specifically requests to run with a non-read only root file system the PSP should deny the pod. If set to false the container may run with a read only root file system if it wishes but it will not be forced to.", + "allowedHostPaths": "AllowedHostPaths is a white list of allowed host path prefixes. Empty indicates that all host paths may be used.", } func (PodSecurityPolicySpec) SwaggerDoc() map[string]string { @@ -497,7 +499,7 @@ func (ReplicationControllerDummy) SwaggerDoc() map[string]string { } var map_RollbackConfig = map[string]string{ - "revision": "The revision to rollback to. If set to 0, rollbck to the last revision.", + "revision": "The revision to rollback to. If set to 0, rollback to the last revision.", } func (RollbackConfig) SwaggerDoc() map[string]string { diff --git a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.conversion.go b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.conversion.go index 9c73c3711dc54..884661db0d67b 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.conversion.go +++ b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.conversion.go @@ -1215,6 +1215,7 @@ func autoConvert_v1beta1_PodSecurityPolicySpec_To_extensions_PodSecurityPolicySp return err } out.ReadOnlyRootFilesystem = in.ReadOnlyRootFilesystem + out.AllowedHostPaths = *(*[]string)(unsafe.Pointer(&in.AllowedHostPaths)) return nil } @@ -1256,6 +1257,7 @@ func autoConvert_extensions_PodSecurityPolicySpec_To_v1beta1_PodSecurityPolicySp return err } out.ReadOnlyRootFilesystem = in.ReadOnlyRootFilesystem + out.AllowedHostPaths = *(*[]string)(unsafe.Pointer(&in.AllowedHostPaths)) return nil } diff --git a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.deepcopy.go b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.deepcopy.go index 95a5ecc0a13c1..9bb39222a57b9 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.deepcopy.go +++ b/staging/src/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.deepcopy.go @@ -826,6 +826,11 @@ func DeepCopy_v1beta1_PodSecurityPolicySpec(in interface{}, out interface{}, c * if err := DeepCopy_v1beta1_FSGroupStrategyOptions(&in.FSGroup, &out.FSGroup, c); err != nil { return err } + if in.AllowedHostPaths != nil { + in, out := &in.AllowedHostPaths, &out.AllowedHostPaths + *out = make([]string, len(*in)) + copy(*out, *in) + } return nil } } diff --git a/staging/src/k8s.io/client-go/pkg/apis/extensions/zz_generated.deepcopy.go b/staging/src/k8s.io/client-go/pkg/apis/extensions/zz_generated.deepcopy.go index b06b0692663fc..e6d3b1925e3fe 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/extensions/zz_generated.deepcopy.go +++ b/staging/src/k8s.io/client-go/pkg/apis/extensions/zz_generated.deepcopy.go @@ -818,6 +818,11 @@ func DeepCopy_extensions_PodSecurityPolicySpec(in interface{}, out interface{}, if err := DeepCopy_extensions_FSGroupStrategyOptions(&in.FSGroup, &out.FSGroup, c); err != nil { return err } + if in.AllowedHostPaths != nil { + in, out := &in.AllowedHostPaths, &out.AllowedHostPaths + *out = make([]string, len(*in)) + copy(*out, *in) + } return nil } } diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/BUILD b/staging/src/k8s.io/client-go/pkg/apis/networking/BUILD new file mode 100644 index 0000000000000..bcb0a04849e42 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/BUILD @@ -0,0 +1,27 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/OWNERS b/staging/src/k8s.io/client-go/pkg/apis/networking/OWNERS new file mode 100755 index 0000000000000..97bde97282c90 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/OWNERS @@ -0,0 +1,4 @@ +reviewers: +- caseydavenport +- danwinship +- thockin diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/doc.go b/staging/src/k8s.io/client-go/pkg/apis/networking/doc.go new file mode 100644 index 0000000000000..bf91d786a2218 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/doc.go @@ -0,0 +1,18 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// +groupName=networking.k8s.io +package networking diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/register.go b/staging/src/k8s.io/client-go/pkg/apis/networking/register.go new file mode 100644 index 0000000000000..4d58a210da29a --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/register.go @@ -0,0 +1,51 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package networking + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupName is the group name use in this package +const GroupName = "networking.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} + +// Kind takes an unqualified kind and returns a Group qualified GroupKind +func Kind(kind string) schema.GroupKind { + return SchemeGroupVersion.WithKind(kind).GroupKind() +} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) + AddToScheme = SchemeBuilder.AddToScheme +) + +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &NetworkPolicy{}, + &NetworkPolicyList{}, + ) + return nil +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/types.go b/staging/src/k8s.io/client-go/pkg/apis/networking/types.go new file mode 100644 index 0000000000000..010736f1b67f3 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/types.go @@ -0,0 +1,115 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package networking + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/intstr" + "k8s.io/client-go/pkg/api" +) + +// +genclient=true + +// NetworkPolicy describes what network traffic is allowed for a set of Pods +type NetworkPolicy struct { + metav1.TypeMeta + // +optional + metav1.ObjectMeta + + // Specification of the desired behavior for this NetworkPolicy. + // +optional + Spec NetworkPolicySpec +} + +// NetworkPolicySpec provides the specification of a NetworkPolicy +type NetworkPolicySpec struct { + // Selects the pods to which this NetworkPolicy object applies. The array of + // ingress rules is applied to any pods selected by this field. Multiple network + // policies can select the same set of pods. In this case, the ingress rules for + // each are combined additively. This field is NOT optional and follows standard + // label selector semantics. An empty podSelector matches all pods in this + // namespace. + PodSelector metav1.LabelSelector + + // List of ingress rules to be applied to the selected pods. Traffic is allowed to + // a pod if there are no NetworkPolicies selecting the pod + // (and cluster policy otherwise allows the traffic), OR if the traffic source is + // the pod's local node, OR if the traffic matches at least one ingress rule + // across all of the NetworkPolicy objects whose podSelector matches the pod. If + // this field is empty then this NetworkPolicy does not allow any traffic (and serves + // solely to ensure that the pods it selects are isolated by default) + // +optional + Ingress []NetworkPolicyIngressRule +} + +// NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods +// matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from. +type NetworkPolicyIngressRule struct { + // List of ports which should be made accessible on the pods selected for this + // rule. Each item in this list is combined using a logical OR. If this field is + // empty or missing, this rule matches all ports (traffic not restricted by port). + // If this field is present and contains at least one item, then this rule allows + // traffic only if the traffic matches at least one port in the list. + // +optional + Ports []NetworkPolicyPort + + // List of sources which should be able to access the pods selected for this rule. + // Items in this list are combined using a logical OR operation. If this field is + // empty or missing, this rule matches all sources (traffic not restricted by + // source). If this field is present and contains at least on item, this rule + // allows traffic only if the traffic matches at least one item in the from list. + // +optional + From []NetworkPolicyPeer +} + +// NetworkPolicyPort describes a port to allow traffic on +type NetworkPolicyPort struct { + // The protocol (TCP or UDP) which traffic must match. If not specified, this + // field defaults to TCP. + // +optional + Protocol *api.Protocol + + // The port on the given protocol. This can either be a numerical or named port on + // a pod. If this field is not provided, this matches all port names and numbers. + // +optional + Port *intstr.IntOrString +} + +// NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields +// must be specified. +type NetworkPolicyPeer struct { + // This is a label selector which selects Pods in this namespace. This field + // follows standard label selector semantics. If present but empty, this selector + // selects all pods in this namespace. + // +optional + PodSelector *metav1.LabelSelector + + // Selects Namespaces using cluster scoped-labels. This matches all pods in all + // namespaces selected by this label selector. This field follows standard label + // selector semantics. If present but empty, this selector selects all namespaces. + // +optional + NamespaceSelector *metav1.LabelSelector +} + +// NetworkPolicyList is a list of NetworkPolicy objects. +type NetworkPolicyList struct { + metav1.TypeMeta + // +optional + metav1.ListMeta + + Items []NetworkPolicy +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/v1/BUILD b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/BUILD new file mode 100644 index 0000000000000..b55e1b8cb274b --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/BUILD @@ -0,0 +1,40 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/extensions:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/networking:go_default_library", + ], +) diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/v1/conversion.go b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/conversion.go new file mode 100644 index 0000000000000..21ec62576df61 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/conversion.go @@ -0,0 +1,195 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/client-go/pkg/api" + "k8s.io/client-go/pkg/api/v1" + "k8s.io/client-go/pkg/apis/extensions" +) + +func addConversionFuncs(scheme *runtime.Scheme) error { + return scheme.AddConversionFuncs( + Convert_v1_NetworkPolicy_To_extensions_NetworkPolicy, + Convert_extensions_NetworkPolicy_To_v1_NetworkPolicy, + Convert_v1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIngressRule, + Convert_extensions_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule, + Convert_v1_NetworkPolicyList_To_extensions_NetworkPolicyList, + Convert_extensions_NetworkPolicyList_To_v1_NetworkPolicyList, + Convert_v1_NetworkPolicyPeer_To_extensions_NetworkPolicyPeer, + Convert_extensions_NetworkPolicyPeer_To_v1_NetworkPolicyPeer, + Convert_v1_NetworkPolicyPort_To_extensions_NetworkPolicyPort, + Convert_extensions_NetworkPolicyPort_To_v1_NetworkPolicyPort, + Convert_v1_NetworkPolicySpec_To_extensions_NetworkPolicySpec, + Convert_extensions_NetworkPolicySpec_To_v1_NetworkPolicySpec, + ) +} + +func Convert_v1_NetworkPolicy_To_extensions_NetworkPolicy(in *NetworkPolicy, out *extensions.NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + return Convert_v1_NetworkPolicySpec_To_extensions_NetworkPolicySpec(&in.Spec, &out.Spec, s) +} + +func Convert_extensions_NetworkPolicy_To_v1_NetworkPolicy(in *extensions.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + return Convert_extensions_NetworkPolicySpec_To_v1_NetworkPolicySpec(&in.Spec, &out.Spec, s) +} + +func Convert_v1_NetworkPolicySpec_To_extensions_NetworkPolicySpec(in *NetworkPolicySpec, out *extensions.NetworkPolicySpec, s conversion.Scope) error { + if err := s.Convert(&in.PodSelector, &out.PodSelector, 0); err != nil { + return err + } + out.Ingress = make([]extensions.NetworkPolicyIngressRule, len(in.Ingress)) + for i := range in.Ingress { + if err := Convert_v1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIngressRule(&in.Ingress[i], &out.Ingress[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_extensions_NetworkPolicySpec_To_v1_NetworkPolicySpec(in *extensions.NetworkPolicySpec, out *NetworkPolicySpec, s conversion.Scope) error { + if err := s.Convert(&in.PodSelector, &out.PodSelector, 0); err != nil { + return err + } + out.Ingress = make([]NetworkPolicyIngressRule, len(in.Ingress)) + for i := range in.Ingress { + if err := Convert_extensions_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(&in.Ingress[i], &out.Ingress[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_v1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIngressRule(in *NetworkPolicyIngressRule, out *extensions.NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = make([]extensions.NetworkPolicyPort, len(in.Ports)) + for i := range in.Ports { + if err := Convert_v1_NetworkPolicyPort_To_extensions_NetworkPolicyPort(&in.Ports[i], &out.Ports[i], s); err != nil { + return err + } + } + out.From = make([]extensions.NetworkPolicyPeer, len(in.From)) + for i := range in.From { + if err := Convert_v1_NetworkPolicyPeer_To_extensions_NetworkPolicyPeer(&in.From[i], &out.From[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_extensions_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(in *extensions.NetworkPolicyIngressRule, out *NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = make([]NetworkPolicyPort, len(in.Ports)) + for i := range in.Ports { + if err := Convert_extensions_NetworkPolicyPort_To_v1_NetworkPolicyPort(&in.Ports[i], &out.Ports[i], s); err != nil { + return err + } + } + out.From = make([]NetworkPolicyPeer, len(in.From)) + for i := range in.From { + if err := Convert_extensions_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(&in.From[i], &out.From[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_v1_NetworkPolicyPeer_To_extensions_NetworkPolicyPeer(in *NetworkPolicyPeer, out *extensions.NetworkPolicyPeer, s conversion.Scope) error { + if in.PodSelector != nil { + out.PodSelector = new(metav1.LabelSelector) + if err := s.Convert(in.PodSelector, out.PodSelector, 0); err != nil { + return err + } + } else { + out.PodSelector = nil + } + if in.NamespaceSelector != nil { + out.NamespaceSelector = new(metav1.LabelSelector) + if err := s.Convert(in.NamespaceSelector, out.NamespaceSelector, 0); err != nil { + return err + } + } else { + out.NamespaceSelector = nil + } + return nil +} + +func Convert_extensions_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(in *extensions.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { + if in.PodSelector != nil { + out.PodSelector = new(metav1.LabelSelector) + if err := s.Convert(in.PodSelector, out.PodSelector, 0); err != nil { + return err + } + } else { + out.PodSelector = nil + } + if in.NamespaceSelector != nil { + out.NamespaceSelector = new(metav1.LabelSelector) + if err := s.Convert(in.NamespaceSelector, out.NamespaceSelector, 0); err != nil { + return err + } + } else { + out.NamespaceSelector = nil + } + return nil +} + +func Convert_v1_NetworkPolicyPort_To_extensions_NetworkPolicyPort(in *NetworkPolicyPort, out *extensions.NetworkPolicyPort, s conversion.Scope) error { + if in.Protocol != nil { + out.Protocol = new(api.Protocol) + *out.Protocol = api.Protocol(*in.Protocol) + } else { + out.Protocol = nil + } + out.Port = in.Port + return nil +} + +func Convert_extensions_NetworkPolicyPort_To_v1_NetworkPolicyPort(in *extensions.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { + if in.Protocol != nil { + out.Protocol = new(v1.Protocol) + *out.Protocol = v1.Protocol(*in.Protocol) + } else { + out.Protocol = nil + } + out.Port = in.Port + return nil +} + +func Convert_v1_NetworkPolicyList_To_extensions_NetworkPolicyList(in *NetworkPolicyList, out *extensions.NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = make([]extensions.NetworkPolicy, len(in.Items)) + for i := range in.Items { + if err := Convert_v1_NetworkPolicy_To_extensions_NetworkPolicy(&in.Items[i], &out.Items[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_extensions_NetworkPolicyList_To_v1_NetworkPolicyList(in *extensions.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = make([]NetworkPolicy, len(in.Items)) + for i := range in.Items { + if err := Convert_extensions_NetworkPolicy_To_v1_NetworkPolicy(&in.Items[i], &out.Items[i], s); err != nil { + return err + } + } + return nil +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/v1/defaults.go b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/defaults.go new file mode 100644 index 0000000000000..7567cf751a326 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/defaults.go @@ -0,0 +1,34 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/client-go/pkg/api/v1" +) + +func addDefaultingFuncs(scheme *runtime.Scheme) error { + return RegisterDefaults(scheme) +} + +func SetDefaults_NetworkPolicyPort(obj *NetworkPolicyPort) { + // Default any undefined Protocol fields to TCP. + if obj.Protocol == nil { + proto := v1.ProtocolTCP + obj.Protocol = &proto + } +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/v1/doc.go b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/doc.go new file mode 100644 index 0000000000000..f1250e70e576b --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/doc.go @@ -0,0 +1,18 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// +groupName=networking.k8s.io +package v1 diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/v1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/generated.pb.go new file mode 100644 index 0000000000000..17e0b01c75e45 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/generated.pb.go @@ -0,0 +1,1345 @@ +/* +Copyright 2017 The Kubernetes 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 protoc-gen-gogo. +// source: k8s.io/kubernetes/pkg/apis/networking/v1/generated.proto +// DO NOT EDIT! + +/* + Package v1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/pkg/apis/networking/v1/generated.proto + + It has these top-level messages: + NetworkPolicy + NetworkPolicyIngressRule + NetworkPolicyList + NetworkPolicyPeer + NetworkPolicyPort + NetworkPolicySpec +*/ +package v1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + +import k8s_io_apimachinery_pkg_util_intstr "k8s.io/apimachinery/pkg/util/intstr" + +import k8s_io_kubernetes_pkg_api_v1 "k8s.io/client-go/pkg/api/v1" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *NetworkPolicy) Reset() { *m = NetworkPolicy{} } +func (*NetworkPolicy) ProtoMessage() {} +func (*NetworkPolicy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func (m *NetworkPolicyIngressRule) Reset() { *m = NetworkPolicyIngressRule{} } +func (*NetworkPolicyIngressRule) ProtoMessage() {} +func (*NetworkPolicyIngressRule) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{1} +} + +func (m *NetworkPolicyList) Reset() { *m = NetworkPolicyList{} } +func (*NetworkPolicyList) ProtoMessage() {} +func (*NetworkPolicyList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } + +func (m *NetworkPolicyPeer) Reset() { *m = NetworkPolicyPeer{} } +func (*NetworkPolicyPeer) ProtoMessage() {} +func (*NetworkPolicyPeer) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } + +func (m *NetworkPolicyPort) Reset() { *m = NetworkPolicyPort{} } +func (*NetworkPolicyPort) ProtoMessage() {} +func (*NetworkPolicyPort) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } + +func (m *NetworkPolicySpec) Reset() { *m = NetworkPolicySpec{} } +func (*NetworkPolicySpec) ProtoMessage() {} +func (*NetworkPolicySpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } + +func init() { + proto.RegisterType((*NetworkPolicy)(nil), "k8s.io.client-go.pkg.apis.networking.v1.NetworkPolicy") + proto.RegisterType((*NetworkPolicyIngressRule)(nil), "k8s.io.client-go.pkg.apis.networking.v1.NetworkPolicyIngressRule") + proto.RegisterType((*NetworkPolicyList)(nil), "k8s.io.client-go.pkg.apis.networking.v1.NetworkPolicyList") + proto.RegisterType((*NetworkPolicyPeer)(nil), "k8s.io.client-go.pkg.apis.networking.v1.NetworkPolicyPeer") + proto.RegisterType((*NetworkPolicyPort)(nil), "k8s.io.client-go.pkg.apis.networking.v1.NetworkPolicyPort") + proto.RegisterType((*NetworkPolicySpec)(nil), "k8s.io.client-go.pkg.apis.networking.v1.NetworkPolicySpec") +} +func (m *NetworkPolicy) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicy) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n2, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n2 + return i, nil +} + +func (m *NetworkPolicyIngressRule) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicyIngressRule) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Ports) > 0 { + for _, msg := range m.Ports { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if len(m.From) > 0 { + for _, msg := range m.From { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *NetworkPolicyList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicyList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n3, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *NetworkPolicyPeer) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicyPeer) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.PodSelector != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.PodSelector.Size())) + n4, err := m.PodSelector.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + } + if m.NamespaceSelector != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.NamespaceSelector.Size())) + n5, err := m.NamespaceSelector.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 + } + return i, nil +} + +func (m *NetworkPolicyPort) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicyPort) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.Protocol != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Protocol))) + i += copy(dAtA[i:], *m.Protocol) + } + if m.Port != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Port.Size())) + n6, err := m.Port.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n6 + } + return i, nil +} + +func (m *NetworkPolicySpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicySpec) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.PodSelector.Size())) + n7, err := m.PodSelector.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n7 + if len(m.Ingress) > 0 { + for _, msg := range m.Ingress { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *NetworkPolicy) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *NetworkPolicyIngressRule) Size() (n int) { + var l int + _ = l + if len(m.Ports) > 0 { + for _, e := range m.Ports { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.From) > 0 { + for _, e := range m.From { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *NetworkPolicyList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *NetworkPolicyPeer) Size() (n int) { + var l int + _ = l + if m.PodSelector != nil { + l = m.PodSelector.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.NamespaceSelector != nil { + l = m.NamespaceSelector.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *NetworkPolicyPort) Size() (n int) { + var l int + _ = l + if m.Protocol != nil { + l = len(*m.Protocol) + n += 1 + l + sovGenerated(uint64(l)) + } + if m.Port != nil { + l = m.Port.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *NetworkPolicySpec) Size() (n int) { + var l int + _ = l + l = m.PodSelector.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Ingress) > 0 { + for _, e := range m.Ingress { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *NetworkPolicy) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicy{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "NetworkPolicySpec", "NetworkPolicySpec", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicyIngressRule) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicyIngressRule{`, + `Ports:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Ports), "NetworkPolicyPort", "NetworkPolicyPort", 1), `&`, ``, 1) + `,`, + `From:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.From), "NetworkPolicyPeer", "NetworkPolicyPeer", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicyList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicyList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "NetworkPolicy", "NetworkPolicy", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicyPeer) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicyPeer{`, + `PodSelector:` + strings.Replace(fmt.Sprintf("%v", this.PodSelector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, + `NamespaceSelector:` + strings.Replace(fmt.Sprintf("%v", this.NamespaceSelector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicyPort) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicyPort{`, + `Protocol:` + valueToStringGenerated(this.Protocol) + `,`, + `Port:` + strings.Replace(fmt.Sprintf("%v", this.Port), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicySpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicySpec{`, + `PodSelector:` + strings.Replace(strings.Replace(this.PodSelector.String(), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1), `&`, ``, 1) + `,`, + `Ingress:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Ingress), "NetworkPolicyIngressRule", "NetworkPolicyIngressRule", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *NetworkPolicy) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicy: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicy: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicyIngressRule) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicyIngressRule: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicyIngressRule: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Ports", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Ports = append(m.Ports, NetworkPolicyPort{}) + if err := m.Ports[len(m.Ports)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field From", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.From = append(m.From, NetworkPolicyPeer{}) + if err := m.From[len(m.From)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicyList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicyList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicyList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, NetworkPolicy{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicyPeer) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicyPeer: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicyPeer: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PodSelector", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.PodSelector == nil { + m.PodSelector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} + } + if err := m.PodSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field NamespaceSelector", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.NamespaceSelector == nil { + m.NamespaceSelector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} + } + if err := m.NamespaceSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicyPort) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicyPort: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicyPort: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Protocol", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := k8s_io_kubernetes_pkg_api_v1.Protocol(dAtA[iNdEx:postIndex]) + m.Protocol = &s + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Port == nil { + m.Port = &k8s_io_apimachinery_pkg_util_intstr.IntOrString{} + } + if err := m.Port.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicySpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicySpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicySpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PodSelector", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.PodSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Ingress", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Ingress = append(m.Ingress, NetworkPolicyIngressRule{}) + if err := m.Ingress[len(m.Ingress)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/networking/v1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 663 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0xcf, 0x4f, 0x13, 0x41, + 0x18, 0xed, 0x56, 0x08, 0x75, 0x90, 0x20, 0x6b, 0x4c, 0x1a, 0x0e, 0x5b, 0xd2, 0x68, 0xc2, 0x41, + 0x67, 0xad, 0xf8, 0x03, 0x63, 0xbc, 0xec, 0xc1, 0x84, 0x44, 0xa1, 0x2e, 0x37, 0x83, 0x09, 0xd3, + 0xe5, 0x63, 0x19, 0xda, 0x9d, 0xd9, 0xcc, 0x4c, 0x2b, 0xdc, 0xfc, 0x13, 0xfc, 0x6b, 0xfc, 0x1b, + 0xb8, 0xc9, 0xd1, 0xc4, 0xa4, 0x91, 0xf5, 0xee, 0xcd, 0x8b, 0x27, 0x33, 0xbb, 0x53, 0xb6, 0xb0, + 0x2c, 0x92, 0xe2, 0x6d, 0x66, 0xf2, 0xbd, 0xf7, 0xbe, 0x37, 0xef, 0x9b, 0x41, 0xab, 0xdd, 0x55, + 0x89, 0x29, 0x77, 0xbb, 0xfd, 0x0e, 0x08, 0x06, 0x0a, 0xa4, 0x1b, 0x77, 0x43, 0x97, 0xc4, 0x54, + 0xba, 0x0c, 0xd4, 0x47, 0x2e, 0xba, 0x94, 0x85, 0xee, 0xa0, 0xe5, 0x86, 0xc0, 0x40, 0x10, 0x05, + 0x3b, 0x38, 0x16, 0x5c, 0x71, 0x7b, 0x39, 0x43, 0xe2, 0x1c, 0x89, 0xe3, 0x6e, 0x88, 0x35, 0x12, + 0xe7, 0x48, 0x3c, 0x68, 0x2d, 0x3e, 0x0c, 0xa9, 0xda, 0xeb, 0x77, 0x70, 0xc0, 0x23, 0x37, 0xe4, + 0x21, 0x77, 0x53, 0x82, 0x4e, 0x7f, 0x37, 0xdd, 0xa5, 0x9b, 0x74, 0x95, 0x11, 0x2f, 0x3e, 0x31, + 0x2d, 0x91, 0x98, 0x46, 0x24, 0xd8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0x34, + 0xf6, 0x3a, 0x9a, 0xd2, 0xa3, 0x69, 0x5c, 0x95, 0xbf, 0x66, 0xfd, 0x9f, 0xe1, 0xec, 0x3f, 0xc3, + 0x6b, 0x4c, 0x6d, 0x88, 0x4d, 0x25, 0x28, 0x0b, 0xbd, 0x9a, 0x1e, 0x41, 0xdd, 0x9c, 0x9f, 0xf2, + 0x34, 0x7f, 0x9d, 0x6f, 0x5c, 0x3f, 0x3e, 0x7b, 0xff, 0xbf, 0x05, 0x76, 0xc7, 0x8c, 0x49, 0x79, + 0x68, 0x11, 0x9a, 0xa1, 0xd9, 0xa3, 0x36, 0x23, 0xe9, 0x4d, 0x38, 0x92, 0x63, 0x5f, 0x83, 0x37, + 0x6f, 0x64, 0x67, 0x46, 0x87, 0x23, 0x0d, 0xef, 0xde, 0xd1, 0x89, 0x53, 0x39, 0x3e, 0x71, 0x2a, + 0xdf, 0x4e, 0x9c, 0xca, 0xa7, 0xc4, 0xb1, 0x8e, 0x12, 0xc7, 0x3a, 0x4e, 0x1c, 0xeb, 0x47, 0xe2, + 0x58, 0x9f, 0x7f, 0x3a, 0x95, 0xf7, 0xd5, 0x41, 0xeb, 0x6f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x7c, + 0x88, 0xbe, 0x48, 0x5a, 0x07, 0x00, 0x00, +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/v1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/generated.proto new file mode 100644 index 0000000000000..0af280b05cc60 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/generated.proto @@ -0,0 +1,127 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.client_go.pkg.apis.networking.v1; + +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; +import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; +import "k8s.io/kubernetes/pkg/apis/extensions/v1beta1/generated.proto"; +import "k8s.io/kubernetes/pkg/apis/policy/v1beta1/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v1"; + +// NetworkPolicy describes what network traffic is allowed for a set of Pods +message NetworkPolicy { + // Standard object's metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Specification of the desired behavior for this NetworkPolicy. + // +optional + optional NetworkPolicySpec spec = 2; +} + +// NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods +// matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from. +message NetworkPolicyIngressRule { + // List of ports which should be made accessible on the pods selected for this + // rule. Each item in this list is combined using a logical OR. If this field is + // empty or missing, this rule matches all ports (traffic not restricted by port). + // If this field is present and contains at least one item, then this rule allows + // traffic only if the traffic matches at least one port in the list. + // +optional + repeated NetworkPolicyPort ports = 1; + + // List of sources which should be able to access the pods selected for this rule. + // Items in this list are combined using a logical OR operation. If this field is + // empty or missing, this rule matches all sources (traffic not restricted by + // source). If this field is present and contains at least on item, this rule + // allows traffic only if the traffic matches at least one item in the from list. + // +optional + repeated NetworkPolicyPeer from = 2; +} + +// NetworkPolicyList is a list of NetworkPolicy objects. +message NetworkPolicyList { + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // Items is a list of schema objects. + repeated NetworkPolicy items = 2; +} + +// NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields +// must be specified. +message NetworkPolicyPeer { + // This is a label selector which selects Pods in this namespace. This field + // follows standard label selector semantics. If present but empty, this selector + // selects all pods in this namespace. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector podSelector = 1; + + // Selects Namespaces using cluster scoped-labels. This matches all pods in all + // namespaces selected by this label selector. This field follows standard label + // selector semantics. If present but empty, this selector selects all namespaces. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector namespaceSelector = 2; +} + +// NetworkPolicyPort describes a port to allow traffic on +message NetworkPolicyPort { + // The protocol (TCP or UDP) which traffic must match. If not specified, this + // field defaults to TCP. + // +optional + optional string protocol = 1; + + // The port on the given protocol. This can either be a numerical or named port on + // a pod. If this field is not provided, this matches all port names and numbers. + // +optional + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString port = 2; +} + +// NetworkPolicySpec provides the specification of a NetworkPolicy +message NetworkPolicySpec { + // Selects the pods to which this NetworkPolicy object applies. The array of + // ingress rules is applied to any pods selected by this field. Multiple network + // policies can select the same set of pods. In this case, the ingress rules for + // each are combined additively. This field is NOT optional and follows standard + // label selector semantics. An empty podSelector matches all pods in this + // namespace. + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector podSelector = 1; + + // List of ingress rules to be applied to the selected pods. Traffic is allowed to + // a pod if there are no NetworkPolicies selecting the pod + // (and cluster policy otherwise allows the traffic), OR if the traffic source is + // the pod's local node, OR if the traffic matches at least one ingress rule + // across all of the NetworkPolicy objects whose podSelector matches the pod. If + // this field is empty then this NetworkPolicy does not allow any traffic (and serves + // solely to ensure that the pods it selects are isolated by default) + // +optional + repeated NetworkPolicyIngressRule ingress = 2; +} + diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/v1/register.go b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/register.go new file mode 100644 index 0000000000000..c8d3c83bcc906 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/register.go @@ -0,0 +1,50 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupName is the group name use in this package +const GroupName = "networking.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addDefaultingFuncs, addConversionFuncs) + AddToScheme = SchemeBuilder.AddToScheme +) + +// Adds the list of known types to api.Scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &NetworkPolicy{}, + &NetworkPolicyList{}, + ) + + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) + return nil +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/v1/types.generated.go b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/types.generated.go new file mode 100644 index 0000000000000..da04aee42173e --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/types.generated.go @@ -0,0 +1,2322 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +// ************************************************************ +// DO NOT EDIT. +// THIS FILE IS AUTO-GENERATED BY codecgen. +// ************************************************************ + +package v1 + +import ( + "errors" + "fmt" + codec1978 "github.com/ugorji/go/codec" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" + pkg4_intstr "k8s.io/apimachinery/pkg/util/intstr" + pkg3_v1 "k8s.io/client-go/pkg/api/v1" + "reflect" + "runtime" + time "time" +) + +const ( + // ----- content types ---- + codecSelferC_UTF81234 = 1 + codecSelferC_RAW1234 = 0 + // ----- value types used ---- + codecSelferValueTypeArray1234 = 10 + codecSelferValueTypeMap1234 = 9 + // ----- containerStateValues ---- + codecSelfer_containerMapKey1234 = 2 + codecSelfer_containerMapValue1234 = 3 + codecSelfer_containerMapEnd1234 = 4 + codecSelfer_containerArrayElem1234 = 6 + codecSelfer_containerArrayEnd1234 = 7 +) + +var ( + codecSelferBitsize1234 = uint8(reflect.TypeOf(uint(0)).Bits()) + codecSelferOnlyMapOrArrayEncodeToStructErr1234 = errors.New(`only encoded map or array can be decoded into a struct`) +) + +type codecSelfer1234 struct{} + +func init() { + if codec1978.GenVersion != 5 { + _, file, _, _ := runtime.Caller(0) + err := fmt.Errorf("codecgen version mismatch: current: %v, need %v. Re-generate file: %v", + 5, codec1978.GenVersion, file) + panic(err) + } + if false { // reference the types, but skip this branch at build/run time + var v0 pkg1_v1.TypeMeta + var v1 pkg2_types.UID + var v2 pkg4_intstr.IntOrString + var v3 pkg3_v1.Protocol + var v4 time.Time + _, _, _, _, _ = v0, v1, v2, v3, v4 + } +} + +func (x *NetworkPolicy) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("spec")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicy) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "spec": + if r.TryDecodeAsNil() { + x.Spec = NetworkPolicySpec{} + } else { + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv12 := &x.Kind + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv14 := &x.APIVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv16 := &x.ObjectMeta + yym17 := z.DecBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.DecExt(yyv16) { + } else { + z.DecFallback(yyv16, false) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Spec = NetworkPolicySpec{} + } else { + yyv18 := &x.Spec + yyv18.CodecDecodeSelf(d) + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = len(x.Ingress) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy4 := &x.PodSelector + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(yy4) { + } else { + z.EncFallback(yy4) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("podSelector")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy6 := &x.PodSelector + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(yy6) { + } else { + z.EncFallback(yy6) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Ingress == nil { + r.EncodeNil() + } else { + yym9 := z.EncBinary() + _ = yym9 + if false { + } else { + h.encSliceNetworkPolicyIngressRule(([]NetworkPolicyIngressRule)(x.Ingress), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("ingress")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Ingress == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + h.encSliceNetworkPolicyIngressRule(([]NetworkPolicyIngressRule)(x.Ingress), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicySpec) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicySpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "podSelector": + if r.TryDecodeAsNil() { + x.PodSelector = pkg1_v1.LabelSelector{} + } else { + yyv4 := &x.PodSelector + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(yyv4) { + } else { + z.DecFallback(yyv4, false) + } + } + case "ingress": + if r.TryDecodeAsNil() { + x.Ingress = nil + } else { + yyv6 := &x.Ingress + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSliceNetworkPolicyIngressRule((*[]NetworkPolicyIngressRule)(yyv6), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.PodSelector = pkg1_v1.LabelSelector{} + } else { + yyv9 := &x.PodSelector + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(yyv9) { + } else { + z.DecFallback(yyv9, false) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Ingress = nil + } else { + yyv11 := &x.Ingress + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + h.decSliceNetworkPolicyIngressRule((*[]NetworkPolicyIngressRule)(yyv11), d) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicyIngressRule) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Ports) != 0 + yyq2[1] = len(x.From) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Ports == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSliceNetworkPolicyPort(([]NetworkPolicyPort)(x.Ports), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("ports")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Ports == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSliceNetworkPolicyPort(([]NetworkPolicyPort)(x.Ports), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.From == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encSliceNetworkPolicyPeer(([]NetworkPolicyPeer)(x.From), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("from")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.From == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encSliceNetworkPolicyPeer(([]NetworkPolicyPeer)(x.From), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicyIngressRule) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicyIngressRule) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "ports": + if r.TryDecodeAsNil() { + x.Ports = nil + } else { + yyv4 := &x.Ports + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSliceNetworkPolicyPort((*[]NetworkPolicyPort)(yyv4), d) + } + } + case "from": + if r.TryDecodeAsNil() { + x.From = nil + } else { + yyv6 := &x.From + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSliceNetworkPolicyPeer((*[]NetworkPolicyPeer)(yyv6), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicyIngressRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Ports = nil + } else { + yyv9 := &x.Ports + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + h.decSliceNetworkPolicyPort((*[]NetworkPolicyPort)(yyv9), d) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.From = nil + } else { + yyv11 := &x.From + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + h.decSliceNetworkPolicyPeer((*[]NetworkPolicyPeer)(yyv11), d) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicyPort) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Protocol != nil + yyq2[1] = x.Port != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Protocol == nil { + r.EncodeNil() + } else { + yy4 := *x.Protocol + yysf5 := &yy4 + yysf5.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("protocol")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Protocol == nil { + r.EncodeNil() + } else { + yy6 := *x.Protocol + yysf7 := &yy6 + yysf7.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Port == nil { + r.EncodeNil() + } else { + yym9 := z.EncBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.EncExt(x.Port) { + } else if !yym9 && z.IsJSONHandle() { + z.EncJSONMarshal(x.Port) + } else { + z.EncFallback(x.Port) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("port")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Port == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.Port) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(x.Port) + } else { + z.EncFallback(x.Port) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicyPort) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicyPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "protocol": + if r.TryDecodeAsNil() { + if x.Protocol != nil { + x.Protocol = nil + } + } else { + if x.Protocol == nil { + x.Protocol = new(pkg3_v1.Protocol) + } + x.Protocol.CodecDecodeSelf(d) + } + case "port": + if r.TryDecodeAsNil() { + if x.Port != nil { + x.Port = nil + } + } else { + if x.Port == nil { + x.Port = new(pkg4_intstr.IntOrString) + } + yym6 := z.DecBinary() + _ = yym6 + if false { + } else if z.HasExtensions() && z.DecExt(x.Port) { + } else if !yym6 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.Port) + } else { + z.DecFallback(x.Port, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicyPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Protocol != nil { + x.Protocol = nil + } + } else { + if x.Protocol == nil { + x.Protocol = new(pkg3_v1.Protocol) + } + x.Protocol.CodecDecodeSelf(d) + } + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Port != nil { + x.Port = nil + } + } else { + if x.Port == nil { + x.Port = new(pkg4_intstr.IntOrString) + } + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(x.Port) { + } else if !yym10 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.Port) + } else { + z.DecFallback(x.Port, false) + } + } + for { + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj7-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicyPeer) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.PodSelector != nil + yyq2[1] = x.NamespaceSelector != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.PodSelector == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else if z.HasExtensions() && z.EncExt(x.PodSelector) { + } else { + z.EncFallback(x.PodSelector) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("podSelector")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.PodSelector == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(x.PodSelector) { + } else { + z.EncFallback(x.PodSelector) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.NamespaceSelector == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(x.NamespaceSelector) { + } else { + z.EncFallback(x.NamespaceSelector) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("namespaceSelector")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.NamespaceSelector == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(x.NamespaceSelector) { + } else { + z.EncFallback(x.NamespaceSelector) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicyPeer) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicyPeer) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "podSelector": + if r.TryDecodeAsNil() { + if x.PodSelector != nil { + x.PodSelector = nil + } + } else { + if x.PodSelector == nil { + x.PodSelector = new(pkg1_v1.LabelSelector) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(x.PodSelector) { + } else { + z.DecFallback(x.PodSelector, false) + } + } + case "namespaceSelector": + if r.TryDecodeAsNil() { + if x.NamespaceSelector != nil { + x.NamespaceSelector = nil + } + } else { + if x.NamespaceSelector == nil { + x.NamespaceSelector = new(pkg1_v1.LabelSelector) + } + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(x.NamespaceSelector) { + } else { + z.DecFallback(x.NamespaceSelector, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicyPeer) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.PodSelector != nil { + x.PodSelector = nil + } + } else { + if x.PodSelector == nil { + x.PodSelector = new(pkg1_v1.LabelSelector) + } + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(x.PodSelector) { + } else { + z.DecFallback(x.PodSelector, false) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.NamespaceSelector != nil { + x.NamespaceSelector = nil + } + } else { + if x.NamespaceSelector == nil { + x.NamespaceSelector = new(pkg1_v1.LabelSelector) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.DecExt(x.NamespaceSelector) { + } else { + z.DecFallback(x.NamespaceSelector, false) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicyList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceNetworkPolicy(([]NetworkPolicy)(x.Items), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceNetworkPolicy(([]NetworkPolicy)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicyList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicyList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceNetworkPolicy((*[]NetworkPolicy)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicyList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceNetworkPolicy((*[]NetworkPolicy)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) encSliceNetworkPolicyIngressRule(v []NetworkPolicyIngressRule, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceNetworkPolicyIngressRule(v *[]NetworkPolicyIngressRule, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicyIngressRule{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 48) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]NetworkPolicyIngressRule, yyrl1) + } + } else { + yyv1 = make([]NetworkPolicyIngressRule, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyIngressRule{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicyIngressRule{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyIngressRule{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicyIngressRule{}) // var yyz1 NetworkPolicyIngressRule + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyIngressRule{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicyIngressRule{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceNetworkPolicyPort(v []NetworkPolicyPort, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceNetworkPolicyPort(v *[]NetworkPolicyPort, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicyPort{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]NetworkPolicyPort, yyrl1) + } + } else { + yyv1 = make([]NetworkPolicyPort, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPort{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicyPort{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPort{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicyPort{}) // var yyz1 NetworkPolicyPort + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPort{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicyPort{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceNetworkPolicyPeer(v []NetworkPolicyPeer, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceNetworkPolicyPeer(v *[]NetworkPolicyPeer, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicyPeer{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]NetworkPolicyPeer, yyrl1) + } + } else { + yyv1 = make([]NetworkPolicyPeer, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPeer{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicyPeer{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPeer{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicyPeer{}) // var yyz1 NetworkPolicyPeer + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPeer{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicyPeer{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceNetworkPolicy(v []NetworkPolicy, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceNetworkPolicy(v *[]NetworkPolicy, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicy{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 320) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]NetworkPolicy, yyrl1) + } + } else { + yyv1 = make([]NetworkPolicy, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicy{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicy{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicy{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicy{}) // var yyz1 NetworkPolicy + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicy{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicy{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/v1/types.go b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/types.go new file mode 100644 index 0000000000000..26422c4a974f0 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/types.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/intstr" + "k8s.io/client-go/pkg/api/v1" +) + +// +genclient=true + +// NetworkPolicy describes what network traffic is allowed for a set of Pods +type NetworkPolicy struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Specification of the desired behavior for this NetworkPolicy. + // +optional + Spec NetworkPolicySpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` +} + +// NetworkPolicySpec provides the specification of a NetworkPolicy +type NetworkPolicySpec struct { + // Selects the pods to which this NetworkPolicy object applies. The array of + // ingress rules is applied to any pods selected by this field. Multiple network + // policies can select the same set of pods. In this case, the ingress rules for + // each are combined additively. This field is NOT optional and follows standard + // label selector semantics. An empty podSelector matches all pods in this + // namespace. + PodSelector metav1.LabelSelector `json:"podSelector" protobuf:"bytes,1,opt,name=podSelector"` + + // List of ingress rules to be applied to the selected pods. Traffic is allowed to + // a pod if there are no NetworkPolicies selecting the pod + // (and cluster policy otherwise allows the traffic), OR if the traffic source is + // the pod's local node, OR if the traffic matches at least one ingress rule + // across all of the NetworkPolicy objects whose podSelector matches the pod. If + // this field is empty then this NetworkPolicy does not allow any traffic (and serves + // solely to ensure that the pods it selects are isolated by default) + // +optional + Ingress []NetworkPolicyIngressRule `json:"ingress,omitempty" protobuf:"bytes,2,rep,name=ingress"` +} + +// NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods +// matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from. +type NetworkPolicyIngressRule struct { + // List of ports which should be made accessible on the pods selected for this + // rule. Each item in this list is combined using a logical OR. If this field is + // empty or missing, this rule matches all ports (traffic not restricted by port). + // If this field is present and contains at least one item, then this rule allows + // traffic only if the traffic matches at least one port in the list. + // +optional + Ports []NetworkPolicyPort `json:"ports,omitempty" protobuf:"bytes,1,rep,name=ports"` + + // List of sources which should be able to access the pods selected for this rule. + // Items in this list are combined using a logical OR operation. If this field is + // empty or missing, this rule matches all sources (traffic not restricted by + // source). If this field is present and contains at least on item, this rule + // allows traffic only if the traffic matches at least one item in the from list. + // +optional + From []NetworkPolicyPeer `json:"from,omitempty" protobuf:"bytes,2,rep,name=from"` +} + +// NetworkPolicyPort describes a port to allow traffic on +type NetworkPolicyPort struct { + // The protocol (TCP or UDP) which traffic must match. If not specified, this + // field defaults to TCP. + // +optional + Protocol *v1.Protocol `json:"protocol,omitempty" protobuf:"bytes,1,opt,name=protocol,casttype=k8s.io/kubernetes/pkg/api/v1.Protocol"` + + // The port on the given protocol. This can either be a numerical or named port on + // a pod. If this field is not provided, this matches all port names and numbers. + // +optional + Port *intstr.IntOrString `json:"port,omitempty" protobuf:"bytes,2,opt,name=port"` +} + +// NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields +// must be specified. +type NetworkPolicyPeer struct { + // This is a label selector which selects Pods in this namespace. This field + // follows standard label selector semantics. If present but empty, this selector + // selects all pods in this namespace. + // +optional + PodSelector *metav1.LabelSelector `json:"podSelector,omitempty" protobuf:"bytes,1,opt,name=podSelector"` + + // Selects Namespaces using cluster scoped-labels. This matches all pods in all + // namespaces selected by this label selector. This field follows standard label + // selector semantics. If present but empty, this selector selects all namespaces. + // +optional + NamespaceSelector *metav1.LabelSelector `json:"namespaceSelector,omitempty" protobuf:"bytes,2,opt,name=namespaceSelector"` +} + +// NetworkPolicyList is a list of NetworkPolicy objects. +type NetworkPolicyList struct { + metav1.TypeMeta `json:",inline"` + // Standard list metadata. + // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Items is a list of schema objects. + Items []NetworkPolicy `json:"items" protobuf:"bytes,2,rep,name=items"` +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/v1/types_swagger_doc_generated.go b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/types_swagger_doc_generated.go new file mode 100644 index 0000000000000..0df3f14013c96 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/types_swagger_doc_generated.go @@ -0,0 +1,90 @@ +/* +Copyright 2016 The Kubernetes 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. +*/ + +package v1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_NetworkPolicy = map[string]string{ + "": "NetworkPolicy describes what network traffic is allowed for a set of Pods", + "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "spec": "Specification of the desired behavior for this NetworkPolicy.", +} + +func (NetworkPolicy) SwaggerDoc() map[string]string { + return map_NetworkPolicy +} + +var map_NetworkPolicyIngressRule = map[string]string{ + "": "NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from.", + "ports": "List of ports which should be made accessible on the pods selected for this rule. Each item in this list is combined using a logical OR. If this field is empty or missing, this rule matches all ports (traffic not restricted by port). If this field is present and contains at least one item, then this rule allows traffic only if the traffic matches at least one port in the list.", + "from": "List of sources which should be able to access the pods selected for this rule. Items in this list are combined using a logical OR operation. If this field is empty or missing, this rule matches all sources (traffic not restricted by source). If this field is present and contains at least on item, this rule allows traffic only if the traffic matches at least one item in the from list.", +} + +func (NetworkPolicyIngressRule) SwaggerDoc() map[string]string { + return map_NetworkPolicyIngressRule +} + +var map_NetworkPolicyList = map[string]string{ + "": "NetworkPolicyList is a list of NetworkPolicy objects.", + "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "items": "Items is a list of schema objects.", +} + +func (NetworkPolicyList) SwaggerDoc() map[string]string { + return map_NetworkPolicyList +} + +var map_NetworkPolicyPeer = map[string]string{ + "": "NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields must be specified.", + "podSelector": "This is a label selector which selects Pods in this namespace. This field follows standard label selector semantics. If present but empty, this selector selects all pods in this namespace.", + "namespaceSelector": "Selects Namespaces using cluster scoped-labels. This matches all pods in all namespaces selected by this label selector. This field follows standard label selector semantics. If present but empty, this selector selects all namespaces.", +} + +func (NetworkPolicyPeer) SwaggerDoc() map[string]string { + return map_NetworkPolicyPeer +} + +var map_NetworkPolicyPort = map[string]string{ + "": "NetworkPolicyPort describes a port to allow traffic on", + "protocol": "The protocol (TCP or UDP) which traffic must match. If not specified, this field defaults to TCP.", + "port": "The port on the given protocol. This can either be a numerical or named port on a pod. If this field is not provided, this matches all port names and numbers.", +} + +func (NetworkPolicyPort) SwaggerDoc() map[string]string { + return map_NetworkPolicyPort +} + +var map_NetworkPolicySpec = map[string]string{ + "": "NetworkPolicySpec provides the specification of a NetworkPolicy", + "podSelector": "Selects the pods to which this NetworkPolicy object applies. The array of ingress rules is applied to any pods selected by this field. Multiple network policies can select the same set of pods. In this case, the ingress rules for each are combined additively. This field is NOT optional and follows standard label selector semantics. An empty podSelector matches all pods in this namespace.", + "ingress": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod (and cluster policy otherwise allows the traffic), OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default)", +} + +func (NetworkPolicySpec) SwaggerDoc() map[string]string { + return map_NetworkPolicySpec +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.conversion.go b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.conversion.go new file mode 100644 index 0000000000000..500438e92f923 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.conversion.go @@ -0,0 +1,195 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" + api "k8s.io/client-go/pkg/api" + api_v1 "k8s.io/client-go/pkg/api/v1" + networking "k8s.io/client-go/pkg/apis/networking" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v1_NetworkPolicy_To_networking_NetworkPolicy, + Convert_networking_NetworkPolicy_To_v1_NetworkPolicy, + Convert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule, + Convert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule, + Convert_v1_NetworkPolicyList_To_networking_NetworkPolicyList, + Convert_networking_NetworkPolicyList_To_v1_NetworkPolicyList, + Convert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer, + Convert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer, + Convert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort, + Convert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort, + Convert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec, + Convert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec, + ) +} + +func autoConvert_v1_NetworkPolicy_To_networking_NetworkPolicy(in *NetworkPolicy, out *networking.NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + return nil +} + +// Convert_v1_NetworkPolicy_To_networking_NetworkPolicy is an autogenerated conversion function. +func Convert_v1_NetworkPolicy_To_networking_NetworkPolicy(in *NetworkPolicy, out *networking.NetworkPolicy, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicy_To_networking_NetworkPolicy(in, out, s) +} + +func autoConvert_networking_NetworkPolicy_To_v1_NetworkPolicy(in *networking.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + return nil +} + +// Convert_networking_NetworkPolicy_To_v1_NetworkPolicy is an autogenerated conversion function. +func Convert_networking_NetworkPolicy_To_v1_NetworkPolicy(in *networking.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicy_To_v1_NetworkPolicy(in, out, s) +} + +func autoConvert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(in *NetworkPolicyIngressRule, out *networking.NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = *(*[]networking.NetworkPolicyPort)(unsafe.Pointer(&in.Ports)) + out.From = *(*[]networking.NetworkPolicyPeer)(unsafe.Pointer(&in.From)) + return nil +} + +// Convert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule is an autogenerated conversion function. +func Convert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(in *NetworkPolicyIngressRule, out *networking.NetworkPolicyIngressRule, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(in, out, s) +} + +func autoConvert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(in *networking.NetworkPolicyIngressRule, out *NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = *(*[]NetworkPolicyPort)(unsafe.Pointer(&in.Ports)) + out.From = *(*[]NetworkPolicyPeer)(unsafe.Pointer(&in.From)) + return nil +} + +// Convert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule is an autogenerated conversion function. +func Convert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(in *networking.NetworkPolicyIngressRule, out *NetworkPolicyIngressRule, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(in, out, s) +} + +func autoConvert_v1_NetworkPolicyList_To_networking_NetworkPolicyList(in *NetworkPolicyList, out *networking.NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]networking.NetworkPolicy)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1_NetworkPolicyList_To_networking_NetworkPolicyList is an autogenerated conversion function. +func Convert_v1_NetworkPolicyList_To_networking_NetworkPolicyList(in *NetworkPolicyList, out *networking.NetworkPolicyList, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicyList_To_networking_NetworkPolicyList(in, out, s) +} + +func autoConvert_networking_NetworkPolicyList_To_v1_NetworkPolicyList(in *networking.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]NetworkPolicy, 0) + } else { + out.Items = *(*[]NetworkPolicy)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_networking_NetworkPolicyList_To_v1_NetworkPolicyList is an autogenerated conversion function. +func Convert_networking_NetworkPolicyList_To_v1_NetworkPolicyList(in *networking.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicyList_To_v1_NetworkPolicyList(in, out, s) +} + +func autoConvert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(in *NetworkPolicyPeer, out *networking.NetworkPolicyPeer, s conversion.Scope) error { + out.PodSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.PodSelector)) + out.NamespaceSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.NamespaceSelector)) + return nil +} + +// Convert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer is an autogenerated conversion function. +func Convert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(in *NetworkPolicyPeer, out *networking.NetworkPolicyPeer, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(in, out, s) +} + +func autoConvert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(in *networking.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { + out.PodSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.PodSelector)) + out.NamespaceSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.NamespaceSelector)) + return nil +} + +// Convert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer is an autogenerated conversion function. +func Convert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(in *networking.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(in, out, s) +} + +func autoConvert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort(in *NetworkPolicyPort, out *networking.NetworkPolicyPort, s conversion.Scope) error { + out.Protocol = (*api.Protocol)(unsafe.Pointer(in.Protocol)) + out.Port = (*intstr.IntOrString)(unsafe.Pointer(in.Port)) + return nil +} + +// Convert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort is an autogenerated conversion function. +func Convert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort(in *NetworkPolicyPort, out *networking.NetworkPolicyPort, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort(in, out, s) +} + +func autoConvert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort(in *networking.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { + out.Protocol = (*api_v1.Protocol)(unsafe.Pointer(in.Protocol)) + out.Port = (*intstr.IntOrString)(unsafe.Pointer(in.Port)) + return nil +} + +// Convert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort is an autogenerated conversion function. +func Convert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort(in *networking.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort(in, out, s) +} + +func autoConvert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec(in *NetworkPolicySpec, out *networking.NetworkPolicySpec, s conversion.Scope) error { + out.PodSelector = in.PodSelector + out.Ingress = *(*[]networking.NetworkPolicyIngressRule)(unsafe.Pointer(&in.Ingress)) + return nil +} + +// Convert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec is an autogenerated conversion function. +func Convert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec(in *NetworkPolicySpec, out *networking.NetworkPolicySpec, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec(in, out, s) +} + +func autoConvert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec(in *networking.NetworkPolicySpec, out *NetworkPolicySpec, s conversion.Scope) error { + out.PodSelector = in.PodSelector + out.Ingress = *(*[]NetworkPolicyIngressRule)(unsafe.Pointer(&in.Ingress)) + return nil +} + +// Convert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec is an autogenerated conversion function. +func Convert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec(in *networking.NetworkPolicySpec, out *NetworkPolicySpec, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec(in, out, s) +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.deepcopy.go b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.deepcopy.go new file mode 100644 index 0000000000000..6d9b335d4289d --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.deepcopy.go @@ -0,0 +1,182 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" + api_v1 "k8s.io/client-go/pkg/api/v1" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicy, InType: reflect.TypeOf(&NetworkPolicy{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicyIngressRule, InType: reflect.TypeOf(&NetworkPolicyIngressRule{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicyList, InType: reflect.TypeOf(&NetworkPolicyList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicyPeer, InType: reflect.TypeOf(&NetworkPolicyPeer{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicyPort, InType: reflect.TypeOf(&NetworkPolicyPort{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicySpec, InType: reflect.TypeOf(&NetworkPolicySpec{})}, + ) +} + +// DeepCopy_v1_NetworkPolicy is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicy(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicy) + out := out.(*NetworkPolicy) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) + } + if err := DeepCopy_v1_NetworkPolicySpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicyIngressRule is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicyIngressRule(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyIngressRule) + out := out.(*NetworkPolicyIngressRule) + *out = *in + if in.Ports != nil { + in, out := &in.Ports, &out.Ports + *out = make([]NetworkPolicyPort, len(*in)) + for i := range *in { + if err := DeepCopy_v1_NetworkPolicyPort(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.From != nil { + in, out := &in.From, &out.From + *out = make([]NetworkPolicyPeer, len(*in)) + for i := range *in { + if err := DeepCopy_v1_NetworkPolicyPeer(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicyList is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicyList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyList) + out := out.(*NetworkPolicyList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]NetworkPolicy, len(*in)) + for i := range *in { + if err := DeepCopy_v1_NetworkPolicy(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicyPeer is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicyPeer(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyPeer) + out := out.(*NetworkPolicyPeer) + *out = *in + if in.PodSelector != nil { + in, out := &in.PodSelector, &out.PodSelector + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*meta_v1.LabelSelector) + } + } + if in.NamespaceSelector != nil { + in, out := &in.NamespaceSelector, &out.NamespaceSelector + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*meta_v1.LabelSelector) + } + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicyPort is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicyPort(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyPort) + out := out.(*NetworkPolicyPort) + *out = *in + if in.Protocol != nil { + in, out := &in.Protocol, &out.Protocol + *out = new(api_v1.Protocol) + **out = **in + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(intstr.IntOrString) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicySpec is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicySpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicySpec) + out := out.(*NetworkPolicySpec) + *out = *in + if newVal, err := c.DeepCopy(&in.PodSelector); err != nil { + return err + } else { + out.PodSelector = *newVal.(*meta_v1.LabelSelector) + } + if in.Ingress != nil { + in, out := &in.Ingress, &out.Ingress + *out = make([]NetworkPolicyIngressRule, len(*in)) + for i := range *in { + if err := DeepCopy_v1_NetworkPolicyIngressRule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.defaults.go b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.defaults.go new file mode 100644 index 0000000000000..0319c88a76f7d --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.defaults.go @@ -0,0 +1,51 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + scheme.AddTypeDefaultingFunc(&NetworkPolicy{}, func(obj interface{}) { SetObjectDefaults_NetworkPolicy(obj.(*NetworkPolicy)) }) + scheme.AddTypeDefaultingFunc(&NetworkPolicyList{}, func(obj interface{}) { SetObjectDefaults_NetworkPolicyList(obj.(*NetworkPolicyList)) }) + return nil +} + +func SetObjectDefaults_NetworkPolicy(in *NetworkPolicy) { + for i := range in.Spec.Ingress { + a := &in.Spec.Ingress[i] + for j := range a.Ports { + b := &a.Ports[j] + SetDefaults_NetworkPolicyPort(b) + } + } +} + +func SetObjectDefaults_NetworkPolicyList(in *NetworkPolicyList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_NetworkPolicy(a) + } +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/networking/zz_generated.deepcopy.go b/staging/src/k8s.io/client-go/pkg/apis/networking/zz_generated.deepcopy.go new file mode 100644 index 0000000000000..802868447c431 --- /dev/null +++ b/staging/src/k8s.io/client-go/pkg/apis/networking/zz_generated.deepcopy.go @@ -0,0 +1,182 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package networking + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" + api "k8s.io/client-go/pkg/api" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicy, InType: reflect.TypeOf(&NetworkPolicy{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicyIngressRule, InType: reflect.TypeOf(&NetworkPolicyIngressRule{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicyList, InType: reflect.TypeOf(&NetworkPolicyList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicyPeer, InType: reflect.TypeOf(&NetworkPolicyPeer{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicyPort, InType: reflect.TypeOf(&NetworkPolicyPort{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicySpec, InType: reflect.TypeOf(&NetworkPolicySpec{})}, + ) +} + +// DeepCopy_networking_NetworkPolicy is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicy(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicy) + out := out.(*NetworkPolicy) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if err := DeepCopy_networking_NetworkPolicySpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicyIngressRule is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicyIngressRule(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyIngressRule) + out := out.(*NetworkPolicyIngressRule) + *out = *in + if in.Ports != nil { + in, out := &in.Ports, &out.Ports + *out = make([]NetworkPolicyPort, len(*in)) + for i := range *in { + if err := DeepCopy_networking_NetworkPolicyPort(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.From != nil { + in, out := &in.From, &out.From + *out = make([]NetworkPolicyPeer, len(*in)) + for i := range *in { + if err := DeepCopy_networking_NetworkPolicyPeer(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicyList is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicyList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyList) + out := out.(*NetworkPolicyList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]NetworkPolicy, len(*in)) + for i := range *in { + if err := DeepCopy_networking_NetworkPolicy(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicyPeer is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicyPeer(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyPeer) + out := out.(*NetworkPolicyPeer) + *out = *in + if in.PodSelector != nil { + in, out := &in.PodSelector, &out.PodSelector + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*v1.LabelSelector) + } + } + if in.NamespaceSelector != nil { + in, out := &in.NamespaceSelector, &out.NamespaceSelector + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*v1.LabelSelector) + } + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicyPort is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicyPort(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyPort) + out := out.(*NetworkPolicyPort) + *out = *in + if in.Protocol != nil { + in, out := &in.Protocol, &out.Protocol + *out = new(api.Protocol) + **out = **in + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(intstr.IntOrString) + **out = **in + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicySpec is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicySpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicySpec) + out := out.(*NetworkPolicySpec) + *out = *in + if newVal, err := c.DeepCopy(&in.PodSelector); err != nil { + return err + } else { + out.PodSelector = *newVal.(*v1.LabelSelector) + } + if in.Ingress != nil { + in, out := &in.Ingress, &out.Ingress + *out = make([]NetworkPolicyIngressRule, len(*in)) + for i := range *in { + if err := DeepCopy_networking_NetworkPolicyIngressRule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} diff --git a/staging/src/k8s.io/client-go/pkg/apis/policy/BUILD b/staging/src/k8s.io/client-go/pkg/apis/policy/BUILD index 2650813d5fd3c..3fce625945b2a 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/policy/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/policy/BUILD @@ -16,10 +16,6 @@ go_library( "zz_generated.deepcopy.go", ], tags = ["automanaged"], - visibility = [ - "//vendor/k8s.io/client-go/pkg/api/v1:__pkg__", - "//vendor/k8s.io/client-go/pkg/apis:__subpackages__", - ], deps = [ "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/policy/install/BUILD b/staging/src/k8s.io/client-go/pkg/apis/policy/install/BUILD index 287bf66e5bd6d..5cb7b9bebcbff 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/policy/install/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/policy/install/BUILD @@ -11,7 +11,6 @@ go_library( name = "go_default_library", srcs = ["install.go"], tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.pb.go index a4922f455c63a..50367855c9a06 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.pb.go @@ -1394,56 +1394,55 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 805 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x94, 0xdf, 0x6e, 0xe3, 0x44, - 0x14, 0xc6, 0xe3, 0xa6, 0x29, 0x65, 0x36, 0x89, 0xca, 0xc0, 0x42, 0x89, 0x84, 0x83, 0x72, 0xb5, - 0x8b, 0x60, 0x4c, 0x77, 0x11, 0x2a, 0x5c, 0xac, 0x58, 0x93, 0x0a, 0x16, 0x6d, 0xd5, 0xd5, 0x14, - 0x84, 0x84, 0x40, 0x62, 0x6c, 0x9f, 0x75, 0x87, 0x8c, 0xff, 0x68, 0x3c, 0x0e, 0xcd, 0x1d, 0x8f, - 0xc0, 0x05, 0x0f, 0x55, 0x09, 0x09, 0xed, 0x25, 0x42, 0x28, 0xa2, 0xe6, 0x19, 0xb8, 0x47, 0x1e, - 0x4f, 0x9a, 0xb8, 0x49, 0xb4, 0x81, 0x22, 0xee, 0x3c, 0x33, 0xe7, 0xf7, 0x7d, 0xe7, 0x9c, 0x39, - 0x63, 0xf4, 0xc1, 0xe8, 0x30, 0x23, 0x3c, 0x71, 0x46, 0xb9, 0x07, 0x32, 0x06, 0x05, 0x99, 0x93, - 0x8e, 0x42, 0x87, 0xa5, 0x3c, 0x73, 0xd2, 0x44, 0x70, 0x7f, 0xe2, 0x8c, 0x0f, 0x3c, 0x50, 0xec, - 0xc0, 0x09, 0x21, 0x06, 0xc9, 0x14, 0x04, 0x24, 0x95, 0x89, 0x4a, 0xf0, 0xdd, 0x0a, 0x25, 0x73, - 0x94, 0xa4, 0xa3, 0x90, 0x94, 0x28, 0xa9, 0x50, 0x62, 0xd0, 0xde, 0x3b, 0x21, 0x57, 0x67, 0xb9, - 0x47, 0xfc, 0x24, 0x72, 0xc2, 0x24, 0x4c, 0x1c, 0xad, 0xe0, 0xe5, 0x4f, 0xf5, 0x4a, 0x2f, 0xf4, - 0x57, 0xa5, 0xdc, 0x7b, 0xcf, 0x24, 0xc5, 0x52, 0x1e, 0x31, 0xff, 0x8c, 0xc7, 0x20, 0x27, 0xf3, - 0xb4, 0x22, 0x50, 0xcc, 0x19, 0x2f, 0xe5, 0xd3, 0x73, 0xd6, 0x51, 0x32, 0x8f, 0x15, 0x8f, 0x60, - 0x09, 0x78, 0xff, 0x79, 0x40, 0xe6, 0x9f, 0x41, 0xc4, 0x96, 0xb8, 0xfb, 0xeb, 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0xed, 0xc6, 0xaf, 0x97, 0x76, - 0xe3, 0x87, 0xc2, 0xb6, 0x2e, 0x0a, 0xdb, 0x7a, 0x56, 0xd8, 0xd6, 0x1f, 0x85, 0x6d, 0xfd, 0xf8, - 0xa7, 0xdd, 0xf8, 0xea, 0x05, 0x73, 0xe9, 0x7f, 0x07, 0x00, 0x00, 0xff, 0xff, 0xc4, 0xc0, 0x72, - 0x96, 0xcb, 0x08, 0x00, 0x00, + // 787 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x94, 0x4b, 0x6f, 0xeb, 0x44, + 0x14, 0xc7, 0xe3, 0x3c, 0x4a, 0x98, 0x9b, 0x44, 0x65, 0xe0, 0x42, 0x88, 0x84, 0x83, 0xb2, 0xba, + 0x17, 0xc1, 0x98, 0xde, 0x8b, 0x50, 0x61, 0x51, 0x51, 0x93, 0x0a, 0x8a, 0x1a, 0xa5, 0x9a, 0x82, + 0x90, 0x10, 0x48, 0x8c, 0xed, 0x53, 0x67, 0x88, 0x5f, 0xb2, 0xc7, 0xa1, 0xd9, 0xf1, 0x11, 0x58, + 0xf0, 0xa1, 0x2a, 0x21, 0xa1, 0x2e, 0x11, 0x42, 0x11, 0x35, 0x9f, 0x81, 0x3d, 0xb2, 0x3d, 0x79, + 0xb8, 0x49, 0xd4, 0x40, 0x11, 0xbb, 0xcc, 0xe3, 0xf7, 0xff, 0x9f, 0xf3, 0xf7, 0x99, 0xa0, 0x0f, + 0xc6, 0x87, 0x11, 0xe1, 0xbe, 0x36, 0x8e, 0x0d, 0x08, 0x3d, 0x10, 0x10, 0x69, 0xc1, 0xd8, 0xd6, + 0x58, 0xc0, 0x23, 0x2d, 0xf0, 0x1d, 0x6e, 0x4e, 0xb5, 0xc9, 0x81, 0x01, 0x82, 0x1d, 0x68, 0x36, + 0x78, 0x10, 0x32, 0x01, 0x16, 0x09, 0x42, 0x5f, 0xf8, 0xf8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x03, 0xae, 0x02, 0x30, 0xe7, 0x19, 0xef, + 0x65, 0xf4, 0x2b, 0x92, 0x6e, 0x9c, 0xac, 0x9c, 0xd1, 0xc2, 0xcd, 0x8e, 0x83, 0xf0, 0x7a, 0x88, + 0x78, 0x1f, 0x55, 0xc6, 0x30, 0xcd, 0x3e, 0xf9, 0x8b, 0x34, 0xfd, 0x89, 0x3f, 0x42, 0xb5, 0x09, + 0x73, 0x62, 0x90, 0xb3, 0xff, 0xd6, 0x6e, 0xb3, 0xff, 0x39, 0x77, 0x81, 0xe6, 0xe0, 0x87, 0xe5, + 0x43, 0x45, 0x7f, 0x7a, 0x7d, 0xab, 0x96, 0x6e, 0x6e, 0xd5, 0xd2, 0xaf, 0xb7, 0x6a, 0xe9, 0x87, + 0x44, 0x55, 0xae, 0x13, 0x55, 0xb9, 0x49, 0x54, 0xe5, 0x8f, 0x44, 0x55, 0x7e, 0xfc, 0x53, 0x2d, + 0x7d, 0xf5, 0x82, 0xfc, 0xe8, 0x7f, 0x07, 0x00, 0x00, 0xff, 0xff, 0xff, 0x18, 0xbb, 0x8c, 0x95, + 0x08, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.proto index 3350c06c39c66..1cdde5a183d42 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.proto @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.policy.v1beta1; +package k8s.io.client_go.pkg.apis.policy.v1beta1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; // Package-wide variables from generator "generated". diff --git a/staging/src/k8s.io/client-go/pkg/apis/rbac/BUILD b/staging/src/k8s.io/client-go/pkg/apis/rbac/BUILD index 1da25cf5a62af..2825eb324bfb2 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/rbac/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/rbac/BUILD @@ -17,10 +17,6 @@ go_library( "zz_generated.deepcopy.go", ], tags = ["automanaged"], - visibility = [ - "//vendor/k8s.io/client-go/pkg/api/v1:__pkg__", - "//vendor/k8s.io/client-go/pkg/apis:__subpackages__", - ], deps = [ "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/rbac/install/BUILD b/staging/src/k8s.io/client-go/pkg/apis/rbac/install/BUILD index bb5aa3b730dd3..97d0df565429c 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/rbac/install/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/rbac/install/BUILD @@ -11,7 +11,6 @@ go_library( name = "go_default_library", srcs = ["install.go"], tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.pb.go index 21b9000a674a9..af7640d873b20 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.pb.go @@ -2766,58 +2766,57 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 841 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x54, 0x4d, 0x6f, 0xe3, 0x44, - 0x18, 0xce, 0xb4, 0x09, 0x4d, 0xde, 0x52, 0x95, 0x0e, 0x12, 0x32, 0x3d, 0x38, 0x95, 0x4f, 0x15, + // 826 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x54, 0xcf, 0x6f, 0xe3, 0x44, + 0x14, 0xce, 0xb4, 0x09, 0x4d, 0x5e, 0xa9, 0x4a, 0x07, 0x09, 0x99, 0x1e, 0x9c, 0xca, 0xa7, 0x8a, 0x1f, 0x36, 0x2d, 0x0b, 0xec, 0x01, 0x0e, 0x6b, 0x0e, 0xa8, 0x62, 0x29, 0xd5, 0xac, 0x58, 0x89, - 0xd5, 0x4a, 0x30, 0x71, 0x66, 0x93, 0x21, 0xfe, 0xd2, 0x8c, 0x1d, 0xb1, 0x42, 0x48, 0x1c, 0x39, - 0xf2, 0x2b, 0x38, 0x72, 0x40, 0xe2, 0xc8, 0x89, 0x4b, 0x05, 0x97, 0x1e, 0xe1, 0x12, 0x51, 0xf3, - 0x43, 0x40, 0x1e, 0x8f, 0x3f, 0x8a, 0x53, 0xf5, 0x03, 0x29, 0x12, 0xd2, 0x9e, 0x12, 0xbf, 0xef, - 0xf3, 0x3c, 0xf3, 0x3e, 0xf3, 0xda, 0x0f, 0xdc, 0x9d, 0xdd, 0x95, 0x36, 0x8f, 0x9c, 0x59, 0x3a, - 0x62, 0x22, 0x64, 0x09, 0x93, 0x4e, 0x3c, 0x9b, 0x38, 0x34, 0xe6, 0xd2, 0x11, 0x23, 0xea, 0x39, - 0xf3, 0x03, 0xea, 0xc7, 0x53, 0x7a, 0xe0, 0x4c, 0x58, 0xc8, 0x04, 0x4d, 0xd8, 0xd8, 0x8e, 0x45, - 0x94, 0x44, 0x78, 0xbf, 0x60, 0xda, 0x35, 0xd3, 0x8e, 0x67, 0x13, 0x3b, 0x67, 0x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ca, - 0x8c, 0x23, 0x15, 0x02, 0xef, 0x41, 0x77, 0xc6, 0xc3, 0xb1, 0xb1, 0xa6, 0x90, 0xcf, 0x6b, 0x64, - 0xf7, 0x43, 0x1e, 0x8e, 0x89, 0xea, 0xe4, 0x88, 0x90, 0x06, 0x4c, 0xbd, 0x43, 0x0d, 0x44, 0x1e, - 0x5d, 0x44, 0x75, 0xac, 0x1f, 0x11, 0x6c, 0xe8, 0xf7, 0xaf, 0xd2, 0x43, 0x97, 0xea, 0x1d, 0x02, - 0xd0, 0x98, 0x3f, 0x64, 0x42, 0xf2, 0x28, 0xd4, 0xe7, 0x56, 0x5f, 0xca, 0xbd, 0x93, 0x23, 0xdd, - 0x21, 0x0d, 0xd4, 0xd5, 0x33, 0x60, 0x07, 0x06, 0xf9, 0xaf, 0x8c, 0xa9, 0xc7, 0x8c, 0xae, 0x82, - 0xed, 0x68, 0xd8, 0xe0, 0xb8, 0x6c, 0x90, 0x1a, 0xe3, 0xbe, 0x72, 0x7a, 0x6e, 0x76, 0xce, 0xce, - 0xcd, 0xce, 0xef, 0xe7, 0x66, 0xe7, 0x9b, 0xcc, 0x44, 0xa7, 0x99, 0x89, 0xce, 0x32, 0x13, 0xfd, - 0x99, 0x99, 0xe8, 0xbb, 0xbf, 0xcc, 0xce, 0xa3, 0x7e, 0x79, 0xf1, 0xff, 0x04, 0x00, 0x00, 0xff, - 0xff, 0x22, 0x38, 0x96, 0xd3, 0x59, 0x0c, 0x00, 0x00, + 0xd5, 0x4a, 0x30, 0x71, 0x66, 0x93, 0x21, 0xfe, 0xa5, 0x19, 0x3b, 0xd2, 0x0a, 0x21, 0x71, 0xe4, + 0xc8, 0x5f, 0xc1, 0x91, 0x03, 0x12, 0x47, 0x4e, 0x5c, 0x2a, 0xb8, 0xec, 0x11, 0x2e, 0x11, 0x35, + 0x7f, 0x08, 0xc8, 0xe3, 0xf1, 0x8f, 0x34, 0xa9, 0x9a, 0x16, 0x29, 0x12, 0xd2, 0x9e, 0x12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ff --git a/staging/src/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.proto index 75302176c3aec..ba462c669f815 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.proto @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.rbac.v1alpha1; +package k8s.io.client_go.pkg.apis.rbac.v1alpha1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1alpha1"; diff --git a/staging/src/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.pb.go index 5078deff67026..978d74b81ba14 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.pb.go @@ -2766,57 +2766,56 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 824 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x54, 0xbf, 0x8f, 0xe3, 0x44, - 0x18, 0xcd, 0x64, 0x13, 0x6d, 0x3c, 0x4b, 0x14, 0x76, 0x90, 0x90, 0x49, 0xe1, 0x44, 0x6e, 0x58, - 0x04, 0x67, 0xdf, 0xde, 0x9d, 0x38, 0x24, 0x44, 0x81, 0x29, 0xd0, 0x89, 0x63, 0x39, 0x0d, 0x02, - 0xf1, 0x4b, 0xe8, 0x26, 0xce, 0x9c,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f, 0x18, 0x9d, 0xef, 0x52, 0x03, 0x9c, 0xa5, 0x06, 0x78, 0x9a, 0x1a, 0xe0, 0xf7, 0xd4, - 0x00, 0x3f, 0xfc, 0x61, 0x74, 0x3e, 0xdb, 0x57, 0x2f, 0xfe, 0x57, 0x00, 0x00, 0x00, 0xff, 0xff, - 0x2d, 0xfe, 0x9c, 0x61, 0x44, 0x0c, 0x00, 0x00, + // 804 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x54, 0x4b, 0x6f, 0xf3, 0x44, + 0x14, 0xcd, 0xe4, 0xa1, 0xc4, 0x13, 0xa2, 0xd0, 0x41, 0x42, 0x26, 0x0b, 0x27, 0xf2, 0x86, 0x22, + 0xf8, 0xec, 0xbe, 0x44, 0x91, 0x10, 0x0b, 0xcc, 0x02, 0x55, 0x94, 0x52, 0x0d, 0x02, 0xf1, 0x12, + 0xaa, 0xe3, 0x4c, 0xdd, 0x21, 0x7e, 0xc9, 0x33, 0x8e, 0x54, 0xc1, 0x82, 0x1d, 0x5b, 0xfe, 0x04, + 0xbb, 0xee, 0xd8, 0xb2, 0x62, 0x55, 0x58, 0x75, 0xd9, 0x55, 0x44, 0xcd, 0x0f, 0x01, 0xd9, 0x1e, + 0x3f, 0xd2, 0xa4, 0x34, 0x14, 0x29, 0x12, 0xd2, 0xb7, 0x6a, 0xe7, 0xde, 0x73, 0xce, 0xdc, 0x33, + 0xd7, 0x39, 0xf0, 0x70, 0xfa, 0x16, 0xd3, 0xa8, 0xaf, 0x4f, 0xa3, 0x31, 0x09, 0x3d, 0xc2, 0x09, + 0xd3, 0x83, 0xa9, 0xad, 0x9b, 0x01, 0x65, 0x7a, 0x38, 0x36, 0x2d, 0x7d, 0xb6, 0x3b, 0x26, 0xdc, + 0xdc, 0xd5, 0x6d, 0xe2, 0x91, 0xd0, 0xe4, 0x64, 0xa2, 0x05, 0xa1, 0xcf, 0x7d,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0, + 0x39, 0xa5, 0xde, 0x44, 0xae, 0xa7, 0xc8, 0x17, 0x04, 0xb2, 0xf9, 0x01, 0xf5, 0x26, 0x38, 0xed, + 0x24, 0x08, 0xcf, 0x74, 0x49, 0xfa, 0x01, 0x55, 0x10, 0x49, 0x68, 0xe1, 0xb4, 0xa3, 0x5e, 0x01, + 0xd8, 0x16, 0x1f, 0x5f, 0xa1, 0x07, 0x1e, 0xd4, 0xab, 0xce, 0x57, 0x5f, 0x67, 0xbe, 0x7f, 0xbe, + 0x1d, 0xe9, 0x50, 0x4a, 0xfe, 0xb2, 0xc0, 0xb4, 0x88, 0xdc, 0x4c, 0x61, 0x5b, 0x02, 0x26, 0x9d, + 0xe4, 0x0d, 0x5c, 0x62, 0x8c, 0xd7, 0xae, 0xef, 0x94, 0xda, 0xcd, 0x9d, 0x52, 0xbb, 0xbd, 0x53, + 0x6a, 0xdf, 0xc7, 0x0a, 0xb8, 0x8e, 0x15, 0x70, 0x13, 0x2b, 0xe0, 0x8f, 0x58, 0x01, 0x3f, 0xfe, + 0xa9, 0xd4, 0xbe, 0x68, 0x8b, 0x17, 0xff, 0x3b, 0x00, 0x00, 0xff, 0xff, 0x98, 0x18, 0x7e, 0x05, + 0x0e, 0x0c, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.proto index b18fc0fd95352..d4a6ebcf66820 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.proto @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.rbac.v1beta1; +package k8s.io.client_go.pkg.apis.rbac.v1beta1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; diff --git a/staging/src/k8s.io/client-go/pkg/apis/settings/BUILD b/staging/src/k8s.io/client-go/pkg/apis/settings/BUILD index b896f3531ff23..f0ff3f2ce1f4a 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/settings/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/settings/BUILD @@ -16,10 +16,6 @@ go_library( "zz_generated.deepcopy.go", ], tags = ["automanaged"], - visibility = [ - "//vendor/k8s.io/client-go/pkg/api/v1:__pkg__", - "//vendor/k8s.io/client-go/pkg/apis:__subpackages__", - ], deps = [ "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/settings/install/BUILD b/staging/src/k8s.io/client-go/pkg/apis/settings/install/BUILD index f23b5047e21f1..9289ee74d9356 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/settings/install/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/settings/install/BUILD @@ -11,7 +11,6 @@ go_library( name = "go_default_library", srcs = ["install.go"], tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.pb.go index d3f49e55bfcd3..7b601b5af1392 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.pb.go @@ -891,40 +891,39 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 550 bytes of a gzipped FileDescriptorProto + // 535 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x92, 0x41, 0x8b, 0xd3, 0x40, - 0x14, 0xc7, 0x9b, 0x6d, 0x4b, 0xeb, 0xb4, 0x8b, 0x12, 0x3c, 0x84, 0x1e, 0xb2, 0x4b, 0xf1, 0xb0, - 0xea, 0x3a, 0xb1, 0xab, 0xa8, 0xa0, 0xa7, 0xc8, 0x0a, 0x82, 0xcb, 0x2e, 0x29, 0xf4, 0x20, 0x2b, - 0x38, 0x4d, 0x9f, 0x69, 0x6c, 0x93, 0x09, 0x33, 0x93, 0xa0, 0x37, 0x3f, 0x82, 0x5f, 0x4a, 0x28, - 0xe8, 0x61, 0x8f, 0x9e, 0x16, 0x5b, 0xbf, 0x88, 0xcc, 0x74, 0xd2, 0x44, 0xba, 0x65, 0xab, 0xb7, - 0x79, 0x8f, 0xf7, 0xff, 0xbd, 0xff, 0x3f, 0x2f, 0xe8, 0xc5, 0xe4, 0x19, 0xc7, 0x21, 0x75, 0x26, - 0xe9, 0x10, 0x58, 0x0c, 0x02, 0xb8, 0x93, 0x4c, 0x02, 0x87, 0x24, 0x21, 0x77, 0x38, 0x08, 0x11, - 0xc6, 0x01, 0x77, 0xb2, 0x1e, 0x99, 0x26, 0x63, 0xd2, 0x73, 0x02, 0x88, 0x81, 0x11, 0x01, 0x23, - 0x9c, 0x30, 0x2a, 0xa8, 0x79, 0xb8, 0x54, 0xe3, 0x42, 0x8d, 0x93, 0x49, 0x80, 0xa5, 0x1a, 0xe7, - 0x6a, 0x9c, 0xab, 0x3b, 0x0f, 0x82, 0x50, 0x8c, 0xd3, 0x21, 0xf6, 0x69, 0xe4, 0x04, 0x34, 0xa0, - 0x8e, 0x82, 0x0c, 0xd3, 0x0f, 0xaa, 0x52, 0x85, 0x7a, 0x2d, 0xe1, 0x9d, 0xc7, 0xda, 0x1a, 0x49, - 0xc2, 0x88, 0xf8, 0xe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91, 0x84, - 0x03, 0x10, 0x2f, 0x05, 0x00, 0x00, + 0x14, 0xc7, 0x9b, 0xed, 0x96, 0xd6, 0x69, 0x17, 0x25, 0x78, 0x08, 0x3d, 0x64, 0x97, 0xe2, 0x61, + 0xd5, 0x75, 0x62, 0x57, 0x51, 0x41, 0x4f, 0x91, 0x15, 0x04, 0x97, 0x5d, 0x52, 0xe8, 0x41, 0x56, + 0x70, 0x9a, 0x3e, 0xd3, 0xd8, 0x66, 0x26, 0xcc, 0x4c, 0x02, 0xde, 0xfc, 0x08, 0x7e, 0x29, 0xa1, + 0xa0, 0x87, 0x3d, 0x7a, 0x5a, 0x6c, 0xfd, 0x22, 0x32, 0xd3, 0x49, 0x53, 0xa9, 0x65, 0xab, 0xb7, + 0x79, 0x8f, 0xf7, 0xff, 0xbd, 0xff, 0xff, 0x25, 0xe8, 0xc5, 0xf8, 0x99, 0xc0, 0x31, 0xf3, 0xc6, + 0xd9, 0x00, 0x38, 0x05, 0x09, 0xc2, 0x4b, 0xc7, 0x91, 0x47, 0xd2, 0x58, 0x78, 0x02, 0xa4, 0x8c, + 0x69, 0x24, 0xbc, 0xbc, 0x4b, 0x26, 0xe9, 0x88, 0x74, 0xbd, 0x08, 0x28, 0x70, 0x22, 0x61, 0x88, + 0x53, 0xce, 0x24, 0xb3, 0x8f, 0x16, 0x6a, 0x5c, 0xaa, 0x71, 0x3a, 0x8e, 0xb0, 0x52, 0xe3, 0x42, + 0x8d, 0x0b, 0x75, 0xfb, 0x41, 0x14, 0xcb, 0x51, 0x36, 0xc0, 0x21, 0x4b, 0xbc, 0x88, 0x45, 0xcc, + 0xd3, 0x90, 0x41, 0xf6, 0x41, 0x57, 0xba, 0xd0, 0xaf, 0x05, 0xbc, 0xfd, 0xd8, 0x58, 0x23, 0x69, + 0x9c, 0x90, 0x70, 0x14, 0x53, 0xe0, 0x9f, 0x4a, 0x73, 0x09, 0x48, 0xe2, 0xe5, 0x6b, 0x96, 0xda, + 0xde, 0x26, 0x15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60, 0xd2, 0x33, 0xd2, 0x32, 0x52, 0xd1, 0x09, + 0x96, 0x58, 0xfb, 0x25, 0xaa, 0x02, 0xcd, 0x4d, 0xa0, 0x3b, 0x9b, 0x03, 0x29, 0xea, 0x09, 0xcd, + 0xfb, 0x84, 0xfb, 0x4d, 0x83, 0xab, 0x9e, 0xd0, 0x3c, 0x50, 0x6a, 0xbb, 0x8f, 0xea, 0x40, 0xf3, + 0x57, 0x9c, 0x25, 0x4e, 0x55, 0x83, 0xee, 0x5f, 0x0b, 0x52, 0xc3, 0x3d, 0x96, 0xf1, 0x10, 0xfc, + 0x9b, 0x86, 0x57, 0x37, 0xed, 0xa0, 0x80, 0xd9, 0x67, 0xa8, 0x9e, 0xb3, 0x49, 0x96, 0x80, 0x70, + 0x76, 0xb7, 0x31, 0xd8, 0xd7, 0xc3, 0x25, 0x70, 0x51, 0x8b, 0xa0, 0xa0, 0xd8, 0x21, 0x6a, 0x2d, + 0x9e, 0xa7, 0x2c, 0xa3, 0x52, 0x38, 0x35, 0x4d, 0xbd, 0xbb, 0x0d, 0x55, 0x2b, 0xfc, 0xdb, 0x06, + 0xdd, 0x5a, 0x69, 0x8a, 0xe0, 0x0f, 0xa8, 0x7f, 0x6f, 0x3a, 0x73, 0x2b, 0x97, 0x33, 0xb7, 0xf2, + 0x63, 0xe6, 0x56, 0x3e, 0xcf, 0x5d, 0x6b, 0x3a, 0x77, 0xad, 0xcb, 0xb9, 0x6b, 0xfd, 0x9c, 0xbb, + 0xd6, 0x97, 0x5f, 0x6e, 0xe5, 0x6d, 0xa3, 0xf8, 0x27, 0x7e, 0x07, 0x00, 0x00, 0xff, 0xff, 0xe9, + 0x9c, 0x18, 0x84, 0xf9, 0x04, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.proto index c27c921f7aeb5..e75537827718c 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.proto @@ -19,12 +19,11 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.settings.v1alpha1; +package k8s.io.client_go.pkg.apis.settings.v1alpha1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; // Package-wide variables from generator "generated". @@ -59,18 +58,18 @@ message PodPresetSpec { // Env defines the collection of EnvVar to inject into containers. // +optional - repeated k8s.io.kubernetes.pkg.api.v1.EnvVar env = 2; + repeated k8s.io.client_go.pkg.api.v1.EnvVar env = 2; // EnvFrom defines the collection of EnvFromSource to inject into containers. // +optional - repeated k8s.io.kubernetes.pkg.api.v1.EnvFromSource envFrom = 3; + repeated k8s.io.client_go.pkg.api.v1.EnvFromSource envFrom = 3; // Volumes defines the collection of Volume to inject into the pod. // +optional - repeated k8s.io.kubernetes.pkg.api.v1.Volume volumes = 4; + repeated k8s.io.client_go.pkg.api.v1.Volume volumes = 4; // VolumeMounts defines the collection of VolumeMount to inject into containers. // +optional - repeated k8s.io.kubernetes.pkg.api.v1.VolumeMount volumeMounts = 5; + repeated k8s.io.client_go.pkg.api.v1.VolumeMount volumeMounts = 5; } diff --git a/staging/src/k8s.io/client-go/pkg/apis/storage/BUILD b/staging/src/k8s.io/client-go/pkg/apis/storage/BUILD index c6619824914a5..6e2604388adbe 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/storage/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/storage/BUILD @@ -16,10 +16,6 @@ go_library( "zz_generated.deepcopy.go", ], tags = ["automanaged"], - visibility = [ - "//vendor/k8s.io/client-go/pkg/api/v1:__pkg__", - "//vendor/k8s.io/client-go/pkg/apis:__subpackages__", - ], deps = [ "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/storage/install/BUILD b/staging/src/k8s.io/client-go/pkg/apis/storage/install/BUILD index c99ddaaddef37..2d9863555052f 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/storage/install/BUILD +++ b/staging/src/k8s.io/client-go/pkg/apis/storage/install/BUILD @@ -11,7 +11,6 @@ go_library( name = "go_default_library", srcs = ["install.go"], tags = ["automanaged"], - visibility = ["//visibility:private"], deps = [ "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", diff --git a/staging/src/k8s.io/client-go/pkg/apis/storage/v1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/storage/v1/generated.pb.go index 3e88054c8b548..ef9cac57e9f37 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/storage/v1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/storage/v1/generated.pb.go @@ -707,35 +707,34 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 474 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x92, 0x4f, 0x6f, 0xd3, 0x30, - 0x18, 0xc6, 0xe3, 0x54, 0x95, 0x36, 0x17, 0x44, 0x15, 0x38, 0x54, 0x3d, 0x64, 0xd5, 0x04, 0x52, + // 458 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x91, 0xcf, 0x6f, 0xd3, 0x30, + 0x14, 0xc7, 0xe3, 0x54, 0x95, 0x36, 0x17, 0x44, 0x15, 0x38, 0x54, 0x3d, 0x78, 0xd5, 0x04, 0x52, 0x2f, 0xd8, 0x74, 0x63, 0x68, 0x42, 0xe2, 0xd2, 0x89, 0x03, 0x12, 0x88, 0x29, 0x5c, 0x10, 0xe2, - 0x80, 0xdb, 0xbd, 0xa4, 0x26, 0x4d, 0x1c, 0xd9, 0x6f, 0x02, 0xbd, 0xf1, 0x11, 0xf8, 0x58, 0x15, - 0xa7, 0x1d, 0x39, 0x0d, 0x1a, 0xbe, 0x08, 0xca, 0x1f, 0x96, 0x88, 0x6c, 0xa2, 0xda, 0x2d, 0xaf, - 0xed, 0xdf, 0xe3, 0xe7, 0x79, 0x1c, 0x7a, 0x14, 0x1c, 0x1b, 0x26, 0x15, 0x0f, 0x92, 0x19, 0xe8, - 0x08, 0x10, 0x0c, 0x8f, 0x03, 0x9f, 0x8b, 0x58, 0x1a, 0x6e, 0x50, 0x69, 0xe1, 0x03, 0x4f, 0x27, - 0xdc, 0x87, 0x08, 0xb4, 0x40, 0x38, 0x63, 0xb1, 0x56, 0xa8, 0x9c, 0x07, 0x25, 0xc6, 0x6a, 0x8c, - 0xc5, 0x81, 0xcf, 0x72, 0x8c, 0x55, 0x18, 0x4b, 0x27, 0xc3, 0x87, 0xbe, 0xc4, 0x45, 0x32, 0x63, - 0x73, 0x15, 0x72, 0x5f, 0xf9, 0x8a, 0x17, 0xf4, 0x2c, 0xf9, 0x58, 0x4c, 0xc5, 0x50, 0x7c, 0x95, - 0xaa, 0xc3, 0xc7, 0x95, 0x19, 0x11, 0xcb, 0x50, 0xcc, 0x17, 0x32, 0x02, 0xbd, 0xaa, 0xed, 0x84, - 0x80, 0xe2, 0x0a, 0x2f, 0x43, 0x7e, 0x1d, 0xa5, 0x93, 0x08, 0x65, 0x08, 0x2d, 0xe0, 0xc9, 0xff, - 0x00, 0x33, 0x5f, 0x40, 0x28, 0x5a, 0xdc, 0xe1, 0x75, 0x5c, 0x82, 0x72, 0xc9, 0x65, 0x84, 0x06, - 0x75, 0x0b, 0x6a, 0x64, 0x32, 0xa0, 0x53, 0xd0, 0x75, 0x20, 0xf8, 0x22, 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0x58, 0x95, 0x7e, 0x76, 0xfd, 0x62, 0xe9, 0xdd, 0xa3, 0xdd, 0x4c, + 0x2e, 0x53, 0xa8, 0xc6, 0xf1, 0xab, 0xe2, 0xa9, 0x7b, 0x4c, 0xf6, 0xbf, 0x11, 0xda, 0x6f, 0xbf, + 0xff, 0x52, 0x59, 0xf4, 0xde, 0x6f, 0x59, 0xe6, 0x37, 0xb3, 0x5c, 0xd0, 0xa5, 0xe3, 0x7e, 0xdd, + 0xf5, 0xce, 0x9f, 0x9d, 0x96, 0xe1, 0xb7, 0xb4, 0xab, 0x10, 0x22, 0x3b, 0x70, 0x4b, 0x4b, 0x87, + 0xff, 0x61, 0x69, 0x7a, 0xbb, 0xce, 0xef, 0xbe, 0x28, 0x92, 0xfc, 0x2a, 0x70, 0x7a, 0x7f, 0xbd, + 0x61, 0xce, 0xf9, 0x86, 0x39, 0xdf, 0x37, 0xcc, 0xf9, 0x92, 0x33, 0xb2, 0xce, 0x19, 0x39, 0xcf, + 0x19, 0xf9, 0x99, 0x33, 0xf2, 0xf5, 0x17, 0x73, 0xde, 0xb9, 0xd9, 0xe4, 0x77, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xab, 0x11, 0xb9, 0x95, 0xb6, 0x03, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/storage/v1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/storage/v1/generated.proto index 9457ee7aeb3dc..ad53eb557ea17 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/storage/v1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/storage/v1/generated.proto @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.storage.v1; +package k8s.io.client_go.pkg.apis.storage.v1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1"; diff --git a/staging/src/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.pb.go b/staging/src/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.pb.go index 6ef1e6e13f834..f3a999d1d9c39 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.pb.go +++ b/staging/src/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.pb.go @@ -707,35 +707,34 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 479 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x92, 0x4d, 0x8b, 0xd3, 0x40, - 0x1c, 0xc6, 0x33, 0x2d, 0xc5, 0xdd, 0xa9, 0x62, 0x89, 0x1e, 0x4a, 0x0f, 0xd9, 0xb2, 0xa7, 0x2a, - 0x38, 0x63, 0xd7, 0x17, 0xca, 0x82, 0x97, 0x8a, 0xa0, 0xa0, 0xb8, 0xc4, 0x9b, 0x28, 0x38, 0xe9, - 0xfe, 0x4d, 0xc7, 0x34, 0x99, 0x30, 0xf3, 0x4f, 0xb0, 0xe0, 0xc1, 0x8f, 0xe0, 0xc7, 0xea, 0xcd, - 0x3d, 0x7a, 0x5a, 0x6c, 0xf4, 0x83, 0x48, 0x5e, 0xdc, 0x04, 0xe3, 0x62, 0xf1, 0x96, 0x79, 0xf9, - 0x3d, 0xff, 0xe7, 0x79, 0x26, 0xf4, 0x38, 0x98, 0x19, 0x26, 0x15, 0x0f, 0x12, 0x0f, 0x74, 0x04, - 0x08, 0x86, 0xc7, 0x81, 0xcf, 0x45, 0x2c, 0x0d, 0x37, 0xa8, 0xb4, 0xf0, 0x81, 0xa7, 0x53, 0x0f, - 0x50, 0x4c, 0xb9, 0x0f, 0x11, 0x68, 0x81, 0x70, 0xca, 0x62, 0xad, 0x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 0x8d, 0x0a, 0xe9, 0x9f, 0xd4, 0x47, 0x6e, 0xf3, 0x9e, 0xfd, 0x89, 0xd2, 0x58, 0x68, 0x11, - 0x02, 0x82, 0x36, 0xc3, 0xee, 0xb8, 0x3b, 0xe9, 0x1f, 0x3d, 0x65, 0xbb, 0xff, 0x23, 0xac, 0x19, - 0x93, 0x9d, 0x5c, 0x48, 0x3d, 0x89, 0x50, 0xaf, 0x6b, 0xcb, 0xf5, 0x81, 0xdb, 0x98, 0x37, 0x7a, - 0x44, 0xaf, 0xff, 0x81, 0xd8, 0x03, 0xda, 0x0d, 0x60, 0x5d, 0x94, 0xb4, 0xef, 0xe6, 0x9f, 0xf6, - 0x4d, 0xda, 0x4b, 0xc5, 0x2a, 0x81, 0x32, 0x93, 0x5b, 0x2e, 0x8e, 0x3b, 0x33, 0x72, 0xf8, 0x95, - 0xd0, 0x41, 0x73, 0xfe, 0x73, 0x69, 0xd0, 0x7e, 0xd3, 0xaa, 0x9a, 0xed, 0x56, 0x75, 0x4e, 0x17, - 0x45, 0x0f, 0x2a, 0xd7, 0x7b, 0xbf, 0x77, 0x1a, 0x35, 0xbf, 0xa5, 0x3d, 0x89, 0x10, 0x9a, 0x61, - 0xa7, 0xa8, 0x6a, 0xf6, 0xbf, 0x55, 0xcd, 0xaf, 0x55, 0x43, 0x7a, 0xcf, 0x72, 0x39, 0xb7, 0x54, - 0x9d, 0xdf, 0xda, 0x6c, 0x1d, 0xeb, 0x6c, 0xeb, 0x58, 0xdf, 0xb6, 0x8e, 0xf5, 0x39, 0x73, 0xc8, - 0x26, 0x73, 0xc8, 0x59, 0xe6, 0x90, 0xef, 0x99, 0x43, 0xbe, 0xfc, 0x70, 0xac, 0xd7, 0x57, 0x2a, - 0xb5, 0x5f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x7e, 0xb2, 0x39, 0x2a, 0x05, 0x04, 0x00, 0x00, + // 463 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00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 0xd0, 0xec, 0xff, 0x5a, 0x1a, 0xb4, 0x3f, 0xb4, 0x54, 0xb3, 0xdd, 0x54, 0xe7, 0x74, + 0x21, 0x7a, 0x50, 0x4d, 0xbd, 0xf7, 0xef, 0xa4, 0xa1, 0xf9, 0x23, 0xed, 0x49, 0x84, 0xd0, 0x0c, + 0x3b, 0x85, 0xaa, 0xd9, 0x75, 0x55, 0xcd, 0x6f, 0x55, 0x4d, 0x7a, 0xaf, 0xf2, 0x38, 0xb7, 0x4c, + 0x9d, 0xdf, 0xdb, 0x6c, 0x1d, 0xeb, 0x6c, 0xeb, 0x58, 0x3f, 0xb7, 0x8e, 0xf5, 0x2d, 0x73, 0xc8, + 0x26, 0x73, 0xc8, 0x59, 0xe6, 0x90, 0x5f, 0x99, 0x43, 0xbe, 0xff, 0x76, 0xac, 0xf7, 0x37, 0xaa, + 0xb4, 0xbf, 0x01, 0x00, 0x00, 0xff, 0xff, 0x90, 0xa9, 0x9d, 0x71, 0xcf, 0x03, 0x00, 0x00, } diff --git a/staging/src/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.proto b/staging/src/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.proto index 28080dd611010..1ba1eb8ca3f1a 100644 --- a/staging/src/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.proto +++ b/staging/src/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.proto @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.storage.v1beta1; +package k8s.io.client_go.pkg.apis.storage.v1beta1; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; diff --git a/staging/src/k8s.io/client-go/pkg/util/BUILD b/staging/src/k8s.io/client-go/pkg/util/BUILD index fbf326b6bbdf3..ff028a804fe0e 100644 --- a/staging/src/k8s.io/client-go/pkg/util/BUILD +++ b/staging/src/k8s.io/client-go/pkg/util/BUILD @@ -16,7 +16,4 @@ go_library( "util.go", ], tags = ["automanaged"], - visibility = [ - "//vendor/k8s.io/client-go/pkg/api/v1:__pkg__", - ], ) diff --git a/staging/src/k8s.io/client-go/tools/clientcmd/client_config.go b/staging/src/k8s.io/client-go/tools/clientcmd/client_config.go index 31a0036dc2e3a..103648f1dc77d 100644 --- a/staging/src/k8s.io/client-go/tools/clientcmd/client_config.go +++ b/staging/src/k8s.io/client-go/tools/clientcmd/client_config.go @@ -205,7 +205,7 @@ func getServerIdentificationPartialConfig(configAuthInfo clientcmdapi.AuthInfo, // we want this order of precedence for user identifcation // 1. configAuthInfo minus auth-path (the final result of command line flags and merged .kubeconfig files) // 2. configAuthInfo.auth-path (this file can contain information that conflicts with #1, and we want #1 to win the priority) -// 3. if there is not enough information to idenfity the user, load try the ~/.kubernetes_auth file +// 3. if there is not enough information to identify the user, load try the ~/.kubernetes_auth file // 4. if there is not enough information to identify the user, prompt if possible func (config *DirectClientConfig) getUserIdentificationPartialConfig(configAuthInfo clientcmdapi.AuthInfo, fallbackReader io.Reader, persistAuthConfig restclient.AuthProviderConfigPersister) (*restclient.Config, error) { mergedConfig := &restclient.Config{} diff --git a/staging/src/k8s.io/kube-aggregator/pkg/apis/apiregistration/v1beta1/generated.pb.go b/staging/src/k8s.io/kube-aggregator/pkg/apis/apiregistration/v1beta1/generated.pb.go index 2a3b332a75258..01dd7adeb8317 100644 --- a/staging/src/k8s.io/kube-aggregator/pkg/apis/apiregistration/v1beta1/generated.pb.go +++ b/staging/src/k8s.io/kube-aggregator/pkg/apis/apiregistration/v1beta1/generated.pb.go @@ -1479,56 +1479,56 @@ func init() { } var fileDescriptorGenerated = []byte{ - // 815 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0x4d, 0x6f, 0x1b, 0x45, - 0x18, 0xf6, 0x3a, 0x4e, 0xe2, 0x4c, 0x42, 0x1b, 0x06, 0x55, 0x58, 0x91, 0x58, 0x07, 0x23, 0x81, - 0x8b, 0xe8, 0x2e, 0x29, 0x88, 0x0f, 0x71, 0xea, 0xe6, 0x50, 0x59, 0x72, 0xa1, 0x1a, 0x47, 0x3d, - 0x20, 0x24, 0x3a, 0x5e, 0xbf, 0x59, 0x0f, 0xf6, 0x7e, 0x30, 0x33, 0xbb, 0xc2, 0xb7, 0xfe, 0x04, - 0x2e, 0xfc, 0xa7, 0x1c, 0x38, 0xf4, 0x98, 0x93, 0x45, 0xcc, 0xbf, 0xe8, 0x05, 0x34, 0xb3, 0xb3, - 0x1f, 0x8d, 0x5d, 0xb5, 0x8a, 0x72, 0xb1, 0xfc, 0x7e, 0x3c, 0xcf, 0xf3, 0x7e, 0xed, 0xa0, 0xe7, - 0xb3, 0xef, 0x84, 0xc3, 0x62, 0x77, 0x96, 0x8e, 0x81, 0x47, 0x20, 0x41, 0xb8, 0x19, 0x44, 0x93, - 0x98, 0xbb, 0xb5, 0xc0, 0x03, 0x1a, 0x04, 0x1c, 0x02, 0x2a, 0x63, 0xee, 0x26, 0xb3, 0xc0, 0xa5, - 0x09, 0x13, 0xea, 0x87, 0x43, 0xc0, 0x84, 0xe4, 0x54, 0xb2, 0x38, 0x72, 0xb3, 0x93, 0x31, 0x48, - 0x7a, 0xe2, 0x06, 0x10, 0x01, 0xa7, 0x12, 0x26, 0x4e, 0xc2, 0x63, 0x19, 0xe3, 0x6f, 0x73, 0x22, - 0x47, 0x11, 0xfd, 0x5a, 0x11, 0x39, 0xc9, 0x2c, 0x70, 0x14, 0x91, 0x73, 0x8d, 0xc8, 0x31, 0x44, - 0x47, 0x0f, 0x02, 0x26, 0xa7, 0xe9, 0xd8, 0xf1, 0xe3, 0xd0, 0x0d, 0xe2, 0x20, 0x76,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xa2, 0x21, 0x88, 0x84, 0xfa, 0xc5, 0x83, 0xf2, 0xbe, 0xa1, 0xd9, 0xfb, 0xb1, 0x08, 0x90, 0x2a, - 0x07, 0x1f, 0xa3, 0x96, 0x32, 0xcc, 0x62, 0xcb, 0x97, 0x52, 0xe5, 0x12, 0x1d, 0xf1, 0xee, 0x5f, - 0x5c, 0xd9, 0x8d, 0x97, 0x57, 0x76, 0xe3, 0xf2, 0xca, 0x6e, 0xbc, 0x58, 0xd9, 0xd6, 0xc5, 0xca, - 0xb6, 0x5e, 0xae, 0x6c, 0xeb, 0x9f, 0x95, 0x6d, 0xfd, 0xf9, 0xaf, 0xdd, 0xf8, 0x79, 0xd7, 0x74, - 0xf1, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1b, 0x3e, 0xbd, 0x0a, 0x05, 0x08, 0x00, 0x00, + // 801 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0xcf, 0x6f, 0x1b, 0x45, + 0x14, 0xf6, 0x3a, 0xfe, 0x95, 0x49, 0x68, 0xc3, 0xa0, 0x0a, 0xcb, 0x12, 0xeb, 0x60, 0x24, 0x70, + 0x11, 0xdd, 0x25, 0x05, 0xf1, 0x43, 0x9c, 0xba, 0x39, 0x54, 0x96, 0x5c, 0xa8, 0xc6, 0x51, 0x0f, + 0x08, 0x89, 0x8e, 0xd7, 0x2f, 0xeb, 0xc1, 0xd9, 0x1f, 0xcc, 0xcc, 0x5a, 0xf2, 0xad, 0x7f, 0x02, + 0x17, 0xfe, 0xa7, 0x1c, 0x38, 0xf4, 0x98, 0x93, 0x45, 0xcc, 0x7f, 0xd1, 0x0b, 0x68, 0x66, 0x67, + 0x77, 0x5d, 0xdb, 0x15, 0x51, 0x94, 0x8b, 0xe5, 0x79, 0xef, 0x7d, 0xdf, 0xf7, 0xe6, 0xbd, 0x6f, + 0x07, 0xbd, 0x9c, 0x7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 0x0c, 0x73, 0xe8, 0x1d, 0xaa, 0xed, 0x9d, 0x3e, + 0xc9, 0x62, 0xa4, 0xc8, 0xe2, 0x2f, 0x50, 0x2b, 0xe1, 0x2c, 0xe6, 0x4c, 0x2e, 0xda, 0x8d, 0x63, + 0xab, 0xbf, 0x57, 0xee, 0xfa, 0xb9, 0x89, 0x93, 0xa2, 0xa2, 0xf7, 0xa7, 0x85, 0x8e, 0x36, 0x3f, + 0x72, 0xfc, 0xca, 0x42, 0xc8, 0xcf, 0x3f, 0x2c, 0xd1, 0xb6, 0xb4, 0x0d, 0x86, 0x77, 0x60, 0x83, + 0xe2, 0x6b, 0x2d, 0xdf, 0xca, 0x22, 0x24, 0xc8, 0x9a, 0x66, 0x0f, 0xd0, 0xd1, 0xe6, 0xfa, 0xb0, + 0x8b, 0xf6, 0x23, 0x1a, 0x82, 0x48, 0xa8, 0x9f, 0x3f, 0x28, 0xef, 0x1b, 0x9a, 0xfd, 0x1f, 0xf3, + 0x04, 0x29, 0x6b, 0xf0, 0x31, 0xaa, 0xa9, 0x83, 0x59, 0x6c, 0xf1, 0x52, 0xaa, 0x5a, 0xa2, 0x33, + 0xde, 0xc3, 0xcb, 0x6b, 0xbb, 0xf2, 0xfa, 0xda, 0xae, 0x5c, 0x5d, 0xdb, 0x95, 0x57, 0x2b, 0xdb, + 0xba, 0x5c, 0xd9, 0xd6, 0xeb, 0x95, 0x6d, 0xfd, 0xbd, 0xb2, 0xad, 0x3f, 0xfe, 0xb1, 0x2b, 0x3f, + 0x37, 0xcd, 0x2d, 0xfe, 0x0b, 0x00, 0x00, 0xff, 0xff, 0xd6, 0x26, 0x9e, 0xdb, 0xcf, 0x07, 0x00, + 0x00, } diff --git a/staging/src/k8s.io/kube-aggregator/pkg/apis/apiregistration/v1beta1/generated.proto b/staging/src/k8s.io/kube-aggregator/pkg/apis/apiregistration/v1beta1/generated.proto index 0e1d703781910..99e99b8361cc7 100644 --- a/staging/src/k8s.io/kube-aggregator/pkg/apis/apiregistration/v1beta1/generated.proto +++ b/staging/src/k8s.io/kube-aggregator/pkg/apis/apiregistration/v1beta1/generated.proto @@ -25,7 +25,6 @@ import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; -import "k8s.io/apiserver/pkg/apis/example/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; diff --git a/staging/src/k8s.io/kube-aggregator/pkg/apiserver/BUILD b/staging/src/k8s.io/kube-aggregator/pkg/apiserver/BUILD index 26c6515b151ba..ead36c19b36a6 100644 --- a/staging/src/k8s.io/kube-aggregator/pkg/apiserver/BUILD +++ b/staging/src/k8s.io/kube-aggregator/pkg/apiserver/BUILD @@ -11,7 +11,6 @@ load( go_test( name = "go_default_test", srcs = [ - "apiservice_controller_test.go", "handler_apis_test.go", "handler_proxy_test.go", ], @@ -25,8 +24,6 @@ go_test( "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", "//vendor/k8s.io/apiserver/pkg/authentication/user:go_default_library", "//vendor/k8s.io/apiserver/pkg/endpoints/request:go_default_library", - "//vendor/k8s.io/client-go/listers/core/v1:go_default_library", - "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", "//vendor/k8s.io/client-go/tools/cache:go_default_library", "//vendor/k8s.io/kube-aggregator/pkg/apis/apiregistration:go_default_library", "//vendor/k8s.io/kube-aggregator/pkg/client/listers/apiregistration/internalversion:go_default_library", @@ -65,6 +62,7 @@ go_library( "//vendor/k8s.io/apiserver/pkg/registry/rest:go_default_library", "//vendor/k8s.io/apiserver/pkg/server:go_default_library", "//vendor/k8s.io/apiserver/pkg/util/feature:go_default_library", + "//vendor/k8s.io/apiserver/pkg/util/proxy:go_default_library", "//vendor/k8s.io/client-go/informers:go_default_library", "//vendor/k8s.io/client-go/informers/core/v1:go_default_library", "//vendor/k8s.io/client-go/kubernetes:go_default_library", diff --git a/staging/src/k8s.io/kube-aggregator/pkg/apiserver/apiserver.go b/staging/src/k8s.io/kube-aggregator/pkg/apiserver/apiserver.go index 87e0d3e695afb..a502582168d2c 100644 --- a/staging/src/k8s.io/kube-aggregator/pkg/apiserver/apiserver.go +++ b/staging/src/k8s.io/kube-aggregator/pkg/apiserver/apiserver.go @@ -18,6 +18,7 @@ package apiserver import ( "net/http" + "net/url" "time" "k8s.io/apimachinery/pkg/apimachinery/announced" @@ -30,8 +31,10 @@ import ( genericapirequest "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/apiserver/pkg/registry/rest" genericapiserver "k8s.io/apiserver/pkg/server" + "k8s.io/apiserver/pkg/util/proxy" kubeinformers "k8s.io/client-go/informers" kubeclientset "k8s.io/client-go/kubernetes" + listersv1 "k8s.io/client-go/listers/core/v1" "k8s.io/client-go/pkg/version" "k8s.io/kube-aggregator/pkg/apis/apiregistration" @@ -70,6 +73,19 @@ func init() { // legacyAPIServiceName is the fixed name of the only non-groupified API version const legacyAPIServiceName = "v1." +type ServiceResolver interface { + ResolveEndpoint(namespace, name string) (*url.URL, error) +} + +type aggregatorEndpointRouting struct { + services listersv1.ServiceLister + endpoints listersv1.EndpointsLister +} + +type aggregatorClusterRouting struct { + services listersv1.ServiceLister +} + type Config struct { GenericConfig *genericapiserver.Config CoreAPIServerClient kubeclientset.Interface @@ -78,6 +94,9 @@ type Config struct { // this to confirm the proxy's identity ProxyClientCert []byte ProxyClientKey []byte + + // Indicates if the Aggregator should send to the cluster IP (false) or route to the endpoints IP (true) + EnableAggregatorRouting bool } // APIAggregator contains state for a Kubernetes cluster master/api server. @@ -104,6 +123,9 @@ type APIAggregator struct { // provided for easier embedding APIRegistrationInformers informers.SharedInformerFactory + + // Information needed to determine routing for the aggregator + routing ServiceResolver } type completedConfig struct { @@ -128,9 +150,17 @@ func (c *Config) SkipComplete() completedConfig { return completedConfig{c} } +func (r *aggregatorEndpointRouting) ResolveEndpoint(namespace, name string) (*url.URL, error) { + return proxy.ResolveEndpoint(r.services, r.endpoints, namespace, name) +} + +func (r *aggregatorClusterRouting) ResolveEndpoint(namespace, name string) (*url.URL, error) { + return proxy.ResolveCluster(r.services, namespace, name) +} + // New returns a new instance of APIAggregator from the given config. func (c completedConfig) NewWithDelegate(delegationTarget genericapiserver.DelegationTarget) (*APIAggregator, error) { - genericServer, err := c.Config.GenericConfig.SkipComplete().New(delegationTarget) // completion is done in Complete, no need for a second time + genericServer, err := c.Config.GenericConfig.SkipComplete().New("kube-aggregator", delegationTarget) // completion is done in Complete, no need for a second time if err != nil { return nil, err } @@ -145,6 +175,18 @@ func (c completedConfig) NewWithDelegate(delegationTarget genericapiserver.Deleg ) kubeInformers := kubeinformers.NewSharedInformerFactory(c.CoreAPIServerClient, 5*time.Minute) + var routing ServiceResolver + if c.EnableAggregatorRouting { + routing = &aggregatorEndpointRouting{ + services: kubeInformers.Core().V1().Services().Lister(), + endpoints: kubeInformers.Core().V1().Endpoints().Lister(), + } + } else { + routing = &aggregatorClusterRouting{ + services: kubeInformers.Core().V1().Services().Lister(), + } + } + s := &APIAggregator{ GenericAPIServer: genericServer, delegateHandler: delegationTarget.UnprotectedHandler(), @@ -155,6 +197,7 @@ func (c completedConfig) NewWithDelegate(delegationTarget genericapiserver.Deleg handledGroups: sets.String{}, lister: informerFactory.Apiregistration().InternalVersion().APIServices().Lister(), APIRegistrationInformers: informerFactory, + routing: routing, } apiGroupInfo := genericapiserver.NewDefaultAPIGroupInfo(apiregistration.GroupName, registry, Scheme, metav1.ParameterCodec, Codecs) @@ -174,8 +217,8 @@ func (c completedConfig) NewWithDelegate(delegationTarget genericapiserver.Deleg lister: s.lister, mapper: s.contextMapper, } - s.GenericAPIServer.Handler.PostGoRestfulMux.Handle("/apis", apisHandler) - s.GenericAPIServer.Handler.PostGoRestfulMux.UnlistedHandle("/apis/", apisHandler) + s.GenericAPIServer.Handler.NonGoRestfulMux.Handle("/apis", apisHandler) + s.GenericAPIServer.Handler.NonGoRestfulMux.UnlistedHandle("/apis/", apisHandler) apiserviceRegistrationController := NewAPIServiceRegistrationController(informerFactory.Apiregistration().InternalVersion().APIServices(), kubeInformers.Core().V1().Services(), s) availableController := statuscontrollers.NewAvailableConditionController( @@ -204,11 +247,11 @@ func (c completedConfig) NewWithDelegate(delegationTarget genericapiserver.Deleg // AddAPIService adds an API service. It is not thread-safe, so only call it on one thread at a time please. // It's a slow moving API, so its ok to run the controller on a single thread -func (s *APIAggregator) AddAPIService(apiService *apiregistration.APIService, destinationHost string) { +func (s *APIAggregator) AddAPIService(apiService *apiregistration.APIService) { // if the proxyHandler already exists, it needs to be updated. The aggregation bits do not // since they are wired against listers because they require multiple resources to respond if proxyHandler, exists := s.proxyHandlers[apiService.Name]; exists { - proxyHandler.updateAPIService(apiService, destinationHost) + proxyHandler.updateAPIService(apiService) return } @@ -224,11 +267,12 @@ func (s *APIAggregator) AddAPIService(apiService *apiregistration.APIService, de localDelegate: s.delegateHandler, proxyClientCert: s.proxyClientCert, proxyClientKey: s.proxyClientKey, + routing: s.routing, } - proxyHandler.updateAPIService(apiService, destinationHost) + proxyHandler.updateAPIService(apiService) s.proxyHandlers[apiService.Name] = proxyHandler - s.GenericAPIServer.Handler.PostGoRestfulMux.Handle(proxyPath, proxyHandler) - s.GenericAPIServer.Handler.PostGoRestfulMux.UnlistedHandlePrefix(proxyPath+"/", proxyHandler) + s.GenericAPIServer.Handler.NonGoRestfulMux.Handle(proxyPath, proxyHandler) + s.GenericAPIServer.Handler.NonGoRestfulMux.UnlistedHandlePrefix(proxyPath+"/", proxyHandler) // if we're dealing with the legacy group, we're done here if apiService.Name == legacyAPIServiceName { @@ -250,8 +294,8 @@ func (s *APIAggregator) AddAPIService(apiService *apiregistration.APIService, de contextMapper: s.contextMapper, } // aggregation is protected - s.GenericAPIServer.Handler.PostGoRestfulMux.Handle(groupPath, groupDiscoveryHandler) - s.GenericAPIServer.Handler.PostGoRestfulMux.UnlistedHandle(groupPath+"/", groupDiscoveryHandler) + s.GenericAPIServer.Handler.NonGoRestfulMux.Handle(groupPath, groupDiscoveryHandler) + s.GenericAPIServer.Handler.NonGoRestfulMux.UnlistedHandle(groupPath+"/", groupDiscoveryHandler) s.handledGroups.Insert(apiService.Spec.Group) } @@ -265,8 +309,8 @@ func (s *APIAggregator) RemoveAPIService(apiServiceName string) { if apiServiceName == legacyAPIServiceName { proxyPath = "/api" } - s.GenericAPIServer.Handler.PostGoRestfulMux.Unregister(proxyPath) - s.GenericAPIServer.Handler.PostGoRestfulMux.Unregister(proxyPath + "/") + s.GenericAPIServer.Handler.NonGoRestfulMux.Unregister(proxyPath) + s.GenericAPIServer.Handler.NonGoRestfulMux.Unregister(proxyPath + "/") delete(s.proxyHandlers, apiServiceName) // TODO unregister group level discovery when there are no more versions for the group diff --git a/staging/src/k8s.io/kube-aggregator/pkg/apiserver/apiservice_controller.go b/staging/src/k8s.io/kube-aggregator/pkg/apiserver/apiservice_controller.go index b8d9e07f84262..189e0a7515247 100644 --- a/staging/src/k8s.io/kube-aggregator/pkg/apiserver/apiservice_controller.go +++ b/staging/src/k8s.io/kube-aggregator/pkg/apiserver/apiservice_controller.go @@ -39,7 +39,7 @@ import ( ) type APIHandlerManager interface { - AddAPIService(apiService *apiregistration.APIService, destinationHost string) + AddAPIService(apiService *apiregistration.APIService) RemoveAPIService(apiServiceName string) } @@ -102,33 +102,10 @@ func (c *APIServiceRegistrationController) sync(key string) error { return nil } - // TODO move the destination host to status so that you can see where its going - c.apiHandlerManager.AddAPIService(apiService, c.getDestinationHost(apiService)) + c.apiHandlerManager.AddAPIService(apiService) return nil } -func (c *APIServiceRegistrationController) getDestinationHost(apiService *apiregistration.APIService) string { - if apiService.Spec.Service == nil { - return "" - } - - destinationHost := apiService.Spec.Service.Name + "." + apiService.Spec.Service.Namespace + ".svc" - service, err := c.serviceLister.Services(apiService.Spec.Service.Namespace).Get(apiService.Spec.Service.Name) - if err != nil { - return destinationHost - } - switch { - // use IP from a clusterIP for these service types - case service.Spec.Type == v1.ServiceTypeClusterIP, - service.Spec.Type == v1.ServiceTypeNodePort, - service.Spec.Type == v1.ServiceTypeLoadBalancer: - return service.Spec.ClusterIP - } - - // return the normal DNS name by default - return destinationHost -} - func (c *APIServiceRegistrationController) Run(stopCh <-chan struct{}) { defer utilruntime.HandleCrash() defer c.queue.ShutDown() diff --git a/staging/src/k8s.io/kube-aggregator/pkg/apiserver/apiservice_controller_test.go b/staging/src/k8s.io/kube-aggregator/pkg/apiserver/apiservice_controller_test.go deleted file mode 100644 index 0084802bbd715..0000000000000 --- a/staging/src/k8s.io/kube-aggregator/pkg/apiserver/apiservice_controller_test.go +++ /dev/null @@ -1,139 +0,0 @@ -/* -Copyright 2016 The Kubernetes 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. -*/ - -package apiserver - -import ( - "testing" - - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - v1listers "k8s.io/client-go/listers/core/v1" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/tools/cache" - - "k8s.io/kube-aggregator/pkg/apis/apiregistration" -) - -func TestGetDestinationHost(t *testing.T) { - tests := []struct { - name string - services []*v1.Service - apiService *apiregistration.APIService - - expected string - }{ - { - name: "cluster ip", - services: []*v1.Service{ - { - ObjectMeta: metav1.ObjectMeta{Namespace: "one", Name: "alfa"}, - Spec: v1.ServiceSpec{ - Type: v1.ServiceTypeClusterIP, - ClusterIP: "hit", - }, - }, - }, - apiService: &apiregistration.APIService{ - ObjectMeta: metav1.ObjectMeta{Name: "v1."}, - Spec: apiregistration.APIServiceSpec{ - Service: &apiregistration.ServiceReference{ - Namespace: "one", - Name: "alfa", - }, - }, - }, - - expected: "hit", - }, - { - name: "loadbalancer", - services: []*v1.Service{ - { - ObjectMeta: metav1.ObjectMeta{Namespace: "one", Name: "alfa"}, - Spec: v1.ServiceSpec{ - Type: v1.ServiceTypeLoadBalancer, - ClusterIP: "lb", - }, - }, - }, - apiService: &apiregistration.APIService{ - ObjectMeta: metav1.ObjectMeta{Name: "v1."}, - Spec: apiregistration.APIServiceSpec{ - Service: &apiregistration.ServiceReference{ - Namespace: "one", - Name: "alfa", - }, - }, - }, - - expected: "lb", - }, - { - name: "node port", - services: []*v1.Service{ - { - ObjectMeta: metav1.ObjectMeta{Namespace: "one", Name: "alfa"}, - Spec: v1.ServiceSpec{ - Type: v1.ServiceTypeNodePort, - ClusterIP: "np", - }, - }, - }, - apiService: &apiregistration.APIService{ - ObjectMeta: metav1.ObjectMeta{Name: "v1."}, - Spec: apiregistration.APIServiceSpec{ - Service: &apiregistration.ServiceReference{ - Namespace: "one", - Name: "alfa", - }, - }, - }, - - expected: "np", - }, - { - name: "missing service", - apiService: &apiregistration.APIService{ - ObjectMeta: metav1.ObjectMeta{Name: "v1."}, - Spec: apiregistration.APIServiceSpec{ - Service: &apiregistration.ServiceReference{ - Namespace: "one", - Name: "alfa", - }, - }, - }, - - expected: "alfa.one.svc", - }, - } - - for _, test := range tests { - serviceCache := cache.NewIndexer(cache.DeletionHandlingMetaNamespaceKeyFunc, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}) - serviceLister := v1listers.NewServiceLister(serviceCache) - c := &APIServiceRegistrationController{ - serviceLister: serviceLister, - } - for i := range test.services { - serviceCache.Add(test.services[i]) - } - - actual := c.getDestinationHost(test.apiService) - if actual != test.expected { - t.Errorf("%s expected %v, got %v", test.name, test.expected, actual) - } - - } -} diff --git a/staging/src/k8s.io/kube-aggregator/pkg/apiserver/handler_proxy.go b/staging/src/k8s.io/kube-aggregator/pkg/apiserver/handler_proxy.go index 9820a6281fd4a..397b0ab528fef 100644 --- a/staging/src/k8s.io/kube-aggregator/pkg/apiserver/handler_proxy.go +++ b/staging/src/k8s.io/kube-aggregator/pkg/apiserver/handler_proxy.go @@ -50,6 +50,9 @@ type proxyHandler struct { proxyClientCert []byte proxyClientKey []byte + // Endpoints based routing to map from cluster IP to routable IP + routing ServiceResolver + handlingInfo atomic.Value } @@ -64,8 +67,10 @@ type proxyHandlingInfo struct { transportBuildingError error // proxyRoundTripper is the re-useable portion of the transport. It does not vary with any request. proxyRoundTripper http.RoundTripper - // destinationHost is the hostname of the backing API server - destinationHost string + // serviceName is the name of the service this handler proxies to + serviceName string + // namespace is the namespace the service lives in + serviceNamespace string } func (r *proxyHandler) ServeHTTP(w http.ResponseWriter, req *http.Request) { @@ -108,7 +113,12 @@ func (r *proxyHandler) ServeHTTP(w http.ResponseWriter, req *http.Request) { // write a new location based on the existing request pointed at the target service location := &url.URL{} location.Scheme = "https" - location.Host = handlingInfo.destinationHost + rloc, err := r.routing.ResolveEndpoint(handlingInfo.serviceNamespace, handlingInfo.serviceName) + if err != nil { + http.Error(w, "missing route", http.StatusInternalServerError) + return + } + location.Host = rloc.Host location.Path = req.URL.Path location.RawQuery = req.URL.Query().Encode() @@ -119,7 +129,7 @@ func (r *proxyHandler) ServeHTTP(w http.ResponseWriter, req *http.Request) { upgrade := false // we need to wrap the roundtripper in another roundtripper which will apply the front proxy headers - proxyRoundTripper, upgrade, err := maybeWrapForConnectionUpgrades(handlingInfo.restConfig, proxyRoundTripper, req) + proxyRoundTripper, upgrade, err = maybeWrapForConnectionUpgrades(handlingInfo.restConfig, proxyRoundTripper, req) if err != nil { http.Error(w, err.Error(), http.StatusInternalServerError) return @@ -175,14 +185,13 @@ func (r *responder) Error(err error) { // these methods provide locked access to fields -func (r *proxyHandler) updateAPIService(apiService *apiregistrationapi.APIService, destinationHost string) { +func (r *proxyHandler) updateAPIService(apiService *apiregistrationapi.APIService) { if apiService.Spec.Service == nil { r.handlingInfo.Store(proxyHandlingInfo{local: true}) return } newInfo := proxyHandlingInfo{ - destinationHost: destinationHost, restConfig: &restclient.Config{ TLSClientConfig: restclient.TLSClientConfig{ Insecure: apiService.Spec.InsecureSkipTLSVerify, @@ -192,6 +201,8 @@ func (r *proxyHandler) updateAPIService(apiService *apiregistrationapi.APIServic CAData: apiService.Spec.CABundle, }, }, + serviceName: apiService.Spec.Service.Name, + serviceNamespace: apiService.Spec.Service.Namespace, } newInfo.proxyRoundTripper, newInfo.transportBuildingError = restclient.TransportFor(newInfo.restConfig) r.handlingInfo.Store(newInfo) diff --git a/staging/src/k8s.io/kube-aggregator/pkg/apiserver/handler_proxy_test.go b/staging/src/k8s.io/kube-aggregator/pkg/apiserver/handler_proxy_test.go index 046e0c9f450bd..d03a79fa87d85 100644 --- a/staging/src/k8s.io/kube-aggregator/pkg/apiserver/handler_proxy_test.go +++ b/staging/src/k8s.io/kube-aggregator/pkg/apiserver/handler_proxy_test.go @@ -31,6 +31,7 @@ import ( genericapirequest "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/kube-aggregator/pkg/apis/apiregistration" + "net/url" ) type targetHTTPHandler struct { @@ -78,6 +79,17 @@ func (*fakeRequestContextMapper) Update(req *http.Request, context genericapireq return nil } +type mockedRouter struct { + destinationHost string +} + +func (r *mockedRouter) ResolveEndpoint(namespace, name string) (*url.URL, error) { + return &url.URL{ + Scheme: "https", + Host: r.destinationHost, + }, nil +} + func TestProxyHandler(t *testing.T) { target := &targetHTTPHandler{} targetServer := httptest.NewTLSServer(target) @@ -159,15 +171,15 @@ func TestProxyHandler(t *testing.T) { func() { handler := &proxyHandler{ localDelegate: http.NewServeMux(), + routing: &mockedRouter{destinationHost: targetServer.Listener.Addr().String()}, } handler.contextMapper = &fakeRequestContextMapper{user: tc.user} server := httptest.NewServer(handler) defer server.Close() if tc.apiService != nil { - handler.updateAPIService(tc.apiService, tc.apiService.Spec.Service.Name+"."+tc.apiService.Spec.Service.Namespace+".svc") + handler.updateAPIService(tc.apiService) curr := handler.handlingInfo.Load().(proxyHandlingInfo) - curr.destinationHost = targetServer.Listener.Addr().String() handler.handlingInfo.Store(curr) } diff --git a/staging/src/k8s.io/kube-aggregator/pkg/controllers/autoregister/BUILD b/staging/src/k8s.io/kube-aggregator/pkg/controllers/autoregister/BUILD index fac3713c3fdec..389bb26260099 100644 --- a/staging/src/k8s.io/kube-aggregator/pkg/controllers/autoregister/BUILD +++ b/staging/src/k8s.io/kube-aggregator/pkg/controllers/autoregister/BUILD @@ -10,25 +10,16 @@ load( go_test( name = "go_default_test", - srcs = [ - "autoregister_controller_new_test.go", - "autoregister_controller_test.go", - ], + srcs = ["autoregister_controller_test.go"], library = ":go_default_library", tags = ["automanaged"], deps = [ - "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", - "//vendor/k8s.io/apimachinery/pkg/api/meta:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", - "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", - "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", "//vendor/k8s.io/client-go/testing:go_default_library", "//vendor/k8s.io/client-go/tools/cache:go_default_library", "//vendor/k8s.io/client-go/util/workqueue:go_default_library", "//vendor/k8s.io/kube-aggregator/pkg/apis/apiregistration:go_default_library", - "//vendor/k8s.io/kube-aggregator/pkg/client/clientset_generated/internalclientset:go_default_library", "//vendor/k8s.io/kube-aggregator/pkg/client/clientset_generated/internalclientset/fake:go_default_library", - "//vendor/k8s.io/kube-aggregator/pkg/client/informers/internalversion:go_default_library", "//vendor/k8s.io/kube-aggregator/pkg/client/listers/apiregistration/internalversion:go_default_library", ], ) diff --git a/staging/src/k8s.io/kube-aggregator/pkg/controllers/autoregister/autoregister_controller_new_test.go b/staging/src/k8s.io/kube-aggregator/pkg/controllers/autoregister/autoregister_controller_new_test.go deleted file mode 100644 index 9a6181f83612e..0000000000000 --- a/staging/src/k8s.io/kube-aggregator/pkg/controllers/autoregister/autoregister_controller_new_test.go +++ /dev/null @@ -1,232 +0,0 @@ -/* -Copyright 2017 The Kubernetes 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. -*/ - -package autoregister - -import ( - "fmt" - "testing" - - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - clienttesting "k8s.io/client-go/testing" - "k8s.io/client-go/tools/cache" - "k8s.io/client-go/util/workqueue" - "k8s.io/kube-aggregator/pkg/apis/apiregistration" - "k8s.io/kube-aggregator/pkg/client/clientset_generated/internalclientset/fake" - listers "k8s.io/kube-aggregator/pkg/client/listers/apiregistration/internalversion" -) - -func newAutoRegisterManagedAPIService(name string) *apiregistration.APIService { - return &apiregistration.APIService{ - ObjectMeta: metav1.ObjectMeta{Name: name, Labels: map[string]string{AutoRegisterManagedLabel: string("true")}}, - } -} - -func newAutoRegisterManagedModifiedAPIService(name string) *apiregistration.APIService { - return &apiregistration.APIService{ - ObjectMeta: metav1.ObjectMeta{Name: name, Labels: map[string]string{AutoRegisterManagedLabel: string("true")}}, - Spec: apiregistration.APIServiceSpec{ - Group: "something", - }, - } -} - -func newAPIService(name string) *apiregistration.APIService { - return &apiregistration.APIService{ - ObjectMeta: metav1.ObjectMeta{Name: name}, - } -} - -func checkForNothing(name string, client *fake.Clientset) error { - if len(client.Actions()) > 0 { - return fmt.Errorf("unexpected action: %v", client.Actions()) - } - - return nil -} - -func checkForCreate(name string, client *fake.Clientset) error { - if len(client.Actions()) == 0 { - return nil - } - if len(client.Actions()) > 1 { - return fmt.Errorf("unexpected action: %v", client.Actions()) - } - - action := client.Actions()[0] - - createAction, ok := action.(clienttesting.CreateAction) - if !ok { - return fmt.Errorf("unexpected action: %v", client.Actions()) - } - apiService := createAction.GetObject().(*apiregistration.APIService) - if apiService.Name != name || apiService.Labels[AutoRegisterManagedLabel] != "true" { - return fmt.Errorf("bad name or label %v", createAction) - } - - return nil -} - -func checkForUpdate(name string, client *fake.Clientset) error { - if len(client.Actions()) == 0 { - return nil - } - if len(client.Actions()) > 1 { - return fmt.Errorf("unexpected action: %v", client.Actions()) - } - - action := client.Actions()[0] - updateAction, ok := action.(clienttesting.UpdateAction) - if !ok { - return fmt.Errorf("unexpected action: %v", client.Actions()) - } - apiService := updateAction.GetObject().(*apiregistration.APIService) - if apiService.Name != name || apiService.Labels[AutoRegisterManagedLabel] != "true" || apiService.Spec.Group != "" { - return fmt.Errorf("bad name, label, or group %v", updateAction) - } - - return nil -} - -func checkForDelete(name string, client *fake.Clientset) error { - if len(client.Actions()) == 0 { - return nil - } - - for _, action := range client.Actions() { - deleteAction, ok := action.(clienttesting.DeleteAction) - if !ok { - return fmt.Errorf("unexpected action: %v", client.Actions()) - } - if deleteAction.GetName() != name { - return fmt.Errorf("bad name %v", deleteAction) - } - } - - return nil -} - -func TestSync(t *testing.T) { - tests := []struct { - name string - apiServiceName string - addAPIServices []*apiregistration.APIService - updateAPIServices []*apiregistration.APIService - addSyncAPIServices []*apiregistration.APIService - delSyncAPIServices []string - expectedResults func(name string, client *fake.Clientset) error - }{ - { - name: "adding an API service which isn't auto-managed does nothing", - apiServiceName: "foo", - addAPIServices: []*apiregistration.APIService{newAPIService("foo")}, - updateAPIServices: []*apiregistration.APIService{}, - addSyncAPIServices: []*apiregistration.APIService{}, - delSyncAPIServices: []string{}, - expectedResults: checkForNothing, - }, - { - name: "adding one to auto-register should create", - apiServiceName: "foo", - addAPIServices: []*apiregistration.APIService{}, - updateAPIServices: []*apiregistration.APIService{}, - addSyncAPIServices: []*apiregistration.APIService{newAPIService("foo")}, - delSyncAPIServices: []string{}, - expectedResults: checkForCreate, - }, - { - name: "duplicate AddAPIServiceToSync don't panic", - apiServiceName: "foo", - addAPIServices: []*apiregistration.APIService{newAutoRegisterManagedAPIService("foo")}, - updateAPIServices: []*apiregistration.APIService{}, - addSyncAPIServices: []*apiregistration.APIService{newAutoRegisterManagedAPIService("foo"), newAutoRegisterManagedAPIService("foo")}, - delSyncAPIServices: []string{}, - expectedResults: checkForNothing, - }, - { - name: "duplicate RemoveAPIServiceToSync don't panic", - apiServiceName: "foo", - addAPIServices: []*apiregistration.APIService{newAutoRegisterManagedAPIService("foo")}, - updateAPIServices: []*apiregistration.APIService{}, - addSyncAPIServices: []*apiregistration.APIService{}, - delSyncAPIServices: []string{"foo", "foo"}, - expectedResults: checkForDelete, - }, - { - name: "removing auto-manged then RemoveAPIService should not touch APIService", - apiServiceName: "foo", - addAPIServices: []*apiregistration.APIService{}, - updateAPIServices: []*apiregistration.APIService{newAPIService("foo")}, - addSyncAPIServices: []*apiregistration.APIService{}, - delSyncAPIServices: []string{"foo"}, - expectedResults: checkForNothing, - }, - { - name: "create managed apiservice without a matching request", - apiServiceName: "foo", - addAPIServices: []*apiregistration.APIService{newAPIService("foo")}, - updateAPIServices: []*apiregistration.APIService{newAutoRegisterManagedAPIService("foo")}, - addSyncAPIServices: []*apiregistration.APIService{}, - delSyncAPIServices: []string{}, - expectedResults: checkForDelete, - }, - { - name: "modifying it should result in stomping", - apiServiceName: "foo", - addAPIServices: []*apiregistration.APIService{}, - updateAPIServices: []*apiregistration.APIService{newAutoRegisterManagedModifiedAPIService("foo")}, - addSyncAPIServices: []*apiregistration.APIService{newAutoRegisterManagedAPIService("foo")}, - delSyncAPIServices: []string{}, - expectedResults: checkForUpdate, - }, - } - - for _, test := range tests { - fakeClient := fake.NewSimpleClientset() - apiServiceIndexer := cache.NewIndexer(cache.MetaNamespaceKeyFunc, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}) - - c := autoRegisterController{ - apiServiceClient: fakeClient.Apiregistration(), - apiServiceLister: listers.NewAPIServiceLister(apiServiceIndexer), - apiServicesToSync: map[string]*apiregistration.APIService{}, - queue: workqueue.NewNamedRateLimitingQueue(workqueue.DefaultControllerRateLimiter(), "autoregister"), - } - - for _, obj := range test.addAPIServices { - apiServiceIndexer.Add(obj) - } - - for _, obj := range test.updateAPIServices { - apiServiceIndexer.Update(obj) - } - - for _, obj := range test.addSyncAPIServices { - c.AddAPIServiceToSync(obj) - } - - for _, objName := range test.delSyncAPIServices { - c.RemoveAPIServiceToSync(objName) - } - - c.checkAPIService(test.apiServiceName) - - //compare the expected results - err := test.expectedResults(test.apiServiceName, fakeClient) - if err != nil { - t.Errorf("%s %v", test.name, err) - } - } -} diff --git a/staging/src/k8s.io/kube-aggregator/pkg/controllers/autoregister/autoregister_controller_test.go b/staging/src/k8s.io/kube-aggregator/pkg/controllers/autoregister/autoregister_controller_test.go index f34e0b530a558..9a6181f83612e 100644 --- a/staging/src/k8s.io/kube-aggregator/pkg/controllers/autoregister/autoregister_controller_test.go +++ b/staging/src/k8s.io/kube-aggregator/pkg/controllers/autoregister/autoregister_controller_test.go @@ -18,326 +18,215 @@ package autoregister import ( "fmt" - "reflect" "testing" - "time" - apierrors "k8s.io/apimachinery/pkg/api/errors" - "k8s.io/apimachinery/pkg/api/meta" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/util/wait" - "k8s.io/apimachinery/pkg/watch" - core "k8s.io/client-go/testing" - + clienttesting "k8s.io/client-go/testing" + "k8s.io/client-go/tools/cache" + "k8s.io/client-go/util/workqueue" "k8s.io/kube-aggregator/pkg/apis/apiregistration" - "k8s.io/kube-aggregator/pkg/client/clientset_generated/internalclientset" "k8s.io/kube-aggregator/pkg/client/clientset_generated/internalclientset/fake" - informers "k8s.io/kube-aggregator/pkg/client/informers/internalversion" + listers "k8s.io/kube-aggregator/pkg/client/listers/apiregistration/internalversion" ) -func alwaysReady() bool { return true } +func newAutoRegisterManagedAPIService(name string) *apiregistration.APIService { + return &apiregistration.APIService{ + ObjectMeta: metav1.ObjectMeta{Name: name, Labels: map[string]string{AutoRegisterManagedLabel: string("true")}}, + } +} -func waitForNothing(startTime time.Time, client *fake.Clientset) (bool, error) { - if len(client.Actions()) > 0 { - return false, fmt.Errorf("unexpected action: %v", client.Actions()) +func newAutoRegisterManagedModifiedAPIService(name string) *apiregistration.APIService { + return &apiregistration.APIService{ + ObjectMeta: metav1.ObjectMeta{Name: name, Labels: map[string]string{AutoRegisterManagedLabel: string("true")}}, + Spec: apiregistration.APIServiceSpec{ + Group: "something", + }, } - if time.Now().After(startTime.Add(3 * time.Second)) { - return true, nil +} + +func newAPIService(name string) *apiregistration.APIService { + return &apiregistration.APIService{ + ObjectMeta: metav1.ObjectMeta{Name: name}, } - return false, nil } -func waitForCreate(name string) func(startTime time.Time, client *fake.Clientset) (bool, error) { - return func(startTime time.Time, client *fake.Clientset) (bool, error) { - if len(client.Actions()) == 0 { - return false, nil - } - if len(client.Actions()) > 1 { - return false, fmt.Errorf("unexpected action: %v", client.Actions()) - } +func checkForNothing(name string, client *fake.Clientset) error { + if len(client.Actions()) > 0 { + return fmt.Errorf("unexpected action: %v", client.Actions()) + } - action := client.Actions()[0] - createAction, ok := action.(core.CreateAction) - if !ok { - return false, fmt.Errorf("unexpected action: %v", client.Actions()) - } - apiService := createAction.GetObject().(*apiregistration.APIService) - if apiService.Name != name || apiService.Labels[AutoRegisterManagedLabel] != "true" { - return false, fmt.Errorf("bad name or label %v", createAction) - } + return nil +} - return true, nil +func checkForCreate(name string, client *fake.Clientset) error { + if len(client.Actions()) == 0 { + return nil + } + if len(client.Actions()) > 1 { + return fmt.Errorf("unexpected action: %v", client.Actions()) } -} -func waitForUpdate(name string) func(startTime time.Time, client *fake.Clientset) (bool, error) { - return func(startTime time.Time, client *fake.Clientset) (bool, error) { - if len(client.Actions()) == 0 { - return false, nil - } - if len(client.Actions()) > 1 { - return false, fmt.Errorf("unexpected action: %v", client.Actions()) - } + action := client.Actions()[0] - action := client.Actions()[0] - updateAction, ok := action.(core.UpdateAction) - if !ok { - return false, fmt.Errorf("unexpected action: %v", client.Actions()) - } - apiService := updateAction.GetObject().(*apiregistration.APIService) - if apiService.Name != name || apiService.Labels[AutoRegisterManagedLabel] != "true" || apiService.Spec.Group != "" { - return false, fmt.Errorf("bad name, label, or group %v", updateAction) - } + createAction, ok := action.(clienttesting.CreateAction) + if !ok { + return fmt.Errorf("unexpected action: %v", client.Actions()) + } + apiService := createAction.GetObject().(*apiregistration.APIService) + if apiService.Name != name || apiService.Labels[AutoRegisterManagedLabel] != "true" { + return fmt.Errorf("bad name or label %v", createAction) + } - return true, nil + return nil +} + +func checkForUpdate(name string, client *fake.Clientset) error { + if len(client.Actions()) == 0 { + return nil + } + if len(client.Actions()) > 1 { + return fmt.Errorf("unexpected action: %v", client.Actions()) } + + action := client.Actions()[0] + updateAction, ok := action.(clienttesting.UpdateAction) + if !ok { + return fmt.Errorf("unexpected action: %v", client.Actions()) + } + apiService := updateAction.GetObject().(*apiregistration.APIService) + if apiService.Name != name || apiService.Labels[AutoRegisterManagedLabel] != "true" || apiService.Spec.Group != "" { + return fmt.Errorf("bad name, label, or group %v", updateAction) + } + + return nil } -func waitForDelete(name string) func(startTime time.Time, client *fake.Clientset) (bool, error) { - return func(startTime time.Time, client *fake.Clientset) (bool, error) { - if len(client.Actions()) == 0 { - return false, nil - } +func checkForDelete(name string, client *fake.Clientset) error { + if len(client.Actions()) == 0 { + return nil + } - // tolerate delete being called multiple times. This happens if the delete fails on missing resource which - // happens on an unsynced cache - for _, action := range client.Actions() { - deleteAction, ok := action.(core.DeleteAction) - if !ok { - return false, fmt.Errorf("unexpected action: %v", client.Actions()) - } - if deleteAction.GetName() != name { - return false, fmt.Errorf("bad name %v", deleteAction) - } + for _, action := range client.Actions() { + deleteAction, ok := action.(clienttesting.DeleteAction) + if !ok { + return fmt.Errorf("unexpected action: %v", client.Actions()) + } + if deleteAction.GetName() != name { + return fmt.Errorf("bad name %v", deleteAction) } - - return true, nil } + + return nil } -func TestCheckAPIService(t *testing.T) { +func TestSync(t *testing.T) { tests := []struct { - name string - - steps []func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface) - expectedResults []func(startTime time.Time, client *fake.Clientset) (bool, error) + name string + apiServiceName string + addAPIServices []*apiregistration.APIService + updateAPIServices []*apiregistration.APIService + addSyncAPIServices []*apiregistration.APIService + delSyncAPIServices []string + expectedResults func(name string, client *fake.Clientset) error }{ { - name: "do nothing", - steps: []func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface){ - // adding an API service which isn't auto-managed does nothing - func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface) { - fakeWatch.Add(&apiregistration.APIService{ObjectMeta: metav1.ObjectMeta{Name: "foo"}}) - }, - // removing an auto-sync that doesn't exist should do nothing - func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface) { - c.RemoveAPIServiceToSync("bar") - }, - }, - expectedResults: []func(startTime time.Time, client *fake.Clientset) (bool, error){ - waitForNothing, - waitForNothing, - }, + name: "adding an API service which isn't auto-managed does nothing", + apiServiceName: "foo", + addAPIServices: []*apiregistration.APIService{newAPIService("foo")}, + updateAPIServices: []*apiregistration.APIService{}, + addSyncAPIServices: []*apiregistration.APIService{}, + delSyncAPIServices: []string{}, + expectedResults: checkForNothing, + }, + { + name: "adding one to auto-register should create", + apiServiceName: "foo", + addAPIServices: []*apiregistration.APIService{}, + updateAPIServices: []*apiregistration.APIService{}, + addSyncAPIServices: []*apiregistration.APIService{newAPIService("foo")}, + delSyncAPIServices: []string{}, + expectedResults: checkForCreate, + }, + { + name: "duplicate AddAPIServiceToSync don't panic", + apiServiceName: "foo", + addAPIServices: []*apiregistration.APIService{newAutoRegisterManagedAPIService("foo")}, + updateAPIServices: []*apiregistration.APIService{}, + addSyncAPIServices: []*apiregistration.APIService{newAutoRegisterManagedAPIService("foo"), newAutoRegisterManagedAPIService("foo")}, + delSyncAPIServices: []string{}, + expectedResults: checkForNothing, }, { - name: "simple create and delete", - steps: []func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface){ - // adding one to auto-register should create - func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface) { - c.AddAPIServiceToSync(&apiregistration.APIService{ObjectMeta: metav1.ObjectMeta{Name: "foo"}}) - }, - // adding the same item again shouldn't do anything - func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface) { - c.AddAPIServiceToSync(&apiregistration.APIService{ObjectMeta: metav1.ObjectMeta{Name: "foo"}}) - }, - // removing entry should delete the API service since its managed - func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface) { - c.RemoveAPIServiceToSync("foo") - }, - }, - expectedResults: []func(startTime time.Time, client *fake.Clientset) (bool, error){ - waitForCreate("foo"), - waitForNothing, - waitForDelete("foo"), - }, + name: "duplicate RemoveAPIServiceToSync don't panic", + apiServiceName: "foo", + addAPIServices: []*apiregistration.APIService{newAutoRegisterManagedAPIService("foo")}, + updateAPIServices: []*apiregistration.APIService{}, + addSyncAPIServices: []*apiregistration.APIService{}, + delSyncAPIServices: []string{"foo", "foo"}, + expectedResults: checkForDelete, }, { - name: "create, user manage, then delete", - steps: []func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface){ - // adding one to auto-register should create - func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface) { - c.AddAPIServiceToSync(&apiregistration.APIService{ObjectMeta: metav1.ObjectMeta{Name: "foo"}}) - }, - // adding an API service to take ownership shouldn't cause the controller to do anything - func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface) { - fakeWatch.Modify(&apiregistration.APIService{ObjectMeta: metav1.ObjectMeta{Name: "foo"}}) - }, - // removing entry should NOT delete the API service since its user owned - func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface) { - c.RemoveAPIServiceToSync("foo") - }, - }, - expectedResults: []func(startTime time.Time, client *fake.Clientset) (bool, error){ - waitForCreate("foo"), - waitForNothing, - waitForNothing, - }, + name: "removing auto-manged then RemoveAPIService should not touch APIService", + apiServiceName: "foo", + addAPIServices: []*apiregistration.APIService{}, + updateAPIServices: []*apiregistration.APIService{newAPIService("foo")}, + addSyncAPIServices: []*apiregistration.APIService{}, + delSyncAPIServices: []string{"foo"}, + expectedResults: checkForNothing, }, { - name: "create managed apiservice without a matching request", - steps: []func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface){ - // adding an API service which isn't auto-managed does nothing - func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface) { - fakeWatch.Add(&apiregistration.APIService{ObjectMeta: metav1.ObjectMeta{Name: "foo"}}) - }, - // adding an API service which claims to be managed but isn't should be deleted - func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface) { - fakeWatch.Modify(&apiregistration.APIService{ - ObjectMeta: metav1.ObjectMeta{ - Name: "foo", - Labels: map[string]string{AutoRegisterManagedLabel: "true"}, - }}) - }, - }, - expectedResults: []func(startTime time.Time, client *fake.Clientset) (bool, error){ - waitForNothing, - waitForDelete("foo"), - }, + name: "create managed apiservice without a matching request", + apiServiceName: "foo", + addAPIServices: []*apiregistration.APIService{newAPIService("foo")}, + updateAPIServices: []*apiregistration.APIService{newAutoRegisterManagedAPIService("foo")}, + addSyncAPIServices: []*apiregistration.APIService{}, + delSyncAPIServices: []string{}, + expectedResults: checkForDelete, }, { - name: "modifying it should result in stomping", - steps: []func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface){ - // adding one to auto-register should create - func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface) { - c.AddAPIServiceToSync(&apiregistration.APIService{ObjectMeta: metav1.ObjectMeta{Name: "foo"}}) - }, - // updating a managed APIService should result in stomping it - func(c AutoAPIServiceRegistration, fakeWatch *watch.FakeWatcher, client internalclientset.Interface) { - fakeWatch.Modify(&apiregistration.APIService{ - ObjectMeta: metav1.ObjectMeta{ - Name: "foo", - Labels: map[string]string{AutoRegisterManagedLabel: "true"}, - }, - Spec: apiregistration.APIServiceSpec{ - Group: "something", - }, - }) - }, - }, - expectedResults: []func(startTime time.Time, client *fake.Clientset) (bool, error){ - waitForCreate("foo"), - waitForUpdate("foo"), - }, + name: "modifying it should result in stomping", + apiServiceName: "foo", + addAPIServices: []*apiregistration.APIService{}, + updateAPIServices: []*apiregistration.APIService{newAutoRegisterManagedModifiedAPIService("foo")}, + addSyncAPIServices: []*apiregistration.APIService{newAutoRegisterManagedAPIService("foo")}, + delSyncAPIServices: []string{}, + expectedResults: checkForUpdate, }, } -NextTest: for _, test := range tests { - client := fake.NewSimpleClientset() - informerFactory := informers.NewSharedInformerFactory(client, 0) - fakeWatch := watch.NewFake() - client.PrependWatchReactor("apiservices", core.DefaultWatchReactor(fakeWatch, nil)) - - c := NewAutoRegisterController(informerFactory.Apiregistration().InternalVersion().APIServices(), client.Apiregistration()) - - stopCh := make(chan struct{}) - go informerFactory.Start(stopCh) - go c.Run(3, stopCh) - - // wait for the initial sync to complete - err := wait.PollImmediate(10*time.Millisecond, 10*time.Second, func() (bool, error) { - return c.apiServiceSynced(), nil - }) - if err != nil { - t.Errorf("%s %v", test.name, err) - close(stopCh) - continue NextTest + fakeClient := fake.NewSimpleClientset() + apiServiceIndexer := cache.NewIndexer(cache.MetaNamespaceKeyFunc, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}) + + c := autoRegisterController{ + apiServiceClient: fakeClient.Apiregistration(), + apiServiceLister: listers.NewAPIServiceLister(apiServiceIndexer), + apiServicesToSync: map[string]*apiregistration.APIService{}, + queue: workqueue.NewNamedRateLimitingQueue(workqueue.DefaultControllerRateLimiter(), "autoregister"), } - for i, step := range test.steps { - client.ClearActions() - step(c, fakeWatch, client) - - startTime := time.Now() - err := wait.PollImmediate(10*time.Millisecond, 20*time.Second, func() (bool, error) { - return test.expectedResults[i](startTime, client) - }) - if err != nil { - t.Errorf("%s[%d] %v", test.name, i, err) - close(stopCh) - continue NextTest - } + for _, obj := range test.addAPIServices { + apiServiceIndexer.Add(obj) + } - // make sure that any create/update/delete is propagated to the watch - for _, a := range client.Actions() { - switch action := a.(type) { - case core.CreateAction: - fakeWatch.Add(action.GetObject()) - metadata, err := meta.Accessor(action.GetObject()) - if err != nil { - t.Fatal(err) - } - err = wait.PollImmediate(10*time.Millisecond, 10*time.Second, func() (bool, error) { - if _, err := c.apiServiceLister.Get(metadata.GetName()); err == nil { - return true, nil - } - return false, nil - }) - if err != nil { - t.Errorf("%s[%d] %v", test.name, i, err) - close(stopCh) - continue NextTest - } + for _, obj := range test.updateAPIServices { + apiServiceIndexer.Update(obj) + } - case core.DeleteAction: - obj, err := c.apiServiceLister.Get(action.GetName()) - if apierrors.IsNotFound(err) { - close(stopCh) - continue NextTest - } - if err != nil { - t.Fatal(err) - } - fakeWatch.Delete(obj) - err = wait.PollImmediate(10*time.Millisecond, 10*time.Second, func() (bool, error) { - if _, err := c.apiServiceLister.Get(action.GetName()); apierrors.IsNotFound(err) { - return true, nil - } - return false, nil - }) - if err != nil { - t.Errorf("%s[%d] %v", test.name, i, err) - close(stopCh) - continue NextTest - } + for _, obj := range test.addSyncAPIServices { + c.AddAPIServiceToSync(obj) + } - case core.UpdateAction: - fakeWatch.Modify(action.GetObject()) - metadata, err := meta.Accessor(action.GetObject()) - if err != nil { - t.Fatal(err) - } - err = wait.PollImmediate(10*time.Millisecond, 10*time.Second, func() (bool, error) { - obj, err := c.apiServiceLister.Get(metadata.GetName()) - if err != nil { - return false, err - } - if reflect.DeepEqual(obj, action.GetObject()) { - return true, nil - } + for _, objName := range test.delSyncAPIServices { + c.RemoveAPIServiceToSync(objName) + } - return false, nil - }) - if err != nil { - t.Errorf("%s[%d] %v", test.name, i, err) - close(stopCh) - continue NextTest - } + c.checkAPIService(test.apiServiceName) - } - } + //compare the expected results + err := test.expectedResults(test.apiServiceName, fakeClient) + if err != nil { + t.Errorf("%s %v", test.name, err) } - - close(stopCh) } } diff --git a/staging/src/k8s.io/kube-apiextensions-server/Godeps/Godeps.json b/staging/src/k8s.io/kube-apiextensions-server/Godeps/Godeps.json index 433aebd206a98..98d14a51a720e 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/Godeps/Godeps.json +++ b/staging/src/k8s.io/kube-apiextensions-server/Godeps/Godeps.json @@ -254,6 +254,10 @@ "ImportPath": "github.com/pkg/errors", "Rev": "a22138067af1c4942683050411a841ade67fe1eb" }, + { + "ImportPath": "github.com/pmezard/go-difflib/difflib", + "Rev": "d8ed2627bdf02c080bf22230dbb337003b7aba2d" + }, { "ImportPath": "github.com/prometheus/client_golang/prometheus", "Rev": "e51041b3fa41cece0dca035740ba6411905be473" @@ -282,6 +286,14 @@ "ImportPath": "github.com/spf13/pflag", "Rev": "9ff6c6923cfffbcd502984b8e0c80539a94968b7" }, + { + "ImportPath": "github.com/stretchr/testify/assert", + "Rev": "e3a8ff8ce36581f87a15341206f205b1da467059" + }, + { + "ImportPath": "github.com/stretchr/testify/require", + "Rev": "e3a8ff8ce36581f87a15341206f205b1da467059" + }, { "ImportPath": "github.com/ugorji/go/codec", "Rev": "ded73eae5db7e7a0ef6f55aace87a2873c5d2b74" diff --git a/staging/src/k8s.io/kube-apiextensions-server/artifacts/customresource-01/noxu-resource-definition.yaml b/staging/src/k8s.io/kube-apiextensions-server/artifacts/customresource-01/noxu-resource-definition.yaml index 8011eee8fa8cf..86205f9dbfe49 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/artifacts/customresource-01/noxu-resource-definition.yaml +++ b/staging/src/k8s.io/kube-apiextensions-server/artifacts/customresource-01/noxu-resource-definition.yaml @@ -1,4 +1,4 @@ -apiVersion: apiextensions.k8s.io/v1alpha1 +apiVersion: apiextensions.k8s.io/v1beta1 kind: CustomResourceDefinition metadata: name: noxus.mygroup.example.com diff --git a/staging/src/k8s.io/kube-apiextensions-server/hack/update-codegen.sh b/staging/src/k8s.io/kube-apiextensions-server/hack/update-codegen.sh index 23f60f40043ec..2784f1b4f4749 100755 --- a/staging/src/k8s.io/kube-apiextensions-server/hack/update-codegen.sh +++ b/staging/src/k8s.io/kube-apiextensions-server/hack/update-codegen.sh @@ -47,20 +47,20 @@ PREFIX=k8s.io/kube-apiextensions-server/pkg/apis INPUT_BASE="--input-base ${PREFIX}" INPUT_APIS=( apiextensions/ -apiextensions/v1alpha1 +apiextensions/v1beta1 ) INPUT="--input ${INPUT_APIS[@]}" CLIENTSET_PATH="--clientset-path k8s.io/kube-apiextensions-server/pkg/client/clientset" ${CLIENTGEN} ${INPUT_BASE} ${INPUT} ${CLIENTSET_PATH} --output-base ${KUBE_ROOT}/vendor -${CLIENTGEN} --clientset-name="clientset" ${INPUT_BASE} --input apiextensions/v1alpha1 ${CLIENTSET_PATH} --output-base ${KUBE_ROOT}/vendor +${CLIENTGEN} --clientset-name="clientset" ${INPUT_BASE} --input apiextensions/v1beta1 ${CLIENTSET_PATH} --output-base ${KUBE_ROOT}/vendor echo "Building lister-gen" listergen="${PWD}/lister-gen" go build -o "${listergen}" ./cmd/libs/go2idl/lister-gen -LISTER_INPUT="--input-dirs k8s.io/kube-apiextensions-server/pkg/apis/apiextensions --input-dirs k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" +LISTER_INPUT="--input-dirs k8s.io/kube-apiextensions-server/pkg/apis/apiextensions --input-dirs k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" LISTER_PATH="--output-package k8s.io/kube-apiextensions-server/pkg/client/listers" ${listergen} ${LISTER_INPUT} ${LISTER_PATH} --output-base ${KUBE_ROOT}/vendor @@ -71,7 +71,7 @@ go build -o "${informergen}" ./cmd/libs/go2idl/informer-gen ${informergen} \ --output-base ${KUBE_ROOT}/vendor \ - --input-dirs k8s.io/kube-apiextensions-server/pkg/apis/apiextensions --input-dirs k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1 \ + --input-dirs k8s.io/kube-apiextensions-server/pkg/apis/apiextensions --input-dirs k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1 \ --versioned-clientset-package k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset \ --internal-clientset-package k8s.io/kube-apiextensions-server/pkg/client/clientset/internalclientset \ --listers-package k8s.io/kube-apiextensions-server/pkg/client/listers \ diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/helpers.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/helpers.go index c5731fca96669..299ddc22b45db 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/helpers.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/helpers.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 The Kubernetes Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/helpers_test.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/helpers_test.go index 40e65b59a86b3..1abb498155894 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/helpers_test.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/helpers_test.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 The Kubernetes Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/install/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/install/BUILD index a13b2b1dd6e6e..cbfb0dad5fb99 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/install/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/install/BUILD @@ -30,6 +30,6 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1:go_default_library", ], ) diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/install/install.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/install/install.go index 1efb0cebeae18..f568d22dad9df 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/install/install.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/install/install.go @@ -22,7 +22,7 @@ import ( "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/util/sets" "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions" - "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" ) // Install registers the API group and adds types to a scheme @@ -31,12 +31,12 @@ func Install(groupFactoryRegistry announced.APIGroupFactoryRegistry, registry *r &announced.GroupMetaFactoryArgs{ GroupName: apiextensions.GroupName, RootScopedKinds: sets.NewString("CustomResourceDefinition"), - VersionPreferenceOrder: []string{v1alpha1.SchemeGroupVersion.Version}, + VersionPreferenceOrder: []string{v1beta1.SchemeGroupVersion.Version}, ImportPrefix: "k8s.io/kube-apiextensions-server/pkg/apis/apiextension", AddInternalObjectsToScheme: apiextensions.AddToScheme, }, announced.VersionToSchemeFunc{ - v1alpha1.SchemeGroupVersion.Version: v1alpha1.AddToScheme, + v1beta1.SchemeGroupVersion.Version: v1beta1.AddToScheme, }, ).Announce(groupFactoryRegistry).RegisterAndEnable(registry, scheme); err != nil { panic(err) diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/zz_generated.conversion.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/zz_generated.conversion.go deleted file mode 100644 index 53b5569b6cae9..0000000000000 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/zz_generated.conversion.go +++ /dev/null @@ -1,225 +0,0 @@ -// +build !ignore_autogenerated - -/* -Copyright 2017 The Kubernetes 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. -*/ - -// This file was autogenerated by conversion-gen. Do not edit it manually! - -package v1alpha1 - -import ( - conversion "k8s.io/apimachinery/pkg/conversion" - runtime "k8s.io/apimachinery/pkg/runtime" - apiextensions "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions" - unsafe "unsafe" -) - -func init() { - SchemeBuilder.Register(RegisterConversions) -} - -// RegisterConversions adds conversion functions to the given scheme. -// Public to allow building arbitrary schemes. -func RegisterConversions(scheme *runtime.Scheme) error { - return scheme.AddGeneratedConversionFuncs( - Convert_v1alpha1_CustomResourceDefinition_To_apiextensions_CustomResourceDefinition, - Convert_apiextensions_CustomResourceDefinition_To_v1alpha1_CustomResourceDefinition, - Convert_v1alpha1_CustomResourceDefinitionCondition_To_apiextensions_CustomResourceDefinitionCondition, - Convert_apiextensions_CustomResourceDefinitionCondition_To_v1alpha1_CustomResourceDefinitionCondition, - Convert_v1alpha1_CustomResourceDefinitionList_To_apiextensions_CustomResourceDefinitionList, - Convert_apiextensions_CustomResourceDefinitionList_To_v1alpha1_CustomResourceDefinitionList, - Convert_v1alpha1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames, - Convert_apiextensions_CustomResourceDefinitionNames_To_v1alpha1_CustomResourceDefinitionNames, - Convert_v1alpha1_CustomResourceDefinitionSpec_To_apiextensions_CustomResourceDefinitionSpec, - Convert_apiextensions_CustomResourceDefinitionSpec_To_v1alpha1_CustomResourceDefinitionSpec, - Convert_v1alpha1_CustomResourceDefinitionStatus_To_apiextensions_CustomResourceDefinitionStatus, - Convert_apiextensions_CustomResourceDefinitionStatus_To_v1alpha1_CustomResourceDefinitionStatus, - ) -} - -func autoConvert_v1alpha1_CustomResourceDefinition_To_apiextensions_CustomResourceDefinition(in *CustomResourceDefinition, out *apiextensions.CustomResourceDefinition, s conversion.Scope) error { - out.ObjectMeta = in.ObjectMeta - if err := Convert_v1alpha1_CustomResourceDefinitionSpec_To_apiextensions_CustomResourceDefinitionSpec(&in.Spec, &out.Spec, s); err != nil { - return err - } - if err := Convert_v1alpha1_CustomResourceDefinitionStatus_To_apiextensions_CustomResourceDefinitionStatus(&in.Status, &out.Status, s); err != nil { - return err - } - return nil -} - -// Convert_v1alpha1_CustomResourceDefinition_To_apiextensions_CustomResourceDefinition is an autogenerated conversion function. -func Convert_v1alpha1_CustomResourceDefinition_To_apiextensions_CustomResourceDefinition(in *CustomResourceDefinition, out *apiextensions.CustomResourceDefinition, s conversion.Scope) error { - return autoConvert_v1alpha1_CustomResourceDefinition_To_apiextensions_CustomResourceDefinition(in, out, s) -} - -func autoConvert_apiextensions_CustomResourceDefinition_To_v1alpha1_CustomResourceDefinition(in *apiextensions.CustomResourceDefinition, out *CustomResourceDefinition, s conversion.Scope) error { - out.ObjectMeta = in.ObjectMeta - if err := Convert_apiextensions_CustomResourceDefinitionSpec_To_v1alpha1_CustomResourceDefinitionSpec(&in.Spec, &out.Spec, s); err != nil { - return err - } - if err := Convert_apiextensions_CustomResourceDefinitionStatus_To_v1alpha1_CustomResourceDefinitionStatus(&in.Status, &out.Status, s); err != nil { - return err - } - return nil -} - -// Convert_apiextensions_CustomResourceDefinition_To_v1alpha1_CustomResourceDefinition is an autogenerated conversion function. -func Convert_apiextensions_CustomResourceDefinition_To_v1alpha1_CustomResourceDefinition(in *apiextensions.CustomResourceDefinition, out *CustomResourceDefinition, s conversion.Scope) error { - return autoConvert_apiextensions_CustomResourceDefinition_To_v1alpha1_CustomResourceDefinition(in, out, s) -} - -func autoConvert_v1alpha1_CustomResourceDefinitionCondition_To_apiextensions_CustomResourceDefinitionCondition(in *CustomResourceDefinitionCondition, out *apiextensions.CustomResourceDefinitionCondition, s conversion.Scope) error { - out.Type = apiextensions.CustomResourceDefinitionConditionType(in.Type) - out.Status = apiextensions.ConditionStatus(in.Status) - out.LastTransitionTime = in.LastTransitionTime - out.Reason = in.Reason - out.Message = in.Message - return nil -} - -// Convert_v1alpha1_CustomResourceDefinitionCondition_To_apiextensions_CustomResourceDefinitionCondition is an autogenerated conversion function. -func Convert_v1alpha1_CustomResourceDefinitionCondition_To_apiextensions_CustomResourceDefinitionCondition(in *CustomResourceDefinitionCondition, out *apiextensions.CustomResourceDefinitionCondition, s conversion.Scope) error { - return autoConvert_v1alpha1_CustomResourceDefinitionCondition_To_apiextensions_CustomResourceDefinitionCondition(in, out, s) -} - -func autoConvert_apiextensions_CustomResourceDefinitionCondition_To_v1alpha1_CustomResourceDefinitionCondition(in *apiextensions.CustomResourceDefinitionCondition, out *CustomResourceDefinitionCondition, s conversion.Scope) error { - out.Type = CustomResourceDefinitionConditionType(in.Type) - out.Status = ConditionStatus(in.Status) - out.LastTransitionTime = in.LastTransitionTime - out.Reason = in.Reason - out.Message = in.Message - return nil -} - -// Convert_apiextensions_CustomResourceDefinitionCondition_To_v1alpha1_CustomResourceDefinitionCondition is an autogenerated conversion function. -func Convert_apiextensions_CustomResourceDefinitionCondition_To_v1alpha1_CustomResourceDefinitionCondition(in *apiextensions.CustomResourceDefinitionCondition, out *CustomResourceDefinitionCondition, s conversion.Scope) error { - return autoConvert_apiextensions_CustomResourceDefinitionCondition_To_v1alpha1_CustomResourceDefinitionCondition(in, out, s) -} - -func autoConvert_v1alpha1_CustomResourceDefinitionList_To_apiextensions_CustomResourceDefinitionList(in *CustomResourceDefinitionList, out *apiextensions.CustomResourceDefinitionList, s conversion.Scope) error { - out.ListMeta = in.ListMeta - out.Items = *(*[]apiextensions.CustomResourceDefinition)(unsafe.Pointer(&in.Items)) - return nil -} - -// Convert_v1alpha1_CustomResourceDefinitionList_To_apiextensions_CustomResourceDefinitionList is an autogenerated conversion function. -func Convert_v1alpha1_CustomResourceDefinitionList_To_apiextensions_CustomResourceDefinitionList(in *CustomResourceDefinitionList, out *apiextensions.CustomResourceDefinitionList, s conversion.Scope) error { - return autoConvert_v1alpha1_CustomResourceDefinitionList_To_apiextensions_CustomResourceDefinitionList(in, out, s) -} - -func autoConvert_apiextensions_CustomResourceDefinitionList_To_v1alpha1_CustomResourceDefinitionList(in *apiextensions.CustomResourceDefinitionList, out *CustomResourceDefinitionList, s conversion.Scope) error { - out.ListMeta = in.ListMeta - if in.Items == nil { - out.Items = make([]CustomResourceDefinition, 0) - } else { - out.Items = *(*[]CustomResourceDefinition)(unsafe.Pointer(&in.Items)) - } - return nil -} - -// Convert_apiextensions_CustomResourceDefinitionList_To_v1alpha1_CustomResourceDefinitionList is an autogenerated conversion function. -func Convert_apiextensions_CustomResourceDefinitionList_To_v1alpha1_CustomResourceDefinitionList(in *apiextensions.CustomResourceDefinitionList, out *CustomResourceDefinitionList, s conversion.Scope) error { - return autoConvert_apiextensions_CustomResourceDefinitionList_To_v1alpha1_CustomResourceDefinitionList(in, out, s) -} - -func autoConvert_v1alpha1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames(in *CustomResourceDefinitionNames, out *apiextensions.CustomResourceDefinitionNames, s conversion.Scope) error { - out.Plural = in.Plural - out.Singular = in.Singular - out.ShortNames = *(*[]string)(unsafe.Pointer(&in.ShortNames)) - out.Kind = in.Kind - out.ListKind = in.ListKind - return nil -} - -// Convert_v1alpha1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames is an autogenerated conversion function. -func Convert_v1alpha1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames(in *CustomResourceDefinitionNames, out *apiextensions.CustomResourceDefinitionNames, s conversion.Scope) error { - return autoConvert_v1alpha1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames(in, out, s) -} - -func autoConvert_apiextensions_CustomResourceDefinitionNames_To_v1alpha1_CustomResourceDefinitionNames(in *apiextensions.CustomResourceDefinitionNames, out *CustomResourceDefinitionNames, s conversion.Scope) error { - out.Plural = in.Plural - out.Singular = in.Singular - out.ShortNames = *(*[]string)(unsafe.Pointer(&in.ShortNames)) - out.Kind = in.Kind - out.ListKind = in.ListKind - return nil -} - -// Convert_apiextensions_CustomResourceDefinitionNames_To_v1alpha1_CustomResourceDefinitionNames is an autogenerated conversion function. -func Convert_apiextensions_CustomResourceDefinitionNames_To_v1alpha1_CustomResourceDefinitionNames(in *apiextensions.CustomResourceDefinitionNames, out *CustomResourceDefinitionNames, s conversion.Scope) error { - return autoConvert_apiextensions_CustomResourceDefinitionNames_To_v1alpha1_CustomResourceDefinitionNames(in, out, s) -} - -func autoConvert_v1alpha1_CustomResourceDefinitionSpec_To_apiextensions_CustomResourceDefinitionSpec(in *CustomResourceDefinitionSpec, out *apiextensions.CustomResourceDefinitionSpec, s conversion.Scope) error { - out.Group = in.Group - out.Version = in.Version - if err := Convert_v1alpha1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames(&in.Names, &out.Names, s); err != nil { - return err - } - out.Scope = apiextensions.ResourceScope(in.Scope) - return nil -} - -// Convert_v1alpha1_CustomResourceDefinitionSpec_To_apiextensions_CustomResourceDefinitionSpec is an autogenerated conversion function. -func Convert_v1alpha1_CustomResourceDefinitionSpec_To_apiextensions_CustomResourceDefinitionSpec(in *CustomResourceDefinitionSpec, out *apiextensions.CustomResourceDefinitionSpec, s conversion.Scope) error { - return autoConvert_v1alpha1_CustomResourceDefinitionSpec_To_apiextensions_CustomResourceDefinitionSpec(in, out, s) -} - -func autoConvert_apiextensions_CustomResourceDefinitionSpec_To_v1alpha1_CustomResourceDefinitionSpec(in *apiextensions.CustomResourceDefinitionSpec, out *CustomResourceDefinitionSpec, s conversion.Scope) error { - out.Group = in.Group - out.Version = in.Version - if err := Convert_apiextensions_CustomResourceDefinitionNames_To_v1alpha1_CustomResourceDefinitionNames(&in.Names, &out.Names, s); err != nil { - return err - } - out.Scope = ResourceScope(in.Scope) - return nil -} - -// Convert_apiextensions_CustomResourceDefinitionSpec_To_v1alpha1_CustomResourceDefinitionSpec is an autogenerated conversion function. -func Convert_apiextensions_CustomResourceDefinitionSpec_To_v1alpha1_CustomResourceDefinitionSpec(in *apiextensions.CustomResourceDefinitionSpec, out *CustomResourceDefinitionSpec, s conversion.Scope) error { - return autoConvert_apiextensions_CustomResourceDefinitionSpec_To_v1alpha1_CustomResourceDefinitionSpec(in, out, s) -} - -func autoConvert_v1alpha1_CustomResourceDefinitionStatus_To_apiextensions_CustomResourceDefinitionStatus(in *CustomResourceDefinitionStatus, out *apiextensions.CustomResourceDefinitionStatus, s conversion.Scope) error { - out.Conditions = *(*[]apiextensions.CustomResourceDefinitionCondition)(unsafe.Pointer(&in.Conditions)) - if err := Convert_v1alpha1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames(&in.AcceptedNames, &out.AcceptedNames, s); err != nil { - return err - } - return nil -} - -// Convert_v1alpha1_CustomResourceDefinitionStatus_To_apiextensions_CustomResourceDefinitionStatus is an autogenerated conversion function. -func Convert_v1alpha1_CustomResourceDefinitionStatus_To_apiextensions_CustomResourceDefinitionStatus(in *CustomResourceDefinitionStatus, out *apiextensions.CustomResourceDefinitionStatus, s conversion.Scope) error { - return autoConvert_v1alpha1_CustomResourceDefinitionStatus_To_apiextensions_CustomResourceDefinitionStatus(in, out, s) -} - -func autoConvert_apiextensions_CustomResourceDefinitionStatus_To_v1alpha1_CustomResourceDefinitionStatus(in *apiextensions.CustomResourceDefinitionStatus, out *CustomResourceDefinitionStatus, s conversion.Scope) error { - if in.Conditions == nil { - out.Conditions = make([]CustomResourceDefinitionCondition, 0) - } else { - out.Conditions = *(*[]CustomResourceDefinitionCondition)(unsafe.Pointer(&in.Conditions)) - } - if err := Convert_apiextensions_CustomResourceDefinitionNames_To_v1alpha1_CustomResourceDefinitionNames(&in.AcceptedNames, &out.AcceptedNames, s); err != nil { - return err - } - return nil -} - -// Convert_apiextensions_CustomResourceDefinitionStatus_To_v1alpha1_CustomResourceDefinitionStatus is an autogenerated conversion function. -func Convert_apiextensions_CustomResourceDefinitionStatus_To_v1alpha1_CustomResourceDefinitionStatus(in *apiextensions.CustomResourceDefinitionStatus, out *CustomResourceDefinitionStatus, s conversion.Scope) error { - return autoConvert_apiextensions_CustomResourceDefinitionStatus_To_v1alpha1_CustomResourceDefinitionStatus(in, out, s) -} diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/BUILD similarity index 100% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/BUILD rename to staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/BUILD diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/defaults.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/defaults.go similarity index 98% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/defaults.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/defaults.go index 50a4e2ac28da2..edffaed55f082 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/defaults.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/defaults.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package v1beta1 import ( "strings" diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/doc.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/doc.go similarity index 84% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/doc.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/doc.go index c5d447effd05b..6cf6a3d3ec0d7 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/doc.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/doc.go @@ -18,6 +18,6 @@ limitations under the License. // +k8s:conversion-gen=k8s.io/kubernetes/vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions // +k8s:defaulter-gen=TypeMeta -// Package v1alpha1 is the v1alpha1 version of the API. +// Package v1beta1 is the v1beta1 version of the API. // +groupName=apiextensions.k8s.io -package v1alpha1 // import "k8s.io/apiextension-server/pkg/apis/apiextensions/v1alpha1" +package v1beta1 // import "k8s.io/apiextension-server/pkg/apis/apiextensions/v1beta1" diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/register.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/register.go similarity index 97% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/register.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/register.go index 45aa6e659eb42..7eda9b5321488 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/register.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/register.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package v1beta1 import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -25,7 +25,7 @@ import ( const GroupName = "apiextensions.k8s.io" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1beta1"} // Kind takes an unqualified kind and returns back a Group qualified GroupKind func Kind(kind string) schema.GroupKind { diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/types.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/types.go similarity index 99% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/types.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/types.go index 0d6fb7e027d29..a9a93c37f9f97 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/types.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/types.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package v1beta1 import metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/zz_generated.conversion.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/zz_generated.conversion.go new file mode 100644 index 0000000000000..137523f391d14 --- /dev/null +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/zz_generated.conversion.go @@ -0,0 +1,225 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v1beta1 + +import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + apiextensions "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v1beta1_CustomResourceDefinition_To_apiextensions_CustomResourceDefinition, + Convert_apiextensions_CustomResourceDefinition_To_v1beta1_CustomResourceDefinition, + Convert_v1beta1_CustomResourceDefinitionCondition_To_apiextensions_CustomResourceDefinitionCondition, + Convert_apiextensions_CustomResourceDefinitionCondition_To_v1beta1_CustomResourceDefinitionCondition, + Convert_v1beta1_CustomResourceDefinitionList_To_apiextensions_CustomResourceDefinitionList, + Convert_apiextensions_CustomResourceDefinitionList_To_v1beta1_CustomResourceDefinitionList, + Convert_v1beta1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames, + Convert_apiextensions_CustomResourceDefinitionNames_To_v1beta1_CustomResourceDefinitionNames, + Convert_v1beta1_CustomResourceDefinitionSpec_To_apiextensions_CustomResourceDefinitionSpec, + Convert_apiextensions_CustomResourceDefinitionSpec_To_v1beta1_CustomResourceDefinitionSpec, + Convert_v1beta1_CustomResourceDefinitionStatus_To_apiextensions_CustomResourceDefinitionStatus, + Convert_apiextensions_CustomResourceDefinitionStatus_To_v1beta1_CustomResourceDefinitionStatus, + ) +} + +func autoConvert_v1beta1_CustomResourceDefinition_To_apiextensions_CustomResourceDefinition(in *CustomResourceDefinition, out *apiextensions.CustomResourceDefinition, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_v1beta1_CustomResourceDefinitionSpec_To_apiextensions_CustomResourceDefinitionSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_v1beta1_CustomResourceDefinitionStatus_To_apiextensions_CustomResourceDefinitionStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_v1beta1_CustomResourceDefinition_To_apiextensions_CustomResourceDefinition is an autogenerated conversion function. +func Convert_v1beta1_CustomResourceDefinition_To_apiextensions_CustomResourceDefinition(in *CustomResourceDefinition, out *apiextensions.CustomResourceDefinition, s conversion.Scope) error { + return autoConvert_v1beta1_CustomResourceDefinition_To_apiextensions_CustomResourceDefinition(in, out, s) +} + +func autoConvert_apiextensions_CustomResourceDefinition_To_v1beta1_CustomResourceDefinition(in *apiextensions.CustomResourceDefinition, out *CustomResourceDefinition, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_apiextensions_CustomResourceDefinitionSpec_To_v1beta1_CustomResourceDefinitionSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_apiextensions_CustomResourceDefinitionStatus_To_v1beta1_CustomResourceDefinitionStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_apiextensions_CustomResourceDefinition_To_v1beta1_CustomResourceDefinition is an autogenerated conversion function. +func Convert_apiextensions_CustomResourceDefinition_To_v1beta1_CustomResourceDefinition(in *apiextensions.CustomResourceDefinition, out *CustomResourceDefinition, s conversion.Scope) error { + return autoConvert_apiextensions_CustomResourceDefinition_To_v1beta1_CustomResourceDefinition(in, out, s) +} + +func autoConvert_v1beta1_CustomResourceDefinitionCondition_To_apiextensions_CustomResourceDefinitionCondition(in *CustomResourceDefinitionCondition, out *apiextensions.CustomResourceDefinitionCondition, s conversion.Scope) error { + out.Type = apiextensions.CustomResourceDefinitionConditionType(in.Type) + out.Status = apiextensions.ConditionStatus(in.Status) + out.LastTransitionTime = in.LastTransitionTime + out.Reason = in.Reason + out.Message = in.Message + return nil +} + +// Convert_v1beta1_CustomResourceDefinitionCondition_To_apiextensions_CustomResourceDefinitionCondition is an autogenerated conversion function. +func Convert_v1beta1_CustomResourceDefinitionCondition_To_apiextensions_CustomResourceDefinitionCondition(in *CustomResourceDefinitionCondition, out *apiextensions.CustomResourceDefinitionCondition, s conversion.Scope) error { + return autoConvert_v1beta1_CustomResourceDefinitionCondition_To_apiextensions_CustomResourceDefinitionCondition(in, out, s) +} + +func autoConvert_apiextensions_CustomResourceDefinitionCondition_To_v1beta1_CustomResourceDefinitionCondition(in *apiextensions.CustomResourceDefinitionCondition, out *CustomResourceDefinitionCondition, s conversion.Scope) error { + out.Type = CustomResourceDefinitionConditionType(in.Type) + out.Status = ConditionStatus(in.Status) + out.LastTransitionTime = in.LastTransitionTime + out.Reason = in.Reason + out.Message = in.Message + return nil +} + +// Convert_apiextensions_CustomResourceDefinitionCondition_To_v1beta1_CustomResourceDefinitionCondition is an autogenerated conversion function. +func Convert_apiextensions_CustomResourceDefinitionCondition_To_v1beta1_CustomResourceDefinitionCondition(in *apiextensions.CustomResourceDefinitionCondition, out *CustomResourceDefinitionCondition, s conversion.Scope) error { + return autoConvert_apiextensions_CustomResourceDefinitionCondition_To_v1beta1_CustomResourceDefinitionCondition(in, out, s) +} + +func autoConvert_v1beta1_CustomResourceDefinitionList_To_apiextensions_CustomResourceDefinitionList(in *CustomResourceDefinitionList, out *apiextensions.CustomResourceDefinitionList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]apiextensions.CustomResourceDefinition)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1beta1_CustomResourceDefinitionList_To_apiextensions_CustomResourceDefinitionList is an autogenerated conversion function. +func Convert_v1beta1_CustomResourceDefinitionList_To_apiextensions_CustomResourceDefinitionList(in *CustomResourceDefinitionList, out *apiextensions.CustomResourceDefinitionList, s conversion.Scope) error { + return autoConvert_v1beta1_CustomResourceDefinitionList_To_apiextensions_CustomResourceDefinitionList(in, out, s) +} + +func autoConvert_apiextensions_CustomResourceDefinitionList_To_v1beta1_CustomResourceDefinitionList(in *apiextensions.CustomResourceDefinitionList, out *CustomResourceDefinitionList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]CustomResourceDefinition, 0) + } else { + out.Items = *(*[]CustomResourceDefinition)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_apiextensions_CustomResourceDefinitionList_To_v1beta1_CustomResourceDefinitionList is an autogenerated conversion function. +func Convert_apiextensions_CustomResourceDefinitionList_To_v1beta1_CustomResourceDefinitionList(in *apiextensions.CustomResourceDefinitionList, out *CustomResourceDefinitionList, s conversion.Scope) error { + return autoConvert_apiextensions_CustomResourceDefinitionList_To_v1beta1_CustomResourceDefinitionList(in, out, s) +} + +func autoConvert_v1beta1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames(in *CustomResourceDefinitionNames, out *apiextensions.CustomResourceDefinitionNames, s conversion.Scope) error { + out.Plural = in.Plural + out.Singular = in.Singular + out.ShortNames = *(*[]string)(unsafe.Pointer(&in.ShortNames)) + out.Kind = in.Kind + out.ListKind = in.ListKind + return nil +} + +// Convert_v1beta1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames is an autogenerated conversion function. +func Convert_v1beta1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames(in *CustomResourceDefinitionNames, out *apiextensions.CustomResourceDefinitionNames, s conversion.Scope) error { + return autoConvert_v1beta1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames(in, out, s) +} + +func autoConvert_apiextensions_CustomResourceDefinitionNames_To_v1beta1_CustomResourceDefinitionNames(in *apiextensions.CustomResourceDefinitionNames, out *CustomResourceDefinitionNames, s conversion.Scope) error { + out.Plural = in.Plural + out.Singular = in.Singular + out.ShortNames = *(*[]string)(unsafe.Pointer(&in.ShortNames)) + out.Kind = in.Kind + out.ListKind = in.ListKind + return nil +} + +// Convert_apiextensions_CustomResourceDefinitionNames_To_v1beta1_CustomResourceDefinitionNames is an autogenerated conversion function. +func Convert_apiextensions_CustomResourceDefinitionNames_To_v1beta1_CustomResourceDefinitionNames(in *apiextensions.CustomResourceDefinitionNames, out *CustomResourceDefinitionNames, s conversion.Scope) error { + return autoConvert_apiextensions_CustomResourceDefinitionNames_To_v1beta1_CustomResourceDefinitionNames(in, out, s) +} + +func autoConvert_v1beta1_CustomResourceDefinitionSpec_To_apiextensions_CustomResourceDefinitionSpec(in *CustomResourceDefinitionSpec, out *apiextensions.CustomResourceDefinitionSpec, s conversion.Scope) error { + out.Group = in.Group + out.Version = in.Version + if err := Convert_v1beta1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames(&in.Names, &out.Names, s); err != nil { + return err + } + out.Scope = apiextensions.ResourceScope(in.Scope) + return nil +} + +// Convert_v1beta1_CustomResourceDefinitionSpec_To_apiextensions_CustomResourceDefinitionSpec is an autogenerated conversion function. +func Convert_v1beta1_CustomResourceDefinitionSpec_To_apiextensions_CustomResourceDefinitionSpec(in *CustomResourceDefinitionSpec, out *apiextensions.CustomResourceDefinitionSpec, s conversion.Scope) error { + return autoConvert_v1beta1_CustomResourceDefinitionSpec_To_apiextensions_CustomResourceDefinitionSpec(in, out, s) +} + +func autoConvert_apiextensions_CustomResourceDefinitionSpec_To_v1beta1_CustomResourceDefinitionSpec(in *apiextensions.CustomResourceDefinitionSpec, out *CustomResourceDefinitionSpec, s conversion.Scope) error { + out.Group = in.Group + out.Version = in.Version + if err := Convert_apiextensions_CustomResourceDefinitionNames_To_v1beta1_CustomResourceDefinitionNames(&in.Names, &out.Names, s); err != nil { + return err + } + out.Scope = ResourceScope(in.Scope) + return nil +} + +// Convert_apiextensions_CustomResourceDefinitionSpec_To_v1beta1_CustomResourceDefinitionSpec is an autogenerated conversion function. +func Convert_apiextensions_CustomResourceDefinitionSpec_To_v1beta1_CustomResourceDefinitionSpec(in *apiextensions.CustomResourceDefinitionSpec, out *CustomResourceDefinitionSpec, s conversion.Scope) error { + return autoConvert_apiextensions_CustomResourceDefinitionSpec_To_v1beta1_CustomResourceDefinitionSpec(in, out, s) +} + +func autoConvert_v1beta1_CustomResourceDefinitionStatus_To_apiextensions_CustomResourceDefinitionStatus(in *CustomResourceDefinitionStatus, out *apiextensions.CustomResourceDefinitionStatus, s conversion.Scope) error { + out.Conditions = *(*[]apiextensions.CustomResourceDefinitionCondition)(unsafe.Pointer(&in.Conditions)) + if err := Convert_v1beta1_CustomResourceDefinitionNames_To_apiextensions_CustomResourceDefinitionNames(&in.AcceptedNames, &out.AcceptedNames, s); err != nil { + return err + } + return nil +} + +// Convert_v1beta1_CustomResourceDefinitionStatus_To_apiextensions_CustomResourceDefinitionStatus is an autogenerated conversion function. +func Convert_v1beta1_CustomResourceDefinitionStatus_To_apiextensions_CustomResourceDefinitionStatus(in *CustomResourceDefinitionStatus, out *apiextensions.CustomResourceDefinitionStatus, s conversion.Scope) error { + return autoConvert_v1beta1_CustomResourceDefinitionStatus_To_apiextensions_CustomResourceDefinitionStatus(in, out, s) +} + +func autoConvert_apiextensions_CustomResourceDefinitionStatus_To_v1beta1_CustomResourceDefinitionStatus(in *apiextensions.CustomResourceDefinitionStatus, out *CustomResourceDefinitionStatus, s conversion.Scope) error { + if in.Conditions == nil { + out.Conditions = make([]CustomResourceDefinitionCondition, 0) + } else { + out.Conditions = *(*[]CustomResourceDefinitionCondition)(unsafe.Pointer(&in.Conditions)) + } + if err := Convert_apiextensions_CustomResourceDefinitionNames_To_v1beta1_CustomResourceDefinitionNames(&in.AcceptedNames, &out.AcceptedNames, s); err != nil { + return err + } + return nil +} + +// Convert_apiextensions_CustomResourceDefinitionStatus_To_v1beta1_CustomResourceDefinitionStatus is an autogenerated conversion function. +func Convert_apiextensions_CustomResourceDefinitionStatus_To_v1beta1_CustomResourceDefinitionStatus(in *apiextensions.CustomResourceDefinitionStatus, out *CustomResourceDefinitionStatus, s conversion.Scope) error { + return autoConvert_apiextensions_CustomResourceDefinitionStatus_To_v1beta1_CustomResourceDefinitionStatus(in, out, s) +} diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/zz_generated.deepcopy.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/zz_generated.deepcopy.go similarity index 64% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/zz_generated.deepcopy.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/zz_generated.deepcopy.go index edfa95b5ef786..5291372c3406a 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1/zz_generated.deepcopy.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1/zz_generated.deepcopy.go @@ -18,7 +18,7 @@ limitations under the License. // This file was autogenerated by deepcopy-gen. Do not edit it manually! -package v1alpha1 +package v1beta1 import ( v1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -35,17 +35,17 @@ func init() { // to allow building arbitrary schemes. func RegisterDeepCopies(scheme *runtime.Scheme) error { return scheme.AddGeneratedDeepCopyFuncs( - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_CustomResourceDefinition, InType: reflect.TypeOf(&CustomResourceDefinition{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_CustomResourceDefinitionCondition, InType: reflect.TypeOf(&CustomResourceDefinitionCondition{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_CustomResourceDefinitionList, InType: reflect.TypeOf(&CustomResourceDefinitionList{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_CustomResourceDefinitionNames, InType: reflect.TypeOf(&CustomResourceDefinitionNames{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_CustomResourceDefinitionSpec, InType: reflect.TypeOf(&CustomResourceDefinitionSpec{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_CustomResourceDefinitionStatus, InType: reflect.TypeOf(&CustomResourceDefinitionStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CustomResourceDefinition, InType: reflect.TypeOf(&CustomResourceDefinition{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CustomResourceDefinitionCondition, InType: reflect.TypeOf(&CustomResourceDefinitionCondition{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CustomResourceDefinitionList, InType: reflect.TypeOf(&CustomResourceDefinitionList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CustomResourceDefinitionNames, InType: reflect.TypeOf(&CustomResourceDefinitionNames{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CustomResourceDefinitionSpec, InType: reflect.TypeOf(&CustomResourceDefinitionSpec{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CustomResourceDefinitionStatus, InType: reflect.TypeOf(&CustomResourceDefinitionStatus{})}, ) } -// DeepCopy_v1alpha1_CustomResourceDefinition is an autogenerated deepcopy function. -func DeepCopy_v1alpha1_CustomResourceDefinition(in interface{}, out interface{}, c *conversion.Cloner) error { +// DeepCopy_v1beta1_CustomResourceDefinition is an autogenerated deepcopy function. +func DeepCopy_v1beta1_CustomResourceDefinition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomResourceDefinition) out := out.(*CustomResourceDefinition) @@ -69,8 +69,8 @@ func DeepCopy_v1alpha1_CustomResourceDefinition(in interface{}, out interface{}, } } -// DeepCopy_v1alpha1_CustomResourceDefinitionCondition is an autogenerated deepcopy function. -func DeepCopy_v1alpha1_CustomResourceDefinitionCondition(in interface{}, out interface{}, c *conversion.Cloner) error { +// DeepCopy_v1beta1_CustomResourceDefinitionCondition is an autogenerated deepcopy function. +func DeepCopy_v1beta1_CustomResourceDefinitionCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomResourceDefinitionCondition) out := out.(*CustomResourceDefinitionCondition) @@ -80,8 +80,8 @@ func DeepCopy_v1alpha1_CustomResourceDefinitionCondition(in interface{}, out int } } -// DeepCopy_v1alpha1_CustomResourceDefinitionList is an autogenerated deepcopy function. -func DeepCopy_v1alpha1_CustomResourceDefinitionList(in interface{}, out interface{}, c *conversion.Cloner) error { +// DeepCopy_v1beta1_CustomResourceDefinitionList is an autogenerated deepcopy function. +func DeepCopy_v1beta1_CustomResourceDefinitionList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomResourceDefinitionList) out := out.(*CustomResourceDefinitionList) @@ -101,8 +101,8 @@ func DeepCopy_v1alpha1_CustomResourceDefinitionList(in interface{}, out interfac } } -// DeepCopy_v1alpha1_CustomResourceDefinitionNames is an autogenerated deepcopy function. -func DeepCopy_v1alpha1_CustomResourceDefinitionNames(in interface{}, out interface{}, c *conversion.Cloner) error { +// DeepCopy_v1beta1_CustomResourceDefinitionNames is an autogenerated deepcopy function. +func DeepCopy_v1beta1_CustomResourceDefinitionNames(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomResourceDefinitionNames) out := out.(*CustomResourceDefinitionNames) @@ -116,8 +116,8 @@ func DeepCopy_v1alpha1_CustomResourceDefinitionNames(in interface{}, out interfa } } -// DeepCopy_v1alpha1_CustomResourceDefinitionSpec is an autogenerated deepcopy function. -func DeepCopy_v1alpha1_CustomResourceDefinitionSpec(in interface{}, out interface{}, c *conversion.Cloner) error { +// DeepCopy_v1beta1_CustomResourceDefinitionSpec is an autogenerated deepcopy function. +func DeepCopy_v1beta1_CustomResourceDefinitionSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomResourceDefinitionSpec) out := out.(*CustomResourceDefinitionSpec) @@ -131,8 +131,8 @@ func DeepCopy_v1alpha1_CustomResourceDefinitionSpec(in interface{}, out interfac } } -// DeepCopy_v1alpha1_CustomResourceDefinitionStatus is an autogenerated deepcopy function. -func DeepCopy_v1alpha1_CustomResourceDefinitionStatus(in interface{}, out interface{}, c *conversion.Cloner) error { +// DeepCopy_v1beta1_CustomResourceDefinitionStatus is an autogenerated deepcopy function. +func DeepCopy_v1beta1_CustomResourceDefinitionStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomResourceDefinitionStatus) out := out.(*CustomResourceDefinitionStatus) diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apiserver/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/apiserver/BUILD index 7bcbf18de77be..41702b8e5b671 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/apiserver/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/apiserver/BUILD @@ -47,7 +47,7 @@ go_library( "//vendor/k8s.io/client-go/util/workqueue:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/install:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/internalclientset:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions:go_default_library", diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apiserver/apiserver.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/apiserver/apiserver.go index dec369eb56f46..5c8d1799ce557 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/apiserver/apiserver.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/apiserver/apiserver.go @@ -17,9 +17,13 @@ limitations under the License. package apiserver import ( + "fmt" "net/http" + "os" "time" + "github.com/golang/glog" + "k8s.io/apimachinery/pkg/apimachinery/announced" "k8s.io/apimachinery/pkg/apimachinery/registered" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -34,7 +38,7 @@ import ( "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions" "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/install" - "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" "k8s.io/kube-apiextensions-server/pkg/client/clientset/internalclientset" internalinformers "k8s.io/kube-apiextensions-server/pkg/client/informers/internalversion" "k8s.io/kube-apiextensions-server/pkg/controller/finalizer" @@ -107,7 +111,7 @@ func (c *Config) SkipComplete() completedConfig { // New returns a new instance of CustomResourceDefinitions from the given config. func (c completedConfig) New(delegationTarget genericapiserver.DelegationTarget) (*CustomResourceDefinitions, error) { - genericServer, err := c.Config.GenericConfig.SkipComplete().New(delegationTarget) // completion is done in Complete, no need for a second time + genericServer, err := c.Config.GenericConfig.SkipComplete().New("kube-apiextensions-server", delegationTarget) // completion is done in Complete, no need for a second time if err != nil { return nil, err } @@ -117,12 +121,12 @@ func (c completedConfig) New(delegationTarget genericapiserver.DelegationTarget) } apiGroupInfo := genericapiserver.NewDefaultAPIGroupInfo(apiextensions.GroupName, registry, Scheme, metav1.ParameterCodec, Codecs) - apiGroupInfo.GroupMeta.GroupVersion = v1alpha1.SchemeGroupVersion + apiGroupInfo.GroupMeta.GroupVersion = v1beta1.SchemeGroupVersion customResourceDefintionStorage := customresourcedefinition.NewREST(Scheme, c.GenericConfig.RESTOptionsGetter) - v1alpha1storage := map[string]rest.Storage{} - v1alpha1storage["customresourcedefinitions"] = customResourceDefintionStorage - v1alpha1storage["customresourcedefinitions/status"] = customresourcedefinition.NewStatusREST(Scheme, customResourceDefintionStorage) - apiGroupInfo.VersionedResourcesStorageMap["v1alpha1"] = v1alpha1storage + v1beta1storage := map[string]rest.Storage{} + v1beta1storage["customresourcedefinitions"] = customResourceDefintionStorage + v1beta1storage["customresourcedefinitions/status"] = customresourcedefinition.NewStatusREST(Scheme, customResourceDefintionStorage) + apiGroupInfo.VersionedResourcesStorageMap["v1beta1"] = v1beta1storage if err := s.GenericAPIServer.InstallAPIGroup(&apiGroupInfo); err != nil { return nil, err @@ -130,7 +134,18 @@ func (c completedConfig) New(delegationTarget genericapiserver.DelegationTarget) crdClient, err := internalclientset.NewForConfig(s.GenericAPIServer.LoopbackClientConfig) if err != nil { - return nil, err + // it's really bad that this is leaking here, but until we can fix the test (which I'm pretty sure isn't even testing what it wants to test), + // we need to be able to move forward + kubeAPIVersions := os.Getenv("KUBE_API_VERSIONS") + if len(kubeAPIVersions) == 0 { + return nil, fmt.Errorf("failed to create clientset: %v", err) + } + + // KUBE_API_VERSIONS is used in test-update-storage-objects.sh, disabling a number of API + // groups. This leads to a nil client above and undefined behaviour further down. + // + // TODO: get rid of KUBE_API_VERSIONS or define sane behaviour if set + glog.Errorf("Failed to create clientset with KUBE_API_VERSIONS=%q. KUBE_API_VERSIONS is only for testing. Things will break.", kubeAPIVersions) } s.Informers = internalinformers.NewSharedInformerFactory(crdClient, 5*time.Minute) @@ -156,8 +171,8 @@ func (c completedConfig) New(delegationTarget genericapiserver.DelegationTarget) c.CRDRESTOptionsGetter, c.GenericConfig.AdmissionControl, ) - s.GenericAPIServer.Handler.PostGoRestfulMux.Handle("/apis", crdHandler) - s.GenericAPIServer.Handler.PostGoRestfulMux.HandlePrefix("/apis/", crdHandler) + s.GenericAPIServer.Handler.NonGoRestfulMux.Handle("/apis", crdHandler) + s.GenericAPIServer.Handler.NonGoRestfulMux.HandlePrefix("/apis/", crdHandler) crdController := NewDiscoveryController(s.Informers.Apiextensions().InternalVersion().CustomResourceDefinitions(), versionDiscoveryHandler, groupDiscoveryHandler, c.GenericConfig.RequestContextMapper) namingController := status.NewNamingConditionController(s.Informers.Apiextensions().InternalVersion().CustomResourceDefinitions(), crdClient) @@ -167,6 +182,11 @@ func (c completedConfig) New(delegationTarget genericapiserver.DelegationTarget) crdHandler, ) + // this only happens when KUBE_API_VERSIONS is set. We must return without adding poststarthooks which would affect healthz + if crdClient == nil { + return s, nil + } + s.GenericAPIServer.AddPostStartHook("start-apiextensions-informers", func(context genericapiserver.PostStartHookContext) error { s.Informers.Start(context.StopCh) return nil diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/apiserver/customresource_handler.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/apiserver/customresource_handler.go index dcbfd84a4f41d..435d21c4f69bd 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/apiserver/customresource_handler.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/apiserver/customresource_handler.go @@ -247,13 +247,9 @@ func (r *crdHandler) removeDeadStorage() { // GetCustomResourceListerCollectionDeleter returns the ListerCollectionDeleter for // the given uid, or nil if one does not exist. -func (r *crdHandler) GetCustomResourceListerCollectionDeleter(uid types.UID) finalizer.ListerCollectionDeleter { - storageMap := r.customStorage.Load().(crdStorageMap) - ret, ok := storageMap[uid] - if !ok { - return nil - } - return ret.storage +func (r *crdHandler) GetCustomResourceListerCollectionDeleter(crd *apiextensions.CustomResourceDefinition) finalizer.ListerCollectionDeleter { + info := r.getServingInfoFor(crd) + return info.storage } func (r *crdHandler) getServingInfoFor(crd *apiextensions.CustomResourceDefinition) *crdInfo { @@ -279,6 +275,17 @@ func (r *crdHandler) getServingInfoFor(crd *apiextensions.CustomResourceDefiniti r.restOptionsGetter, ) + // When new REST storage is created, the storage cacher for the CR starts asynchronously. + // REST API operations return like list use the RV of etcd, but the storage cacher's reflector's list + // can get a different RV because etcd can be touched in between the initial list operation (if that's what you're doing first) + // and the storage cache reflector starting. + // Later, you can issue a watch with the REST apis list.RV and end up earlier than the storage cacher. + // The time window is really narrow, but it can happen. The simplest "solution" is to wait + // briefly for the storage cache to start before we return out new storage so its more likely that we'll have valid + // resource versions for the watch cache. We don't expose cache status outside of the caching layer + // so I can't think of way to determine it reliably. + time.Sleep(1 * time.Second) + parameterScheme := runtime.NewScheme() parameterScheme.AddUnversionedTypes(schema.GroupVersion{Group: crd.Spec.Group, Version: crd.Spec.Version}, &metav1.ListOptions{}, diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/BUILD index 7123a33a2ea1b..2c05f71234cad 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/BUILD @@ -19,6 +19,6 @@ go_library( "//vendor/k8s.io/client-go/discovery:go_default_library", "//vendor/k8s.io/client-go/rest:go_default_library", "//vendor/k8s.io/client-go/util/flowcontrol:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1:go_default_library", ], ) diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/clientset.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/clientset.go index ff05382140958..7a2f136c15db0 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/clientset.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/clientset.go @@ -21,38 +21,38 @@ import ( discovery "k8s.io/client-go/discovery" rest "k8s.io/client-go/rest" flowcontrol "k8s.io/client-go/util/flowcontrol" - apiextensionsv1alpha1 "k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1" + apiextensionsv1beta1 "k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1" ) type Interface interface { Discovery() discovery.DiscoveryInterface - ApiextensionsV1alpha1() apiextensionsv1alpha1.ApiextensionsV1alpha1Interface + ApiextensionsV1beta1() apiextensionsv1beta1.ApiextensionsV1beta1Interface // Deprecated: please explicitly pick a version if possible. - Apiextensions() apiextensionsv1alpha1.ApiextensionsV1alpha1Interface + Apiextensions() apiextensionsv1beta1.ApiextensionsV1beta1Interface } // Clientset contains the clients for groups. Each group has exactly one // version included in a Clientset. type Clientset struct { *discovery.DiscoveryClient - *apiextensionsv1alpha1.ApiextensionsV1alpha1Client + *apiextensionsv1beta1.ApiextensionsV1beta1Client } -// ApiextensionsV1alpha1 retrieves the ApiextensionsV1alpha1Client -func (c *Clientset) ApiextensionsV1alpha1() apiextensionsv1alpha1.ApiextensionsV1alpha1Interface { +// ApiextensionsV1beta1 retrieves the ApiextensionsV1beta1Client +func (c *Clientset) ApiextensionsV1beta1() apiextensionsv1beta1.ApiextensionsV1beta1Interface { if c == nil { return nil } - return c.ApiextensionsV1alpha1Client + return c.ApiextensionsV1beta1Client } // Deprecated: Apiextensions retrieves the default version of ApiextensionsClient. // Please explicitly pick a version. -func (c *Clientset) Apiextensions() apiextensionsv1alpha1.ApiextensionsV1alpha1Interface { +func (c *Clientset) Apiextensions() apiextensionsv1beta1.ApiextensionsV1beta1Interface { if c == nil { return nil } - return c.ApiextensionsV1alpha1Client + return c.ApiextensionsV1beta1Client } // Discovery retrieves the DiscoveryClient @@ -71,7 +71,7 @@ func NewForConfig(c *rest.Config) (*Clientset, error) { } var cs Clientset var err error - cs.ApiextensionsV1alpha1Client, err = apiextensionsv1alpha1.NewForConfig(&configShallowCopy) + cs.ApiextensionsV1beta1Client, err = apiextensionsv1beta1.NewForConfig(&configShallowCopy) if err != nil { return nil, err } @@ -88,7 +88,7 @@ func NewForConfig(c *rest.Config) (*Clientset, error) { // panics if there is an error in the config. func NewForConfigOrDie(c *rest.Config) *Clientset { var cs Clientset - cs.ApiextensionsV1alpha1Client = apiextensionsv1alpha1.NewForConfigOrDie(c) + cs.ApiextensionsV1beta1Client = apiextensionsv1beta1.NewForConfigOrDie(c) cs.DiscoveryClient = discovery.NewDiscoveryClientForConfigOrDie(c) return &cs @@ -97,7 +97,7 @@ func NewForConfigOrDie(c *rest.Config) *Clientset { // New creates a new Clientset for the given RESTClient. func New(c rest.Interface) *Clientset { var cs Clientset - cs.ApiextensionsV1alpha1Client = apiextensionsv1alpha1.New(c) + cs.ApiextensionsV1beta1Client = apiextensionsv1beta1.New(c) cs.DiscoveryClient = discovery.NewDiscoveryClient(c) return &cs diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/fake/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/fake/BUILD index cd82496d120d5..3e999e1d64fff 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/fake/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/fake/BUILD @@ -24,9 +24,9 @@ go_library( "//vendor/k8s.io/client-go/discovery:go_default_library", "//vendor/k8s.io/client-go/discovery/fake:go_default_library", "//vendor/k8s.io/client-go/testing:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/fake:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake:go_default_library", ], ) diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/fake/clientset_generated.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/fake/clientset_generated.go index 2689ae594fdc9..ef5a1d8607731 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/fake/clientset_generated.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/fake/clientset_generated.go @@ -23,8 +23,8 @@ import ( fakediscovery "k8s.io/client-go/discovery/fake" "k8s.io/client-go/testing" clientset "k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset" - apiextensionsv1alpha1 "k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1" - fakeapiextensionsv1alpha1 "k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/fake" + apiextensionsv1beta1 "k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1" + fakeapiextensionsv1beta1 "k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake" ) // NewSimpleClientset returns a clientset that will respond with the provided objects. @@ -60,12 +60,12 @@ func (c *Clientset) Discovery() discovery.DiscoveryInterface { var _ clientset.Interface = &Clientset{} -// ApiextensionsV1alpha1 retrieves the ApiextensionsV1alpha1Client -func (c *Clientset) ApiextensionsV1alpha1() apiextensionsv1alpha1.ApiextensionsV1alpha1Interface { - return &fakeapiextensionsv1alpha1.FakeApiextensionsV1alpha1{Fake: &c.Fake} +// ApiextensionsV1beta1 retrieves the ApiextensionsV1beta1Client +func (c *Clientset) ApiextensionsV1beta1() apiextensionsv1beta1.ApiextensionsV1beta1Interface { + return &fakeapiextensionsv1beta1.FakeApiextensionsV1beta1{Fake: &c.Fake} } -// Apiextensions retrieves the ApiextensionsV1alpha1Client -func (c *Clientset) Apiextensions() apiextensionsv1alpha1.ApiextensionsV1alpha1Interface { - return &fakeapiextensionsv1alpha1.FakeApiextensionsV1alpha1{Fake: &c.Fake} +// Apiextensions retrieves the ApiextensionsV1beta1Client +func (c *Clientset) Apiextensions() apiextensionsv1beta1.ApiextensionsV1beta1Interface { + return &fakeapiextensionsv1beta1.FakeApiextensionsV1beta1{Fake: &c.Fake} } diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/fake/register.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/fake/register.go index 9c2b393867609..d31cd113b68f0 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/fake/register.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/fake/register.go @@ -21,7 +21,7 @@ import ( runtime "k8s.io/apimachinery/pkg/runtime" schema "k8s.io/apimachinery/pkg/runtime/schema" serializer "k8s.io/apimachinery/pkg/runtime/serializer" - apiextensionsv1alpha1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + apiextensionsv1beta1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" ) var scheme = runtime.NewScheme() @@ -48,6 +48,6 @@ func init() { // After this, RawExtensions in Kubernetes types will serialize kube-aggregator types // correctly. func AddToScheme(scheme *runtime.Scheme) { - apiextensionsv1alpha1.AddToScheme(scheme) + apiextensionsv1beta1.AddToScheme(scheme) } diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/scheme/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/scheme/BUILD index 56cf2c632dbe1..240a4292e66e2 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/scheme/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/scheme/BUILD @@ -19,6 +19,6 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1:go_default_library", ], ) diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/scheme/register.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/scheme/register.go index 05c68e870d6a0..f0688a15171d6 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/scheme/register.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/scheme/register.go @@ -21,7 +21,7 @@ import ( runtime "k8s.io/apimachinery/pkg/runtime" schema "k8s.io/apimachinery/pkg/runtime/schema" serializer "k8s.io/apimachinery/pkg/runtime/serializer" - apiextensionsv1alpha1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + apiextensionsv1beta1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" ) var Scheme = runtime.NewScheme() @@ -48,6 +48,6 @@ func init() { // After this, RawExtensions in Kubernetes types will serialize kube-aggregator types // correctly. func AddToScheme(scheme *runtime.Scheme) { - apiextensionsv1alpha1.AddToScheme(scheme) + apiextensionsv1beta1.AddToScheme(scheme) } diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/BUILD similarity index 95% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/BUILD rename to staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/BUILD index 4e6c23682c238..7bd7069dea4e7 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/BUILD @@ -22,7 +22,7 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", "//vendor/k8s.io/client-go/rest:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/scheme:go_default_library", ], ) diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/apiextensions_client.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/apiextensions_client.go similarity index 61% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/apiextensions_client.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/apiextensions_client.go index 697faee2919ab..8799838be2232 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/apiextensions_client.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/apiextensions_client.go @@ -14,31 +14,31 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package v1beta1 import ( serializer "k8s.io/apimachinery/pkg/runtime/serializer" rest "k8s.io/client-go/rest" - v1alpha1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + v1beta1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" "k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/scheme" ) -type ApiextensionsV1alpha1Interface interface { +type ApiextensionsV1beta1Interface interface { RESTClient() rest.Interface CustomResourceDefinitionsGetter } -// ApiextensionsV1alpha1Client is used to interact with features provided by the apiextensions.k8s.io group. -type ApiextensionsV1alpha1Client struct { +// ApiextensionsV1beta1Client is used to interact with features provided by the apiextensions.k8s.io group. +type ApiextensionsV1beta1Client struct { restClient rest.Interface } -func (c *ApiextensionsV1alpha1Client) CustomResourceDefinitions() CustomResourceDefinitionInterface { +func (c *ApiextensionsV1beta1Client) CustomResourceDefinitions() CustomResourceDefinitionInterface { return newCustomResourceDefinitions(c) } -// NewForConfig creates a new ApiextensionsV1alpha1Client for the given config. -func NewForConfig(c *rest.Config) (*ApiextensionsV1alpha1Client, error) { +// NewForConfig creates a new ApiextensionsV1beta1Client for the given config. +func NewForConfig(c *rest.Config) (*ApiextensionsV1beta1Client, error) { config := *c if err := setConfigDefaults(&config); err != nil { return nil, err @@ -47,12 +47,12 @@ func NewForConfig(c *rest.Config) (*ApiextensionsV1alpha1Client, error) { if err != nil { return nil, err } - return &ApiextensionsV1alpha1Client{client}, nil + return &ApiextensionsV1beta1Client{client}, nil } -// NewForConfigOrDie creates a new ApiextensionsV1alpha1Client for the given config and +// NewForConfigOrDie creates a new ApiextensionsV1beta1Client for the given config and // panics if there is an error in the config. -func NewForConfigOrDie(c *rest.Config) *ApiextensionsV1alpha1Client { +func NewForConfigOrDie(c *rest.Config) *ApiextensionsV1beta1Client { client, err := NewForConfig(c) if err != nil { panic(err) @@ -60,13 +60,13 @@ func NewForConfigOrDie(c *rest.Config) *ApiextensionsV1alpha1Client { return client } -// New creates a new ApiextensionsV1alpha1Client for the given RESTClient. -func New(c rest.Interface) *ApiextensionsV1alpha1Client { - return &ApiextensionsV1alpha1Client{c} +// New creates a new ApiextensionsV1beta1Client for the given RESTClient. +func New(c rest.Interface) *ApiextensionsV1beta1Client { + return &ApiextensionsV1beta1Client{c} } func setConfigDefaults(config *rest.Config) error { - gv := v1alpha1.SchemeGroupVersion + gv := v1beta1.SchemeGroupVersion config.GroupVersion = &gv config.APIPath = "/apis" config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} @@ -80,7 +80,7 @@ func setConfigDefaults(config *rest.Config) error { // RESTClient returns a RESTClient that is used to communicate // with API server by this client implementation. -func (c *ApiextensionsV1alpha1Client) RESTClient() rest.Interface { +func (c *ApiextensionsV1beta1Client) RESTClient() rest.Interface { if c == nil { return nil } diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/customresourcedefinition.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/customresourcedefinition.go similarity index 76% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/customresourcedefinition.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/customresourcedefinition.go index ea791adbe7643..00cfe919d8b95 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/customresourcedefinition.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/customresourcedefinition.go @@ -14,14 +14,14 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package v1beta1 import ( v1 "k8s.io/apimachinery/pkg/apis/meta/v1" types "k8s.io/apimachinery/pkg/types" watch "k8s.io/apimachinery/pkg/watch" rest "k8s.io/client-go/rest" - v1alpha1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + v1beta1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" scheme "k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/scheme" ) @@ -33,15 +33,15 @@ type CustomResourceDefinitionsGetter interface { // CustomResourceDefinitionInterface has methods to work with CustomResourceDefinition resources. type CustomResourceDefinitionInterface interface { - Create(*v1alpha1.CustomResourceDefinition) (*v1alpha1.CustomResourceDefinition, error) - Update(*v1alpha1.CustomResourceDefinition) (*v1alpha1.CustomResourceDefinition, error) - UpdateStatus(*v1alpha1.CustomResourceDefinition) (*v1alpha1.CustomResourceDefinition, error) + Create(*v1beta1.CustomResourceDefinition) (*v1beta1.CustomResourceDefinition, error) + Update(*v1beta1.CustomResourceDefinition) (*v1beta1.CustomResourceDefinition, error) + UpdateStatus(*v1beta1.CustomResourceDefinition) (*v1beta1.CustomResourceDefinition, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string, options v1.GetOptions) (*v1alpha1.CustomResourceDefinition, error) - List(opts v1.ListOptions) (*v1alpha1.CustomResourceDefinitionList, error) + Get(name string, options v1.GetOptions) (*v1beta1.CustomResourceDefinition, error) + List(opts v1.ListOptions) (*v1beta1.CustomResourceDefinitionList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.CustomResourceDefinition, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.CustomResourceDefinition, err error) CustomResourceDefinitionExpansion } @@ -51,15 +51,15 @@ type customResourceDefinitions struct { } // newCustomResourceDefinitions returns a CustomResourceDefinitions -func newCustomResourceDefinitions(c *ApiextensionsV1alpha1Client) *customResourceDefinitions { +func newCustomResourceDefinitions(c *ApiextensionsV1beta1Client) *customResourceDefinitions { return &customResourceDefinitions{ client: c.RESTClient(), } } // Create takes the representation of a customResourceDefinition and creates it. Returns the server's representation of the customResourceDefinition, and an error, if there is any. -func (c *customResourceDefinitions) Create(customResourceDefinition *v1alpha1.CustomResourceDefinition) (result *v1alpha1.CustomResourceDefinition, err error) { - result = &v1alpha1.CustomResourceDefinition{} +func (c *customResourceDefinitions) Create(customResourceDefinition *v1beta1.CustomResourceDefinition) (result *v1beta1.CustomResourceDefinition, err error) { + result = &v1beta1.CustomResourceDefinition{} err = c.client.Post(). Resource("customresourcedefinitions"). Body(customResourceDefinition). @@ -69,8 +69,8 @@ func (c *customResourceDefinitions) Create(customResourceDefinition *v1alpha1.Cu } // Update takes the representation of a customResourceDefinition and updates it. Returns the server's representation of the customResourceDefinition, and an error, if there is any. -func (c *customResourceDefinitions) Update(customResourceDefinition *v1alpha1.CustomResourceDefinition) (result *v1alpha1.CustomResourceDefinition, err error) { - result = &v1alpha1.CustomResourceDefinition{} +func (c *customResourceDefinitions) Update(customResourceDefinition *v1beta1.CustomResourceDefinition) (result *v1beta1.CustomResourceDefinition, err error) { + result = &v1beta1.CustomResourceDefinition{} err = c.client.Put(). Resource("customresourcedefinitions"). Name(customResourceDefinition.Name). @@ -83,8 +83,8 @@ func (c *customResourceDefinitions) Update(customResourceDefinition *v1alpha1.Cu // UpdateStatus was generated because the type contains a Status member. // Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). -func (c *customResourceDefinitions) UpdateStatus(customResourceDefinition *v1alpha1.CustomResourceDefinition) (result *v1alpha1.CustomResourceDefinition, err error) { - result = &v1alpha1.CustomResourceDefinition{} +func (c *customResourceDefinitions) UpdateStatus(customResourceDefinition *v1beta1.CustomResourceDefinition) (result *v1beta1.CustomResourceDefinition, err error) { + result = &v1beta1.CustomResourceDefinition{} err = c.client.Put(). Resource("customresourcedefinitions"). Name(customResourceDefinition.Name). @@ -116,8 +116,8 @@ func (c *customResourceDefinitions) DeleteCollection(options *v1.DeleteOptions, } // Get takes name of the customResourceDefinition, and returns the corresponding customResourceDefinition object, and an error if there is any. -func (c *customResourceDefinitions) Get(name string, options v1.GetOptions) (result *v1alpha1.CustomResourceDefinition, err error) { - result = &v1alpha1.CustomResourceDefinition{} +func (c *customResourceDefinitions) Get(name string, options v1.GetOptions) (result *v1beta1.CustomResourceDefinition, err error) { + result = &v1beta1.CustomResourceDefinition{} err = c.client.Get(). Resource("customresourcedefinitions"). Name(name). @@ -128,8 +128,8 @@ func (c *customResourceDefinitions) Get(name string, options v1.GetOptions) (res } // List takes label and field selectors, and returns the list of CustomResourceDefinitions that match those selectors. -func (c *customResourceDefinitions) List(opts v1.ListOptions) (result *v1alpha1.CustomResourceDefinitionList, err error) { - result = &v1alpha1.CustomResourceDefinitionList{} +func (c *customResourceDefinitions) List(opts v1.ListOptions) (result *v1beta1.CustomResourceDefinitionList, err error) { + result = &v1beta1.CustomResourceDefinitionList{} err = c.client.Get(). Resource("customresourcedefinitions"). VersionedParams(&opts, scheme.ParameterCodec). @@ -148,8 +148,8 @@ func (c *customResourceDefinitions) Watch(opts v1.ListOptions) (watch.Interface, } // Patch applies the patch and returns the patched customResourceDefinition. -func (c *customResourceDefinitions) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.CustomResourceDefinition, err error) { - result = &v1alpha1.CustomResourceDefinition{} +func (c *customResourceDefinitions) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.CustomResourceDefinition, err error) { + result = &v1beta1.CustomResourceDefinition{} err = c.client.Patch(pt). Resource("customresourcedefinitions"). SubResource(subresources...). diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/doc.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/doc.go new file mode 100644 index 0000000000000..11b5238972076 --- /dev/null +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package has the automatically generated typed clients. +package v1beta1 diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/fake/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake/BUILD similarity index 90% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/fake/BUILD rename to staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake/BUILD index c2f776aba68bc..ab772e059657d 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/fake/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake/BUILD @@ -23,7 +23,7 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", "//vendor/k8s.io/client-go/rest:go_default_library", "//vendor/k8s.io/client-go/testing:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1:go_default_library", ], ) diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake/doc.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake/doc.go new file mode 100644 index 0000000000000..c6548330a0d0a --- /dev/null +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +// This package is generated by client-gen with custom arguments. + +// Package fake has the automatically generated clients. +package fake diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/fake/fake_apiextensions_client.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake/fake_apiextensions_client.go similarity index 73% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/fake/fake_apiextensions_client.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake/fake_apiextensions_client.go index 5745a44657793..38d09f1805c6d 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/fake/fake_apiextensions_client.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake/fake_apiextensions_client.go @@ -19,20 +19,20 @@ package fake import ( rest "k8s.io/client-go/rest" testing "k8s.io/client-go/testing" - v1alpha1 "k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1" + v1beta1 "k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1" ) -type FakeApiextensionsV1alpha1 struct { +type FakeApiextensionsV1beta1 struct { *testing.Fake } -func (c *FakeApiextensionsV1alpha1) CustomResourceDefinitions() v1alpha1.CustomResourceDefinitionInterface { +func (c *FakeApiextensionsV1beta1) CustomResourceDefinitions() v1beta1.CustomResourceDefinitionInterface { return &FakeCustomResourceDefinitions{c} } // RESTClient returns a RESTClient that is used to communicate // with API server by this client implementation. -func (c *FakeApiextensionsV1alpha1) RESTClient() rest.Interface { +func (c *FakeApiextensionsV1beta1) RESTClient() rest.Interface { var ret *rest.RESTClient return ret } diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/fake/fake_customresourcedefinition.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake/fake_customresourcedefinition.go similarity index 64% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/fake/fake_customresourcedefinition.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake/fake_customresourcedefinition.go index 6a8c856c0b931..5dc54244937e3 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/fake/fake_customresourcedefinition.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/fake/fake_customresourcedefinition.go @@ -23,70 +23,70 @@ import ( types "k8s.io/apimachinery/pkg/types" watch "k8s.io/apimachinery/pkg/watch" testing "k8s.io/client-go/testing" - v1alpha1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + v1beta1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" ) // FakeCustomResourceDefinitions implements CustomResourceDefinitionInterface type FakeCustomResourceDefinitions struct { - Fake *FakeApiextensionsV1alpha1 + Fake *FakeApiextensionsV1beta1 } -var customresourcedefinitionsResource = schema.GroupVersionResource{Group: "apiextensions.k8s.io", Version: "v1alpha1", Resource: "customresourcedefinitions"} +var customresourcedefinitionsResource = schema.GroupVersionResource{Group: "apiextensions.k8s.io", Version: "v1beta1", Resource: "customresourcedefinitions"} -var customresourcedefinitionsKind = schema.GroupVersionKind{Group: "apiextensions.k8s.io", Version: "v1alpha1", Kind: "CustomResourceDefinition"} +var customresourcedefinitionsKind = schema.GroupVersionKind{Group: "apiextensions.k8s.io", Version: "v1beta1", Kind: "CustomResourceDefinition"} -func (c *FakeCustomResourceDefinitions) Create(customResourceDefinition *v1alpha1.CustomResourceDefinition) (result *v1alpha1.CustomResourceDefinition, err error) { +func (c *FakeCustomResourceDefinitions) Create(customResourceDefinition *v1beta1.CustomResourceDefinition) (result *v1beta1.CustomResourceDefinition, err error) { obj, err := c.Fake. - Invokes(testing.NewRootCreateAction(customresourcedefinitionsResource, customResourceDefinition), &v1alpha1.CustomResourceDefinition{}) + Invokes(testing.NewRootCreateAction(customresourcedefinitionsResource, customResourceDefinition), &v1beta1.CustomResourceDefinition{}) if obj == nil { return nil, err } - return obj.(*v1alpha1.CustomResourceDefinition), err + return obj.(*v1beta1.CustomResourceDefinition), err } -func (c *FakeCustomResourceDefinitions) Update(customResourceDefinition *v1alpha1.CustomResourceDefinition) (result *v1alpha1.CustomResourceDefinition, err error) { +func (c *FakeCustomResourceDefinitions) Update(customResourceDefinition *v1beta1.CustomResourceDefinition) (result *v1beta1.CustomResourceDefinition, err error) { obj, err := c.Fake. - Invokes(testing.NewRootUpdateAction(customresourcedefinitionsResource, customResourceDefinition), &v1alpha1.CustomResourceDefinition{}) + Invokes(testing.NewRootUpdateAction(customresourcedefinitionsResource, customResourceDefinition), &v1beta1.CustomResourceDefinition{}) if obj == nil { return nil, err } - return obj.(*v1alpha1.CustomResourceDefinition), err + return obj.(*v1beta1.CustomResourceDefinition), err } -func (c *FakeCustomResourceDefinitions) UpdateStatus(customResourceDefinition *v1alpha1.CustomResourceDefinition) (*v1alpha1.CustomResourceDefinition, error) { +func (c *FakeCustomResourceDefinitions) UpdateStatus(customResourceDefinition *v1beta1.CustomResourceDefinition) (*v1beta1.CustomResourceDefinition, error) { obj, err := c.Fake. - Invokes(testing.NewRootUpdateSubresourceAction(customresourcedefinitionsResource, "status", customResourceDefinition), &v1alpha1.CustomResourceDefinition{}) + Invokes(testing.NewRootUpdateSubresourceAction(customresourcedefinitionsResource, "status", customResourceDefinition), &v1beta1.CustomResourceDefinition{}) if obj == nil { return nil, err } - return obj.(*v1alpha1.CustomResourceDefinition), err + return obj.(*v1beta1.CustomResourceDefinition), err } func (c *FakeCustomResourceDefinitions) Delete(name string, options *v1.DeleteOptions) error { _, err := c.Fake. - Invokes(testing.NewRootDeleteAction(customresourcedefinitionsResource, name), &v1alpha1.CustomResourceDefinition{}) + Invokes(testing.NewRootDeleteAction(customresourcedefinitionsResource, name), &v1beta1.CustomResourceDefinition{}) return err } func (c *FakeCustomResourceDefinitions) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { action := testing.NewRootDeleteCollectionAction(customresourcedefinitionsResource, listOptions) - _, err := c.Fake.Invokes(action, &v1alpha1.CustomResourceDefinitionList{}) + _, err := c.Fake.Invokes(action, &v1beta1.CustomResourceDefinitionList{}) return err } -func (c *FakeCustomResourceDefinitions) Get(name string, options v1.GetOptions) (result *v1alpha1.CustomResourceDefinition, err error) { +func (c *FakeCustomResourceDefinitions) Get(name string, options v1.GetOptions) (result *v1beta1.CustomResourceDefinition, err error) { obj, err := c.Fake. - Invokes(testing.NewRootGetAction(customresourcedefinitionsResource, name), &v1alpha1.CustomResourceDefinition{}) + Invokes(testing.NewRootGetAction(customresourcedefinitionsResource, name), &v1beta1.CustomResourceDefinition{}) if obj == nil { return nil, err } - return obj.(*v1alpha1.CustomResourceDefinition), err + return obj.(*v1beta1.CustomResourceDefinition), err } -func (c *FakeCustomResourceDefinitions) List(opts v1.ListOptions) (result *v1alpha1.CustomResourceDefinitionList, err error) { +func (c *FakeCustomResourceDefinitions) List(opts v1.ListOptions) (result *v1beta1.CustomResourceDefinitionList, err error) { obj, err := c.Fake. - Invokes(testing.NewRootListAction(customresourcedefinitionsResource, customresourcedefinitionsKind, opts), &v1alpha1.CustomResourceDefinitionList{}) + Invokes(testing.NewRootListAction(customresourcedefinitionsResource, customresourcedefinitionsKind, opts), &v1beta1.CustomResourceDefinitionList{}) if obj == nil { return nil, err } @@ -95,8 +95,8 @@ func (c *FakeCustomResourceDefinitions) List(opts v1.ListOptions) (result *v1alp if label == nil { label = labels.Everything() } - list := &v1alpha1.CustomResourceDefinitionList{} - for _, item := range obj.(*v1alpha1.CustomResourceDefinitionList).Items { + list := &v1beta1.CustomResourceDefinitionList{} + for _, item := range obj.(*v1beta1.CustomResourceDefinitionList).Items { if label.Matches(labels.Set(item.Labels)) { list.Items = append(list.Items, item) } @@ -111,11 +111,11 @@ func (c *FakeCustomResourceDefinitions) Watch(opts v1.ListOptions) (watch.Interf } // Patch applies the patch and returns the patched customResourceDefinition. -func (c *FakeCustomResourceDefinitions) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.CustomResourceDefinition, err error) { +func (c *FakeCustomResourceDefinitions) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.CustomResourceDefinition, err error) { obj, err := c.Fake. - Invokes(testing.NewRootPatchSubresourceAction(customresourcedefinitionsResource, name, data, subresources...), &v1alpha1.CustomResourceDefinition{}) + Invokes(testing.NewRootPatchSubresourceAction(customresourcedefinitionsResource, name, data, subresources...), &v1beta1.CustomResourceDefinition{}) if obj == nil { return nil, err } - return obj.(*v1alpha1.CustomResourceDefinition), err + return obj.(*v1beta1.CustomResourceDefinition), err } diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/generated_expansion.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/generated_expansion.go similarity index 97% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/generated_expansion.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/generated_expansion.go index 5a6d09982bc16..2f721078b077e 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1alpha1/generated_expansion.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset/typed/apiextensions/v1beta1/generated_expansion.go @@ -14,6 +14,6 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package v1beta1 type CustomResourceDefinitionExpansion interface{} diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/BUILD index 9be2ed18bf04b..e170c6b7544f5 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/BUILD @@ -18,7 +18,7 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", "//vendor/k8s.io/client-go/tools/cache:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/internalinterfaces:go_default_library", diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/BUILD index fcd04ad604c19..c544036fc6f00 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/BUILD @@ -12,7 +12,7 @@ go_library( srcs = ["interface.go"], tags = ["automanaged"], deps = [ - "//vendor/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1beta1:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/internalinterfaces:go_default_library", ], ) diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/interface.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/interface.go index f25b9c9534c44..bbf5807f67151 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/interface.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/interface.go @@ -19,14 +19,14 @@ limitations under the License. package apiextensions import ( - v1alpha1 "k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1alpha1" + v1beta1 "k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1beta1" internalinterfaces "k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/internalinterfaces" ) // Interface provides access to each of this group's versions. type Interface interface { - // V1alpha1 provides access to shared informers for resources in V1alpha1. - V1alpha1() v1alpha1.Interface + // V1beta1 provides access to shared informers for resources in V1beta1. + V1beta1() v1beta1.Interface } type group struct { @@ -38,7 +38,7 @@ func New(f internalinterfaces.SharedInformerFactory) Interface { return &group{f} } -// V1alpha1 returns a new v1alpha1.Interface. -func (g *group) V1alpha1() v1alpha1.Interface { - return v1alpha1.New(g.SharedInformerFactory) +// V1beta1 returns a new v1beta1.Interface. +func (g *group) V1beta1() v1beta1.Interface { + return v1beta1.New(g.SharedInformerFactory) } diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1alpha1/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1beta1/BUILD similarity index 91% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1alpha1/BUILD rename to staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1beta1/BUILD index 2724cf7f0557b..bd12cd1c3e217 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1alpha1/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1beta1/BUILD @@ -19,9 +19,9 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", "//vendor/k8s.io/client-go/tools/cache:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/internalinterfaces:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1beta1:go_default_library", ], ) diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1alpha1/customresourcedefinition.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1beta1/customresourcedefinition.go similarity index 71% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1alpha1/customresourcedefinition.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1beta1/customresourcedefinition.go index c81a5c2e129f8..c89e6792130d1 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1alpha1/customresourcedefinition.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1beta1/customresourcedefinition.go @@ -16,17 +16,17 @@ limitations under the License. // This file was automatically generated by informer-gen -package v1alpha1 +package v1beta1 import ( v1 "k8s.io/apimachinery/pkg/apis/meta/v1" runtime "k8s.io/apimachinery/pkg/runtime" watch "k8s.io/apimachinery/pkg/watch" cache "k8s.io/client-go/tools/cache" - apiextensions_v1alpha1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + apiextensions_v1beta1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" clientset "k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset" internalinterfaces "k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/internalinterfaces" - v1alpha1 "k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1alpha1" + v1beta1 "k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1beta1" time "time" ) @@ -34,7 +34,7 @@ import ( // CustomResourceDefinitions. type CustomResourceDefinitionInformer interface { Informer() cache.SharedIndexInformer - Lister() v1alpha1.CustomResourceDefinitionLister + Lister() v1beta1.CustomResourceDefinitionLister } type customResourceDefinitionInformer struct { @@ -45,13 +45,13 @@ func newCustomResourceDefinitionInformer(client clientset.Interface, resyncPerio sharedIndexInformer := cache.NewSharedIndexInformer( &cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { - return client.ApiextensionsV1alpha1().CustomResourceDefinitions().List(options) + return client.ApiextensionsV1beta1().CustomResourceDefinitions().List(options) }, WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { - return client.ApiextensionsV1alpha1().CustomResourceDefinitions().Watch(options) + return client.ApiextensionsV1beta1().CustomResourceDefinitions().Watch(options) }, }, - &apiextensions_v1alpha1.CustomResourceDefinition{}, + &apiextensions_v1beta1.CustomResourceDefinition{}, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, ) @@ -60,9 +60,9 @@ func newCustomResourceDefinitionInformer(client clientset.Interface, resyncPerio } func (f *customResourceDefinitionInformer) Informer() cache.SharedIndexInformer { - return f.factory.InformerFor(&apiextensions_v1alpha1.CustomResourceDefinition{}, newCustomResourceDefinitionInformer) + return f.factory.InformerFor(&apiextensions_v1beta1.CustomResourceDefinition{}, newCustomResourceDefinitionInformer) } -func (f *customResourceDefinitionInformer) Lister() v1alpha1.CustomResourceDefinitionLister { - return v1alpha1.NewCustomResourceDefinitionLister(f.Informer().GetIndexer()) +func (f *customResourceDefinitionInformer) Lister() v1beta1.CustomResourceDefinitionLister { + return v1beta1.NewCustomResourceDefinitionLister(f.Informer().GetIndexer()) } diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1alpha1/interface.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1beta1/interface.go similarity index 98% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1alpha1/interface.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1beta1/interface.go index 82cf7e7099f46..51feb60cd7f59 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1alpha1/interface.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/apiextensions/v1beta1/interface.go @@ -16,7 +16,7 @@ limitations under the License. // This file was automatically generated by informer-gen -package v1alpha1 +package v1beta1 import ( internalinterfaces "k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/internalinterfaces" diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/generic.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/generic.go index 909e31293eb62..d15a507ccba37 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/generic.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/informers/externalversions/generic.go @@ -22,7 +22,7 @@ import ( "fmt" schema "k8s.io/apimachinery/pkg/runtime/schema" cache "k8s.io/client-go/tools/cache" - v1alpha1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + v1beta1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" ) // GenericInformer is type of SharedIndexInformer which will locate and delegate to other @@ -51,9 +51,9 @@ func (f *genericInformer) Lister() cache.GenericLister { // TODO extend this to unknown resources with a client pool func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource) (GenericInformer, error) { switch resource { - // Group=Apiextensions, Version=V1alpha1 - case v1alpha1.SchemeGroupVersion.WithResource("customresourcedefinitions"): - return &genericInformer{resource: resource.GroupResource(), informer: f.Apiextensions().V1alpha1().CustomResourceDefinitions().Informer()}, nil + // Group=Apiextensions, Version=V1beta1 + case v1beta1.SchemeGroupVersion.WithResource("customresourcedefinitions"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Apiextensions().V1beta1().CustomResourceDefinitions().Informer()}, nil } diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1alpha1/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1beta1/BUILD similarity index 94% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1alpha1/BUILD rename to staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1beta1/BUILD index ac475798aba7c..a87a9177c450d 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1alpha1/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1beta1/BUILD @@ -19,6 +19,6 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", "//vendor/k8s.io/client-go/tools/cache:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1:go_default_library", ], ) diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1alpha1/customresourcedefinition.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1beta1/customresourcedefinition.go similarity index 73% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1alpha1/customresourcedefinition.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1beta1/customresourcedefinition.go index 128e6175a9f32..f069276d167ac 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1alpha1/customresourcedefinition.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1beta1/customresourcedefinition.go @@ -16,22 +16,22 @@ limitations under the License. // This file was automatically generated by lister-gen -package v1alpha1 +package v1beta1 import ( "k8s.io/apimachinery/pkg/api/errors" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/labels" "k8s.io/client-go/tools/cache" - v1alpha1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + v1beta1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" ) // CustomResourceDefinitionLister helps list CustomResourceDefinitions. type CustomResourceDefinitionLister interface { // List lists all CustomResourceDefinitions in the indexer. - List(selector labels.Selector) (ret []*v1alpha1.CustomResourceDefinition, err error) + List(selector labels.Selector) (ret []*v1beta1.CustomResourceDefinition, err error) // Get retrieves the CustomResourceDefinition from the index for a given name. - Get(name string) (*v1alpha1.CustomResourceDefinition, error) + Get(name string) (*v1beta1.CustomResourceDefinition, error) CustomResourceDefinitionListerExpansion } @@ -46,22 +46,22 @@ func NewCustomResourceDefinitionLister(indexer cache.Indexer) CustomResourceDefi } // List lists all CustomResourceDefinitions in the indexer. -func (s *customResourceDefinitionLister) List(selector labels.Selector) (ret []*v1alpha1.CustomResourceDefinition, err error) { +func (s *customResourceDefinitionLister) List(selector labels.Selector) (ret []*v1beta1.CustomResourceDefinition, err error) { err = cache.ListAll(s.indexer, selector, func(m interface{}) { - ret = append(ret, m.(*v1alpha1.CustomResourceDefinition)) + ret = append(ret, m.(*v1beta1.CustomResourceDefinition)) }) return ret, err } // Get retrieves the CustomResourceDefinition from the index for a given name. -func (s *customResourceDefinitionLister) Get(name string) (*v1alpha1.CustomResourceDefinition, error) { - key := &v1alpha1.CustomResourceDefinition{ObjectMeta: v1.ObjectMeta{Name: name}} +func (s *customResourceDefinitionLister) Get(name string) (*v1beta1.CustomResourceDefinition, error) { + key := &v1beta1.CustomResourceDefinition{ObjectMeta: v1.ObjectMeta{Name: name}} obj, exists, err := s.indexer.Get(key) if err != nil { return nil, err } if !exists { - return nil, errors.NewNotFound(v1alpha1.Resource("customresourcedefinition"), name) + return nil, errors.NewNotFound(v1beta1.Resource("customresourcedefinition"), name) } - return obj.(*v1alpha1.CustomResourceDefinition), nil + return obj.(*v1beta1.CustomResourceDefinition), nil } diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1alpha1/expansion_generated.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1beta1/expansion_generated.go similarity index 97% rename from staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1alpha1/expansion_generated.go rename to staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1beta1/expansion_generated.go index e1a2d1573a5c4..5723fc39b737c 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1alpha1/expansion_generated.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/client/listers/apiextensions/v1beta1/expansion_generated.go @@ -16,7 +16,7 @@ limitations under the License. // This file was automatically generated by lister-gen -package v1alpha1 +package v1beta1 // CustomResourceDefinitionListerExpansion allows custom methods to be added to // CustomResourceDefinitionLister. diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/cmd/server/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/cmd/server/BUILD index 9b14126e2d4af..27ea2d571e153 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/cmd/server/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/cmd/server/BUILD @@ -17,7 +17,7 @@ go_library( "//vendor/k8s.io/apiserver/pkg/registry/generic:go_default_library", "//vendor/k8s.io/apiserver/pkg/server:go_default_library", "//vendor/k8s.io/apiserver/pkg/server/options:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/apiserver:go_default_library", ], ) diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/cmd/server/start.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/cmd/server/start.go index 822a615ca7d5c..6b76aeb4cde46 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/cmd/server/start.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/cmd/server/start.go @@ -27,7 +27,7 @@ import ( genericregistry "k8s.io/apiserver/pkg/registry/generic" genericapiserver "k8s.io/apiserver/pkg/server" genericoptions "k8s.io/apiserver/pkg/server/options" - "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" "k8s.io/kube-apiextensions-server/pkg/apiserver" ) @@ -42,7 +42,7 @@ type CustomResourceDefinitionsServerOptions struct { func NewCustomResourceDefinitionsServerOptions(out, errOut io.Writer) *CustomResourceDefinitionsServerOptions { o := &CustomResourceDefinitionsServerOptions{ - RecommendedOptions: genericoptions.NewRecommendedOptions(defaultEtcdPathPrefix, apiserver.Scheme, apiserver.Codecs.LegacyCodec(v1alpha1.SchemeGroupVersion)), + RecommendedOptions: genericoptions.NewRecommendedOptions(defaultEtcdPathPrefix, apiserver.Scheme, apiserver.Codecs.LegacyCodec(v1beta1.SchemeGroupVersion)), StdOut: out, StdErr: errOut, diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/controller/finalizer/BUILD b/staging/src/k8s.io/kube-apiextensions-server/pkg/controller/finalizer/BUILD index 30442094d6024..a86a7d1d84c58 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/controller/finalizer/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/controller/finalizer/BUILD @@ -17,7 +17,6 @@ go_library( "//vendor/k8s.io/apimachinery/pkg/api/meta:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1/unstructured:go_default_library", "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", - "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/errors:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/controller/finalizer/crd_finalizer.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/controller/finalizer/crd_finalizer.go index 634292e956a27..ef9d33896b726 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/controller/finalizer/crd_finalizer.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/controller/finalizer/crd_finalizer.go @@ -27,7 +27,6 @@ import ( "k8s.io/apimachinery/pkg/api/meta" "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" "k8s.io/apimachinery/pkg/conversion" - "k8s.io/apimachinery/pkg/types" utilerrors "k8s.io/apimachinery/pkg/util/errors" utilruntime "k8s.io/apimachinery/pkg/util/runtime" "k8s.io/apimachinery/pkg/util/sets" @@ -69,7 +68,7 @@ type ListerCollectionDeleter interface { type CRClientGetter interface { // GetCustomResourceListerCollectionDeleter gets the ListerCollectionDeleter for the given CRD // UID. - GetCustomResourceListerCollectionDeleter(uid types.UID) ListerCollectionDeleter + GetCustomResourceListerCollectionDeleter(crd *apiextensions.CustomResourceDefinition) ListerCollectionDeleter } // NewCRDFinalizer creates a new CRDFinalizer. @@ -162,7 +161,7 @@ func (c *CRDFinalizer) deleteInstances(crd *apiextensions.CustomResourceDefiniti // Now we can start deleting items. While it would be ideal to use a REST API client, doing so // could incorrectly delete a ThirdPartyResource with the same URL as the CustomResource, so we go // directly to the storage instead. Since we control the storage, we know that delete collection works. - crClient := c.crClientGetter.GetCustomResourceListerCollectionDeleter(crd.UID) + crClient := c.crClientGetter.GetCustomResourceListerCollectionDeleter(crd) if crClient == nil { err := fmt.Errorf("unable to find a custom resource client for %s.%s", crd.Status.AcceptedNames.Plural, crd.Spec.Group) return apiextensions.CustomResourceDefinitionCondition{ diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/controller/status/naming_controller.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/controller/status/naming_controller.go index b788ec7b0c9c3..45053878f99d1 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/controller/status/naming_controller.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/controller/status/naming_controller.go @@ -19,6 +19,7 @@ package status import ( "fmt" "reflect" + "strings" "time" "github.com/golang/glog" @@ -230,6 +231,11 @@ func equalToAcceptedOrFresh(requestedName, acceptedName string, usedNames sets.S func (c *NamingConditionController) sync(key string) error { inCustomResourceDefinition, err := c.crdLister.Get(key) if apierrors.IsNotFound(err) { + // CRD was deleted and has freed its names. + // Reconsider all other CRDs in the same group. + if err := c.requeueAllOtherGroupCRDs(key); err != nil { + return err + } return nil } if err != nil { @@ -264,14 +270,8 @@ func (c *NamingConditionController) sync(key string) error { // we updated our status, so we may be releasing a name. When this happens, we need to rekick everything in our group // if we fail to rekick, just return as normal. We'll get everything on a resync - list, err := c.crdLister.List(labels.Everything()) - if err != nil { - return nil - } - for _, curr := range list { - if curr.Spec.Group == crd.Spec.Group { - c.queue.Add(curr.Name) - } + if err := c.requeueAllOtherGroupCRDs(key); err != nil { + return err } return nil @@ -358,3 +358,17 @@ func (c *NamingConditionController) deleteCustomResourceDefinition(obj interface glog.V(4).Infof("Deleting %q", castObj.Name) c.enqueue(castObj) } + +func (c *NamingConditionController) requeueAllOtherGroupCRDs(name string) error { + pluralGroup := strings.SplitN(name, ".", 2) + list, err := c.crdLister.List(labels.Everything()) + if err != nil { + return err + } + for _, curr := range list { + if curr.Spec.Group == pluralGroup[1] && curr.Name != name { + c.queue.Add(curr.Name) + } + } + return nil +} diff --git a/staging/src/k8s.io/kube-apiextensions-server/pkg/registry/customresourcedefinition/etcd.go b/staging/src/k8s.io/kube-apiextensions-server/pkg/registry/customresourcedefinition/etcd.go index 63bcd93ba48a9..efaf41e95d6b4 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/pkg/registry/customresourcedefinition/etcd.go +++ b/staging/src/k8s.io/kube-apiextensions-server/pkg/registry/customresourcedefinition/etcd.go @@ -58,6 +58,14 @@ func NewREST(scheme *runtime.Scheme, optsGetter generic.RESTOptionsGetter) *REST return &REST{store} } +// Implement ShortNamesProvider +var _ rest.ShortNamesProvider = &REST{} + +// ShortNames implements the ShortNamesProvider interface. Returns a list of short names for a resource. +func (r *REST) ShortNames() []string { + return []string{"crd"} +} + // Delete adds the CRD finalizer to the list func (r *REST) Delete(ctx genericapirequest.Context, name string, options *metav1.DeleteOptions) (runtime.Object, bool, error) { obj, err := r.Get(ctx, name, &metav1.GetOptions{}) diff --git a/staging/src/k8s.io/kube-apiextensions-server/test/integration/BUILD b/staging/src/k8s.io/kube-apiextensions-server/test/integration/BUILD index ae598a317a8d2..18b0011f175ab 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/test/integration/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/test/integration/BUILD @@ -11,6 +11,7 @@ go_test( name = "go_default_test", srcs = [ "basic_test.go", + "finalization_test.go", "registration_test.go", ], tags = [ @@ -19,14 +20,16 @@ go_test( ], deps = [ "//vendor/github.com/coreos/etcd/clientv3:go_default_library", + "//vendor/github.com/stretchr/testify/require:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", "//vendor/k8s.io/apimachinery/pkg/api/meta:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1/unstructured:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", "//vendor/k8s.io/client-go/dynamic:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/apiserver:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/test/integration/testserver:go_default_library", ], diff --git a/staging/src/k8s.io/kube-apiextensions-server/test/integration/basic_test.go b/staging/src/k8s.io/kube-apiextensions-server/test/integration/basic_test.go index 7bc0939b1561b..f4c19804fd81b 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/test/integration/basic_test.go +++ b/staging/src/k8s.io/kube-apiextensions-server/test/integration/basic_test.go @@ -26,9 +26,10 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/wait" "k8s.io/apimachinery/pkg/watch" "k8s.io/client-go/dynamic" - apiextensionsv1alpha1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + apiextensionsv1beta1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" "k8s.io/kube-apiextensions-server/test/integration/testserver" ) @@ -47,7 +48,7 @@ func TestNamespaceScopedCRUD(t *testing.T) { } defer close(stopCh) - noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1alpha1.NamespaceScoped) + noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1beta1.NamespaceScoped) noxuVersionClient, err := testserver.CreateNewCustomResourceDefinition(noxuDefinition, apiExtensionClient, clientPool) if err != nil { t.Fatal(err) @@ -64,7 +65,7 @@ func TestClusterScopedCRUD(t *testing.T) { } defer close(stopCh) - noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1alpha1.ClusterScoped) + noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1beta1.ClusterScoped) noxuVersionClient, err := testserver.CreateNewCustomResourceDefinition(noxuDefinition, apiExtensionClient, clientPool) if err != nil { t.Fatal(err) @@ -74,7 +75,7 @@ func TestClusterScopedCRUD(t *testing.T) { testSimpleCRUD(t, ns, noxuDefinition, noxuVersionClient) } -func testSimpleCRUD(t *testing.T, ns string, noxuDefinition *apiextensionsv1alpha1.CustomResourceDefinition, noxuVersionClient *dynamic.Client) { +func testSimpleCRUD(t *testing.T, ns string, noxuDefinition *apiextensionsv1beta1.CustomResourceDefinition, noxuVersionClient *dynamic.Client) { noxuResourceClient := NewNamespacedCustomResourceClient(ns, noxuVersionClient, noxuDefinition) initialList, err := noxuResourceClient.List(metav1.ListOptions{}) if err != nil { @@ -198,7 +199,7 @@ func testSimpleCRUD(t *testing.T, ns string, noxuDefinition *apiextensionsv1alph func TestDiscovery(t *testing.T) { group := "mygroup.example.com" - version := "v1alpha1" + version := "v1beta1" stopCh, apiExtensionClient, clientPool, err := testserver.StartDefaultServer() if err != nil { @@ -206,7 +207,7 @@ func TestDiscovery(t *testing.T) { } defer close(stopCh) - scope := apiextensionsv1alpha1.NamespaceScoped + scope := apiextensionsv1beta1.NamespaceScoped noxuDefinition := testserver.NewNoxuCustomResourceDefinition(scope) _, err = testserver.CreateNewCustomResourceDefinition(noxuDefinition, apiExtensionClient, clientPool) if err != nil { @@ -250,7 +251,7 @@ func TestNoNamespaceReject(t *testing.T) { } defer close(stopCh) - noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1alpha1.NamespaceScoped) + noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1beta1.NamespaceScoped) noxuVersionClient, err := testserver.CreateNewCustomResourceDefinition(noxuDefinition, apiExtensionClient, clientPool) if err != nil { t.Fatal(err) @@ -289,7 +290,7 @@ func TestSameNameDiffNamespace(t *testing.T) { } defer close(stopCh) - noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1alpha1.NamespaceScoped) + noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1beta1.NamespaceScoped) noxuVersionClient, err := testserver.CreateNewCustomResourceDefinition(noxuDefinition, apiExtensionClient, clientPool) if err != nil { t.Fatal(err) @@ -309,7 +310,8 @@ func TestSelfLink(t *testing.T) { } defer close(stopCh) - noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1alpha1.NamespaceScoped) + // namespace scoped + noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1beta1.NamespaceScoped) noxuVersionClient, err := testserver.CreateNewCustomResourceDefinition(noxuDefinition, apiExtensionClient, clientPool) if err != nil { t.Fatal(err) @@ -318,7 +320,7 @@ func TestSelfLink(t *testing.T) { ns := "not-the-default" noxuNamespacedResourceClient := noxuVersionClient.Resource(&metav1.APIResource{ Name: noxuDefinition.Spec.Names.Plural, - Namespaced: true, + Namespaced: noxuDefinition.Spec.Scope == apiextensionsv1beta1.NamespaceScoped, }, ns) noxuInstanceToCreate := testserver.NewNoxuInstance(ns, "foo") @@ -327,12 +329,31 @@ func TestSelfLink(t *testing.T) { t.Fatal(err) } - if e, a := "/apis/mygroup.example.com/v1alpha1/namespaces/not-the-default/noxus/foo", createdNoxuInstance.GetSelfLink(); e != a { + if e, a := "/apis/mygroup.example.com/v1beta1/namespaces/not-the-default/noxus/foo", createdNoxuInstance.GetSelfLink(); e != a { t.Errorf("expected %v, got %v", e, a) } - // TODO add test for cluster scoped self-link when its available + // cluster scoped + curletDefinition := testserver.NewCurletCustomResourceDefinition(apiextensionsv1beta1.ClusterScoped) + curletVersionClient, err := testserver.CreateNewCustomResourceDefinition(curletDefinition, apiExtensionClient, clientPool) + if err != nil { + t.Fatal(err) + } + curletResourceClient := curletVersionClient.Resource(&metav1.APIResource{ + Name: curletDefinition.Spec.Names.Plural, + Namespaced: curletDefinition.Spec.Scope == apiextensionsv1beta1.NamespaceScoped, + }, ns) + + curletInstanceToCreate := testserver.NewCurletInstance(ns, "foo") + createdCurletInstance, err := curletResourceClient.Create(curletInstanceToCreate) + if err != nil { + t.Fatal(err) + } + + if e, a := "/apis/mygroup.example.com/v1beta1/foo", createdCurletInstance.GetSelfLink(); e != a { + t.Errorf("expected %v, got %v", e, a) + } } func TestPreserveInt(t *testing.T) { @@ -342,7 +363,7 @@ func TestPreserveInt(t *testing.T) { } defer close(stopCh) - noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1alpha1.ClusterScoped) + noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1beta1.ClusterScoped) noxuVersionClient, err := testserver.CreateNewCustomResourceDefinition(noxuDefinition, apiExtensionClient, clientPool) if err != nil { t.Fatal(err) @@ -387,7 +408,7 @@ func TestCrossNamespaceListWatch(t *testing.T) { } defer close(stopCh) - noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1alpha1.NamespaceScoped) + noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1beta1.NamespaceScoped) noxuVersionClient, err := testserver.CreateNewCustomResourceDefinition(noxuDefinition, apiExtensionClient, clientPool) if err != nil { t.Fatal(err) @@ -480,7 +501,7 @@ func TestCrossNamespaceListWatch(t *testing.T) { checkNamespacesWatchHelper(t, ns2, noxuNamespacesWatch2) } -func createInstanceWithNamespaceHelper(t *testing.T, ns string, name string, noxuNamespacedResourceClient *dynamic.ResourceClient, noxuDefinition *apiextensionsv1alpha1.CustomResourceDefinition) *unstructured.Unstructured { +func createInstanceWithNamespaceHelper(t *testing.T, ns string, name string, noxuNamespacedResourceClient *dynamic.ResourceClient, noxuDefinition *apiextensionsv1beta1.CustomResourceDefinition) *unstructured.Unstructured { createdInstance, err := instantiateCustomResource(t, testserver.NewNoxuInstance(ns, name), noxuNamespacedResourceClient, noxuDefinition) if err != nil { t.Fatalf("unable to create noxu Instance:%v", err) @@ -515,3 +536,64 @@ func checkNamespacesWatchHelper(t *testing.T, ns string, namespacedwatch watch.I namespacedAddEvent++ } } + +func TestNameConflict(t *testing.T) { + stopCh, apiExtensionClient, clientPool, err := testserver.StartDefaultServer() + if err != nil { + t.Fatal(err) + } + defer close(stopCh) + + noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1beta1.NamespaceScoped) + _, err = testserver.CreateNewCustomResourceDefinition(noxuDefinition, apiExtensionClient, clientPool) + if err != nil { + t.Fatal(err) + } + + noxu2Definition := testserver.NewNoxu2CustomResourceDefinition(apiextensionsv1beta1.NamespaceScoped) + _, err = apiExtensionClient.Apiextensions().CustomResourceDefinitions().Create(noxu2Definition) + if err != nil { + t.Fatal(err) + } + + // A NameConflict occurs + err = wait.Poll(500*time.Millisecond, wait.ForeverTestTimeout, func() (bool, error) { + crd, err := testserver.GetCustomResourceDefinition(noxu2Definition, apiExtensionClient) + if err != nil { + return false, err + } + + for _, condition := range crd.Status.Conditions { + if condition.Type == apiextensionsv1beta1.NamesAccepted && condition.Status == apiextensionsv1beta1.ConditionFalse { + return true, nil + } + } + return false, nil + }) + if err != nil { + t.Fatal(err) + } + + err = testserver.DeleteCustomResourceDefinition(noxuDefinition, apiExtensionClient) + if err != nil { + t.Fatal(err) + } + + // Names are now accepted + err = wait.Poll(500*time.Millisecond, wait.ForeverTestTimeout, func() (bool, error) { + crd, err := testserver.GetCustomResourceDefinition(noxu2Definition, apiExtensionClient) + if err != nil { + return false, err + } + + for _, condition := range crd.Status.Conditions { + if condition.Type == apiextensionsv1beta1.NamesAccepted && condition.Status == apiextensionsv1beta1.ConditionTrue { + return true, nil + } + } + return false, nil + }) + if err != nil { + t.Fatal(err) + } +} diff --git a/staging/src/k8s.io/kube-apiextensions-server/test/integration/finalization_test.go b/staging/src/k8s.io/kube-apiextensions-server/test/integration/finalization_test.go new file mode 100644 index 0000000000000..f7d8cfc1fea9c --- /dev/null +++ b/staging/src/k8s.io/kube-apiextensions-server/test/integration/finalization_test.go @@ -0,0 +1,98 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package integration + +import ( + "testing" + + "github.com/stretchr/testify/require" + + "k8s.io/apimachinery/pkg/api/errors" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + apiextensionsv1beta1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" + "k8s.io/kube-apiextensions-server/test/integration/testserver" +) + +func TestFinalization(t *testing.T) { + stopCh, apiExtensionClient, clientPool, err := testserver.StartDefaultServer() + require.NoError(t, err) + defer close(stopCh) + + noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1beta1.ClusterScoped) + noxuVersionClient, err := testserver.CreateNewCustomResourceDefinition(noxuDefinition, apiExtensionClient, clientPool) + require.NoError(t, err) + + ns := "not-the-default" + name := "foo123" + noxuResourceClient := NewNamespacedCustomResourceClient(ns, noxuVersionClient, noxuDefinition) + + instance := testserver.NewNoxuInstance(ns, name) + instance.SetFinalizers([]string{"noxu.example.com/finalizer"}) + createdNoxuInstance, err := instantiateCustomResource(t, instance, noxuResourceClient, noxuDefinition) + require.NoError(t, err) + + uid := createdNoxuInstance.GetUID() + err = noxuResourceClient.Delete(name, &metav1.DeleteOptions{ + Preconditions: &metav1.Preconditions{ + UID: &uid, + }, + }) + require.NoError(t, err) + + // Deleting something with a finalizer sets deletion timestamp to a not-nil value but does not + // remove the object from the API server. Here we read it to confirm this. + gottenNoxuInstance, err := noxuResourceClient.Get(name) + require.NoError(t, err) + + require.NotNil(t, gottenNoxuInstance.GetDeletionTimestamp()) + + // Trying to delete it again to confirm it will not remove the object because finalizer is still there. + err = noxuResourceClient.Delete(name, &metav1.DeleteOptions{ + Preconditions: &metav1.Preconditions{ + UID: &uid, + }, + }) + require.NoError(t, err) + + // Removing the finalizers to allow the following delete remove the object. + // This step will fail if previous delete wrongly removed the object. + for { + gottenNoxuInstance.SetFinalizers(nil) + _, err = noxuResourceClient.Update(gottenNoxuInstance) + if err == nil { + break + } + if !errors.IsConflict(err) { + require.NoError(t, err) // Fail on unexpected error + } + gottenNoxuInstance, err = noxuResourceClient.Get(name) + require.NoError(t, err) + } + + // Now when finalizer is not there it should be possible to actually remove the object from the server. + err = noxuResourceClient.Delete(name, &metav1.DeleteOptions{ + Preconditions: &metav1.Preconditions{ + UID: &uid, + }, + }) + require.NoError(t, err) + + // Check that the object is actually gone. + _, err = noxuResourceClient.Get(name) + require.Error(t, err) + require.True(t, errors.IsNotFound(err), "%#v", err) +} diff --git a/staging/src/k8s.io/kube-apiextensions-server/test/integration/registration_test.go b/staging/src/k8s.io/kube-apiextensions-server/test/integration/registration_test.go index 8d01c5063d686..8530beae9e686 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/test/integration/registration_test.go +++ b/staging/src/k8s.io/kube-apiextensions-server/test/integration/registration_test.go @@ -34,12 +34,12 @@ import ( "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" "k8s.io/apimachinery/pkg/watch" "k8s.io/client-go/dynamic" - apiextensionsv1alpha1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + apiextensionsv1beta1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" extensionsapiserver "k8s.io/kube-apiextensions-server/pkg/apiserver" "k8s.io/kube-apiextensions-server/test/integration/testserver" ) -func instantiateCustomResource(t *testing.T, instanceToCreate *unstructured.Unstructured, client *dynamic.ResourceClient, definition *apiextensionsv1alpha1.CustomResourceDefinition) (*unstructured.Unstructured, error) { +func instantiateCustomResource(t *testing.T, instanceToCreate *unstructured.Unstructured, client *dynamic.ResourceClient, definition *apiextensionsv1beta1.CustomResourceDefinition) (*unstructured.Unstructured, error) { createdInstance, err := client.Create(instanceToCreate) if err != nil { t.Logf("%#v", createdInstance) @@ -66,10 +66,10 @@ func instantiateCustomResource(t *testing.T, instanceToCreate *unstructured.Unst return createdInstance, nil } -func NewNamespacedCustomResourceClient(ns string, client *dynamic.Client, definition *apiextensionsv1alpha1.CustomResourceDefinition) *dynamic.ResourceClient { +func NewNamespacedCustomResourceClient(ns string, client *dynamic.Client, definition *apiextensionsv1beta1.CustomResourceDefinition) *dynamic.ResourceClient { return client.Resource(&metav1.APIResource{ Name: definition.Spec.Names.Plural, - Namespaced: definition.Spec.Scope == apiextensionsv1alpha1.NamespaceScoped, + Namespaced: definition.Spec.Scope == apiextensionsv1beta1.NamespaceScoped, }, ns) } @@ -81,7 +81,7 @@ func TestMultipleResourceInstances(t *testing.T) { defer close(stopCh) ns := "not-the-default" - noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1alpha1.NamespaceScoped) + noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1beta1.NamespaceScoped) noxuVersionClient, err := testserver.CreateNewCustomResourceDefinition(noxuDefinition, apiExtensionClient, clientPool) if err != nil { t.Fatal(err) @@ -206,7 +206,7 @@ func TestMultipleRegistration(t *testing.T) { ns := "not-the-default" sameInstanceName := "foo" - noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1alpha1.NamespaceScoped) + noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1beta1.NamespaceScoped) noxuVersionClient, err := testserver.CreateNewCustomResourceDefinition(noxuDefinition, apiExtensionClient, clientPool) if err != nil { t.Fatal(err) @@ -225,7 +225,7 @@ func TestMultipleRegistration(t *testing.T) { t.Errorf("expected %v, got %v", e, a) } - curletDefinition := testserver.NewCurletCustomResourceDefinition(apiextensionsv1alpha1.NamespaceScoped) + curletDefinition := testserver.NewCurletCustomResourceDefinition(apiextensionsv1beta1.NamespaceScoped) curletVersionClient, err := testserver.CreateNewCustomResourceDefinition(curletDefinition, apiExtensionClient, clientPool) if err != nil { t.Fatal(err) @@ -259,7 +259,7 @@ func TestDeRegistrationAndReRegistration(t *testing.T) { t.Fatal(err) } defer close(stopCh) - noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1alpha1.NamespaceScoped) + noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1beta1.NamespaceScoped) ns := "not-the-default" sameInstanceName := "foo" func() { @@ -356,7 +356,7 @@ func TestEtcdStorage(t *testing.T) { etcdPrefix := getPrefixFromConfig(t, config) ns1 := "another-default-is-possible" - curletDefinition := testserver.NewCurletCustomResourceDefinition(apiextensionsv1alpha1.ClusterScoped) + curletDefinition := testserver.NewCurletCustomResourceDefinition(apiextensionsv1beta1.ClusterScoped) curletVersionClient, err := testserver.CreateNewCustomResourceDefinition(curletDefinition, apiExtensionClient, clientPool) if err != nil { t.Fatal(err) @@ -367,7 +367,7 @@ func TestEtcdStorage(t *testing.T) { } ns2 := "the-cruel-default" - noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1alpha1.NamespaceScoped) + noxuDefinition := testserver.NewNoxuCustomResourceDefinition(apiextensionsv1beta1.NamespaceScoped) noxuVersionClient, err := testserver.CreateNewCustomResourceDefinition(noxuDefinition, apiExtensionClient, clientPool) if err != nil { t.Fatal(err) @@ -385,11 +385,11 @@ func TestEtcdStorage(t *testing.T) { etcdPath: path.Join("/", etcdPrefix, "apiextensions.k8s.io/customresourcedefinitions/noxus.mygroup.example.com"), // TODO: Double check this, no namespace? expectedObject: &metaObject{ Kind: "CustomResourceDefinition", - APIVersion: "apiextensions.k8s.io/v1alpha1", + APIVersion: "apiextensions.k8s.io/v1beta1", Metadata: Metadata{ Name: "noxus.mygroup.example.com", Namespace: "", - SelfLink: "/apis/apiextensions.k8s.io/v1alpha1/customresourcedefinitions/noxus.mygroup.example.com", + SelfLink: "/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions/noxus.mygroup.example.com", }, }, }, @@ -397,7 +397,7 @@ func TestEtcdStorage(t *testing.T) { etcdPath: path.Join("/", etcdPrefix, "mygroup.example.com/noxus/the-cruel-default/foo"), expectedObject: &metaObject{ Kind: "WishIHadChosenNoxu", - APIVersion: "mygroup.example.com/v1alpha1", + APIVersion: "mygroup.example.com/v1beta1", Metadata: Metadata{ Name: "foo", Namespace: "the-cruel-default", @@ -410,11 +410,11 @@ func TestEtcdStorage(t *testing.T) { etcdPath: path.Join("/", etcdPrefix, "apiextensions.k8s.io/customresourcedefinitions/curlets.mygroup.example.com"), expectedObject: &metaObject{ Kind: "CustomResourceDefinition", - APIVersion: "apiextensions.k8s.io/v1alpha1", + APIVersion: "apiextensions.k8s.io/v1beta1", Metadata: Metadata{ Name: "curlets.mygroup.example.com", Namespace: "", - SelfLink: "/apis/apiextensions.k8s.io/v1alpha1/customresourcedefinitions/curlets.mygroup.example.com", + SelfLink: "/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions/curlets.mygroup.example.com", }, }, }, @@ -423,7 +423,7 @@ func TestEtcdStorage(t *testing.T) { etcdPath: path.Join("/", etcdPrefix, "mygroup.example.com/curlets/bar"), expectedObject: &metaObject{ Kind: "Curlet", - APIVersion: "mygroup.example.com/v1alpha1", + APIVersion: "mygroup.example.com/v1beta1", Metadata: Metadata{ Name: "bar", Namespace: "", diff --git a/staging/src/k8s.io/kube-apiextensions-server/test/integration/testserver/BUILD b/staging/src/k8s.io/kube-apiextensions-server/test/integration/testserver/BUILD index 9d15c33cde57d..dc39a16b283ac 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/test/integration/testserver/BUILD +++ b/staging/src/k8s.io/kube-apiextensions-server/test/integration/testserver/BUILD @@ -24,7 +24,7 @@ go_library( "//vendor/k8s.io/apiserver/pkg/authorization/authorizerfactory:go_default_library", "//vendor/k8s.io/apiserver/pkg/server:go_default_library", "//vendor/k8s.io/client-go/dynamic:go_default_library", - "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1:go_default_library", + "//vendor/k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/apiserver:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset:go_default_library", "//vendor/k8s.io/kube-apiextensions-server/pkg/cmd/server:go_default_library", diff --git a/staging/src/k8s.io/kube-apiextensions-server/test/integration/testserver/resources.go b/staging/src/k8s.io/kube-apiextensions-server/test/integration/testserver/resources.go index 519cb5e9d8629..262631e7a0093 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/test/integration/testserver/resources.go +++ b/staging/src/k8s.io/kube-apiextensions-server/test/integration/testserver/resources.go @@ -25,17 +25,17 @@ import ( "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/util/wait" "k8s.io/client-go/dynamic" - apiextensionsv1alpha1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1alpha1" + apiextensionsv1beta1 "k8s.io/kube-apiextensions-server/pkg/apis/apiextensions/v1beta1" "k8s.io/kube-apiextensions-server/pkg/client/clientset/clientset" ) -func NewNoxuCustomResourceDefinition(scope apiextensionsv1alpha1.ResourceScope) *apiextensionsv1alpha1.CustomResourceDefinition { - return &apiextensionsv1alpha1.CustomResourceDefinition{ +func NewNoxuCustomResourceDefinition(scope apiextensionsv1beta1.ResourceScope) *apiextensionsv1beta1.CustomResourceDefinition { + return &apiextensionsv1beta1.CustomResourceDefinition{ ObjectMeta: metav1.ObjectMeta{Name: "noxus.mygroup.example.com"}, - Spec: apiextensionsv1alpha1.CustomResourceDefinitionSpec{ + Spec: apiextensionsv1beta1.CustomResourceDefinitionSpec{ Group: "mygroup.example.com", - Version: "v1alpha1", - Names: apiextensionsv1alpha1.CustomResourceDefinitionNames{ + Version: "v1beta1", + Names: apiextensionsv1beta1.CustomResourceDefinitionNames{ Plural: "noxus", Singular: "nonenglishnoxu", Kind: "WishIHadChosenNoxu", @@ -50,7 +50,7 @@ func NewNoxuCustomResourceDefinition(scope apiextensionsv1alpha1.ResourceScope) func NewNoxuInstance(namespace, name string) *unstructured.Unstructured { return &unstructured.Unstructured{ Object: map[string]interface{}{ - "apiVersion": "mygroup.example.com/v1alpha1", + "apiVersion": "mygroup.example.com/v1beta1", "kind": "WishIHadChosenNoxu", "metadata": map[string]interface{}{ "namespace": namespace, @@ -67,13 +67,31 @@ func NewNoxuInstance(namespace, name string) *unstructured.Unstructured { } } -func NewCurletCustomResourceDefinition(scope apiextensionsv1alpha1.ResourceScope) *apiextensionsv1alpha1.CustomResourceDefinition { - return &apiextensionsv1alpha1.CustomResourceDefinition{ - ObjectMeta: metav1.ObjectMeta{Name: "curlets.mygroup.example.com"}, - Spec: apiextensionsv1alpha1.CustomResourceDefinitionSpec{ +func NewNoxu2CustomResourceDefinition(scope apiextensionsv1beta1.ResourceScope) *apiextensionsv1beta1.CustomResourceDefinition { + return &apiextensionsv1beta1.CustomResourceDefinition{ + ObjectMeta: metav1.ObjectMeta{Name: "noxus2.mygroup.example.com"}, + Spec: apiextensionsv1beta1.CustomResourceDefinitionSpec{ Group: "mygroup.example.com", Version: "v1alpha1", - Names: apiextensionsv1alpha1.CustomResourceDefinitionNames{ + Names: apiextensionsv1beta1.CustomResourceDefinitionNames{ + Plural: "noxus2", + Singular: "nonenglishnoxu2", + Kind: "WishIHadChosenNoxu2", + ShortNames: []string{"foo", "bar", "abc", "def"}, + ListKind: "Noxu2ItemList", + }, + Scope: scope, + }, + } +} + +func NewCurletCustomResourceDefinition(scope apiextensionsv1beta1.ResourceScope) *apiextensionsv1beta1.CustomResourceDefinition { + return &apiextensionsv1beta1.CustomResourceDefinition{ + ObjectMeta: metav1.ObjectMeta{Name: "curlets.mygroup.example.com"}, + Spec: apiextensionsv1beta1.CustomResourceDefinitionSpec{ + Group: "mygroup.example.com", + Version: "v1beta1", + Names: apiextensionsv1beta1.CustomResourceDefinitionNames{ Plural: "curlets", Singular: "curlet", Kind: "Curlet", @@ -87,7 +105,7 @@ func NewCurletCustomResourceDefinition(scope apiextensionsv1alpha1.ResourceScope func NewCurletInstance(namespace, name string) *unstructured.Unstructured { return &unstructured.Unstructured{ Object: map[string]interface{}{ - "apiVersion": "mygroup.example.com/v1alpha1", + "apiVersion": "mygroup.example.com/v1beta1", "kind": "Curlet", "metadata": map[string]interface{}{ "namespace": namespace, @@ -100,20 +118,20 @@ func NewCurletInstance(namespace, name string) *unstructured.Unstructured { } } -func CreateNewCustomResourceDefinition(customResourceDefinition *apiextensionsv1alpha1.CustomResourceDefinition, apiExtensionsClient clientset.Interface, clientPool dynamic.ClientPool) (*dynamic.Client, error) { - _, err := apiExtensionsClient.Apiextensions().CustomResourceDefinitions().Create(customResourceDefinition) +func CreateNewCustomResourceDefinition(crd *apiextensionsv1beta1.CustomResourceDefinition, apiExtensionsClient clientset.Interface, clientPool dynamic.ClientPool) (*dynamic.Client, error) { + _, err := apiExtensionsClient.Apiextensions().CustomResourceDefinitions().Create(crd) if err != nil { return nil, err } // wait until the resource appears in discovery - err = wait.PollImmediate(30*time.Millisecond, 30*time.Second, func() (bool, error) { - resourceList, err := apiExtensionsClient.Discovery().ServerResourcesForGroupVersion(customResourceDefinition.Spec.Group + "/" + customResourceDefinition.Spec.Version) + err = wait.PollImmediate(500*time.Millisecond, 30*time.Second, func() (bool, error) { + resourceList, err := apiExtensionsClient.Discovery().ServerResourcesForGroupVersion(crd.Spec.Group + "/" + crd.Spec.Version) if err != nil { return false, nil } for _, resource := range resourceList.APIResources { - if resource.Name == customResourceDefinition.Spec.Names.Plural { + if resource.Name == crd.Spec.Names.Plural { return true, nil } } @@ -123,29 +141,36 @@ func CreateNewCustomResourceDefinition(customResourceDefinition *apiextensionsv1 return nil, err } - dynamicClient, err := clientPool.ClientForGroupVersionResource(schema.GroupVersionResource{Group: customResourceDefinition.Spec.Group, Version: customResourceDefinition.Spec.Version, Resource: customResourceDefinition.Spec.Names.Plural}) + dynamicClient, err := clientPool.ClientForGroupVersionResource(schema.GroupVersionResource{Group: crd.Spec.Group, Version: crd.Spec.Version, Resource: crd.Spec.Names.Plural}) if err != nil { return nil, err } return dynamicClient, nil } -func DeleteCustomResourceDefinition(customResource *apiextensionsv1alpha1.CustomResourceDefinition, apiExtensionsClient clientset.Interface) error { - if err := apiExtensionsClient.Apiextensions().CustomResourceDefinitions().Delete(customResource.Name, nil); err != nil { +func DeleteCustomResourceDefinition(crd *apiextensionsv1beta1.CustomResourceDefinition, apiExtensionsClient clientset.Interface) error { + if err := apiExtensionsClient.Apiextensions().CustomResourceDefinitions().Delete(crd.Name, nil); err != nil { return err } - err := wait.PollImmediate(30*time.Millisecond, 30*time.Second, func() (bool, error) { - if _, err := apiExtensionsClient.Discovery().ServerResourcesForGroupVersion(customResource.Spec.Group + "/" + customResource.Spec.Version); err != nil { + err := wait.PollImmediate(500*time.Millisecond, 30*time.Second, func() (bool, error) { + groupResource, err := apiExtensionsClient.Discovery().ServerResourcesForGroupVersion(crd.Spec.Group + "/" + crd.Spec.Version) + if err != nil { if errors.IsNotFound(err) { return true, nil + } return false, err } - return false, nil + for _, g := range groupResource.APIResources { + if g.Name == crd.Spec.Names.Plural { + return false, nil + } + } + return true, nil }) return err } -func GetCustomResourceDefinition(customResource *apiextensionsv1alpha1.CustomResourceDefinition, apiExtensionsClient clientset.Interface) (*apiextensionsv1alpha1.CustomResourceDefinition, error) { - return apiExtensionsClient.Apiextensions().CustomResourceDefinitions().Get(customResource.Name, metav1.GetOptions{}) +func GetCustomResourceDefinition(crd *apiextensionsv1beta1.CustomResourceDefinition, apiExtensionsClient clientset.Interface) (*apiextensionsv1beta1.CustomResourceDefinition, error) { + return apiExtensionsClient.Apiextensions().CustomResourceDefinitions().Get(crd.Name, metav1.GetOptions{}) } diff --git a/staging/src/k8s.io/kube-apiextensions-server/test/integration/testserver/start.go b/staging/src/k8s.io/kube-apiextensions-server/test/integration/testserver/start.go index 7772ca4c22d9d..3e51475b7addb 100644 --- a/staging/src/k8s.io/kube-apiextensions-server/test/integration/testserver/start.go +++ b/staging/src/k8s.io/kube-apiextensions-server/test/integration/testserver/start.go @@ -42,7 +42,7 @@ func DefaultServerConfig() (*extensionsapiserver.Config, error) { } options := server.NewCustomResourceDefinitionsServerOptions(os.Stdout, os.Stderr) - options.RecommendedOptions.Audit.Path = "-" + options.RecommendedOptions.Audit.LogOptions.Path = "-" options.RecommendedOptions.SecureServing.BindPort = port options.RecommendedOptions.Authentication.SkipInClusterLookup = true options.RecommendedOptions.SecureServing.BindAddress = net.ParseIP("127.0.0.1") @@ -140,7 +140,7 @@ func StartServer(config *extensionsapiserver.Config) (chan struct{}, clientset.I return nil, nil, nil, err } - bytes, _ := apiExtensionsClient.Discovery().RESTClient().Get().AbsPath("/apis/apiextensions.k8s.io/v1alpha1").DoRaw() + bytes, _ := apiExtensionsClient.Discovery().RESTClient().Get().AbsPath("/apis/apiextensions.k8s.io/v1beta1").DoRaw() fmt.Print(string(bytes)) return stopCh, apiExtensionsClient, dynamic.NewDynamicClientPool(server.GenericAPIServer.LoopbackClientConfig), nil diff --git a/staging/src/k8s.io/metrics/pkg/apis/custom_metrics/v1alpha1/generated.pb.go b/staging/src/k8s.io/metrics/pkg/apis/custom_metrics/v1alpha1/generated.pb.go index 15bd8bdedbb81..69f27bfc05aa8 100644 --- a/staging/src/k8s.io/metrics/pkg/apis/custom_metrics/v1alpha1/generated.pb.go +++ b/staging/src/k8s.io/metrics/pkg/apis/custom_metrics/v1alpha1/generated.pb.go @@ -15,14 +15,14 @@ limitations under the License. */ // Code generated by protoc-gen-gogo. -// source: k8s.io/metrics/pkg/apis/custom_metrics/v1alpha1/generated.proto +// source: k8s.io/kubernetes/vendor/k8s.io/metrics/pkg/apis/custom_metrics/v1alpha1/generated.proto // DO NOT EDIT! /* Package v1alpha1 is a generated protocol buffer package. It is generated from these files: - k8s.io/metrics/pkg/apis/custom_metrics/v1alpha1/generated.proto + k8s.io/kubernetes/vendor/k8s.io/metrics/pkg/apis/custom_metrics/v1alpha1/generated.proto It has these top-level messages: MetricValue @@ -46,7 +46,9 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *MetricValue) Reset() { *m = MetricValue{} } func (*MetricValue) ProtoMessage() {} @@ -60,50 +62,50 @@ func init() { proto.RegisterType((*MetricValue)(nil), "k8s.io.metrics.pkg.apis.custom_metrics.v1alpha1.MetricValue") proto.RegisterType((*MetricValueList)(nil), "k8s.io.metrics.pkg.apis.custom_metrics.v1alpha1.MetricValueList") } -func (m *MetricValue) Marshal() (data []byte, err error) { +func (m *MetricValue) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *MetricValue) MarshalTo(data []byte) (int, error) { +func (m *MetricValue) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.DescribedObject.Size())) - n1, err := m.DescribedObject.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.DescribedObject.Size())) + n1, err := m.DescribedObject.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n1 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.MetricName))) - i += copy(data[i:], m.MetricName) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.MetricName))) + i += copy(dAtA[i:], m.MetricName) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Timestamp.Size())) - n2, err := m.Timestamp.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Timestamp.Size())) + n2, err := m.Timestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 if m.WindowSeconds != nil { - data[i] = 0x20 + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(*m.WindowSeconds)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.WindowSeconds)) } - data[i] = 0x2a + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(m.Value.Size())) - n3, err := m.Value.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Value.Size())) + n3, err := m.Value.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -111,35 +113,35 @@ func (m *MetricValue) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *MetricValueList) Marshal() (data []byte, err error) { +func (m *MetricValueList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *MetricValueList) MarshalTo(data []byte) (int, error) { +func (m *MetricValueList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n4, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n4, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n4 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -149,31 +151,31 @@ func (m *MetricValueList) MarshalTo(data []byte) (int, error) { return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m *MetricValue) Size() (n int) { @@ -253,8 +255,8 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *MetricValue) Unmarshal(data []byte) error { - l := len(data) +func (m *MetricValue) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -266,7 +268,7 @@ func (m *MetricValue) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -294,7 +296,7 @@ func (m *MetricValue) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -308,7 +310,7 @@ func (m *MetricValue) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.DescribedObject.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.DescribedObject.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -324,7 +326,7 @@ func (m *MetricValue) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -339,7 +341,7 @@ func (m *MetricValue) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.MetricName = string(data[iNdEx:postIndex]) + m.MetricName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -353,7 +355,7 @@ func (m *MetricValue) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -367,7 +369,7 @@ func (m *MetricValue) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Timestamp.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Timestamp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -383,7 +385,7 @@ func (m *MetricValue) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -403,7 +405,7 @@ func (m *MetricValue) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -417,13 +419,13 @@ func (m *MetricValue) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Value.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Value.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -442,8 +444,8 @@ func (m *MetricValue) Unmarshal(data []byte) error { } return nil } -func (m *MetricValueList) Unmarshal(data []byte) error { - l := len(data) +func (m *MetricValueList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -455,7 +457,7 @@ func (m *MetricValueList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -483,7 +485,7 @@ func (m *MetricValueList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -497,7 +499,7 @@ func (m *MetricValueList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -513,7 +515,7 @@ func (m *MetricValueList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -528,13 +530,13 @@ func (m *MetricValueList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, MetricValue{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -553,8 +555,8 @@ func (m *MetricValueList) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -565,7 +567,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -583,7 +585,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -600,7 +602,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -623,7 +625,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -634,7 +636,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -658,40 +660,45 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/kubernetes/vendor/k8s.io/metrics/pkg/apis/custom_metrics/v1alpha1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 542 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x94, 0x93, 0x4f, 0x6f, 0xd3, 0x30, - 0x18, 0xc6, 0x9b, 0x95, 0x4a, 0xad, 0xab, 0xaa, 0x2c, 0x17, 0xa2, 0x1e, 0xd2, 0x6a, 0xa7, 0x6a, - 0x30, 0x5b, 0x2d, 0x08, 0x38, 0x20, 0x21, 0x45, 0x5c, 0x90, 0x28, 0x88, 0x6c, 0x02, 0x09, 0x90, - 0x26, 0xd7, 0x79, 0x97, 0x9a, 0x36, 0x71, 0x14, 0x3b, 0x9d, 0x76, 0xe3, 0x23, 0xf0, 0x05, 0xf8, - 0x3e, 0x3d, 0x4e, 0x9c, 0x38, 0x55, 0x34, 0x7c, 0x11, 0xe4, 0xfc, 0x59, 0xdb, 0x55, 0x1b, 0xec, - 0x16, 0xdb, 0xef, 0xf3, 0xf3, 0xf3, 0xbe, 0x8f, 0x83, 0x5e, 0x4e, 0x9f, 0x4b, 0xcc, 0x05, 0x09, - 0x40, 0xc5, 0x9c, 0x49, 0x12, 0x4d, 0x7d, 0x42, 0x23, 0x2e, 0x09, 0x4b, 0xa4, 0x12, 0xc1, 0x69, - 0xb9, 0x3f, 0x1f, 0xd0, 0x59, 0x34, 0xa1, 0x03, 0xe2, 0x43, 0x08, 0x31, 0x55, 0xe0, 0xe1, 0x28, - 0x16, 0x4a, 0x98, 0x24, 0x07, 0xe0, 0xa2, 0x10, 0x47, 0x53, 0x1f, 0x6b, 0x00, 0xde, 0x06, 0xe0, - 0x12, 0xd0, 0x39, 0xf2, 0xb9, 0x9a, 0x24, 0x63, 0xcc, 0x44, 0x40, 0x7c, 0xe1, 0x0b, 0x92, 0x71, - 0xc6, 0xc9, 0x59, 0xb6, 0xca, 0x16, 0xd9, 0x57, 0xce, 0xef, 0x3c, 0x29, 0x0c, 0xd2, 0x88, 0x07, - 0x94, 0x4d, 0x78, 0x08, 0xf1, 0x45, 0xe9, 0x92, 0xc4, 0x20, 0x45, 0x12, 0x33, 0xb8, 0xee, 0xea, - 0x56, 0x95, 0xd4, 0xcd, 0x52, 0x32, 0xdf, 0xe9, 0xa5, 0x43, 0x6e, 0x52, 0xc5, 0x49, 0xa8, 0x78, - 0xb0, 0x7b, 0xcd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 0x97, 0xdd, 0xd6, 0xc7, 0xcd, 0x03, 0x77, 0xbb, - 0xce, 0x3c, 0x46, 0xb5, 0xb9, 0x9e, 0xa1, 0x55, 0xcb, 0x1c, 0xe1, 0xdb, 0x1c, 0xe1, 0xf2, 0x45, - 0xe2, 0xf7, 0x09, 0x0d, 0x15, 0x57, 0x17, 0x4e, 0xab, 0x70, 0x55, 0xcb, 0x82, 0x70, 0x73, 0xd6, - 0xc1, 0x4f, 0x03, 0xb5, 0x37, 0xf2, 0x79, 0xc3, 0xa5, 0x32, 0xbf, 0xa0, 0xba, 0xee, 0xc7, 0xa3, - 0x8a, 0x16, 0xe1, 0xe0, 0xff, 0xeb, 0x5e, 0xab, 0x47, 0xa0, 0xa8, 0x73, 0xbf, 0xb8, 0xab, 0x5e, - 0xee, 0xb8, 0x57, 0x44, 0x93, 0xa2, 0x1a, 0x57, 0x10, 0x48, 0x6b, 0xaf, 0x57, 0xed, 0x37, 0x87, - 0x2f, 0xf0, 0x1d, 0x7f, 0x5c, 0xbc, 0x61, 0x77, 0xdd, 0xd4, 0x6b, 0x8d, 0x74, 0x73, 0xb2, 0x73, - 0xb8, 0x58, 0xd9, 0x95, 0xcb, 0x95, 0x5d, 0xf9, 0xb5, 0xb2, 0x2b, 0xdf, 0x52, 0xdb, 0x58, 0xa4, - 0xb6, 0x71, 0x99, 0xda, 0xc6, 0xef, 0xd4, 0x36, 0xbe, 0xff, 0xb1, 0x2b, 0x9f, 0xea, 0x25, 0xed, - 0x6f, 0x00, 0x00, 0x00, 0xff, 0xff, 0xde, 0x29, 0xfe, 0x9a, 0x79, 0x04, 0x00, 0x00, + // 554 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x93, 0xc1, 0x6e, 0xd3, 0x30, + 0x18, 0xc7, 0x9b, 0x95, 0x4a, 0xad, 0xab, 0xaa, 0x2c, 0x17, 0xa2, 0x1e, 0xd2, 0x6a, 0xa7, 0x6a, + 0x30, 0x5b, 0x2d, 0x08, 0x38, 0x70, 0x8a, 0xb8, 0x20, 0x51, 0x10, 0xd9, 0x04, 0x08, 0x90, 0x26, + 0x37, 0xf9, 0x96, 0x9a, 0x36, 0x71, 0x64, 0x3b, 0x9d, 0x76, 0xe3, 0x11, 0x78, 0x01, 0xde, 0xa7, + 0xc7, 0x89, 0x13, 0xa7, 0x8a, 0x86, 0x17, 0x41, 0x49, 0x9c, 0xb5, 0x5d, 0xb5, 0xc1, 0x6e, 0xb1, + 0xfd, 0xfd, 0x7f, 0xfe, 0x7f, 0xdf, 0xdf, 0x41, 0x1f, 0xa7, 0xcf, 0x25, 0x66, 0x9c, 0x4c, 0x93, + 0x31, 0x88, 0x08, 0x14, 0x48, 0x32, 0x87, 0xc8, 0xe7, 0x82, 0xe8, 0x83, 0x10, 0x94, 0x60, 0x9e, + 0x24, 0xf1, 0x34, 0x20, 0x34, 0x66, 0x92, 0x78, 0x89, 0x54, 0x3c, 0x3c, 0x2d, 0xf7, 0xe7, 0x03, + 0x3a, 0x8b, 0x27, 0x74, 0x40, 0x02, 0x88, 0x40, 0x50, 0x05, 0x3e, 0x8e, 0x05, 0x57, 0xdc, 0xd4, + 0x00, 0xac, 0x0b, 0x71, 0x3c, 0x0d, 0x70, 0x06, 0xc0, 0xdb, 0x00, 0x5c, 0x02, 0x3a, 0x47, 0x01, + 0x53, 0x93, 0x64, 0x8c, 0x3d, 0x1e, 0x92, 0x80, 0x07, 0x9c, 0xe4, 0x9c, 0x71, 0x72, 0x96, 0xaf, + 0xf2, 0x45, 0xfe, 0x55, 0xf0, 0x3b, 0x4f, 0xb4, 0x41, 0x1a, 0xb3, 0x90, 0x7a, 0x13, 0x16, 0x81, + 0xb8, 0x28, 0x5d, 0x12, 0x01, 0x92, 0x27, 0xc2, 0x83, 0xeb, 0xae, 0x6e, 0x55, 0xc9, 0xac, 0x59, + 0x4a, 0xe6, 0x3b, 0xbd, 0x74, 0xc8, 0x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 0x5a, 0xf7, 0x7a, 0x46, + 0xbf, 0xea, 0xec, 0xa7, 0xcb, 0x6e, 0xeb, 0xc3, 0xe6, 0x81, 0xbb, 0x5d, 0x67, 0x1e, 0xa3, 0xda, + 0x3c, 0x9b, 0xa1, 0x55, 0xcb, 0x1d, 0xe1, 0xdb, 0x1c, 0xe1, 0xf2, 0x45, 0xe2, 0x77, 0x09, 0x8d, + 0x14, 0x53, 0x17, 0x4e, 0x4b, 0xbb, 0xaa, 0xe5, 0x41, 0xb8, 0x05, 0xeb, 0xe0, 0xa7, 0x81, 0xda, + 0x1b, 0xf9, 0xbc, 0x66, 0x52, 0x99, 0x5f, 0x50, 0x3d, 0xeb, 0xc7, 0xa7, 0x8a, 0xea, 0x70, 0xf0, + 0xff, 0x75, 0x9f, 0xa9, 0x47, 0xa0, 0xa8, 0x73, 0x5f, 0xdf, 0x55, 0x2f, 0x77, 0xdc, 0x2b, 0xa2, + 0x49, 0x51, 0x8d, 0x29, 0x08, 0xa5, 0xb5, 0xd7, 0xab, 0xf6, 0x9b, 0xc3, 0x17, 0xf8, 0x8e, 0x3f, + 0x2e, 0xde, 0xb0, 0xbb, 0x6e, 0xea, 0x55, 0x86, 0x74, 0x0b, 0xb2, 0x73, 0xb8, 0x58, 0xd9, 0x95, + 0xcb, 0x95, 0x5d, 0xf9, 0xb5, 0xb2, 0x2b, 0xdf, 0x52, 0xdb, 0x58, 0xa4, 0xb6, 0x71, 0x99, 0xda, + 0xc6, 0xef, 0xd4, 0x36, 0xbe, 0xff, 0xb1, 0x2b, 0x9f, 0xea, 0x25, 0xed, 0x6f, 0x00, 0x00, 0x00, + 0xff, 0xff, 0x0c, 0x0e, 0x97, 0xc5, 0x92, 0x04, 0x00, 0x00, } diff --git a/staging/src/k8s.io/metrics/pkg/apis/metrics/v1alpha1/generated.pb.go b/staging/src/k8s.io/metrics/pkg/apis/metrics/v1alpha1/generated.pb.go index 17a457c784bf9..560557f83847f 100644 --- a/staging/src/k8s.io/metrics/pkg/apis/metrics/v1alpha1/generated.pb.go +++ b/staging/src/k8s.io/metrics/pkg/apis/metrics/v1alpha1/generated.pb.go @@ -15,14 +15,14 @@ limitations under the License. */ // Code generated by protoc-gen-gogo. -// source: k8s.io/metrics/pkg/apis/metrics/v1alpha1/generated.proto +// source: k8s.io/kubernetes/vendor/k8s.io/metrics/pkg/apis/metrics/v1alpha1/generated.proto // DO NOT EDIT! /* Package v1alpha1 is a generated protocol buffer package. It is generated from these files: - k8s.io/metrics/pkg/apis/metrics/v1alpha1/generated.proto + k8s.io/kubernetes/vendor/k8s.io/metrics/pkg/apis/metrics/v1alpha1/generated.proto It has these top-level messages: ContainerMetrics @@ -54,7 +54,9 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *ContainerMetrics) Reset() { *m = ContainerMetrics{} } func (*ContainerMetrics) ProtoMessage() {} @@ -83,41 +85,45 @@ func init() { proto.RegisterType((*PodMetrics)(nil), "k8s.io.metrics.pkg.apis.metrics.v1alpha1.PodMetrics") proto.RegisterType((*PodMetricsList)(nil), "k8s.io.metrics.pkg.apis.metrics.v1alpha1.PodMetricsList") } -func (m *ContainerMetrics) Marshal() (data []byte, err error) { +func (m *ContainerMetrics) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ContainerMetrics) MarshalTo(data []byte) (int, error) { +func (m *ContainerMetrics) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) if len(m.Usage) > 0 { for k := range m.Usage { - data[i] = 0x12 + dAtA[i] = 0x12 i++ v := m.Usage[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n1, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n1, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -127,61 +133,65 @@ func (m *ContainerMetrics) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *NodeMetrics) Marshal() (data []byte, err error) { +func (m *NodeMetrics) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeMetrics) MarshalTo(data []byte) (int, error) { +func (m *NodeMetrics) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n2, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n2, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Timestamp.Size())) - n3, err := m.Timestamp.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Timestamp.Size())) + n3, err := m.Timestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n3 - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Window.Size())) - n4, err := m.Window.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Window.Size())) + n4, err := m.Window.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n4 if len(m.Usage) > 0 { for k := range m.Usage { - data[i] = 0x22 + dAtA[i] = 0x22 i++ v := m.Usage[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n5, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n5, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -191,35 +201,35 @@ func (m *NodeMetrics) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *NodeMetricsList) Marshal() (data []byte, err error) { +func (m *NodeMetricsList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeMetricsList) MarshalTo(data []byte) (int, error) { +func (m *NodeMetricsList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n6, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n6, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n6 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -229,51 +239,51 @@ func (m *NodeMetricsList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PodMetrics) Marshal() (data []byte, err error) { +func (m *PodMetrics) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodMetrics) MarshalTo(data []byte) (int, error) { +func (m *PodMetrics) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n7, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n7, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n7 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Timestamp.Size())) - n8, err := m.Timestamp.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Timestamp.Size())) + n8, err := m.Timestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n8 - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Window.Size())) - n9, err := m.Window.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Window.Size())) + n9, err := m.Window.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n9 if len(m.Containers) > 0 { for _, msg := range m.Containers { - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -283,35 +293,35 @@ func (m *PodMetrics) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PodMetricsList) Marshal() (data []byte, err error) { +func (m *PodMetricsList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodMetricsList) MarshalTo(data []byte) (int, error) { +func (m *PodMetricsList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n10, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n10, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n10 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -321,31 +331,31 @@ func (m *PodMetricsList) MarshalTo(data []byte) (int, error) { return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m *ContainerMetrics) Size() (n int) { @@ -532,8 +542,8 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *ContainerMetrics) Unmarshal(data []byte) error { - l := len(data) +func (m *ContainerMetrics) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -545,7 +555,7 @@ func (m *ContainerMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -573,7 +583,7 @@ func (m *ContainerMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -588,7 +598,7 @@ func (m *ContainerMetrics) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -602,7 +612,7 @@ func (m *ContainerMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -624,7 +634,7 @@ func (m *ContainerMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -639,7 +649,7 @@ func (m *ContainerMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -654,61 +664,66 @@ func (m *ContainerMetrics) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := k8s_io_client_go_pkg_api_v1.ResourceName(data[iNdEx:postStringIndexmapkey]) + mapkey := k8s_io_client_go_pkg_api_v1.ResourceName(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if m.Usage == nil { + m.Usage = make(k8s_io_client_go_pkg_api_v1.ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } + iNdEx = postmsgIndex + m.Usage[k8s_io_client_go_pkg_api_v1.ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Usage[k8s_io_client_go_pkg_api_v1.ResourceName(mapkey)] = mapvalue } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.Usage == nil { - m.Usage = make(k8s_io_client_go_pkg_api_v1.ResourceList) - } - m.Usage[k8s_io_client_go_pkg_api_v1.ResourceName(mapkey)] = *mapvalue iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -727,8 +742,8 @@ func (m *ContainerMetrics) Unmarshal(data []byte) error { } return nil } -func (m *NodeMetrics) Unmarshal(data []byte) error { - l := len(data) +func (m *NodeMetrics) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -740,7 +755,7 @@ func (m *NodeMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -768,7 +783,7 @@ func (m *NodeMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -782,7 +797,7 @@ func (m *NodeMetrics) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -798,7 +813,7 @@ func (m *NodeMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -812,7 +827,7 @@ func (m *NodeMetrics) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Timestamp.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Timestamp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -828,7 +843,7 @@ func (m *NodeMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -842,7 +857,7 @@ func (m *NodeMetrics) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Window.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Window.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -858,7 +873,7 @@ func (m *NodeMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -880,7 +895,7 @@ func (m *NodeMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -895,7 +910,7 @@ func (m *NodeMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -910,61 +925,66 @@ func (m *NodeMetrics) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := k8s_io_client_go_pkg_api_v1.ResourceName(data[iNdEx:postStringIndexmapkey]) + mapkey := k8s_io_client_go_pkg_api_v1.ResourceName(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if m.Usage == nil { + m.Usage = make(k8s_io_client_go_pkg_api_v1.ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } + iNdEx = postmsgIndex + m.Usage[k8s_io_client_go_pkg_api_v1.ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Usage[k8s_io_client_go_pkg_api_v1.ResourceName(mapkey)] = mapvalue } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.Usage == nil { - m.Usage = make(k8s_io_client_go_pkg_api_v1.ResourceList) - } - m.Usage[k8s_io_client_go_pkg_api_v1.ResourceName(mapkey)] = *mapvalue iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -983,8 +1003,8 @@ func (m *NodeMetrics) Unmarshal(data []byte) error { } return nil } -func (m *NodeMetricsList) Unmarshal(data []byte) error { - l := len(data) +func (m *NodeMetricsList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -996,7 +1016,7 @@ func (m *NodeMetricsList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1024,7 +1044,7 @@ func (m *NodeMetricsList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1038,7 +1058,7 @@ func (m *NodeMetricsList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1054,7 +1074,7 @@ func (m *NodeMetricsList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1069,13 +1089,13 @@ func (m *NodeMetricsList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, NodeMetrics{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1094,8 +1114,8 @@ func (m *NodeMetricsList) Unmarshal(data []byte) error { } return nil } -func (m *PodMetrics) Unmarshal(data []byte) error { - l := len(data) +func (m *PodMetrics) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1107,7 +1127,7 @@ func (m *PodMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1135,7 +1155,7 @@ func (m *PodMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1149,7 +1169,7 @@ func (m *PodMetrics) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1165,7 +1185,7 @@ func (m *PodMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1179,7 +1199,7 @@ func (m *PodMetrics) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Timestamp.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Timestamp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1195,7 +1215,7 @@ func (m *PodMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1209,7 +1229,7 @@ func (m *PodMetrics) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Window.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Window.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1225,7 +1245,7 @@ func (m *PodMetrics) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1240,13 +1260,13 @@ func (m *PodMetrics) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Containers = append(m.Containers, ContainerMetrics{}) - if err := m.Containers[len(m.Containers)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Containers[len(m.Containers)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1265,8 +1285,8 @@ func (m *PodMetrics) Unmarshal(data []byte) error { } return nil } -func (m *PodMetricsList) Unmarshal(data []byte) error { - l := len(data) +func (m *PodMetricsList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1278,7 +1298,7 @@ func (m *PodMetricsList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1306,7 +1326,7 @@ func (m *PodMetricsList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1320,7 +1340,7 @@ func (m *PodMetricsList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1336,7 +1356,7 @@ func (m *PodMetricsList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1351,13 +1371,13 @@ func (m *PodMetricsList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, PodMetrics{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1376,8 +1396,8 @@ func (m *PodMetricsList) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -1388,7 +1408,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1406,7 +1426,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -1423,7 +1443,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1446,7 +1466,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1457,7 +1477,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -1481,47 +1501,53 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/kubernetes/vendor/k8s.io/metrics/pkg/apis/metrics/v1alpha1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 653 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x54, 0x31, 0x6f, 0xd3, 0x40, - 0x18, 0x8d, 0x9b, 0xa4, 0x6a, 0x2f, 0x50, 0x8a, 0xa7, 0x2a, 0x83, 0x5b, 0x65, 0x8a, 0x8a, 0x7a, - 0xa6, 0xa5, 0xa0, 0xa8, 0x13, 0x32, 0xed, 0x80, 0x44, 0x0b, 0x58, 0x05, 0x44, 0x61, 0xe0, 0xe2, - 0x1c, 0xce, 0x91, 0xf8, 0xce, 0xf2, 0x9d, 0x53, 0x65, 0x43, 0xfc, 0x02, 0x24, 0x7e, 0x0f, 0x0b, - 0x53, 0x10, 0x12, 0xea, 0xc8, 0x14, 0x48, 0xfa, 0x2f, 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30, 0x36, - 0xb4, 0x93, 0xb1, 0xa1, 0xfd, 0x18, 0x1b, 0xda, 0xfb, 0x53, 0xa3, 0x70, 0xb4, 0x90, 0x90, 0xfd, - 0x0a, 0x00, 0x00, 0xff, 0xff, 0xc4, 0x2d, 0x5f, 0xdb, 0xdd, 0x08, 0x00, 0x00, + // 681 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x54, 0xc1, 0x4f, 0x13, 0x4f, + 0x14, 0xee, 0x52, 0x4a, 0x60, 0xfa, 0xfb, 0x21, 0xee, 0x89, 0xf4, 0xb0, 0x25, 0x3d, 0x35, 0x18, + 0x66, 0x05, 0xd1, 0x10, 0x4e, 0x66, 0x85, 0x83, 0x89, 0xa0, 0x6c, 0x50, 0x23, 0x7a, 0x70, 0xba, + 0x1d, 0xb7, 0x63, 0xbb, 0x33, 0x9b, 0x9d, 0xd9, 0x92, 0xde, 0x88, 0x47, 0x4f, 0x26, 0x46, 0xff, + 0x26, 0x8c, 0x17, 0x8e, 0x9e, 0x40, 0xea, 0x1f, 0xe0, 0xc5, 0x93, 0x27, 0x33, 0xd3, 0xd9, 0x6e, + 0x65, 0xa1, 0x6c, 0x38, 0x78, 0xe2, 0x36, 0xf3, 0x66, 0xbe, 0xef, 0xbd, 0xf7, 0xbd, 0x6f, 0x06, + 0xec, 0xb4, 0xd7, 0x38, 0x24, 0xcc, 0x6e, 0xc7, 0x0d, 0x1c, 0x51, 0x2c, 0x30, 0xb7, 0xbb, 0x98, + 0x36, 0x59, 0x64, 0xeb, 0x83, 0x00, 0x8b, 0x88, 0x78, 0xdc, 0x0e, 0xdb, 0xbe, 0x8d, 0x42, 0xc2, + 0x87, 0x81, 0xee, 0x32, 0xea, 0x84, 0x2d, 0xb4, 0x6c, 0xfb, 0x98, 0xe2, 0x08, 0x09, 0xdc, 0x84, + 0x61, 0xc4, 0x04, 0x33, 0xeb, 0x03, 0x24,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d0, 0x87, 0x93, 0xca, 0x87, 0xf7, 0xf3, 0xfb, 0x70, 0x44, 0xdd, + 0x6b, 0x0b, 0x9e, 0x67, 0xc1, 0xaf, 0x06, 0xb8, 0x31, 0x22, 0x92, 0xec, 0xd0, 0x7c, 0x95, 0xb1, + 0x61, 0xce, 0x49, 0x4a, 0xb4, 0x32, 0xe1, 0x9c, 0x96, 0x77, 0x3a, 0x89, 0x8c, 0x58, 0x70, 0x0f, + 0x94, 0x88, 0xc0, 0x01, 0xd7, 0x9f, 0xca, 0xdd, 0x2b, 0x0d, 0xd3, 0xf9, 0x3f, 0x19, 0xe0, 0x43, + 0xc9, 0xe5, 0x0e, 0x28, 0x6b, 0x1f, 0x8b, 0x00, 0x3c, 0x61, 0xcd, 0xeb, 0xf7, 0x34, 0xf6, 0x3d, + 0x51, 0x00, 0xbc, 0xe4, 0x7f, 0xe6, 0xfa, 0x4d, 0xad, 0x5f, 0xfd, 0x6f, 0x4f, 0x25, 0x1a, 0x9e, + 0x70, 0x77, 0x24, 0x43, 0xed, 0x8b, 0x01, 0x66, 0xd3, 0xa9, 0xfc, 0x03, 0x8b, 0xbd, 0xf8, 0xdb, + 0x62, 0xab, 0xf9, 0x7b, 0x4b, 0xcb, 0x3c, 0xdf, 0x61, 0xce, 0xe2, 0xe1, 0xa9, 0x55, 0x38, 0x3a, + 0xb5, 0x0a, 0xdf, 0x4e, 0xad, 0xc2, 0x41, 0xdf, 0x32, 0x0e, 0xfb, 0x96, 0x71, 0xd4, 0xb7, 0x8c, + 0xef, 0x7d, 0xcb, 0xf8, 0xf0, 0xc3, 0x2a, 0xec, 0x4d, 0x27, 0x64, 0x7f, 0x02, 0x00, 0x00, 0xff, + 0xff, 0x1c, 0xe1, 0xf7, 0xa5, 0x5a, 0x09, 0x00, 0x00, } diff --git a/staging/src/k8s.io/metrics/pkg/apis/metrics/v1alpha1/types.go b/staging/src/k8s.io/metrics/pkg/apis/metrics/v1alpha1/types.go index 452fc6a346e05..345d2d95759fe 100644 --- a/staging/src/k8s.io/metrics/pkg/apis/metrics/v1alpha1/types.go +++ b/staging/src/k8s.io/metrics/pkg/apis/metrics/v1alpha1/types.go @@ -29,15 +29,15 @@ import ( // resource usage metrics of a node. type NodeMetrics struct { metav1.TypeMeta `json:",inline"` - metav1.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // The following fields define time interval from which metrics were // collected from the interval [Timestamp-Window, Timestamp]. - Timestamp metav1.Time `json:"timestamp"` - Window metav1.Duration `json:"window"` + Timestamp metav1.Time `json:"timestamp" protobuf:"bytes,2,opt,name=timestamp"` + Window metav1.Duration `json:"window" protobuf:"bytes,3,opt,name=window"` // The memory usage is the memory working set. - Usage v1.ResourceList `json:"usage"` + Usage v1.ResourceList `json:"usage" protobuf:"bytes,4,rep,name=usage,casttype=k8s.io/client-go/pkg/api/v1.ResourceList,castkey=k8s.io/client-go/pkg/api/v1.ResourceName,castvalue=k8s.io/apimachinery/pkg/api/resource.Quantity"` } // NodeMetricsList is a list of NodeMetrics. @@ -45,10 +45,10 @@ type NodeMetricsList struct { metav1.TypeMeta `json:",inline"` // Standard list metadata. // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds - metav1.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of node metrics. - Items []NodeMetrics `json:"items"` + Items []NodeMetrics `json:"items" protobuf:"bytes,2,rep,name=items"` } // +genclient=true @@ -58,15 +58,15 @@ type NodeMetricsList struct { // resource usage metrics of a pod. type PodMetrics struct { metav1.TypeMeta `json:",inline"` - metav1.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // The following fields define time interval from which metrics were // collected from the interval [Timestamp-Window, Timestamp]. - Timestamp metav1.Time `json:"timestamp"` - Window metav1.Duration `json:"window"` + Timestamp metav1.Time `json:"timestamp" protobuf:"bytes,2,opt,name=timestamp"` + Window metav1.Duration `json:"window" protobuf:"bytes,3,opt,name=window"` // Metrics for all containers are collected within the same time window. - Containers []ContainerMetrics `json:"containers"` + Containers []ContainerMetrics `json:"containers" protobuf:"bytes,4,rep,name=containers"` } // PodMetricsList is a list of PodMetrics. @@ -74,16 +74,16 @@ type PodMetricsList struct { metav1.TypeMeta `json:",inline"` // Standard list metadata. // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds - metav1.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of pod metrics. - Items []PodMetrics `json:"items"` + Items []PodMetrics `json:"items" protobuf:"bytes,2,rep,name=items"` } // resource usage metrics of a container. type ContainerMetrics struct { // Container name corresponding to the one from pod.spec.containers. - Name string `json:"name"` + Name string `json:"name" protobuf:"bytes,1,opt,name=name"` // The memory usage is the memory working set. - Usage v1.ResourceList `json:"usage"` + Usage v1.ResourceList `json:"usage" protobuf:"bytes,2,rep,name=usage,casttype=k8s.io/client-go/pkg/api/v1.ResourceList,castkey=k8s.io/client-go/pkg/api/v1.ResourceName,castvalue=k8s.io/apimachinery/pkg/api/resource.Quantity"` } diff --git a/staging/src/k8s.io/sample-apiserver/pkg/apiserver/apiserver.go b/staging/src/k8s.io/sample-apiserver/pkg/apiserver/apiserver.go index f014e7f92b90b..619aece7f0bed 100644 --- a/staging/src/k8s.io/sample-apiserver/pkg/apiserver/apiserver.go +++ b/staging/src/k8s.io/sample-apiserver/pkg/apiserver/apiserver.go @@ -90,7 +90,7 @@ func (c *Config) SkipComplete() completedConfig { // New returns a new instance of WardleServer from the given config. func (c completedConfig) New() (*WardleServer, error) { - genericServer, err := c.Config.GenericConfig.SkipComplete().New(genericapiserver.EmptyDelegate) // completion is done in Complete, no need for a second time + genericServer, err := c.Config.GenericConfig.SkipComplete().New("sample-apiserver", genericapiserver.EmptyDelegate) // completion is done in Complete, no need for a second time if err != nil { return nil, err } diff --git a/test/e2e/BUILD b/test/e2e/BUILD index 3097b77e694d3..2c96bf43e57b1 100644 --- a/test/e2e/BUILD +++ b/test/e2e/BUILD @@ -85,6 +85,7 @@ go_library( "network_policy.go", "networking.go", "networking_perf.go", + "no-snat.go", "nodeoutofdisk.go", "nvidia-gpus.go", "pod_gc.go", diff --git a/test/e2e/e2e.go b/test/e2e/e2e.go index 37b76c85ae495..349c02adc1b16 100644 --- a/test/e2e/e2e.go +++ b/test/e2e/e2e.go @@ -18,6 +18,7 @@ package e2e import ( "fmt" + "io/ioutil" "os" "path" "sync" @@ -39,6 +40,7 @@ import ( "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" "k8s.io/kubernetes/pkg/cloudprovider/providers/azure" gcecloud "k8s.io/kubernetes/pkg/cloudprovider/providers/gce" + "k8s.io/kubernetes/pkg/metrics" "k8s.io/kubernetes/pkg/util/logs" commontest "k8s.io/kubernetes/test/e2e/common" "k8s.io/kubernetes/test/e2e/framework" @@ -266,8 +268,45 @@ var _ = ginkgo.SynchronizedAfterSuite(func() { if framework.TestContext.ReportDir != "" { framework.CoreDump(framework.TestContext.ReportDir) } + if framework.TestContext.GatherSuiteMetricsAfterTest { + if err := gatherTestSuiteMetrics(); err != nil { + framework.Logf("Error gathering metrics: %v", err) + } + } }) +func gatherTestSuiteMetrics() error { + framework.Logf("Gathering metrics") + c, err := framework.LoadClientset() + if err != nil { + return fmt.Errorf("error loading client: %v", err) + } + + // Grab metrics for apiserver, scheduler, controller-manager, kubelet (for non-kubemark case). + grabber, err := metrics.NewMetricsGrabber(c, !framework.ProviderIs("kubemark"), true, true, true) + if err != nil { + return fmt.Errorf("failed to create MetricsGrabber: %v", err) + } + + received, err := grabber.Grab() + if err != nil { + return fmt.Errorf("failed to grab metrics: %v", err) + } + + metricsForE2E := (*framework.MetricsForE2E)(&received) + metricsJson := metricsForE2E.PrintJSON() + if framework.TestContext.ReportDir != "" { + filePath := path.Join(framework.TestContext.ReportDir, "MetricsForE2ESuite_"+time.Now().Format(time.RFC3339)+".json") + if err := ioutil.WriteFile(filePath, []byte(metricsJson), 0644); err != nil { + return fmt.Errorf("error writing to %q: %v", filePath, err) + } + } else { + framework.Logf("\n\nTest Suite Metrics:\n%s\n\n", metricsJson) + } + + return nil +} + // TestE2E checks configuration parameters (specified through flags) and then runs // E2E tests using the Ginkgo runner. // If a "report directory" is specified, one or more JUnit test reports will be diff --git a/test/e2e/empty.go b/test/e2e/empty.go index c6437183ffe02..925982fa3db5d 100644 --- a/test/e2e/empty.go +++ b/test/e2e/empty.go @@ -43,7 +43,7 @@ var _ = framework.KubeDescribe("Empty [Feature:Empty]", func() { }) It("starts a pod", func() { - configs, _ := perf.GenerateConfigsForGroup([]*v1.Namespace{f.Namespace}, "empty-pod", 1, 1, framework.GetPauseImageName(f.ClientSet), []string{}, api.Kind("ReplicationController"), 0) + configs, _, _ := perf.GenerateConfigsForGroup([]*v1.Namespace{f.Namespace}, "empty-pod", 1, 1, framework.GetPauseImageName(f.ClientSet), []string{}, api.Kind("ReplicationController"), 0, 0) if len(configs) != 1 { framework.Failf("generateConfigs should have generated single config") } diff --git a/test/e2e/firewall.go b/test/e2e/firewall.go index d6640e1808402..0030dfa57a540 100644 --- a/test/e2e/firewall.go +++ b/test/e2e/firewall.go @@ -22,6 +22,7 @@ import ( "k8s.io/apimachinery/pkg/util/sets" "k8s.io/kubernetes/pkg/api/v1" "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" + "k8s.io/kubernetes/pkg/cloudprovider" gcecloud "k8s.io/kubernetes/pkg/cloudprovider/providers/gce" "k8s.io/kubernetes/pkg/master/ports" "k8s.io/kubernetes/test/e2e/framework" @@ -45,13 +46,18 @@ var _ = framework.KubeDescribe("Firewall rule", func() { gceCloud = cloudConfig.Provider.(*gcecloud.GCECloud) }) - // This test takes around 4 minutes to run + // This test takes around 6 minutes to run It("[Slow] [Serial] should create valid firewall rules for LoadBalancer type service", func() { ns := f.Namespace.Name // This source ranges is just used to examine we have exact same things on LB firewall rules firewallTestSourceRanges := []string{"0.0.0.0/1", "128.0.0.0/1"} serviceName := "firewall-test-loadbalancer" + By("Getting cluster ID") + clusterID, err := framework.GetClusterID(cs) + Expect(err).NotTo(HaveOccurred()) + framework.Logf("Got cluster ID: %v", clusterID) + jig := framework.NewServiceTestJig(cs, serviceName) nodesNames := jig.GetNodesNames(framework.MaxNodesForEndpointsTests) if len(nodesNames) <= 0 { @@ -59,28 +65,52 @@ var _ = framework.KubeDescribe("Firewall rule", func() { } nodesSet := sets.NewString(nodesNames...) - // OnlyLocal service is needed to examine which exact nodes the requests are being forwarded to by the Load Balancer on GCE - By("Creating a LoadBalancer type service with ExternalTrafficPolicy=Local") - svc := jig.CreateOnlyLocalLoadBalancerService(ns, serviceName, - framework.LoadBalancerCreateTimeoutDefault, false, func(svc *v1.Service) { - svc.Spec.Ports = []v1.ServicePort{{Protocol: "TCP", Port: framework.FirewallTestHttpPort}} - svc.Spec.LoadBalancerSourceRanges = firewallTestSourceRanges - }) + By("Creating a LoadBalancer type service with ExternalTrafficPolicy=Global") + svc := jig.CreateLoadBalancerService(ns, serviceName, framework.LoadBalancerCreateTimeoutDefault, func(svc *v1.Service) { + svc.Spec.Ports = []v1.ServicePort{{Protocol: "TCP", Port: framework.FirewallTestHttpPort}} + svc.Spec.LoadBalancerSourceRanges = firewallTestSourceRanges + }) defer func() { jig.UpdateServiceOrFail(svc.Namespace, svc.Name, func(svc *v1.Service) { svc.Spec.Type = v1.ServiceTypeNodePort svc.Spec.LoadBalancerSourceRanges = nil }) Expect(cs.Core().Services(svc.Namespace).Delete(svc.Name, nil)).NotTo(HaveOccurred()) + By("Waiting for the local traffic health check firewall rule to be deleted") + localHCFwName := framework.MakeHealthCheckFirewallNameForLBService(clusterID, cloudprovider.GetLoadBalancerName(svc), false) + _, err := framework.WaitForFirewallRule(gceCloud, localHCFwName, false, framework.LoadBalancerCleanupTimeout) + Expect(err).NotTo(HaveOccurred()) }() svcExternalIP := svc.Status.LoadBalancer.Ingress[0].IP - By("Checking if service's firewall rules are correct") + By("Checking if service's firewall rule is correct") nodeTags := framework.GetInstanceTags(cloudConfig, nodesNames[0]) - expFw := framework.ConstructFirewallForLBService(svc, nodeTags.Items) - fw, err := gceCloud.GetFirewall(expFw.Name) + lbFw := framework.ConstructFirewallForLBService(svc, nodeTags.Items) + fw, err := gceCloud.GetFirewall(lbFw.Name) + Expect(err).NotTo(HaveOccurred()) + Expect(framework.VerifyFirewallRule(fw, lbFw, cloudConfig.Network, false)).NotTo(HaveOccurred()) + + By("Checking if service's nodes health check firewall rule is correct") + nodesHCFw := framework.ConstructHealthCheckFirewallForLBService(clusterID, svc, nodeTags.Items, true) + fw, err = gceCloud.GetFirewall(nodesHCFw.Name) + Expect(err).NotTo(HaveOccurred()) + Expect(framework.VerifyFirewallRule(fw, nodesHCFw, cloudConfig.Network, false)).NotTo(HaveOccurred()) + + // OnlyLocal service is needed to examine which exact nodes the requests are being forwarded to by the Load Balancer on GCE + By("Updating LoadBalancer service to ExternalTrafficPolicy=Local") + svc = jig.UpdateServiceOrFail(svc.Namespace, svc.Name, func(svc *v1.Service) { + svc.Spec.ExternalTrafficPolicy = v1.ServiceExternalTrafficPolicyTypeLocal + }) + + By("Waiting for the nodes health check firewall rule to be deleted") + _, err = framework.WaitForFirewallRule(gceCloud, nodesHCFw.Name, false, framework.LoadBalancerCleanupTimeout) + Expect(err).NotTo(HaveOccurred()) + + By("Waiting for the correct local traffic health check firewall rule to be created") + localHCFw := framework.ConstructHealthCheckFirewallForLBService(clusterID, svc, nodeTags.Items, false) + fw, err = framework.WaitForFirewallRule(gceCloud, localHCFw.Name, true, framework.LoadBalancerCreateTimeoutDefault) Expect(err).NotTo(HaveOccurred()) - Expect(framework.VerifyFirewallRule(fw, expFw, cloudConfig.Network, false)).NotTo(HaveOccurred()) + Expect(framework.VerifyFirewallRule(fw, localHCFw, cloudConfig.Network, false)).NotTo(HaveOccurred()) By(fmt.Sprintf("Creating netexec pods on at most %v nodes", framework.MaxNodesForEndpointsTests)) for i, nodeName := range nodesNames { @@ -100,7 +130,7 @@ var _ = framework.KubeDescribe("Firewall rule", func() { // by removing the tag on one vm and make sure it doesn't get any traffic. This is an imperfect // simulation, we really want to check that traffic doesn't reach a vm outside the GKE cluster, but // that's much harder to do in the current e2e framework. - By("Removing tags from one of the nodes") + By(fmt.Sprintf("Removing tags from one of the nodes: %v", nodesNames[0])) nodesSet.Delete(nodesNames[0]) removedTags := framework.SetInstanceTags(cloudConfig, nodesNames[0], []string{}) defer func() { diff --git a/test/e2e/framework/BUILD b/test/e2e/framework/BUILD index 530287e91ab44..8d96e4ea293d5 100644 --- a/test/e2e/framework/BUILD +++ b/test/e2e/framework/BUILD @@ -45,6 +45,7 @@ go_library( "//pkg/api/v1/helper:go_default_library", "//pkg/api/v1/node:go_default_library", "//pkg/api/v1/pod:go_default_library", + "//pkg/api/v1/service:go_default_library", "//pkg/apis/apps/v1beta1:go_default_library", "//pkg/apis/authorization/v1beta1:go_default_library", "//pkg/apis/batch:go_default_library", diff --git a/test/e2e/framework/firewall_util.go b/test/e2e/framework/firewall_util.go index fe6ede0a57df6..2de5860777a87 100644 --- a/test/e2e/framework/firewall_util.go +++ b/test/e2e/framework/firewall_util.go @@ -18,12 +18,16 @@ package framework import ( "fmt" + "net/http" "strconv" "strings" "time" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/util/sets" + "k8s.io/apimachinery/pkg/util/wait" "k8s.io/kubernetes/pkg/api/v1" + apiservice "k8s.io/kubernetes/pkg/api/v1/service" "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" "k8s.io/kubernetes/pkg/cloudprovider" gcecloud "k8s.io/kubernetes/pkg/cloudprovider/providers/gce" @@ -41,7 +45,7 @@ const ( ) // MakeFirewallNameForLBService return the expected firewall name for a LB service. -// This should match the formatting of makeFirewallName() in pkg/cloudprovider/providers/gce/gce.go +// This should match the formatting of makeFirewallName() in pkg/cloudprovider/providers/gce/gce_loadbalancer.go func MakeFirewallNameForLBService(name string) string { return fmt.Sprintf("k8s-fw-%s", name) } @@ -68,6 +72,32 @@ func ConstructFirewallForLBService(svc *v1.Service, nodesTags []string) *compute return &fw } +func MakeHealthCheckFirewallNameForLBService(clusterID, name string, isNodesHealthCheck bool) string { + return gcecloud.MakeHealthCheckFirewallName(clusterID, name, isNodesHealthCheck) +} + +// ConstructHealthCheckFirewallForLBService returns the expected GCE firewall rule for a loadbalancer type service +func ConstructHealthCheckFirewallForLBService(clusterID string, svc *v1.Service, nodesTags []string, isNodesHealthCheck bool) *compute.Firewall { + if svc.Spec.Type != v1.ServiceTypeLoadBalancer { + Failf("can not construct firewall rule for non-loadbalancer type service") + } + fw := compute.Firewall{} + fw.Name = MakeHealthCheckFirewallNameForLBService(clusterID, cloudprovider.GetLoadBalancerName(svc), isNodesHealthCheck) + fw.TargetTags = nodesTags + fw.SourceRanges = gcecloud.LoadBalancerSrcRanges() + healthCheckPort := gcecloud.GetNodesHealthCheckPort() + if !isNodesHealthCheck { + healthCheckPort = apiservice.GetServiceHealthCheckNodePort(svc) + } + fw.Allowed = []*compute.FirewallAllowed{ + { + IPProtocol: "tcp", + Ports: []string{fmt.Sprintf("%d", healthCheckPort)}, + }, + } + return &fw +} + // GetNodeTags gets tags from one of the Kubernetes nodes func GetNodeTags(c clientset.Interface, cloudConfig CloudConfig) *compute.Tags { nodes := GetReadySchedulableNodesOrDie(c) @@ -303,6 +333,9 @@ func SameStringArray(result, expected []string, include bool) error { // VerifyFirewallRule verifies whether the result firewall is consistent with the expected firewall. // When `portsSubset` is false, match given ports exactly. Otherwise, only check ports are included. func VerifyFirewallRule(res, exp *compute.Firewall, network string, portsSubset bool) error { + if res == nil || exp == nil { + return fmt.Errorf("res and exp must not be nil") + } if res.Name != exp.Name { return fmt.Errorf("incorrect name: %v, expected %v", res.Name, exp.Name) } @@ -325,3 +358,40 @@ func VerifyFirewallRule(res, exp *compute.Firewall, network string, portsSubset } return nil } + +func WaitForFirewallRule(gceCloud *gcecloud.GCECloud, fwName string, exist bool, timeout time.Duration) (*compute.Firewall, error) { + Logf("Waiting up to %v for firewall %v exist=%v", timeout, fwName, exist) + var fw *compute.Firewall + var err error + + condition := func() (bool, error) { + fw, err = gceCloud.GetFirewall(fwName) + if err != nil && exist || + err == nil && !exist || + err != nil && !exist && !IsGoogleAPIHTTPErrorCode(err, http.StatusNotFound) { + return false, nil + } + return true, nil + } + + if err := wait.PollImmediate(5*time.Second, timeout, condition); err != nil { + return nil, fmt.Errorf("error waiting for firewall %v exist=%v", fwName, exist) + } + return fw, nil +} + +func GetClusterID(c clientset.Interface) (string, error) { + cm, err := c.Core().ConfigMaps(metav1.NamespaceSystem).Get(gcecloud.UIDConfigMapName, metav1.GetOptions{}) + if err != nil || cm == nil { + return "", fmt.Errorf("error getting cluster ID: %v", err) + } + clusterID, clusterIDExists := cm.Data[gcecloud.UIDCluster] + providerID, providerIDExists := cm.Data[gcecloud.UIDProvider] + if !clusterIDExists { + return "", fmt.Errorf("cluster ID not set") + } + if providerIDExists { + return providerID, nil + } + return clusterID, nil +} diff --git a/test/e2e/framework/framework.go b/test/e2e/framework/framework.go index d9b0eb4fdc3d3..cb97e447442d3 100644 --- a/test/e2e/framework/framework.go +++ b/test/e2e/framework/framework.go @@ -325,9 +325,8 @@ func (f *Framework) AfterEach() { if TestContext.GatherMetricsAfterTest { By("Gathering metrics") - // Grab apiserver metrics and nodes' kubelet metrics (for non-kubemark case). - // TODO: enable Scheduler and ControllerManager metrics grabbing when Master's Kubelet will be registered. - grabber, err := metrics.NewMetricsGrabber(f.ClientSet, !ProviderIs("kubemark"), false, false, true) + // Grab apiserver, scheduler, controller-manager metrics and nodes' kubelet metrics (for non-kubemark case). + grabber, err := metrics.NewMetricsGrabber(f.ClientSet, !ProviderIs("kubemark"), true, true, true) if err != nil { Logf("Failed to create MetricsGrabber (skipping metrics gathering): %v", err) } else { diff --git a/test/e2e/framework/ingress_utils.go b/test/e2e/framework/ingress_utils.go index c801329fbd4a6..4b9912bcb9a2f 100644 --- a/test/e2e/framework/ingress_utils.go +++ b/test/e2e/framework/ingress_utils.go @@ -478,7 +478,7 @@ func (cont *GCEIngressController) deleteURLMap(del bool) (msg string) { func (cont *GCEIngressController) deleteBackendService(del bool) (msg string) { gceCloud := cont.Cloud.Provider.(*gcecloud.GCECloud) - beList, err := gceCloud.ListBackendServices() + beList, err := gceCloud.ListGlobalBackendServices() if err != nil { if cont.isHTTPErrorCode(err, http.StatusNotFound) { return msg @@ -495,7 +495,7 @@ func (cont *GCEIngressController) deleteBackendService(del bool) (msg string) { } if del { Logf("Deleting backed-service: %s", be.Name) - if err := gceCloud.DeleteBackendService(be.Name); err != nil && + if err := gceCloud.DeleteGlobalBackendService(be.Name); err != nil && !cont.isHTTPErrorCode(err, http.StatusNotFound) { msg += fmt.Sprintf("Failed to delete backend service %v: %v\n", be.Name, err) } diff --git a/test/e2e/framework/kubelet_stats.go b/test/e2e/framework/kubelet_stats.go index 9781b93117351..fc065ad97215e 100644 --- a/test/e2e/framework/kubelet_stats.go +++ b/test/e2e/framework/kubelet_stats.go @@ -39,7 +39,6 @@ import ( "k8s.io/kubernetes/pkg/master/ports" "k8s.io/kubernetes/pkg/metrics" - "github.com/golang/glog" "github.com/prometheus/common/model" ) @@ -103,10 +102,7 @@ func GetKubeletLatencyMetrics(ms metrics.KubeletMetrics) KubeletLatencyMetrics { latencyMethods := sets.NewString( kubeletmetrics.PodWorkerLatencyKey, kubeletmetrics.PodWorkerStartLatencyKey, - kubeletmetrics.SyncPodsLatencyKey, kubeletmetrics.PodStartLatencyKey, - kubeletmetrics.PodStatusLatencyKey, - kubeletmetrics.ContainerManagerOperationsKey, kubeletmetrics.CgroupManagerOperationsKey, kubeletmetrics.DockerOperationsLatencyKey, kubeletmetrics.PodWorkerStartLatencyKey, @@ -370,10 +366,8 @@ func getOneTimeResourceUsageOnNode( } f := func(name string, newStats *stats.ContainerStats) *ContainerResourceUsage { - // TODO(gmarek): remove when #46198 is debugged. - if newStats == nil || newStats.CPU == nil { - glog.Warning("NewStats is %#v for container %v", newStats, name) - return &ContainerResourceUsage{} + if newStats == nil || newStats.CPU == nil || newStats.Memory == nil { + return nil } return &ContainerResourceUsage{ Name: name, @@ -402,7 +396,9 @@ func getOneTimeResourceUsageOnNode( if !isInteresting { continue } - usageMap[pod.PodRef.Name+"/"+container.Name] = f(pod.PodRef.Name+"/"+container.Name, &container) + if usage := f(pod.PodRef.Name+"/"+container.Name, &container); usage != nil { + usageMap[pod.PodRef.Name+"/"+container.Name] = usage + } } } return usageMap, nil diff --git a/test/e2e/framework/log_size_monitoring.go b/test/e2e/framework/log_size_monitoring.go index c578b8a35339c..2d57a38b69406 100644 --- a/test/e2e/framework/log_size_monitoring.go +++ b/test/e2e/framework/log_size_monitoring.go @@ -249,9 +249,13 @@ func (g *LogSizeGatherer) Work() bool { ) if err != nil { Logf("Error while trying to SSH to %v, skipping probe. Error: %v", workItem.ip, err) - if workItem.backoffMultiplier < 128 { - workItem.backoffMultiplier *= 2 + // In case of repeated error give up. + if workItem.backoffMultiplier >= 128 { + Logf("Failed to ssh to a node %v multiple times in a row. Giving up.", workItem.ip) + g.wg.Done() + return false } + workItem.backoffMultiplier *= 2 go g.pushWorkItem(workItem) return true } diff --git a/test/e2e/framework/metrics_util.go b/test/e2e/framework/metrics_util.go index 71d4b4621ee7e..b067f07163cfe 100644 --- a/test/e2e/framework/metrics_util.go +++ b/test/e2e/framework/metrics_util.go @@ -122,9 +122,23 @@ var InterestingApiServerMetrics = []string{ } var InterestingControllerManagerMetrics = []string{ - "garbage_collector_event_queue_latency", - "garbage_collector_dirty_queue_latency", - "garbage_collector_orhan_queue_latency", + "garbage_collector_attempt_to_delete_queue_latency", + "garbage_collector_attempt_to_delete_work_duration", + "garbage_collector_attempt_to_orphan_queue_latency", + "garbage_collector_attempt_to_orphan_work_duration", + "garbage_collector_dirty_processing_latency_microseconds", + "garbage_collector_event_processing_latency_microseconds", + "garbage_collector_graph_changes_queue_latency", + "garbage_collector_graph_changes_work_duration", + "garbage_collector_orphan_processing_latency_microseconds", + + "namespace_queue_latency", + "namespace_queue_latency_sum", + "namespace_queue_latency_count", + "namespace_retries", + "namespace_work_duration", + "namespace_work_duration_sum", + "namespace_work_duration_count", } var InterestingKubeletMetrics = []string{ @@ -224,7 +238,7 @@ func (a *APIResponsiveness) Less(i, j int) bool { // Only 0.5, 0.9 and 0.99 quantiles are supported. func (a *APIResponsiveness) addMetricRequestLatency(resource, subresource, verb string, quantile float64, latency time.Duration) { for i, apicall := range a.APICalls { - if apicall.Resource == resource && apicall.Verb == verb { + if apicall.Resource == resource && apicall.Subresource == subresource && apicall.Verb == verb { a.APICalls[i] = setQuantileAPICall(apicall, quantile, latency) return } @@ -255,7 +269,7 @@ func setQuantile(metric *LatencyMetric, quantile float64, latency time.Duration) // Add request count to the APICall metric entry (creating one if necessary). func (a *APIResponsiveness) addMetricRequestCount(resource, subresource, verb string, count int) { for i, apicall := range a.APICalls { - if apicall.Resource == resource && apicall.Verb == verb { + if apicall.Resource == resource && apicall.Subresource == subresource && apicall.Verb == verb { a.APICalls[i].Count += count return } diff --git a/test/e2e/framework/perf_util.go b/test/e2e/framework/perf_util.go index 161a1173f3926..8f643a8663058 100644 --- a/test/e2e/framework/perf_util.go +++ b/test/e2e/framework/perf_util.go @@ -41,9 +41,10 @@ func ApiCallToPerfData(apicalls *APIResponsiveness) *perftype.PerfData { }, Unit: "ms", Labels: map[string]string{ - "Verb": apicall.Verb, - "Resource": apicall.Resource, - "Count": fmt.Sprintf("%v", apicall.Count), + "Verb": apicall.Verb, + "Resource": apicall.Resource, + "Subresource": apicall.Subresource, + "Count": fmt.Sprintf("%v", apicall.Count), }, } perfData.DataItems = append(perfData.DataItems, item) diff --git a/test/e2e/framework/pv_util.go b/test/e2e/framework/pv_util.go index dc6bf8693db75..5a913c20b839b 100644 --- a/test/e2e/framework/pv_util.go +++ b/test/e2e/framework/pv_util.go @@ -35,6 +35,7 @@ import ( "k8s.io/apimachinery/pkg/util/uuid" "k8s.io/kubernetes/pkg/api" "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/pkg/api/v1/helper" "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" awscloud "k8s.io/kubernetes/pkg/cloudprovider/providers/aws" gcecloud "k8s.io/kubernetes/pkg/cloudprovider/providers/gce" @@ -73,11 +74,13 @@ type PVCMap map[types.NamespacedName]pvcval // }, // } type PersistentVolumeConfig struct { - PVSource v1.PersistentVolumeSource - Prebind *v1.PersistentVolumeClaim - ReclaimPolicy v1.PersistentVolumeReclaimPolicy - NamePrefix string - Labels labels.Set + PVSource v1.PersistentVolumeSource + Prebind *v1.PersistentVolumeClaim + ReclaimPolicy v1.PersistentVolumeReclaimPolicy + NamePrefix string + Labels labels.Set + StorageClassName string + NodeAffinity *v1.NodeAffinity } // PersistentVolumeClaimConfig is consumed by MakePersistentVolumeClaim() to generate a PVC object. @@ -85,9 +88,10 @@ type PersistentVolumeConfig struct { // (+optional) Annotations defines the PVC's annotations type PersistentVolumeClaimConfig struct { - AccessModes []v1.PersistentVolumeAccessMode - Annotations map[string]string - Selector *metav1.LabelSelector + AccessModes []v1.PersistentVolumeAccessMode + Annotations map[string]string + Selector *metav1.LabelSelector + StorageClassName *string } // Clean up a pv and pvc in a single pv/pvc test case. @@ -561,7 +565,7 @@ func makePvcKey(ns, name string) types.NamespacedName { // is assigned, assumes "Retain". Specs are expected to match the test's PVC. // Note: the passed-in claim does not have a name until it is created and thus the PV's // ClaimRef cannot be completely filled-in in this func. Therefore, the ClaimRef's name -// is added later in createPVCPV. +// is added later in CreatePVCPV. func MakePersistentVolume(pvConfig PersistentVolumeConfig) *v1.PersistentVolume { var claimRef *v1.ObjectReference // If the reclaimPolicy is not provided, assume Retain @@ -575,7 +579,7 @@ func MakePersistentVolume(pvConfig PersistentVolumeConfig) *v1.PersistentVolume Namespace: pvConfig.Prebind.Namespace, } } - return &v1.PersistentVolume{ + pv := &v1.PersistentVolume{ ObjectMeta: metav1.ObjectMeta{ GenerateName: pvConfig.NamePrefix, Labels: pvConfig.Labels, @@ -594,9 +598,16 @@ func MakePersistentVolume(pvConfig PersistentVolumeConfig) *v1.PersistentVolume v1.ReadOnlyMany, v1.ReadWriteMany, }, - ClaimRef: claimRef, + ClaimRef: claimRef, + StorageClassName: pvConfig.StorageClassName, }, } + err := helper.StorageNodeAffinityToAlphaAnnotation(pv.Annotations, pvConfig.NodeAffinity) + if err != nil { + Logf("Setting storage node affinity failed: %v", err) + return nil + } + return pv } // Returns a PVC definition based on the namespace. @@ -625,6 +636,7 @@ func MakePersistentVolumeClaim(cfg PersistentVolumeClaimConfig, ns string) *v1.P v1.ResourceName(v1.ResourceStorage): resource.MustParse("1Gi"), }, }, + StorageClassName: cfg.StorageClassName, }, } } diff --git a/test/e2e/framework/service_util.go b/test/e2e/framework/service_util.go index e91cff78b071c..a1bce8f1f26b0 100644 --- a/test/e2e/framework/service_util.go +++ b/test/e2e/framework/service_util.go @@ -50,6 +50,10 @@ const ( // liberal. Fix tracked in #20567. KubeProxyLagTimeout = 5 * time.Minute + // KubeProxyEndpointLagTimeout is the maximum time a kube-proxy daemon on a node is allowed + // to not notice an Endpoint update. + KubeProxyEndpointLagTimeout = 30 * time.Second + // LoadBalancerLagTimeoutDefault is the maximum time a load balancer is allowed to // not respond after creation. LoadBalancerLagTimeoutDefault = 2 * time.Minute @@ -235,6 +239,25 @@ func (j *ServiceTestJig) CreateOnlyLocalLoadBalancerService(namespace, serviceNa return svc } +// CreateLoadBalancerService creates a loadbalancer service and waits +// for it to acquire an ingress IP. +func (j *ServiceTestJig) CreateLoadBalancerService(namespace, serviceName string, timeout time.Duration, tweak func(svc *v1.Service)) *v1.Service { + By("creating a service " + namespace + "/" + serviceName + " with type=LoadBalancer") + svc := j.CreateTCPServiceOrFail(namespace, func(svc *v1.Service) { + svc.Spec.Type = v1.ServiceTypeLoadBalancer + // We need to turn affinity off for our LB distribution tests + svc.Spec.SessionAffinity = v1.ServiceAffinityNone + if tweak != nil { + tweak(svc) + } + }) + + By("waiting for loadbalancer for service " + namespace + "/" + serviceName) + svc = j.WaitForLoadBalancerOrFail(namespace, serviceName, timeout) + j.SanityCheckService(svc, v1.ServiceTypeLoadBalancer) + return svc +} + func GetNodeAddresses(node *v1.Node, addressType v1.NodeAddressType) (ips []string) { for j := range node.Status.Addresses { nodeAddress := &node.Status.Addresses[j] @@ -693,7 +716,8 @@ func (j *ServiceTestJig) GetHTTPContent(host string, port int, timeout time.Dura var body bytes.Buffer var err error if pollErr := wait.PollImmediate(Poll, timeout, func() (bool, error) { - result, err := TestReachableHTTPWithContent(host, port, url, "", &body) + var result bool + result, err = TestReachableHTTPWithContent(host, port, url, "", &body) if err != nil { Logf("Error hitting %v:%v%v, retrying: %v", host, port, url, err) return false, nil @@ -733,18 +757,24 @@ func testHTTPHealthCheckNodePort(ip string, port int, request string) (bool, err return false, fmt.Errorf("Unexpected HTTP response code %s from health check responder at %s", resp.Status, url) } -func (j *ServiceTestJig) TestHTTPHealthCheckNodePort(host string, port int, request string, tries int) (pass, fail int, statusMsg string) { - for i := 0; i < tries; i++ { - success, err := testHTTPHealthCheckNodePort(host, port, request) - if success { - pass++ - } else { - fail++ +func (j *ServiceTestJig) TestHTTPHealthCheckNodePort(host string, port int, request string, timeout time.Duration, expectSucceed bool, threshold int) error { + count := 0 + condition := func() (bool, error) { + success, _ := testHTTPHealthCheckNodePort(host, port, request) + if success && expectSucceed || + !success && !expectSucceed { + count++ } - statusMsg += fmt.Sprintf("\nAttempt %d Error %v", i, err) - time.Sleep(1 * time.Second) + if count >= threshold { + return true, nil + } + return false, nil } - return pass, fail, statusMsg + + if err := wait.PollImmediate(time.Second, timeout, condition); err != nil { + return fmt.Errorf("error waiting for healthCheckNodePort: expected at least %d succeed=%v on %v%v, got %d", threshold, expectSucceed, host, port, count) + } + return nil } // Simple helper class to avoid too much boilerplate in tests diff --git a/test/e2e/framework/test_context.go b/test/e2e/framework/test_context.go index 779b5ceaf6366..b149142ff167a 100644 --- a/test/e2e/framework/test_context.go +++ b/test/e2e/framework/test_context.go @@ -73,6 +73,7 @@ type TestContextType struct { GatherKubeSystemResourceUsageData string GatherLogsSizes bool GatherMetricsAfterTest bool + GatherSuiteMetricsAfterTest bool // Currently supported values are 'hr' for human-readable and 'json'. It's a comma separated list. OutputPrintType string // NodeSchedulableTimeout is the timeout for waiting for all nodes to be schedulable. @@ -162,6 +163,7 @@ func RegisterCommonFlags() { flag.StringVar(&TestContext.GatherKubeSystemResourceUsageData, "gather-resource-usage", "false", "If set to 'true' or 'all' framework will be monitoring resource usage of system all add-ons in (some) e2e tests, if set to 'master' framework will be monitoring master node only, if set to 'none' of 'false' monitoring will be turned off.") flag.BoolVar(&TestContext.GatherLogsSizes, "gather-logs-sizes", false, "If set to true framework will be monitoring logs sizes on all machines running e2e tests.") flag.BoolVar(&TestContext.GatherMetricsAfterTest, "gather-metrics-at-teardown", false, "If set to true framwork will gather metrics from all components after each test.") + flag.BoolVar(&TestContext.GatherSuiteMetricsAfterTest, "gather-suite-metrics-at-teardown", false, "If set to true framwork will gather metrics from all components after the whole test suite completes.") flag.StringVar(&TestContext.OutputPrintType, "output-print-type", "json", "Format in which summaries should be printed: 'hr' for human readable, 'json' for JSON ones.") flag.BoolVar(&TestContext.DumpLogsOnFailure, "dump-logs-on-failure", true, "If set to true test will dump data about the namespace in which test was running.") flag.BoolVar(&TestContext.DisableLogDump, "disable-log-dump", false, "If set to true, logs from master and nodes won't be gathered after test run.") diff --git a/test/e2e/framework/util.go b/test/e2e/framework/util.go index 55986ae2f3dd4..0f31c013ed979 100644 --- a/test/e2e/framework/util.go +++ b/test/e2e/framework/util.go @@ -589,8 +589,6 @@ func WaitForPodsRunningReady(c clientset.Interface, ns string, minPods, allowedN switch { case res && err == nil: nOk++ - case pod.Status.Phase == v1.PodSucceeded: - continue case pod.Status.Phase == v1.PodSucceeded: Logf("The status of Pod %s is Succeeded which is unexpected", pod.ObjectMeta.Name) badPods = append(badPods, pod) @@ -5183,12 +5181,16 @@ func CleanupGCEResources(loadBalancerName string) (retErr error) { if err := DeleteGCEStaticIP(loadBalancerName); err != nil { Logf("%v", err) } + var hcNames []string hc, getErr := gceCloud.GetHttpHealthCheck(loadBalancerName) if getErr != nil && !IsGoogleAPIHTTPErrorCode(getErr, http.StatusNotFound) { retErr = fmt.Errorf("%v\n%v", retErr, getErr) return } - if err := gceCloud.DeleteTargetPool(loadBalancerName, hc); err != nil && + if hc != nil { + hcNames = append(hcNames, hc.Name) + } + if err := gceCloud.DeleteTargetPool(loadBalancerName, hcNames...); err != nil && !IsGoogleAPIHTTPErrorCode(err, http.StatusNotFound) { retErr = fmt.Errorf("%v\n%v", retErr, err) } diff --git a/test/e2e/framework/volume_util.go b/test/e2e/framework/volume_util.go index e22a42b768524..718a84ad2e06d 100644 --- a/test/e2e/framework/volume_util.go +++ b/test/e2e/framework/volume_util.go @@ -76,11 +76,18 @@ type VolumeTestConfig struct { ServerImage string // Ports to export from the server pod. TCP only. ServerPorts []int + // Commands to run in the container image. + ServerCmds []string // Arguments to pass to the container image. ServerArgs []string // Volumes needed to be mounted to the server container from the host // map -> ServerVolumes map[string]string + // Wait for the pod to terminate successfully + // False indicates that the pod is long running + WaitForCompletion bool + // NodeName to run pod on. Default is any node. + NodeName string } // VolumeTest contains a volume to mount into a client pod and its @@ -133,6 +140,11 @@ func StartVolumeServer(client clientset.Interface, config VolumeTestConfig) *v1. By(fmt.Sprint("creating ", serverPodName, " pod")) privileged := new(bool) *privileged = true + + restartPolicy := v1.RestartPolicyAlways + if config.WaitForCompletion { + restartPolicy = v1.RestartPolicyNever + } serverPod := &v1.Pod{ TypeMeta: metav1.TypeMeta{ Kind: "Pod", @@ -153,12 +165,15 @@ func StartVolumeServer(client clientset.Interface, config VolumeTestConfig) *v1. SecurityContext: &v1.SecurityContext{ Privileged: privileged, }, + Command: config.ServerCmds, Args: config.ServerArgs, Ports: serverPodPorts, VolumeMounts: mounts, }, }, - Volumes: volumes, + Volumes: volumes, + RestartPolicy: restartPolicy, + NodeName: config.NodeName, }, } @@ -176,12 +191,16 @@ func StartVolumeServer(client clientset.Interface, config VolumeTestConfig) *v1. ExpectNoError(err, "Failed to create %q pod: %v", serverPodName, err) } } - ExpectNoError(WaitForPodRunningInNamespace(client, serverPod)) - - if pod == nil { - By(fmt.Sprintf("locating the %q server pod", serverPodName)) - pod, err = podClient.Get(serverPodName, metav1.GetOptions{}) - ExpectNoError(err, "Cannot locate the server pod %q: %v", serverPodName, err) + if config.WaitForCompletion { + ExpectNoError(WaitForPodSuccessInNamespace(client, serverPod.Name, serverPod.Namespace)) + ExpectNoError(podClient.Delete(serverPod.Name, nil)) + } else { + ExpectNoError(WaitForPodRunningInNamespace(client, serverPod)) + if pod == nil { + By(fmt.Sprintf("locating the %q server pod", serverPodName)) + pod, err = podClient.Get(serverPodName, metav1.GetOptions{}) + ExpectNoError(err, "Cannot locate the server pod %q: %v", serverPodName, err) + } } return pod } diff --git a/test/e2e/no-snat.go b/test/e2e/no-snat.go new file mode 100644 index 0000000000000..4c4a141d6ca7d --- /dev/null +++ b/test/e2e/no-snat.go @@ -0,0 +1,258 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package e2e + +import ( + "fmt" + "io/ioutil" + "net/http" + "strconv" + "strings" + "time" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/wait" + "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/test/e2e/framework" + + . "github.com/onsi/ginkgo" + // . "github.com/onsi/gomega" +) + +const ( + testPodPort = 8080 + testPodImage = "gcr.io/google_containers/no-snat-test-amd64:1.0.1" + + testProxyPort = 31235 // Firewall rule allows external traffic on ports 30000-32767. I just picked a random one. + testProxyImage = "gcr.io/google_containers/no-snat-test-proxy-amd64:1.0.1" +) + +var ( + testPod = v1.Pod{ + ObjectMeta: metav1.ObjectMeta{ + GenerateName: "no-snat-test", + Labels: map[string]string{ + "no-snat-test": "", + }, + }, + Spec: v1.PodSpec{ + Containers: []v1.Container{ + { + Name: "no-snat-test", + Image: testPodImage, + Args: []string{"--port", strconv.Itoa(testPodPort)}, + Env: []v1.EnvVar{ + { + Name: "POD_IP", + ValueFrom: &v1.EnvVarSource{FieldRef: &v1.ObjectFieldSelector{FieldPath: "status.podIP"}}, + }, + }, + }, + }, + }, + } + + testProxyPod = v1.Pod{ + ObjectMeta: metav1.ObjectMeta{ + Name: "no-snat-test-proxy", + }, + Spec: v1.PodSpec{ + HostNetwork: true, + Containers: []v1.Container{ + { + Name: "no-snat-test-proxy", + Image: testProxyImage, + Args: []string{"--port", strconv.Itoa(testProxyPort)}, + Ports: []v1.ContainerPort{ + { + ContainerPort: testProxyPort, + HostPort: testProxyPort, + }, + }, + }, + }, + }, + } +) + +// Produces a pod spec that passes nip as NODE_IP env var using downward API +func newTestPod(nodename string, nip string) *v1.Pod { + pod := testPod + node_ip := v1.EnvVar{ + Name: "NODE_IP", + Value: nip, + } + pod.Spec.Containers[0].Env = append(pod.Spec.Containers[0].Env, node_ip) + pod.Spec.NodeName = nodename + return &pod +} + +func newTestProxyPod(nodename string) *v1.Pod { + pod := testProxyPod + pod.Spec.NodeName = nodename + return &pod +} + +func getIP(iptype v1.NodeAddressType, node *v1.Node) (string, error) { + for _, addr := range node.Status.Addresses { + if addr.Type == iptype { + return addr.Address, nil + } + } + return "", fmt.Errorf("did not find %s on Node", iptype) +} + +func getSchedulable(nodes []v1.Node) (*v1.Node, error) { + for _, node := range nodes { + if node.Spec.Unschedulable == false { + return &node, nil + } + } + return nil, fmt.Errorf("all Nodes were unschedulable") +} + +func checknosnatURL(proxy, pip string, ips []string) string { + return fmt.Sprintf("http://%s/checknosnat?target=%s&ips=%s", proxy, pip, strings.Join(ips, ",")) +} + +// This test verifies that a Pod on each node in a cluster can talk to Pods on every other node without SNAT. +// We use the [Feature:NoSNAT] tag so that most jobs will skip this test by default. +var _ = framework.KubeDescribe("NoSNAT [Feature:NoSNAT] [Slow]", func() { + f := framework.NewDefaultFramework("no-snat-test") + It("Should be able to send traffic between Pods without SNAT", func() { + cs := f.ClientSet + pc := cs.Core().Pods(f.Namespace.Name) + nc := cs.Core().Nodes() + + By("creating a test pod on each Node") + nodes, err := nc.List(metav1.ListOptions{}) + framework.ExpectNoError(err) + if len(nodes.Items) == 0 { + framework.ExpectNoError(fmt.Errorf("no Nodes in the cluster")) + } + for _, node := range nodes.Items { + // find the Node's internal ip address to feed to the Pod + inIP, err := getIP(v1.NodeInternalIP, &node) + framework.ExpectNoError(err) + + // target Pod at Node and feed Pod Node's InternalIP + pod := newTestPod(node.Name, inIP) + _, err = pc.Create(pod) + framework.ExpectNoError(err) + } + + // In some (most?) scenarios, the test harness doesn't run in the same network as the Pods, + // which means it can't query Pods using their cluster-internal IPs. To get around this, + // we create a Pod in a Node's host network, and have that Pod serve on a specific port of that Node. + // We can then ask this proxy Pod to query the internal endpoints served by the test Pods. + + // Find the first schedulable node; masters are marked unschedulable. We don't put the proxy on the master + // because in some (most?) deployments firewall rules don't allow external traffic to hit ports 30000-32767 + // on the master, but do allow this on the nodes. + node, err := getSchedulable(nodes.Items) + framework.ExpectNoError(err) + By("creating a no-snat-test-proxy Pod on Node " + node.Name + " port " + strconv.Itoa(testProxyPort) + + " so we can target our test Pods through this Node's ExternalIP") + + extIP, err := getIP(v1.NodeExternalIP, node) + framework.ExpectNoError(err) + proxyNodeIP := extIP + ":" + strconv.Itoa(testProxyPort) + + _, err = pc.Create(newTestProxyPod(node.Name)) + framework.ExpectNoError(err) + + By("waiting for all of the no-snat-test pods to be scheduled and running") + err = wait.PollImmediate(10*time.Second, 1*time.Minute, func() (bool, error) { + pods, err := pc.List(metav1.ListOptions{LabelSelector: "no-snat-test"}) + if err != nil { + return false, err + } + + // check all pods are running + for _, pod := range pods.Items { + if pod.Status.Phase != v1.PodRunning { + if pod.Status.Phase != v1.PodPending { + return false, fmt.Errorf("expected pod to be in phase \"Pending\" or \"Running\"") + } + return false, nil // pod is still pending + } + } + return true, nil // all pods are running + }) + framework.ExpectNoError(err) + + By("waiting for the no-snat-test-proxy Pod to be scheduled and running") + err = wait.PollImmediate(10*time.Second, 1*time.Minute, func() (bool, error) { + pod, err := pc.Get("no-snat-test-proxy", metav1.GetOptions{}) + if err != nil { + return false, err + } + if pod.Status.Phase != v1.PodRunning { + if pod.Status.Phase != v1.PodPending { + return false, fmt.Errorf("expected pod to be in phase \"Pending\" or \"Running\"") + } + return false, nil // pod is still pending + } + return true, nil // pod is running + }) + framework.ExpectNoError(err) + + By("sending traffic from each pod to the others and checking that SNAT does not occur") + pods, err := pc.List(metav1.ListOptions{LabelSelector: "no-snat-test"}) + framework.ExpectNoError(err) + + // collect pod IPs + podIPs := []string{} + for _, pod := range pods.Items { + podIPs = append(podIPs, pod.Status.PodIP+":"+strconv.Itoa(testPodPort)) + } + + // hit the /checknosnat endpoint on each Pod, tell each Pod to check all the other Pods + // this test is O(n^2) but it doesn't matter because we only run this test on small clusters (~3 nodes) + errs := []string{} + client := http.Client{ + Timeout: 5 * time.Minute, + } + for _, pip := range podIPs { + ips := []string{} + for _, ip := range podIPs { + if ip == pip { + continue + } + ips = append(ips, ip) + } + // hit /checknosnat on pip, via proxy + resp, err := client.Get(checknosnatURL(proxyNodeIP, pip, ips)) + framework.ExpectNoError(err) + + // check error code on the response, if 500 record the body, which will describe the error + if resp.StatusCode == 500 { + body, err := ioutil.ReadAll(resp.Body) + framework.ExpectNoError(err) + errs = append(errs, string(body)) + } + resp.Body.Close() + } + + // report the errors all at the end + if len(errs) > 0 { + str := strings.Join(errs, "\n") + err := fmt.Errorf("/checknosnat failed in the following cases:\n%s", str) + framework.ExpectNoError(err) + } + }) +}) diff --git a/test/e2e/perf/density.go b/test/e2e/perf/density.go index 607ae7d9c38ce..8be4c3f75b1c2 100644 --- a/test/e2e/perf/density.go +++ b/test/e2e/perf/density.go @@ -65,9 +65,10 @@ type DensityTestConfig struct { PollInterval time.Duration PodCount int // What kind of resource we want to create - kind schema.GroupKind - SecretConfigs []*testutils.SecretConfig - DaemonConfigs []*testutils.DaemonConfig + kind schema.GroupKind + SecretConfigs []*testutils.SecretConfig + ConfigMapConfigs []*testutils.ConfigMapConfig + DaemonConfigs []*testutils.DaemonConfig } func density30AddonResourceVerifier(numNodes int) map[string]framework.ResourceConstraint { @@ -193,11 +194,13 @@ func logPodStartupStatus(c clientset.Interface, expectedPods int, observedLabels func runDensityTest(dtc DensityTestConfig) time.Duration { defer GinkgoRecover() - // Create all secrets + // Create all secrets, configmaps and daemons. for i := range dtc.SecretConfigs { dtc.SecretConfigs[i].Run() } - + for i := range dtc.ConfigMapConfigs { + dtc.ConfigMapConfigs[i].Run() + } for i := range dtc.DaemonConfigs { dtc.DaemonConfigs[i].Run() } @@ -267,11 +270,13 @@ func cleanupDensityTest(dtc DensityTestConfig) { } } - // Delete all secrets + // Delete all secrets, configmaps and daemons. for i := range dtc.SecretConfigs { dtc.SecretConfigs[i].Stop() } - + for i := range dtc.ConfigMapConfigs { + dtc.ConfigMapConfigs[i].Stop() + } for i := range dtc.DaemonConfigs { framework.ExpectNoError(framework.DeleteResourceAndPods( dtc.ClientSet, @@ -395,9 +400,10 @@ var _ = framework.KubeDescribe("Density", func() { // Controls how often the apiserver is polled for pods interval time.Duration // What kind of resource we should be creating. Default: ReplicationController - kind schema.GroupKind - secretsPerPod int - daemonsPerNode int + kind schema.GroupKind + secretsPerPod int + configMapsPerPod int + daemonsPerNode int } densityTests := []Density{ @@ -414,24 +420,27 @@ var _ = framework.KubeDescribe("Density", func() { {podsPerNode: 30, runLatencyTest: true, kind: api.Kind("ReplicationController"), daemonsPerNode: 2}, // Test with secrets {podsPerNode: 30, runLatencyTest: true, kind: extensions.Kind("Deployment"), secretsPerPod: 2}, + // Test with configmaps + {podsPerNode: 30, runLatencyTest: true, kind: extensions.Kind("Deployment"), configMapsPerPod: 2}, } for _, testArg := range densityTests { feature := "ManualPerformance" switch testArg.podsPerNode { case 30: - if testArg.kind == api.Kind("ReplicationController") && testArg.daemonsPerNode == 0 && testArg.secretsPerPod == 0 { + if testArg.kind == api.Kind("ReplicationController") && testArg.daemonsPerNode == 0 && testArg.secretsPerPod == 0 && testArg.configMapsPerPod == 0 { feature = "Performance" } case 95: feature = "HighDensityPerformance" } - name := fmt.Sprintf("[Feature:%s] should allow starting %d pods per node using %v with %v secrets and %v daemons", + name := fmt.Sprintf("[Feature:%s] should allow starting %d pods per node using %v with %v secrets, %v configmaps and %v daemons", feature, testArg.podsPerNode, testArg.kind, testArg.secretsPerPod, + testArg.configMapsPerPod, testArg.daemonsPerNode, ) itArg := testArg @@ -459,6 +468,7 @@ var _ = framework.KubeDescribe("Density", func() { configs := make([]testutils.RunObjectConfig, numberOfCollections) secretConfigs := make([]*testutils.SecretConfig, 0, numberOfCollections*itArg.secretsPerPod) + configMapConfigs := make([]*testutils.ConfigMapConfig, 0, numberOfCollections*itArg.configMapsPerPod) // Since all RCs are created at the same time, timeout for each config // has to assume that it will be run at the very end. podThroughput := 20 @@ -479,6 +489,18 @@ var _ = framework.KubeDescribe("Density", func() { }) secretNames = append(secretNames, secretName) } + configMapNames := []string{} + for j := 0; j < itArg.configMapsPerPod; j++ { + configMapName := fmt.Sprintf("density-configmap-%v-%v", i, j) + configMapConfigs = append(configMapConfigs, &testutils.ConfigMapConfig{ + Content: map[string]string{"foo": "bar"}, + Client: clients[i], + Name: configMapName, + Namespace: nsName, + LogFunc: framework.Logf, + }) + configMapNames = append(configMapNames, configMapName) + } name := fmt.Sprintf("density%v-%v-%v", totalPods, i, uuid) baseConfig := &testutils.RCConfig{ Client: clients[i], @@ -497,6 +519,7 @@ var _ = framework.KubeDescribe("Density", func() { Silent: true, LogFunc: framework.Logf, SecretNames: secretNames, + ConfigMapNames: configMapNames, } switch itArg.kind { case api.Kind("ReplicationController"): @@ -520,6 +543,7 @@ var _ = framework.KubeDescribe("Density", func() { PollInterval: DensityPollInterval, kind: itArg.kind, SecretConfigs: secretConfigs, + ConfigMapConfigs: configMapConfigs, } for i := 0; i < itArg.daemonsPerNode; i++ { diff --git a/test/e2e/perf/load.go b/test/e2e/perf/load.go index 6f95c864c9ed6..2fc4af6c5fbfe 100644 --- a/test/e2e/perf/load.go +++ b/test/e2e/perf/load.go @@ -59,6 +59,8 @@ const ( // nodeCountPerNamespace determines how many namespaces we will be using // depending on the number of nodes in the underlying cluster. nodeCountPerNamespace = 100 + // How many threads will be used to create/delete services during this test. + serviceOperationsParallelism = 5 ) var randomKind = schema.GroupKind{Kind: "Random"} @@ -81,6 +83,7 @@ var _ = framework.KubeDescribe("Load capacity", func() { var ns string var configs []testutils.RunObjectConfig var secretConfigs []*testutils.SecretConfig + var configMapConfigs []*testutils.ConfigMapConfig testCaseBaseName := "load" @@ -139,10 +142,11 @@ var _ = framework.KubeDescribe("Load capacity", func() { image string command []string // What kind of resource we want to create - kind schema.GroupKind - services bool - secretsPerPod int - daemonsPerNode int + kind schema.GroupKind + services bool + secretsPerPod int + configMapsPerPod int + daemonsPerNode int } loadTests := []Load{ @@ -156,20 +160,23 @@ var _ = framework.KubeDescribe("Load capacity", func() { {podsPerNode: 30, image: framework.ServeHostnameImage, kind: api.Kind("ReplicationController"), daemonsPerNode: 2}, // Test with secrets {podsPerNode: 30, image: framework.ServeHostnameImage, kind: extensions.Kind("Deployment"), secretsPerPod: 2}, + // Test with configmaps + {podsPerNode: 30, image: framework.ServeHostnameImage, kind: extensions.Kind("Deployment"), configMapsPerPod: 2}, // Special test case which randomizes created resources {podsPerNode: 30, image: framework.ServeHostnameImage, kind: randomKind}, } for _, testArg := range loadTests { feature := "ManualPerformance" - if testArg.podsPerNode == 30 && testArg.kind == api.Kind("ReplicationController") && testArg.daemonsPerNode == 0 && testArg.secretsPerPod == 0 { + if testArg.podsPerNode == 30 && testArg.kind == api.Kind("ReplicationController") && testArg.daemonsPerNode == 0 && testArg.secretsPerPod == 0 && testArg.configMapsPerPod == 0 { feature = "Performance" } - name := fmt.Sprintf("[Feature:%s] should be able to handle %v pods per node %v with %v secrets and %v daemons", + name := fmt.Sprintf("[Feature:%s] should be able to handle %v pods per node %v with %v secrets, %v configmaps and %v daemons", feature, testArg.podsPerNode, testArg.kind, testArg.secretsPerPod, + testArg.configMapsPerPod, testArg.daemonsPerNode, ) itArg := testArg @@ -182,33 +189,41 @@ var _ = framework.KubeDescribe("Load capacity", func() { framework.ExpectNoError(err) totalPods := (itArg.podsPerNode - itArg.daemonsPerNode) * nodeCount - configs, secretConfigs = generateConfigs(totalPods, itArg.image, itArg.command, namespaces, itArg.kind, itArg.secretsPerPod) + configs, secretConfigs, configMapConfigs = generateConfigs(totalPods, itArg.image, itArg.command, namespaces, itArg.kind, itArg.secretsPerPod, itArg.configMapsPerPod) + if itArg.services { framework.Logf("Creating services") services := generateServicesForConfigs(configs) createService := func(i int) { + defer GinkgoRecover() _, err := clientset.Core().Services(services[i].Namespace).Create(services[i]) framework.ExpectNoError(err) } - workqueue.Parallelize(25, len(services), createService) + workqueue.Parallelize(serviceOperationsParallelism, len(services), createService) framework.Logf("%v Services created.", len(services)) defer func(services []*v1.Service) { framework.Logf("Starting to delete services...") deleteService := func(i int) { + defer GinkgoRecover() err := clientset.Core().Services(services[i].Namespace).Delete(services[i].Name, nil) framework.ExpectNoError(err) } - workqueue.Parallelize(25, len(services), deleteService) + workqueue.Parallelize(serviceOperationsParallelism, len(services), deleteService) framework.Logf("Services deleted") }(services) } else { framework.Logf("Skipping service creation") } - // Create all secrets + // Create all secrets. for i := range secretConfigs { secretConfigs[i].Run() defer secretConfigs[i].Stop() } + // Create all configmaps. + for i := range configMapConfigs { + configMapConfigs[i].Run() + defer configMapConfigs[i].Stop() + } // StartDeamon if needed for i := 0; i < itArg.daemonsPerNode; i++ { daemonName := fmt.Sprintf("load-daemon-%v", i) @@ -346,20 +361,25 @@ func generateConfigs( nss []*v1.Namespace, kind schema.GroupKind, secretsPerPod int, -) ([]testutils.RunObjectConfig, []*testutils.SecretConfig) { + configMapsPerPod int, +) ([]testutils.RunObjectConfig, []*testutils.SecretConfig, []*testutils.ConfigMapConfig) { configs := make([]testutils.RunObjectConfig, 0) secretConfigs := make([]*testutils.SecretConfig, 0) + configMapConfigs := make([]*testutils.ConfigMapConfig, 0) smallGroupCount, mediumGroupCount, bigGroupCount := computePodCounts(totalPods) - newConfigs, newSecretConfigs := GenerateConfigsForGroup(nss, smallGroupName, smallGroupSize, smallGroupCount, image, command, kind, secretsPerPod) + newConfigs, newSecretConfigs, newConfigMapConfigs := GenerateConfigsForGroup(nss, smallGroupName, smallGroupSize, smallGroupCount, image, command, kind, secretsPerPod, configMapsPerPod) configs = append(configs, newConfigs...) secretConfigs = append(secretConfigs, newSecretConfigs...) - newConfigs, newSecretConfigs = GenerateConfigsForGroup(nss, mediumGroupName, mediumGroupSize, mediumGroupCount, image, command, kind, secretsPerPod) + configMapConfigs = append(configMapConfigs, newConfigMapConfigs...) + newConfigs, newSecretConfigs, newConfigMapConfigs = GenerateConfigsForGroup(nss, mediumGroupName, mediumGroupSize, mediumGroupCount, image, command, kind, secretsPerPod, configMapsPerPod) configs = append(configs, newConfigs...) secretConfigs = append(secretConfigs, newSecretConfigs...) - newConfigs, newSecretConfigs = GenerateConfigsForGroup(nss, bigGroupName, bigGroupSize, bigGroupCount, image, command, kind, secretsPerPod) + configMapConfigs = append(configMapConfigs, newConfigMapConfigs...) + newConfigs, newSecretConfigs, newConfigMapConfigs = GenerateConfigsForGroup(nss, bigGroupName, bigGroupSize, bigGroupCount, image, command, kind, secretsPerPod, configMapsPerPod) configs = append(configs, newConfigs...) secretConfigs = append(secretConfigs, newSecretConfigs...) + configMapConfigs = append(configMapConfigs, newConfigMapConfigs...) // Create a number of clients to better simulate real usecase // where not everyone is using exactly the same client. @@ -374,8 +394,11 @@ func generateConfigs( for i := 0; i < len(secretConfigs); i++ { secretConfigs[i].Client = clients[i%len(clients)] } + for i := 0; i < len(configMapConfigs); i++ { + configMapConfigs[i].Client = clients[i%len(clients)] + } - return configs, secretConfigs + return configs, secretConfigs, configMapConfigs } func GenerateConfigsForGroup( @@ -386,14 +409,17 @@ func GenerateConfigsForGroup( command []string, kind schema.GroupKind, secretsPerPod int, -) ([]testutils.RunObjectConfig, []*testutils.SecretConfig) { + configMapsPerPod int, +) ([]testutils.RunObjectConfig, []*testutils.SecretConfig, []*testutils.ConfigMapConfig) { configs := make([]testutils.RunObjectConfig, 0, count) secretConfigs := make([]*testutils.SecretConfig, 0, count*secretsPerPod) + configMapConfigs := make([]*testutils.ConfigMapConfig, 0, count*configMapsPerPod) savedKind := kind for i := 1; i <= count; i++ { kind = savedKind namespace := nss[i%len(nss)].Name secretNames := make([]string, 0, secretsPerPod) + configMapNames := make([]string, 0, configMapsPerPod) for j := 0; j < secretsPerPod; j++ { secretName := fmt.Sprintf("%v-%v-secret-%v", groupName, i, j) @@ -407,6 +433,18 @@ func GenerateConfigsForGroup( secretNames = append(secretNames, secretName) } + for j := 0; j < configMapsPerPod; j++ { + configMapName := fmt.Sprintf("%v-%v-configmap-%v", groupName, i, j) + configMapConfigs = append(configMapConfigs, &testutils.ConfigMapConfig{ + Content: map[string]string{"foo": "bar"}, + Client: nil, // this will be overwritten later + Name: configMapName, + Namespace: namespace, + LogFunc: framework.Logf, + }) + configMapNames = append(configMapNames, configMapName) + } + baseConfig := &testutils.RCConfig{ Client: nil, // this will be overwritten later InternalClient: nil, // this will be overwritten later @@ -419,6 +457,7 @@ func GenerateConfigsForGroup( CpuRequest: 10, // 0.01 core MemRequest: 26214400, // 25MB SecretNames: secretNames, + ConfigMapNames: configMapNames, } if kind == randomKind { @@ -440,7 +479,7 @@ func GenerateConfigsForGroup( } configs = append(configs, config) } - return configs, secretConfigs + return configs, secretConfigs, configMapConfigs } func generateServicesForConfigs(configs []testutils.RunObjectConfig) []*v1.Service { diff --git a/test/e2e/scheduling/OWNERS b/test/e2e/scheduling/OWNERS index d2792efd526b5..731daf5f7e0db 100644 --- a/test/e2e/scheduling/OWNERS +++ b/test/e2e/scheduling/OWNERS @@ -1,4 +1,5 @@ approvers: - sig-scheduling-maintainers +- k82cn reviewers: - sig-scheduling diff --git a/test/e2e/service.go b/test/e2e/service.go index 2724ddad6a506..03282748bcbd5 100644 --- a/test/e2e/service.go +++ b/test/e2e/service.go @@ -1287,12 +1287,9 @@ var _ = framework.KubeDescribe("ESIPP [Slow]", func() { jig.ChangeServiceType(svc.Namespace, svc.Name, v1.ServiceTypeClusterIP, loadBalancerCreateTimeout) // Make sure we didn't leak the health check node port. - for name, ips := range jig.GetEndpointNodes(svc) { - _, fail, status := jig.TestHTTPHealthCheckNodePort(ips[0], healthCheckNodePort, "/healthz", 5) - if fail < 2 { - framework.Failf("Health check node port %v not released on node %v: %v", healthCheckNodePort, name, status) - } - break + threshold := 2 + for _, ips := range jig.GetEndpointNodes(svc) { + Expect(jig.TestHTTPHealthCheckNodePort(ips[0], healthCheckNodePort, "/healthz", framework.KubeProxyEndpointLagTimeout, false, threshold)).NotTo(HaveOccurred()) } Expect(cs.Core().Services(svc.Namespace).Delete(svc.Name, nil)).NotTo(HaveOccurred()) }() @@ -1379,16 +1376,12 @@ var _ = framework.KubeDescribe("ESIPP [Slow]", func() { // HealthCheck should pass only on the node where num(endpoints) > 0 // All other nodes should fail the healthcheck on the service healthCheckNodePort for n, publicIP := range ips { + // Make sure the loadbalancer picked up the health check change. + // Confirm traffic can reach backend through LB before checking healthcheck nodeport. + jig.TestReachableHTTP(ingressIP, svcTCPPort, framework.KubeProxyLagTimeout) expectedSuccess := nodes.Items[n].Name == endpointNodeName framework.Logf("Health checking %s, http://%s:%d%s, expectedSuccess %v", nodes.Items[n].Name, publicIP, healthCheckNodePort, path, expectedSuccess) - pass, fail, err := jig.TestHTTPHealthCheckNodePort(publicIP, healthCheckNodePort, path, 5) - if expectedSuccess && pass < threshold { - framework.Failf("Expected %d successes on %v%v, got %d, err %v", threshold, endpointNodeName, path, pass, err) - } else if !expectedSuccess && fail < threshold { - framework.Failf("Expected %d failures on %v%v, got %d, err %v", threshold, endpointNodeName, path, fail, err) - } - // Make sure the loadbalancer picked up the helth check change - jig.TestReachableHTTP(ingressIP, svcTCPPort, framework.KubeProxyLagTimeout) + Expect(jig.TestHTTPHealthCheckNodePort(publicIP, healthCheckNodePort, path, framework.KubeProxyEndpointLagTimeout, expectedSuccess, threshold)).NotTo(HaveOccurred()) } framework.ExpectNoError(framework.DeleteRCAndPods(f.ClientSet, f.InternalClientset, namespace, serviceName)) } diff --git a/test/e2e/storage/BUILD b/test/e2e/storage/BUILD index eb3fdd0eb7c5c..44bad63721d15 100644 --- a/test/e2e/storage/BUILD +++ b/test/e2e/storage/BUILD @@ -14,6 +14,7 @@ go_library( "persistent_volumes.go", "persistent_volumes-disruptive.go", "persistent_volumes-gce.go", + "persistent_volumes-local.go", "persistent_volumes-vsphere.go", "pv_reclaimpolicy.go", "pvc_label_selector.go", diff --git a/test/e2e/storage/pd.go b/test/e2e/storage/pd.go index 730ff45c5ed5d..d844b6038c057 100644 --- a/test/e2e/storage/pd.go +++ b/test/e2e/storage/pd.go @@ -43,7 +43,7 @@ import ( const ( gcePDDetachTimeout = 10 * time.Minute gcePDDetachPollTime = 10 * time.Second - nodeStatusTimeout = 1 * time.Minute + nodeStatusTimeout = 3 * time.Minute nodeStatusPollTime = 1 * time.Second maxReadRetry = 3 ) @@ -428,6 +428,8 @@ var _ = framework.KubeDescribe("Pod Disks", func() { By("Cleaning up PD-RW test env") podClient.Delete(host0Pod.Name, metav1.NewDeleteOptions(0)) detachAndDeletePDs(diskName, []types.NodeName{host0Name}) + framework.WaitForNodeToBeReady(f.ClientSet, string(host0Name), nodeStatusTimeout) + Expect(len(nodes.Items)).To(Equal(initialGroupSize)) }() By("submitting host0Pod to kubernetes") diff --git a/test/e2e/storage/persistent_volumes-disruptive.go b/test/e2e/storage/persistent_volumes-disruptive.go index 8eb10f592291c..027c73b26943e 100644 --- a/test/e2e/storage/persistent_volumes-disruptive.go +++ b/test/e2e/storage/persistent_volumes-disruptive.go @@ -180,7 +180,7 @@ func testVolumeUnmountsFromDeletedPod(c clientset.Interface, f *framework.Framew result, err := framework.SSH(fmt.Sprintf("mount | grep %s", clientPod.UID), nodeIP, framework.TestContext.Provider) framework.LogSSHResult(result) Expect(err).NotTo(HaveOccurred(), "Encountered SSH error.") - Expect(result.Code).To(BeZero(), fmt.Sprintf("Expected grep exit code of 0, got %s", result.Code)) + Expect(result.Code).To(BeZero(), fmt.Sprintf("Expected grep exit code of 0, got %d", result.Code)) By("Stopping the kubelet.") kubeletCommand(kStop, c, clientPod) diff --git a/test/e2e/storage/persistent_volumes-local.go b/test/e2e/storage/persistent_volumes-local.go new file mode 100644 index 0000000000000..0097d96b701cd --- /dev/null +++ b/test/e2e/storage/persistent_volumes-local.go @@ -0,0 +1,245 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package storage + +import ( + "fmt" + "path/filepath" + + . "github.com/onsi/ginkgo" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + utilerrors "k8s.io/apimachinery/pkg/util/errors" + "k8s.io/apimachinery/pkg/util/uuid" + "k8s.io/kubernetes/pkg/api/v1" + "k8s.io/kubernetes/pkg/client/clientset_generated/clientset" + "k8s.io/kubernetes/test/e2e/framework" +) + +type localTestConfig struct { + ns string + nodes []v1.Node + client clientset.Interface +} + +type localTestVolume struct { + // Node that the volume is on + node *v1.Node + // Path to the volume on the host node + hostDir string + // Path to the volume in the local util container + containerDir string + // PVC for this volume + pvc *v1.PersistentVolumeClaim + // PV for this volume + pv *v1.PersistentVolume +} + +const ( + // TODO: This may not be available/writable on all images. + hostBase = "/tmp" + containerBase = "/myvol" + testFile = "test-file" + testContents = "testdata" + testSC = "local-test-storagclass" +) + +var _ = framework.KubeDescribe("[Volume] PersistentVolumes-local [Feature:LocalPersistentVolumes] [Serial]", func() { + f := framework.NewDefaultFramework("persistent-local-volumes-test") + + var ( + config *localTestConfig + ) + + BeforeEach(func() { + config = &localTestConfig{ + ns: f.Namespace.Name, + client: f.ClientSet, + nodes: []v1.Node{}, + } + + // Get all the schedulable nodes + nodes, err := config.client.CoreV1().Nodes().List(metav1.ListOptions{}) + if err != nil { + framework.Failf("Failed to get nodes: %v", err) + } + + for _, node := range nodes.Items { + if !node.Spec.Unschedulable { + // TODO: does this need to be a deep copy + config.nodes = append(config.nodes, node) + } + } + if len(config.nodes) == 0 { + framework.Failf("No available nodes for scheduling") + } + }) + + Context("when one pod requests one prebound PVC", func() { + var ( + testVol *localTestVolume + node *v1.Node + ) + + BeforeEach(func() { + // Choose the first node + node = &config.nodes[0] + }) + + AfterEach(func() { + cleanupLocalVolume(config, testVol) + testVol = nil + }) + + It("should be able to mount and read from the volume", func() { + By("Initializing test volume") + testVol = setupLocalVolume(config, node) + + By("Creating local PVC and PV") + createLocalPVCPV(config, testVol) + + By("Creating a pod to consume the PV") + readCmd := fmt.Sprintf("cat /mnt/volume1/%s", testFile) + podSpec := createLocalPod(config, testVol, readCmd) + f.TestContainerOutput("pod consumes PV", podSpec, 0, []string{testContents}) + }) + + It("should be able to mount and write to the volume", func() { + By("Initializing test volume") + testVol = setupLocalVolume(config, node) + + By("Creating local PVC and PV") + createLocalPVCPV(config, testVol) + + By("Creating a pod to write to the PV") + testFilePath := filepath.Join("/mnt/volume1", testFile) + cmd := fmt.Sprintf("echo %s > %s; cat %s", testVol.hostDir, testFilePath, testFilePath) + podSpec := createLocalPod(config, testVol, cmd) + f.TestContainerOutput("pod writes to PV", podSpec, 0, []string{testVol.hostDir}) + }) + }) +}) + +// Launches a pod with hostpath volume on a specific node to setup a directory to use +// for the local PV +func setupLocalVolume(config *localTestConfig, node *v1.Node) *localTestVolume { + testDirName := "local-volume-test-" + string(uuid.NewUUID()) + testDir := filepath.Join(containerBase, testDirName) + hostDir := filepath.Join(hostBase, testDirName) + testFilePath := filepath.Join(testDir, testFile) + writeCmd := fmt.Sprintf("mkdir %s; echo %s > %s", testDir, testContents, testFilePath) + framework.Logf("Creating local volume on node %q at path %q", node.Name, hostDir) + + runLocalUtil(config, node.Name, writeCmd) + return &localTestVolume{ + node: node, + hostDir: hostDir, + containerDir: testDir, + } +} + +// Deletes the PVC/PV, and launches a pod with hostpath volume to remove the test directory +func cleanupLocalVolume(config *localTestConfig, volume *localTestVolume) { + if volume == nil { + return + } + + By("Cleaning up PVC and PV") + errs := framework.PVPVCCleanup(config.client, config.ns, volume.pv, volume.pvc) + if len(errs) > 0 { + framework.Logf("AfterEach: Failed to delete PV and/or PVC: %v", utilerrors.NewAggregate(errs)) + } + + By("Removing the test directory") + removeCmd := fmt.Sprintf("rm -r %s", volume.containerDir) + runLocalUtil(config, volume.node.Name, removeCmd) +} + +func runLocalUtil(config *localTestConfig, nodeName, cmd string) { + framework.StartVolumeServer(config.client, framework.VolumeTestConfig{ + Namespace: config.ns, + Prefix: "local-volume-init", + ServerImage: "gcr.io/google_containers/busybox:1.24", + ServerCmds: []string{"/bin/sh"}, + ServerArgs: []string{"-c", cmd}, + ServerVolumes: map[string]string{ + hostBase: containerBase, + }, + WaitForCompletion: true, + NodeName: nodeName, + }) +} + +func makeLocalPVCConfig() framework.PersistentVolumeClaimConfig { + sc := testSC + return framework.PersistentVolumeClaimConfig{ + AccessModes: []v1.PersistentVolumeAccessMode{v1.ReadWriteOnce}, + StorageClassName: &sc, + } +} + +func makeLocalPVConfig(volume *localTestVolume) framework.PersistentVolumeConfig { + // TODO: hostname may not be the best option + nodeKey := "kubernetes.io/hostname" + if volume.node.Labels == nil { + framework.Failf("Node does not have labels") + } + nodeValue, found := volume.node.Labels[nodeKey] + if !found { + framework.Failf("Node does not have required label %q", nodeKey) + } + + return framework.PersistentVolumeConfig{ + PVSource: v1.PersistentVolumeSource{ + Local: &v1.LocalVolumeSource{ + Path: volume.hostDir, + }, + }, + NamePrefix: "local-pv", + StorageClassName: testSC, + NodeAffinity: &v1.NodeAffinity{ + RequiredDuringSchedulingIgnoredDuringExecution: &v1.NodeSelector{ + NodeSelectorTerms: []v1.NodeSelectorTerm{ + { + MatchExpressions: []v1.NodeSelectorRequirement{ + { + Key: nodeKey, + Operator: v1.NodeSelectorOpIn, + Values: []string{nodeValue}, + }, + }, + }, + }, + }, + }, + } +} + +// Creates a PVC and PV with prebinding +func createLocalPVCPV(config *localTestConfig, volume *localTestVolume) { + pvcConfig := makeLocalPVCConfig() + pvConfig := makeLocalPVConfig(volume) + + var err error + volume.pv, volume.pvc, err = framework.CreatePVPVC(config.client, pvConfig, pvcConfig, config.ns, true) + framework.ExpectNoError(err) + framework.WaitOnPVandPVC(config.client, config.ns, volume.pv, volume.pvc) +} + +func createLocalPod(config *localTestConfig, volume *localTestVolume, cmd string) *v1.Pod { + return framework.MakePod(config.ns, []*v1.PersistentVolumeClaim{volume.pvc}, false, cmd) +} diff --git a/test/e2e/storage/vsphere_volume_vsan_policy.go b/test/e2e/storage/vsphere_volume_vsan_policy.go index 042191d6531d0..cd1fc868c9a40 100644 --- a/test/e2e/storage/vsphere_volume_vsan_policy.go +++ b/test/e2e/storage/vsphere_volume_vsan_policy.go @@ -18,6 +18,7 @@ package storage import ( "fmt" + "os" "time" "strings" @@ -41,6 +42,10 @@ const ( Policy_CacheReservation = "cacheReservation" Policy_ObjectSpaceReservation = "objectSpaceReservation" Policy_IopsLimit = "iopsLimit" + DiskFormat = "diskformat" + ThinDisk = "thin" + SpbmStoragePolicy = "storagepolicyname" + BronzeStoragePolicy = "bronze" HostFailuresToTolerateCapabilityVal = "0" CacheReservationCapabilityVal = "20" DiskStripesCapabilityVal = "1" @@ -52,7 +57,11 @@ const ( ) /* - Test to verify if VSAN storage capabilities specified in storage-class is being honored while volume creation. + Test to verify the storage policy based management for dynamic volume provisioning inside kubernetes. + There are 2 ways to achive it: + 1. Specify VSAN storage capabilities in the storage-class. + 2. Use existing vCenter SPBM storage policies. + Valid VSAN storage capabilities are mentioned below: 1. hostFailuresToTolerate 2. forceProvisioning @@ -62,7 +71,9 @@ const ( 6. iopsLimit Steps - 1. Create StorageClass with VSAN storage capabilities set to valid values. + 1. Create StorageClass with. + a. VSAN storage capabilities set to valid/invalid values (or) + b. Use existing vCenter SPBM storage policies. 2. Create PVC which uses the StorageClass created in step 1. 3. Wait for PV to be provisioned. 4. Wait for PVC's status to become Bound @@ -72,7 +83,7 @@ const ( 8. Delete PVC, PV and Storage Class */ -var _ = framework.KubeDescribe("VSAN policy support for dynamic provisioning [Volume]", func() { +var _ = framework.KubeDescribe("vSphere Storage policy support for dynamic provisioning [Volume]", func() { f := framework.NewDefaultFramework("volume-vsan-policy") var ( client clientset.Interface @@ -96,7 +107,7 @@ var _ = framework.KubeDescribe("VSAN policy support for dynamic provisioning [Vo scParameters[Policy_HostFailuresToTolerate] = HostFailuresToTolerateCapabilityVal scParameters[Policy_CacheReservation] = CacheReservationCapabilityVal framework.Logf("Invoking Test for VSAN storage capabilities: %+v", scParameters) - invokeValidVSANPolicyTest(f, client, namespace, scParameters) + invokeValidPolicyTest(f, client, namespace, scParameters) }) // Valid policy. @@ -105,7 +116,7 @@ var _ = framework.KubeDescribe("VSAN policy support for dynamic provisioning [Vo scParameters[Policy_DiskStripes] = "1" scParameters[Policy_ObjectSpaceReservation] = "30" framework.Logf("Invoking Test for VSAN storage capabilities: %+v", scParameters) - invokeValidVSANPolicyTest(f, client, namespace, scParameters) + invokeValidPolicyTest(f, client, namespace, scParameters) }) // Valid policy. @@ -115,7 +126,7 @@ var _ = framework.KubeDescribe("VSAN policy support for dynamic provisioning [Vo scParameters[Policy_ObjectSpaceReservation] = ObjectSpaceReservationCapabilityVal scParameters[Datastore] = VsanDatastore framework.Logf("Invoking Test for VSAN storage capabilities: %+v", scParameters) - invokeValidVSANPolicyTest(f, client, namespace, scParameters) + invokeValidPolicyTest(f, client, namespace, scParameters) }) // Valid policy. @@ -124,7 +135,7 @@ var _ = framework.KubeDescribe("VSAN policy support for dynamic provisioning [Vo scParameters[Policy_ObjectSpaceReservation] = ObjectSpaceReservationCapabilityVal scParameters[Policy_IopsLimit] = IopsLimitCapabilityVal framework.Logf("Invoking Test for VSAN storage capabilities: %+v", scParameters) - invokeValidVSANPolicyTest(f, client, namespace, scParameters) + invokeValidPolicyTest(f, client, namespace, scParameters) }) // Invalid VSAN storage capabilties parameters. @@ -133,12 +144,11 @@ var _ = framework.KubeDescribe("VSAN policy support for dynamic provisioning [Vo scParameters["objectSpaceReserve"] = ObjectSpaceReservationCapabilityVal scParameters[Policy_DiskStripes] = StripeWidthCapabilityVal framework.Logf("Invoking Test for VSAN storage capabilities: %+v", scParameters) - err := invokeInvalidVSANPolicyTestNeg(client, namespace, scParameters) - // This will make sure err is always returned. + err := invokeInvalidPolicyTestNeg(client, namespace, scParameters) Expect(err).To(HaveOccurred()) - errorMsg := "invalid option \\\"objectSpaceReserve\\\" for diskStripes in volume plugin kubernetes.io/vsphere-volume." + errorMsg := "invalid option \\\"objectSpaceReserve\\\" for volume plugin kubernetes.io/vsphere-volume" if !strings.Contains(err.Error(), errorMsg) { - Expect(err).NotTo(HaveOccurred()) + Expect(err).NotTo(HaveOccurred(), errorMsg) } }) @@ -149,12 +159,11 @@ var _ = framework.KubeDescribe("VSAN policy support for dynamic provisioning [Vo scParameters[Policy_DiskStripes] = DiskStripesCapabilityInvalidVal scParameters[Policy_CacheReservation] = CacheReservationCapabilityVal framework.Logf("Invoking Test for VSAN storage capabilities: %+v", scParameters) - err := invokeInvalidVSANPolicyTestNeg(client, namespace, scParameters) - // This will make sure err is always returned. + err := invokeInvalidPolicyTestNeg(client, namespace, scParameters) Expect(err).To(HaveOccurred()) - errorMsg := "Invalid value for " + Policy_DiskStripes + " in volume plugin kubernetes.io/vsphere-volume." + errorMsg := "Invalid value for " + Policy_DiskStripes + "." if !strings.Contains(err.Error(), errorMsg) { - Expect(err).NotTo(HaveOccurred()) + Expect(err).NotTo(HaveOccurred(), errorMsg) } }) @@ -164,12 +173,11 @@ var _ = framework.KubeDescribe("VSAN policy support for dynamic provisioning [Vo By(fmt.Sprintf("Invoking Test for VSAN policy hostFailuresToTolerate: %s", HostFailuresToTolerateCapabilityInvalidVal)) scParameters[Policy_HostFailuresToTolerate] = HostFailuresToTolerateCapabilityInvalidVal framework.Logf("Invoking Test for VSAN storage capabilities: %+v", scParameters) - err := invokeInvalidVSANPolicyTestNeg(client, namespace, scParameters) - // This will make sure err is always returned. + err := invokeInvalidPolicyTestNeg(client, namespace, scParameters) Expect(err).To(HaveOccurred()) - errorMsg := "Invalid value for " + Policy_HostFailuresToTolerate + " in volume plugin kubernetes.io/vsphere-volume." + errorMsg := "Invalid value for " + Policy_HostFailuresToTolerate + "." if !strings.Contains(err.Error(), errorMsg) { - Expect(err).NotTo(HaveOccurred()) + Expect(err).NotTo(HaveOccurred(), errorMsg) } }) @@ -181,21 +189,75 @@ var _ = framework.KubeDescribe("VSAN policy support for dynamic provisioning [Vo scParameters[Policy_ObjectSpaceReservation] = ObjectSpaceReservationCapabilityVal scParameters[Datastore] = VmfsDatastore framework.Logf("Invoking Test for VSAN storage capabilities: %+v", scParameters) - err := invokeInvalidVSANPolicyTestNeg(client, namespace, scParameters) - // This will make sure err is always returned. + err := invokeInvalidPolicyTestNeg(client, namespace, scParameters) Expect(err).To(HaveOccurred()) errorMsg := "The specified datastore: \\\"" + VmfsDatastore + "\\\" is not a VSAN datastore. " + "The policy parameters will work only with VSAN Datastore." - framework.Logf("errorMsg: %+q", errorMsg) if !strings.Contains(err.Error(), errorMsg) { - Expect(err).NotTo(HaveOccurred()) + Expect(err).NotTo(HaveOccurred(), errorMsg) + } + }) + + It("verify an existing and compatible SPBM policy is honored for dynamically provisioned pvc using storageclass", func() { + By(fmt.Sprintf("Invoking Test for SPBM policy: %s", os.Getenv("VSPHERE_SPBM_GOLD_POLICY"))) + goldPolicy := os.Getenv("VSPHERE_SPBM_GOLD_POLICY") + Expect(goldPolicy).NotTo(BeEmpty()) + scParameters[SpbmStoragePolicy] = goldPolicy + scParameters[DiskFormat] = ThinDisk + framework.Logf("Invoking Test for SPBM storage policy: %+v", scParameters) + invokeValidPolicyTest(f, client, namespace, scParameters) + }) + + It("verify if a SPBM policy is not honored on a non-compatible datastore for dynamically provisioned pvc using storageclass", func() { + By(fmt.Sprintf("Invoking Test for SPBM policy: %s and datastore: %s", os.Getenv("VSPHERE_SPBM_TAG_POLICY"), VsanDatastore)) + tagPolicy := os.Getenv("VSPHERE_SPBM_TAG_POLICY") + Expect(tagPolicy).NotTo(BeEmpty()) + scParameters[SpbmStoragePolicy] = tagPolicy + scParameters[Datastore] = VsanDatastore + scParameters[DiskFormat] = ThinDisk + framework.Logf("Invoking Test for SPBM storage policy on a non-compatible datastore: %+v", scParameters) + err := invokeInvalidPolicyTestNeg(client, namespace, scParameters) + Expect(err).To(HaveOccurred()) + errorMsg := "User specified datastore: \\\"" + VsanDatastore + "\\\" is not compatible with the storagePolicy: \\\"" + os.Getenv("VSPHERE_SPBM_TAG_POLICY") + "\\\"" + if !strings.Contains(err.Error(), errorMsg) { + Expect(err).NotTo(HaveOccurred(), errorMsg) + } + }) + + It("verify if a non-existing SPBM policy is not honored for dynamically provisioned pvc using storageclass", func() { + By(fmt.Sprintf("Invoking Test for SPBM policy: %s", BronzeStoragePolicy)) + scParameters[SpbmStoragePolicy] = BronzeStoragePolicy + scParameters[DiskFormat] = ThinDisk + framework.Logf("Invoking Test for non-existing SPBM storage policy: %+v", scParameters) + err := invokeInvalidPolicyTestNeg(client, namespace, scParameters) + Expect(err).To(HaveOccurred()) + errorMsg := "no pbm profile found with name: \\\"" + BronzeStoragePolicy + "\\" + if !strings.Contains(err.Error(), errorMsg) { + Expect(err).NotTo(HaveOccurred(), errorMsg) + } + }) + + It("verify an if a SPBM policy and VSAN capabilities cannot be honored for dynamically provisioned pvc using storageclass", func() { + By(fmt.Sprintf("Invoking Test for SPBM policy: %s with VSAN storage capabilities", os.Getenv("VSPHERE_SPBM_GOLD_POLICY"))) + goldPolicy := os.Getenv("VSPHERE_SPBM_GOLD_POLICY") + Expect(goldPolicy).NotTo(BeEmpty()) + scParameters[SpbmStoragePolicy] = goldPolicy + Expect(scParameters[SpbmStoragePolicy]).NotTo(BeEmpty()) + scParameters[Policy_DiskStripes] = DiskStripesCapabilityVal + scParameters[DiskFormat] = ThinDisk + framework.Logf("Invoking Test for SPBM storage policy and VSAN capabilities together: %+v", scParameters) + err := invokeInvalidPolicyTestNeg(client, namespace, scParameters) + Expect(err).To(HaveOccurred()) + errorMsg := "Cannot specify storage policy capabilities along with storage policy name. Please specify only one." + if !strings.Contains(err.Error(), errorMsg) { + Expect(err).NotTo(HaveOccurred(), errorMsg) } }) }) -func invokeValidVSANPolicyTest(f *framework.Framework, client clientset.Interface, namespace string, scParameters map[string]string) { - By("Creating Storage Class With VSAN policy params") - storageclass, err := client.StorageV1().StorageClasses().Create(getVSphereStorageClassSpec("vsanpolicysc", scParameters)) +func invokeValidPolicyTest(f *framework.Framework, client clientset.Interface, namespace string, scParameters map[string]string) { + By("Creating Storage Class With storage policy params") + storageclass, err := client.StorageV1().StorageClasses().Create(getVSphereStorageClassSpec("storagepolicysc", scParameters)) Expect(err).NotTo(HaveOccurred(), fmt.Sprintf("Failed to create storage class with err: %v", err)) defer client.StorageV1().StorageClasses().Delete(storageclass.Name, nil) @@ -204,7 +266,7 @@ func invokeValidVSANPolicyTest(f *framework.Framework, client clientset.Interfac Expect(err).NotTo(HaveOccurred()) defer framework.DeletePersistentVolumeClaim(client, pvclaim.Name, namespace) - pvclaims := make([]*v1.PersistentVolumeClaim, 1) + var pvclaims []*v1.PersistentVolumeClaim pvclaims = append(pvclaims, pvclaim) By("Waiting for claim to be in bound phase") persistentvolumes, err := framework.WaitForPVClaimBoundPhase(client, pvclaims) @@ -227,9 +289,9 @@ func invokeValidVSANPolicyTest(f *framework.Framework, client clientset.Interfac waitForVSphereDiskToDetach(vsp, persistentvolumes[0].Spec.VsphereVolume.VolumePath, k8stype.NodeName(pod.Spec.NodeName)) } -func invokeInvalidVSANPolicyTestNeg(client clientset.Interface, namespace string, scParameters map[string]string) error { - By("Creating Storage Class With VSAN policy params") - storageclass, err := client.StorageV1().StorageClasses().Create(getVSphereStorageClassSpec("vsanpolicysc", scParameters)) +func invokeInvalidPolicyTestNeg(client clientset.Interface, namespace string, scParameters map[string]string) error { + By("Creating Storage Class With storage policy params") + storageclass, err := client.StorageV1().StorageClasses().Create(getVSphereStorageClassSpec("storagepolicysc", scParameters)) Expect(err).NotTo(HaveOccurred(), fmt.Sprintf("Failed to create storage class with err: %v", err)) defer client.StorageV1().StorageClasses().Delete(storageclass.Name, nil) diff --git a/test/e2e_node/garbage_collector_test.go b/test/e2e_node/garbage_collector_test.go index 1f5aecd38d748..5bce0a2d3aefd 100644 --- a/test/e2e_node/garbage_collector_test.go +++ b/test/e2e_node/garbage_collector_test.go @@ -18,6 +18,7 @@ package e2e_node import ( "fmt" + "strconv" "strings" "time" @@ -150,20 +151,10 @@ func containerGCTest(f *framework.Framework, test testRun) { By("Making sure all containers restart the specified number of times") Eventually(func() error { for _, podSpec := range test.testPods { - updatedPod, err := f.ClientSet.Core().Pods(f.Namespace.Name).Get(podSpec.podName, metav1.GetOptions{}) + err := verifyPodRestartCount(f, podSpec.podName, podSpec.numContainers, podSpec.restartCount) if err != nil { return err } - if len(updatedPod.Status.ContainerStatuses) != podSpec.numContainers { - return fmt.Errorf("expected pod %s to have %d containers, actual: %d", - updatedPod.Name, podSpec.numContainers, len(updatedPod.Status.ContainerStatuses)) - } - for _, containerStatus := range updatedPod.Status.ContainerStatuses { - if containerStatus.RestartCount != podSpec.restartCount { - return fmt.Errorf("pod %s had container with restartcount %d. Should have been at least %d", - updatedPod.Name, containerStatus.RestartCount, podSpec.restartCount) - } - } } return nil }, setupDuration, runtimePollInterval).Should(BeNil()) @@ -289,20 +280,9 @@ func getPods(specs []*testPodSpec) (pods []*v1.Pod) { containers := []v1.Container{} for i := 0; i < spec.numContainers; i++ { containers = append(containers, v1.Container{ - Image: "gcr.io/google_containers/busybox:1.24", - Name: spec.getContainerName(i), - Command: []string{ - "sh", - "-c", - fmt.Sprintf(` - f=/test-empty-dir-mnt/countfile%d - count=$(echo 'hello' >> $f ; wc -l $f | awk {'print $1'}) - if [ $count -lt %d ]; then - exit 0 - fi - while true; do sleep 1; done - `, i, spec.restartCount+1), - }, + Image: "gcr.io/google_containers/busybox:1.24", + Name: spec.getContainerName(i), + Command: getRestartingContainerCommand("/test-empty-dir-mnt", i, spec.restartCount, ""), VolumeMounts: []v1.VolumeMount{ {MountPath: "/test-empty-dir-mnt", Name: "test-empty-dir"}, }, @@ -321,3 +301,36 @@ func getPods(specs []*testPodSpec) (pods []*v1.Pod) { } return } + +func getRestartingContainerCommand(path string, containerNum int, restarts int32, loopingCommand string) []string { + return []string{ + "sh", + "-c", + fmt.Sprintf(` + f=%s/countfile%s + count=$(echo 'hello' >> $f ; wc -l $f | awk {'print $1'}) + if [ $count -lt %d ]; then + exit 0 + fi + while true; do %s sleep 10; done`, + path, strconv.Itoa(containerNum), restarts+1, loopingCommand), + } +} + +func verifyPodRestartCount(f *framework.Framework, podName string, expectedNumContainers int, expectedRestartCount int32) error { + updatedPod, err := f.ClientSet.Core().Pods(f.Namespace.Name).Get(podName, metav1.GetOptions{}) + if err != nil { + return err + } + if len(updatedPod.Status.ContainerStatuses) != expectedNumContainers { + return fmt.Errorf("expected pod %s to have %d containers, actual: %d", + updatedPod.Name, expectedNumContainers, len(updatedPod.Status.ContainerStatuses)) + } + for _, containerStatus := range updatedPod.Status.ContainerStatuses { + if containerStatus.RestartCount != expectedRestartCount { + return fmt.Errorf("pod %s had container with restartcount %d. Should have been at least %d", + updatedPod.Name, containerStatus.RestartCount, expectedRestartCount) + } + } + return nil +} diff --git a/test/e2e_node/summary_test.go b/test/e2e_node/summary_test.go index 227512efc4969..e5b40ae8cdb11 100644 --- a/test/e2e_node/summary_test.go +++ b/test/e2e_node/summary_test.go @@ -53,7 +53,20 @@ var _ = framework.KubeDescribe("Summary API", func() { const pod1 = "stats-busybox-1" By("Creating test pods") - createSummaryTestPods(f, pod0, pod1) + numRestarts := int32(1) + pods := getSummaryTestPods(f, numRestarts, pod0, pod1) + f.PodClient().CreateBatch(pods) + + Eventually(func() error { + for _, pod := range pods { + err := verifyPodRestartCount(f, pod.Name, len(pod.Spec.Containers), numRestarts) + if err != nil { + return err + } + } + return nil + }, time.Minute, 5*time.Second).Should(BeNil()) + // Wait for cAdvisor to collect 2 stats points time.Sleep(15 * time.Second) @@ -131,16 +144,16 @@ var _ = framework.KubeDescribe("Summary API", func() { "StartTime": recent(maxStartAge), "CPU": ptrMatchAllFields(gstruct.Fields{ "Time": recent(maxStatsAge), - "UsageNanoCores": bounded(100000, 100000000), - "UsageCoreNanoSeconds": bounded(10000000, 1000000000), + "UsageNanoCores": bounded(100000, 1E9), + "UsageCoreNanoSeconds": bounded(10000000, 1E11), }), "Memory": ptrMatchAllFields(gstruct.Fields{ "Time": recent(maxStatsAge), - "AvailableBytes": bounded(1*mb, 10*mb), - "UsageBytes": bounded(10*kb, 5*mb), - "WorkingSetBytes": bounded(10*kb, 2*mb), + "AvailableBytes": bounded(10*kb, 10*mb), + "UsageBytes": bounded(10*kb, 20*mb), + "WorkingSetBytes": bounded(10*kb, 20*mb), "RSSBytes": bounded(1*kb, mb), - "PageFaults": bounded(100, 100000), + "PageFaults": bounded(100, 1000000), "MajorPageFaults": bounded(0, 10), }), "Rootfs": ptrMatchAllFields(gstruct.Fields{ @@ -259,7 +272,7 @@ var _ = framework.KubeDescribe("Summary API", func() { }) }) -func createSummaryTestPods(f *framework.Framework, names ...string) { +func getSummaryTestPods(f *framework.Framework, numRestarts int32, names ...string) []*v1.Pod { pods := make([]*v1.Pod, 0, len(names)) for _, name := range names { pods = append(pods, &v1.Pod{ @@ -272,7 +285,7 @@ func createSummaryTestPods(f *framework.Framework, names ...string) { { Name: "busybox-container", Image: "gcr.io/google_containers/busybox:1.24", - Command: []string{"sh", "-c", "ping -c 1 google.com; while true; do echo 'hello world' >> /test-empty-dir-mnt/file ; sleep 1; done"}, + Command: getRestartingContainerCommand("/test-empty-dir-mnt", 0, numRestarts, "ping -c 1 google.com; echo 'hello world' >> /test-empty-dir-mnt/file"), Resources: v1.ResourceRequirements{ Limits: v1.ResourceList{ // Must set memory limit to get MemoryStats.AvailableBytes @@ -297,7 +310,7 @@ func createSummaryTestPods(f *framework.Framework, names ...string) { }, }) } - f.PodClient().CreateBatch(pods) + return pods } // Mapping function for gstruct.MatchAllElements diff --git a/test/images/BUILD b/test/images/BUILD index 21c337a594b65..4424ecf83c1ab 100644 --- a/test/images/BUILD +++ b/test/images/BUILD @@ -28,6 +28,8 @@ filegroup( "//test/images/net:all-srcs", "//test/images/netexec:all-srcs", "//test/images/network-tester:all-srcs", + "//test/images/no-snat-test:all-srcs", + "//test/images/no-snat-test-proxy:all-srcs", "//test/images/port-forward-tester:all-srcs", "//test/images/porter:all-srcs", "//test/images/resource-consumer:all-srcs", diff --git a/test/images/no-snat-test-proxy/BUILD b/test/images/no-snat-test-proxy/BUILD new file mode 100644 index 0000000000000..7092e009581b1 --- /dev/null +++ b/test/images/no-snat-test-proxy/BUILD @@ -0,0 +1,39 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_binary", + "go_library", +) + +go_binary( + name = "no-snat-test-proxy", + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = ["main.go"], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/spf13/pflag:go_default_library", + "//vendor/k8s.io/apiserver/pkg/util/flag:go_default_library", + "//vendor/k8s.io/apiserver/pkg/util/logs:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/test/images/no-snat-test-proxy/Dockerfile b/test/images/no-snat-test-proxy/Dockerfile new file mode 100644 index 0000000000000..232126642f086 --- /dev/null +++ b/test/images/no-snat-test-proxy/Dockerfile @@ -0,0 +1,20 @@ +# Copyright 2017 The Kubernetes 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. + +FROM alpine:3.5 + +ADD no-snat-test-proxy /usr/bin/no-snat-test-proxy +RUN chmod +x /usr/bin/no-snat-test-proxy + +ENTRYPOINT ["/usr/bin/no-snat-test-proxy"] \ No newline at end of file diff --git a/test/images/no-snat-test-proxy/Makefile b/test/images/no-snat-test-proxy/Makefile new file mode 100644 index 0000000000000..8457932667041 --- /dev/null +++ b/test/images/no-snat-test-proxy/Makefile @@ -0,0 +1,29 @@ +# Copyright 2017 The Kubernetes 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. + +REGISTRY?=gcr.io/google_containers +REGISTRY_TAG?=1.0.1 +ARCH?=amd64 +NAME?=no-snat-test-proxy + +build: + go build --ldflags '-linkmode external -extldflags "-static"' -o $(NAME) main.go + docker build -t $(REGISTRY)/$(NAME)-$(ARCH):$(REGISTRY_TAG) . + rm $(NAME) + +push: build + gcloud docker -- push $(REGISTRY)/$(NAME)-$(ARCH):$(REGISTRY_TAG) + +all: build +.PHONY: build push \ No newline at end of file diff --git a/test/images/no-snat-test-proxy/main.go b/test/images/no-snat-test-proxy/main.go new file mode 100644 index 0000000000000..a133343b7943e --- /dev/null +++ b/test/images/no-snat-test-proxy/main.go @@ -0,0 +1,101 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package main + +import ( + "fmt" + "io/ioutil" + "net/http" + "os" + "strings" + + "github.com/spf13/pflag" + "k8s.io/apiserver/pkg/util/flag" + "k8s.io/apiserver/pkg/util/logs" +) + +// This Pod's /checknosnat takes `target` and `ips` arguments, and queries {target}/checknosnat?ips={ips} + +type MasqTestProxy struct { + Port string +} + +func NewMasqTestProxy() *MasqTestProxy { + return &MasqTestProxy{ + Port: "31235", + } +} + +func (m *MasqTestProxy) AddFlags(fs *pflag.FlagSet) { + fs.StringVar(&m.Port, "port", m.Port, "The port to serve /checknosnat endpoint on.") +} + +func main() { + m := NewMasqTestProxy() + m.AddFlags(pflag.CommandLine) + + flag.InitFlags() + logs.InitLogs() + defer logs.FlushLogs() + + if err := m.Run(); err != nil { + fmt.Fprintf(os.Stderr, "%v\n", err) + os.Exit(1) + } +} + +func (m *MasqTestProxy) Run() error { + // register handler + http.HandleFunc("/checknosnat", checknosnat) + + // spin up the server + return http.ListenAndServe(":"+m.Port, nil) +} + +type handler func(http.ResponseWriter, *http.Request) + +func joinErrors(errs []error, sep string) string { + strs := make([]string, len(errs)) + for i, err := range errs { + strs[i] = err.Error() + } + return strings.Join(strs, sep) +} + +func checknosnatURL(pip, ips string) string { + return fmt.Sprintf("http://%s/checknosnat?ips=%s", pip, ips) +} + +func checknosnat(w http.ResponseWriter, req *http.Request) { + url := checknosnatURL(req.URL.Query().Get("target"), req.URL.Query().Get("ips")) + resp, err := http.Get(url) + if err != nil { + w.WriteHeader(500) + fmt.Fprintf(w, "error querying %q, err: %v", url, err) + } else { + body, err := ioutil.ReadAll(resp.Body) + if err != nil { + w.WriteHeader(500) + fmt.Fprintf(w, "error reading body of response from %q, err: %v", url, err) + } else { + // Respond the same status code and body as /checknosnat on the internal Pod + w.WriteHeader(resp.StatusCode) + w.Write(body) + } + } + resp.Body.Close() +} diff --git a/test/images/no-snat-test/BUILD b/test/images/no-snat-test/BUILD new file mode 100644 index 0000000000000..a65e54587dfb3 --- /dev/null +++ b/test/images/no-snat-test/BUILD @@ -0,0 +1,39 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_binary", + "go_library", +) + +go_binary( + name = "no-snat-test", + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = ["main.go"], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/spf13/pflag:go_default_library", + "//vendor/k8s.io/apiserver/pkg/util/flag:go_default_library", + "//vendor/k8s.io/apiserver/pkg/util/logs:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/test/images/no-snat-test/Dockerfile b/test/images/no-snat-test/Dockerfile new file mode 100644 index 0000000000000..1cd01aafd4110 --- /dev/null +++ b/test/images/no-snat-test/Dockerfile @@ -0,0 +1,20 @@ +# Copyright 2017 The Kubernetes 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. + +FROM alpine:3.5 + +ADD no-snat-test /usr/bin/no-snat-test +RUN chmod +x /usr/bin/no-snat-test + +ENTRYPOINT ["/usr/bin/no-snat-test"] \ No newline at end of file diff --git a/test/images/no-snat-test/Makefile b/test/images/no-snat-test/Makefile new file mode 100644 index 0000000000000..5ca0c239992d8 --- /dev/null +++ b/test/images/no-snat-test/Makefile @@ -0,0 +1,29 @@ +# Copyright 2017 The Kubernetes 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. + +REGISTRY?=gcr.io/google_containers +REGISTRY_TAG?=1.0.1 +ARCH?=amd64 +NAME?=no-snat-test + +build: + go build --ldflags '-linkmode external -extldflags "-static"' -o $(NAME) main.go + docker build -t $(REGISTRY)/$(NAME)-$(ARCH):$(REGISTRY_TAG) . + rm $(NAME) + +push: build + gcloud docker -- push $(REGISTRY)/$(NAME)-$(ARCH):$(REGISTRY_TAG) + +all: build +.PHONY: build push \ No newline at end of file diff --git a/test/images/no-snat-test/main.go b/test/images/no-snat-test/main.go new file mode 100644 index 0000000000000..40f16eb36a86e --- /dev/null +++ b/test/images/no-snat-test/main.go @@ -0,0 +1,153 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package main + +import ( + "fmt" + "io/ioutil" + "net" + "net/http" + "os" + "strings" + + "github.com/spf13/pflag" + "k8s.io/apiserver/pkg/util/flag" + "k8s.io/apiserver/pkg/util/logs" +) + +// ip = target for /whoami query +// rip = returned ip +// pip = this pod's ip +// nip = this node's ip + +type MasqTester struct { + Port string +} + +func NewMasqTester() *MasqTester { + return &MasqTester{ + Port: "8080", + } +} + +func (m *MasqTester) AddFlags(fs *pflag.FlagSet) { + fs.StringVar(&m.Port, "port", m.Port, "The port to serve /checknosnat and /whoami endpoints on.") +} + +func main() { + m := NewMasqTester() + m.AddFlags(pflag.CommandLine) + + flag.InitFlags() + logs.InitLogs() + defer logs.FlushLogs() + + if err := m.Run(); err != nil { + fmt.Fprintf(os.Stderr, "%v\n", err) + os.Exit(1) + } +} + +func (m *MasqTester) Run() error { + // pip is the current pod's IP and nip is the current node's IP + // pull the pip and nip out of the env + pip, ok := os.LookupEnv("POD_IP") + if !ok { + return fmt.Errorf("POD_IP env var was not present in the environment") + } + nip, ok := os.LookupEnv("NODE_IP") + if !ok { + return fmt.Errorf("NODE_IP env var was not present in the environment") + } + + // validate that pip and nip are ip addresses. + if net.ParseIP(pip) == nil { + return fmt.Errorf("POD_IP env var contained %q, which is not an IP address", pip) + } + if net.ParseIP(nip) == nil { + return fmt.Errorf("NODE_IP env var contained %q, which is not an IP address", nip) + } + + // register handlers + http.HandleFunc("/whoami", whoami) + http.HandleFunc("/checknosnat", mkChecknosnat(pip, nip)) + + // spin up the server + return http.ListenAndServe(":"+m.Port, nil) +} + +type handler func(http.ResponseWriter, *http.Request) + +func joinErrors(errs []error, sep string) string { + strs := make([]string, len(errs)) + for i, err := range errs { + strs[i] = err.Error() + } + return strings.Join(strs, sep) +} + +// Builds checknosnat handler, using pod and node ip of current location +func mkChecknosnat(pip string, nip string) handler { + // Queries /whoami for each provided ip, resp 200 if all resp bodies match this Pod's ip, 500 otherwise + return func(w http.ResponseWriter, req *http.Request) { + errs := []error{} + ips := strings.Split(req.URL.Query().Get("ips"), ",") + for _, ip := range ips { + if err := check(ip, pip, nip); err != nil { + errs = append(errs, err) + } + } + if len(errs) > 0 { + w.WriteHeader(500) + fmt.Fprintf(w, "%s", joinErrors(errs, ", ")) + return + } + w.WriteHeader(200) + } +} + +// Writes the req.RemoteAddr into the response, req.RemoteAddr is the address of the incoming connection +func whoami(w http.ResponseWriter, req *http.Request) { + fmt.Fprintf(w, "%s", req.RemoteAddr) +} + +// Queries ip/whoami and compares response to pip, uses nip to differentiate SNAT from other potential failure modes +func check(ip string, pip string, nip string) error { + url := fmt.Sprintf("http://%s/whoami", ip) + resp, err := http.Get(url) + if err != nil { + return err + } + defer resp.Body.Close() + body, err := ioutil.ReadAll(resp.Body) + if err != nil { + return err + } + rips := strings.Split(string(body), ":") + if rips == nil || len(rips) == 0 { + return fmt.Errorf("Invalid returned ip %q from %q", string(body), url) + } + rip := rips[0] + if rip != pip { + if rip == nip { + return fmt.Errorf("Returned ip %q != my Pod ip %q, == my Node ip %q - SNAT", rip, pip, nip) + } else { + return fmt.Errorf("Returned ip %q != my Pod ip %q or my Node ip %q - SNAT to unexpected ip (possible SNAT through unexpected interface on the way into another node)", rip, pip, nip) + } + } + return nil +} diff --git a/test/images/serve_hostname/Makefile b/test/images/serve_hostname/Makefile index 9cb104ec73064..fce55966e40ad 100644 --- a/test/images/serve_hostname/Makefile +++ b/test/images/serve_hostname/Makefile @@ -31,7 +31,7 @@ ALL_ARCH = amd64 arm arm64 ppc64le s390x GOARM=7 TEMP_DIR := $(shell mktemp -d) -GOLANG_VERSION=1.8.1 +GOLANG_VERSION=1.8.3 BIN = serve_hostname SRCS = serve_hostname.go diff --git a/test/integration/auth/BUILD b/test/integration/auth/BUILD index 166af52f746bc..c7d2f8181297d 100644 --- a/test/integration/auth/BUILD +++ b/test/integration/auth/BUILD @@ -12,6 +12,7 @@ go_test( srcs = [ "accessreview_test.go", "auth_test.go", + "node_test.go", "rbac_test.go", ], tags = [ @@ -27,7 +28,10 @@ go_test( "//pkg/apis/extensions:go_default_library", "//pkg/apis/rbac:go_default_library", "//pkg/auth/authorizer/abac:go_default_library", + "//pkg/auth/nodeidentifier:go_default_library", "//pkg/client/clientset_generated/internalclientset:go_default_library", + "//pkg/client/informers/informers_generated/internalversion:go_default_library", + "//pkg/kubeapiserver/authorizer:go_default_library", "//pkg/master:go_default_library", "//pkg/registry/rbac/clusterrole:go_default_library", "//pkg/registry/rbac/clusterrole/storage:go_default_library", @@ -38,10 +42,14 @@ go_test( "//pkg/registry/rbac/rolebinding:go_default_library", "//pkg/registry/rbac/rolebinding/storage:go_default_library", "//plugin/pkg/admission/admit:go_default_library", + "//plugin/pkg/admission/noderestriction:go_default_library", "//plugin/pkg/auth/authorizer/rbac:go_default_library", + "//plugin/pkg/auth/authorizer/rbac/bootstrappolicy:go_default_library", "//test/integration:go_default_library", "//test/integration/framework:go_default_library", "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", diff --git a/test/integration/auth/node_test.go b/test/integration/auth/node_test.go new file mode 100644 index 0000000000000..d8d9d895fac3e --- /dev/null +++ b/test/integration/auth/node_test.go @@ -0,0 +1,303 @@ +/* +Copyright 2017 The Kubernetes 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. +*/ + +package auth + +import ( + "net/http" + "net/http/httptest" + "path/filepath" + "runtime" + "testing" + "time" + + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + restclient "k8s.io/client-go/rest" + "k8s.io/kubernetes/pkg/api" + "k8s.io/kubernetes/pkg/auth/nodeidentifier" + clientset "k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset" + informers "k8s.io/kubernetes/pkg/client/informers/informers_generated/internalversion" + "k8s.io/kubernetes/pkg/kubeapiserver/authorizer" + "k8s.io/kubernetes/plugin/pkg/admission/noderestriction" + "k8s.io/kubernetes/plugin/pkg/auth/authorizer/rbac/bootstrappolicy" + "k8s.io/kubernetes/test/integration/framework" +) + +func TestNodeAuthorizer(t *testing.T) { + // Start the server so we know the address + h := &framework.MasterHolder{Initialized: make(chan struct{})} + apiServer := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, req *http.Request) { + <-h.Initialized + h.M.GenericAPIServer.Handler.ServeHTTP(w, req) + })) + + // Build client config, clientset, and informers + clientConfig := &restclient.Config{Host: apiServer.URL, ContentConfig: restclient.ContentConfig{NegotiatedSerializer: api.Codecs}} + superuserClient := clientsetForUser("admin/system:masters", clientConfig) + informerFactory := informers.NewSharedInformerFactory(superuserClient, time.Minute) + + // Set up Node+RBAC authorizer + authorizerConfig := &authorizer.AuthorizationConfig{ + AuthorizationModes: []string{"Node", "RBAC"}, + InformerFactory: informerFactory, + } + nodeRBACAuthorizer, err := authorizerConfig.New() + if err != nil { + t.Fatal(err) + } + defer bootstrappolicy.ClearClusterRoleBindingFilters() + + // Set up NodeRestriction admission + nodeRestrictionAdmission := noderestriction.NewPlugin(nodeidentifier.NewDefaultNodeIdentifier()) + nodeRestrictionAdmission.SetInternalKubeClientSet(superuserClient) + if err := nodeRestrictionAdmission.Validate(); err != nil { + t.Fatal(err) + } + + // Start the server + masterConfig := framework.NewIntegrationTestMasterConfig() + masterConfig.GenericConfig.Authenticator = newFakeAuthenticator() + masterConfig.GenericConfig.Authorizer = nodeRBACAuthorizer + masterConfig.GenericConfig.AdmissionControl = nodeRestrictionAdmission + _, _, closeFn := framework.RunAMasterUsingServer(masterConfig, apiServer, h) + defer closeFn() + + // Start the informers + stopCh := make(chan struct{}) + defer close(stopCh) + informerFactory.Start(stopCh) + + // Wait for a healthy server + for { + result := superuserClient.Core().RESTClient().Get().AbsPath("/healthz").Do() + _, err := result.Raw() + if err == nil { + break + } + t.Log(err) + time.Sleep(time.Second) + } + + // Create objects + if _, err := superuserClient.Core().Secrets("ns").Create(&api.Secret{ObjectMeta: metav1.ObjectMeta{Name: "mysecret"}}); err != nil { + t.Fatal(err) + } + if _, err := superuserClient.Core().Secrets("ns").Create(&api.Secret{ObjectMeta: metav1.ObjectMeta{Name: "mypvsecret"}}); err != nil { + t.Fatal(err) + } + if _, err := superuserClient.Core().ConfigMaps("ns").Create(&api.ConfigMap{ObjectMeta: metav1.ObjectMeta{Name: "myconfigmap"}}); err != nil { + t.Fatal(err) + } + if _, err := superuserClient.Core().PersistentVolumeClaims("ns").Create(&api.PersistentVolumeClaim{ + ObjectMeta: metav1.ObjectMeta{Name: "mypvc"}, + Spec: api.PersistentVolumeClaimSpec{ + AccessModes: []api.PersistentVolumeAccessMode{api.ReadOnlyMany}, + Resources: api.ResourceRequirements{Requests: api.ResourceList{api.ResourceStorage: resource.MustParse("1")}}, + }, + }); err != nil { + t.Fatal(err) + } + if _, err := superuserClient.Core().PersistentVolumes().Create(&api.PersistentVolume{ + ObjectMeta: metav1.ObjectMeta{Name: "mypv"}, + Spec: api.PersistentVolumeSpec{ + AccessModes: []api.PersistentVolumeAccessMode{api.ReadOnlyMany}, + Capacity: api.ResourceList{api.ResourceStorage: resource.MustParse("1")}, + ClaimRef: &api.ObjectReference{Namespace: "ns", Name: "mypvc"}, + PersistentVolumeSource: api.PersistentVolumeSource{AzureFile: &api.AzureFileVolumeSource{ShareName: "default", SecretName: "mypvsecret"}}, + }, + }); err != nil { + t.Fatal(err) + } + + getSecret := func(client clientset.Interface) error { + _, err := client.Core().Secrets("ns").Get("mysecret", metav1.GetOptions{}) + return err + } + getPVSecret := func(client clientset.Interface) error { + _, err := client.Core().Secrets("ns").Get("mypvsecret", metav1.GetOptions{}) + return err + } + getConfigMap := func(client clientset.Interface) error { + _, err := client.Core().ConfigMaps("ns").Get("myconfigmap", metav1.GetOptions{}) + return err + } + getPVC := func(client clientset.Interface) error { + _, err := client.Core().PersistentVolumeClaims("ns").Get("mypvc", metav1.GetOptions{}) + return err + } + getPV := func(client clientset.Interface) error { + _, err := client.Core().PersistentVolumes().Get("mypv", metav1.GetOptions{}) + return err + } + + createNode2NormalPod := func(client clientset.Interface) error { + _, err := client.Core().Pods("ns").Create(&api.Pod{ + ObjectMeta: metav1.ObjectMeta{Name: "node2normalpod"}, + Spec: api.PodSpec{ + NodeName: "node2", + Containers: []api.Container{{Name: "image", Image: "busybox"}}, + Volumes: []api.Volume{ + {Name: "secret", VolumeSource: api.VolumeSource{Secret: &api.SecretVolumeSource{SecretName: "mysecret"}}}, + {Name: "cm", VolumeSource: api.VolumeSource{ConfigMap: &api.ConfigMapVolumeSource{LocalObjectReference: api.LocalObjectReference{Name: "myconfigmap"}}}}, + {Name: "pvc", VolumeSource: api.VolumeSource{PersistentVolumeClaim: &api.PersistentVolumeClaimVolumeSource{ClaimName: "mypvc"}}}, + }, + }, + }) + return err + } + updateNode2NormalPodStatus := func(client clientset.Interface) error { + startTime := metav1.NewTime(time.Now()) + _, err := client.Core().Pods("ns").UpdateStatus(&api.Pod{ + ObjectMeta: metav1.ObjectMeta{Name: "node2normalpod"}, + Status: api.PodStatus{StartTime: &startTime}, + }) + return err + } + deleteNode2NormalPod := func(client clientset.Interface) error { + zero := int64(0) + return client.Core().Pods("ns").Delete("node2normalpod", &metav1.DeleteOptions{GracePeriodSeconds: &zero}) + } + + createNode2MirrorPod := func(client clientset.Interface) error { + _, err := client.Core().Pods("ns").Create(&api.Pod{ + ObjectMeta: metav1.ObjectMeta{ + Name: "node2mirrorpod", + Annotations: map[string]string{api.MirrorPodAnnotationKey: "true"}, + }, + Spec: api.PodSpec{ + NodeName: "node2", + Containers: []api.Container{{Name: "image", Image: "busybox"}}, + }, + }) + return err + } + deleteNode2MirrorPod := func(client clientset.Interface) error { + zero := int64(0) + return client.Core().Pods("ns").Delete("node2mirrorpod", &metav1.DeleteOptions{GracePeriodSeconds: &zero}) + } + + createNode2 := func(client clientset.Interface) error { + _, err := client.Core().Nodes().Create(&api.Node{ObjectMeta: metav1.ObjectMeta{Name: "node2"}}) + return err + } + updateNode2Status := func(client clientset.Interface) error { + _, err := client.Core().Nodes().UpdateStatus(&api.Node{ + ObjectMeta: metav1.ObjectMeta{Name: "node2"}, + Status: api.NodeStatus{}, + }) + return err + } + deleteNode2 := func(client clientset.Interface) error { + return client.Core().Nodes().Delete("node2", nil) + } + + nodeanonClient := clientsetForUser("unknown/system:nodes", clientConfig) + node1Client := clientsetForUser("system:node:node1/system:nodes", clientConfig) + node2Client := clientsetForUser("system:node:node2/system:nodes", clientConfig) + + // all node requests from node1 and unknown node fail + expectForbidden(t, getSecret(nodeanonClient)) + expectForbidden(t, getPVSecret(nodeanonClient)) + expectForbidden(t, getConfigMap(nodeanonClient)) + expectForbidden(t, getPVC(nodeanonClient)) + expectForbidden(t, getPV(nodeanonClient)) + expectForbidden(t, createNode2NormalPod(nodeanonClient)) + expectForbidden(t, createNode2MirrorPod(nodeanonClient)) + expectForbidden(t, deleteNode2MirrorPod(nodeanonClient)) + expectForbidden(t, createNode2(nodeanonClient)) + expectForbidden(t, updateNode2Status(nodeanonClient)) + expectForbidden(t, deleteNode2(nodeanonClient)) + + expectForbidden(t, getSecret(node1Client)) + expectForbidden(t, getPVSecret(node1Client)) + expectForbidden(t, getConfigMap(node1Client)) + expectForbidden(t, getPVC(node1Client)) + expectForbidden(t, getPV(node1Client)) + expectForbidden(t, createNode2NormalPod(nodeanonClient)) + expectForbidden(t, createNode2MirrorPod(node1Client)) + expectForbidden(t, deleteNode2MirrorPod(node1Client)) + expectForbidden(t, createNode2(node1Client)) + expectForbidden(t, updateNode2Status(node1Client)) + expectForbidden(t, deleteNode2(node1Client)) + + // related object requests from node2 fail + expectForbidden(t, getSecret(node2Client)) + expectForbidden(t, getPVSecret(node2Client)) + expectForbidden(t, getConfigMap(node2Client)) + expectForbidden(t, getPVC(node2Client)) + expectForbidden(t, getPV(node2Client)) + expectForbidden(t, createNode2NormalPod(nodeanonClient)) + // mirror pod and self node lifecycle is allowed + expectAllowed(t, createNode2MirrorPod(node2Client)) + expectAllowed(t, deleteNode2MirrorPod(node2Client)) + expectAllowed(t, createNode2(node2Client)) + expectAllowed(t, updateNode2Status(node2Client)) + expectAllowed(t, deleteNode2(node2Client)) + + // create a pod as an admin to add object references + expectAllowed(t, createNode2NormalPod(superuserClient)) + + // unidentifiable node and node1 are still forbidden + expectForbidden(t, getSecret(nodeanonClient)) + expectForbidden(t, getPVSecret(nodeanonClient)) + expectForbidden(t, getConfigMap(nodeanonClient)) + expectForbidden(t, getPVC(nodeanonClient)) + expectForbidden(t, getPV(nodeanonClient)) + expectForbidden(t, createNode2NormalPod(nodeanonClient)) + expectForbidden(t, updateNode2NormalPodStatus(nodeanonClient)) + expectForbidden(t, deleteNode2NormalPod(nodeanonClient)) + expectForbidden(t, createNode2MirrorPod(nodeanonClient)) + expectForbidden(t, deleteNode2MirrorPod(nodeanonClient)) + + expectForbidden(t, getSecret(node1Client)) + expectForbidden(t, getPVSecret(node1Client)) + expectForbidden(t, getConfigMap(node1Client)) + expectForbidden(t, getPVC(node1Client)) + expectForbidden(t, getPV(node1Client)) + expectForbidden(t, createNode2NormalPod(node1Client)) + expectForbidden(t, updateNode2NormalPodStatus(node1Client)) + expectForbidden(t, deleteNode2NormalPod(node1Client)) + expectForbidden(t, createNode2MirrorPod(node1Client)) + expectForbidden(t, deleteNode2MirrorPod(node1Client)) + + // node2 can get referenced objects now + expectAllowed(t, getSecret(node2Client)) + expectAllowed(t, getPVSecret(node2Client)) + expectAllowed(t, getConfigMap(node2Client)) + expectAllowed(t, getPVC(node2Client)) + expectAllowed(t, getPV(node2Client)) + expectForbidden(t, createNode2NormalPod(node2Client)) + expectAllowed(t, updateNode2NormalPodStatus(node2Client)) + expectAllowed(t, deleteNode2NormalPod(node2Client)) + expectAllowed(t, createNode2MirrorPod(node2Client)) + expectAllowed(t, deleteNode2MirrorPod(node2Client)) +} + +func expectForbidden(t *testing.T, err error) { + if !errors.IsForbidden(err) { + _, file, line, _ := runtime.Caller(1) + t.Errorf("%s:%d: Expected forbidden error, got %v", filepath.Base(file), line, err) + } +} + +func expectAllowed(t *testing.T, err error) { + if err != nil { + _, file, line, _ := runtime.Caller(1) + t.Errorf("%s:%d: Expected no error, got %v", filepath.Base(file), line, err) + } +} diff --git a/test/integration/etcd/etcd_storage_path_test.go b/test/integration/etcd/etcd_storage_path_test.go index 33b7a3702d079..936ac26b15352 100644 --- a/test/integration/etcd/etcd_storage_path_test.go +++ b/test/integration/etcd/etcd_storage_path_test.go @@ -141,6 +141,10 @@ var etcdStorageData = map[schema.GroupVersionResource]struct { expectedEtcdPath: "/registry/deployments/etcdstoragepathtestnamespace/deployment2", expectedGVK: gvkP("extensions", "v1beta1", "Deployment"), }, + gvr("apps", "v1beta1", "controllerrevisions"): { + stub: `{"metadata":{"name":"crs1"},"data":{"name":"abc","namespace":"default","creationTimestamp":null,"Spec":{"Replicas":0,"Selector":{"matchLabels":{"foo":"bar"}},"Template":{"creationTimestamp":null,"labels":{"foo":"bar"},"Spec":{"Volumes":null,"InitContainers":null,"Containers":null,"RestartPolicy":"Always","TerminationGracePeriodSeconds":null,"ActiveDeadlineSeconds":null,"DNSPolicy":"ClusterFirst","NodeSelector":null,"ServiceAccountName":"","AutomountServiceAccountToken":null,"NodeName":"","SecurityContext":null,"ImagePullSecrets":null,"Hostname":"","Subdomain":"","Affinity":null,"SchedulerName":"","Tolerations":null,"HostAliases":null}},"VolumeClaimTemplates":null,"ServiceName":""},"Status":{"ObservedGeneration":null,"Replicas":0}},"revision":0}`, + expectedEtcdPath: "/registry/controllerrevisions/etcdstoragepathtestnamespace/crs1", + }, // -- // k8s.io/kubernetes/pkg/apis/autoscaling/v1 @@ -215,6 +219,14 @@ var etcdStorageData = map[schema.GroupVersionResource]struct { }, // -- + // k8s.io/kubernetes/pkg/apis/networking/v1 + gvr("networking.k8s.io", "v1", "networkpolicies"): { + stub: `{"metadata": {"name": "np2"}, "spec": {"podSelector": {"matchLabels": {"e": "f"}}}}`, + expectedEtcdPath: "/registry/networkpolicies/etcdstoragepathtestnamespace/np2", + expectedGVK: gvkP("extensions", "v1beta1", "NetworkPolicy"), + }, + // -- + // k8s.io/kubernetes/pkg/apis/policy/v1beta1 gvr("policy", "v1beta1", "poddisruptionbudgets"): { stub: `{"metadata": {"name": "pdb1"}, "spec": {"selector": {"matchLabels": {"anokkey": "anokvalue"}}}}`, @@ -285,6 +297,16 @@ var etcdStorageData = map[schema.GroupVersionResource]struct { expectedEtcdPath: "/registry/clusterrolebindings/croleb2", }, // -- + + // k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1 + gvr("admissionregistration.k8s.io", "v1alpha1", "initializerconfigurations"): { + stub: `{"metadata":{"name":"ic1"},"initializers":[{"name":"initializer.k8s.io","rules":[{"apiGroups":["group"],"apiVersions":["version"],"resources":["resource"]}],"failurePolicy":"Ignore"}]}`, + expectedEtcdPath: "/registry/initializerconfigurations/ic1", + }, + gvr("admissionregistration.k8s.io", "v1alpha1", "externaladmissionhookconfigurations"): { + stub: `{"metadata":{"name":"hook1","creationTimestamp":null},"externalAdmissionHooks":[{"name":"externaladmissionhook.k8s.io","clientConfig":{"service":{"namespace":"","name":""},"caBundle":null},"rules":[{"operations":["CREATE"],"apiGroups":["group"],"apiVersions":["version"],"resources":["resource"]}],"failurePolicy":"Ignore"}]}`, + expectedEtcdPath: "/registry/externaladmissionhookconfigurations/hook1", + }, } // Be very careful when whitelisting an object as ephemeral. @@ -585,7 +607,7 @@ func startRealMasterOrDie(t *testing.T, certDir string) (*allClient, clientv3.KV kubeAPIServerConfig.APIResourceConfigSource = &allResourceSource{} // force enable all resources - kubeAPIServer, err := app.CreateKubeAPIServer(kubeAPIServerConfig, genericapiserver.EmptyDelegate, sharedInformers) + kubeAPIServer, err := app.CreateKubeAPIServer(kubeAPIServerConfig, genericapiserver.EmptyDelegate, sharedInformers, nil) if err != nil { t.Fatal(err) } diff --git a/test/integration/examples/apiserver_test.go b/test/integration/examples/apiserver_test.go index 7766282e7d26a..87f401701f401 100644 --- a/test/integration/examples/apiserver_test.go +++ b/test/integration/examples/apiserver_test.go @@ -118,7 +118,7 @@ func TestAggregatedAPIServer(t *testing.T) { } kubeClientConfigValue.Store(kubeAPIServerConfig.GenericConfig.LoopbackClientConfig) - kubeAPIServer, err := app.CreateKubeAPIServer(kubeAPIServerConfig, genericapiserver.EmptyDelegate, sharedInformers) + kubeAPIServer, err := app.CreateKubeAPIServer(kubeAPIServerConfig, genericapiserver.EmptyDelegate, sharedInformers, nil) if err != nil { t.Fatal(err) } diff --git a/test/integration/framework/master_utils.go b/test/integration/framework/master_utils.go index 499a84249364a..7adc063a7089f 100644 --- a/test/integration/framework/master_utils.go +++ b/test/integration/framework/master_utils.go @@ -253,7 +253,7 @@ func startMasterOrDie(masterConfig *master.Config, incomingServer *httptest.Serv } masterConfig.GenericConfig.SharedInformerFactory = extinformers.NewSharedInformerFactory(clientset, masterConfig.GenericConfig.LoopbackClientConfig.Timeout) - m, err = masterConfig.Complete().New(genericapiserver.EmptyDelegate) + m, err = masterConfig.Complete().New(genericapiserver.EmptyDelegate, nil) if err != nil { closeFn() glog.Fatalf("error in bringing up the master: %v", err) diff --git a/test/kubemark/cloud-provider-config.sh b/test/kubemark/cloud-provider-config.sh old mode 100644 new mode 100755 diff --git a/test/kubemark/configure-kubectl.sh b/test/kubemark/configure-kubectl.sh old mode 100644 new mode 100755 diff --git a/test/kubemark/gce/util.sh b/test/kubemark/gce/util.sh index d37ee974a3b29..5bb57bbed04ea 100644 --- a/test/kubemark/gce/util.sh +++ b/test/kubemark/gce/util.sh @@ -113,7 +113,7 @@ function execute-cmd-on-master-with-retries() { } function copy-files() { - run-gcloud-compute-with-retries copy-files --zone="${ZONE}" --project="${PROJECT}" $@ + run-gcloud-compute-with-retries scp --recurse --zone="${ZONE}" --project="${PROJECT}" $@ } function delete-master-instance-and-resources { diff --git a/test/kubemark/resources/start-kubemark-master.sh b/test/kubemark/resources/start-kubemark-master.sh old mode 100644 new mode 100755 index 83b6ad4a7a21a..bdc11bc64bc14 --- a/test/kubemark/resources/start-kubemark-master.sh +++ b/test/kubemark/resources/start-kubemark-master.sh @@ -17,6 +17,10 @@ # Script that starts kubelet on kubemark-master as a supervisord process # and then runs the master components as pods using kubelet. +set -o errexit +set -o nounset +set -o pipefail + # Define key path variables. KUBE_ROOT="/home/kubernetes" KUBE_BINDIR="${KUBE_ROOT}/kubernetes/server/bin" @@ -93,7 +97,6 @@ function safe-format-and-mount() { mkfs.ext4 -F "${device}" fi - mkdir -p "${mountpoint}" echo "Mounting '${device}' at '${mountpoint}'" mount -o discard,defaults "${device}" "${mountpoint}" } @@ -493,9 +496,17 @@ start-kubemaster-component "kube-controller-manager" start-kubemaster-component "kube-scheduler" start-kubemaster-component "kube-addon-manager" -# Wait till apiserver is working fine. +# Wait till apiserver is working fine or timeout. +echo -n "Waiting for apiserver to be healthy" +start=$(date +%s) until [ "$(curl 127.0.0.1:8080/healthz 2> /dev/null)" == "ok" ]; do + echo -n "." sleep 1 + now=$(date +%s) + if [ $((now - start)) -gt 300 ]; then + echo "Timeout!" + exit 1 + fi done echo "Done for the configuration for kubermark master" diff --git a/test/kubemark/run-e2e-tests.sh b/test/kubemark/run-e2e-tests.sh index 476b3472e8128..aeb039410f4f9 100755 --- a/test/kubemark/run-e2e-tests.sh +++ b/test/kubemark/run-e2e-tests.sh @@ -33,7 +33,7 @@ export KUBECONFIG="${ABSOLUTE_ROOT}/test/kubemark/resources/kubeconfig.kubemark" export E2E_MIN_STARTUP_PODS=0 if [[ -z "$@" ]]; then - ARGS='--ginkgo.focus=\[Feature:Performance\]' + ARGS='--ginkgo.focus=[Feature:Performance]' else ARGS=$@ fi @@ -43,5 +43,6 @@ if [[ -f /.dockerenv ]]; then go run ./hack/e2e.go -- -v --check-version-skew=false --test --test_args="--e2e-verify-service-account=false --dump-logs-on-failure=false ${ARGS}" else # Running locally. + ARGS=$(echo $ARGS | sed 's/\[/\\\[/g' | sed 's/\]/\\\]/g') ${KUBE_ROOT}/hack/ginkgo-e2e.sh "--e2e-verify-service-account=false" "--dump-logs-on-failure=false" $ARGS fi diff --git a/test/kubemark/start-kubemark.sh b/test/kubemark/start-kubemark.sh index d9a63c2f7769d..f64f48620b10c 100755 --- a/test/kubemark/start-kubemark.sh +++ b/test/kubemark/start-kubemark.sh @@ -16,6 +16,10 @@ # Script that creates a Kubemark cluster for any given cloud provider. +set -o errexit +set -o nounset +set -o pipefail + TMP_ROOT="$(dirname "${BASH_SOURCE}")/../.." KUBE_ROOT=$(readlink -e ${TMP_ROOT} 2> /dev/null || perl -MCwd -e 'print Cwd::abs_path shift' ${TMP_ROOT}) @@ -110,34 +114,6 @@ function write-pki-config-to-master { echo "Wrote PKI certs, keys, tokens and admin password to master." } -# Copy all the necessary resource files (scripts/configs/manifests) to the master. -function copy-resource-files-to-master { - copy-files \ - "${SERVER_BINARY_TAR}" \ - "${RESOURCE_DIRECTORY}/kubemark-master-env.sh" \ - "${RESOURCE_DIRECTORY}/start-kubemark-master.sh" \ - "${KUBEMARK_DIRECTORY}/configure-kubectl.sh" \ - "${RESOURCE_DIRECTORY}/manifests/etcd.yaml" \ - "${RESOURCE_DIRECTORY}/manifests/etcd-events.yaml" \ - "${RESOURCE_DIRECTORY}/manifests/kube-apiserver.yaml" \ - "${RESOURCE_DIRECTORY}/manifests/kube-scheduler.yaml" \ - "${RESOURCE_DIRECTORY}/manifests/kube-controller-manager.yaml" \ - "${RESOURCE_DIRECTORY}/manifests/kube-addon-manager.yaml" \ - "${RESOURCE_DIRECTORY}/manifests/addons/kubemark-rbac-bindings" \ - "kubernetes@${MASTER_NAME}":/home/kubernetes/ - echo "Copied server binary, master startup scripts, configs and resource manifests to master." -} - -# Make startup scripts executable and run start-kubemark-master.sh. -function start-master-components { - echo "" - MASTER_STARTUP_CMD="sudo chmod a+x /home/kubernetes/configure-kubectl.sh && \ - sudo chmod a+x /home/kubernetes/start-kubemark-master.sh && \ - sudo bash /home/kubernetes/start-kubemark-master.sh" - execute-cmd-on-master-with-retries "${MASTER_STARTUP_CMD}" - echo "The master has started and is now live." -} - # Write kubeconfig to ${RESOURCE_DIRECTORY}/kubeconfig.kubemark in order to # use kubectl locally. function write-local-kubeconfig { @@ -167,6 +143,33 @@ EOF echo "Kubeconfig file for kubemark master written to ${LOCAL_KUBECONFIG}." } +# Copy all the necessary resource files (scripts/configs/manifests) to the master. +function copy-resource-files-to-master { + copy-files \ + "${SERVER_BINARY_TAR}" \ + "${RESOURCE_DIRECTORY}/kubemark-master-env.sh" \ + "${RESOURCE_DIRECTORY}/start-kubemark-master.sh" \ + "${RESOURCE_DIRECTORY}/kubeconfig.kubemark" \ + "${KUBEMARK_DIRECTORY}/configure-kubectl.sh" \ + "${RESOURCE_DIRECTORY}/manifests/etcd.yaml" \ + "${RESOURCE_DIRECTORY}/manifests/etcd-events.yaml" \ + "${RESOURCE_DIRECTORY}/manifests/kube-apiserver.yaml" \ + "${RESOURCE_DIRECTORY}/manifests/kube-scheduler.yaml" \ + "${RESOURCE_DIRECTORY}/manifests/kube-controller-manager.yaml" \ + "${RESOURCE_DIRECTORY}/manifests/kube-addon-manager.yaml" \ + "${RESOURCE_DIRECTORY}/manifests/addons/kubemark-rbac-bindings" \ + "kubernetes@${MASTER_NAME}":/home/kubernetes/ + echo "Copied server binary, master startup scripts, configs and resource manifests to master." +} + +# Make startup scripts executable and run start-kubemark-master.sh. +function start-master-components { + echo "" + MASTER_STARTUP_CMD="sudo bash /home/kubernetes/start-kubemark-master.sh" + execute-cmd-on-master-with-retries "${MASTER_STARTUP_CMD}" + echo "The master has started and is now live." +} + # Finds the right kubemark binary for 'linux/amd64' platform and uses it to # create a docker image for hollow-node and upload it to the appropriate # docker container registry for the cloud provider. @@ -303,8 +306,8 @@ current-context: kubemark-context") metrics_mem=$((200 + ${metrics_mem_per_node}*${NUM_NODES:-10})) sed -i'' -e "s/{{METRICS_MEM}}/${metrics_mem}/g" "${RESOURCE_DIRECTORY}/addons/heapster.json" metrics_cpu_per_node_numerator=${NUM_NODES:-10} - metrics_cpu_per_node_denumerator=2 - metrics_cpu=$((80 + metrics_cpu_per_node_numerator / metrics_cpu_per_node_denumerator)) + metrics_cpu_per_node_denominator=2 + metrics_cpu=$((80 + metrics_cpu_per_node_numerator / metrics_cpu_per_node_denominator)) sed -i'' -e "s/{{METRICS_CPU}}/${metrics_cpu}/g" "${RESOURCE_DIRECTORY}/addons/heapster.json" eventer_mem_per_node=500 eventer_mem=$((200 * 1024 + ${eventer_mem_per_node}*${NUM_NODES:-10})) @@ -378,13 +381,13 @@ create-master-instance-with-resources generate-pki-config wait-for-master-reachability write-pki-config-to-master +write-local-kubeconfig copy-resource-files-to-master start-master-components # Setup for hollow-nodes. echo "" echo -e "${color_yellow}STARTING SETUP FOR HOLLOW-NODES${color_norm}" -write-local-kubeconfig create-and-upload-hollow-node-image create-kube-hollow-node-resources wait-for-hollow-nodes-to-run-or-timeout diff --git a/test/utils/runners.go b/test/utils/runners.go index c1cdb21a2d5ec..ae3e5990aeaf4 100644 --- a/test/utils/runners.go +++ b/test/utils/runners.go @@ -163,8 +163,9 @@ type RCConfig struct { NodeDumpFunc func(c clientset.Interface, nodeNames []string, logFunc func(fmt string, args ...interface{})) ContainerDumpFunc func(c clientset.Interface, ns string, logFunc func(ftm string, args ...interface{})) - // Names of the secrets to mount - SecretNames []string + // Names of the secrets and configmaps to mount. + SecretNames []string + ConfigMapNames []string } func (rc *RCConfig) RCConfigLog(fmt string, args ...interface{}) { @@ -306,6 +307,9 @@ func (config *DeploymentConfig) create() error { if len(config.SecretNames) > 0 { attachSecrets(&deployment.Spec.Template, config.SecretNames) } + if len(config.ConfigMapNames) > 0 { + attachConfigMaps(&deployment.Spec.Template, config.ConfigMapNames) + } config.applyTo(&deployment.Spec.Template) @@ -370,6 +374,9 @@ func (config *ReplicaSetConfig) create() error { if len(config.SecretNames) > 0 { attachSecrets(&rs.Spec.Template, config.SecretNames) } + if len(config.ConfigMapNames) > 0 { + attachConfigMaps(&rs.Spec.Template, config.ConfigMapNames) + } config.applyTo(&rs.Spec.Template) @@ -430,6 +437,9 @@ func (config *JobConfig) create() error { if len(config.SecretNames) > 0 { attachSecrets(&job.Spec.Template, config.SecretNames) } + if len(config.ConfigMapNames) > 0 { + attachConfigMaps(&job.Spec.Template, config.ConfigMapNames) + } config.applyTo(&job.Spec.Template) @@ -529,6 +539,9 @@ func (config *RCConfig) create() error { if len(config.SecretNames) > 0 { attachSecrets(rc.Spec.Template, config.SecretNames) } + if len(config.ConfigMapNames) > 0 { + attachConfigMaps(rc.Spec.Template, config.ConfigMapNames) + } config.applyTo(rc.Spec.Template) @@ -1118,6 +1131,67 @@ func attachSecrets(template *v1.PodTemplateSpec, secretNames []string) { template.Spec.Containers[0].VolumeMounts = mounts } +type ConfigMapConfig struct { + Content map[string]string + Client clientset.Interface + Name string + Namespace string + // If set this function will be used to print log lines instead of glog. + LogFunc func(fmt string, args ...interface{}) +} + +func (config *ConfigMapConfig) Run() error { + configMap := &v1.ConfigMap{ + ObjectMeta: metav1.ObjectMeta{ + Name: config.Name, + }, + Data: map[string]string{}, + } + for k, v := range config.Content { + configMap.Data[k] = v + } + + _, err := config.Client.Core().ConfigMaps(config.Namespace).Create(configMap) + if err != nil { + return fmt.Errorf("Error creating configmap: %v", err) + } + config.LogFunc("Created configmap %v/%v", config.Namespace, config.Name) + return nil +} + +func (config *ConfigMapConfig) Stop() error { + if err := config.Client.Core().ConfigMaps(config.Namespace).Delete(config.Name, &metav1.DeleteOptions{}); err != nil { + return fmt.Errorf("Error deleting configmap: %v", err) + } + config.LogFunc("Deleted configmap %v/%v", config.Namespace, config.Name) + return nil +} + +// TODO: attach configmaps using different possibilities: env vars. +func attachConfigMaps(template *v1.PodTemplateSpec, configMapNames []string) { + volumes := make([]v1.Volume, 0, len(configMapNames)) + mounts := make([]v1.VolumeMount, 0, len(configMapNames)) + for _, name := range configMapNames { + volumes = append(volumes, v1.Volume{ + Name: name, + VolumeSource: v1.VolumeSource{ + ConfigMap: &v1.ConfigMapVolumeSource{ + LocalObjectReference: v1.LocalObjectReference{ + Name: name, + }, + }, + }, + }) + mounts = append(mounts, v1.VolumeMount{ + Name: name, + MountPath: fmt.Sprintf("/%v", name), + }) + } + + template.Spec.Volumes = volumes + template.Spec.Containers[0].VolumeMounts = mounts +} + type DaemonConfig struct { Client clientset.Interface Name string diff --git a/third_party/BUILD b/third_party/BUILD index 801e43d550120..a100a2ca1aef6 100644 --- a/third_party/BUILD +++ b/third_party/BUILD @@ -20,6 +20,7 @@ filegroup( "//third_party/forked/golang/expansion:all-srcs", "//third_party/forked/golang/reflect:all-srcs", "//third_party/forked/golang/template:all-srcs", + "//third_party/forked/gonum/graph:all-srcs", "//third_party/htpasswd:all-srcs", ], tags = ["automanaged"], diff --git a/third_party/forked/gonum/graph/BUILD b/third_party/forked/gonum/graph/BUILD new file mode 100644 index 0000000000000..5fef90777fb18 --- /dev/null +++ b/third_party/forked/gonum/graph/BUILD @@ -0,0 +1,32 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["graph.go"], + tags = ["automanaged"], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [ + ":package-srcs", + "//third_party/forked/gonum/graph/internal/linear:all-srcs", + "//third_party/forked/gonum/graph/simple:all-srcs", + "//third_party/forked/gonum/graph/traverse:all-srcs", + ], + tags = ["automanaged"], +) diff --git a/third_party/forked/gonum/graph/LICENSE b/third_party/forked/gonum/graph/LICENSE new file mode 100644 index 0000000000000..76edf5ef7e94f --- /dev/null +++ b/third_party/forked/gonum/graph/LICENSE @@ -0,0 +1,23 @@ +Copyright ©2013 The gonum Authors. All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + * Neither the name of the gonum project nor the names of its authors and + contributors may be used to endorse or promote products derived from this + software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. \ No newline at end of file diff --git a/third_party/forked/gonum/graph/README.md b/third_party/forked/gonum/graph/README.md new file mode 100644 index 0000000000000..3b51e664a4740 --- /dev/null +++ b/third_party/forked/gonum/graph/README.md @@ -0,0 +1 @@ +Forked from gonum/graph@50b27dea7ebbfb052dfaf91681afc6fde28d8796 to support memory-use improvements to the simple graph diff --git a/third_party/forked/gonum/graph/graph.go b/third_party/forked/gonum/graph/graph.go new file mode 100644 index 0000000000000..adade5d79bbbe --- /dev/null +++ b/third_party/forked/gonum/graph/graph.go @@ -0,0 +1,153 @@ +// Copyright ©2014 The gonum Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package graph + +// Node is a graph node. It returns a graph-unique integer ID. +type Node interface { + ID() int +} + +// Edge is a graph edge. In directed graphs, the direction of the +// edge is given from -> to, otherwise the edge is semantically +// unordered. +type Edge interface { + From() Node + To() Node + Weight() float64 +} + +// Graph is a generalized graph. +type Graph interface { + // Has returns whether the node exists within the graph. + Has(Node) bool + + // Nodes returns all the nodes in the graph. + Nodes() []Node + + // From returns all nodes that can be reached directly + // from the given node. + From(Node) []Node + + // HasEdgeBeteen returns whether an edge exists between + // nodes x and y without considering direction. + HasEdgeBetween(x, y Node) bool + + // Edge returns the edge from u to v if such an edge + // exists and nil otherwise. The node v must be directly + // reachable from u as defined by the From method. + Edge(u, v Node) Edge +} + +// Undirected is an undirected graph. +type Undirected interface { + Graph + + // EdgeBetween returns the edge between nodes x and y. + EdgeBetween(x, y Node) Edge +} + +// Directed is a directed graph. +type Directed interface { + Graph + + // HasEdgeFromTo returns whether an edge exists + // in the graph from u to v. + HasEdgeFromTo(u, v Node) bool + + // To returns all nodes that can reach directly + // to the given node. + To(Node) []Node +} + +// Weighter defines graphs that can report edge weights. +type Weighter interface { + // Weight returns the weight for the edge between + // x and y if Edge(x, y) returns a non-nil Edge. + // If x and y are the same node or there is no + // joining edge between the two nodes the weight + // value returned is implementation dependent. + // Weight returns true if an edge exists between + // x and y or if x and y have the same ID, false + // otherwise. + Weight(x, y Node) (w float64, ok bool) +} + +// NodeAdder is an interface for adding arbitrary nodes to a graph. +type NodeAdder interface { + // NewNodeID returns a new unique arbitrary ID. + NewNodeID() int + + // Adds a node to the graph. AddNode panics if + // the added node ID matches an existing node ID. + AddNode(Node) +} + +// NodeRemover is an interface for removing nodes from a graph. +type NodeRemover interface { + // RemoveNode removes a node from the graph, as + // well as any edges attached to it. If the node + // is not in the graph it is a no-op. + RemoveNode(Node) +} + +// EdgeSetter is an interface for adding edges to a graph. +type EdgeSetter interface { + // SetEdge adds an edge from one node to another. + // If the graph supports node addition the nodes + // will be added if they do not exist, otherwise + // SetEdge will panic. + // If the IDs returned by e.From and e.To are + // equal, SetEdge will panic. + SetEdge(e Edge) +} + +// EdgeRemover is an interface for removing nodes from a graph. +type EdgeRemover interface { + // RemoveEdge removes the given edge, leaving the + // terminal nodes. If the edge does not exist it + // is a no-op. + RemoveEdge(Edge) +} + +// Builder is a graph that can have nodes and edges added. +type Builder interface { + NodeAdder + EdgeSetter +} + +// UndirectedBuilder is an undirected graph builder. +type UndirectedBuilder interface { + Undirected + Builder +} + +// DirectedBuilder is a directed graph builder. +type DirectedBuilder interface { + Directed + Builder +} + +// Copy copies nodes and edges as undirected edges from the source to the destination +// without first clearing the destination. Copy will panic if a node ID in the source +// graph matches a node ID in the destination. +// +// If the source is undirected and the destination is directed both directions will +// be present in the destination after the copy is complete. +// +// If the source is a directed graph, the destination is undirected, and a fundamental +// cycle exists with two nodes where the edge weights differ, the resulting destination +// graph's edge weight between those nodes is undefined. If there is a defined function +// to resolve such conflicts, an Undirect may be used to do this. +func Copy(dst Builder, src Graph) { + nodes := src.Nodes() + for _, n := range nodes { + dst.AddNode(n) + } + for _, u := range nodes { + for _, v := range src.From(u) { + dst.SetEdge(src.Edge(u, v)) + } + } +} diff --git a/third_party/forked/gonum/graph/internal/linear/BUILD b/third_party/forked/gonum/graph/internal/linear/BUILD new file mode 100644 index 0000000000000..95b086fd354bc --- /dev/null +++ b/third_party/forked/gonum/graph/internal/linear/BUILD @@ -0,0 +1,28 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["linear.go"], + tags = ["automanaged"], + deps = ["//third_party/forked/gonum/graph:go_default_library"], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/third_party/forked/gonum/graph/internal/linear/linear.go b/third_party/forked/gonum/graph/internal/linear/linear.go new file mode 100644 index 0000000000000..ce7c6cfffdfd8 --- /dev/null +++ b/third_party/forked/gonum/graph/internal/linear/linear.go @@ -0,0 +1,74 @@ +// Copyright ©2015 The gonum Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// Package linear provides common linear data structures. +package linear + +import ( + "k8s.io/kubernetes/third_party/forked/gonum/graph" +) + +// NodeStack implements a LIFO stack of graph.Node. +type NodeStack []graph.Node + +// Len returns the number of graph.Nodes on the stack. +func (s *NodeStack) Len() int { return len(*s) } + +// Pop returns the last graph.Node on the stack and removes it +// from the stack. +func (s *NodeStack) Pop() graph.Node { + v := *s + v, n := v[:len(v)-1], v[len(v)-1] + *s = v + return n +} + +// Push adds the node n to the stack at the last position. +func (s *NodeStack) Push(n graph.Node) { *s = append(*s, n) } + +// NodeQueue implements a FIFO queue. +type NodeQueue struct { + head int + data []graph.Node +} + +// Len returns the number of graph.Nodes in the queue. +func (q *NodeQueue) Len() int { return len(q.data) - q.head } + +// Enqueue adds the node n to the back of the queue. +func (q *NodeQueue) Enqueue(n graph.Node) { + if len(q.data) == cap(q.data) && q.head > 0 { + l := q.Len() + copy(q.data, q.data[q.head:]) + q.head = 0 + q.data = append(q.data[:l], n) + } else { + q.data = append(q.data, n) + } +} + +// Dequeue returns the graph.Node at the front of the queue and +// removes it from the queue. +func (q *NodeQueue) Dequeue() graph.Node { + if q.Len() == 0 { + panic("queue: empty queue") + } + + var n graph.Node + n, q.data[q.head] = q.data[q.head], nil + q.head++ + + if q.Len() == 0 { + q.head = 0 + q.data = q.data[:0] + } + + return n +} + +// Reset clears the queue for reuse. +func (q *NodeQueue) Reset() { + q.head = 0 + q.data = q.data[:0] +} diff --git a/third_party/forked/gonum/graph/simple/BUILD b/third_party/forked/gonum/graph/simple/BUILD new file mode 100644 index 0000000000000..092f84cb823d6 --- /dev/null +++ b/third_party/forked/gonum/graph/simple/BUILD @@ -0,0 +1,49 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "directed_acyclic_test.go", + "edgeholder_test.go", + "undirected_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = ["//third_party/forked/gonum/graph:go_default_library"], +) + +go_library( + name = "go_default_library", + srcs = [ + "directed_acyclic.go", + "edgeholder.go", + "simple.go", + "undirected.go", + ], + tags = ["automanaged"], + deps = [ + "//third_party/forked/gonum/graph:go_default_library", + "//vendor/golang.org/x/tools/container/intsets:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/third_party/forked/gonum/graph/simple/directed_acyclic.go b/third_party/forked/gonum/graph/simple/directed_acyclic.go new file mode 100644 index 0000000000000..ac930feb169f9 --- /dev/null +++ b/third_party/forked/gonum/graph/simple/directed_acyclic.go @@ -0,0 +1,83 @@ +package simple + +import ( + "k8s.io/kubernetes/third_party/forked/gonum/graph" +) + +// DirectedAcyclicGraph implements graph.Directed using UndirectedGraph, +// which only stores one edge for any node pair. +type DirectedAcyclicGraph struct { + *UndirectedGraph +} + +func NewDirectedAcyclicGraph(self, absent float64) *DirectedAcyclicGraph { + return &DirectedAcyclicGraph{ + UndirectedGraph: NewUndirectedGraph(self, absent), + } +} + +func (g *DirectedAcyclicGraph) HasEdgeFromTo(u, v graph.Node) bool { + edge := g.UndirectedGraph.EdgeBetween(u, v) + if edge == nil { + return false + } + return (edge.From().ID() == u.ID()) +} + +func (g *DirectedAcyclicGraph) From(n graph.Node) []graph.Node { + if !g.Has(n) { + return nil + } + + fid := n.ID() + nodes := make([]graph.Node, 0, g.UndirectedGraph.edges[n.ID()].Len()) + g.UndirectedGraph.edges[n.ID()].Visit(func(neighbor int, edge graph.Edge) { + if edge.From().ID() == fid { + nodes = append(nodes, g.UndirectedGraph.nodes[edge.To().ID()]) + } + }) + return nodes +} + +func (g *DirectedAcyclicGraph) VisitFrom(n graph.Node, visitor func(neighbor graph.Node) (shouldContinue bool)) { + if !g.Has(n) { + return + } + fid := n.ID() + g.UndirectedGraph.edges[n.ID()].Visit(func(neighbor int, edge graph.Edge) { + if edge.From().ID() == fid { + if !visitor(g.UndirectedGraph.nodes[edge.To().ID()]) { + return + } + } + }) +} + +func (g *DirectedAcyclicGraph) To(n graph.Node) []graph.Node { + if !g.Has(n) { + return nil + } + + tid := n.ID() + nodes := make([]graph.Node, 0, g.UndirectedGraph.edges[n.ID()].Len()) + g.UndirectedGraph.edges[n.ID()].Visit(func(neighbor int, edge graph.Edge) { + if edge.To().ID() == tid { + nodes = append(nodes, g.UndirectedGraph.nodes[edge.From().ID()]) + } + }) + return nodes +} + +func (g *DirectedAcyclicGraph) VisitTo(n graph.Node, visitor func(neighbor graph.Node) (shouldContinue bool)) { + if !g.Has(n) { + return + } + tid := n.ID() + g.UndirectedGraph.edges[n.ID()].Visit(func(neighbor int, edge graph.Edge) { + if edge.To().ID() == tid { + if !visitor(g.UndirectedGraph.nodes[edge.From().ID()]) { + return + } + } + }) +} diff --git a/third_party/forked/gonum/graph/simple/directed_acyclic_test.go b/third_party/forked/gonum/graph/simple/directed_acyclic_test.go new file mode 100644 index 0000000000000..0f3454d8a71e0 --- /dev/null +++ b/third_party/forked/gonum/graph/simple/directed_acyclic_test.go @@ -0,0 +1,62 @@ +// Copyright ©2014 The gonum Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package simple + +import ( + "math" + "testing" + + "k8s.io/kubernetes/third_party/forked/gonum/graph" +) + +var _ graph.Graph = &DirectedAcyclicGraph{} +var _ graph.Directed = &DirectedAcyclicGraph{} + +// Tests Issue #27 +func TestAcyclicEdgeOvercounting(t *testing.T) { + g := generateDummyAcyclicGraph() + + if neigh := g.From(Node(Node(2))); len(neigh) != 2 { + t.Errorf("Node 2 has incorrect number of neighbors got neighbors %v (count %d), expected 2 neighbors {0,1}", neigh, len(neigh)) + } +} + +func generateDummyAcyclicGraph() *DirectedAcyclicGraph { + nodes := [4]struct{ srcID, targetID int }{ + {2, 1}, + {1, 0}, + {0, 2}, + {2, 0}, + } + + g := NewDirectedAcyclicGraph(0, math.Inf(1)) + + for _, n := range nodes { + g.SetEdge(Edge{F: Node(n.srcID), T: Node(n.targetID), W: 1}) + } + + return g +} + +// Test for issue #123 https://github.com/gonum/graph/issues/123 +func TestAcyclicIssue123DirectedGraph(t *testing.T) { + defer func() { + if r := recover(); r != nil { + t.Errorf("unexpected panic: %v", r) + } + }() + g := NewDirectedAcyclicGraph(0, math.Inf(1)) + + n0 := Node(g.NewNodeID()) + g.AddNode(n0) + + n1 := Node(g.NewNodeID()) + g.AddNode(n1) + + g.RemoveNode(n0) + + n2 := Node(g.NewNodeID()) + g.AddNode(n2) +} diff --git a/third_party/forked/gonum/graph/simple/edgeholder.go b/third_party/forked/gonum/graph/simple/edgeholder.go new file mode 100644 index 0000000000000..f2248ab7db982 --- /dev/null +++ b/third_party/forked/gonum/graph/simple/edgeholder.go @@ -0,0 +1,122 @@ +package simple + +import "k8s.io/kubernetes/third_party/forked/gonum/graph" + +// edgeHolder represents a set of edges, with no more than one edge to or from a particular neighbor node +type edgeHolder interface { + // Visit invokes visitor with each edge and the id of the neighbor node in the edge + Visit(visitor func(neighbor int, edge graph.Edge)) + // Delete removes edges to or from the specified neighbor + Delete(neighbor int) edgeHolder + // Set stores the edge to or from the specified neighbor + Set(neighbor int, edge graph.Edge) edgeHolder + // Get returns the edge to or from the specified neighbor + Get(neighbor int) (graph.Edge, bool) + // Len returns the number of edges + Len() int +} + +// sliceEdgeHolder holds a list of edges to or from self +type sliceEdgeHolder struct { + self int + edges []graph.Edge +} + +func (e *sliceEdgeHolder) Visit(visitor func(neighbor int, edge graph.Edge)) { + for _, edge := range e.edges { + if edge.From().ID() == e.self { + visitor(edge.To().ID(), edge) + } else { + visitor(edge.From().ID(), edge) + } + } +} +func (e *sliceEdgeHolder) Delete(neighbor int) edgeHolder { + edges := e.edges[:0] + for i, edge := range e.edges { + if edge.From().ID() == e.self { + if edge.To().ID() == neighbor { + continue + } + } else { + if edge.From().ID() == neighbor { + continue + } + } + edges = append(edges, e.edges[i]) + } + e.edges = edges + return e +} +func (e *sliceEdgeHolder) Set(neighbor int, newEdge graph.Edge) edgeHolder { + for i, edge := range e.edges { + if edge.From().ID() == e.self { + if edge.To().ID() == neighbor { + e.edges[i] = newEdge + return e + } + } else { + if edge.From().ID() == neighbor { + e.edges[i] = newEdge + return e + } + } + } + + if len(e.edges) < 4 { + e.edges = append(e.edges, newEdge) + return e + } + + h := mapEdgeHolder(make(map[int]graph.Edge, len(e.edges)+1)) + for i, edge := range e.edges { + if edge.From().ID() == e.self { + h[edge.To().ID()] = e.edges[i] + } else { + h[edge.From().ID()] = e.edges[i] + } + } + h[neighbor] = newEdge + return h +} +func (e *sliceEdgeHolder) Get(neighbor int) (graph.Edge, bool) { + for _, edge := range e.edges { + if edge.From().ID() == e.self { + if edge.To().ID() == neighbor { + return edge, true + } + } else { + if edge.From().ID() == neighbor { + return edge, true + } + } + } + return nil, false +} +func (e *sliceEdgeHolder) Len() int { + return len(e.edges) +} + +// mapEdgeHolder holds a map of neighbors to edges +type mapEdgeHolder map[int]graph.Edge + +func (e mapEdgeHolder) Visit(visitor func(neighbor int, edge graph.Edge)) { + for neighbor, edge := range e { + visitor(neighbor, edge) + } +} +func (e mapEdgeHolder) Delete(neighbor int) edgeHolder { + delete(e, neighbor) + return e +} +func (e mapEdgeHolder) Set(neighbor int, edge graph.Edge) edgeHolder { + e[neighbor] = edge + return e +} +func (e mapEdgeHolder) Get(neighbor int) (graph.Edge, bool) { + edge, ok := e[neighbor] + return edge, ok +} +func (e mapEdgeHolder) Len() int { + return len(e) +} diff --git a/third_party/forked/gonum/graph/simple/edgeholder_test.go b/third_party/forked/gonum/graph/simple/edgeholder_test.go new file mode 100644 index 0000000000000..6c9be3750004d --- /dev/null +++ b/third_party/forked/gonum/graph/simple/edgeholder_test.go @@ -0,0 +1,104 @@ +package simple + +import ( + "reflect" + "sort" + "testing" + + "k8s.io/kubernetes/third_party/forked/gonum/graph" +) + +func TestEdgeHolder(t *testing.T) { + holder := edgeHolder(&sliceEdgeHolder{self: 1}) + + // Empty tests + if len := holder.Len(); len != 0 { + t.Errorf("expected 0") + } + if n, ok := holder.Get(2); ok || n != nil { + t.Errorf("expected nil,false") + } + holder.Visit(func(_ int, _ graph.Edge) { t.Errorf("unexpected call to visitor") }) + holder = holder.Delete(2) + + // Insert an edge to ourselves + holder = holder.Set(1, Edge{F: Node(1), T: Node(1)}) + if len := holder.Len(); len != 1 { + t.Errorf("expected 1") + } + if n, ok := holder.Get(1); !ok || n == nil || n.From().ID() != 1 || n.To().ID() != 1 { + t.Errorf("expected edge to ourselves, got %#v", n) + } + neighbors := []int{} + holder.Visit(func(neighbor int, _ graph.Edge) { neighbors = append(neighbors, neighbor) }) + if !reflect.DeepEqual(neighbors, []int{1}) { + t.Errorf("expected a single visit to ourselves, got %v", neighbors) + } + + // Insert edges from us to other nodes + holder = holder.Set(2, Edge{F: Node(1), T: Node(2)}) + holder = holder.Set(3, Edge{F: Node(1), T: Node(3)}) + holder = holder.Set(4, Edge{F: Node(1), T: Node(4)}) + if len := holder.Len(); len != 4 { + t.Errorf("expected 4") + } + if n, ok := holder.Get(2); !ok || n == nil || n.From().ID() != 1 || n.To().ID() != 2 { + t.Errorf("expected edge from us to another node, got %#v", n) + } + neighbors = []int{} + holder.Visit(func(neighbor int, _ graph.Edge) { neighbors = append(neighbors, neighbor) }) + if !reflect.DeepEqual(neighbors, []int{1, 2, 3, 4}) { + t.Errorf("expected a single visit to ourselves, got %v", neighbors) + } + + // Insert edges to us to other nodes + holder = holder.Set(2, Edge{F: Node(2), T: Node(1)}) + holder = holder.Set(3, Edge{F: Node(3), T: Node(1)}) + holder = holder.Set(4, Edge{F: Node(4), T: Node(1)}) + if len := holder.Len(); len != 4 { + t.Errorf("expected 4") + } + if n, ok := holder.Get(2); !ok || n == nil || n.From().ID() != 2 || n.To().ID() != 1 { + t.Errorf("expected reversed edge, got %#v", n) + } + neighbors = []int{} + holder.Visit(func(neighbor int, _ graph.Edge) { neighbors = append(neighbors, neighbor) }) + if !reflect.DeepEqual(neighbors, []int{1, 2, 3, 4}) { + t.Errorf("expected a single visit to ourselves, got %v", neighbors) + } + + if _, ok := holder.(*sliceEdgeHolder); !ok { + t.Errorf("expected slice edge holder") + } + + // Make the transition to a map + holder = holder.Set(5, Edge{F: Node(5), T: Node(1)}) + + if _, ok := holder.(mapEdgeHolder); !ok { + t.Errorf("expected map edge holder") + } + if len := holder.Len(); len != 5 { + t.Errorf("expected 5") + } + if n, ok := holder.Get(2); !ok || n == nil || n.From().ID() != 2 || n.To().ID() != 1 { + t.Errorf("expected old edges, got %#v", n) + } + if n, ok := holder.Get(5); !ok || n == nil || n.From().ID() != 5 || n.To().ID() != 1 { + t.Errorf("expected new edge, got %#v", n) + } + neighbors = []int{} + holder.Visit(func(neighbor int, _ graph.Edge) { neighbors = append(neighbors, neighbor) }) + sort.Ints(neighbors) // sort, map order is random + if !reflect.DeepEqual(neighbors, []int{1, 2, 3, 4, 5}) { + t.Errorf("expected 1,2,3,4,5, got %v", neighbors) + } + holder = holder.Delete(1) + holder = holder.Delete(2) + holder = holder.Delete(3) + holder = holder.Delete(4) + holder = holder.Delete(5) + holder = holder.Delete(6) + if len := holder.Len(); len != 0 { + t.Errorf("expected 0") + } +} diff --git a/third_party/forked/gonum/graph/simple/simple.go b/third_party/forked/gonum/graph/simple/simple.go new file mode 100644 index 0000000000000..9bc56b8be63a9 --- /dev/null +++ b/third_party/forked/gonum/graph/simple/simple.go @@ -0,0 +1,45 @@ +// Copyright ©2014 The gonum Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// Package simple provides a suite of simple graph implementations satisfying +// the gonum/graph interfaces. +package simple + +import ( + "math" + + "k8s.io/kubernetes/third_party/forked/gonum/graph" +) + +// Node is a simple graph node. +type Node int + +// ID returns the ID number of the node. +func (n Node) ID() int { + return int(n) +} + +// Edge is a simple graph edge. +type Edge struct { + F, T graph.Node + W float64 +} + +// From returns the from-node of the edge. +func (e Edge) From() graph.Node { return e.F } + +// To returns the to-node of the edge. +func (e Edge) To() graph.Node { return e.T } + +// Weight returns the weight of the edge. +func (e Edge) Weight() float64 { return e.W } + +// maxInt is the maximum value of the machine-dependent int type. +const maxInt int = int(^uint(0) >> 1) + +// isSame returns whether two float64 values are the same where NaN values +// are equalable. +func isSame(a, b float64) bool { + return a == b || (math.IsNaN(a) && math.IsNaN(b)) +} diff --git a/third_party/forked/gonum/graph/simple/undirected.go b/third_party/forked/gonum/graph/simple/undirected.go new file mode 100644 index 0000000000000..231fa3deda49d --- /dev/null +++ b/third_party/forked/gonum/graph/simple/undirected.go @@ -0,0 +1,242 @@ +// Copyright ©2014 The gonum Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package simple + +import ( + "fmt" + + "golang.org/x/tools/container/intsets" + + "k8s.io/kubernetes/third_party/forked/gonum/graph" +) + +// UndirectedGraph implements a generalized undirected graph. +type UndirectedGraph struct { + nodes map[int]graph.Node + edges map[int]edgeHolder + + self, absent float64 + + freeIDs intsets.Sparse + usedIDs intsets.Sparse +} + +// NewUndirectedGraph returns an UndirectedGraph with the specified self and absent +// edge weight values. +func NewUndirectedGraph(self, absent float64) *UndirectedGraph { + return &UndirectedGraph{ + nodes: make(map[int]graph.Node), + edges: make(map[int]edgeHolder), + + self: self, + absent: absent, + } +} + +// NewNodeID returns a new unique ID for a node to be added to g. The returned ID does +// not become a valid ID in g until it is added to g. +func (g *UndirectedGraph) NewNodeID() int { + if len(g.nodes) == 0 { + return 0 + } + if len(g.nodes) == maxInt { + panic(fmt.Sprintf("simple: cannot allocate node: no slot")) + } + + var id int + if g.freeIDs.Len() != 0 && g.freeIDs.TakeMin(&id) { + return id + } + if id = g.usedIDs.Max(); id < maxInt { + return id + 1 + } + for id = 0; id < maxInt; id++ { + if !g.usedIDs.Has(id) { + return id + } + } + panic("unreachable") +} + +// AddNode adds n to the graph. It panics if the added node ID matches an existing node ID. +func (g *UndirectedGraph) AddNode(n graph.Node) { + if _, exists := g.nodes[n.ID()]; exists { + panic(fmt.Sprintf("simple: node ID collision: %d", n.ID())) + } + g.nodes[n.ID()] = n + g.edges[n.ID()] = &sliceEdgeHolder{self: n.ID()} + + g.freeIDs.Remove(n.ID()) + g.usedIDs.Insert(n.ID()) +} + +// RemoveNode removes n from the graph, as well as any edges attached to it. If the node +// is not in the graph it is a no-op. +func (g *UndirectedGraph) RemoveNode(n graph.Node) { + if _, ok := g.nodes[n.ID()]; !ok { + return + } + delete(g.nodes, n.ID()) + + g.edges[n.ID()].Visit(func(neighbor int, edge graph.Edge) { + g.edges[neighbor] = g.edges[neighbor].Delete(n.ID()) + }) + delete(g.edges, n.ID()) + + g.freeIDs.Insert(n.ID()) + g.usedIDs.Remove(n.ID()) + +} + +// SetEdge adds e, an edge from one node to another. If the nodes do not exist, they are added. +// It will panic if the IDs of the e.From and e.To are equal. +func (g *UndirectedGraph) SetEdge(e graph.Edge) { + var ( + from = e.From() + fid = from.ID() + to = e.To() + tid = to.ID() + ) + + if fid == tid { + panic("simple: adding self edge") + } + + if !g.Has(from) { + g.AddNode(from) + } + if !g.Has(to) { + g.AddNode(to) + } + + g.edges[fid] = g.edges[fid].Set(tid, e) + g.edges[tid] = g.edges[tid].Set(fid, e) +} + +// RemoveEdge removes e from the graph, leaving the terminal nodes. If the edge does not exist +// it is a no-op. +func (g *UndirectedGraph) RemoveEdge(e graph.Edge) { + from, to := e.From(), e.To() + if _, ok := g.nodes[from.ID()]; !ok { + return + } + if _, ok := g.nodes[to.ID()]; !ok { + return + } + + g.edges[from.ID()] = g.edges[from.ID()].Delete(to.ID()) + g.edges[to.ID()] = g.edges[to.ID()].Delete(from.ID()) +} + +// Node returns the node in the graph with the given ID. +func (g *UndirectedGraph) Node(id int) graph.Node { + return g.nodes[id] +} + +// Has returns whether the node exists within the graph. +func (g *UndirectedGraph) Has(n graph.Node) bool { + _, ok := g.nodes[n.ID()] + return ok +} + +// Nodes returns all the nodes in the graph. +func (g *UndirectedGraph) Nodes() []graph.Node { + nodes := make([]graph.Node, len(g.nodes)) + i := 0 + for _, n := range g.nodes { + nodes[i] = n + i++ + } + + return nodes +} + +// Edges returns all the edges in the graph. +func (g *UndirectedGraph) Edges() []graph.Edge { + var edges []graph.Edge + + seen := make(map[[2]int]struct{}) + for _, u := range g.edges { + u.Visit(func(neighbor int, e graph.Edge) { + uid := e.From().ID() + vid := e.To().ID() + if _, ok := seen[[2]int{uid, vid}]; ok { + return + } + seen[[2]int{uid, vid}] = struct{}{} + seen[[2]int{vid, uid}] = struct{}{} + edges = append(edges, e) + }) + } + + return edges +} + +// From returns all nodes in g that can be reached directly from n. +func (g *UndirectedGraph) From(n graph.Node) []graph.Node { + if !g.Has(n) { + return nil + } + + nodes := make([]graph.Node, g.edges[n.ID()].Len()) + i := 0 + g.edges[n.ID()].Visit(func(neighbor int, edge graph.Edge) { + nodes[i] = g.nodes[neighbor] + i++ + }) + + return nodes +} + +// HasEdgeBetween returns whether an edge exists between nodes x and y. +func (g *UndirectedGraph) HasEdgeBetween(x, y graph.Node) bool { + _, ok := g.edges[x.ID()].Get(y.ID()) + return ok +} + +// Edge returns the edge from u to v if such an edge exists and nil otherwise. +// The node v must be directly reachable from u as defined by the From method. +func (g *UndirectedGraph) Edge(u, v graph.Node) graph.Edge { + return g.EdgeBetween(u, v) +} + +// EdgeBetween returns the edge between nodes x and y. +func (g *UndirectedGraph) EdgeBetween(x, y graph.Node) graph.Edge { + // We don't need to check if neigh exists because + // it's implicit in the edges access. + if !g.Has(x) { + return nil + } + + edge, _ := g.edges[x.ID()].Get(y.ID()) + return edge +} + +// Weight returns the weight for the edge between x and y if Edge(x, y) returns a non-nil Edge. +// If x and y are the same node or there is no joining edge between the two nodes the weight +// value returned is either the graph's absent or self value. Weight returns true if an edge +// exists between x and y or if x and y have the same ID, false otherwise. +func (g *UndirectedGraph) Weight(x, y graph.Node) (w float64, ok bool) { + xid := x.ID() + yid := y.ID() + if xid == yid { + return g.self, true + } + if n, ok := g.edges[xid]; ok { + if e, ok := n.Get(yid); ok { + return e.Weight(), true + } + } + return g.absent, false +} + +// Degree returns the degree of n in g. +func (g *UndirectedGraph) Degree(n graph.Node) int { + if _, ok := g.nodes[n.ID()]; !ok { + return 0 + } + + return g.edges[n.ID()].Len() +} diff --git a/third_party/forked/gonum/graph/simple/undirected_test.go b/third_party/forked/gonum/graph/simple/undirected_test.go new file mode 100644 index 0000000000000..42c1f6061702b --- /dev/null +++ b/third_party/forked/gonum/graph/simple/undirected_test.go @@ -0,0 +1,63 @@ +// Copyright ©2014 The gonum Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package simple + +import ( + "math" + "testing" + + "k8s.io/kubernetes/third_party/forked/gonum/graph" +) + +var _ graph.Graph = (*UndirectedGraph)(nil) + +func TestAssertMutableNotDirected(t *testing.T) { + var g graph.UndirectedBuilder = NewUndirectedGraph(0, math.Inf(1)) + if _, ok := g.(graph.Directed); ok { + t.Fatal("Graph is directed, but a MutableGraph cannot safely be directed!") + } +} + +func TestMaxID(t *testing.T) { + g := NewUndirectedGraph(0, math.Inf(1)) + nodes := make(map[graph.Node]struct{}) + for i := Node(0); i < 3; i++ { + g.AddNode(i) + nodes[i] = struct{}{} + } + g.RemoveNode(Node(0)) + delete(nodes, Node(0)) + g.RemoveNode(Node(2)) + delete(nodes, Node(2)) + n := Node(g.NewNodeID()) + g.AddNode(n) + if !g.Has(n) { + t.Error("added node does not exist in graph") + } + if _, exists := nodes[n]; exists { + t.Errorf("Created already existing node id: %v", n.ID()) + } +} + +// Test for issue #123 https://github.com/gonum/graph/issues/123 +func TestIssue123UndirectedGraph(t *testing.T) { + defer func() { + if r := recover(); r != nil { + t.Errorf("unexpected panic: %v", r) + } + }() + g := NewUndirectedGraph(0, math.Inf(1)) + + n0 := Node(g.NewNodeID()) + g.AddNode(n0) + + n1 := Node(g.NewNodeID()) + g.AddNode(n1) + + g.RemoveNode(n0) + + n2 := Node(g.NewNodeID()) + g.AddNode(n2) +} diff --git a/third_party/forked/gonum/graph/traverse/BUILD b/third_party/forked/gonum/graph/traverse/BUILD new file mode 100644 index 0000000000000..e0eb285a76198 --- /dev/null +++ b/third_party/forked/gonum/graph/traverse/BUILD @@ -0,0 +1,35 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "traverse.go", + "visit_depth_first.go", + ], + tags = ["automanaged"], + deps = [ + "//third_party/forked/gonum/graph:go_default_library", + "//third_party/forked/gonum/graph/internal/linear:go_default_library", + "//vendor/golang.org/x/tools/container/intsets:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/third_party/forked/gonum/graph/traverse/traverse.go b/third_party/forked/gonum/graph/traverse/traverse.go new file mode 100644 index 0000000000000..cc361c85fe35b --- /dev/null +++ b/third_party/forked/gonum/graph/traverse/traverse.go @@ -0,0 +1,186 @@ +// Copyright ©2015 The gonum Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// Package traverse provides basic graph traversal primitives. +package traverse + +import ( + "golang.org/x/tools/container/intsets" + + "k8s.io/kubernetes/third_party/forked/gonum/graph" + "k8s.io/kubernetes/third_party/forked/gonum/graph/internal/linear" +) + +// BreadthFirst implements stateful breadth-first graph traversal. +type BreadthFirst struct { + EdgeFilter func(graph.Edge) bool + Visit func(u, v graph.Node) + queue linear.NodeQueue + visited *intsets.Sparse +} + +// Walk performs a breadth-first traversal of the graph g starting from the given node, +// depending on the the EdgeFilter field and the until parameter if they are non-nil. The +// traversal follows edges for which EdgeFilter(edge) is true and returns the first node +// for which until(node, depth) is true. During the traversal, if the Visit field is +// non-nil, it is called with the nodes joined by each followed edge. +func (b *BreadthFirst) Walk(g graph.Graph, from graph.Node, until func(n graph.Node, d int) bool) graph.Node { + if b.visited == nil { + b.visited = &intsets.Sparse{} + } + b.queue.Enqueue(from) + b.visited.Insert(from.ID()) + + var ( + depth int + children int + untilNext = 1 + ) + for b.queue.Len() > 0 { + t := b.queue.Dequeue() + if until != nil && until(t, depth) { + return t + } + for _, n := range g.From(t) { + if b.EdgeFilter != nil && !b.EdgeFilter(g.Edge(t, n)) { + continue + } + if b.visited.Has(n.ID()) { + continue + } + if b.Visit != nil { + b.Visit(t, n) + } + b.visited.Insert(n.ID()) + children++ + b.queue.Enqueue(n) + } + if untilNext--; untilNext == 0 { + depth++ + untilNext = children + children = 0 + } + } + + return nil +} + +// WalkAll calls Walk for each unvisited node of the graph g using edges independent +// of their direction. The functions before and after are called prior to commencing +// and after completing each walk if they are non-nil respectively. The function +// during is called on each node as it is traversed. +func (b *BreadthFirst) WalkAll(g graph.Undirected, before, after func(), during func(graph.Node)) { + b.Reset() + for _, from := range g.Nodes() { + if b.Visited(from) { + continue + } + if before != nil { + before() + } + b.Walk(g, from, func(n graph.Node, _ int) bool { + if during != nil { + during(n) + } + return false + }) + if after != nil { + after() + } + } +} + +// Visited returned whether the node n was visited during a traverse. +func (b *BreadthFirst) Visited(n graph.Node) bool { + return b.visited != nil && b.visited.Has(n.ID()) +} + +// Reset resets the state of the traverser for reuse. +func (b *BreadthFirst) Reset() { + b.queue.Reset() + if b.visited != nil { + b.visited.Clear() + } +} + +// DepthFirst implements stateful depth-first graph traversal. +type DepthFirst struct { + EdgeFilter func(graph.Edge) bool + Visit func(u, v graph.Node) + stack linear.NodeStack + visited *intsets.Sparse +} + +// Walk performs a depth-first traversal of the graph g starting from the given node, +// depending on the the EdgeFilter field and the until parameter if they are non-nil. The +// traversal follows edges for which EdgeFilter(edge) is true and returns the first node +// for which until(node) is true. During the traversal, if the Visit field is non-nil, it +// is called with the nodes joined by each followed edge. +func (d *DepthFirst) Walk(g graph.Graph, from graph.Node, until func(graph.Node) bool) graph.Node { + if d.visited == nil { + d.visited = &intsets.Sparse{} + } + d.stack.Push(from) + d.visited.Insert(from.ID()) + + for d.stack.Len() > 0 { + t := d.stack.Pop() + if until != nil && until(t) { + return t + } + for _, n := range g.From(t) { + if d.EdgeFilter != nil && !d.EdgeFilter(g.Edge(t, n)) { + continue + } + if d.visited.Has(n.ID()) { + continue + } + if d.Visit != nil { + d.Visit(t, n) + } + d.visited.Insert(n.ID()) + d.stack.Push(n) + } + } + + return nil +} + +// WalkAll calls Walk for each unvisited node of the graph g using edges independent +// of their direction. The functions before and after are called prior to commencing +// and after completing each walk if they are non-nil respectively. The function +// during is called on each node as it is traversed. +func (d *DepthFirst) WalkAll(g graph.Undirected, before, after func(), during func(graph.Node)) { + d.Reset() + for _, from := range g.Nodes() { + if d.Visited(from) { + continue + } + if before != nil { + before() + } + d.Walk(g, from, func(n graph.Node) bool { + if during != nil { + during(n) + } + return false + }) + if after != nil { + after() + } + } +} + +// Visited returned whether the node n was visited during a traverse. +func (d *DepthFirst) Visited(n graph.Node) bool { + return d.visited != nil && d.visited.Has(n.ID()) +} + +// Reset resets the state of the traverser for reuse. +func (d *DepthFirst) Reset() { + d.stack = d.stack[:0] + if d.visited != nil { + d.visited.Clear() + } +} diff --git a/third_party/forked/gonum/graph/traverse/visit_depth_first.go b/third_party/forked/gonum/graph/traverse/visit_depth_first.go new file mode 100644 index 0000000000000..b7f45a7b32186 --- /dev/null +++ b/third_party/forked/gonum/graph/traverse/visit_depth_first.go @@ -0,0 +1,86 @@ +// Copyright ©2015 The gonum Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// Package traverse provides basic graph traversal primitives. +package traverse + +import ( + "golang.org/x/tools/container/intsets" + + "k8s.io/kubernetes/third_party/forked/gonum/graph" + "k8s.io/kubernetes/third_party/forked/gonum/graph/internal/linear" +) + +// VisitableGraph +type VisitableGraph interface { + graph.Graph + + // VisitFrom invokes visitor with all nodes that can be reached directly from the given node. + // If visitor returns false, visiting is short-circuited. + VisitFrom(from graph.Node, visitor func(graph.Node) (shouldContinue bool)) +} + +// VisitingDepthFirst implements stateful depth-first graph traversal on a visitable graph. +type VisitingDepthFirst struct { + EdgeFilter func(graph.Edge) bool + Visit func(u, v graph.Node) + stack linear.NodeStack + visited *intsets.Sparse +} + +// Walk performs a depth-first traversal of the graph g starting from the given node, +// depending on the the EdgeFilter field and the until parameter if they are non-nil. The +// traversal follows edges for which EdgeFilter(edge) is true and returns the first node +// for which until(node) is true. During the traversal, if the Visit field is non-nil, it +// is called with the nodes joined by each followed edge. +func (d *VisitingDepthFirst) Walk(g VisitableGraph, from graph.Node, until func(graph.Node) bool) graph.Node { + if d.visited == nil { + d.visited = &intsets.Sparse{} + } + d.stack.Push(from) + d.visited.Insert(from.ID()) + if until != nil && until(from) { + return from + } + + var found graph.Node + for d.stack.Len() > 0 { + t := d.stack.Pop() + g.VisitFrom(t, func(n graph.Node) (shouldContinue bool) { + if d.EdgeFilter != nil && !d.EdgeFilter(g.Edge(t, n)) { + return true + } + if d.visited.Has(n.ID()) { + return true + } + if d.Visit != nil { + d.Visit(t, n) + } + d.visited.Insert(n.ID()) + d.stack.Push(n) + if until != nil && until(n) { + found = n + return false + } + return true + }) + if found != nil { + return found + } + } + return nil +} + +// Visited returned whether the node n was visited during a traverse. +func (d *VisitingDepthFirst) Visited(n graph.Node) bool { + return d.visited != nil && d.visited.Has(n.ID()) +} + +// Reset resets the state of the traverser for reuse. +func (d *VisitingDepthFirst) Reset() { + d.stack = d.stack[:0] + if d.visited != nil { + d.visited.Clear() + } +} diff --git a/translations/README.md b/translations/README.md index 59fe9c308e5bc..2091f50a1c8e9 100644 --- a/translations/README.md +++ b/translations/README.md @@ -23,7 +23,7 @@ Once the strings are wrapped, you can extract strings from go files using the `go-xgettext` command which can be installed with: ```console -go get github.com/gosexy/gettext/tree/master/go-xgettext +go get github.com/gosexy/gettext/go-xgettext ``` Once that's installed you can run `hack/update-translations.sh`, which diff --git a/vendor/BUILD b/vendor/BUILD index 9f91330aa7b03..89aeb8b66d740 100644 --- a/vendor/BUILD +++ b/vendor/BUILD @@ -346,6 +346,7 @@ filegroup( "//vendor/golang.org/x/text/unicode/norm:all-srcs", "//vendor/golang.org/x/text/width:all-srcs", "//vendor/golang.org/x/time/rate:all-srcs", + "//vendor/golang.org/x/tools/container/intsets:all-srcs", "//vendor/google.golang.org/api/cloudmonitoring/v2beta2:all-srcs", "//vendor/google.golang.org/api/compute/v0.alpha:all-srcs", "//vendor/google.golang.org/api/compute/v0.beta:all-srcs", diff --git a/vendor/golang.org/x/tools/AUTHORS b/vendor/golang.org/x/tools/AUTHORS new file mode 100644 index 0000000000000..15167cd746c56 --- /dev/null +++ b/vendor/golang.org/x/tools/AUTHORS @@ -0,0 +1,3 @@ +# This source code refers to The Go Authors for copyright purposes. +# The master list of authors is in the main Go distribution, +# visible at http://tip.golang.org/AUTHORS. diff --git a/vendor/golang.org/x/tools/CONTRIBUTORS b/vendor/golang.org/x/tools/CONTRIBUTORS new file mode 100644 index 0000000000000..1c4577e968061 --- /dev/null +++ b/vendor/golang.org/x/tools/CONTRIBUTORS @@ -0,0 +1,3 @@ +# This source code was written by the Go contributors. +# The master list of contributors is in the main Go distribution, +# visible at http://tip.golang.org/CONTRIBUTORS. diff --git a/vendor/golang.org/x/tools/LICENSE b/vendor/golang.org/x/tools/LICENSE new file mode 100644 index 0000000000000..6a66aea5eafe0 --- /dev/null +++ b/vendor/golang.org/x/tools/LICENSE @@ -0,0 +1,27 @@ +Copyright (c) 2009 The Go Authors. All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google Inc. nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/vendor/golang.org/x/tools/PATENTS b/vendor/golang.org/x/tools/PATENTS new file mode 100644 index 0000000000000..733099041f84f --- /dev/null +++ b/vendor/golang.org/x/tools/PATENTS @@ -0,0 +1,22 @@ +Additional IP Rights Grant (Patents) + +"This implementation" means the copyrightable works distributed by +Google as part of the Go project. + +Google hereby grants to You a perpetual, worldwide, non-exclusive, +no-charge, royalty-free, irrevocable (except as stated in this section) +patent license to make, have made, use, offer to sell, sell, import, +transfer and otherwise run, modify and propagate the contents of this +implementation of Go, where such license applies only to those patent +claims, both currently owned or controlled by Google and acquired in +the future, licensable by Google that are necessarily infringed by this +implementation of Go. This grant does not include claims that would be +infringed only as a consequence of further modification of this +implementation. If you or your agent or exclusive licensee institute or +order or agree to the institution of patent litigation against any +entity (including a cross-claim or counterclaim in a lawsuit) alleging +that this implementation of Go or any code incorporated within this +implementation of Go constitutes direct or contributory patent +infringement, or inducement of patent infringement, then any patent +rights granted to you under this License for this implementation of Go +shall terminate as of the date such litigation is filed. diff --git a/vendor/golang.org/x/tools/container/intsets/BUILD b/vendor/golang.org/x/tools/container/intsets/BUILD new file mode 100644 index 0000000000000..c6b2fa906a0c3 --- /dev/null +++ b/vendor/golang.org/x/tools/container/intsets/BUILD @@ -0,0 +1,32 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "popcnt_amd64.go", + "popcnt_amd64.s", + "sparse.go", + "util.go", + ], + tags = ["automanaged"], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/vendor/golang.org/x/tools/container/intsets/popcnt_amd64.go b/vendor/golang.org/x/tools/container/intsets/popcnt_amd64.go new file mode 100644 index 0000000000000..99ea813d28491 --- /dev/null +++ b/vendor/golang.org/x/tools/container/intsets/popcnt_amd64.go @@ -0,0 +1,20 @@ +// Copyright 2015 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build amd64,!appengine,!gccgo + +package intsets + +func popcnt(x word) int +func havePOPCNT() bool + +var hasPOPCNT = havePOPCNT() + +// popcount returns the population count (number of set bits) of x. +func popcount(x word) int { + if hasPOPCNT { + return popcnt(x) + } + return popcountTable(x) // faster than Hacker's Delight +} diff --git a/vendor/golang.org/x/tools/container/intsets/popcnt_amd64.s b/vendor/golang.org/x/tools/container/intsets/popcnt_amd64.s new file mode 100644 index 0000000000000..05c3d6fb573b2 --- /dev/null +++ b/vendor/golang.org/x/tools/container/intsets/popcnt_amd64.s @@ -0,0 +1,30 @@ +// Copyright 2015 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build amd64,!appengine,!gccgo + +#include "textflag.h" + +// func havePOPCNT() bool +TEXT ·havePOPCNT(SB),4,$0 + MOVQ $1, AX + CPUID + SHRQ $23, CX + ANDQ $1, CX + MOVB CX, ret+0(FP) + RET + +// func popcnt(word) int +TEXT ·popcnt(SB),NOSPLIT,$0-8 + XORQ AX, AX + MOVQ x+0(FP), SI + // POPCNT (SI), AX is not recognized by Go assembler, + // so we assemble it ourselves. + BYTE $0xf3 + BYTE $0x48 + BYTE $0x0f + BYTE $0xb8 + BYTE $0xc6 + MOVQ AX, ret+8(FP) + RET diff --git a/vendor/golang.org/x/tools/container/intsets/popcnt_gccgo.go b/vendor/golang.org/x/tools/container/intsets/popcnt_gccgo.go new file mode 100644 index 0000000000000..82a8875c85da7 --- /dev/null +++ b/vendor/golang.org/x/tools/container/intsets/popcnt_gccgo.go @@ -0,0 +1,9 @@ +// Copyright 2015 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build gccgo + +package intsets + +func popcount(x word) int diff --git a/vendor/golang.org/x/tools/container/intsets/popcnt_gccgo_c.c b/vendor/golang.org/x/tools/container/intsets/popcnt_gccgo_c.c new file mode 100644 index 0000000000000..08abb32ec46a7 --- /dev/null +++ b/vendor/golang.org/x/tools/container/intsets/popcnt_gccgo_c.c @@ -0,0 +1,19 @@ +// Copyright 2015 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build gccgo + +#include +#include +#include + +#define _STRINGIFY2_(x) #x +#define _STRINGIFY_(x) _STRINGIFY2_(x) +#define GOSYM_PREFIX _STRINGIFY_(__USER_LABEL_PREFIX__) + +extern intptr_t popcount(uintptr_t x) __asm__(GOSYM_PREFIX GOPKGPATH ".popcount"); + +intptr_t popcount(uintptr_t x) { + return __builtin_popcountl((unsigned long)(x)); +} diff --git a/vendor/golang.org/x/tools/container/intsets/popcnt_generic.go b/vendor/golang.org/x/tools/container/intsets/popcnt_generic.go new file mode 100644 index 0000000000000..3985a1da1a2f5 --- /dev/null +++ b/vendor/golang.org/x/tools/container/intsets/popcnt_generic.go @@ -0,0 +1,33 @@ +// Copyright 2015 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build !amd64 appengine +// +build !gccgo + +package intsets + +import "runtime" + +// We compared three algorithms---Hacker's Delight, table lookup, +// and AMD64's SSE4.1 hardware POPCNT---on a 2.67GHz Xeon X5550. +// +// % GOARCH=amd64 go test -run=NONE -bench=Popcount +// POPCNT 5.12 ns/op +// Table 8.53 ns/op +// HackersDelight 9.96 ns/op +// +// % GOARCH=386 go test -run=NONE -bench=Popcount +// Table 10.4 ns/op +// HackersDelight 5.23 ns/op +// +// (AMD64's ABM1 hardware supports ntz and nlz too, +// but they aren't critical.) + +// popcount returns the population count (number of set bits) of x. +func popcount(x word) int { + if runtime.GOARCH == "386" { + return popcountHD(uint32(x)) + } + return popcountTable(x) +} diff --git a/vendor/golang.org/x/tools/container/intsets/sparse.go b/vendor/golang.org/x/tools/container/intsets/sparse.go new file mode 100644 index 0000000000000..adcdf40d5ab55 --- /dev/null +++ b/vendor/golang.org/x/tools/container/intsets/sparse.go @@ -0,0 +1,967 @@ +// Copyright 2014 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// Package intsets provides Sparse, a compact and fast representation +// for sparse sets of int values. +// +// The time complexity of the operations Len, Insert, Remove and Has +// is in O(n) but in practice those methods are faster and more +// space-efficient than equivalent operations on sets based on the Go +// map type. The IsEmpty, Min, Max, Clear and TakeMin operations +// require constant time. +// +package intsets + +// TODO(adonovan): +// - Add InsertAll(...int), RemoveAll(...int) +// - Add 'bool changed' results for {Intersection,Difference}With too. +// +// TODO(adonovan): implement Dense, a dense bit vector with a similar API. +// The space usage would be proportional to Max(), not Len(), and the +// implementation would be based upon big.Int. +// +// TODO(adonovan): experiment with making the root block indirect (nil +// iff IsEmpty). This would reduce the memory usage when empty and +// might simplify the aliasing invariants. +// +// TODO(adonovan): opt: make UnionWith and Difference faster. +// These are the hot-spots for go/pointer. + +import ( + "bytes" + "fmt" +) + +// A Sparse is a set of int values. +// Sparse operations (even queries) are not concurrency-safe. +// +// The zero value for Sparse is a valid empty set. +// +// Sparse sets must be copied using the Copy method, not by assigning +// a Sparse value. +// +type Sparse struct { + // An uninitialized Sparse represents an empty set. + // An empty set may also be represented by + // root.next == root.prev == &root. + // In a non-empty set, root.next points to the first block and + // root.prev to the last. + // root.offset and root.bits are unused. + root block +} + +type word uintptr + +const ( + _m = ^word(0) + bitsPerWord = 8 << (_m>>8&1 + _m>>16&1 + _m>>32&1) + bitsPerBlock = 256 // optimal value for go/pointer solver performance + wordsPerBlock = bitsPerBlock / bitsPerWord +) + +// Limit values of implementation-specific int type. +const ( + MaxInt = int(^uint(0) >> 1) + MinInt = -MaxInt - 1 +) + +// -- block ------------------------------------------------------------ + +// A set is represented as a circular doubly-linked list of blocks, +// each containing an offset and a bit array of fixed size +// bitsPerBlock; the blocks are ordered by increasing offset. +// +// The set contains an element x iff the block whose offset is x - (x +// mod bitsPerBlock) has the bit (x mod bitsPerBlock) set, where mod +// is the Euclidean remainder. +// +// A block may only be empty transiently. +// +type block struct { + offset int // offset mod bitsPerBlock == 0 + bits [wordsPerBlock]word // contains at least one set bit + next, prev *block // doubly-linked list of blocks +} + +// wordMask returns the word index (in block.bits) +// and single-bit mask for the block's ith bit. +func wordMask(i uint) (w uint, mask word) { + w = i / bitsPerWord + mask = 1 << (i % bitsPerWord) + return +} + +// insert sets the block b's ith bit and +// returns true if it was not already set. +// +func (b *block) insert(i uint) bool { + w, mask := wordMask(i) + if b.bits[w]&mask == 0 { + b.bits[w] |= mask + return true + } + return false +} + +// remove clears the block's ith bit and +// returns true if the bit was previously set. +// NB: may leave the block empty. +// +func (b *block) remove(i uint) bool { + w, mask := wordMask(i) + if b.bits[w]&mask != 0 { + b.bits[w] &^= mask + return true + } + return false +} + +// has reports whether the block's ith bit is set. +func (b *block) has(i uint) bool { + w, mask := wordMask(i) + return b.bits[w]&mask != 0 +} + +// empty reports whether b.len()==0, but more efficiently. +func (b *block) empty() bool { + for _, w := range b.bits { + if w != 0 { + return false + } + } + return true +} + +// len returns the number of set bits in block b. +func (b *block) len() int { + var l int + for _, w := range b.bits { + l += popcount(w) + } + return l +} + +// max returns the maximum element of the block. +// The block must not be empty. +// +func (b *block) max() int { + bi := b.offset + bitsPerBlock + // Decrement bi by number of high zeros in last.bits. + for i := len(b.bits) - 1; i >= 0; i-- { + if w := b.bits[i]; w != 0 { + return bi - nlz(w) - 1 + } + bi -= bitsPerWord + } + panic("BUG: empty block") +} + +// min returns the minimum element of the block, +// and also removes it if take is set. +// The block must not be initially empty. +// NB: may leave the block empty. +// +func (b *block) min(take bool) int { + for i, w := range b.bits { + if w != 0 { + tz := ntz(w) + if take { + b.bits[i] = w &^ (1 << uint(tz)) + } + return b.offset + int(i*bitsPerWord) + tz + } + } + panic("BUG: empty block") +} + +// forEach calls f for each element of block b. +// f must not mutate b's enclosing Sparse. +func (b *block) forEach(f func(int)) { + for i, w := range b.bits { + offset := b.offset + i*bitsPerWord + for bi := 0; w != 0 && bi < bitsPerWord; bi++ { + if w&1 != 0 { + f(offset) + } + offset++ + w >>= 1 + } + } +} + +// offsetAndBitIndex returns the offset of the block that would +// contain x and the bit index of x within that block. +// +func offsetAndBitIndex(x int) (int, uint) { + mod := x % bitsPerBlock + if mod < 0 { + // Euclidean (non-negative) remainder + mod += bitsPerBlock + } + return x - mod, uint(mod) +} + +// -- Sparse -------------------------------------------------------------- + +// start returns the root's next block, which is the root block +// (if s.IsEmpty()) or the first true block otherwise. +// start has the side effect of ensuring that s is properly +// initialized. +// +func (s *Sparse) start() *block { + root := &s.root + if root.next == nil { + root.next = root + root.prev = root + } else if root.next.prev != root { + // Copying a Sparse x leads to pernicious corruption: the + // new Sparse y shares the old linked list, but iteration + // on y will never encounter &y.root so it goes into a + // loop. Fail fast before this occurs. + panic("A Sparse has been copied without (*Sparse).Copy()") + } + + return root.next +} + +// IsEmpty reports whether the set s is empty. +func (s *Sparse) IsEmpty() bool { + return s.start() == &s.root +} + +// Len returns the number of elements in the set s. +func (s *Sparse) Len() int { + var l int + for b := s.start(); b != &s.root; b = b.next { + l += b.len() + } + return l +} + +// Max returns the maximum element of the set s, or MinInt if s is empty. +func (s *Sparse) Max() int { + if s.IsEmpty() { + return MinInt + } + return s.root.prev.max() +} + +// Min returns the minimum element of the set s, or MaxInt if s is empty. +func (s *Sparse) Min() int { + if s.IsEmpty() { + return MaxInt + } + return s.root.next.min(false) +} + +// block returns the block that would contain offset, +// or nil if s contains no such block. +// +func (s *Sparse) block(offset int) *block { + b := s.start() + for b != &s.root && b.offset <= offset { + if b.offset == offset { + return b + } + b = b.next + } + return nil +} + +// Insert adds x to the set s, and reports whether the set grew. +func (s *Sparse) Insert(x int) bool { + offset, i := offsetAndBitIndex(x) + b := s.start() + for b != &s.root && b.offset <= offset { + if b.offset == offset { + return b.insert(i) + } + b = b.next + } + + // Insert new block before b. + new := &block{offset: offset} + new.next = b + new.prev = b.prev + new.prev.next = new + new.next.prev = new + return new.insert(i) +} + +func (s *Sparse) removeBlock(b *block) { + b.prev.next = b.next + b.next.prev = b.prev +} + +// Remove removes x from the set s, and reports whether the set shrank. +func (s *Sparse) Remove(x int) bool { + offset, i := offsetAndBitIndex(x) + if b := s.block(offset); b != nil { + if !b.remove(i) { + return false + } + if b.empty() { + s.removeBlock(b) + } + return true + } + return false +} + +// Clear removes all elements from the set s. +func (s *Sparse) Clear() { + s.root.next = &s.root + s.root.prev = &s.root +} + +// If set s is non-empty, TakeMin sets *p to the minimum element of +// the set s, removes that element from the set and returns true. +// Otherwise, it returns false and *p is undefined. +// +// This method may be used for iteration over a worklist like so: +// +// var x int +// for worklist.TakeMin(&x) { use(x) } +// +func (s *Sparse) TakeMin(p *int) bool { + head := s.start() + if head == &s.root { + return false + } + *p = head.min(true) + if head.empty() { + s.removeBlock(head) + } + return true +} + +// Has reports whether x is an element of the set s. +func (s *Sparse) Has(x int) bool { + offset, i := offsetAndBitIndex(x) + if b := s.block(offset); b != nil { + return b.has(i) + } + return false +} + +// forEach applies function f to each element of the set s in order. +// +// f must not mutate s. Consequently, forEach is not safe to expose +// to clients. In any case, using "range s.AppendTo()" allows more +// natural control flow with continue/break/return. +// +func (s *Sparse) forEach(f func(int)) { + for b := s.start(); b != &s.root; b = b.next { + b.forEach(f) + } +} + +// Copy sets s to the value of x. +func (s *Sparse) Copy(x *Sparse) { + if s == x { + return + } + + xb := x.start() + sb := s.start() + for xb != &x.root { + if sb == &s.root { + sb = s.insertBlockBefore(sb) + } + sb.offset = xb.offset + sb.bits = xb.bits + xb = xb.next + sb = sb.next + } + s.discardTail(sb) +} + +// insertBlockBefore returns a new block, inserting it before next. +func (s *Sparse) insertBlockBefore(next *block) *block { + b := new(block) + b.next = next + b.prev = next.prev + b.prev.next = b + next.prev = b + return b +} + +// discardTail removes block b and all its successors from s. +func (s *Sparse) discardTail(b *block) { + if b != &s.root { + b.prev.next = &s.root + s.root.prev = b.prev + } +} + +// IntersectionWith sets s to the intersection s ∩ x. +func (s *Sparse) IntersectionWith(x *Sparse) { + if s == x { + return + } + + xb := x.start() + sb := s.start() + for xb != &x.root && sb != &s.root { + switch { + case xb.offset < sb.offset: + xb = xb.next + + case xb.offset > sb.offset: + sb = sb.next + s.removeBlock(sb.prev) + + default: + var sum word + for i := range sb.bits { + r := xb.bits[i] & sb.bits[i] + sb.bits[i] = r + sum |= r + } + if sum != 0 { + sb = sb.next + } else { + // sb will be overwritten or removed + } + + xb = xb.next + } + } + + s.discardTail(sb) +} + +// Intersection sets s to the intersection x ∩ y. +func (s *Sparse) Intersection(x, y *Sparse) { + switch { + case s == x: + s.IntersectionWith(y) + return + case s == y: + s.IntersectionWith(x) + return + case x == y: + s.Copy(x) + return + } + + xb := x.start() + yb := y.start() + sb := s.start() + for xb != &x.root && yb != &y.root { + switch { + case xb.offset < yb.offset: + xb = xb.next + continue + case xb.offset > yb.offset: + yb = yb.next + continue + } + + if sb == &s.root { + sb = s.insertBlockBefore(sb) + } + sb.offset = xb.offset + + var sum word + for i := range sb.bits { + r := xb.bits[i] & yb.bits[i] + sb.bits[i] = r + sum |= r + } + if sum != 0 { + sb = sb.next + } else { + // sb will be overwritten or removed + } + + xb = xb.next + yb = yb.next + } + + s.discardTail(sb) +} + +// Intersects reports whether s ∩ x ≠ ∅. +func (s *Sparse) Intersects(x *Sparse) bool { + sb := s.start() + xb := x.start() + for sb != &s.root && xb != &x.root { + switch { + case xb.offset < sb.offset: + xb = xb.next + case xb.offset > sb.offset: + sb = sb.next + default: + for i := range sb.bits { + if sb.bits[i]&xb.bits[i] != 0 { + return true + } + } + sb = sb.next + xb = xb.next + } + } + return false +} + +// UnionWith sets s to the union s ∪ x, and reports whether s grew. +func (s *Sparse) UnionWith(x *Sparse) bool { + if s == x { + return false + } + + var changed bool + xb := x.start() + sb := s.start() + for xb != &x.root { + if sb != &s.root && sb.offset == xb.offset { + for i := range xb.bits { + if sb.bits[i] != xb.bits[i] { + sb.bits[i] |= xb.bits[i] + changed = true + } + } + xb = xb.next + } else if sb == &s.root || sb.offset > xb.offset { + sb = s.insertBlockBefore(sb) + sb.offset = xb.offset + sb.bits = xb.bits + changed = true + + xb = xb.next + } + sb = sb.next + } + return changed +} + +// Union sets s to the union x ∪ y. +func (s *Sparse) Union(x, y *Sparse) { + switch { + case x == y: + s.Copy(x) + return + case s == x: + s.UnionWith(y) + return + case s == y: + s.UnionWith(x) + return + } + + xb := x.start() + yb := y.start() + sb := s.start() + for xb != &x.root || yb != &y.root { + if sb == &s.root { + sb = s.insertBlockBefore(sb) + } + switch { + case yb == &y.root || (xb != &x.root && xb.offset < yb.offset): + sb.offset = xb.offset + sb.bits = xb.bits + xb = xb.next + + case xb == &x.root || (yb != &y.root && yb.offset < xb.offset): + sb.offset = yb.offset + sb.bits = yb.bits + yb = yb.next + + default: + sb.offset = xb.offset + for i := range xb.bits { + sb.bits[i] = xb.bits[i] | yb.bits[i] + } + xb = xb.next + yb = yb.next + } + sb = sb.next + } + + s.discardTail(sb) +} + +// DifferenceWith sets s to the difference s ∖ x. +func (s *Sparse) DifferenceWith(x *Sparse) { + if s == x { + s.Clear() + return + } + + xb := x.start() + sb := s.start() + for xb != &x.root && sb != &s.root { + switch { + case xb.offset > sb.offset: + sb = sb.next + + case xb.offset < sb.offset: + xb = xb.next + + default: + var sum word + for i := range sb.bits { + r := sb.bits[i] & ^xb.bits[i] + sb.bits[i] = r + sum |= r + } + sb = sb.next + xb = xb.next + + if sum == 0 { + s.removeBlock(sb.prev) + } + } + } +} + +// Difference sets s to the difference x ∖ y. +func (s *Sparse) Difference(x, y *Sparse) { + switch { + case x == y: + s.Clear() + return + case s == x: + s.DifferenceWith(y) + return + case s == y: + var y2 Sparse + y2.Copy(y) + s.Difference(x, &y2) + return + } + + xb := x.start() + yb := y.start() + sb := s.start() + for xb != &x.root && yb != &y.root { + if xb.offset > yb.offset { + // y has block, x has none + yb = yb.next + continue + } + + if sb == &s.root { + sb = s.insertBlockBefore(sb) + } + sb.offset = xb.offset + + switch { + case xb.offset < yb.offset: + // x has block, y has none + sb.bits = xb.bits + + sb = sb.next + + default: + // x and y have corresponding blocks + var sum word + for i := range sb.bits { + r := xb.bits[i] & ^yb.bits[i] + sb.bits[i] = r + sum |= r + } + if sum != 0 { + sb = sb.next + } else { + // sb will be overwritten or removed + } + + yb = yb.next + } + xb = xb.next + } + + for xb != &x.root { + if sb == &s.root { + sb = s.insertBlockBefore(sb) + } + sb.offset = xb.offset + sb.bits = xb.bits + sb = sb.next + + xb = xb.next + } + + s.discardTail(sb) +} + +// SymmetricDifferenceWith sets s to the symmetric difference s ∆ x. +func (s *Sparse) SymmetricDifferenceWith(x *Sparse) { + if s == x { + s.Clear() + return + } + + sb := s.start() + xb := x.start() + for xb != &x.root && sb != &s.root { + switch { + case sb.offset < xb.offset: + sb = sb.next + case xb.offset < sb.offset: + nb := s.insertBlockBefore(sb) + nb.offset = xb.offset + nb.bits = xb.bits + xb = xb.next + default: + var sum word + for i := range sb.bits { + r := sb.bits[i] ^ xb.bits[i] + sb.bits[i] = r + sum |= r + } + sb = sb.next + xb = xb.next + if sum == 0 { + s.removeBlock(sb.prev) + } + } + } + + for xb != &x.root { // append the tail of x to s + sb = s.insertBlockBefore(sb) + sb.offset = xb.offset + sb.bits = xb.bits + sb = sb.next + xb = xb.next + } +} + +// SymmetricDifference sets s to the symmetric difference x ∆ y. +func (s *Sparse) SymmetricDifference(x, y *Sparse) { + switch { + case x == y: + s.Clear() + return + case s == x: + s.SymmetricDifferenceWith(y) + return + case s == y: + s.SymmetricDifferenceWith(x) + return + } + + sb := s.start() + xb := x.start() + yb := y.start() + for xb != &x.root && yb != &y.root { + if sb == &s.root { + sb = s.insertBlockBefore(sb) + } + switch { + case yb.offset < xb.offset: + sb.offset = yb.offset + sb.bits = yb.bits + sb = sb.next + yb = yb.next + case xb.offset < yb.offset: + sb.offset = xb.offset + sb.bits = xb.bits + sb = sb.next + xb = xb.next + default: + var sum word + for i := range sb.bits { + r := xb.bits[i] ^ yb.bits[i] + sb.bits[i] = r + sum |= r + } + if sum != 0 { + sb.offset = xb.offset + sb = sb.next + } + xb = xb.next + yb = yb.next + } + } + + for xb != &x.root { // append the tail of x to s + if sb == &s.root { + sb = s.insertBlockBefore(sb) + } + sb.offset = xb.offset + sb.bits = xb.bits + sb = sb.next + xb = xb.next + } + + for yb != &y.root { // append the tail of y to s + if sb == &s.root { + sb = s.insertBlockBefore(sb) + } + sb.offset = yb.offset + sb.bits = yb.bits + sb = sb.next + yb = yb.next + } + + s.discardTail(sb) +} + +// SubsetOf reports whether s ∖ x = ∅. +func (s *Sparse) SubsetOf(x *Sparse) bool { + if s == x { + return true + } + + sb := s.start() + xb := x.start() + for sb != &s.root { + switch { + case xb == &x.root || xb.offset > sb.offset: + return false + case xb.offset < sb.offset: + xb = xb.next + default: + for i := range sb.bits { + if sb.bits[i]&^xb.bits[i] != 0 { + return false + } + } + sb = sb.next + xb = xb.next + } + } + return true +} + +// Equals reports whether the sets s and t have the same elements. +func (s *Sparse) Equals(t *Sparse) bool { + if s == t { + return true + } + sb := s.start() + tb := t.start() + for { + switch { + case sb == &s.root && tb == &t.root: + return true + case sb == &s.root || tb == &t.root: + return false + case sb.offset != tb.offset: + return false + case sb.bits != tb.bits: + return false + } + + sb = sb.next + tb = tb.next + } +} + +// String returns a human-readable description of the set s. +func (s *Sparse) String() string { + var buf bytes.Buffer + buf.WriteByte('{') + s.forEach(func(x int) { + if buf.Len() > 1 { + buf.WriteByte(' ') + } + fmt.Fprintf(&buf, "%d", x) + }) + buf.WriteByte('}') + return buf.String() +} + +// BitString returns the set as a string of 1s and 0s denoting the sum +// of the i'th powers of 2, for each i in s. A radix point, always +// preceded by a digit, appears if the sum is non-integral. +// +// Examples: +// {}.BitString() = "0" +// {4,5}.BitString() = "110000" +// {-3}.BitString() = "0.001" +// {-3,0,4,5}.BitString() = "110001.001" +// +func (s *Sparse) BitString() string { + if s.IsEmpty() { + return "0" + } + + min, max := s.Min(), s.Max() + var nbytes int + if max > 0 { + nbytes = max + } + nbytes++ // zero bit + radix := nbytes + if min < 0 { + nbytes += len(".") - min + } + + b := make([]byte, nbytes) + for i := range b { + b[i] = '0' + } + if radix < nbytes { + b[radix] = '.' + } + s.forEach(func(x int) { + if x >= 0 { + x += len(".") + } + b[radix-x] = '1' + }) + return string(b) +} + +// GoString returns a string showing the internal representation of +// the set s. +// +func (s *Sparse) GoString() string { + var buf bytes.Buffer + for b := s.start(); b != &s.root; b = b.next { + fmt.Fprintf(&buf, "block %p {offset=%d next=%p prev=%p", + b, b.offset, b.next, b.prev) + for _, w := range b.bits { + fmt.Fprintf(&buf, " 0%016x", w) + } + fmt.Fprintf(&buf, "}\n") + } + return buf.String() +} + +// AppendTo returns the result of appending the elements of s to slice +// in order. +func (s *Sparse) AppendTo(slice []int) []int { + s.forEach(func(x int) { + slice = append(slice, x) + }) + return slice +} + +// -- Testing/debugging ------------------------------------------------ + +// check returns an error if the representation invariants of s are violated. +func (s *Sparse) check() error { + if !s.root.empty() { + return fmt.Errorf("non-empty root block") + } + if s.root.offset != 0 { + return fmt.Errorf("root block has non-zero offset %d", s.root.offset) + } + for b := s.start(); b != &s.root; b = b.next { + if b.offset%bitsPerBlock != 0 { + return fmt.Errorf("bad offset modulo: %d", b.offset) + } + if b.empty() { + return fmt.Errorf("empty block") + } + if b.prev.next != b { + return fmt.Errorf("bad prev.next link") + } + if b.next.prev != b { + return fmt.Errorf("bad next.prev link") + } + if b.prev != &s.root { + if b.offset <= b.prev.offset { + return fmt.Errorf("bad offset order: b.offset=%d, prev.offset=%d", + b.offset, b.prev.offset) + } + } + } + return nil +} diff --git a/vendor/golang.org/x/tools/container/intsets/util.go b/vendor/golang.org/x/tools/container/intsets/util.go new file mode 100644 index 0000000000000..dd1db86b1c1d7 --- /dev/null +++ b/vendor/golang.org/x/tools/container/intsets/util.go @@ -0,0 +1,84 @@ +// Copyright 2013 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package intsets + +// From Hacker's Delight, fig 5.2. +func popcountHD(x uint32) int { + x -= (x >> 1) & 0x55555555 + x = (x & 0x33333333) + ((x >> 2) & 0x33333333) + x = (x + (x >> 4)) & 0x0f0f0f0f + x = x + (x >> 8) + x = x + (x >> 16) + return int(x & 0x0000003f) +} + +var a [1 << 8]byte + +func init() { + for i := range a { + var n byte + for x := i; x != 0; x >>= 1 { + if x&1 != 0 { + n++ + } + } + a[i] = n + } +} + +func popcountTable(x word) int { + return int(a[byte(x>>(0*8))] + + a[byte(x>>(1*8))] + + a[byte(x>>(2*8))] + + a[byte(x>>(3*8))] + + a[byte(x>>(4*8))] + + a[byte(x>>(5*8))] + + a[byte(x>>(6*8))] + + a[byte(x>>(7*8))]) +} + +// nlz returns the number of leading zeros of x. +// From Hacker's Delight, fig 5.11. +func nlz(x word) int { + x |= (x >> 1) + x |= (x >> 2) + x |= (x >> 4) + x |= (x >> 8) + x |= (x >> 16) + x |= (x >> 32) + return popcount(^x) +} + +// ntz returns the number of trailing zeros of x. +// From Hacker's Delight, fig 5.13. +func ntz(x word) int { + if x == 0 { + return bitsPerWord + } + n := 1 + if bitsPerWord == 64 { + if (x & 0xffffffff) == 0 { + n = n + 32 + x = x >> 32 + } + } + if (x & 0x0000ffff) == 0 { + n = n + 16 + x = x >> 16 + } + if (x & 0x000000ff) == 0 { + n = n + 8 + x = x >> 8 + } + if (x & 0x0000000f) == 0 { + n = n + 4 + x = x >> 4 + } + if (x & 0x00000003) == 0 { + n = n + 2 + x = x >> 2 + } + return n - int(x&1) +}