mirror of
https://github.com/wahyd4/cert-manager.git
synced 2026-08-22 11:36:42 +10:00
Merge pull request #2731 from munnerz/kube-1.18
Update k8s.io dependencies to Kubernetes 1.18.0
This commit is contained in:
@@ -12662,6 +12662,41 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
================================================================================
|
||||
|
||||
|
||||
================================================================================
|
||||
= vendor/golang.org/x/sync 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/sync/LICENSE 5d4950ecb7b26d2c5e4e7b4e0dd74707
|
||||
================================================================================
|
||||
|
||||
|
||||
================================================================================
|
||||
= vendor/golang.org/x/sys licensed under: =
|
||||
|
||||
@@ -17034,6 +17069,215 @@ third-party archives.
|
||||
================================================================================
|
||||
|
||||
|
||||
================================================================================
|
||||
= vendor/sigs.k8s.io/apiserver-network-proxy/konnectivity-client licensed under: =
|
||||
|
||||
Apache License
|
||||
Version 2.0, January 2004
|
||||
http://www.apache.org/licenses/
|
||||
|
||||
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||
|
||||
1. Definitions.
|
||||
|
||||
"License" shall mean the terms and conditions for use, reproduction,
|
||||
and distribution as defined by Sections 1 through 9 of this document.
|
||||
|
||||
"Licensor" shall mean the copyright owner or entity authorized by
|
||||
the copyright owner that is granting the License.
|
||||
|
||||
"Legal Entity" shall mean the union of the acting entity and all
|
||||
other entities that control, are controlled by, or are under common
|
||||
control with that entity. For the purposes of this definition,
|
||||
"control" means (i) the power, direct or indirect, to cause the
|
||||
direction or management of such entity, whether by contract or
|
||||
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||
|
||||
"You" (or "Your") shall mean an individual or Legal Entity
|
||||
exercising permissions granted by this License.
|
||||
|
||||
"Source" form shall mean the preferred form for making modifications,
|
||||
including but not limited to software source code, documentation
|
||||
source, and configuration files.
|
||||
|
||||
"Object" form shall mean any form resulting from mechanical
|
||||
transformation or translation of a Source form, including but
|
||||
not limited to compiled object code, generated documentation,
|
||||
and conversions to other media types.
|
||||
|
||||
"Work" shall mean the work of authorship, whether in Source or
|
||||
Object form, made available under the License, as indicated by a
|
||||
copyright notice that is included in or attached to the work
|
||||
(an example is provided in the Appendix below).
|
||||
|
||||
"Derivative Works" shall mean any work, whether in Source or Object
|
||||
form, that is based on (or derived from) the Work and for which the
|
||||
editorial revisions, annotations, elaborations, or other modifications
|
||||
represent, as a whole, an original work of authorship. For the purposes
|
||||
of this License, Derivative Works shall not include works that remain
|
||||
separable from, or merely link (or bind by name) to the interfaces of,
|
||||
the Work and Derivative Works thereof.
|
||||
|
||||
"Contribution" shall mean any work of authorship, including
|
||||
the original version of the Work and any modifications or additions
|
||||
to that Work or Derivative Works thereof, that is intentionally
|
||||
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||
or by an individual or Legal Entity authorized to submit on behalf of
|
||||
the copyright owner. For the purposes of this definition, "submitted"
|
||||
means any form of electronic, verbal, or written communication sent
|
||||
to the Licensor or its representatives, including but not limited to
|
||||
communication on electronic mailing lists, source code control systems,
|
||||
and issue tracking systems that are managed by, or on behalf of, the
|
||||
Licensor for the purpose of discussing and improving the Work, but
|
||||
excluding communication that is conspicuously marked or otherwise
|
||||
designated in writing by the copyright owner as "Not a Contribution."
|
||||
|
||||
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||
on behalf of whom a Contribution has been received by Licensor and
|
||||
subsequently incorporated within the Work.
|
||||
|
||||
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
copyright license to reproduce, prepare Derivative Works of,
|
||||
publicly display, publicly perform, sublicense, and distribute the
|
||||
Work and such Derivative Works in Source or Object form.
|
||||
|
||||
3. Grant of Patent License. Subject to the terms and conditions of
|
||||
this License, each Contributor 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, and otherwise transfer the Work,
|
||||
where such license applies only to those patent claims licensable
|
||||
by such Contributor that are necessarily infringed by their
|
||||
Contribution(s) alone or by combination of their Contribution(s)
|
||||
with the Work to which such Contribution(s) was submitted. If You
|
||||
institute patent litigation against any entity (including a
|
||||
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||
or a Contribution incorporated within the Work constitutes direct
|
||||
or contributory patent infringement, then any patent licenses
|
||||
granted to You under this License for that Work shall terminate
|
||||
as of the date such litigation is filed.
|
||||
|
||||
4. Redistribution. You may reproduce and distribute copies of the
|
||||
Work or Derivative Works thereof in any medium, with or without
|
||||
modifications, and in Source or Object form, provided that You
|
||||
meet the following conditions:
|
||||
|
||||
(a) You must give any other recipients of the Work or
|
||||
Derivative Works a copy of this License; and
|
||||
|
||||
(b) You must cause any modified files to carry prominent notices
|
||||
stating that You changed the files; and
|
||||
|
||||
(c) You must retain, in the Source form of any Derivative Works
|
||||
that You distribute, all copyright, patent, trademark, and
|
||||
attribution notices from the Source form of the Work,
|
||||
excluding those notices that do not pertain to any part of
|
||||
the Derivative Works; and
|
||||
|
||||
(d) If the Work includes a "NOTICE" text file as part of its
|
||||
distribution, then any Derivative Works that You distribute must
|
||||
include a readable copy of the attribution notices contained
|
||||
within such NOTICE file, excluding those notices that do not
|
||||
pertain to any part of the Derivative Works, in at least one
|
||||
of the following places: within a NOTICE text file distributed
|
||||
as part of the Derivative Works; within the Source form or
|
||||
documentation, if provided along with the Derivative Works; or,
|
||||
within a display generated by the Derivative Works, if and
|
||||
wherever such third-party notices normally appear. The contents
|
||||
of the NOTICE file are for informational purposes only and
|
||||
do not modify the License. You may add Your own attribution
|
||||
notices within Derivative Works that You distribute, alongside
|
||||
or as an addendum to the NOTICE text from the Work, provided
|
||||
that such additional attribution notices cannot be construed
|
||||
as modifying the License.
|
||||
|
||||
You may add Your own copyright statement to Your modifications and
|
||||
may provide additional or different license terms and conditions
|
||||
for use, reproduction, or distribution of Your modifications, or
|
||||
for any such Derivative Works as a whole, provided Your use,
|
||||
reproduction, and distribution of the Work otherwise complies with
|
||||
the conditions stated in this License.
|
||||
|
||||
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||
any Contribution intentionally submitted for inclusion in the Work
|
||||
by You to the Licensor shall be under the terms and conditions of
|
||||
this License, without any additional terms or conditions.
|
||||
Notwithstanding the above, nothing herein shall supersede or modify
|
||||
the terms of any separate license agreement you may have executed
|
||||
with Licensor regarding such Contributions.
|
||||
|
||||
6. Trademarks. This License does not grant permission to use the trade
|
||||
names, trademarks, service marks, or product names of the Licensor,
|
||||
except as required for reasonable and customary use in describing the
|
||||
origin of the Work and reproducing the content of the NOTICE file.
|
||||
|
||||
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||
agreed to in writing, Licensor provides the Work (and each
|
||||
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||
implied, including, without limitation, any warranties or conditions
|
||||
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||
appropriateness of using or redistributing the Work and assume any
|
||||
risks associated with Your exercise of permissions under this License.
|
||||
|
||||
8. Limitation of Liability. In no event and under no legal theory,
|
||||
whether in tort (including negligence), contract, or otherwise,
|
||||
unless required by applicable law (such as deliberate and grossly
|
||||
negligent acts) or agreed to in writing, shall any Contributor be
|
||||
liable to You for damages, including any direct, indirect, special,
|
||||
incidental, or consequential damages of any character arising as a
|
||||
result of this License or out of the use or inability to use the
|
||||
Work (including but not limited to damages for loss of goodwill,
|
||||
work stoppage, computer failure or malfunction, or any and all
|
||||
other commercial damages or losses), even if such Contributor
|
||||
has been advised of the possibility of such damages.
|
||||
|
||||
9. Accepting Warranty or Additional Liability. While redistributing
|
||||
the Work or Derivative Works thereof, You may choose to offer,
|
||||
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||
or other liability obligations and/or rights consistent with this
|
||||
License. However, in accepting such obligations, You may act only
|
||||
on Your own behalf and on Your sole responsibility, not on behalf
|
||||
of any other Contributor, and only if You agree to indemnify,
|
||||
defend, and hold each Contributor harmless for any liability
|
||||
incurred by, or claims asserted against, such Contributor by reason
|
||||
of your accepting any such warranty or additional liability.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
APPENDIX: How to apply the Apache License to your work.
|
||||
|
||||
To apply the Apache License to your work, attach the following
|
||||
boilerplate notice, with the fields enclosed by brackets "{}"
|
||||
replaced with your own identifying information. (Don't include
|
||||
the brackets!) The text should be enclosed in the appropriate
|
||||
comment syntax for the file format. We also recommend that a
|
||||
file or class name and description of purpose be included on the
|
||||
same "printed page" as the copyright notice for easier
|
||||
identification within third-party archives.
|
||||
|
||||
Copyright {yyyy} {name of copyright owner}
|
||||
|
||||
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.
|
||||
|
||||
= vendor/sigs.k8s.io/apiserver-network-proxy/konnectivity-client/LICENSE e3fc50a88d0a364313df4b21ef20c29e
|
||||
================================================================================
|
||||
|
||||
|
||||
================================================================================
|
||||
= vendor/sigs.k8s.io/controller-runtime licensed under: =
|
||||
|
||||
@@ -17453,7 +17697,7 @@ third-party archives.
|
||||
|
||||
|
||||
================================================================================
|
||||
= vendor/sigs.k8s.io/structured-merge-diff licensed under: =
|
||||
= vendor/sigs.k8s.io/structured-merge-diff/v3 licensed under: =
|
||||
|
||||
Apache License
|
||||
Version 2.0, January 2004
|
||||
@@ -17657,7 +17901,7 @@ third-party archives.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
|
||||
= vendor/sigs.k8s.io/structured-merge-diff/LICENSE e3fc50a88d0a364313df4b21ef20c29e
|
||||
= vendor/sigs.k8s.io/structured-merge-diff/v3/LICENSE e3fc50a88d0a364313df4b21ef20c29e
|
||||
================================================================================
|
||||
|
||||
|
||||
|
||||
@@ -4,6 +4,10 @@ go 1.12
|
||||
|
||||
replace github.com/prometheus/client_golang => github.com/prometheus/client_golang v0.9.4
|
||||
|
||||
replace sigs.k8s.io/controller-runtime => github.com/munnerz/controller-runtime v0.1.8-0.20200318092001-e22ac1073450
|
||||
|
||||
replace sigs.k8s.io/controller-tools => github.com/munnerz/controller-tools v0.1.10-0.20200323145043-a2d268fbf03d
|
||||
|
||||
replace golang.org/x/crypto => github.com/munnerz/crypto v0.0.0-20191203200931-e1844778daa5
|
||||
|
||||
require (
|
||||
@@ -19,7 +23,7 @@ require (
|
||||
github.com/digitalocean/godo v1.29.0
|
||||
github.com/go-logr/logr v0.1.0
|
||||
github.com/go-logr/zapr v0.1.1 // indirect
|
||||
github.com/google/gofuzz v1.0.0
|
||||
github.com/google/gofuzz v1.1.0
|
||||
github.com/gorilla/context v1.1.1 // indirect
|
||||
github.com/gorilla/mux v1.6.2
|
||||
github.com/hashicorp/vault/api v1.0.4
|
||||
@@ -27,7 +31,7 @@ require (
|
||||
github.com/kr/pretty v0.1.0
|
||||
github.com/mattbaird/jsonpatch v0.0.0-20171005235357-81af80346b1a
|
||||
github.com/miekg/dns v0.0.0-20170721150254-0f3adef2e220
|
||||
github.com/munnerz/crd-schema-fuzz v0.0.0-20191114184610-fbd148d44a0a
|
||||
github.com/munnerz/crd-schema-fuzz v1.0.0
|
||||
github.com/onsi/ginkgo v1.11.0
|
||||
github.com/onsi/gomega v1.8.1
|
||||
github.com/pavel-v-chernykh/keystore-go v2.1.0+incompatible
|
||||
@@ -36,25 +40,25 @@ require (
|
||||
github.com/spf13/cobra v0.0.5
|
||||
github.com/spf13/pflag v1.0.5
|
||||
github.com/stretchr/testify v1.4.0
|
||||
golang.org/x/crypto v0.0.0-20191202143827-86a70503ff7e
|
||||
golang.org/x/crypto v0.0.0-20200220183623-bac4c82f6975
|
||||
golang.org/x/net v0.0.0-20191004110552-13f9640d40b9
|
||||
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45
|
||||
google.golang.org/api v0.4.0
|
||||
gopkg.in/ini.v1 v1.52.0 // indirect
|
||||
gopkg.in/yaml.v2 v2.2.8
|
||||
k8s.io/api v0.17.3
|
||||
k8s.io/apiextensions-apiserver v0.17.3
|
||||
k8s.io/apimachinery v0.17.3
|
||||
k8s.io/apiserver v0.17.3
|
||||
k8s.io/client-go v0.17.3
|
||||
k8s.io/code-generator v0.17.3
|
||||
k8s.io/component-base v0.17.3
|
||||
k8s.io/api v0.18.0
|
||||
k8s.io/apiextensions-apiserver v0.18.0
|
||||
k8s.io/apimachinery v0.18.0
|
||||
k8s.io/apiserver v0.18.0
|
||||
k8s.io/client-go v0.18.0
|
||||
k8s.io/code-generator v0.18.0
|
||||
k8s.io/component-base v0.18.0
|
||||
k8s.io/klog v1.0.0
|
||||
k8s.io/kube-aggregator v0.17.3
|
||||
k8s.io/kube-openapi v0.0.0-20191107075043-30be4d16710a
|
||||
k8s.io/utils v0.0.0-20191114184206-e782cd3c129f
|
||||
k8s.io/kube-aggregator v0.18.0
|
||||
k8s.io/kube-openapi v0.0.0-20200121204235-bf4fb3bd569c
|
||||
k8s.io/utils v0.0.0-20200324210504-a9aa75ae1b89
|
||||
sigs.k8s.io/controller-runtime v0.5.1-0.20200307095134-d0de78d9f1c1
|
||||
sigs.k8s.io/controller-tools v0.2.5
|
||||
sigs.k8s.io/controller-tools v0.2.8
|
||||
sigs.k8s.io/testing_frameworks v0.1.2
|
||||
software.sslmate.com/src/go-pkcs12 v0.0.0-20180114231543-2291e8f0f237
|
||||
)
|
||||
|
||||
@@ -25,7 +25,6 @@ github.com/Azure/go-autorest/tracing v0.5.0 h1:TRn4WjSnkcSy5AEG3pnbtFSwNtwzjr4VY
|
||||
github.com/Azure/go-autorest/tracing v0.5.0/go.mod h1:r/s2XiOKccPW3HrqB+W0TQzfbtp2fGCgRFtBroKn4Dk=
|
||||
github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ=
|
||||
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
|
||||
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
|
||||
github.com/NYTimes/gziphandler v0.0.0-20170623195520-56545f4a5d46 h1:lsxEuwrXEAokXB9qhlbKWPpo3KMLZQ5WB5WLQRW1uq0=
|
||||
github.com/NYTimes/gziphandler v0.0.0-20170623195520-56545f4a5d46/go.mod h1:3wb06e3pkSAbeQ52E9H9iFoQsEEwGN64994WTCIhntQ=
|
||||
github.com/PuerkitoBio/purell v1.0.0/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0=
|
||||
@@ -59,16 +58,13 @@ github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+Ce
|
||||
github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs=
|
||||
github.com/blang/semver v3.5.0+incompatible h1:CGxCgetQ64DKk7rdZ++Vfnb1+ogGNnB17OJKJXD2Cfs=
|
||||
github.com/blang/semver v3.5.0+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk=
|
||||
github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU=
|
||||
github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw=
|
||||
github.com/cloudflare/cloudflare-go v0.8.5 h1:k1iz+H2jIL8OnS+bGhNQ6GPldi7VCo2tuWmfQ4kMiDI=
|
||||
github.com/cloudflare/cloudflare-go v0.8.5/go.mod h1:8KhU6K+zHUEWOSU++mEQYf7D9UZOcQcibUoSm6vCUz4=
|
||||
github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa h1:OaNxuTZr7kxeODyLWsRMC+OD03aFUH+mW6r2d+MWa5Y=
|
||||
github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8=
|
||||
github.com/coreos/bbolt v1.3.1-coreos.6 h1:uTXKg9gY70s9jMAKdfljFQcuh4e/BXOM+V+d00KFj3A=
|
||||
github.com/coreos/bbolt v1.3.1-coreos.6/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk=
|
||||
github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
|
||||
github.com/coreos/etcd v3.3.15+incompatible h1:+9RjdC18gMxNQVvSiXvObLu29mOFmkgdsB4cRTlV+EE=
|
||||
github.com/coreos/etcd v3.3.15+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
|
||||
github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk=
|
||||
github.com/coreos/go-oidc v2.1.0+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc=
|
||||
github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
|
||||
@@ -86,7 +82,6 @@ github.com/cpu/goacmedns v0.0.0-20180701200144-565ecf2a84df/go.mod h1:sesf/pNnCY
|
||||
github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE=
|
||||
github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
|
||||
github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY=
|
||||
github.com/davecgh/go-spew v0.0.0-20151105211317-5215b55f46b2/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
|
||||
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
@@ -104,10 +99,12 @@ github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3
|
||||
github.com/dustin/go-humanize v0.0.0-20171111073723-bb3d318650d4/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
|
||||
github.com/dustin/go-humanize v1.0.0 h1:VSnTsYCnlFHaM2/igO1h6X3HA71jcobQuxemgkq4zYo=
|
||||
github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
|
||||
github.com/elazarl/goproxy v0.0.0-20170405201442-c4fc26588b6e/go.mod h1:/Zj4wYkgs4iZTTu3o/KG3Itv/qCCa8VVMlb3i9OVuzc=
|
||||
github.com/elazarl/goproxy v0.0.0-20180725130230-947c36da3153/go.mod h1:/Zj4wYkgs4iZTTu3o/KG3Itv/qCCa8VVMlb3i9OVuzc=
|
||||
github.com/emicklei/go-restful v0.0.0-20170410110728-ff4f55a20633/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs=
|
||||
github.com/emicklei/go-restful v2.9.5+incompatible h1:spTtZBk5DYEvbxMVutUuTyh1Ao2r4iyvLdACqsl/Ljk=
|
||||
github.com/emicklei/go-restful v2.9.5+incompatible/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs=
|
||||
github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
|
||||
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
|
||||
github.com/evanphx/json-patch v4.2.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk=
|
||||
github.com/evanphx/json-patch v4.5.0+incompatible h1:ouOWdg56aJriqS0huScTkVXPC5IcNrDCXZ6OoTAWu7M=
|
||||
github.com/evanphx/json-patch v4.5.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk=
|
||||
@@ -189,8 +186,8 @@ github.com/gobuffalo/flect v0.2.0 h1:EWCvMGGxOjsgwlWaP+f4+Hh6yrrte7JeFL2S6b+0hdM
|
||||
github.com/gobuffalo/flect v0.2.0/go.mod h1:W3K3X9ksuZfir8f/LrfVtWmCDQFfayuylOJ7sz/Fj80=
|
||||
github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ=
|
||||
github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4=
|
||||
github.com/gogo/protobuf v1.2.2-0.20190723190241-65acae22fc9d h1:3PaI8p3seN09VjbTYC/QWlUZdZ1qS1zGjy7LH2Wt07I=
|
||||
github.com/gogo/protobuf v1.2.2-0.20190723190241-65acae22fc9d/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o=
|
||||
github.com/gogo/protobuf v1.3.1 h1:DqDEcV5aeaTmdFBePNpYsp3FlcVH/2ISVVM9Qf8PSls=
|
||||
github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o=
|
||||
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b h1:VKtxabqXZkF25pY9ekfRL6a582T4P37/31XEstQ5p58=
|
||||
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
|
||||
github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903 h1:LbsanbbD6LieFkXbj9YNNBupiGHJgFeLpO0j0Fza1h8=
|
||||
@@ -219,9 +216,10 @@ github.com/google/go-cmp v0.3.0 h1:crn/baboCvb5fXaQ0IJ1SGTsTVrWpDsCWC8EGETZijY=
|
||||
github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
|
||||
github.com/google/go-querystring v1.0.0 h1:Xkwi/a1rcvNg1PPYe5vI8GbeBY/jrVuDX5ASuANWTrk=
|
||||
github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck=
|
||||
github.com/google/gofuzz v0.0.0-20161122191042-44d81051d367/go.mod h1:HP5RmnzzSNb993RKQDq4+1A4ia9nllfqcQFTQJedwGI=
|
||||
github.com/google/gofuzz v1.0.0 h1:A8PeW59pxE9IoFRqBp37U+mSNaQoZ46F1f0f863XSXw=
|
||||
github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
|
||||
github.com/google/gofuzz v1.1.0 h1:Hsa8mG0dQ46ij8Sl2AYJDUv1oA9/d6Vk+3LG99Oe02g=
|
||||
github.com/google/gofuzz v1.1.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
|
||||
github.com/google/martian v2.1.0+incompatible h1:/CP5g8u/VJHijgedC/Legn3BAbAaWPgecwXBIDzw5no=
|
||||
github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs=
|
||||
github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc=
|
||||
@@ -233,6 +231,7 @@ github.com/googleapis/gax-go/v2 v2.0.4 h1:hU4mGcQI4DaAYW+IbTun+2qEZVFxK0ySjQLTbS
|
||||
github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg=
|
||||
github.com/googleapis/gnostic v0.0.0-20170729233727-0c5108395e2d h1:7XGaL1e6bYS1yIonGp9761ExpPPV1ui0SAC59Yube9k=
|
||||
github.com/googleapis/gnostic v0.0.0-20170729233727-0c5108395e2d/go.mod h1:sJBsCZ4ayReDTBIg8b9dl28c5xFWyhBTVRp3pOg5EKY=
|
||||
github.com/googleapis/gnostic v0.1.0/go.mod h1:sJBsCZ4ayReDTBIg8b9dl28c5xFWyhBTVRp3pOg5EKY=
|
||||
github.com/googleapis/gnostic v0.3.1 h1:WeAefnSUHlBb0iJKwxFDZdbfGwkd7xRNuV+IpXMJhYk=
|
||||
github.com/googleapis/gnostic v0.3.1/go.mod h1:on+2t9HRStVgn95RSsFWFz+6Q0Snyqv1awfrALZdbtU=
|
||||
github.com/gophercloud/gophercloud v0.1.0 h1:P/nh25+rzXouhytV2pUHBb65fnds26Ghl8/391+sT5o=
|
||||
@@ -246,16 +245,11 @@ github.com/gorilla/mux v1.6.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2z
|
||||
github.com/gorilla/websocket v0.0.0-20170926233335-4201258b820c/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ=
|
||||
github.com/gorilla/websocket v1.4.0 h1:WDFjx/TMzVgy9VdMMQi2K2Emtwi2QcUQsztZ/zLaH/Q=
|
||||
github.com/gorilla/websocket v1.4.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ=
|
||||
github.com/gregjones/httpcache v0.0.0-20170728041850-787624de3eb7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA=
|
||||
github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA=
|
||||
github.com/grpc-ecosystem/go-grpc-middleware v0.0.0-20190222133341-cfaf5686ec79 h1:lR9ssWAqp9qL0bALxqEEkuudiP1eweOdv9jsRK3e7lE=
|
||||
github.com/grpc-ecosystem/go-grpc-middleware v0.0.0-20190222133341-cfaf5686ec79/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs=
|
||||
github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4 h1:z53tR0945TRRQO/fLEVPI6SMv7ZflF0TEaTAoU7tOzg=
|
||||
github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs=
|
||||
github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92BcuyuQ/YW4NSIpoGtfXNho=
|
||||
github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk=
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.3.0 h1:HJtP6RRwj2EpPCD/mhAWzSvLL/dFTdPm1UrWwanoFos=
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.3.0/go.mod h1:RSKVYQBd5MCa4OVpNdGskqpgL2+G+NZTnrVHpWWfpdw=
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.9.5 h1:UImYN5qQ8tuGpGE16ZmjvcTtTw24zw1QAp/SlnNrZhI=
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
|
||||
github.com/hashicorp/errwrap v1.0.0 h1:hLrqtEDnRye3+sgx6z4qVLNuviH3MR5aQ0ykNJa/UYA=
|
||||
@@ -308,7 +302,6 @@ github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af h1:pmfjZENx5i
|
||||
github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k=
|
||||
github.com/jonboulle/clockwork v0.1.0 h1:VKV+ZcuP6l3yW9doeqz6ziZGgcynBVQO+obU0+0hcPo=
|
||||
github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo=
|
||||
github.com/json-iterator/go v0.0.0-20180612202835-f2b4162afba3/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU=
|
||||
github.com/json-iterator/go v1.1.6 h1:MrUvLMLTMxbqFJ9kzlvat/rYZqZnW3u4wkLzWTaFwKs=
|
||||
github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU=
|
||||
github.com/json-iterator/go v1.1.7 h1:KfgG9LzI+pYjr4xvmz/5H4FXjokeP+rlHLhv3iH62Fo=
|
||||
@@ -371,12 +364,15 @@ github.com/mitchellh/reflectwalk v1.0.0/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx
|
||||
github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q=
|
||||
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg=
|
||||
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q=
|
||||
github.com/modern-go/reflect2 v0.0.0-20180320133207-05fbef0ca5da/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
|
||||
github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
|
||||
github.com/modern-go/reflect2 v1.0.1 h1:9f412s+6RmYXLWZSEzVVgPGK7C2PphHj5RJrvfx9AWI=
|
||||
github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
|
||||
github.com/munnerz/crd-schema-fuzz v0.0.0-20191114184610-fbd148d44a0a h1:gPv2n6t9+4/hMqRSgTCz1OpM4vx7lLgNxIsrUTtMBaA=
|
||||
github.com/munnerz/crd-schema-fuzz v0.0.0-20191114184610-fbd148d44a0a/go.mod h1:fVs1Mso4ZxhlygBEUDgOcyLtp5/DnLuCb8H5GI3CzS4=
|
||||
github.com/munnerz/controller-runtime v0.1.8-0.20200318092001-e22ac1073450 h1:JVe6Zq1UU0+Sips4INYr3tmQYCBU8SsSx3UlGd9RPh8=
|
||||
github.com/munnerz/controller-runtime v0.1.8-0.20200318092001-e22ac1073450/go.mod h1:FAh/6qSQ+dJE/CNZCNW1d/RCSI2K2cLmm+J457bB0OI=
|
||||
github.com/munnerz/controller-tools v0.1.10-0.20200323145043-a2d268fbf03d h1:dTHZ9GYcAirNN04tOtCpRgqceNDzChH9y8IHnSAqeOU=
|
||||
github.com/munnerz/controller-tools v0.1.10-0.20200323145043-a2d268fbf03d/go.mod h1:etyVkyUd4jBXBgv91n5rRHD/7EdjUs/CQSgYDLFKsmU=
|
||||
github.com/munnerz/crd-schema-fuzz v1.0.0 h1:8erI9yzEnOGw9K5O+a8zZdoo8N/OwrFi7c7SjBtkHAs=
|
||||
github.com/munnerz/crd-schema-fuzz v1.0.0/go.mod h1:4z/rcm37JxUkSsExFcLL6ZIT1SgDRdLiu7qq1evdVS0=
|
||||
github.com/munnerz/crypto v0.0.0-20191203200931-e1844778daa5 h1:hzR/iusv78rQSxebvSpz0olAoNmGbJrE42oeKFQ+Ni8=
|
||||
github.com/munnerz/crypto v0.0.0-20191203200931-e1844778daa5/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
github.com/munnerz/goautoneg v0.0.0-20120707110453-a547fc61f48d/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ=
|
||||
@@ -390,16 +386,10 @@ github.com/olekukonko/tablewriter v0.0.0-20170122224234-a0225b3f23b5/go.mod h1:v
|
||||
github.com/onsi/ginkgo v0.0.0-20170829012221-11459a886d9c/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/ginkgo v1.4.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/ginkgo v1.8.0 h1:VkHVNpR4iVnU8XQR6DBm8BqYjN7CRzw+xKUbVVbbW9w=
|
||||
github.com/onsi/ginkgo v1.8.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/ginkgo v1.10.1 h1:q/mM8GF/n0shIN8SaAZ0V+jnLPzen6WIVZdiwrRlMlo=
|
||||
github.com/onsi/ginkgo v1.10.1/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/ginkgo v1.11.0 h1:JAKSXpt1YjtLA7YpPiqO9ss6sNXEsPfSGdwN0UHqzrw=
|
||||
github.com/onsi/ginkgo v1.11.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/gomega v0.0.0-20170829124025-dcabb60a477c/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA=
|
||||
github.com/onsi/gomega v1.3.0/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA=
|
||||
github.com/onsi/gomega v1.5.0 h1:izbySO9zDPmjJ8rDjLvkA2zJHIo+HkYXHnf7eN7SSyo=
|
||||
github.com/onsi/gomega v1.5.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
|
||||
github.com/onsi/gomega v1.7.0 h1:XPnZz8VVBHjVsy1vzJmRwIcSwiUO+JFfrv/xGiigmME=
|
||||
github.com/onsi/gomega v1.7.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
|
||||
github.com/onsi/gomega v1.8.1 h1:C5Dqfs/LeauYDX0jJXIe2SWmwCbGzx9yF8C8xy3Lh34=
|
||||
@@ -418,7 +408,6 @@ github.com/pkg/errors v0.8.0 h1:WdK/asTD0HN+q6hsWO3/vpuAkAr+tw6aNJNDFFf0+qw=
|
||||
github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
|
||||
github.com/pkg/errors v0.8.1 h1:iURUrRGxPUNPdy5/HRSm+Yj6okJ6UtLINN0Q9M4+h3I=
|
||||
github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
|
||||
github.com/pmezard/go-difflib v0.0.0-20151028094244-d8ed2627bdf0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
||||
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
|
||||
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
||||
github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI=
|
||||
@@ -428,14 +417,14 @@ github.com/prometheus/client_golang v0.9.4/go.mod h1:oCXIBxdI62A4cR6aTRJCgetEjec
|
||||
github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo=
|
||||
github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90 h1:S/YWwWx/RA8rT8tKFRuGUZhuA90OyIBpPCXkcbwU8DE=
|
||||
github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
|
||||
github.com/prometheus/common v0.0.0-20181126121408-4724e9255275/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro=
|
||||
github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
|
||||
github.com/prometheus/client_model v0.2.0 h1:uq5h0d+GuxiXLJLNABMgp2qUWDPiLvgCzz2dUR+/W/M=
|
||||
github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
|
||||
github.com/prometheus/common v0.4.1 h1:K0MGApIoQvMw27RTdJkPbr3JZ7DNbtxQNyi5STVM6Kw=
|
||||
github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4=
|
||||
github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk=
|
||||
github.com/prometheus/procfs v0.0.0-20181204211112-1dc9a6cbc91a/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk=
|
||||
github.com/prometheus/procfs v0.0.2 h1:6LJUbpNm42llc4HRCuvApCSWB/WfhuNo9K98Q9sNGfs=
|
||||
github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA=
|
||||
github.com/remyoudompheng/bigfft v0.0.0-20170806203942-52369c62f446/go.mod h1:uYEyJGbgTkfkS4+E/PavXkNJcbFIpEtjt2B0KDQ5+9M=
|
||||
github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg=
|
||||
github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g=
|
||||
github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
|
||||
@@ -452,8 +441,6 @@ github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d h1:zE9ykE
|
||||
github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc=
|
||||
github.com/smartystreets/goconvey v0.0.0-20190330032615-68dc04aab96a h1:pa8hGb/2YqsZKovtsgrwcDH1RZhVbTKCjLp47XpqCDs=
|
||||
github.com/smartystreets/goconvey v0.0.0-20190330032615-68dc04aab96a/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA=
|
||||
github.com/soheilhy/cmux v0.1.3 h1:09wy7WZk4AqO03yH85Ex1X+Uo3vDsil3Fa9AgF8Emss=
|
||||
github.com/soheilhy/cmux v0.1.3/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM=
|
||||
github.com/soheilhy/cmux v0.1.4 h1:0HKaf1o97UwFjHH9o5XsHUOF+tqmdA7KEzXLpiyaw0E=
|
||||
github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM=
|
||||
github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ=
|
||||
@@ -474,7 +461,6 @@ github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DM
|
||||
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE=
|
||||
github.com/stretchr/testify v0.0.0-20151208002404-e3a8ff8ce365/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
|
||||
github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
|
||||
github.com/stretchr/testify v1.3.0 h1:TivCn/peBQ7UY8ooIcPgZFpTNSz0Q2U6UrFlUfqbe0Q=
|
||||
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
|
||||
@@ -487,8 +473,6 @@ github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljT
|
||||
github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
|
||||
github.com/urfave/cli/v2 v2.1.1/go.mod h1:SE9GqnLQmjVa0iPEY0f1w3ygNIYcIJ0OKPMoW2caLfQ=
|
||||
github.com/vektah/gqlparser v1.1.2/go.mod h1:1ycwN7Ij5njmMkPPAOaRFY4rET2Enx7IkVv3vaXspKw=
|
||||
github.com/xiang90/probing v0.0.0-20160813154853-07dd2e8dfe18 h1:MPPkRncZLN9Kh4MEFmbnK4h3BD7AUmskWv2+EeZJCCs=
|
||||
github.com/xiang90/probing v0.0.0-20160813154853-07dd2e8dfe18/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU=
|
||||
github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2 h1:eY9dn8+vbi4tKz5Qo6v2eYzo7kUS51QINcR5jNpbZS8=
|
||||
github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU=
|
||||
github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q=
|
||||
@@ -501,28 +485,19 @@ go.mongodb.org/mongo-driver v1.1.1/go.mod h1:u7ryQJ+DOzQmeO7zB6MHyr8jkEQvC8vH7qL
|
||||
go.mongodb.org/mongo-driver v1.1.2/go.mod h1:u7ryQJ+DOzQmeO7zB6MHyr8jkEQvC8vH7qLUO4lqsUM=
|
||||
go.opencensus.io v0.21.0 h1:mU6zScU4U1YAFPHEHYk+3JC4SY7JxgkqS10ZOSyksNg=
|
||||
go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
|
||||
go.uber.org/atomic v0.0.0-20181018215023-8dc6146f7569 h1:nSQar3Y0E3VQF/VdZ8PTAilaXpER+d7ypdABCrpwMdg=
|
||||
go.uber.org/atomic v0.0.0-20181018215023-8dc6146f7569/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
|
||||
go.uber.org/atomic v1.3.2 h1:2Oa65PReHzfn29GpvgsYwloV9AVFHPDk8tYxt2c2tr4=
|
||||
go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
|
||||
go.uber.org/atomic v1.4.0 h1:cxzIVoETapQEqDhQu3QfnvXAV4AlzcvUCxkVUFw3+EU=
|
||||
go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
|
||||
go.uber.org/multierr v0.0.0-20180122172545-ddea229ff1df h1:shvkWr0NAZkg4nPuE3XrKP0VuBPijjk3TfX6Y6acFNg=
|
||||
go.uber.org/multierr v0.0.0-20180122172545-ddea229ff1df/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0=
|
||||
go.uber.org/multierr v1.1.0 h1:HoEmRHQPVSqub6w2z2d2EOVs2fjyFRGyofhKuyDq0QI=
|
||||
go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0=
|
||||
go.uber.org/zap v0.0.0-20180814183419-67bc79d13d15/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q=
|
||||
go.uber.org/zap v1.10.0 h1:ORx85nbTijNz8ljznvCMR1ZBIPKFn3jQrag10X2AsuM=
|
||||
go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q=
|
||||
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
|
||||
golang.org/x/exp v0.0.0-20190125153040-c74c464bbbf2/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
|
||||
golang.org/x/exp v0.0.0-20190312203227-4b39c73a6495/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
|
||||
golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
|
||||
golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
|
||||
golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU=
|
||||
golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
|
||||
golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
|
||||
golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE=
|
||||
golang.org/x/net v0.0.0-20170114055629-f2499483f923/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180112015858-5ccada7d0a7b/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
@@ -539,8 +514,6 @@ golang.org/x/net v0.0.0-20190320064053-1272bf9dcd53/go.mod h1:t9HGtf8HONx5eT2rtn
|
||||
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
|
||||
golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20190812203447-cdfb69ac37fc h1:gkKoSkUmnU6bpS/VhkuO27bzQeSA51uaEfbOW5dNb68=
|
||||
golang.org/x/net v0.0.0-20190812203447-cdfb69ac37fc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20191004110552-13f9640d40b9 h1:rjwSpXsdiK0dV8/Naq3kAw9ymfAeJIyd0upUIElB+lI=
|
||||
@@ -557,6 +530,7 @@ golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJ
|
||||
golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6 h1:bjcUS9ztw9kFmmIxJInhon/0Is3p+EHBKNgquIzo1OI=
|
||||
golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e h1:vcxGaoTs7kV8m5Np9uUNQin4BrLOthgV7252N8V+FwY=
|
||||
golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sys v0.0.0-20170830134202-bb24a47a89ea/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180117170059-2c42eef0765b/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
@@ -571,7 +545,6 @@ golang.org/x/sys v0.0.0-20190129075346-302c3dd5f1cc/go.mod h1:STP8DvDyc/dI5b8T5h
|
||||
golang.org/x/sys v0.0.0-20190209173611-3b5209105503/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190321052220-f7bb7a8bee54/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190403152447-81d4e9dc473e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
@@ -581,8 +554,8 @@ golang.org/x/sys v0.0.0-20190616124812-15dcb6c0061f h1:25KHgbfyiSm6vwQLbM3zZIe1v
|
||||
golang.org/x/sys v0.0.0-20190616124812-15dcb6c0061f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456 h1:ng0gs1AKnRRuEMZoTLLlbOd+C17zUDepwGQBb/n+JVg=
|
||||
golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190922100055-0a153f010e69 h1:rOhMmluY6kLMhdnrivzec6lLgaVbMHMn2ISQXJeJ5EM=
|
||||
golang.org/x/sys v0.0.0-20190922100055-0a153f010e69/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20191022100944-742c48ecaeb7 h1:HmbHVPwrPEKPGLAcHSrMe6+hqSUlvZU0rab6x5EXfGU=
|
||||
golang.org/x/sys v0.0.0-20191022100944-742c48ecaeb7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/text v0.0.0-20160726164857-2910a502d2bf/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/text v0.3.1-0.20171227012246-e19ae1496984/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
@@ -601,27 +574,20 @@ golang.org/x/tools v0.0.0-20181011042414-1f849cf54d09/go.mod h1:n7NCudcB/nEzxVGm
|
||||
golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190125232054-d66bd3c5d5a6/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190206041539-40960b6deb8e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY=
|
||||
golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
|
||||
golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
|
||||
golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
|
||||
golang.org/x/tools v0.0.0-20190328211700-ab21143f2384 h1:TFlARGu6Czu1z7q93HTxcP1P+/ZFC/IKythI5RzrnRg=
|
||||
golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
|
||||
golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
||||
golang.org/x/tools v0.0.0-20190614205625-5aca471b1d59/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||
golang.org/x/tools v0.0.0-20190617190820-da514acc4774/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||
golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac h1:MQEvx39qSf8vyrx3XRaOe+j1UDIzKwkYOVObRgGPVqI=
|
||||
golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||
golang.org/x/tools v0.0.0-20190920225731-5eefd052ad72 h1:bw9doJza/SFBEweII/rHQh338oozWyiFsBRHtrflcws=
|
||||
golang.org/x/tools v0.0.0-20190920225731-5eefd052ad72/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7 h1:9zdDQZ7Thm29KFXgAX/+yaf3eVbP7djjWp/dXAppNCc=
|
||||
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
gomodules.xyz/jsonpatch/v2 v2.0.1 h1:xyiBuvkD2g5n7cYzx6u2sxQvsAy4QJsZFCzGVdzOXZ0=
|
||||
gomodules.xyz/jsonpatch/v2 v2.0.1/go.mod h1:IhYNNY4jnS53ZnfE4PAmpKtDpTCj1JFXc+3mwe7XcUU=
|
||||
gonum.org/v1/gonum v0.0.0-20190331200053-3d26580ed485/go.mod h1:2ltnJ7xHfj0zHS40VVPYEAAMTa3ZGguvHGBSJeRWqE0=
|
||||
gonum.org/v1/netlib v0.0.0-20190313105609-8cb42192e0e0/go.mod h1:wa6Ws7BG/ESfp6dHfk7C6KdzKA7wR7u/rKwOGE66zvw=
|
||||
gonum.org/v1/netlib v0.0.0-20190331212654-76723241ea4e/go.mod h1:kS+toOQn6AQKjmKJ7gzohV1XkqsFehRA2FbsbkopSuQ=
|
||||
google.golang.org/api v0.4.0 h1:KKgc1aqhV8wDPbDzlDtpvyjZFY3vjz85FP7p4wcQUyI=
|
||||
google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE=
|
||||
google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
|
||||
@@ -633,8 +599,8 @@ google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRn
|
||||
google.golang.org/genproto v0.0.0-20190404172233-64821d5d2107 h1:xtNn7qFlagY2mQNFHMSRPjT2RkOV4OXM7P5TVy9xATo=
|
||||
google.golang.org/genproto v0.0.0-20190404172233-64821d5d2107/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
|
||||
google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
|
||||
google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873 h1:nfPFGzJkUDX6uBmpN/pSw7MbOAWegH5QDQuoXFHedLg=
|
||||
google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
|
||||
google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55 h1:gSJIx1SDwno+2ElGhA4+qG2zF97qiUzTM+rQ0klBOcE=
|
||||
google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc=
|
||||
google.golang.org/grpc v1.14.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw=
|
||||
google.golang.org/grpc v1.19.0 h1:cfg4PD8YEdSFnm7qLV4++93WcmhH2nIUhMjhdCvl3j8=
|
||||
google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
|
||||
@@ -643,6 +609,8 @@ google.golang.org/grpc v1.23.0 h1:AzbTB6ux+okLTzP8Ru1Xs41C303zdcfEht7MQnYJt5A=
|
||||
google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg=
|
||||
google.golang.org/grpc v1.23.1 h1:q4XQuHFC6I28BKZpo6IYyb3mNO+l7lSOxRuYTCiDfXk=
|
||||
google.golang.org/grpc v1.23.1/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg=
|
||||
google.golang.org/grpc v1.26.0 h1:2dTRdpdFEEhJYQD8EMLB61nnrzSCTbG38PhqdhvOltg=
|
||||
google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
|
||||
gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw=
|
||||
gopkg.in/asn1-ber.v1 v1.0.0-20181015200546-f715ec2f112d/go.mod h1:cuepJuh7vyXfUyUwEgHQXw849cJrilpS5NeIjOWESAw=
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
@@ -653,7 +621,6 @@ gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8
|
||||
gopkg.in/cheggaaa/pb.v1 v1.0.25/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw=
|
||||
gopkg.in/fsnotify.v1 v1.4.7 h1:xOHLXZwVvI9hhs+cLKq5+I5onOuwQLhQwiu63xxlHs4=
|
||||
gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
|
||||
gopkg.in/inf.v0 v0.9.0/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw=
|
||||
gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc=
|
||||
gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw=
|
||||
gopkg.in/ini.v1 v1.38.2/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
|
||||
@@ -674,7 +641,6 @@ gopkg.in/yaml.v2 v2.2.2 h1:ZCJp+EgiOT7lHqUV2J862kp8Qj64Jo6az82+3Td9dZw=
|
||||
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
gopkg.in/yaml.v2 v2.2.4 h1:/eiJrUcujPVeJ3xlSWaiNi3uSVmDGBK1pDHUHAnao1I=
|
||||
gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
gopkg.in/yaml.v2 v2.2.7/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
gopkg.in/yaml.v2 v2.2.8 h1:obN1ZagJSUGI0Ek/LBmuj4SNLPfIny3KsKFopxRdj10=
|
||||
gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
gopkg.in/yaml.v3 v3.0.0-20190905181640-827449938966 h1:B0J02caTR6tpSJozBJyiAzT6CtBzjclw4pgm9gg8Ys0=
|
||||
@@ -684,85 +650,59 @@ gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81
|
||||
honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
k8s.io/api v0.0.0-20191016110408-35e52d86657a/go.mod h1:/L5qH+AD540e7Cetbui1tuJeXdmNhO8jM6VkXeDdDhQ=
|
||||
k8s.io/api v0.17.0 h1:H9d/lw+VkZKEVIUc8F3wgiQ+FUXTTr21M87jXLU7yqM=
|
||||
k8s.io/api v0.17.0/go.mod h1:npsyOePkeP0CPwyGfXDHxvypiYMJxBWAMpQxCaJ4ZxI=
|
||||
k8s.io/api v0.17.2/go.mod h1:BS9fjjLc4CMuqfSO8vgbHPKMt5+SF0ET6u/RVDihTo4=
|
||||
k8s.io/api v0.17.3 h1:XAm3PZp3wnEdzekNkcmj/9Y1zdmQYJ1I4GKSBBZ8aG0=
|
||||
k8s.io/api v0.17.3/go.mod h1:YZ0OTkuw7ipbe305fMpIdf3GLXZKRigjtZaV5gzC2J0=
|
||||
k8s.io/apiextensions-apiserver v0.0.0-20191016113550-5357c4baaf65/go.mod h1:5BINdGqggRXXKnDgpwoJ7PyQH8f+Ypp02fvVNcIFy9s=
|
||||
k8s.io/apiextensions-apiserver v0.17.0 h1:+XgcGxqaMztkbbvsORgCmHIb4uImHKvTjNyu7b8gRnA=
|
||||
k8s.io/apiextensions-apiserver v0.17.0/go.mod h1:XiIFUakZywkUl54fVXa7QTEHcqQz9HG55nHd1DCoHj8=
|
||||
k8s.io/apiextensions-apiserver v0.17.2/go.mod h1:4KdMpjkEjjDI2pPfBA15OscyNldHWdBCfsWMDWAmSTs=
|
||||
k8s.io/apiextensions-apiserver v0.17.3 h1:WDZWkPcbgvchEdDd7ysL21GGPx3UKZQLDZXEkevT6n4=
|
||||
k8s.io/apiextensions-apiserver v0.17.3/go.mod h1:CJbCyMfkKftAd/X/V6OTHYhVn7zXnDdnkUjS1h0GTeY=
|
||||
k8s.io/apimachinery v0.0.0-20191004115801-a2eda9f80ab8/go.mod h1:llRdnznGEAqC3DcNm6yEj472xaFVfLM7hnYofMb12tQ=
|
||||
k8s.io/apimachinery v0.17.0 h1:xRBnuie9rXcPxUkDizUsGvPf1cnlZCFu210op7J7LJo=
|
||||
k8s.io/apimachinery v0.17.0/go.mod h1:b9qmWdKlLuU9EBh+06BtLcSf/Mu89rWL33naRxs1uZg=
|
||||
k8s.io/apimachinery v0.17.2/go.mod h1:b9qmWdKlLuU9EBh+06BtLcSf/Mu89rWL33naRxs1uZg=
|
||||
k8s.io/apimachinery v0.17.3 h1:f+uZV6rm4/tHE7xXgLyToprg6xWairaClGVkm2t8omg=
|
||||
k8s.io/apimachinery v0.17.3/go.mod h1:gxLnyZcGNdZTCLnq3fgzyg2A5BVCHTNDFrw8AmuJ+0g=
|
||||
k8s.io/apiserver v0.0.0-20191016112112-5190913f932d/go.mod h1:7OqfAolfWxUM/jJ/HBLyE+cdaWFBUoo5Q5pHgJVj2ws=
|
||||
k8s.io/apiserver v0.17.0 h1:XhUix+FKFDcBygWkQNp7wKKvZL030QUlH1o8vFeSgZA=
|
||||
k8s.io/apiserver v0.17.0/go.mod h1:ABM+9x/prjINN6iiffRVNCBR2Wk7uY4z+EtEGZD48cg=
|
||||
k8s.io/apiserver v0.17.2/go.mod h1:lBmw/TtQdtxvrTk0e2cgtOxHizXI+d0mmGQURIHQZlo=
|
||||
k8s.io/apiserver v0.17.3 h1:faZbSuFtJ4dx09vctKZGHms/7bp3qFtbqb10Swswqfs=
|
||||
k8s.io/apiserver v0.17.3/go.mod h1:iJtsPpu1ZpEnHaNawpSV0nYTGBhhX2dUlnn7/QS7QiY=
|
||||
k8s.io/client-go v0.0.0-20191016111102-bec269661e48/go.mod h1:hrwktSwYGI4JK+TJA3dMaFyyvHVi/aLarVHpbs8bgCU=
|
||||
k8s.io/client-go v0.17.0 h1:8QOGvUGdqDMFrm9sD6IUFl256BcffynGoe80sxgTEDg=
|
||||
k8s.io/client-go v0.17.0/go.mod h1:TYgR6EUHs6k45hb6KWjVD6jFZvJV4gHDikv/It0xz+k=
|
||||
k8s.io/client-go v0.17.2/go.mod h1:QAzRgsa0C2xl4/eVpeVAZMvikCn8Nm81yqVx3Kk9XYI=
|
||||
k8s.io/client-go v0.17.3 h1:deUna1Ksx05XeESH6XGCyONNFfiQmDdqeqUvicvP6nU=
|
||||
k8s.io/client-go v0.17.3/go.mod h1:cLXlTMtWHkuK4tD360KpWz2gG2KtdWEr/OT02i3emRQ=
|
||||
k8s.io/code-generator v0.0.0-20191004115455-8e001e5d1894 h1:NMYlxaF7rYQJk2E2IyrUhaX81zX24+dmoZdkPw0gJqI=
|
||||
k8s.io/code-generator v0.0.0-20191004115455-8e001e5d1894/go.mod h1:mJUgkl06XV4kstAnLHAIzJPVCOzVR+ZcfPIv4fUsFCY=
|
||||
k8s.io/code-generator v0.17.0 h1:y+KWtDWNqlJzJu/kUy8goJZO0X71PGIpAHLX8a0JYk0=
|
||||
k8s.io/code-generator v0.17.0/go.mod h1:DVmfPQgxQENqDIzVR2ddLXMH34qeszkKSdH/N+s+38s=
|
||||
k8s.io/code-generator v0.17.2/go.mod h1:DVmfPQgxQENqDIzVR2ddLXMH34qeszkKSdH/N+s+38s=
|
||||
k8s.io/code-generator v0.17.3 h1:q/hDMk2cvFzSxol7k/VA1qCssR7VSMXHQHhzuX29VJ8=
|
||||
k8s.io/code-generator v0.17.3/go.mod h1:l8BLVwASXQZTo2xamW5mQNFCe1XPiAesVq7Y1t7PiQQ=
|
||||
k8s.io/component-base v0.0.0-20191016111319-039242c015a9/go.mod h1:SuWowIgd/dtU/m/iv8OD9eOxp3QZBBhTIiWMsBQvKjI=
|
||||
k8s.io/component-base v0.17.0 h1:BnDFcmBDq+RPpxXjmuYnZXb59XNN9CaFrX8ba9+3xrA=
|
||||
k8s.io/component-base v0.17.0/go.mod h1:rKuRAokNMY2nn2A6LP/MiwpoaMRHpfRnrPaUJJj1Yoc=
|
||||
k8s.io/component-base v0.17.2/go.mod h1:zMPW3g5aH7cHJpKYQ/ZsGMcgbsA/VyhEugF3QT1awLs=
|
||||
k8s.io/component-base v0.17.3 h1:hQzTSshY14aLSR6WGIYvmw+w+u6V4d+iDR2iDGMrlUg=
|
||||
k8s.io/component-base v0.17.3/go.mod h1:GeQf4BrgelWm64PXkIXiPh/XS0hnO42d9gx9BtbZRp8=
|
||||
k8s.io/api v0.18.0-rc.1 h1:hEUIbswR8BaacroH6OX/rjrK1kvEIUFZt3EpEar7/CM=
|
||||
k8s.io/api v0.18.0-rc.1/go.mod h1:ZOh6SbHjOYyaMLlWmB2+UOQKEWDpCnVEVpEyt7S2J9s=
|
||||
k8s.io/api v0.18.0 h1:lwYk8Vt7rsVTwjRU6pzEsa9YNhThbmbocQlKvNBB4EQ=
|
||||
k8s.io/api v0.18.0/go.mod h1:q2HRQkfDzHMBZL9l/y9rH63PkQl4vae0xRT+8prbrK8=
|
||||
k8s.io/apiextensions-apiserver v0.18.0-rc.1 h1:rhdw261gFouyOz8A8G0J1bhpOF2lLUF+LWv1o0d81E8=
|
||||
k8s.io/apiextensions-apiserver v0.18.0-rc.1/go.mod h1:U5F8MzX2yXVHRuSKY5xBkS9999/VHu6PJNOInIpVLe4=
|
||||
k8s.io/apiextensions-apiserver v0.18.0 h1:HN4/P8vpGZFvB5SOMuPPH2Wt9Y/ryX+KRvIyAkchu1Q=
|
||||
k8s.io/apiextensions-apiserver v0.18.0/go.mod h1:18Cwn1Xws4xnWQNC00FLq1E350b9lUF+aOdIWDOZxgo=
|
||||
k8s.io/apimachinery v0.18.0-rc.1 h1:pYWMpBgJdEe1OacuI89D49JLcTG5ZLx9D7a1dGOdYh4=
|
||||
k8s.io/apimachinery v0.18.0-rc.1/go.mod h1:9SnR/e11v5IbyPCGbvJViimtJ0SwHG4nfZFjU77ftcA=
|
||||
k8s.io/apimachinery v0.18.0 h1:fuPfYpk3cs1Okp/515pAf0dNhL66+8zk8RLbSX+EgAE=
|
||||
k8s.io/apimachinery v0.18.0/go.mod h1:9SnR/e11v5IbyPCGbvJViimtJ0SwHG4nfZFjU77ftcA=
|
||||
k8s.io/apiserver v0.18.0-rc.1 h1:P+tvb0Hum3tsyz6cF/mKJwXhDB/DMGhkkx+K7MQWj04=
|
||||
k8s.io/apiserver v0.18.0-rc.1/go.mod h1:RYE9w2Lijk1aWW3i3pS7kFGU0Afof+UDoOz1qW9aSYg=
|
||||
k8s.io/apiserver v0.18.0 h1:ELAWpGWC6XdbRLi5lwAbEbvksD7hkXxPdxaJsdpist4=
|
||||
k8s.io/apiserver v0.18.0/go.mod h1:3S2O6FeBBd6XTo0njUrLxiqk8GNy6wWOftjhJcXYnjw=
|
||||
k8s.io/client-go v0.18.0-rc.1 h1:e3vtZ2p1wkcpUccs5e006uf3nu9UqzIvTfkuYfPVSZI=
|
||||
k8s.io/client-go v0.18.0-rc.1/go.mod h1:0lGW/AaaFfNWlmyYvWSJrtaDlti7oNRyCjq4CNK/Ipk=
|
||||
k8s.io/client-go v0.18.0 h1:yqKw4cTUQraZK3fcVCMeSa+lqKwcjZ5wtcOIPnxQno4=
|
||||
k8s.io/client-go v0.18.0/go.mod h1:uQSYDYs4WhVZ9i6AIoEZuwUggLVEF64HOD37boKAtF8=
|
||||
k8s.io/code-generator v0.18.0-rc.1 h1:jkki5S+ps0tbsWm+J9iMVGNDTsr2CEVs7KmHHMMaH3U=
|
||||
k8s.io/code-generator v0.18.0-rc.1/go.mod h1:+UHX5rSbxmR8kzS+FAv7um6dtYrZokQvjHpDSYRVkTc=
|
||||
k8s.io/code-generator v0.18.0 h1:0xIRWzym+qMgVpGmLESDeMfz/orwgxwxFFAo1xfGNtQ=
|
||||
k8s.io/code-generator v0.18.0/go.mod h1:+UHX5rSbxmR8kzS+FAv7um6dtYrZokQvjHpDSYRVkTc=
|
||||
k8s.io/component-base v0.18.0-rc.1 h1:i/+YkGsfS58M1jhAO0cLnZR1bnhSvZKx7rqRaq7B1s0=
|
||||
k8s.io/component-base v0.18.0-rc.1/go.mod h1:NNlRaxZEdLqTs2+6yXiU2SHl8gKsbcy19Ii+Sfq53RM=
|
||||
k8s.io/component-base v0.18.0 h1:I+lP0fNfsEdTDpHaL61bCAqTZLoiWjEEP304Mo5ZQgE=
|
||||
k8s.io/component-base v0.18.0/go.mod h1:u3BCg0z1uskkzrnAKFzulmYaEpZF7XC9Pf/uFyb1v2c=
|
||||
k8s.io/gengo v0.0.0-20190128074634-0689ccc1d7d6/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0=
|
||||
k8s.io/gengo v0.0.0-20190822140433-26a664648505 h1:ZY6yclUKVbZ+SdWnkfY+Je5vrMpKOxmGeKRbsXVmqYM=
|
||||
k8s.io/gengo v0.0.0-20190822140433-26a664648505/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0=
|
||||
k8s.io/gengo v0.0.0-20200114144118-36b2048a9120 h1:RPscN6KhmG54S33L+lr3GS+oD1jmchIU0ll519K6FA4=
|
||||
k8s.io/gengo v0.0.0-20200114144118-36b2048a9120/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0=
|
||||
k8s.io/klog v0.0.0-20181102134211-b9b56d5dfc92/go.mod h1:Gq+BEi5rUBO/HRz0bTSXDUcqjScdoY3a9IHpCEIOOfk=
|
||||
k8s.io/klog v0.3.0/go.mod h1:Gq+BEi5rUBO/HRz0bTSXDUcqjScdoY3a9IHpCEIOOfk=
|
||||
k8s.io/klog v0.4.0 h1:lCJCxf/LIowc2IGS9TPjWDyXY4nOmdGdfcwwDQCOURQ=
|
||||
k8s.io/klog v0.4.0/go.mod h1:4Bi6QPql/J/LkTDqv7R/cd3hPo4k2DG6Ptcz060Ez5I=
|
||||
k8s.io/klog v1.0.0 h1:Pt+yjF5aB1xDSVbau4VsWe+dQNzA0qv1LlXdC2dF6Q8=
|
||||
k8s.io/klog v1.0.0/go.mod h1:4Bi6QPql/J/LkTDqv7R/cd3hPo4k2DG6Ptcz060Ez5I=
|
||||
k8s.io/kube-aggregator v0.17.3 h1:U7U/XHnKwQlvFmsEE6ubpjF0Y4AVhKtXo+9I3d0L6rY=
|
||||
k8s.io/kube-aggregator v0.17.3/go.mod h1:1dMwMFQbmH76RKF0614L7dNenMl3dwnUJuOOyZ3GMXA=
|
||||
k8s.io/kube-openapi v0.0.0-20190816220812-743ec37842bf h1:EYm5AW/UUDbnmnI+gK0TJDVK9qPLhM+sRHYanNKw0EQ=
|
||||
k8s.io/kube-openapi v0.0.0-20190816220812-743ec37842bf/go.mod h1:1TqjTSzOxsLGIKfj0lK8EeCP7K1iUG65v09OM0/WG5E=
|
||||
k8s.io/kube-openapi v0.0.0-20191107075043-30be4d16710a h1:UcxjrRMyNx/i/y8G7kPvLyy7rfbeuf1PYyBf973pgyU=
|
||||
k8s.io/kube-openapi v0.0.0-20191107075043-30be4d16710a/go.mod h1:1TqjTSzOxsLGIKfj0lK8EeCP7K1iUG65v09OM0/WG5E=
|
||||
k8s.io/utils v0.0.0-20190801114015-581e00157fb1 h1:+ySTxfHnfzZb9ys375PXNlLhkJPLKgHajBU0N62BDvE=
|
||||
k8s.io/utils v0.0.0-20190801114015-581e00157fb1/go.mod h1:sZAwmy6armz5eXlNoLmJcl4F1QuKu7sr+mFQ0byX7Ew=
|
||||
k8s.io/utils v0.0.0-20191114184206-e782cd3c129f h1:GiPwtSzdP43eI1hpPCbROQCCIgCuiMMNF8YUVLF3vJo=
|
||||
k8s.io/utils v0.0.0-20191114184206-e782cd3c129f/go.mod h1:sZAwmy6armz5eXlNoLmJcl4F1QuKu7sr+mFQ0byX7Ew=
|
||||
modernc.org/cc v1.0.0/go.mod h1:1Sk4//wdnYJiUIxnW8ddKpaOJCF37yAdqYnkxUpaYxw=
|
||||
modernc.org/golex v1.0.0/go.mod h1:b/QX9oBD/LhixY6NDh+IdGv17hgB+51fET1i2kPSmvk=
|
||||
modernc.org/mathutil v1.0.0/go.mod h1:wU0vUrJsVWBZ4P6e7xtFJEhFSNsfRLJ8H458uRjg03k=
|
||||
modernc.org/strutil v1.0.0/go.mod h1:lstksw84oURvj9y3tn8lGvRxyRC1S2+g5uuIzNfIOBs=
|
||||
modernc.org/xc v1.0.0/go.mod h1:mRNCo0bvLjGhHO9WsyuKVU4q0ceiDDDoEeWDJHrNx8I=
|
||||
sigs.k8s.io/controller-runtime v0.5.1-0.20200307095134-d0de78d9f1c1 h1:GolnBOlK7B/TxbPY3766BY6N+nsHzc/XHfxdCy7OuKs=
|
||||
sigs.k8s.io/controller-runtime v0.5.1-0.20200307095134-d0de78d9f1c1/go.mod h1:Uojny7gvg55YLQnEGnPzRE3dC4ik2tRlZJgOUCWXAV4=
|
||||
sigs.k8s.io/controller-tools v0.2.5 h1:kH7HKWed9XO42OTxyhUtqyImiefdZV2Q9Jbrytvhf18=
|
||||
sigs.k8s.io/controller-tools v0.2.5/go.mod h1:+t0Hz6tOhJQCdd7IYO0mNzimmiM9sqMU0021u6UCF2o=
|
||||
sigs.k8s.io/structured-merge-diff v0.0.0-20190525122527-15d366b2352e/go.mod h1:wWxsB5ozmmv/SG7nM11ayaAW51xMvak/t1r0CSlcokI=
|
||||
sigs.k8s.io/structured-merge-diff v0.0.0-20190817042607-6149e4549fca h1:6dsH6AYQWbyZmtttJNe8Gq1cXOeS1BdV3eW37zHilAQ=
|
||||
sigs.k8s.io/structured-merge-diff v0.0.0-20190817042607-6149e4549fca/go.mod h1:IIgPezJWb76P0hotTxzDbWsMYB8APh18qZnxkomBpxA=
|
||||
sigs.k8s.io/structured-merge-diff v1.0.1-0.20191108220359-b1b620dd3f06 h1:zD2IemQ4LmOcAumeiyDWXKUI2SO0NYDe3H6QGvPOVgU=
|
||||
sigs.k8s.io/structured-merge-diff v1.0.1-0.20191108220359-b1b620dd3f06/go.mod h1:/ULNhyfzRopfcjskuui0cTITekDduZ7ycKN3oUT9R18=
|
||||
k8s.io/kube-aggregator v0.18.0 h1:J+wa9FDQ3SbgyA8wQBNg2m2FMSm+mMQfs2A58500hs0=
|
||||
k8s.io/kube-aggregator v0.18.0/go.mod h1:ateewQ5QbjMZF/dihEFXwaEwoA4v/mayRvzfmvb6eqI=
|
||||
k8s.io/kube-openapi v0.0.0-20200121204235-bf4fb3bd569c h1:/KUFqjjqAcY4Us6luF5RDNZ16KJtb49HfR3ZHB9qYXM=
|
||||
k8s.io/kube-openapi v0.0.0-20200121204235-bf4fb3bd569c/go.mod h1:GRQhZsXIAJ1xR0C9bd8UpWHZ5plfAS9fzPjJuQ6JL3E=
|
||||
k8s.io/utils v0.0.0-20200229041039-0a110f9eb7ab h1:I3f2hcBrepGRXI1z4sukzAb8w1R4eqbsHrAsx06LGYM=
|
||||
k8s.io/utils v0.0.0-20200229041039-0a110f9eb7ab/go.mod h1:sZAwmy6armz5eXlNoLmJcl4F1QuKu7sr+mFQ0byX7Ew=
|
||||
k8s.io/utils v0.0.0-20200324210504-a9aa75ae1b89 h1:d4vVOjXm687F1iLSP2q3lyPPuyvTUt3aVoBpi2DqRsU=
|
||||
k8s.io/utils v0.0.0-20200324210504-a9aa75ae1b89/go.mod h1:sZAwmy6armz5eXlNoLmJcl4F1QuKu7sr+mFQ0byX7Ew=
|
||||
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.7 h1:uuHDyjllyzRyCIvvn0OBjiRB0SgBZGqHNYAmjR7fO50=
|
||||
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.7/go.mod h1:PHgbrJT7lCHcxMU+mDHEm+nx46H4zuuHZkDP6icnhu0=
|
||||
sigs.k8s.io/structured-merge-diff/v3 v3.0.0-20200116222232-67a7b8c61874/go.mod h1:PlARxl6Hbt/+BC80dRLi1qAmnMqwqDg62YvvVkZjemw=
|
||||
sigs.k8s.io/structured-merge-diff/v3 v3.0.0 h1:dOmIZBMfhcHS09XZkMyUgkq5trg3/jRyJYFZUiaOp8E=
|
||||
sigs.k8s.io/structured-merge-diff/v3 v3.0.0/go.mod h1:PlARxl6Hbt/+BC80dRLi1qAmnMqwqDg62YvvVkZjemw=
|
||||
sigs.k8s.io/testing_frameworks v0.1.2 h1:vK0+tvjF0BZ/RYFeZ1E6BYBwHJJXhjuZ3TdsEKH+UQM=
|
||||
sigs.k8s.io/testing_frameworks v0.1.2/go.mod h1:ToQrwSC3s8Xf/lADdZp3Mktcql9CG0UAmdJG9th5i0w=
|
||||
sigs.k8s.io/yaml v1.1.0 h1:4A07+ZFc2wgJwo8YNlQpr1rVlgUDlxXHhPJciaPY5gs=
|
||||
sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o=
|
||||
sigs.k8s.io/yaml v1.2.0 h1:kr/MCeFWJWTwyaHoR9c8EjH9OumOmoF9YGiZd7lFm/Q=
|
||||
sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc=
|
||||
software.sslmate.com/src/go-pkcs12 v0.0.0-20180114231543-2291e8f0f237 h1:iAEkCBPbRaflBgZ7o9gjVUuWuvWeV4sytFWg9o+Pj2k=
|
||||
software.sslmate.com/src/go-pkcs12 v0.0.0-20180114231543-2291e8f0f237/go.mod h1:/xvNRWUqm0+/ZMiF4EX00vrSCMsE4/NHb+Pt3freEeQ=
|
||||
|
||||
@@ -18,6 +18,7 @@ package main
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"context"
|
||||
"errors"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
@@ -83,7 +84,7 @@ var cmd = &cobra.Command{
|
||||
return err
|
||||
}
|
||||
|
||||
ingList, err := client.ExtensionsV1beta1().Ingresses("").List(metav1.ListOptions{})
|
||||
ingList, err := client.ExtensionsV1beta1().Ingresses("").List(context.TODO(), metav1.ListOptions{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
+90
-48
@@ -270,8 +270,8 @@ def go_repositories():
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "github.com/coreos/etcd",
|
||||
sum = "h1:+9RjdC18gMxNQVvSiXvObLu29mOFmkgdsB4cRTlV+EE=",
|
||||
version = "v3.3.15+incompatible",
|
||||
sum = "h1:jFneRYjIvLMLhDLCzuTuU4rSJUjRplcJQ7pD7MnhC04=",
|
||||
version = "v3.3.10+incompatible",
|
||||
)
|
||||
go_repository(
|
||||
name = "com_github_coreos_go_etcd",
|
||||
@@ -406,8 +406,8 @@ def go_repositories():
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "github.com/elazarl/goproxy",
|
||||
sum = "h1:p1yVGRW3nmb85p1Sh1ZJSDm4A4iKLS5QNbvUHMgGu/M=",
|
||||
version = "v0.0.0-20170405201442-c4fc26588b6e",
|
||||
sum = "h1:yUdfgN0XgIJw7foRItutHYUIhlcKzcSf5vDpdhQAKTc=",
|
||||
version = "v0.0.0-20180725130230-947c36da3153",
|
||||
)
|
||||
go_repository(
|
||||
name = "com_github_emicklei_go_restful",
|
||||
@@ -622,8 +622,8 @@ def go_repositories():
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "github.com/gogo/protobuf",
|
||||
sum = "h1:3PaI8p3seN09VjbTYC/QWlUZdZ1qS1zGjy7LH2Wt07I=",
|
||||
version = "v1.2.2-0.20190723190241-65acae22fc9d",
|
||||
sum = "h1:DqDEcV5aeaTmdFBePNpYsp3FlcVH/2ISVVM9Qf8PSls=",
|
||||
version = "v1.3.1",
|
||||
)
|
||||
go_repository(
|
||||
name = "com_github_golang_glog",
|
||||
@@ -702,8 +702,8 @@ def go_repositories():
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "github.com/google/gofuzz",
|
||||
sum = "h1:A8PeW59pxE9IoFRqBp37U+mSNaQoZ46F1f0f863XSXw=",
|
||||
version = "v1.0.0",
|
||||
sum = "h1:Hsa8mG0dQ46ij8Sl2AYJDUv1oA9/d6Vk+3LG99Oe02g=",
|
||||
version = "v1.1.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "com_github_google_martian",
|
||||
@@ -1455,8 +1455,8 @@ def go_repositories():
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "github.com/prometheus/client_model",
|
||||
sum = "h1:S/YWwWx/RA8rT8tKFRuGUZhuA90OyIBpPCXkcbwU8DE=",
|
||||
version = "v0.0.0-20190129233127-fd36f4220a90",
|
||||
sum = "h1:uq5h0d+GuxiXLJLNABMgp2qUWDPiLvgCzz2dUR+/W/M=",
|
||||
version = "v0.2.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "com_github_prometheus_common",
|
||||
@@ -1791,64 +1791,64 @@ def go_repositories():
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "k8s.io/api",
|
||||
sum = "h1:XAm3PZp3wnEdzekNkcmj/9Y1zdmQYJ1I4GKSBBZ8aG0=",
|
||||
version = "v0.17.3",
|
||||
sum = "h1:lwYk8Vt7rsVTwjRU6pzEsa9YNhThbmbocQlKvNBB4EQ=",
|
||||
version = "v0.18.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_apiextensions_apiserver",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "k8s.io/apiextensions-apiserver",
|
||||
sum = "h1:WDZWkPcbgvchEdDd7ysL21GGPx3UKZQLDZXEkevT6n4=",
|
||||
version = "v0.17.3",
|
||||
sum = "h1:HN4/P8vpGZFvB5SOMuPPH2Wt9Y/ryX+KRvIyAkchu1Q=",
|
||||
version = "v0.18.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_apimachinery",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "k8s.io/apimachinery",
|
||||
sum = "h1:f+uZV6rm4/tHE7xXgLyToprg6xWairaClGVkm2t8omg=",
|
||||
version = "v0.17.3",
|
||||
sum = "h1:fuPfYpk3cs1Okp/515pAf0dNhL66+8zk8RLbSX+EgAE=",
|
||||
version = "v0.18.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_apiserver",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "k8s.io/apiserver",
|
||||
sum = "h1:faZbSuFtJ4dx09vctKZGHms/7bp3qFtbqb10Swswqfs=",
|
||||
version = "v0.17.3",
|
||||
sum = "h1:ELAWpGWC6XdbRLi5lwAbEbvksD7hkXxPdxaJsdpist4=",
|
||||
version = "v0.18.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_client_go",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "k8s.io/client-go",
|
||||
sum = "h1:deUna1Ksx05XeESH6XGCyONNFfiQmDdqeqUvicvP6nU=",
|
||||
version = "v0.17.3",
|
||||
sum = "h1:yqKw4cTUQraZK3fcVCMeSa+lqKwcjZ5wtcOIPnxQno4=",
|
||||
version = "v0.18.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_code_generator",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "k8s.io/code-generator",
|
||||
sum = "h1:q/hDMk2cvFzSxol7k/VA1qCssR7VSMXHQHhzuX29VJ8=",
|
||||
version = "v0.17.3",
|
||||
sum = "h1:0xIRWzym+qMgVpGmLESDeMfz/orwgxwxFFAo1xfGNtQ=",
|
||||
version = "v0.18.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_component_base",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "k8s.io/component-base",
|
||||
sum = "h1:hQzTSshY14aLSR6WGIYvmw+w+u6V4d+iDR2iDGMrlUg=",
|
||||
version = "v0.17.3",
|
||||
sum = "h1:I+lP0fNfsEdTDpHaL61bCAqTZLoiWjEEP304Mo5ZQgE=",
|
||||
version = "v0.18.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_gengo",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "k8s.io/gengo",
|
||||
sum = "h1:ZY6yclUKVbZ+SdWnkfY+Je5vrMpKOxmGeKRbsXVmqYM=",
|
||||
version = "v0.0.0-20190822140433-26a664648505",
|
||||
sum = "h1:RPscN6KhmG54S33L+lr3GS+oD1jmchIU0ll519K6FA4=",
|
||||
version = "v0.0.0-20200114144118-36b2048a9120",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_klog",
|
||||
@@ -1863,32 +1863,34 @@ def go_repositories():
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "k8s.io/kube-aggregator",
|
||||
sum = "h1:U7U/XHnKwQlvFmsEE6ubpjF0Y4AVhKtXo+9I3d0L6rY=",
|
||||
version = "v0.17.3",
|
||||
sum = "h1:J+wa9FDQ3SbgyA8wQBNg2m2FMSm+mMQfs2A58500hs0=",
|
||||
version = "v0.18.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_kube_openapi",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "k8s.io/kube-openapi",
|
||||
sum = "h1:UcxjrRMyNx/i/y8G7kPvLyy7rfbeuf1PYyBf973pgyU=",
|
||||
version = "v0.0.0-20191107075043-30be4d16710a",
|
||||
sum = "h1:/KUFqjjqAcY4Us6luF5RDNZ16KJtb49HfR3ZHB9qYXM=",
|
||||
version = "v0.0.0-20200121204235-bf4fb3bd569c",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_sigs_controller_runtime",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "sigs.k8s.io/controller-runtime",
|
||||
sum = "h1:GolnBOlK7B/TxbPY3766BY6N+nsHzc/XHfxdCy7OuKs=",
|
||||
version = "v0.5.1-0.20200307095134-d0de78d9f1c1",
|
||||
replace = "github.com/munnerz/controller-runtime",
|
||||
sum = "h1:JVe6Zq1UU0+Sips4INYr3tmQYCBU8SsSx3UlGd9RPh8=",
|
||||
version = "v0.1.8-0.20200318092001-e22ac1073450",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_sigs_controller_tools",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "sigs.k8s.io/controller-tools",
|
||||
sum = "h1:kH7HKWed9XO42OTxyhUtqyImiefdZV2Q9Jbrytvhf18=",
|
||||
version = "v0.2.5",
|
||||
replace = "github.com/munnerz/controller-tools",
|
||||
sum = "h1:dTHZ9GYcAirNN04tOtCpRgqceNDzChH9y8IHnSAqeOU=",
|
||||
version = "v0.1.10-0.20200323145043-a2d268fbf03d",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_sigs_structured_merge_diff",
|
||||
@@ -1911,16 +1913,16 @@ def go_repositories():
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "sigs.k8s.io/yaml",
|
||||
sum = "h1:4A07+ZFc2wgJwo8YNlQpr1rVlgUDlxXHhPJciaPY5gs=",
|
||||
version = "v1.1.0",
|
||||
sum = "h1:kr/MCeFWJWTwyaHoR9c8EjH9OumOmoF9YGiZd7lFm/Q=",
|
||||
version = "v1.2.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_utils",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "k8s.io/utils",
|
||||
sum = "h1:GiPwtSzdP43eI1hpPCbROQCCIgCuiMMNF8YUVLF3vJo=",
|
||||
version = "v0.0.0-20191114184206-e782cd3c129f",
|
||||
sum = "h1:d4vVOjXm687F1iLSP2q3lyPPuyvTUt3aVoBpi2DqRsU=",
|
||||
version = "v0.0.0-20200324210504-a9aa75ae1b89",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_opencensus_go",
|
||||
@@ -1951,16 +1953,16 @@ def go_repositories():
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "google.golang.org/genproto",
|
||||
sum = "h1:nfPFGzJkUDX6uBmpN/pSw7MbOAWegH5QDQuoXFHedLg=",
|
||||
version = "v0.0.0-20190502173448-54afdca5d873",
|
||||
sum = "h1:gSJIx1SDwno+2ElGhA4+qG2zF97qiUzTM+rQ0klBOcE=",
|
||||
version = "v0.0.0-20190819201941-24fa4b261c55",
|
||||
)
|
||||
go_repository(
|
||||
name = "org_golang_google_grpc",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "google.golang.org/grpc",
|
||||
sum = "h1:q4XQuHFC6I28BKZpo6IYyb3mNO+l7lSOxRuYTCiDfXk=",
|
||||
version = "v1.23.1",
|
||||
sum = "h1:2dTRdpdFEEhJYQD8EMLB61nnrzSCTbG38PhqdhvOltg=",
|
||||
version = "v1.26.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "org_golang_x_crypto",
|
||||
@@ -1976,8 +1978,8 @@ def go_repositories():
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "golang.org/x/exp",
|
||||
sum = "h1:I6A9Ag9FpEKOjcKrRNjQkPHawoXIhKyTGfvvjFAiiAk=",
|
||||
version = "v0.0.0-20190312203227-4b39c73a6495",
|
||||
sum = "h1:c2HOrn5iMezYjSlGPncknSEr/8x5LELb/ilJbXi9DEA=",
|
||||
version = "v0.0.0-20190121172915-509febef88a4",
|
||||
)
|
||||
go_repository(
|
||||
name = "org_golang_x_image",
|
||||
@@ -2032,8 +2034,8 @@ def go_repositories():
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "golang.org/x/sys",
|
||||
sum = "h1:rOhMmluY6kLMhdnrivzec6lLgaVbMHMn2ISQXJeJ5EM=",
|
||||
version = "v0.0.0-20190922100055-0a153f010e69",
|
||||
sum = "h1:HmbHVPwrPEKPGLAcHSrMe6+hqSUlvZU0rab6x5EXfGU=",
|
||||
version = "v0.0.0-20191022100944-742c48ecaeb7",
|
||||
)
|
||||
go_repository(
|
||||
name = "org_golang_x_text",
|
||||
@@ -2272,8 +2274,8 @@ def go_repositories():
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "github.com/munnerz/crd-schema-fuzz",
|
||||
sum = "h1:gPv2n6t9+4/hMqRSgTCz1OpM4vx7lLgNxIsrUTtMBaA=",
|
||||
version = "v0.0.0-20191114184610-fbd148d44a0a",
|
||||
sum = "h1:8erI9yzEnOGw9K5O+a8zZdoo8N/OwrFi7c7SjBtkHAs=",
|
||||
version = "v1.0.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "com_github_agnivade_levenshtein",
|
||||
@@ -2507,3 +2509,43 @@ def go_repositories():
|
||||
sum = "h1:Qt8FeAtxE/vfdrLmR3rxR6JRE0RoVmbXu8+6kZtYU4k=",
|
||||
version = "v2.1.1",
|
||||
)
|
||||
go_repository(
|
||||
name = "com_github_census_instrumentation_opencensus_proto",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "github.com/census-instrumentation/opencensus-proto",
|
||||
sum = "h1:glEXhBS5PSLLv4IXzLA5yPRVX4bilULVyxxbrfOtDAk=",
|
||||
version = "v0.2.1",
|
||||
)
|
||||
go_repository(
|
||||
name = "com_github_envoyproxy_go_control_plane",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "github.com/envoyproxy/go-control-plane",
|
||||
sum = "h1:4cmBvAEBNJaGARUEs3/suWRyfyBfhf7I60WBZq+bv2w=",
|
||||
version = "v0.9.1-0.20191026205805-5f8ba28d4473",
|
||||
)
|
||||
go_repository(
|
||||
name = "com_github_envoyproxy_protoc_gen_validate",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "github.com/envoyproxy/protoc-gen-validate",
|
||||
sum = "h1:EQciDnbrYxy13PgWoY8AqoxGiPrpgBZ1R8UNe3ddc+A=",
|
||||
version = "v0.1.0",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_sigs_apiserver_network_proxy_konnectivity_client",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "sigs.k8s.io/apiserver-network-proxy/konnectivity-client",
|
||||
sum = "h1:uuHDyjllyzRyCIvvn0OBjiRB0SgBZGqHNYAmjR7fO50=",
|
||||
version = "v0.0.7",
|
||||
)
|
||||
go_repository(
|
||||
name = "io_k8s_sigs_structured_merge_diff_v3",
|
||||
build_file_generation = "on",
|
||||
build_file_proto_mode = "disable",
|
||||
importpath = "sigs.k8s.io/structured-merge-diff/v3",
|
||||
sum = "h1:dOmIZBMfhcHS09XZkMyUgkq5trg3/jRyJYFZUiaOp8E=",
|
||||
version = "v3.0.0",
|
||||
)
|
||||
|
||||
@@ -83,7 +83,7 @@ func NewForConfig(c *rest.Config) (*Clientset, error) {
|
||||
configShallowCopy := *c
|
||||
if configShallowCopy.RateLimiter == nil && configShallowCopy.QPS > 0 {
|
||||
if configShallowCopy.Burst <= 0 {
|
||||
return nil, fmt.Errorf("Burst is required to be greater than 0 when RateLimiter is not set and QPS is set to greater than 0")
|
||||
return nil, fmt.Errorf("burst is required to be greater than 0 when RateLimiter is not set and QPS is set to greater than 0")
|
||||
}
|
||||
configShallowCopy.RateLimiter = flowcontrol.NewTokenBucketRateLimiter(configShallowCopy.QPS, configShallowCopy.Burst)
|
||||
}
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha2
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1alpha2 "github.com/jetstack/cert-manager/pkg/apis/acme/v1alpha2"
|
||||
@@ -37,15 +38,15 @@ type ChallengesGetter interface {
|
||||
|
||||
// ChallengeInterface has methods to work with Challenge resources.
|
||||
type ChallengeInterface interface {
|
||||
Create(*v1alpha2.Challenge) (*v1alpha2.Challenge, error)
|
||||
Update(*v1alpha2.Challenge) (*v1alpha2.Challenge, error)
|
||||
UpdateStatus(*v1alpha2.Challenge) (*v1alpha2.Challenge, error)
|
||||
Delete(name string, options *v1.DeleteOptions) error
|
||||
DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error
|
||||
Get(name string, options v1.GetOptions) (*v1alpha2.Challenge, error)
|
||||
List(opts v1.ListOptions) (*v1alpha2.ChallengeList, error)
|
||||
Watch(opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.Challenge, err error)
|
||||
Create(ctx context.Context, challenge *v1alpha2.Challenge, opts v1.CreateOptions) (*v1alpha2.Challenge, error)
|
||||
Update(ctx context.Context, challenge *v1alpha2.Challenge, opts v1.UpdateOptions) (*v1alpha2.Challenge, error)
|
||||
UpdateStatus(ctx context.Context, challenge *v1alpha2.Challenge, opts v1.UpdateOptions) (*v1alpha2.Challenge, error)
|
||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha2.Challenge, error)
|
||||
List(ctx context.Context, opts v1.ListOptions) (*v1alpha2.ChallengeList, error)
|
||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.Challenge, err error)
|
||||
ChallengeExpansion
|
||||
}
|
||||
|
||||
@@ -64,20 +65,20 @@ func newChallenges(c *AcmeV1alpha2Client, namespace string) *challenges {
|
||||
}
|
||||
|
||||
// Get takes name of the challenge, and returns the corresponding challenge object, and an error if there is any.
|
||||
func (c *challenges) Get(name string, options v1.GetOptions) (result *v1alpha2.Challenge, err error) {
|
||||
func (c *challenges) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.Challenge, err error) {
|
||||
result = &v1alpha2.Challenge{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
Name(name).
|
||||
VersionedParams(&options, scheme.ParameterCodec).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Challenges that match those selectors.
|
||||
func (c *challenges) List(opts v1.ListOptions) (result *v1alpha2.ChallengeList, err error) {
|
||||
func (c *challenges) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.ChallengeList, err error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -88,13 +89,13 @@ func (c *challenges) List(opts v1.ListOptions) (result *v1alpha2.ChallengeList,
|
||||
Resource("challenges").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested challenges.
|
||||
func (c *challenges) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *challenges) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -105,87 +106,90 @@ func (c *challenges) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
Resource("challenges").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Watch()
|
||||
Watch(ctx)
|
||||
}
|
||||
|
||||
// Create takes the representation of a challenge and creates it. Returns the server's representation of the challenge, and an error, if there is any.
|
||||
func (c *challenges) Create(challenge *v1alpha2.Challenge) (result *v1alpha2.Challenge, err error) {
|
||||
func (c *challenges) Create(ctx context.Context, challenge *v1alpha2.Challenge, opts v1.CreateOptions) (result *v1alpha2.Challenge, err error) {
|
||||
result = &v1alpha2.Challenge{}
|
||||
err = c.client.Post().
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(challenge).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Update takes the representation of a challenge and updates it. Returns the server's representation of the challenge, and an error, if there is any.
|
||||
func (c *challenges) Update(challenge *v1alpha2.Challenge) (result *v1alpha2.Challenge, err error) {
|
||||
func (c *challenges) Update(ctx context.Context, challenge *v1alpha2.Challenge, opts v1.UpdateOptions) (result *v1alpha2.Challenge, err error) {
|
||||
result = &v1alpha2.Challenge{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
Name(challenge.Name).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(challenge).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
|
||||
func (c *challenges) UpdateStatus(challenge *v1alpha2.Challenge) (result *v1alpha2.Challenge, err error) {
|
||||
func (c *challenges) UpdateStatus(ctx context.Context, challenge *v1alpha2.Challenge, opts v1.UpdateOptions) (result *v1alpha2.Challenge, err error) {
|
||||
result = &v1alpha2.Challenge{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
Name(challenge.Name).
|
||||
SubResource("status").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(challenge).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Delete takes name of the challenge and deletes it. Returns an error if one occurs.
|
||||
func (c *challenges) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *challenges) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
Name(name).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *challenges) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
func (c *challenges) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
var timeout time.Duration
|
||||
if listOptions.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOptions.TimeoutSeconds) * time.Second
|
||||
if listOpts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
||||
}
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
VersionedParams(&listOptions, scheme.ParameterCodec).
|
||||
VersionedParams(&listOpts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched challenge.
|
||||
func (c *challenges) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.Challenge, err error) {
|
||||
func (c *challenges) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.Challenge, err error) {
|
||||
result = &v1alpha2.Challenge{}
|
||||
err = c.client.Patch(pt).
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
SubResource(subresources...).
|
||||
Name(name).
|
||||
SubResource(subresources...).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(data).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
@@ -19,6 +19,8 @@ limitations under the License.
|
||||
package fake
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
v1alpha2 "github.com/jetstack/cert-manager/pkg/apis/acme/v1alpha2"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
labels "k8s.io/apimachinery/pkg/labels"
|
||||
@@ -39,7 +41,7 @@ var challengesResource = schema.GroupVersionResource{Group: "acme.cert-manager.i
|
||||
var challengesKind = schema.GroupVersionKind{Group: "acme.cert-manager.io", Version: "v1alpha2", Kind: "Challenge"}
|
||||
|
||||
// Get takes name of the challenge, and returns the corresponding challenge object, and an error if there is any.
|
||||
func (c *FakeChallenges) Get(name string, options v1.GetOptions) (result *v1alpha2.Challenge, err error) {
|
||||
func (c *FakeChallenges) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.Challenge, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewGetAction(challengesResource, c.ns, name), &v1alpha2.Challenge{})
|
||||
|
||||
@@ -50,7 +52,7 @@ func (c *FakeChallenges) Get(name string, options v1.GetOptions) (result *v1alph
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Challenges that match those selectors.
|
||||
func (c *FakeChallenges) List(opts v1.ListOptions) (result *v1alpha2.ChallengeList, err error) {
|
||||
func (c *FakeChallenges) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.ChallengeList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewListAction(challengesResource, challengesKind, c.ns, opts), &v1alpha2.ChallengeList{})
|
||||
|
||||
@@ -72,14 +74,14 @@ func (c *FakeChallenges) List(opts v1.ListOptions) (result *v1alpha2.ChallengeLi
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested challenges.
|
||||
func (c *FakeChallenges) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *FakeChallenges) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
return c.Fake.
|
||||
InvokesWatch(testing.NewWatchAction(challengesResource, c.ns, opts))
|
||||
|
||||
}
|
||||
|
||||
// Create takes the representation of a challenge and creates it. Returns the server's representation of the challenge, and an error, if there is any.
|
||||
func (c *FakeChallenges) Create(challenge *v1alpha2.Challenge) (result *v1alpha2.Challenge, err error) {
|
||||
func (c *FakeChallenges) Create(ctx context.Context, challenge *v1alpha2.Challenge, opts v1.CreateOptions) (result *v1alpha2.Challenge, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewCreateAction(challengesResource, c.ns, challenge), &v1alpha2.Challenge{})
|
||||
|
||||
@@ -90,7 +92,7 @@ func (c *FakeChallenges) Create(challenge *v1alpha2.Challenge) (result *v1alpha2
|
||||
}
|
||||
|
||||
// Update takes the representation of a challenge and updates it. Returns the server's representation of the challenge, and an error, if there is any.
|
||||
func (c *FakeChallenges) Update(challenge *v1alpha2.Challenge) (result *v1alpha2.Challenge, err error) {
|
||||
func (c *FakeChallenges) Update(ctx context.Context, challenge *v1alpha2.Challenge, opts v1.UpdateOptions) (result *v1alpha2.Challenge, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateAction(challengesResource, c.ns, challenge), &v1alpha2.Challenge{})
|
||||
|
||||
@@ -102,7 +104,7 @@ func (c *FakeChallenges) Update(challenge *v1alpha2.Challenge) (result *v1alpha2
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeChallenges) UpdateStatus(challenge *v1alpha2.Challenge) (*v1alpha2.Challenge, error) {
|
||||
func (c *FakeChallenges) UpdateStatus(ctx context.Context, challenge *v1alpha2.Challenge, opts v1.UpdateOptions) (*v1alpha2.Challenge, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateSubresourceAction(challengesResource, "status", c.ns, challenge), &v1alpha2.Challenge{})
|
||||
|
||||
@@ -113,7 +115,7 @@ func (c *FakeChallenges) UpdateStatus(challenge *v1alpha2.Challenge) (*v1alpha2.
|
||||
}
|
||||
|
||||
// Delete takes name of the challenge and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeChallenges) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeChallenges) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewDeleteAction(challengesResource, c.ns, name), &v1alpha2.Challenge{})
|
||||
|
||||
@@ -121,15 +123,15 @@ func (c *FakeChallenges) Delete(name string, options *v1.DeleteOptions) error {
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *FakeChallenges) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(challengesResource, c.ns, listOptions)
|
||||
func (c *FakeChallenges) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(challengesResource, c.ns, listOpts)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &v1alpha2.ChallengeList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched challenge.
|
||||
func (c *FakeChallenges) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.Challenge, err error) {
|
||||
func (c *FakeChallenges) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.Challenge, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewPatchSubresourceAction(challengesResource, c.ns, name, pt, data, subresources...), &v1alpha2.Challenge{})
|
||||
|
||||
|
||||
@@ -19,6 +19,8 @@ limitations under the License.
|
||||
package fake
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
v1alpha2 "github.com/jetstack/cert-manager/pkg/apis/acme/v1alpha2"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
labels "k8s.io/apimachinery/pkg/labels"
|
||||
@@ -39,7 +41,7 @@ var ordersResource = schema.GroupVersionResource{Group: "acme.cert-manager.io",
|
||||
var ordersKind = schema.GroupVersionKind{Group: "acme.cert-manager.io", Version: "v1alpha2", Kind: "Order"}
|
||||
|
||||
// Get takes name of the order, and returns the corresponding order object, and an error if there is any.
|
||||
func (c *FakeOrders) Get(name string, options v1.GetOptions) (result *v1alpha2.Order, err error) {
|
||||
func (c *FakeOrders) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.Order, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewGetAction(ordersResource, c.ns, name), &v1alpha2.Order{})
|
||||
|
||||
@@ -50,7 +52,7 @@ func (c *FakeOrders) Get(name string, options v1.GetOptions) (result *v1alpha2.O
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Orders that match those selectors.
|
||||
func (c *FakeOrders) List(opts v1.ListOptions) (result *v1alpha2.OrderList, err error) {
|
||||
func (c *FakeOrders) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.OrderList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewListAction(ordersResource, ordersKind, c.ns, opts), &v1alpha2.OrderList{})
|
||||
|
||||
@@ -72,14 +74,14 @@ func (c *FakeOrders) List(opts v1.ListOptions) (result *v1alpha2.OrderList, err
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested orders.
|
||||
func (c *FakeOrders) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *FakeOrders) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
return c.Fake.
|
||||
InvokesWatch(testing.NewWatchAction(ordersResource, c.ns, opts))
|
||||
|
||||
}
|
||||
|
||||
// Create takes the representation of a order and creates it. Returns the server's representation of the order, and an error, if there is any.
|
||||
func (c *FakeOrders) Create(order *v1alpha2.Order) (result *v1alpha2.Order, err error) {
|
||||
func (c *FakeOrders) Create(ctx context.Context, order *v1alpha2.Order, opts v1.CreateOptions) (result *v1alpha2.Order, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewCreateAction(ordersResource, c.ns, order), &v1alpha2.Order{})
|
||||
|
||||
@@ -90,7 +92,7 @@ func (c *FakeOrders) Create(order *v1alpha2.Order) (result *v1alpha2.Order, err
|
||||
}
|
||||
|
||||
// Update takes the representation of a order and updates it. Returns the server's representation of the order, and an error, if there is any.
|
||||
func (c *FakeOrders) Update(order *v1alpha2.Order) (result *v1alpha2.Order, err error) {
|
||||
func (c *FakeOrders) Update(ctx context.Context, order *v1alpha2.Order, opts v1.UpdateOptions) (result *v1alpha2.Order, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateAction(ordersResource, c.ns, order), &v1alpha2.Order{})
|
||||
|
||||
@@ -102,7 +104,7 @@ func (c *FakeOrders) Update(order *v1alpha2.Order) (result *v1alpha2.Order, err
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeOrders) UpdateStatus(order *v1alpha2.Order) (*v1alpha2.Order, error) {
|
||||
func (c *FakeOrders) UpdateStatus(ctx context.Context, order *v1alpha2.Order, opts v1.UpdateOptions) (*v1alpha2.Order, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateSubresourceAction(ordersResource, "status", c.ns, order), &v1alpha2.Order{})
|
||||
|
||||
@@ -113,7 +115,7 @@ func (c *FakeOrders) UpdateStatus(order *v1alpha2.Order) (*v1alpha2.Order, error
|
||||
}
|
||||
|
||||
// Delete takes name of the order and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeOrders) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeOrders) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewDeleteAction(ordersResource, c.ns, name), &v1alpha2.Order{})
|
||||
|
||||
@@ -121,15 +123,15 @@ func (c *FakeOrders) Delete(name string, options *v1.DeleteOptions) error {
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *FakeOrders) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(ordersResource, c.ns, listOptions)
|
||||
func (c *FakeOrders) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(ordersResource, c.ns, listOpts)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &v1alpha2.OrderList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched order.
|
||||
func (c *FakeOrders) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.Order, err error) {
|
||||
func (c *FakeOrders) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.Order, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewPatchSubresourceAction(ordersResource, c.ns, name, pt, data, subresources...), &v1alpha2.Order{})
|
||||
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha2
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1alpha2 "github.com/jetstack/cert-manager/pkg/apis/acme/v1alpha2"
|
||||
@@ -37,15 +38,15 @@ type OrdersGetter interface {
|
||||
|
||||
// OrderInterface has methods to work with Order resources.
|
||||
type OrderInterface interface {
|
||||
Create(*v1alpha2.Order) (*v1alpha2.Order, error)
|
||||
Update(*v1alpha2.Order) (*v1alpha2.Order, error)
|
||||
UpdateStatus(*v1alpha2.Order) (*v1alpha2.Order, error)
|
||||
Delete(name string, options *v1.DeleteOptions) error
|
||||
DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error
|
||||
Get(name string, options v1.GetOptions) (*v1alpha2.Order, error)
|
||||
List(opts v1.ListOptions) (*v1alpha2.OrderList, error)
|
||||
Watch(opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.Order, err error)
|
||||
Create(ctx context.Context, order *v1alpha2.Order, opts v1.CreateOptions) (*v1alpha2.Order, error)
|
||||
Update(ctx context.Context, order *v1alpha2.Order, opts v1.UpdateOptions) (*v1alpha2.Order, error)
|
||||
UpdateStatus(ctx context.Context, order *v1alpha2.Order, opts v1.UpdateOptions) (*v1alpha2.Order, error)
|
||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha2.Order, error)
|
||||
List(ctx context.Context, opts v1.ListOptions) (*v1alpha2.OrderList, error)
|
||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.Order, err error)
|
||||
OrderExpansion
|
||||
}
|
||||
|
||||
@@ -64,20 +65,20 @@ func newOrders(c *AcmeV1alpha2Client, namespace string) *orders {
|
||||
}
|
||||
|
||||
// Get takes name of the order, and returns the corresponding order object, and an error if there is any.
|
||||
func (c *orders) Get(name string, options v1.GetOptions) (result *v1alpha2.Order, err error) {
|
||||
func (c *orders) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.Order, err error) {
|
||||
result = &v1alpha2.Order{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
Name(name).
|
||||
VersionedParams(&options, scheme.ParameterCodec).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Orders that match those selectors.
|
||||
func (c *orders) List(opts v1.ListOptions) (result *v1alpha2.OrderList, err error) {
|
||||
func (c *orders) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.OrderList, err error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -88,13 +89,13 @@ func (c *orders) List(opts v1.ListOptions) (result *v1alpha2.OrderList, err erro
|
||||
Resource("orders").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested orders.
|
||||
func (c *orders) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *orders) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -105,87 +106,90 @@ func (c *orders) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
Resource("orders").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Watch()
|
||||
Watch(ctx)
|
||||
}
|
||||
|
||||
// Create takes the representation of a order and creates it. Returns the server's representation of the order, and an error, if there is any.
|
||||
func (c *orders) Create(order *v1alpha2.Order) (result *v1alpha2.Order, err error) {
|
||||
func (c *orders) Create(ctx context.Context, order *v1alpha2.Order, opts v1.CreateOptions) (result *v1alpha2.Order, err error) {
|
||||
result = &v1alpha2.Order{}
|
||||
err = c.client.Post().
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(order).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Update takes the representation of a order and updates it. Returns the server's representation of the order, and an error, if there is any.
|
||||
func (c *orders) Update(order *v1alpha2.Order) (result *v1alpha2.Order, err error) {
|
||||
func (c *orders) Update(ctx context.Context, order *v1alpha2.Order, opts v1.UpdateOptions) (result *v1alpha2.Order, err error) {
|
||||
result = &v1alpha2.Order{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
Name(order.Name).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(order).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
|
||||
func (c *orders) UpdateStatus(order *v1alpha2.Order) (result *v1alpha2.Order, err error) {
|
||||
func (c *orders) UpdateStatus(ctx context.Context, order *v1alpha2.Order, opts v1.UpdateOptions) (result *v1alpha2.Order, err error) {
|
||||
result = &v1alpha2.Order{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
Name(order.Name).
|
||||
SubResource("status").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(order).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Delete takes name of the order and deletes it. Returns an error if one occurs.
|
||||
func (c *orders) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *orders) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
Name(name).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *orders) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
func (c *orders) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
var timeout time.Duration
|
||||
if listOptions.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOptions.TimeoutSeconds) * time.Second
|
||||
if listOpts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
||||
}
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
VersionedParams(&listOptions, scheme.ParameterCodec).
|
||||
VersionedParams(&listOpts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched order.
|
||||
func (c *orders) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.Order, err error) {
|
||||
func (c *orders) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.Order, err error) {
|
||||
result = &v1alpha2.Order{}
|
||||
err = c.client.Patch(pt).
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
SubResource(subresources...).
|
||||
Name(name).
|
||||
SubResource(subresources...).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(data).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1alpha3 "github.com/jetstack/cert-manager/pkg/apis/acme/v1alpha3"
|
||||
@@ -37,15 +38,15 @@ type ChallengesGetter interface {
|
||||
|
||||
// ChallengeInterface has methods to work with Challenge resources.
|
||||
type ChallengeInterface interface {
|
||||
Create(*v1alpha3.Challenge) (*v1alpha3.Challenge, error)
|
||||
Update(*v1alpha3.Challenge) (*v1alpha3.Challenge, error)
|
||||
UpdateStatus(*v1alpha3.Challenge) (*v1alpha3.Challenge, error)
|
||||
Delete(name string, options *v1.DeleteOptions) error
|
||||
DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error
|
||||
Get(name string, options v1.GetOptions) (*v1alpha3.Challenge, error)
|
||||
List(opts v1.ListOptions) (*v1alpha3.ChallengeList, error)
|
||||
Watch(opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.Challenge, err error)
|
||||
Create(ctx context.Context, challenge *v1alpha3.Challenge, opts v1.CreateOptions) (*v1alpha3.Challenge, error)
|
||||
Update(ctx context.Context, challenge *v1alpha3.Challenge, opts v1.UpdateOptions) (*v1alpha3.Challenge, error)
|
||||
UpdateStatus(ctx context.Context, challenge *v1alpha3.Challenge, opts v1.UpdateOptions) (*v1alpha3.Challenge, error)
|
||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha3.Challenge, error)
|
||||
List(ctx context.Context, opts v1.ListOptions) (*v1alpha3.ChallengeList, error)
|
||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.Challenge, err error)
|
||||
ChallengeExpansion
|
||||
}
|
||||
|
||||
@@ -64,20 +65,20 @@ func newChallenges(c *AcmeV1alpha3Client, namespace string) *challenges {
|
||||
}
|
||||
|
||||
// Get takes name of the challenge, and returns the corresponding challenge object, and an error if there is any.
|
||||
func (c *challenges) Get(name string, options v1.GetOptions) (result *v1alpha3.Challenge, err error) {
|
||||
func (c *challenges) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha3.Challenge, err error) {
|
||||
result = &v1alpha3.Challenge{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
Name(name).
|
||||
VersionedParams(&options, scheme.ParameterCodec).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Challenges that match those selectors.
|
||||
func (c *challenges) List(opts v1.ListOptions) (result *v1alpha3.ChallengeList, err error) {
|
||||
func (c *challenges) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha3.ChallengeList, err error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -88,13 +89,13 @@ func (c *challenges) List(opts v1.ListOptions) (result *v1alpha3.ChallengeList,
|
||||
Resource("challenges").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested challenges.
|
||||
func (c *challenges) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *challenges) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -105,87 +106,90 @@ func (c *challenges) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
Resource("challenges").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Watch()
|
||||
Watch(ctx)
|
||||
}
|
||||
|
||||
// Create takes the representation of a challenge and creates it. Returns the server's representation of the challenge, and an error, if there is any.
|
||||
func (c *challenges) Create(challenge *v1alpha3.Challenge) (result *v1alpha3.Challenge, err error) {
|
||||
func (c *challenges) Create(ctx context.Context, challenge *v1alpha3.Challenge, opts v1.CreateOptions) (result *v1alpha3.Challenge, err error) {
|
||||
result = &v1alpha3.Challenge{}
|
||||
err = c.client.Post().
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(challenge).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Update takes the representation of a challenge and updates it. Returns the server's representation of the challenge, and an error, if there is any.
|
||||
func (c *challenges) Update(challenge *v1alpha3.Challenge) (result *v1alpha3.Challenge, err error) {
|
||||
func (c *challenges) Update(ctx context.Context, challenge *v1alpha3.Challenge, opts v1.UpdateOptions) (result *v1alpha3.Challenge, err error) {
|
||||
result = &v1alpha3.Challenge{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
Name(challenge.Name).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(challenge).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
|
||||
func (c *challenges) UpdateStatus(challenge *v1alpha3.Challenge) (result *v1alpha3.Challenge, err error) {
|
||||
func (c *challenges) UpdateStatus(ctx context.Context, challenge *v1alpha3.Challenge, opts v1.UpdateOptions) (result *v1alpha3.Challenge, err error) {
|
||||
result = &v1alpha3.Challenge{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
Name(challenge.Name).
|
||||
SubResource("status").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(challenge).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Delete takes name of the challenge and deletes it. Returns an error if one occurs.
|
||||
func (c *challenges) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *challenges) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
Name(name).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *challenges) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
func (c *challenges) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
var timeout time.Duration
|
||||
if listOptions.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOptions.TimeoutSeconds) * time.Second
|
||||
if listOpts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
||||
}
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
VersionedParams(&listOptions, scheme.ParameterCodec).
|
||||
VersionedParams(&listOpts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched challenge.
|
||||
func (c *challenges) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.Challenge, err error) {
|
||||
func (c *challenges) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.Challenge, err error) {
|
||||
result = &v1alpha3.Challenge{}
|
||||
err = c.client.Patch(pt).
|
||||
Namespace(c.ns).
|
||||
Resource("challenges").
|
||||
SubResource(subresources...).
|
||||
Name(name).
|
||||
SubResource(subresources...).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(data).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
@@ -19,6 +19,8 @@ limitations under the License.
|
||||
package fake
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
v1alpha3 "github.com/jetstack/cert-manager/pkg/apis/acme/v1alpha3"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
labels "k8s.io/apimachinery/pkg/labels"
|
||||
@@ -39,7 +41,7 @@ var challengesResource = schema.GroupVersionResource{Group: "acme.cert-manager.i
|
||||
var challengesKind = schema.GroupVersionKind{Group: "acme.cert-manager.io", Version: "v1alpha3", Kind: "Challenge"}
|
||||
|
||||
// Get takes name of the challenge, and returns the corresponding challenge object, and an error if there is any.
|
||||
func (c *FakeChallenges) Get(name string, options v1.GetOptions) (result *v1alpha3.Challenge, err error) {
|
||||
func (c *FakeChallenges) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha3.Challenge, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewGetAction(challengesResource, c.ns, name), &v1alpha3.Challenge{})
|
||||
|
||||
@@ -50,7 +52,7 @@ func (c *FakeChallenges) Get(name string, options v1.GetOptions) (result *v1alph
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Challenges that match those selectors.
|
||||
func (c *FakeChallenges) List(opts v1.ListOptions) (result *v1alpha3.ChallengeList, err error) {
|
||||
func (c *FakeChallenges) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha3.ChallengeList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewListAction(challengesResource, challengesKind, c.ns, opts), &v1alpha3.ChallengeList{})
|
||||
|
||||
@@ -72,14 +74,14 @@ func (c *FakeChallenges) List(opts v1.ListOptions) (result *v1alpha3.ChallengeLi
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested challenges.
|
||||
func (c *FakeChallenges) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *FakeChallenges) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
return c.Fake.
|
||||
InvokesWatch(testing.NewWatchAction(challengesResource, c.ns, opts))
|
||||
|
||||
}
|
||||
|
||||
// Create takes the representation of a challenge and creates it. Returns the server's representation of the challenge, and an error, if there is any.
|
||||
func (c *FakeChallenges) Create(challenge *v1alpha3.Challenge) (result *v1alpha3.Challenge, err error) {
|
||||
func (c *FakeChallenges) Create(ctx context.Context, challenge *v1alpha3.Challenge, opts v1.CreateOptions) (result *v1alpha3.Challenge, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewCreateAction(challengesResource, c.ns, challenge), &v1alpha3.Challenge{})
|
||||
|
||||
@@ -90,7 +92,7 @@ func (c *FakeChallenges) Create(challenge *v1alpha3.Challenge) (result *v1alpha3
|
||||
}
|
||||
|
||||
// Update takes the representation of a challenge and updates it. Returns the server's representation of the challenge, and an error, if there is any.
|
||||
func (c *FakeChallenges) Update(challenge *v1alpha3.Challenge) (result *v1alpha3.Challenge, err error) {
|
||||
func (c *FakeChallenges) Update(ctx context.Context, challenge *v1alpha3.Challenge, opts v1.UpdateOptions) (result *v1alpha3.Challenge, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateAction(challengesResource, c.ns, challenge), &v1alpha3.Challenge{})
|
||||
|
||||
@@ -102,7 +104,7 @@ func (c *FakeChallenges) Update(challenge *v1alpha3.Challenge) (result *v1alpha3
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeChallenges) UpdateStatus(challenge *v1alpha3.Challenge) (*v1alpha3.Challenge, error) {
|
||||
func (c *FakeChallenges) UpdateStatus(ctx context.Context, challenge *v1alpha3.Challenge, opts v1.UpdateOptions) (*v1alpha3.Challenge, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateSubresourceAction(challengesResource, "status", c.ns, challenge), &v1alpha3.Challenge{})
|
||||
|
||||
@@ -113,7 +115,7 @@ func (c *FakeChallenges) UpdateStatus(challenge *v1alpha3.Challenge) (*v1alpha3.
|
||||
}
|
||||
|
||||
// Delete takes name of the challenge and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeChallenges) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeChallenges) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewDeleteAction(challengesResource, c.ns, name), &v1alpha3.Challenge{})
|
||||
|
||||
@@ -121,15 +123,15 @@ func (c *FakeChallenges) Delete(name string, options *v1.DeleteOptions) error {
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *FakeChallenges) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(challengesResource, c.ns, listOptions)
|
||||
func (c *FakeChallenges) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(challengesResource, c.ns, listOpts)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &v1alpha3.ChallengeList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched challenge.
|
||||
func (c *FakeChallenges) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.Challenge, err error) {
|
||||
func (c *FakeChallenges) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.Challenge, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewPatchSubresourceAction(challengesResource, c.ns, name, pt, data, subresources...), &v1alpha3.Challenge{})
|
||||
|
||||
|
||||
@@ -19,6 +19,8 @@ limitations under the License.
|
||||
package fake
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
v1alpha3 "github.com/jetstack/cert-manager/pkg/apis/acme/v1alpha3"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
labels "k8s.io/apimachinery/pkg/labels"
|
||||
@@ -39,7 +41,7 @@ var ordersResource = schema.GroupVersionResource{Group: "acme.cert-manager.io",
|
||||
var ordersKind = schema.GroupVersionKind{Group: "acme.cert-manager.io", Version: "v1alpha3", Kind: "Order"}
|
||||
|
||||
// Get takes name of the order, and returns the corresponding order object, and an error if there is any.
|
||||
func (c *FakeOrders) Get(name string, options v1.GetOptions) (result *v1alpha3.Order, err error) {
|
||||
func (c *FakeOrders) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha3.Order, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewGetAction(ordersResource, c.ns, name), &v1alpha3.Order{})
|
||||
|
||||
@@ -50,7 +52,7 @@ func (c *FakeOrders) Get(name string, options v1.GetOptions) (result *v1alpha3.O
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Orders that match those selectors.
|
||||
func (c *FakeOrders) List(opts v1.ListOptions) (result *v1alpha3.OrderList, err error) {
|
||||
func (c *FakeOrders) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha3.OrderList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewListAction(ordersResource, ordersKind, c.ns, opts), &v1alpha3.OrderList{})
|
||||
|
||||
@@ -72,14 +74,14 @@ func (c *FakeOrders) List(opts v1.ListOptions) (result *v1alpha3.OrderList, err
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested orders.
|
||||
func (c *FakeOrders) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *FakeOrders) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
return c.Fake.
|
||||
InvokesWatch(testing.NewWatchAction(ordersResource, c.ns, opts))
|
||||
|
||||
}
|
||||
|
||||
// Create takes the representation of a order and creates it. Returns the server's representation of the order, and an error, if there is any.
|
||||
func (c *FakeOrders) Create(order *v1alpha3.Order) (result *v1alpha3.Order, err error) {
|
||||
func (c *FakeOrders) Create(ctx context.Context, order *v1alpha3.Order, opts v1.CreateOptions) (result *v1alpha3.Order, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewCreateAction(ordersResource, c.ns, order), &v1alpha3.Order{})
|
||||
|
||||
@@ -90,7 +92,7 @@ func (c *FakeOrders) Create(order *v1alpha3.Order) (result *v1alpha3.Order, err
|
||||
}
|
||||
|
||||
// Update takes the representation of a order and updates it. Returns the server's representation of the order, and an error, if there is any.
|
||||
func (c *FakeOrders) Update(order *v1alpha3.Order) (result *v1alpha3.Order, err error) {
|
||||
func (c *FakeOrders) Update(ctx context.Context, order *v1alpha3.Order, opts v1.UpdateOptions) (result *v1alpha3.Order, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateAction(ordersResource, c.ns, order), &v1alpha3.Order{})
|
||||
|
||||
@@ -102,7 +104,7 @@ func (c *FakeOrders) Update(order *v1alpha3.Order) (result *v1alpha3.Order, err
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeOrders) UpdateStatus(order *v1alpha3.Order) (*v1alpha3.Order, error) {
|
||||
func (c *FakeOrders) UpdateStatus(ctx context.Context, order *v1alpha3.Order, opts v1.UpdateOptions) (*v1alpha3.Order, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateSubresourceAction(ordersResource, "status", c.ns, order), &v1alpha3.Order{})
|
||||
|
||||
@@ -113,7 +115,7 @@ func (c *FakeOrders) UpdateStatus(order *v1alpha3.Order) (*v1alpha3.Order, error
|
||||
}
|
||||
|
||||
// Delete takes name of the order and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeOrders) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeOrders) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewDeleteAction(ordersResource, c.ns, name), &v1alpha3.Order{})
|
||||
|
||||
@@ -121,15 +123,15 @@ func (c *FakeOrders) Delete(name string, options *v1.DeleteOptions) error {
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *FakeOrders) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(ordersResource, c.ns, listOptions)
|
||||
func (c *FakeOrders) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(ordersResource, c.ns, listOpts)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &v1alpha3.OrderList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched order.
|
||||
func (c *FakeOrders) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.Order, err error) {
|
||||
func (c *FakeOrders) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.Order, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewPatchSubresourceAction(ordersResource, c.ns, name, pt, data, subresources...), &v1alpha3.Order{})
|
||||
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1alpha3 "github.com/jetstack/cert-manager/pkg/apis/acme/v1alpha3"
|
||||
@@ -37,15 +38,15 @@ type OrdersGetter interface {
|
||||
|
||||
// OrderInterface has methods to work with Order resources.
|
||||
type OrderInterface interface {
|
||||
Create(*v1alpha3.Order) (*v1alpha3.Order, error)
|
||||
Update(*v1alpha3.Order) (*v1alpha3.Order, error)
|
||||
UpdateStatus(*v1alpha3.Order) (*v1alpha3.Order, error)
|
||||
Delete(name string, options *v1.DeleteOptions) error
|
||||
DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error
|
||||
Get(name string, options v1.GetOptions) (*v1alpha3.Order, error)
|
||||
List(opts v1.ListOptions) (*v1alpha3.OrderList, error)
|
||||
Watch(opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.Order, err error)
|
||||
Create(ctx context.Context, order *v1alpha3.Order, opts v1.CreateOptions) (*v1alpha3.Order, error)
|
||||
Update(ctx context.Context, order *v1alpha3.Order, opts v1.UpdateOptions) (*v1alpha3.Order, error)
|
||||
UpdateStatus(ctx context.Context, order *v1alpha3.Order, opts v1.UpdateOptions) (*v1alpha3.Order, error)
|
||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha3.Order, error)
|
||||
List(ctx context.Context, opts v1.ListOptions) (*v1alpha3.OrderList, error)
|
||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.Order, err error)
|
||||
OrderExpansion
|
||||
}
|
||||
|
||||
@@ -64,20 +65,20 @@ func newOrders(c *AcmeV1alpha3Client, namespace string) *orders {
|
||||
}
|
||||
|
||||
// Get takes name of the order, and returns the corresponding order object, and an error if there is any.
|
||||
func (c *orders) Get(name string, options v1.GetOptions) (result *v1alpha3.Order, err error) {
|
||||
func (c *orders) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha3.Order, err error) {
|
||||
result = &v1alpha3.Order{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
Name(name).
|
||||
VersionedParams(&options, scheme.ParameterCodec).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Orders that match those selectors.
|
||||
func (c *orders) List(opts v1.ListOptions) (result *v1alpha3.OrderList, err error) {
|
||||
func (c *orders) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha3.OrderList, err error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -88,13 +89,13 @@ func (c *orders) List(opts v1.ListOptions) (result *v1alpha3.OrderList, err erro
|
||||
Resource("orders").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested orders.
|
||||
func (c *orders) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *orders) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -105,87 +106,90 @@ func (c *orders) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
Resource("orders").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Watch()
|
||||
Watch(ctx)
|
||||
}
|
||||
|
||||
// Create takes the representation of a order and creates it. Returns the server's representation of the order, and an error, if there is any.
|
||||
func (c *orders) Create(order *v1alpha3.Order) (result *v1alpha3.Order, err error) {
|
||||
func (c *orders) Create(ctx context.Context, order *v1alpha3.Order, opts v1.CreateOptions) (result *v1alpha3.Order, err error) {
|
||||
result = &v1alpha3.Order{}
|
||||
err = c.client.Post().
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(order).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Update takes the representation of a order and updates it. Returns the server's representation of the order, and an error, if there is any.
|
||||
func (c *orders) Update(order *v1alpha3.Order) (result *v1alpha3.Order, err error) {
|
||||
func (c *orders) Update(ctx context.Context, order *v1alpha3.Order, opts v1.UpdateOptions) (result *v1alpha3.Order, err error) {
|
||||
result = &v1alpha3.Order{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
Name(order.Name).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(order).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
|
||||
func (c *orders) UpdateStatus(order *v1alpha3.Order) (result *v1alpha3.Order, err error) {
|
||||
func (c *orders) UpdateStatus(ctx context.Context, order *v1alpha3.Order, opts v1.UpdateOptions) (result *v1alpha3.Order, err error) {
|
||||
result = &v1alpha3.Order{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
Name(order.Name).
|
||||
SubResource("status").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(order).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Delete takes name of the order and deletes it. Returns an error if one occurs.
|
||||
func (c *orders) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *orders) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
Name(name).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *orders) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
func (c *orders) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
var timeout time.Duration
|
||||
if listOptions.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOptions.TimeoutSeconds) * time.Second
|
||||
if listOpts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
||||
}
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
VersionedParams(&listOptions, scheme.ParameterCodec).
|
||||
VersionedParams(&listOpts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched order.
|
||||
func (c *orders) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.Order, err error) {
|
||||
func (c *orders) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.Order, err error) {
|
||||
result = &v1alpha3.Order{}
|
||||
err = c.client.Patch(pt).
|
||||
Namespace(c.ns).
|
||||
Resource("orders").
|
||||
SubResource(subresources...).
|
||||
Name(name).
|
||||
SubResource(subresources...).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(data).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha2
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1alpha2 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
@@ -37,15 +38,15 @@ type CertificatesGetter interface {
|
||||
|
||||
// CertificateInterface has methods to work with Certificate resources.
|
||||
type CertificateInterface interface {
|
||||
Create(*v1alpha2.Certificate) (*v1alpha2.Certificate, error)
|
||||
Update(*v1alpha2.Certificate) (*v1alpha2.Certificate, error)
|
||||
UpdateStatus(*v1alpha2.Certificate) (*v1alpha2.Certificate, error)
|
||||
Delete(name string, options *v1.DeleteOptions) error
|
||||
DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error
|
||||
Get(name string, options v1.GetOptions) (*v1alpha2.Certificate, error)
|
||||
List(opts v1.ListOptions) (*v1alpha2.CertificateList, error)
|
||||
Watch(opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.Certificate, err error)
|
||||
Create(ctx context.Context, certificate *v1alpha2.Certificate, opts v1.CreateOptions) (*v1alpha2.Certificate, error)
|
||||
Update(ctx context.Context, certificate *v1alpha2.Certificate, opts v1.UpdateOptions) (*v1alpha2.Certificate, error)
|
||||
UpdateStatus(ctx context.Context, certificate *v1alpha2.Certificate, opts v1.UpdateOptions) (*v1alpha2.Certificate, error)
|
||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha2.Certificate, error)
|
||||
List(ctx context.Context, opts v1.ListOptions) (*v1alpha2.CertificateList, error)
|
||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.Certificate, err error)
|
||||
CertificateExpansion
|
||||
}
|
||||
|
||||
@@ -64,20 +65,20 @@ func newCertificates(c *CertmanagerV1alpha2Client, namespace string) *certificat
|
||||
}
|
||||
|
||||
// Get takes name of the certificate, and returns the corresponding certificate object, and an error if there is any.
|
||||
func (c *certificates) Get(name string, options v1.GetOptions) (result *v1alpha2.Certificate, err error) {
|
||||
func (c *certificates) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.Certificate, err error) {
|
||||
result = &v1alpha2.Certificate{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
Name(name).
|
||||
VersionedParams(&options, scheme.ParameterCodec).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Certificates that match those selectors.
|
||||
func (c *certificates) List(opts v1.ListOptions) (result *v1alpha2.CertificateList, err error) {
|
||||
func (c *certificates) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.CertificateList, err error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -88,13 +89,13 @@ func (c *certificates) List(opts v1.ListOptions) (result *v1alpha2.CertificateLi
|
||||
Resource("certificates").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested certificates.
|
||||
func (c *certificates) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *certificates) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -105,87 +106,90 @@ func (c *certificates) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
Resource("certificates").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Watch()
|
||||
Watch(ctx)
|
||||
}
|
||||
|
||||
// Create takes the representation of a certificate and creates it. Returns the server's representation of the certificate, and an error, if there is any.
|
||||
func (c *certificates) Create(certificate *v1alpha2.Certificate) (result *v1alpha2.Certificate, err error) {
|
||||
func (c *certificates) Create(ctx context.Context, certificate *v1alpha2.Certificate, opts v1.CreateOptions) (result *v1alpha2.Certificate, err error) {
|
||||
result = &v1alpha2.Certificate{}
|
||||
err = c.client.Post().
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(certificate).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Update takes the representation of a certificate and updates it. Returns the server's representation of the certificate, and an error, if there is any.
|
||||
func (c *certificates) Update(certificate *v1alpha2.Certificate) (result *v1alpha2.Certificate, err error) {
|
||||
func (c *certificates) Update(ctx context.Context, certificate *v1alpha2.Certificate, opts v1.UpdateOptions) (result *v1alpha2.Certificate, err error) {
|
||||
result = &v1alpha2.Certificate{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
Name(certificate.Name).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(certificate).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
|
||||
func (c *certificates) UpdateStatus(certificate *v1alpha2.Certificate) (result *v1alpha2.Certificate, err error) {
|
||||
func (c *certificates) UpdateStatus(ctx context.Context, certificate *v1alpha2.Certificate, opts v1.UpdateOptions) (result *v1alpha2.Certificate, err error) {
|
||||
result = &v1alpha2.Certificate{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
Name(certificate.Name).
|
||||
SubResource("status").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(certificate).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Delete takes name of the certificate and deletes it. Returns an error if one occurs.
|
||||
func (c *certificates) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *certificates) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
Name(name).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *certificates) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
func (c *certificates) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
var timeout time.Duration
|
||||
if listOptions.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOptions.TimeoutSeconds) * time.Second
|
||||
if listOpts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
||||
}
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
VersionedParams(&listOptions, scheme.ParameterCodec).
|
||||
VersionedParams(&listOpts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched certificate.
|
||||
func (c *certificates) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.Certificate, err error) {
|
||||
func (c *certificates) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.Certificate, err error) {
|
||||
result = &v1alpha2.Certificate{}
|
||||
err = c.client.Patch(pt).
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
SubResource(subresources...).
|
||||
Name(name).
|
||||
SubResource(subresources...).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(data).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha2
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1alpha2 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
@@ -37,15 +38,15 @@ type CertificateRequestsGetter interface {
|
||||
|
||||
// CertificateRequestInterface has methods to work with CertificateRequest resources.
|
||||
type CertificateRequestInterface interface {
|
||||
Create(*v1alpha2.CertificateRequest) (*v1alpha2.CertificateRequest, error)
|
||||
Update(*v1alpha2.CertificateRequest) (*v1alpha2.CertificateRequest, error)
|
||||
UpdateStatus(*v1alpha2.CertificateRequest) (*v1alpha2.CertificateRequest, error)
|
||||
Delete(name string, options *v1.DeleteOptions) error
|
||||
DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error
|
||||
Get(name string, options v1.GetOptions) (*v1alpha2.CertificateRequest, error)
|
||||
List(opts v1.ListOptions) (*v1alpha2.CertificateRequestList, error)
|
||||
Watch(opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.CertificateRequest, err error)
|
||||
Create(ctx context.Context, certificateRequest *v1alpha2.CertificateRequest, opts v1.CreateOptions) (*v1alpha2.CertificateRequest, error)
|
||||
Update(ctx context.Context, certificateRequest *v1alpha2.CertificateRequest, opts v1.UpdateOptions) (*v1alpha2.CertificateRequest, error)
|
||||
UpdateStatus(ctx context.Context, certificateRequest *v1alpha2.CertificateRequest, opts v1.UpdateOptions) (*v1alpha2.CertificateRequest, error)
|
||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha2.CertificateRequest, error)
|
||||
List(ctx context.Context, opts v1.ListOptions) (*v1alpha2.CertificateRequestList, error)
|
||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.CertificateRequest, err error)
|
||||
CertificateRequestExpansion
|
||||
}
|
||||
|
||||
@@ -64,20 +65,20 @@ func newCertificateRequests(c *CertmanagerV1alpha2Client, namespace string) *cer
|
||||
}
|
||||
|
||||
// Get takes name of the certificateRequest, and returns the corresponding certificateRequest object, and an error if there is any.
|
||||
func (c *certificateRequests) Get(name string, options v1.GetOptions) (result *v1alpha2.CertificateRequest, err error) {
|
||||
func (c *certificateRequests) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.CertificateRequest, err error) {
|
||||
result = &v1alpha2.CertificateRequest{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
Name(name).
|
||||
VersionedParams(&options, scheme.ParameterCodec).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of CertificateRequests that match those selectors.
|
||||
func (c *certificateRequests) List(opts v1.ListOptions) (result *v1alpha2.CertificateRequestList, err error) {
|
||||
func (c *certificateRequests) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.CertificateRequestList, err error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -88,13 +89,13 @@ func (c *certificateRequests) List(opts v1.ListOptions) (result *v1alpha2.Certif
|
||||
Resource("certificaterequests").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested certificateRequests.
|
||||
func (c *certificateRequests) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *certificateRequests) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -105,87 +106,90 @@ func (c *certificateRequests) Watch(opts v1.ListOptions) (watch.Interface, error
|
||||
Resource("certificaterequests").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Watch()
|
||||
Watch(ctx)
|
||||
}
|
||||
|
||||
// Create takes the representation of a certificateRequest and creates it. Returns the server's representation of the certificateRequest, and an error, if there is any.
|
||||
func (c *certificateRequests) Create(certificateRequest *v1alpha2.CertificateRequest) (result *v1alpha2.CertificateRequest, err error) {
|
||||
func (c *certificateRequests) Create(ctx context.Context, certificateRequest *v1alpha2.CertificateRequest, opts v1.CreateOptions) (result *v1alpha2.CertificateRequest, err error) {
|
||||
result = &v1alpha2.CertificateRequest{}
|
||||
err = c.client.Post().
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(certificateRequest).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Update takes the representation of a certificateRequest and updates it. Returns the server's representation of the certificateRequest, and an error, if there is any.
|
||||
func (c *certificateRequests) Update(certificateRequest *v1alpha2.CertificateRequest) (result *v1alpha2.CertificateRequest, err error) {
|
||||
func (c *certificateRequests) Update(ctx context.Context, certificateRequest *v1alpha2.CertificateRequest, opts v1.UpdateOptions) (result *v1alpha2.CertificateRequest, err error) {
|
||||
result = &v1alpha2.CertificateRequest{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
Name(certificateRequest.Name).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(certificateRequest).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
|
||||
func (c *certificateRequests) UpdateStatus(certificateRequest *v1alpha2.CertificateRequest) (result *v1alpha2.CertificateRequest, err error) {
|
||||
func (c *certificateRequests) UpdateStatus(ctx context.Context, certificateRequest *v1alpha2.CertificateRequest, opts v1.UpdateOptions) (result *v1alpha2.CertificateRequest, err error) {
|
||||
result = &v1alpha2.CertificateRequest{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
Name(certificateRequest.Name).
|
||||
SubResource("status").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(certificateRequest).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Delete takes name of the certificateRequest and deletes it. Returns an error if one occurs.
|
||||
func (c *certificateRequests) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *certificateRequests) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
Name(name).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *certificateRequests) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
func (c *certificateRequests) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
var timeout time.Duration
|
||||
if listOptions.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOptions.TimeoutSeconds) * time.Second
|
||||
if listOpts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
||||
}
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
VersionedParams(&listOptions, scheme.ParameterCodec).
|
||||
VersionedParams(&listOpts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched certificateRequest.
|
||||
func (c *certificateRequests) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.CertificateRequest, err error) {
|
||||
func (c *certificateRequests) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.CertificateRequest, err error) {
|
||||
result = &v1alpha2.CertificateRequest{}
|
||||
err = c.client.Patch(pt).
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
SubResource(subresources...).
|
||||
Name(name).
|
||||
SubResource(subresources...).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(data).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha2
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1alpha2 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
@@ -37,15 +38,15 @@ type ClusterIssuersGetter interface {
|
||||
|
||||
// ClusterIssuerInterface has methods to work with ClusterIssuer resources.
|
||||
type ClusterIssuerInterface interface {
|
||||
Create(*v1alpha2.ClusterIssuer) (*v1alpha2.ClusterIssuer, error)
|
||||
Update(*v1alpha2.ClusterIssuer) (*v1alpha2.ClusterIssuer, error)
|
||||
UpdateStatus(*v1alpha2.ClusterIssuer) (*v1alpha2.ClusterIssuer, error)
|
||||
Delete(name string, options *v1.DeleteOptions) error
|
||||
DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error
|
||||
Get(name string, options v1.GetOptions) (*v1alpha2.ClusterIssuer, error)
|
||||
List(opts v1.ListOptions) (*v1alpha2.ClusterIssuerList, error)
|
||||
Watch(opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.ClusterIssuer, err error)
|
||||
Create(ctx context.Context, clusterIssuer *v1alpha2.ClusterIssuer, opts v1.CreateOptions) (*v1alpha2.ClusterIssuer, error)
|
||||
Update(ctx context.Context, clusterIssuer *v1alpha2.ClusterIssuer, opts v1.UpdateOptions) (*v1alpha2.ClusterIssuer, error)
|
||||
UpdateStatus(ctx context.Context, clusterIssuer *v1alpha2.ClusterIssuer, opts v1.UpdateOptions) (*v1alpha2.ClusterIssuer, error)
|
||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha2.ClusterIssuer, error)
|
||||
List(ctx context.Context, opts v1.ListOptions) (*v1alpha2.ClusterIssuerList, error)
|
||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.ClusterIssuer, err error)
|
||||
ClusterIssuerExpansion
|
||||
}
|
||||
|
||||
@@ -62,19 +63,19 @@ func newClusterIssuers(c *CertmanagerV1alpha2Client) *clusterIssuers {
|
||||
}
|
||||
|
||||
// Get takes name of the clusterIssuer, and returns the corresponding clusterIssuer object, and an error if there is any.
|
||||
func (c *clusterIssuers) Get(name string, options v1.GetOptions) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
func (c *clusterIssuers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
result = &v1alpha2.ClusterIssuer{}
|
||||
err = c.client.Get().
|
||||
Resource("clusterissuers").
|
||||
Name(name).
|
||||
VersionedParams(&options, scheme.ParameterCodec).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of ClusterIssuers that match those selectors.
|
||||
func (c *clusterIssuers) List(opts v1.ListOptions) (result *v1alpha2.ClusterIssuerList, err error) {
|
||||
func (c *clusterIssuers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.ClusterIssuerList, err error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -84,13 +85,13 @@ func (c *clusterIssuers) List(opts v1.ListOptions) (result *v1alpha2.ClusterIssu
|
||||
Resource("clusterissuers").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested clusterIssuers.
|
||||
func (c *clusterIssuers) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *clusterIssuers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -100,81 +101,84 @@ func (c *clusterIssuers) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
Resource("clusterissuers").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Watch()
|
||||
Watch(ctx)
|
||||
}
|
||||
|
||||
// Create takes the representation of a clusterIssuer and creates it. Returns the server's representation of the clusterIssuer, and an error, if there is any.
|
||||
func (c *clusterIssuers) Create(clusterIssuer *v1alpha2.ClusterIssuer) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
func (c *clusterIssuers) Create(ctx context.Context, clusterIssuer *v1alpha2.ClusterIssuer, opts v1.CreateOptions) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
result = &v1alpha2.ClusterIssuer{}
|
||||
err = c.client.Post().
|
||||
Resource("clusterissuers").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(clusterIssuer).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Update takes the representation of a clusterIssuer and updates it. Returns the server's representation of the clusterIssuer, and an error, if there is any.
|
||||
func (c *clusterIssuers) Update(clusterIssuer *v1alpha2.ClusterIssuer) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
func (c *clusterIssuers) Update(ctx context.Context, clusterIssuer *v1alpha2.ClusterIssuer, opts v1.UpdateOptions) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
result = &v1alpha2.ClusterIssuer{}
|
||||
err = c.client.Put().
|
||||
Resource("clusterissuers").
|
||||
Name(clusterIssuer.Name).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(clusterIssuer).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
|
||||
func (c *clusterIssuers) UpdateStatus(clusterIssuer *v1alpha2.ClusterIssuer) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
func (c *clusterIssuers) UpdateStatus(ctx context.Context, clusterIssuer *v1alpha2.ClusterIssuer, opts v1.UpdateOptions) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
result = &v1alpha2.ClusterIssuer{}
|
||||
err = c.client.Put().
|
||||
Resource("clusterissuers").
|
||||
Name(clusterIssuer.Name).
|
||||
SubResource("status").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(clusterIssuer).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Delete takes name of the clusterIssuer and deletes it. Returns an error if one occurs.
|
||||
func (c *clusterIssuers) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *clusterIssuers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Resource("clusterissuers").
|
||||
Name(name).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *clusterIssuers) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
func (c *clusterIssuers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
var timeout time.Duration
|
||||
if listOptions.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOptions.TimeoutSeconds) * time.Second
|
||||
if listOpts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
||||
}
|
||||
return c.client.Delete().
|
||||
Resource("clusterissuers").
|
||||
VersionedParams(&listOptions, scheme.ParameterCodec).
|
||||
VersionedParams(&listOpts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched clusterIssuer.
|
||||
func (c *clusterIssuers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
func (c *clusterIssuers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
result = &v1alpha2.ClusterIssuer{}
|
||||
err = c.client.Patch(pt).
|
||||
Resource("clusterissuers").
|
||||
SubResource(subresources...).
|
||||
Name(name).
|
||||
SubResource(subresources...).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(data).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
+12
-10
@@ -19,6 +19,8 @@ limitations under the License.
|
||||
package fake
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
v1alpha2 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
labels "k8s.io/apimachinery/pkg/labels"
|
||||
@@ -39,7 +41,7 @@ var certificatesResource = schema.GroupVersionResource{Group: "cert-manager.io",
|
||||
var certificatesKind = schema.GroupVersionKind{Group: "cert-manager.io", Version: "v1alpha2", Kind: "Certificate"}
|
||||
|
||||
// Get takes name of the certificate, and returns the corresponding certificate object, and an error if there is any.
|
||||
func (c *FakeCertificates) Get(name string, options v1.GetOptions) (result *v1alpha2.Certificate, err error) {
|
||||
func (c *FakeCertificates) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.Certificate, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewGetAction(certificatesResource, c.ns, name), &v1alpha2.Certificate{})
|
||||
|
||||
@@ -50,7 +52,7 @@ func (c *FakeCertificates) Get(name string, options v1.GetOptions) (result *v1al
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Certificates that match those selectors.
|
||||
func (c *FakeCertificates) List(opts v1.ListOptions) (result *v1alpha2.CertificateList, err error) {
|
||||
func (c *FakeCertificates) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.CertificateList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewListAction(certificatesResource, certificatesKind, c.ns, opts), &v1alpha2.CertificateList{})
|
||||
|
||||
@@ -72,14 +74,14 @@ func (c *FakeCertificates) List(opts v1.ListOptions) (result *v1alpha2.Certifica
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested certificates.
|
||||
func (c *FakeCertificates) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *FakeCertificates) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
return c.Fake.
|
||||
InvokesWatch(testing.NewWatchAction(certificatesResource, c.ns, opts))
|
||||
|
||||
}
|
||||
|
||||
// Create takes the representation of a certificate and creates it. Returns the server's representation of the certificate, and an error, if there is any.
|
||||
func (c *FakeCertificates) Create(certificate *v1alpha2.Certificate) (result *v1alpha2.Certificate, err error) {
|
||||
func (c *FakeCertificates) Create(ctx context.Context, certificate *v1alpha2.Certificate, opts v1.CreateOptions) (result *v1alpha2.Certificate, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewCreateAction(certificatesResource, c.ns, certificate), &v1alpha2.Certificate{})
|
||||
|
||||
@@ -90,7 +92,7 @@ func (c *FakeCertificates) Create(certificate *v1alpha2.Certificate) (result *v1
|
||||
}
|
||||
|
||||
// Update takes the representation of a certificate and updates it. Returns the server's representation of the certificate, and an error, if there is any.
|
||||
func (c *FakeCertificates) Update(certificate *v1alpha2.Certificate) (result *v1alpha2.Certificate, err error) {
|
||||
func (c *FakeCertificates) Update(ctx context.Context, certificate *v1alpha2.Certificate, opts v1.UpdateOptions) (result *v1alpha2.Certificate, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateAction(certificatesResource, c.ns, certificate), &v1alpha2.Certificate{})
|
||||
|
||||
@@ -102,7 +104,7 @@ func (c *FakeCertificates) Update(certificate *v1alpha2.Certificate) (result *v1
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeCertificates) UpdateStatus(certificate *v1alpha2.Certificate) (*v1alpha2.Certificate, error) {
|
||||
func (c *FakeCertificates) UpdateStatus(ctx context.Context, certificate *v1alpha2.Certificate, opts v1.UpdateOptions) (*v1alpha2.Certificate, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateSubresourceAction(certificatesResource, "status", c.ns, certificate), &v1alpha2.Certificate{})
|
||||
|
||||
@@ -113,7 +115,7 @@ func (c *FakeCertificates) UpdateStatus(certificate *v1alpha2.Certificate) (*v1a
|
||||
}
|
||||
|
||||
// Delete takes name of the certificate and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeCertificates) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeCertificates) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewDeleteAction(certificatesResource, c.ns, name), &v1alpha2.Certificate{})
|
||||
|
||||
@@ -121,15 +123,15 @@ func (c *FakeCertificates) Delete(name string, options *v1.DeleteOptions) error
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *FakeCertificates) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(certificatesResource, c.ns, listOptions)
|
||||
func (c *FakeCertificates) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(certificatesResource, c.ns, listOpts)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &v1alpha2.CertificateList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched certificate.
|
||||
func (c *FakeCertificates) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.Certificate, err error) {
|
||||
func (c *FakeCertificates) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.Certificate, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewPatchSubresourceAction(certificatesResource, c.ns, name, pt, data, subresources...), &v1alpha2.Certificate{})
|
||||
|
||||
|
||||
+12
-10
@@ -19,6 +19,8 @@ limitations under the License.
|
||||
package fake
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
v1alpha2 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
labels "k8s.io/apimachinery/pkg/labels"
|
||||
@@ -39,7 +41,7 @@ var certificaterequestsResource = schema.GroupVersionResource{Group: "cert-manag
|
||||
var certificaterequestsKind = schema.GroupVersionKind{Group: "cert-manager.io", Version: "v1alpha2", Kind: "CertificateRequest"}
|
||||
|
||||
// Get takes name of the certificateRequest, and returns the corresponding certificateRequest object, and an error if there is any.
|
||||
func (c *FakeCertificateRequests) Get(name string, options v1.GetOptions) (result *v1alpha2.CertificateRequest, err error) {
|
||||
func (c *FakeCertificateRequests) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.CertificateRequest, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewGetAction(certificaterequestsResource, c.ns, name), &v1alpha2.CertificateRequest{})
|
||||
|
||||
@@ -50,7 +52,7 @@ func (c *FakeCertificateRequests) Get(name string, options v1.GetOptions) (resul
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of CertificateRequests that match those selectors.
|
||||
func (c *FakeCertificateRequests) List(opts v1.ListOptions) (result *v1alpha2.CertificateRequestList, err error) {
|
||||
func (c *FakeCertificateRequests) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.CertificateRequestList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewListAction(certificaterequestsResource, certificaterequestsKind, c.ns, opts), &v1alpha2.CertificateRequestList{})
|
||||
|
||||
@@ -72,14 +74,14 @@ func (c *FakeCertificateRequests) List(opts v1.ListOptions) (result *v1alpha2.Ce
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested certificateRequests.
|
||||
func (c *FakeCertificateRequests) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *FakeCertificateRequests) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
return c.Fake.
|
||||
InvokesWatch(testing.NewWatchAction(certificaterequestsResource, c.ns, opts))
|
||||
|
||||
}
|
||||
|
||||
// Create takes the representation of a certificateRequest and creates it. Returns the server's representation of the certificateRequest, and an error, if there is any.
|
||||
func (c *FakeCertificateRequests) Create(certificateRequest *v1alpha2.CertificateRequest) (result *v1alpha2.CertificateRequest, err error) {
|
||||
func (c *FakeCertificateRequests) Create(ctx context.Context, certificateRequest *v1alpha2.CertificateRequest, opts v1.CreateOptions) (result *v1alpha2.CertificateRequest, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewCreateAction(certificaterequestsResource, c.ns, certificateRequest), &v1alpha2.CertificateRequest{})
|
||||
|
||||
@@ -90,7 +92,7 @@ func (c *FakeCertificateRequests) Create(certificateRequest *v1alpha2.Certificat
|
||||
}
|
||||
|
||||
// Update takes the representation of a certificateRequest and updates it. Returns the server's representation of the certificateRequest, and an error, if there is any.
|
||||
func (c *FakeCertificateRequests) Update(certificateRequest *v1alpha2.CertificateRequest) (result *v1alpha2.CertificateRequest, err error) {
|
||||
func (c *FakeCertificateRequests) Update(ctx context.Context, certificateRequest *v1alpha2.CertificateRequest, opts v1.UpdateOptions) (result *v1alpha2.CertificateRequest, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateAction(certificaterequestsResource, c.ns, certificateRequest), &v1alpha2.CertificateRequest{})
|
||||
|
||||
@@ -102,7 +104,7 @@ func (c *FakeCertificateRequests) Update(certificateRequest *v1alpha2.Certificat
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeCertificateRequests) UpdateStatus(certificateRequest *v1alpha2.CertificateRequest) (*v1alpha2.CertificateRequest, error) {
|
||||
func (c *FakeCertificateRequests) UpdateStatus(ctx context.Context, certificateRequest *v1alpha2.CertificateRequest, opts v1.UpdateOptions) (*v1alpha2.CertificateRequest, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateSubresourceAction(certificaterequestsResource, "status", c.ns, certificateRequest), &v1alpha2.CertificateRequest{})
|
||||
|
||||
@@ -113,7 +115,7 @@ func (c *FakeCertificateRequests) UpdateStatus(certificateRequest *v1alpha2.Cert
|
||||
}
|
||||
|
||||
// Delete takes name of the certificateRequest and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeCertificateRequests) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeCertificateRequests) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewDeleteAction(certificaterequestsResource, c.ns, name), &v1alpha2.CertificateRequest{})
|
||||
|
||||
@@ -121,15 +123,15 @@ func (c *FakeCertificateRequests) Delete(name string, options *v1.DeleteOptions)
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *FakeCertificateRequests) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(certificaterequestsResource, c.ns, listOptions)
|
||||
func (c *FakeCertificateRequests) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(certificaterequestsResource, c.ns, listOpts)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &v1alpha2.CertificateRequestList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched certificateRequest.
|
||||
func (c *FakeCertificateRequests) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.CertificateRequest, err error) {
|
||||
func (c *FakeCertificateRequests) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.CertificateRequest, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewPatchSubresourceAction(certificaterequestsResource, c.ns, name, pt, data, subresources...), &v1alpha2.CertificateRequest{})
|
||||
|
||||
|
||||
+12
-10
@@ -19,6 +19,8 @@ limitations under the License.
|
||||
package fake
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
v1alpha2 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
labels "k8s.io/apimachinery/pkg/labels"
|
||||
@@ -38,7 +40,7 @@ var clusterissuersResource = schema.GroupVersionResource{Group: "cert-manager.io
|
||||
var clusterissuersKind = schema.GroupVersionKind{Group: "cert-manager.io", Version: "v1alpha2", Kind: "ClusterIssuer"}
|
||||
|
||||
// Get takes name of the clusterIssuer, and returns the corresponding clusterIssuer object, and an error if there is any.
|
||||
func (c *FakeClusterIssuers) Get(name string, options v1.GetOptions) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
func (c *FakeClusterIssuers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootGetAction(clusterissuersResource, name), &v1alpha2.ClusterIssuer{})
|
||||
if obj == nil {
|
||||
@@ -48,7 +50,7 @@ func (c *FakeClusterIssuers) Get(name string, options v1.GetOptions) (result *v1
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of ClusterIssuers that match those selectors.
|
||||
func (c *FakeClusterIssuers) List(opts v1.ListOptions) (result *v1alpha2.ClusterIssuerList, err error) {
|
||||
func (c *FakeClusterIssuers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.ClusterIssuerList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootListAction(clusterissuersResource, clusterissuersKind, opts), &v1alpha2.ClusterIssuerList{})
|
||||
if obj == nil {
|
||||
@@ -69,13 +71,13 @@ func (c *FakeClusterIssuers) List(opts v1.ListOptions) (result *v1alpha2.Cluster
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested clusterIssuers.
|
||||
func (c *FakeClusterIssuers) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *FakeClusterIssuers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
return c.Fake.
|
||||
InvokesWatch(testing.NewRootWatchAction(clusterissuersResource, opts))
|
||||
}
|
||||
|
||||
// Create takes the representation of a clusterIssuer and creates it. Returns the server's representation of the clusterIssuer, and an error, if there is any.
|
||||
func (c *FakeClusterIssuers) Create(clusterIssuer *v1alpha2.ClusterIssuer) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
func (c *FakeClusterIssuers) Create(ctx context.Context, clusterIssuer *v1alpha2.ClusterIssuer, opts v1.CreateOptions) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootCreateAction(clusterissuersResource, clusterIssuer), &v1alpha2.ClusterIssuer{})
|
||||
if obj == nil {
|
||||
@@ -85,7 +87,7 @@ func (c *FakeClusterIssuers) Create(clusterIssuer *v1alpha2.ClusterIssuer) (resu
|
||||
}
|
||||
|
||||
// Update takes the representation of a clusterIssuer and updates it. Returns the server's representation of the clusterIssuer, and an error, if there is any.
|
||||
func (c *FakeClusterIssuers) Update(clusterIssuer *v1alpha2.ClusterIssuer) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
func (c *FakeClusterIssuers) Update(ctx context.Context, clusterIssuer *v1alpha2.ClusterIssuer, opts v1.UpdateOptions) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootUpdateAction(clusterissuersResource, clusterIssuer), &v1alpha2.ClusterIssuer{})
|
||||
if obj == nil {
|
||||
@@ -96,7 +98,7 @@ func (c *FakeClusterIssuers) Update(clusterIssuer *v1alpha2.ClusterIssuer) (resu
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeClusterIssuers) UpdateStatus(clusterIssuer *v1alpha2.ClusterIssuer) (*v1alpha2.ClusterIssuer, error) {
|
||||
func (c *FakeClusterIssuers) UpdateStatus(ctx context.Context, clusterIssuer *v1alpha2.ClusterIssuer, opts v1.UpdateOptions) (*v1alpha2.ClusterIssuer, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootUpdateSubresourceAction(clusterissuersResource, "status", clusterIssuer), &v1alpha2.ClusterIssuer{})
|
||||
if obj == nil {
|
||||
@@ -106,22 +108,22 @@ func (c *FakeClusterIssuers) UpdateStatus(clusterIssuer *v1alpha2.ClusterIssuer)
|
||||
}
|
||||
|
||||
// Delete takes name of the clusterIssuer and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeClusterIssuers) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeClusterIssuers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewRootDeleteAction(clusterissuersResource, name), &v1alpha2.ClusterIssuer{})
|
||||
return err
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *FakeClusterIssuers) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewRootDeleteCollectionAction(clusterissuersResource, listOptions)
|
||||
func (c *FakeClusterIssuers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
action := testing.NewRootDeleteCollectionAction(clusterissuersResource, listOpts)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &v1alpha2.ClusterIssuerList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched clusterIssuer.
|
||||
func (c *FakeClusterIssuers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
func (c *FakeClusterIssuers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.ClusterIssuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootPatchSubresourceAction(clusterissuersResource, name, pt, data, subresources...), &v1alpha2.ClusterIssuer{})
|
||||
if obj == nil {
|
||||
|
||||
@@ -19,6 +19,8 @@ limitations under the License.
|
||||
package fake
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
v1alpha2 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
labels "k8s.io/apimachinery/pkg/labels"
|
||||
@@ -39,7 +41,7 @@ var issuersResource = schema.GroupVersionResource{Group: "cert-manager.io", Vers
|
||||
var issuersKind = schema.GroupVersionKind{Group: "cert-manager.io", Version: "v1alpha2", Kind: "Issuer"}
|
||||
|
||||
// Get takes name of the issuer, and returns the corresponding issuer object, and an error if there is any.
|
||||
func (c *FakeIssuers) Get(name string, options v1.GetOptions) (result *v1alpha2.Issuer, err error) {
|
||||
func (c *FakeIssuers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.Issuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewGetAction(issuersResource, c.ns, name), &v1alpha2.Issuer{})
|
||||
|
||||
@@ -50,7 +52,7 @@ func (c *FakeIssuers) Get(name string, options v1.GetOptions) (result *v1alpha2.
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Issuers that match those selectors.
|
||||
func (c *FakeIssuers) List(opts v1.ListOptions) (result *v1alpha2.IssuerList, err error) {
|
||||
func (c *FakeIssuers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.IssuerList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewListAction(issuersResource, issuersKind, c.ns, opts), &v1alpha2.IssuerList{})
|
||||
|
||||
@@ -72,14 +74,14 @@ func (c *FakeIssuers) List(opts v1.ListOptions) (result *v1alpha2.IssuerList, er
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested issuers.
|
||||
func (c *FakeIssuers) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *FakeIssuers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
return c.Fake.
|
||||
InvokesWatch(testing.NewWatchAction(issuersResource, c.ns, opts))
|
||||
|
||||
}
|
||||
|
||||
// Create takes the representation of a issuer and creates it. Returns the server's representation of the issuer, and an error, if there is any.
|
||||
func (c *FakeIssuers) Create(issuer *v1alpha2.Issuer) (result *v1alpha2.Issuer, err error) {
|
||||
func (c *FakeIssuers) Create(ctx context.Context, issuer *v1alpha2.Issuer, opts v1.CreateOptions) (result *v1alpha2.Issuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewCreateAction(issuersResource, c.ns, issuer), &v1alpha2.Issuer{})
|
||||
|
||||
@@ -90,7 +92,7 @@ func (c *FakeIssuers) Create(issuer *v1alpha2.Issuer) (result *v1alpha2.Issuer,
|
||||
}
|
||||
|
||||
// Update takes the representation of a issuer and updates it. Returns the server's representation of the issuer, and an error, if there is any.
|
||||
func (c *FakeIssuers) Update(issuer *v1alpha2.Issuer) (result *v1alpha2.Issuer, err error) {
|
||||
func (c *FakeIssuers) Update(ctx context.Context, issuer *v1alpha2.Issuer, opts v1.UpdateOptions) (result *v1alpha2.Issuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateAction(issuersResource, c.ns, issuer), &v1alpha2.Issuer{})
|
||||
|
||||
@@ -102,7 +104,7 @@ func (c *FakeIssuers) Update(issuer *v1alpha2.Issuer) (result *v1alpha2.Issuer,
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeIssuers) UpdateStatus(issuer *v1alpha2.Issuer) (*v1alpha2.Issuer, error) {
|
||||
func (c *FakeIssuers) UpdateStatus(ctx context.Context, issuer *v1alpha2.Issuer, opts v1.UpdateOptions) (*v1alpha2.Issuer, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateSubresourceAction(issuersResource, "status", c.ns, issuer), &v1alpha2.Issuer{})
|
||||
|
||||
@@ -113,7 +115,7 @@ func (c *FakeIssuers) UpdateStatus(issuer *v1alpha2.Issuer) (*v1alpha2.Issuer, e
|
||||
}
|
||||
|
||||
// Delete takes name of the issuer and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeIssuers) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeIssuers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewDeleteAction(issuersResource, c.ns, name), &v1alpha2.Issuer{})
|
||||
|
||||
@@ -121,15 +123,15 @@ func (c *FakeIssuers) Delete(name string, options *v1.DeleteOptions) error {
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *FakeIssuers) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(issuersResource, c.ns, listOptions)
|
||||
func (c *FakeIssuers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(issuersResource, c.ns, listOpts)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &v1alpha2.IssuerList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched issuer.
|
||||
func (c *FakeIssuers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.Issuer, err error) {
|
||||
func (c *FakeIssuers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.Issuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewPatchSubresourceAction(issuersResource, c.ns, name, pt, data, subresources...), &v1alpha2.Issuer{})
|
||||
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha2
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1alpha2 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
@@ -37,15 +38,15 @@ type IssuersGetter interface {
|
||||
|
||||
// IssuerInterface has methods to work with Issuer resources.
|
||||
type IssuerInterface interface {
|
||||
Create(*v1alpha2.Issuer) (*v1alpha2.Issuer, error)
|
||||
Update(*v1alpha2.Issuer) (*v1alpha2.Issuer, error)
|
||||
UpdateStatus(*v1alpha2.Issuer) (*v1alpha2.Issuer, error)
|
||||
Delete(name string, options *v1.DeleteOptions) error
|
||||
DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error
|
||||
Get(name string, options v1.GetOptions) (*v1alpha2.Issuer, error)
|
||||
List(opts v1.ListOptions) (*v1alpha2.IssuerList, error)
|
||||
Watch(opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.Issuer, err error)
|
||||
Create(ctx context.Context, issuer *v1alpha2.Issuer, opts v1.CreateOptions) (*v1alpha2.Issuer, error)
|
||||
Update(ctx context.Context, issuer *v1alpha2.Issuer, opts v1.UpdateOptions) (*v1alpha2.Issuer, error)
|
||||
UpdateStatus(ctx context.Context, issuer *v1alpha2.Issuer, opts v1.UpdateOptions) (*v1alpha2.Issuer, error)
|
||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha2.Issuer, error)
|
||||
List(ctx context.Context, opts v1.ListOptions) (*v1alpha2.IssuerList, error)
|
||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.Issuer, err error)
|
||||
IssuerExpansion
|
||||
}
|
||||
|
||||
@@ -64,20 +65,20 @@ func newIssuers(c *CertmanagerV1alpha2Client, namespace string) *issuers {
|
||||
}
|
||||
|
||||
// Get takes name of the issuer, and returns the corresponding issuer object, and an error if there is any.
|
||||
func (c *issuers) Get(name string, options v1.GetOptions) (result *v1alpha2.Issuer, err error) {
|
||||
func (c *issuers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.Issuer, err error) {
|
||||
result = &v1alpha2.Issuer{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
Name(name).
|
||||
VersionedParams(&options, scheme.ParameterCodec).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Issuers that match those selectors.
|
||||
func (c *issuers) List(opts v1.ListOptions) (result *v1alpha2.IssuerList, err error) {
|
||||
func (c *issuers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.IssuerList, err error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -88,13 +89,13 @@ func (c *issuers) List(opts v1.ListOptions) (result *v1alpha2.IssuerList, err er
|
||||
Resource("issuers").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested issuers.
|
||||
func (c *issuers) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *issuers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -105,87 +106,90 @@ func (c *issuers) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
Resource("issuers").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Watch()
|
||||
Watch(ctx)
|
||||
}
|
||||
|
||||
// Create takes the representation of a issuer and creates it. Returns the server's representation of the issuer, and an error, if there is any.
|
||||
func (c *issuers) Create(issuer *v1alpha2.Issuer) (result *v1alpha2.Issuer, err error) {
|
||||
func (c *issuers) Create(ctx context.Context, issuer *v1alpha2.Issuer, opts v1.CreateOptions) (result *v1alpha2.Issuer, err error) {
|
||||
result = &v1alpha2.Issuer{}
|
||||
err = c.client.Post().
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(issuer).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Update takes the representation of a issuer and updates it. Returns the server's representation of the issuer, and an error, if there is any.
|
||||
func (c *issuers) Update(issuer *v1alpha2.Issuer) (result *v1alpha2.Issuer, err error) {
|
||||
func (c *issuers) Update(ctx context.Context, issuer *v1alpha2.Issuer, opts v1.UpdateOptions) (result *v1alpha2.Issuer, err error) {
|
||||
result = &v1alpha2.Issuer{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
Name(issuer.Name).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(issuer).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
|
||||
func (c *issuers) UpdateStatus(issuer *v1alpha2.Issuer) (result *v1alpha2.Issuer, err error) {
|
||||
func (c *issuers) UpdateStatus(ctx context.Context, issuer *v1alpha2.Issuer, opts v1.UpdateOptions) (result *v1alpha2.Issuer, err error) {
|
||||
result = &v1alpha2.Issuer{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
Name(issuer.Name).
|
||||
SubResource("status").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(issuer).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Delete takes name of the issuer and deletes it. Returns an error if one occurs.
|
||||
func (c *issuers) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *issuers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
Name(name).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *issuers) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
func (c *issuers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
var timeout time.Duration
|
||||
if listOptions.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOptions.TimeoutSeconds) * time.Second
|
||||
if listOpts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
||||
}
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
VersionedParams(&listOptions, scheme.ParameterCodec).
|
||||
VersionedParams(&listOpts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched issuer.
|
||||
func (c *issuers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha2.Issuer, err error) {
|
||||
func (c *issuers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.Issuer, err error) {
|
||||
result = &v1alpha2.Issuer{}
|
||||
err = c.client.Patch(pt).
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
SubResource(subresources...).
|
||||
Name(name).
|
||||
SubResource(subresources...).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(data).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1alpha3 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha3"
|
||||
@@ -37,15 +38,15 @@ type CertificatesGetter interface {
|
||||
|
||||
// CertificateInterface has methods to work with Certificate resources.
|
||||
type CertificateInterface interface {
|
||||
Create(*v1alpha3.Certificate) (*v1alpha3.Certificate, error)
|
||||
Update(*v1alpha3.Certificate) (*v1alpha3.Certificate, error)
|
||||
UpdateStatus(*v1alpha3.Certificate) (*v1alpha3.Certificate, error)
|
||||
Delete(name string, options *v1.DeleteOptions) error
|
||||
DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error
|
||||
Get(name string, options v1.GetOptions) (*v1alpha3.Certificate, error)
|
||||
List(opts v1.ListOptions) (*v1alpha3.CertificateList, error)
|
||||
Watch(opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.Certificate, err error)
|
||||
Create(ctx context.Context, certificate *v1alpha3.Certificate, opts v1.CreateOptions) (*v1alpha3.Certificate, error)
|
||||
Update(ctx context.Context, certificate *v1alpha3.Certificate, opts v1.UpdateOptions) (*v1alpha3.Certificate, error)
|
||||
UpdateStatus(ctx context.Context, certificate *v1alpha3.Certificate, opts v1.UpdateOptions) (*v1alpha3.Certificate, error)
|
||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha3.Certificate, error)
|
||||
List(ctx context.Context, opts v1.ListOptions) (*v1alpha3.CertificateList, error)
|
||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.Certificate, err error)
|
||||
CertificateExpansion
|
||||
}
|
||||
|
||||
@@ -64,20 +65,20 @@ func newCertificates(c *CertmanagerV1alpha3Client, namespace string) *certificat
|
||||
}
|
||||
|
||||
// Get takes name of the certificate, and returns the corresponding certificate object, and an error if there is any.
|
||||
func (c *certificates) Get(name string, options v1.GetOptions) (result *v1alpha3.Certificate, err error) {
|
||||
func (c *certificates) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha3.Certificate, err error) {
|
||||
result = &v1alpha3.Certificate{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
Name(name).
|
||||
VersionedParams(&options, scheme.ParameterCodec).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Certificates that match those selectors.
|
||||
func (c *certificates) List(opts v1.ListOptions) (result *v1alpha3.CertificateList, err error) {
|
||||
func (c *certificates) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha3.CertificateList, err error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -88,13 +89,13 @@ func (c *certificates) List(opts v1.ListOptions) (result *v1alpha3.CertificateLi
|
||||
Resource("certificates").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested certificates.
|
||||
func (c *certificates) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *certificates) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -105,87 +106,90 @@ func (c *certificates) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
Resource("certificates").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Watch()
|
||||
Watch(ctx)
|
||||
}
|
||||
|
||||
// Create takes the representation of a certificate and creates it. Returns the server's representation of the certificate, and an error, if there is any.
|
||||
func (c *certificates) Create(certificate *v1alpha3.Certificate) (result *v1alpha3.Certificate, err error) {
|
||||
func (c *certificates) Create(ctx context.Context, certificate *v1alpha3.Certificate, opts v1.CreateOptions) (result *v1alpha3.Certificate, err error) {
|
||||
result = &v1alpha3.Certificate{}
|
||||
err = c.client.Post().
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(certificate).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Update takes the representation of a certificate and updates it. Returns the server's representation of the certificate, and an error, if there is any.
|
||||
func (c *certificates) Update(certificate *v1alpha3.Certificate) (result *v1alpha3.Certificate, err error) {
|
||||
func (c *certificates) Update(ctx context.Context, certificate *v1alpha3.Certificate, opts v1.UpdateOptions) (result *v1alpha3.Certificate, err error) {
|
||||
result = &v1alpha3.Certificate{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
Name(certificate.Name).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(certificate).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
|
||||
func (c *certificates) UpdateStatus(certificate *v1alpha3.Certificate) (result *v1alpha3.Certificate, err error) {
|
||||
func (c *certificates) UpdateStatus(ctx context.Context, certificate *v1alpha3.Certificate, opts v1.UpdateOptions) (result *v1alpha3.Certificate, err error) {
|
||||
result = &v1alpha3.Certificate{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
Name(certificate.Name).
|
||||
SubResource("status").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(certificate).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Delete takes name of the certificate and deletes it. Returns an error if one occurs.
|
||||
func (c *certificates) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *certificates) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
Name(name).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *certificates) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
func (c *certificates) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
var timeout time.Duration
|
||||
if listOptions.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOptions.TimeoutSeconds) * time.Second
|
||||
if listOpts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
||||
}
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
VersionedParams(&listOptions, scheme.ParameterCodec).
|
||||
VersionedParams(&listOpts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched certificate.
|
||||
func (c *certificates) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.Certificate, err error) {
|
||||
func (c *certificates) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.Certificate, err error) {
|
||||
result = &v1alpha3.Certificate{}
|
||||
err = c.client.Patch(pt).
|
||||
Namespace(c.ns).
|
||||
Resource("certificates").
|
||||
SubResource(subresources...).
|
||||
Name(name).
|
||||
SubResource(subresources...).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(data).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1alpha3 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha3"
|
||||
@@ -37,15 +38,15 @@ type CertificateRequestsGetter interface {
|
||||
|
||||
// CertificateRequestInterface has methods to work with CertificateRequest resources.
|
||||
type CertificateRequestInterface interface {
|
||||
Create(*v1alpha3.CertificateRequest) (*v1alpha3.CertificateRequest, error)
|
||||
Update(*v1alpha3.CertificateRequest) (*v1alpha3.CertificateRequest, error)
|
||||
UpdateStatus(*v1alpha3.CertificateRequest) (*v1alpha3.CertificateRequest, error)
|
||||
Delete(name string, options *v1.DeleteOptions) error
|
||||
DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error
|
||||
Get(name string, options v1.GetOptions) (*v1alpha3.CertificateRequest, error)
|
||||
List(opts v1.ListOptions) (*v1alpha3.CertificateRequestList, error)
|
||||
Watch(opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.CertificateRequest, err error)
|
||||
Create(ctx context.Context, certificateRequest *v1alpha3.CertificateRequest, opts v1.CreateOptions) (*v1alpha3.CertificateRequest, error)
|
||||
Update(ctx context.Context, certificateRequest *v1alpha3.CertificateRequest, opts v1.UpdateOptions) (*v1alpha3.CertificateRequest, error)
|
||||
UpdateStatus(ctx context.Context, certificateRequest *v1alpha3.CertificateRequest, opts v1.UpdateOptions) (*v1alpha3.CertificateRequest, error)
|
||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha3.CertificateRequest, error)
|
||||
List(ctx context.Context, opts v1.ListOptions) (*v1alpha3.CertificateRequestList, error)
|
||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.CertificateRequest, err error)
|
||||
CertificateRequestExpansion
|
||||
}
|
||||
|
||||
@@ -64,20 +65,20 @@ func newCertificateRequests(c *CertmanagerV1alpha3Client, namespace string) *cer
|
||||
}
|
||||
|
||||
// Get takes name of the certificateRequest, and returns the corresponding certificateRequest object, and an error if there is any.
|
||||
func (c *certificateRequests) Get(name string, options v1.GetOptions) (result *v1alpha3.CertificateRequest, err error) {
|
||||
func (c *certificateRequests) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha3.CertificateRequest, err error) {
|
||||
result = &v1alpha3.CertificateRequest{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
Name(name).
|
||||
VersionedParams(&options, scheme.ParameterCodec).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of CertificateRequests that match those selectors.
|
||||
func (c *certificateRequests) List(opts v1.ListOptions) (result *v1alpha3.CertificateRequestList, err error) {
|
||||
func (c *certificateRequests) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha3.CertificateRequestList, err error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -88,13 +89,13 @@ func (c *certificateRequests) List(opts v1.ListOptions) (result *v1alpha3.Certif
|
||||
Resource("certificaterequests").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested certificateRequests.
|
||||
func (c *certificateRequests) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *certificateRequests) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -105,87 +106,90 @@ func (c *certificateRequests) Watch(opts v1.ListOptions) (watch.Interface, error
|
||||
Resource("certificaterequests").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Watch()
|
||||
Watch(ctx)
|
||||
}
|
||||
|
||||
// Create takes the representation of a certificateRequest and creates it. Returns the server's representation of the certificateRequest, and an error, if there is any.
|
||||
func (c *certificateRequests) Create(certificateRequest *v1alpha3.CertificateRequest) (result *v1alpha3.CertificateRequest, err error) {
|
||||
func (c *certificateRequests) Create(ctx context.Context, certificateRequest *v1alpha3.CertificateRequest, opts v1.CreateOptions) (result *v1alpha3.CertificateRequest, err error) {
|
||||
result = &v1alpha3.CertificateRequest{}
|
||||
err = c.client.Post().
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(certificateRequest).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Update takes the representation of a certificateRequest and updates it. Returns the server's representation of the certificateRequest, and an error, if there is any.
|
||||
func (c *certificateRequests) Update(certificateRequest *v1alpha3.CertificateRequest) (result *v1alpha3.CertificateRequest, err error) {
|
||||
func (c *certificateRequests) Update(ctx context.Context, certificateRequest *v1alpha3.CertificateRequest, opts v1.UpdateOptions) (result *v1alpha3.CertificateRequest, err error) {
|
||||
result = &v1alpha3.CertificateRequest{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
Name(certificateRequest.Name).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(certificateRequest).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
|
||||
func (c *certificateRequests) UpdateStatus(certificateRequest *v1alpha3.CertificateRequest) (result *v1alpha3.CertificateRequest, err error) {
|
||||
func (c *certificateRequests) UpdateStatus(ctx context.Context, certificateRequest *v1alpha3.CertificateRequest, opts v1.UpdateOptions) (result *v1alpha3.CertificateRequest, err error) {
|
||||
result = &v1alpha3.CertificateRequest{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
Name(certificateRequest.Name).
|
||||
SubResource("status").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(certificateRequest).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Delete takes name of the certificateRequest and deletes it. Returns an error if one occurs.
|
||||
func (c *certificateRequests) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *certificateRequests) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
Name(name).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *certificateRequests) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
func (c *certificateRequests) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
var timeout time.Duration
|
||||
if listOptions.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOptions.TimeoutSeconds) * time.Second
|
||||
if listOpts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
||||
}
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
VersionedParams(&listOptions, scheme.ParameterCodec).
|
||||
VersionedParams(&listOpts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched certificateRequest.
|
||||
func (c *certificateRequests) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.CertificateRequest, err error) {
|
||||
func (c *certificateRequests) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.CertificateRequest, err error) {
|
||||
result = &v1alpha3.CertificateRequest{}
|
||||
err = c.client.Patch(pt).
|
||||
Namespace(c.ns).
|
||||
Resource("certificaterequests").
|
||||
SubResource(subresources...).
|
||||
Name(name).
|
||||
SubResource(subresources...).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(data).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1alpha3 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha3"
|
||||
@@ -37,15 +38,15 @@ type ClusterIssuersGetter interface {
|
||||
|
||||
// ClusterIssuerInterface has methods to work with ClusterIssuer resources.
|
||||
type ClusterIssuerInterface interface {
|
||||
Create(*v1alpha3.ClusterIssuer) (*v1alpha3.ClusterIssuer, error)
|
||||
Update(*v1alpha3.ClusterIssuer) (*v1alpha3.ClusterIssuer, error)
|
||||
UpdateStatus(*v1alpha3.ClusterIssuer) (*v1alpha3.ClusterIssuer, error)
|
||||
Delete(name string, options *v1.DeleteOptions) error
|
||||
DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error
|
||||
Get(name string, options v1.GetOptions) (*v1alpha3.ClusterIssuer, error)
|
||||
List(opts v1.ListOptions) (*v1alpha3.ClusterIssuerList, error)
|
||||
Watch(opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.ClusterIssuer, err error)
|
||||
Create(ctx context.Context, clusterIssuer *v1alpha3.ClusterIssuer, opts v1.CreateOptions) (*v1alpha3.ClusterIssuer, error)
|
||||
Update(ctx context.Context, clusterIssuer *v1alpha3.ClusterIssuer, opts v1.UpdateOptions) (*v1alpha3.ClusterIssuer, error)
|
||||
UpdateStatus(ctx context.Context, clusterIssuer *v1alpha3.ClusterIssuer, opts v1.UpdateOptions) (*v1alpha3.ClusterIssuer, error)
|
||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha3.ClusterIssuer, error)
|
||||
List(ctx context.Context, opts v1.ListOptions) (*v1alpha3.ClusterIssuerList, error)
|
||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.ClusterIssuer, err error)
|
||||
ClusterIssuerExpansion
|
||||
}
|
||||
|
||||
@@ -62,19 +63,19 @@ func newClusterIssuers(c *CertmanagerV1alpha3Client) *clusterIssuers {
|
||||
}
|
||||
|
||||
// Get takes name of the clusterIssuer, and returns the corresponding clusterIssuer object, and an error if there is any.
|
||||
func (c *clusterIssuers) Get(name string, options v1.GetOptions) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
func (c *clusterIssuers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
result = &v1alpha3.ClusterIssuer{}
|
||||
err = c.client.Get().
|
||||
Resource("clusterissuers").
|
||||
Name(name).
|
||||
VersionedParams(&options, scheme.ParameterCodec).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of ClusterIssuers that match those selectors.
|
||||
func (c *clusterIssuers) List(opts v1.ListOptions) (result *v1alpha3.ClusterIssuerList, err error) {
|
||||
func (c *clusterIssuers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha3.ClusterIssuerList, err error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -84,13 +85,13 @@ func (c *clusterIssuers) List(opts v1.ListOptions) (result *v1alpha3.ClusterIssu
|
||||
Resource("clusterissuers").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested clusterIssuers.
|
||||
func (c *clusterIssuers) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *clusterIssuers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -100,81 +101,84 @@ func (c *clusterIssuers) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
Resource("clusterissuers").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Watch()
|
||||
Watch(ctx)
|
||||
}
|
||||
|
||||
// Create takes the representation of a clusterIssuer and creates it. Returns the server's representation of the clusterIssuer, and an error, if there is any.
|
||||
func (c *clusterIssuers) Create(clusterIssuer *v1alpha3.ClusterIssuer) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
func (c *clusterIssuers) Create(ctx context.Context, clusterIssuer *v1alpha3.ClusterIssuer, opts v1.CreateOptions) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
result = &v1alpha3.ClusterIssuer{}
|
||||
err = c.client.Post().
|
||||
Resource("clusterissuers").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(clusterIssuer).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Update takes the representation of a clusterIssuer and updates it. Returns the server's representation of the clusterIssuer, and an error, if there is any.
|
||||
func (c *clusterIssuers) Update(clusterIssuer *v1alpha3.ClusterIssuer) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
func (c *clusterIssuers) Update(ctx context.Context, clusterIssuer *v1alpha3.ClusterIssuer, opts v1.UpdateOptions) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
result = &v1alpha3.ClusterIssuer{}
|
||||
err = c.client.Put().
|
||||
Resource("clusterissuers").
|
||||
Name(clusterIssuer.Name).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(clusterIssuer).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
|
||||
func (c *clusterIssuers) UpdateStatus(clusterIssuer *v1alpha3.ClusterIssuer) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
func (c *clusterIssuers) UpdateStatus(ctx context.Context, clusterIssuer *v1alpha3.ClusterIssuer, opts v1.UpdateOptions) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
result = &v1alpha3.ClusterIssuer{}
|
||||
err = c.client.Put().
|
||||
Resource("clusterissuers").
|
||||
Name(clusterIssuer.Name).
|
||||
SubResource("status").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(clusterIssuer).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Delete takes name of the clusterIssuer and deletes it. Returns an error if one occurs.
|
||||
func (c *clusterIssuers) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *clusterIssuers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Resource("clusterissuers").
|
||||
Name(name).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *clusterIssuers) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
func (c *clusterIssuers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
var timeout time.Duration
|
||||
if listOptions.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOptions.TimeoutSeconds) * time.Second
|
||||
if listOpts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
||||
}
|
||||
return c.client.Delete().
|
||||
Resource("clusterissuers").
|
||||
VersionedParams(&listOptions, scheme.ParameterCodec).
|
||||
VersionedParams(&listOpts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched clusterIssuer.
|
||||
func (c *clusterIssuers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
func (c *clusterIssuers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
result = &v1alpha3.ClusterIssuer{}
|
||||
err = c.client.Patch(pt).
|
||||
Resource("clusterissuers").
|
||||
SubResource(subresources...).
|
||||
Name(name).
|
||||
SubResource(subresources...).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(data).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
+12
-10
@@ -19,6 +19,8 @@ limitations under the License.
|
||||
package fake
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
v1alpha3 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha3"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
labels "k8s.io/apimachinery/pkg/labels"
|
||||
@@ -39,7 +41,7 @@ var certificatesResource = schema.GroupVersionResource{Group: "cert-manager.io",
|
||||
var certificatesKind = schema.GroupVersionKind{Group: "cert-manager.io", Version: "v1alpha3", Kind: "Certificate"}
|
||||
|
||||
// Get takes name of the certificate, and returns the corresponding certificate object, and an error if there is any.
|
||||
func (c *FakeCertificates) Get(name string, options v1.GetOptions) (result *v1alpha3.Certificate, err error) {
|
||||
func (c *FakeCertificates) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha3.Certificate, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewGetAction(certificatesResource, c.ns, name), &v1alpha3.Certificate{})
|
||||
|
||||
@@ -50,7 +52,7 @@ func (c *FakeCertificates) Get(name string, options v1.GetOptions) (result *v1al
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Certificates that match those selectors.
|
||||
func (c *FakeCertificates) List(opts v1.ListOptions) (result *v1alpha3.CertificateList, err error) {
|
||||
func (c *FakeCertificates) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha3.CertificateList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewListAction(certificatesResource, certificatesKind, c.ns, opts), &v1alpha3.CertificateList{})
|
||||
|
||||
@@ -72,14 +74,14 @@ func (c *FakeCertificates) List(opts v1.ListOptions) (result *v1alpha3.Certifica
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested certificates.
|
||||
func (c *FakeCertificates) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *FakeCertificates) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
return c.Fake.
|
||||
InvokesWatch(testing.NewWatchAction(certificatesResource, c.ns, opts))
|
||||
|
||||
}
|
||||
|
||||
// Create takes the representation of a certificate and creates it. Returns the server's representation of the certificate, and an error, if there is any.
|
||||
func (c *FakeCertificates) Create(certificate *v1alpha3.Certificate) (result *v1alpha3.Certificate, err error) {
|
||||
func (c *FakeCertificates) Create(ctx context.Context, certificate *v1alpha3.Certificate, opts v1.CreateOptions) (result *v1alpha3.Certificate, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewCreateAction(certificatesResource, c.ns, certificate), &v1alpha3.Certificate{})
|
||||
|
||||
@@ -90,7 +92,7 @@ func (c *FakeCertificates) Create(certificate *v1alpha3.Certificate) (result *v1
|
||||
}
|
||||
|
||||
// Update takes the representation of a certificate and updates it. Returns the server's representation of the certificate, and an error, if there is any.
|
||||
func (c *FakeCertificates) Update(certificate *v1alpha3.Certificate) (result *v1alpha3.Certificate, err error) {
|
||||
func (c *FakeCertificates) Update(ctx context.Context, certificate *v1alpha3.Certificate, opts v1.UpdateOptions) (result *v1alpha3.Certificate, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateAction(certificatesResource, c.ns, certificate), &v1alpha3.Certificate{})
|
||||
|
||||
@@ -102,7 +104,7 @@ func (c *FakeCertificates) Update(certificate *v1alpha3.Certificate) (result *v1
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeCertificates) UpdateStatus(certificate *v1alpha3.Certificate) (*v1alpha3.Certificate, error) {
|
||||
func (c *FakeCertificates) UpdateStatus(ctx context.Context, certificate *v1alpha3.Certificate, opts v1.UpdateOptions) (*v1alpha3.Certificate, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateSubresourceAction(certificatesResource, "status", c.ns, certificate), &v1alpha3.Certificate{})
|
||||
|
||||
@@ -113,7 +115,7 @@ func (c *FakeCertificates) UpdateStatus(certificate *v1alpha3.Certificate) (*v1a
|
||||
}
|
||||
|
||||
// Delete takes name of the certificate and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeCertificates) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeCertificates) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewDeleteAction(certificatesResource, c.ns, name), &v1alpha3.Certificate{})
|
||||
|
||||
@@ -121,15 +123,15 @@ func (c *FakeCertificates) Delete(name string, options *v1.DeleteOptions) error
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *FakeCertificates) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(certificatesResource, c.ns, listOptions)
|
||||
func (c *FakeCertificates) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(certificatesResource, c.ns, listOpts)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &v1alpha3.CertificateList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched certificate.
|
||||
func (c *FakeCertificates) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.Certificate, err error) {
|
||||
func (c *FakeCertificates) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.Certificate, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewPatchSubresourceAction(certificatesResource, c.ns, name, pt, data, subresources...), &v1alpha3.Certificate{})
|
||||
|
||||
|
||||
+12
-10
@@ -19,6 +19,8 @@ limitations under the License.
|
||||
package fake
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
v1alpha3 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha3"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
labels "k8s.io/apimachinery/pkg/labels"
|
||||
@@ -39,7 +41,7 @@ var certificaterequestsResource = schema.GroupVersionResource{Group: "cert-manag
|
||||
var certificaterequestsKind = schema.GroupVersionKind{Group: "cert-manager.io", Version: "v1alpha3", Kind: "CertificateRequest"}
|
||||
|
||||
// Get takes name of the certificateRequest, and returns the corresponding certificateRequest object, and an error if there is any.
|
||||
func (c *FakeCertificateRequests) Get(name string, options v1.GetOptions) (result *v1alpha3.CertificateRequest, err error) {
|
||||
func (c *FakeCertificateRequests) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha3.CertificateRequest, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewGetAction(certificaterequestsResource, c.ns, name), &v1alpha3.CertificateRequest{})
|
||||
|
||||
@@ -50,7 +52,7 @@ func (c *FakeCertificateRequests) Get(name string, options v1.GetOptions) (resul
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of CertificateRequests that match those selectors.
|
||||
func (c *FakeCertificateRequests) List(opts v1.ListOptions) (result *v1alpha3.CertificateRequestList, err error) {
|
||||
func (c *FakeCertificateRequests) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha3.CertificateRequestList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewListAction(certificaterequestsResource, certificaterequestsKind, c.ns, opts), &v1alpha3.CertificateRequestList{})
|
||||
|
||||
@@ -72,14 +74,14 @@ func (c *FakeCertificateRequests) List(opts v1.ListOptions) (result *v1alpha3.Ce
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested certificateRequests.
|
||||
func (c *FakeCertificateRequests) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *FakeCertificateRequests) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
return c.Fake.
|
||||
InvokesWatch(testing.NewWatchAction(certificaterequestsResource, c.ns, opts))
|
||||
|
||||
}
|
||||
|
||||
// Create takes the representation of a certificateRequest and creates it. Returns the server's representation of the certificateRequest, and an error, if there is any.
|
||||
func (c *FakeCertificateRequests) Create(certificateRequest *v1alpha3.CertificateRequest) (result *v1alpha3.CertificateRequest, err error) {
|
||||
func (c *FakeCertificateRequests) Create(ctx context.Context, certificateRequest *v1alpha3.CertificateRequest, opts v1.CreateOptions) (result *v1alpha3.CertificateRequest, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewCreateAction(certificaterequestsResource, c.ns, certificateRequest), &v1alpha3.CertificateRequest{})
|
||||
|
||||
@@ -90,7 +92,7 @@ func (c *FakeCertificateRequests) Create(certificateRequest *v1alpha3.Certificat
|
||||
}
|
||||
|
||||
// Update takes the representation of a certificateRequest and updates it. Returns the server's representation of the certificateRequest, and an error, if there is any.
|
||||
func (c *FakeCertificateRequests) Update(certificateRequest *v1alpha3.CertificateRequest) (result *v1alpha3.CertificateRequest, err error) {
|
||||
func (c *FakeCertificateRequests) Update(ctx context.Context, certificateRequest *v1alpha3.CertificateRequest, opts v1.UpdateOptions) (result *v1alpha3.CertificateRequest, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateAction(certificaterequestsResource, c.ns, certificateRequest), &v1alpha3.CertificateRequest{})
|
||||
|
||||
@@ -102,7 +104,7 @@ func (c *FakeCertificateRequests) Update(certificateRequest *v1alpha3.Certificat
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeCertificateRequests) UpdateStatus(certificateRequest *v1alpha3.CertificateRequest) (*v1alpha3.CertificateRequest, error) {
|
||||
func (c *FakeCertificateRequests) UpdateStatus(ctx context.Context, certificateRequest *v1alpha3.CertificateRequest, opts v1.UpdateOptions) (*v1alpha3.CertificateRequest, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateSubresourceAction(certificaterequestsResource, "status", c.ns, certificateRequest), &v1alpha3.CertificateRequest{})
|
||||
|
||||
@@ -113,7 +115,7 @@ func (c *FakeCertificateRequests) UpdateStatus(certificateRequest *v1alpha3.Cert
|
||||
}
|
||||
|
||||
// Delete takes name of the certificateRequest and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeCertificateRequests) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeCertificateRequests) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewDeleteAction(certificaterequestsResource, c.ns, name), &v1alpha3.CertificateRequest{})
|
||||
|
||||
@@ -121,15 +123,15 @@ func (c *FakeCertificateRequests) Delete(name string, options *v1.DeleteOptions)
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *FakeCertificateRequests) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(certificaterequestsResource, c.ns, listOptions)
|
||||
func (c *FakeCertificateRequests) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(certificaterequestsResource, c.ns, listOpts)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &v1alpha3.CertificateRequestList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched certificateRequest.
|
||||
func (c *FakeCertificateRequests) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.CertificateRequest, err error) {
|
||||
func (c *FakeCertificateRequests) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.CertificateRequest, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewPatchSubresourceAction(certificaterequestsResource, c.ns, name, pt, data, subresources...), &v1alpha3.CertificateRequest{})
|
||||
|
||||
|
||||
+12
-10
@@ -19,6 +19,8 @@ limitations under the License.
|
||||
package fake
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
v1alpha3 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha3"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
labels "k8s.io/apimachinery/pkg/labels"
|
||||
@@ -38,7 +40,7 @@ var clusterissuersResource = schema.GroupVersionResource{Group: "cert-manager.io
|
||||
var clusterissuersKind = schema.GroupVersionKind{Group: "cert-manager.io", Version: "v1alpha3", Kind: "ClusterIssuer"}
|
||||
|
||||
// Get takes name of the clusterIssuer, and returns the corresponding clusterIssuer object, and an error if there is any.
|
||||
func (c *FakeClusterIssuers) Get(name string, options v1.GetOptions) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
func (c *FakeClusterIssuers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootGetAction(clusterissuersResource, name), &v1alpha3.ClusterIssuer{})
|
||||
if obj == nil {
|
||||
@@ -48,7 +50,7 @@ func (c *FakeClusterIssuers) Get(name string, options v1.GetOptions) (result *v1
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of ClusterIssuers that match those selectors.
|
||||
func (c *FakeClusterIssuers) List(opts v1.ListOptions) (result *v1alpha3.ClusterIssuerList, err error) {
|
||||
func (c *FakeClusterIssuers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha3.ClusterIssuerList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootListAction(clusterissuersResource, clusterissuersKind, opts), &v1alpha3.ClusterIssuerList{})
|
||||
if obj == nil {
|
||||
@@ -69,13 +71,13 @@ func (c *FakeClusterIssuers) List(opts v1.ListOptions) (result *v1alpha3.Cluster
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested clusterIssuers.
|
||||
func (c *FakeClusterIssuers) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *FakeClusterIssuers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
return c.Fake.
|
||||
InvokesWatch(testing.NewRootWatchAction(clusterissuersResource, opts))
|
||||
}
|
||||
|
||||
// Create takes the representation of a clusterIssuer and creates it. Returns the server's representation of the clusterIssuer, and an error, if there is any.
|
||||
func (c *FakeClusterIssuers) Create(clusterIssuer *v1alpha3.ClusterIssuer) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
func (c *FakeClusterIssuers) Create(ctx context.Context, clusterIssuer *v1alpha3.ClusterIssuer, opts v1.CreateOptions) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootCreateAction(clusterissuersResource, clusterIssuer), &v1alpha3.ClusterIssuer{})
|
||||
if obj == nil {
|
||||
@@ -85,7 +87,7 @@ func (c *FakeClusterIssuers) Create(clusterIssuer *v1alpha3.ClusterIssuer) (resu
|
||||
}
|
||||
|
||||
// Update takes the representation of a clusterIssuer and updates it. Returns the server's representation of the clusterIssuer, and an error, if there is any.
|
||||
func (c *FakeClusterIssuers) Update(clusterIssuer *v1alpha3.ClusterIssuer) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
func (c *FakeClusterIssuers) Update(ctx context.Context, clusterIssuer *v1alpha3.ClusterIssuer, opts v1.UpdateOptions) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootUpdateAction(clusterissuersResource, clusterIssuer), &v1alpha3.ClusterIssuer{})
|
||||
if obj == nil {
|
||||
@@ -96,7 +98,7 @@ func (c *FakeClusterIssuers) Update(clusterIssuer *v1alpha3.ClusterIssuer) (resu
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeClusterIssuers) UpdateStatus(clusterIssuer *v1alpha3.ClusterIssuer) (*v1alpha3.ClusterIssuer, error) {
|
||||
func (c *FakeClusterIssuers) UpdateStatus(ctx context.Context, clusterIssuer *v1alpha3.ClusterIssuer, opts v1.UpdateOptions) (*v1alpha3.ClusterIssuer, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootUpdateSubresourceAction(clusterissuersResource, "status", clusterIssuer), &v1alpha3.ClusterIssuer{})
|
||||
if obj == nil {
|
||||
@@ -106,22 +108,22 @@ func (c *FakeClusterIssuers) UpdateStatus(clusterIssuer *v1alpha3.ClusterIssuer)
|
||||
}
|
||||
|
||||
// Delete takes name of the clusterIssuer and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeClusterIssuers) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeClusterIssuers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewRootDeleteAction(clusterissuersResource, name), &v1alpha3.ClusterIssuer{})
|
||||
return err
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *FakeClusterIssuers) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewRootDeleteCollectionAction(clusterissuersResource, listOptions)
|
||||
func (c *FakeClusterIssuers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
action := testing.NewRootDeleteCollectionAction(clusterissuersResource, listOpts)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &v1alpha3.ClusterIssuerList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched clusterIssuer.
|
||||
func (c *FakeClusterIssuers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
func (c *FakeClusterIssuers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.ClusterIssuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootPatchSubresourceAction(clusterissuersResource, name, pt, data, subresources...), &v1alpha3.ClusterIssuer{})
|
||||
if obj == nil {
|
||||
|
||||
@@ -19,6 +19,8 @@ limitations under the License.
|
||||
package fake
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
v1alpha3 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha3"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
labels "k8s.io/apimachinery/pkg/labels"
|
||||
@@ -39,7 +41,7 @@ var issuersResource = schema.GroupVersionResource{Group: "cert-manager.io", Vers
|
||||
var issuersKind = schema.GroupVersionKind{Group: "cert-manager.io", Version: "v1alpha3", Kind: "Issuer"}
|
||||
|
||||
// Get takes name of the issuer, and returns the corresponding issuer object, and an error if there is any.
|
||||
func (c *FakeIssuers) Get(name string, options v1.GetOptions) (result *v1alpha3.Issuer, err error) {
|
||||
func (c *FakeIssuers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha3.Issuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewGetAction(issuersResource, c.ns, name), &v1alpha3.Issuer{})
|
||||
|
||||
@@ -50,7 +52,7 @@ func (c *FakeIssuers) Get(name string, options v1.GetOptions) (result *v1alpha3.
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Issuers that match those selectors.
|
||||
func (c *FakeIssuers) List(opts v1.ListOptions) (result *v1alpha3.IssuerList, err error) {
|
||||
func (c *FakeIssuers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha3.IssuerList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewListAction(issuersResource, issuersKind, c.ns, opts), &v1alpha3.IssuerList{})
|
||||
|
||||
@@ -72,14 +74,14 @@ func (c *FakeIssuers) List(opts v1.ListOptions) (result *v1alpha3.IssuerList, er
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested issuers.
|
||||
func (c *FakeIssuers) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *FakeIssuers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
return c.Fake.
|
||||
InvokesWatch(testing.NewWatchAction(issuersResource, c.ns, opts))
|
||||
|
||||
}
|
||||
|
||||
// Create takes the representation of a issuer and creates it. Returns the server's representation of the issuer, and an error, if there is any.
|
||||
func (c *FakeIssuers) Create(issuer *v1alpha3.Issuer) (result *v1alpha3.Issuer, err error) {
|
||||
func (c *FakeIssuers) Create(ctx context.Context, issuer *v1alpha3.Issuer, opts v1.CreateOptions) (result *v1alpha3.Issuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewCreateAction(issuersResource, c.ns, issuer), &v1alpha3.Issuer{})
|
||||
|
||||
@@ -90,7 +92,7 @@ func (c *FakeIssuers) Create(issuer *v1alpha3.Issuer) (result *v1alpha3.Issuer,
|
||||
}
|
||||
|
||||
// Update takes the representation of a issuer and updates it. Returns the server's representation of the issuer, and an error, if there is any.
|
||||
func (c *FakeIssuers) Update(issuer *v1alpha3.Issuer) (result *v1alpha3.Issuer, err error) {
|
||||
func (c *FakeIssuers) Update(ctx context.Context, issuer *v1alpha3.Issuer, opts v1.UpdateOptions) (result *v1alpha3.Issuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateAction(issuersResource, c.ns, issuer), &v1alpha3.Issuer{})
|
||||
|
||||
@@ -102,7 +104,7 @@ func (c *FakeIssuers) Update(issuer *v1alpha3.Issuer) (result *v1alpha3.Issuer,
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeIssuers) UpdateStatus(issuer *v1alpha3.Issuer) (*v1alpha3.Issuer, error) {
|
||||
func (c *FakeIssuers) UpdateStatus(ctx context.Context, issuer *v1alpha3.Issuer, opts v1.UpdateOptions) (*v1alpha3.Issuer, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateSubresourceAction(issuersResource, "status", c.ns, issuer), &v1alpha3.Issuer{})
|
||||
|
||||
@@ -113,7 +115,7 @@ func (c *FakeIssuers) UpdateStatus(issuer *v1alpha3.Issuer) (*v1alpha3.Issuer, e
|
||||
}
|
||||
|
||||
// Delete takes name of the issuer and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeIssuers) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeIssuers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewDeleteAction(issuersResource, c.ns, name), &v1alpha3.Issuer{})
|
||||
|
||||
@@ -121,15 +123,15 @@ func (c *FakeIssuers) Delete(name string, options *v1.DeleteOptions) error {
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *FakeIssuers) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(issuersResource, c.ns, listOptions)
|
||||
func (c *FakeIssuers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(issuersResource, c.ns, listOpts)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &v1alpha3.IssuerList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched issuer.
|
||||
func (c *FakeIssuers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.Issuer, err error) {
|
||||
func (c *FakeIssuers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.Issuer, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewPatchSubresourceAction(issuersResource, c.ns, name, pt, data, subresources...), &v1alpha3.Issuer{})
|
||||
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1alpha3 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha3"
|
||||
@@ -37,15 +38,15 @@ type IssuersGetter interface {
|
||||
|
||||
// IssuerInterface has methods to work with Issuer resources.
|
||||
type IssuerInterface interface {
|
||||
Create(*v1alpha3.Issuer) (*v1alpha3.Issuer, error)
|
||||
Update(*v1alpha3.Issuer) (*v1alpha3.Issuer, error)
|
||||
UpdateStatus(*v1alpha3.Issuer) (*v1alpha3.Issuer, error)
|
||||
Delete(name string, options *v1.DeleteOptions) error
|
||||
DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error
|
||||
Get(name string, options v1.GetOptions) (*v1alpha3.Issuer, error)
|
||||
List(opts v1.ListOptions) (*v1alpha3.IssuerList, error)
|
||||
Watch(opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.Issuer, err error)
|
||||
Create(ctx context.Context, issuer *v1alpha3.Issuer, opts v1.CreateOptions) (*v1alpha3.Issuer, error)
|
||||
Update(ctx context.Context, issuer *v1alpha3.Issuer, opts v1.UpdateOptions) (*v1alpha3.Issuer, error)
|
||||
UpdateStatus(ctx context.Context, issuer *v1alpha3.Issuer, opts v1.UpdateOptions) (*v1alpha3.Issuer, error)
|
||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha3.Issuer, error)
|
||||
List(ctx context.Context, opts v1.ListOptions) (*v1alpha3.IssuerList, error)
|
||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.Issuer, err error)
|
||||
IssuerExpansion
|
||||
}
|
||||
|
||||
@@ -64,20 +65,20 @@ func newIssuers(c *CertmanagerV1alpha3Client, namespace string) *issuers {
|
||||
}
|
||||
|
||||
// Get takes name of the issuer, and returns the corresponding issuer object, and an error if there is any.
|
||||
func (c *issuers) Get(name string, options v1.GetOptions) (result *v1alpha3.Issuer, err error) {
|
||||
func (c *issuers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha3.Issuer, err error) {
|
||||
result = &v1alpha3.Issuer{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
Name(name).
|
||||
VersionedParams(&options, scheme.ParameterCodec).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of Issuers that match those selectors.
|
||||
func (c *issuers) List(opts v1.ListOptions) (result *v1alpha3.IssuerList, err error) {
|
||||
func (c *issuers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha3.IssuerList, err error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -88,13 +89,13 @@ func (c *issuers) List(opts v1.ListOptions) (result *v1alpha3.IssuerList, err er
|
||||
Resource("issuers").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested issuers.
|
||||
func (c *issuers) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *issuers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
var timeout time.Duration
|
||||
if opts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||
@@ -105,87 +106,90 @@ func (c *issuers) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
Resource("issuers").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Watch()
|
||||
Watch(ctx)
|
||||
}
|
||||
|
||||
// Create takes the representation of a issuer and creates it. Returns the server's representation of the issuer, and an error, if there is any.
|
||||
func (c *issuers) Create(issuer *v1alpha3.Issuer) (result *v1alpha3.Issuer, err error) {
|
||||
func (c *issuers) Create(ctx context.Context, issuer *v1alpha3.Issuer, opts v1.CreateOptions) (result *v1alpha3.Issuer, err error) {
|
||||
result = &v1alpha3.Issuer{}
|
||||
err = c.client.Post().
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(issuer).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Update takes the representation of a issuer and updates it. Returns the server's representation of the issuer, and an error, if there is any.
|
||||
func (c *issuers) Update(issuer *v1alpha3.Issuer) (result *v1alpha3.Issuer, err error) {
|
||||
func (c *issuers) Update(ctx context.Context, issuer *v1alpha3.Issuer, opts v1.UpdateOptions) (result *v1alpha3.Issuer, err error) {
|
||||
result = &v1alpha3.Issuer{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
Name(issuer.Name).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(issuer).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
|
||||
func (c *issuers) UpdateStatus(issuer *v1alpha3.Issuer) (result *v1alpha3.Issuer, err error) {
|
||||
func (c *issuers) UpdateStatus(ctx context.Context, issuer *v1alpha3.Issuer, opts v1.UpdateOptions) (result *v1alpha3.Issuer, err error) {
|
||||
result = &v1alpha3.Issuer{}
|
||||
err = c.client.Put().
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
Name(issuer.Name).
|
||||
SubResource("status").
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(issuer).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
// Delete takes name of the issuer and deletes it. Returns an error if one occurs.
|
||||
func (c *issuers) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *issuers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
Name(name).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *issuers) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
func (c *issuers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||
var timeout time.Duration
|
||||
if listOptions.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOptions.TimeoutSeconds) * time.Second
|
||||
if listOpts.TimeoutSeconds != nil {
|
||||
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
||||
}
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
VersionedParams(&listOptions, scheme.ParameterCodec).
|
||||
VersionedParams(&listOpts, scheme.ParameterCodec).
|
||||
Timeout(timeout).
|
||||
Body(options).
|
||||
Do().
|
||||
Body(&opts).
|
||||
Do(ctx).
|
||||
Error()
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched issuer.
|
||||
func (c *issuers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha3.Issuer, err error) {
|
||||
func (c *issuers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha3.Issuer, err error) {
|
||||
result = &v1alpha3.Issuer{}
|
||||
err = c.client.Patch(pt).
|
||||
Namespace(c.ns).
|
||||
Resource("issuers").
|
||||
SubResource(subresources...).
|
||||
Name(name).
|
||||
SubResource(subresources...).
|
||||
VersionedParams(&opts, scheme.ParameterCodec).
|
||||
Body(data).
|
||||
Do().
|
||||
Do(ctx).
|
||||
Into(result)
|
||||
return
|
||||
}
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha2
|
||||
|
||||
import (
|
||||
"context"
|
||||
time "time"
|
||||
|
||||
acmev1alpha2 "github.com/jetstack/cert-manager/pkg/apis/acme/v1alpha2"
|
||||
@@ -61,13 +62,13 @@ func NewFilteredChallengeInformer(client versioned.Interface, namespace string,
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.AcmeV1alpha2().Challenges(namespace).List(options)
|
||||
return client.AcmeV1alpha2().Challenges(namespace).List(context.TODO(), options)
|
||||
},
|
||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.AcmeV1alpha2().Challenges(namespace).Watch(options)
|
||||
return client.AcmeV1alpha2().Challenges(namespace).Watch(context.TODO(), options)
|
||||
},
|
||||
},
|
||||
&acmev1alpha2.Challenge{},
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha2
|
||||
|
||||
import (
|
||||
"context"
|
||||
time "time"
|
||||
|
||||
acmev1alpha2 "github.com/jetstack/cert-manager/pkg/apis/acme/v1alpha2"
|
||||
@@ -61,13 +62,13 @@ func NewFilteredOrderInformer(client versioned.Interface, namespace string, resy
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.AcmeV1alpha2().Orders(namespace).List(options)
|
||||
return client.AcmeV1alpha2().Orders(namespace).List(context.TODO(), options)
|
||||
},
|
||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.AcmeV1alpha2().Orders(namespace).Watch(options)
|
||||
return client.AcmeV1alpha2().Orders(namespace).Watch(context.TODO(), options)
|
||||
},
|
||||
},
|
||||
&acmev1alpha2.Order{},
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha3
|
||||
|
||||
import (
|
||||
"context"
|
||||
time "time"
|
||||
|
||||
acmev1alpha3 "github.com/jetstack/cert-manager/pkg/apis/acme/v1alpha3"
|
||||
@@ -61,13 +62,13 @@ func NewFilteredChallengeInformer(client versioned.Interface, namespace string,
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.AcmeV1alpha3().Challenges(namespace).List(options)
|
||||
return client.AcmeV1alpha3().Challenges(namespace).List(context.TODO(), options)
|
||||
},
|
||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.AcmeV1alpha3().Challenges(namespace).Watch(options)
|
||||
return client.AcmeV1alpha3().Challenges(namespace).Watch(context.TODO(), options)
|
||||
},
|
||||
},
|
||||
&acmev1alpha3.Challenge{},
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha3
|
||||
|
||||
import (
|
||||
"context"
|
||||
time "time"
|
||||
|
||||
acmev1alpha3 "github.com/jetstack/cert-manager/pkg/apis/acme/v1alpha3"
|
||||
@@ -61,13 +62,13 @@ func NewFilteredOrderInformer(client versioned.Interface, namespace string, resy
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.AcmeV1alpha3().Orders(namespace).List(options)
|
||||
return client.AcmeV1alpha3().Orders(namespace).List(context.TODO(), options)
|
||||
},
|
||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.AcmeV1alpha3().Orders(namespace).Watch(options)
|
||||
return client.AcmeV1alpha3().Orders(namespace).Watch(context.TODO(), options)
|
||||
},
|
||||
},
|
||||
&acmev1alpha3.Order{},
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha2
|
||||
|
||||
import (
|
||||
"context"
|
||||
time "time"
|
||||
|
||||
certmanagerv1alpha2 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
@@ -61,13 +62,13 @@ func NewFilteredCertificateInformer(client versioned.Interface, namespace string
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha2().Certificates(namespace).List(options)
|
||||
return client.CertmanagerV1alpha2().Certificates(namespace).List(context.TODO(), options)
|
||||
},
|
||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha2().Certificates(namespace).Watch(options)
|
||||
return client.CertmanagerV1alpha2().Certificates(namespace).Watch(context.TODO(), options)
|
||||
},
|
||||
},
|
||||
&certmanagerv1alpha2.Certificate{},
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha2
|
||||
|
||||
import (
|
||||
"context"
|
||||
time "time"
|
||||
|
||||
certmanagerv1alpha2 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
@@ -61,13 +62,13 @@ func NewFilteredCertificateRequestInformer(client versioned.Interface, namespace
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha2().CertificateRequests(namespace).List(options)
|
||||
return client.CertmanagerV1alpha2().CertificateRequests(namespace).List(context.TODO(), options)
|
||||
},
|
||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha2().CertificateRequests(namespace).Watch(options)
|
||||
return client.CertmanagerV1alpha2().CertificateRequests(namespace).Watch(context.TODO(), options)
|
||||
},
|
||||
},
|
||||
&certmanagerv1alpha2.CertificateRequest{},
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha2
|
||||
|
||||
import (
|
||||
"context"
|
||||
time "time"
|
||||
|
||||
certmanagerv1alpha2 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
@@ -60,13 +61,13 @@ func NewFilteredClusterIssuerInformer(client versioned.Interface, resyncPeriod t
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha2().ClusterIssuers().List(options)
|
||||
return client.CertmanagerV1alpha2().ClusterIssuers().List(context.TODO(), options)
|
||||
},
|
||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha2().ClusterIssuers().Watch(options)
|
||||
return client.CertmanagerV1alpha2().ClusterIssuers().Watch(context.TODO(), options)
|
||||
},
|
||||
},
|
||||
&certmanagerv1alpha2.ClusterIssuer{},
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha2
|
||||
|
||||
import (
|
||||
"context"
|
||||
time "time"
|
||||
|
||||
certmanagerv1alpha2 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
@@ -61,13 +62,13 @@ func NewFilteredIssuerInformer(client versioned.Interface, namespace string, res
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha2().Issuers(namespace).List(options)
|
||||
return client.CertmanagerV1alpha2().Issuers(namespace).List(context.TODO(), options)
|
||||
},
|
||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha2().Issuers(namespace).Watch(options)
|
||||
return client.CertmanagerV1alpha2().Issuers(namespace).Watch(context.TODO(), options)
|
||||
},
|
||||
},
|
||||
&certmanagerv1alpha2.Issuer{},
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha3
|
||||
|
||||
import (
|
||||
"context"
|
||||
time "time"
|
||||
|
||||
certmanagerv1alpha3 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha3"
|
||||
@@ -61,13 +62,13 @@ func NewFilteredCertificateInformer(client versioned.Interface, namespace string
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha3().Certificates(namespace).List(options)
|
||||
return client.CertmanagerV1alpha3().Certificates(namespace).List(context.TODO(), options)
|
||||
},
|
||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha3().Certificates(namespace).Watch(options)
|
||||
return client.CertmanagerV1alpha3().Certificates(namespace).Watch(context.TODO(), options)
|
||||
},
|
||||
},
|
||||
&certmanagerv1alpha3.Certificate{},
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha3
|
||||
|
||||
import (
|
||||
"context"
|
||||
time "time"
|
||||
|
||||
certmanagerv1alpha3 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha3"
|
||||
@@ -61,13 +62,13 @@ func NewFilteredCertificateRequestInformer(client versioned.Interface, namespace
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha3().CertificateRequests(namespace).List(options)
|
||||
return client.CertmanagerV1alpha3().CertificateRequests(namespace).List(context.TODO(), options)
|
||||
},
|
||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha3().CertificateRequests(namespace).Watch(options)
|
||||
return client.CertmanagerV1alpha3().CertificateRequests(namespace).Watch(context.TODO(), options)
|
||||
},
|
||||
},
|
||||
&certmanagerv1alpha3.CertificateRequest{},
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha3
|
||||
|
||||
import (
|
||||
"context"
|
||||
time "time"
|
||||
|
||||
certmanagerv1alpha3 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha3"
|
||||
@@ -60,13 +61,13 @@ func NewFilteredClusterIssuerInformer(client versioned.Interface, resyncPeriod t
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha3().ClusterIssuers().List(options)
|
||||
return client.CertmanagerV1alpha3().ClusterIssuers().List(context.TODO(), options)
|
||||
},
|
||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha3().ClusterIssuers().Watch(options)
|
||||
return client.CertmanagerV1alpha3().ClusterIssuers().Watch(context.TODO(), options)
|
||||
},
|
||||
},
|
||||
&certmanagerv1alpha3.ClusterIssuer{},
|
||||
|
||||
@@ -19,6 +19,7 @@ limitations under the License.
|
||||
package v1alpha3
|
||||
|
||||
import (
|
||||
"context"
|
||||
time "time"
|
||||
|
||||
certmanagerv1alpha3 "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha3"
|
||||
@@ -61,13 +62,13 @@ func NewFilteredIssuerInformer(client versioned.Interface, namespace string, res
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha3().Issuers(namespace).List(options)
|
||||
return client.CertmanagerV1alpha3().Issuers(namespace).List(context.TODO(), options)
|
||||
},
|
||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CertmanagerV1alpha3().Issuers(namespace).Watch(options)
|
||||
return client.CertmanagerV1alpha3().Issuers(namespace).Watch(context.TODO(), options)
|
||||
},
|
||||
},
|
||||
&certmanagerv1alpha3.Issuer{},
|
||||
|
||||
@@ -30,6 +30,7 @@ go_library(
|
||||
"@com_github_go_logr_logr//:go_default_library",
|
||||
"@io_k8s_api//core/v1:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/api/errors:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/apis/meta/v1:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/util/errors:go_default_library",
|
||||
"@io_k8s_client_go//listers/core/v1:go_default_library",
|
||||
"@io_k8s_client_go//tools/cache:go_default_library",
|
||||
|
||||
@@ -23,6 +23,7 @@ import (
|
||||
"github.com/go-logr/logr"
|
||||
corev1 "k8s.io/api/core/v1"
|
||||
k8sErrors "k8s.io/apimachinery/pkg/api/errors"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
corelisters "k8s.io/client-go/listers/core/v1"
|
||||
"k8s.io/client-go/tools/cache"
|
||||
"k8s.io/client-go/tools/record"
|
||||
@@ -164,7 +165,7 @@ func (c *controller) runScheduler(ctx context.Context) {
|
||||
ch = ch.DeepCopy()
|
||||
ch.Status.Processing = true
|
||||
|
||||
_, err := c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).UpdateStatus(ch)
|
||||
_, err := c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).UpdateStatus(context.TODO(), ch, metav1.UpdateOptions{})
|
||||
if err != nil {
|
||||
log.Error(err, "error scheduling challenge for processing")
|
||||
return
|
||||
|
||||
@@ -24,6 +24,7 @@ import (
|
||||
|
||||
acmeapi "golang.org/x/crypto/acme"
|
||||
corev1 "k8s.io/api/core/v1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
utilerrors "k8s.io/apimachinery/pkg/util/errors"
|
||||
|
||||
"github.com/jetstack/cert-manager/pkg/acme"
|
||||
@@ -74,7 +75,7 @@ func (c *controller) Sync(ctx context.Context, ch *cmacme.Challenge) (err error)
|
||||
if reflect.DeepEqual(oldChal.Status, ch.Status) && len(oldChal.Finalizers) == len(ch.Finalizers) {
|
||||
return
|
||||
}
|
||||
_, updateErr := c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).UpdateStatus(ch)
|
||||
_, updateErr := c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).UpdateStatus(context.TODO(), ch, metav1.UpdateOptions{})
|
||||
if updateErr != nil {
|
||||
err = utilerrors.NewAggregate([]error{err, updateErr})
|
||||
}
|
||||
@@ -252,14 +253,14 @@ func (c *controller) handleFinalizer(ctx context.Context, ch *cmacme.Challenge)
|
||||
|
||||
defer func() {
|
||||
// call UpdateStatus first as we may have updated the challenge.status.reason field
|
||||
ch, updateErr := c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).UpdateStatus(ch)
|
||||
ch, updateErr := c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).UpdateStatus(context.TODO(), ch, metav1.UpdateOptions{})
|
||||
if updateErr != nil {
|
||||
err = utilerrors.NewAggregate([]error{err, updateErr})
|
||||
return
|
||||
}
|
||||
// call Update to remove the metadata.finalizers entry
|
||||
ch.Finalizers = ch.Finalizers[1:]
|
||||
_, updateErr = c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).Update(ch)
|
||||
_, updateErr = c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).Update(context.TODO(), ch, metav1.UpdateOptions{})
|
||||
if updateErr != nil {
|
||||
err = utilerrors.NewAggregate([]error{err, updateErr})
|
||||
return
|
||||
|
||||
@@ -54,7 +54,7 @@ func (c *controller) Sync(ctx context.Context, o *cmacme.Order) (err error) {
|
||||
return
|
||||
}
|
||||
log.Info("updating Order resource status")
|
||||
_, updateErr := c.cmClient.AcmeV1alpha2().Orders(o.Namespace).UpdateStatus(o)
|
||||
_, updateErr := c.cmClient.AcmeV1alpha2().Orders(o.Namespace).UpdateStatus(context.TODO(), o, metav1.UpdateOptions{})
|
||||
if updateErr != nil {
|
||||
log.Error(err, "failed to update status")
|
||||
err = utilerrors.NewAggregate([]error{err, updateErr})
|
||||
@@ -331,7 +331,7 @@ func (c *controller) anyRequiredChallengesDoNotExist(requiredChallenges []cmacme
|
||||
|
||||
func (c *controller) createRequiredChallenges(o *cmacme.Order, requiredChallenges []cmacme.Challenge) error {
|
||||
for _, ch := range requiredChallenges {
|
||||
_, err := c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).Create(&ch)
|
||||
_, err := c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).Create(context.TODO(), &ch, metav1.CreateOptions{})
|
||||
if apierrors.IsAlreadyExists(err) {
|
||||
continue
|
||||
}
|
||||
@@ -359,7 +359,7 @@ func (c *controller) deleteLeftoverChallenges(o *cmacme.Order, requiredChallenge
|
||||
}
|
||||
|
||||
for _, ch := range leftover {
|
||||
if err := c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).Delete(ch.Name, nil); err != nil {
|
||||
if err := c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).Delete(context.TODO(), ch.Name, metav1.DeleteOptions{}); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
@@ -374,7 +374,7 @@ func (c *controller) deleteAllChallenges(o *cmacme.Order) error {
|
||||
}
|
||||
|
||||
for _, ch := range challenges {
|
||||
if err := c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).Delete(ch.Name, nil); err != nil {
|
||||
if err := c.cmClient.AcmeV1alpha2().Challenges(ch.Namespace).Delete(context.TODO(), ch.Name, metav1.DeleteOptions{}); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
@@ -27,6 +27,7 @@ go_library(
|
||||
"@com_github_go_logr_logr//:go_default_library",
|
||||
"@com_github_kr_pretty//:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/api/errors:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/apis/meta/v1:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/labels:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/util/errors:go_default_library",
|
||||
"@io_k8s_client_go//tools/cache:go_default_library",
|
||||
|
||||
@@ -121,7 +121,7 @@ func (a *ACME) Sign(ctx context.Context, cr *v1alpha2.CertificateRequest, issuer
|
||||
if k8sErrors.IsNotFound(err) {
|
||||
// Failing to create the order here is most likely network related.
|
||||
// We should backoff and keep trying.
|
||||
_, err = a.acmeClientV.Orders(expectedOrder.Namespace).Create(expectedOrder)
|
||||
_, err = a.acmeClientV.Orders(expectedOrder.Namespace).Create(context.TODO(), expectedOrder, metav1.CreateOptions{})
|
||||
if err != nil {
|
||||
message := fmt.Sprintf("Failed create new order resource %s/%s", expectedOrder.Namespace, expectedOrder.Name)
|
||||
|
||||
@@ -175,7 +175,7 @@ func (a *ACME) Sign(ctx context.Context, cr *v1alpha2.CertificateRequest, issuer
|
||||
x509Cert, err := pki.DecodeX509CertificateBytes(order.Status.Certificate)
|
||||
if errors.IsInvalidData(err) {
|
||||
log.Error(err, "failed to decode x509 certificate data on Order resource")
|
||||
return nil, a.acmeClientV.Orders(order.Namespace).Delete(order.Name, nil)
|
||||
return nil, a.acmeClientV.Orders(order.Namespace).Delete(context.TODO(), order.Name, metav1.DeleteOptions{})
|
||||
}
|
||||
ok, err := pki.PublicKeyMatchesCertificate(csr.PublicKey, x509Cert)
|
||||
if err != nil {
|
||||
@@ -183,7 +183,7 @@ func (a *ACME) Sign(ctx context.Context, cr *v1alpha2.CertificateRequest, issuer
|
||||
}
|
||||
if !ok {
|
||||
log.Error(err, "failed to decode x509 certificate data on Order resource, recreating...")
|
||||
return nil, a.acmeClientV.Orders(order.Namespace).Delete(order.Name, nil)
|
||||
return nil, a.acmeClientV.Orders(order.Namespace).Delete(context.TODO(), order.Name, metav1.DeleteOptions{})
|
||||
}
|
||||
|
||||
log.Info("certificate issued")
|
||||
|
||||
@@ -24,6 +24,7 @@ import (
|
||||
|
||||
"github.com/kr/pretty"
|
||||
k8sErrors "k8s.io/apimachinery/pkg/api/errors"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
utilerrors "k8s.io/apimachinery/pkg/util/errors"
|
||||
|
||||
apiutil "github.com/jetstack/cert-manager/pkg/api/util"
|
||||
@@ -169,5 +170,5 @@ func (c *Controller) updateCertificateRequestStatus(ctx context.Context, old, ne
|
||||
}
|
||||
|
||||
log.V(logf.DebugLevel).Info("updating resource due to change in status", "diff", pretty.Diff(string(oldBytes), string(newBytes)))
|
||||
return c.cmClient.CertmanagerV1alpha2().CertificateRequests(new.Namespace).UpdateStatus(new)
|
||||
return c.cmClient.CertmanagerV1alpha2().CertificateRequests(new.Namespace).UpdateStatus(context.TODO(), new, metav1.UpdateOptions{})
|
||||
}
|
||||
|
||||
@@ -371,7 +371,7 @@ func (c *certificateRequestManager) processCertificate(ctx context.Context, crt
|
||||
return err
|
||||
}
|
||||
|
||||
req, err = c.cmClient.CertmanagerV1alpha2().CertificateRequests(crt.Namespace).Create(req)
|
||||
req, err = c.cmClient.CertmanagerV1alpha2().CertificateRequests(crt.Namespace).Create(context.TODO(), req, metav1.CreateOptions{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -387,7 +387,7 @@ func (c *certificateRequestManager) processCertificate(ctx context.Context, crt
|
||||
x509CSR, err := pki.DecodeX509CertificateRequestBytes(existingReq.Spec.CSRPEM)
|
||||
if errors.IsInvalidData(err) {
|
||||
log.Info("failed to decode existing CSR on CertificateRequest, deleting resource...")
|
||||
return c.cmClient.CertmanagerV1alpha2().CertificateRequests(existingReq.Namespace).Delete(existingReq.Name, nil)
|
||||
return c.cmClient.CertmanagerV1alpha2().CertificateRequests(existingReq.Namespace).Delete(context.TODO(), existingReq.Name, metav1.DeleteOptions{})
|
||||
}
|
||||
if err != nil {
|
||||
return err
|
||||
@@ -404,7 +404,7 @@ func (c *certificateRequestManager) processCertificate(ctx context.Context, crt
|
||||
// do anything with the certificate if it is issued
|
||||
if !publicKeyMatches {
|
||||
log.Info("stored private key is not valid for CSR stored on existing CertificateRequest, recreating CertificateRequest resource")
|
||||
err := c.cmClient.CertmanagerV1alpha2().CertificateRequests(existingReq.Namespace).Delete(existingReq.Name, nil)
|
||||
err := c.cmClient.CertmanagerV1alpha2().CertificateRequests(existingReq.Namespace).Delete(context.TODO(), existingReq.Name, metav1.DeleteOptions{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -437,7 +437,7 @@ func (c *certificateRequestManager) processCertificate(ctx context.Context, crt
|
||||
case cmapi.CertificateRequestReasonFailed:
|
||||
if existingReq.Status.FailureTime == nil || c.clock.Since(existingReq.Status.FailureTime.Time) > time.Hour {
|
||||
log.Info("deleting failed certificate request")
|
||||
err := c.cmClient.CertmanagerV1alpha2().CertificateRequests(existingReq.Namespace).Delete(existingReq.Name, nil)
|
||||
err := c.cmClient.CertmanagerV1alpha2().CertificateRequests(existingReq.Namespace).Delete(context.TODO(), existingReq.Name, metav1.DeleteOptions{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -477,7 +477,7 @@ func (c *certificateRequestManager) processCertificate(ctx context.Context, crt
|
||||
}
|
||||
if !publicKeyMatches {
|
||||
log.Info("private key stored in Secret does not match public key of issued certificate, deleting the old CertificateRequest resource")
|
||||
return c.cmClient.CertmanagerV1alpha2().CertificateRequests(existingReq.Namespace).Delete(existingReq.Name, nil)
|
||||
return c.cmClient.CertmanagerV1alpha2().CertificateRequests(existingReq.Namespace).Delete(context.TODO(), existingReq.Name, metav1.DeleteOptions{})
|
||||
}
|
||||
|
||||
// Check if the Certificate requires renewal according to the renewBefore
|
||||
@@ -485,7 +485,7 @@ func (c *certificateRequestManager) processCertificate(ctx context.Context, crt
|
||||
log.Info("checking if certificate stored on CertificateRequest is up to date")
|
||||
if c.certificateNeedsRenew(ctx, x509Cert, crt) {
|
||||
log.Info("certificate stored on CertificateRequest needs renewal, so deleting the old CertificateRequest resource")
|
||||
err := c.cmClient.CertmanagerV1alpha2().CertificateRequests(existingReq.Namespace).Delete(existingReq.Name, nil)
|
||||
err := c.cmClient.CertmanagerV1alpha2().CertificateRequests(existingReq.Namespace).Delete(context.TODO(), existingReq.Name, metav1.DeleteOptions{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -546,14 +546,14 @@ func (c *certificateRequestManager) updateSecretData(ctx context.Context, crt *c
|
||||
}
|
||||
|
||||
if existingSecret == nil {
|
||||
_, err = c.kubeClient.CoreV1().Secrets(newSecret.Namespace).Create(newSecret)
|
||||
_, err = c.kubeClient.CoreV1().Secrets(newSecret.Namespace).Create(context.TODO(), newSecret, metav1.CreateOptions{})
|
||||
if err != nil {
|
||||
return false, err
|
||||
}
|
||||
return true, nil
|
||||
}
|
||||
|
||||
_, err = c.kubeClient.CoreV1().Secrets(newSecret.Namespace).Update(newSecret)
|
||||
_, err = c.kubeClient.CoreV1().Secrets(newSecret.Namespace).Update(context.TODO(), newSecret, metav1.UpdateOptions{})
|
||||
if err != nil {
|
||||
return false, err
|
||||
}
|
||||
@@ -588,7 +588,7 @@ func (c *certificateRequestManager) issueTemporaryCertificate(ctx context.Contex
|
||||
return err
|
||||
}
|
||||
|
||||
newSecret, err = c.kubeClient.CoreV1().Secrets(newSecret.Namespace).Update(newSecret)
|
||||
newSecret, err = c.kubeClient.CoreV1().Secrets(newSecret.Namespace).Update(context.TODO(), newSecret, metav1.UpdateOptions{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -689,7 +689,7 @@ func (c *certificateRequestManager) cleanupExistingCertificateRequests(log logr.
|
||||
continue
|
||||
}
|
||||
|
||||
err = c.cmClient.CertmanagerV1alpha2().CertificateRequests(req.Namespace).Delete(req.Name, nil)
|
||||
err = c.cmClient.CertmanagerV1alpha2().CertificateRequests(req.Namespace).Delete(context.TODO(), req.Name, metav1.DeleteOptions{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
@@ -29,6 +29,7 @@ import (
|
||||
"github.com/kr/pretty"
|
||||
corev1 "k8s.io/api/core/v1"
|
||||
k8sErrors "k8s.io/apimachinery/pkg/api/errors"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
corelisters "k8s.io/client-go/listers/core/v1"
|
||||
"k8s.io/client-go/tools/cache"
|
||||
|
||||
@@ -244,7 +245,7 @@ func updateCertificateStatus(ctx context.Context, cmClient cmclient.Interface, o
|
||||
return nil, nil
|
||||
}
|
||||
log.V(logf.DebugLevel).Info("updating resource due to change in status", "diff", pretty.Diff(string(oldBytes), string(newBytes)))
|
||||
return cmClient.CertmanagerV1alpha2().Certificates(new.Namespace).UpdateStatus(new)
|
||||
return cmClient.CertmanagerV1alpha2().Certificates(new.Namespace).UpdateStatus(context.TODO(), new, metav1.UpdateOptions{})
|
||||
}
|
||||
|
||||
func certificateHasTemporaryCertificateAnnotation(crt *v1alpha2.Certificate) bool {
|
||||
|
||||
@@ -24,6 +24,7 @@ go_library(
|
||||
"@com_github_go_logr_logr//:go_default_library",
|
||||
"@io_k8s_api//core/v1:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/api/errors:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/apis/meta/v1:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/labels:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/util/errors:go_default_library",
|
||||
"@io_k8s_client_go//listers/core/v1:go_default_library",
|
||||
|
||||
@@ -23,6 +23,7 @@ import (
|
||||
"time"
|
||||
|
||||
v1 "k8s.io/api/core/v1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
"k8s.io/apimachinery/pkg/util/errors"
|
||||
|
||||
apiutil "github.com/jetstack/cert-manager/pkg/api/util"
|
||||
@@ -94,5 +95,5 @@ func (c *controller) updateIssuerStatus(old, new *v1alpha2.ClusterIssuer) (*v1al
|
||||
if reflect.DeepEqual(old.Status, new.Status) {
|
||||
return nil, nil
|
||||
}
|
||||
return c.cmClient.CertmanagerV1alpha2().ClusterIssuers().UpdateStatus(new)
|
||||
return c.cmClient.CertmanagerV1alpha2().ClusterIssuers().UpdateStatus(context.TODO(), new, metav1.UpdateOptions{})
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package clusterissuers
|
||||
|
||||
import (
|
||||
"context"
|
||||
"reflect"
|
||||
"runtime/debug"
|
||||
"testing"
|
||||
@@ -59,7 +60,7 @@ func TestUpdateIssuerStatus(t *testing.T) {
|
||||
|
||||
originalIssuer := newFakeIssuerWithStatus("test", v1alpha2.IssuerStatus{})
|
||||
|
||||
issuer, err := fakeClient.CertmanagerV1alpha2().ClusterIssuers().Create(originalIssuer)
|
||||
issuer, err := fakeClient.CertmanagerV1alpha2().ClusterIssuers().Create(context.TODO(), originalIssuer, metav1.CreateOptions{})
|
||||
assertErrIsNil(t, fatalf, err)
|
||||
|
||||
assertNumberOfActions(t, fatalf, filter(fakeClient.Actions()), 1)
|
||||
|
||||
@@ -76,7 +76,7 @@ func (c *controller) Sync(ctx context.Context, ing *extv1beta1.Ingress) error {
|
||||
}
|
||||
|
||||
for _, crt := range newCrts {
|
||||
_, err := c.cmClient.CertmanagerV1alpha2().Certificates(crt.Namespace).Create(crt)
|
||||
_, err := c.cmClient.CertmanagerV1alpha2().Certificates(crt.Namespace).Create(context.TODO(), crt, metav1.CreateOptions{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -84,7 +84,7 @@ func (c *controller) Sync(ctx context.Context, ing *extv1beta1.Ingress) error {
|
||||
}
|
||||
|
||||
for _, crt := range updateCrts {
|
||||
_, err := c.cmClient.CertmanagerV1alpha2().Certificates(crt.Namespace).Update(crt)
|
||||
_, err := c.cmClient.CertmanagerV1alpha2().Certificates(crt.Namespace).Update(context.TODO(), crt, metav1.UpdateOptions{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -97,7 +97,7 @@ func (c *controller) Sync(ctx context.Context, ing *extv1beta1.Ingress) error {
|
||||
}
|
||||
|
||||
for _, crt := range unrequiredCrts {
|
||||
err = c.cmClient.CertmanagerV1alpha2().Certificates(crt.Namespace).Delete(crt.Name, nil)
|
||||
err = c.cmClient.CertmanagerV1alpha2().Certificates(crt.Namespace).Delete(context.TODO(), crt.Name, metav1.DeleteOptions{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
@@ -24,6 +24,7 @@ go_library(
|
||||
"@com_github_go_logr_logr//:go_default_library",
|
||||
"@io_k8s_api//core/v1:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/api/errors:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/apis/meta/v1:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/labels:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/util/errors:go_default_library",
|
||||
"@io_k8s_client_go//listers/core/v1:go_default_library",
|
||||
|
||||
@@ -23,6 +23,7 @@ import (
|
||||
"time"
|
||||
|
||||
v1 "k8s.io/api/core/v1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
"k8s.io/apimachinery/pkg/util/errors"
|
||||
|
||||
apiutil "github.com/jetstack/cert-manager/pkg/api/util"
|
||||
@@ -94,5 +95,5 @@ func (c *controller) updateIssuerStatus(old, new *v1alpha2.Issuer) (*v1alpha2.Is
|
||||
if reflect.DeepEqual(old.Status, new.Status) {
|
||||
return nil, nil
|
||||
}
|
||||
return c.cmClient.CertmanagerV1alpha2().Issuers(new.Namespace).UpdateStatus(new)
|
||||
return c.cmClient.CertmanagerV1alpha2().Issuers(new.Namespace).UpdateStatus(context.TODO(), new, metav1.UpdateOptions{})
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package issuers
|
||||
|
||||
import (
|
||||
"context"
|
||||
"reflect"
|
||||
"runtime/debug"
|
||||
"testing"
|
||||
@@ -59,7 +60,7 @@ func TestUpdateIssuerStatus(t *testing.T) {
|
||||
|
||||
originalIssuer := newFakeIssuerWithStatus("test", v1alpha2.IssuerStatus{})
|
||||
|
||||
issuer, err := cmClient.CertmanagerV1alpha2().Issuers("testns").Create(originalIssuer)
|
||||
issuer, err := cmClient.CertmanagerV1alpha2().Issuers("testns").Create(context.TODO(), originalIssuer, metav1.CreateOptions{})
|
||||
assertErrIsNil(t, fatalf, err)
|
||||
|
||||
assertNumberOfActions(t, fatalf, filter(cmClient.Actions()), 1)
|
||||
|
||||
@@ -410,9 +410,9 @@ func (c *controller) updateSecret(secret *corev1.Secret, pk, ca, crt []byte) err
|
||||
|
||||
var err error
|
||||
if secret.ResourceVersion == "" {
|
||||
_, err = c.kubeClient.CoreV1().Secrets(secret.Namespace).Create(secret)
|
||||
_, err = c.kubeClient.CoreV1().Secrets(secret.Namespace).Create(context.TODO(), secret, metav1.CreateOptions{})
|
||||
} else {
|
||||
_, err = c.kubeClient.CoreV1().Secrets(secret.Namespace).Update(secret)
|
||||
_, err = c.kubeClient.CoreV1().Secrets(secret.Namespace).Update(context.TODO(), secret, metav1.UpdateOptions{})
|
||||
}
|
||||
if err != nil {
|
||||
return err
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package webhook
|
||||
|
||||
import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
"errors"
|
||||
"fmt"
|
||||
@@ -48,7 +49,7 @@ func (r *Webhook) Present(ch *v1alpha1.ChallengeRequest) error {
|
||||
return err
|
||||
}
|
||||
|
||||
result := cl.Post().Resource(solverName).Body(pl).Do()
|
||||
result := cl.Post().Resource(solverName).Body(pl).Do(context.TODO())
|
||||
// we will check this error after parsing the response
|
||||
resErr := result.Error()
|
||||
|
||||
@@ -84,7 +85,7 @@ func (r *Webhook) CleanUp(ch *v1alpha1.ChallengeRequest) error {
|
||||
return err
|
||||
}
|
||||
|
||||
result := cl.Post().Resource(solverName).Body(pl).Do()
|
||||
result := cl.Post().Resource(solverName).Body(pl).Do(context.TODO())
|
||||
// we will check this error after parsing the response
|
||||
resErr := result.Error()
|
||||
|
||||
|
||||
@@ -131,7 +131,7 @@ func (s *Solver) createIngress(ch *cmacme.Challenge, svcName string) (*extv1beta
|
||||
ing = s.mergeIngressObjectMetaWithIngressResourceTemplate(ing, ch.Spec.Solver.HTTP01.Ingress.IngressTemplate)
|
||||
}
|
||||
|
||||
return s.Client.ExtensionsV1beta1().Ingresses(ch.Namespace).Create(ing)
|
||||
return s.Client.ExtensionsV1beta1().Ingresses(ch.Namespace).Create(context.TODO(), ing, metav1.CreateOptions{})
|
||||
}
|
||||
|
||||
func buildIngressResource(ch *cmacme.Challenge, svcName string) (*extv1beta1.Ingress, error) {
|
||||
@@ -234,11 +234,11 @@ func (s *Solver) addChallengePathToIngress(ctx context.Context, ch *cmacme.Chall
|
||||
return ing, nil
|
||||
}
|
||||
rule.HTTP.Paths[i] = ingPathToAdd
|
||||
return s.Client.ExtensionsV1beta1().Ingresses(ing.Namespace).Update(ing)
|
||||
return s.Client.ExtensionsV1beta1().Ingresses(ing.Namespace).Update(context.TODO(), ing, metav1.UpdateOptions{})
|
||||
}
|
||||
}
|
||||
rule.HTTP.Paths = append([]extv1beta1.HTTPIngressPath{ingPathToAdd}, rule.HTTP.Paths...)
|
||||
return s.Client.ExtensionsV1beta1().Ingresses(ing.Namespace).Update(ing)
|
||||
return s.Client.ExtensionsV1beta1().Ingresses(ing.Namespace).Update(context.TODO(), ing, metav1.UpdateOptions{})
|
||||
}
|
||||
}
|
||||
|
||||
@@ -251,7 +251,7 @@ func (s *Solver) addChallengePathToIngress(ctx context.Context, ch *cmacme.Chall
|
||||
},
|
||||
},
|
||||
})
|
||||
return s.Client.ExtensionsV1beta1().Ingresses(ing.Namespace).Update(ing)
|
||||
return s.Client.ExtensionsV1beta1().Ingresses(ing.Namespace).Update(context.TODO(), ing, metav1.UpdateOptions{})
|
||||
}
|
||||
|
||||
// cleanupIngresses will remove the rules added by cert-manager to an existing
|
||||
@@ -278,7 +278,7 @@ func (s *Solver) cleanupIngresses(ctx context.Context, ch *cmacme.Challenge) err
|
||||
log := logf.WithRelatedResource(log, ingress).V(logf.DebugLevel)
|
||||
|
||||
log.Info("deleting ingress resource")
|
||||
err := s.Client.ExtensionsV1beta1().Ingresses(ingress.Namespace).Delete(ingress.Name, nil)
|
||||
err := s.Client.ExtensionsV1beta1().Ingresses(ingress.Namespace).Delete(context.TODO(), ingress.Name, metav1.DeleteOptions{})
|
||||
if err != nil {
|
||||
log.Info("failed to delete ingress resource", "error", err)
|
||||
errs = append(errs, err)
|
||||
@@ -290,7 +290,7 @@ func (s *Solver) cleanupIngresses(ctx context.Context, ch *cmacme.Challenge) err
|
||||
}
|
||||
|
||||
// otherwise, we need to remove any cert-manager added rules from the ingress resource
|
||||
ing, err := s.Client.ExtensionsV1beta1().Ingresses(ch.Namespace).Get(existingIngressName, metav1.GetOptions{})
|
||||
ing, err := s.Client.ExtensionsV1beta1().Ingresses(ch.Namespace).Get(context.TODO(), existingIngressName, metav1.GetOptions{})
|
||||
if k8sErrors.IsNotFound(err) {
|
||||
log.Error(err, "named ingress resource not found, skipping cleanup")
|
||||
return nil
|
||||
@@ -333,7 +333,7 @@ func (s *Solver) cleanupIngresses(ctx context.Context, ch *cmacme.Challenge) err
|
||||
|
||||
ing.Spec.Rules = ingRules
|
||||
|
||||
_, err = s.Client.ExtensionsV1beta1().Ingresses(ing.Namespace).Update(ing)
|
||||
_, err = s.Client.ExtensionsV1beta1().Ingresses(ing.Namespace).Update(context.TODO(), ing, metav1.UpdateOptions{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
@@ -144,7 +144,7 @@ func TestCleanupIngresses(t *testing.T) {
|
||||
},
|
||||
CheckFn: func(t *testing.T, s *solverFixture, args ...interface{}) {
|
||||
createdIngress := s.testResources[createdIngressKey].(*v1beta1.Ingress)
|
||||
ing, err := s.Builder.FakeKubeClient().ExtensionsV1beta1().Ingresses(s.Challenge.Namespace).Get(createdIngress.Name, metav1.GetOptions{})
|
||||
ing, err := s.Builder.FakeKubeClient().ExtensionsV1beta1().Ingresses(s.Challenge.Namespace).Get(context.TODO(), createdIngress.Name, metav1.GetOptions{})
|
||||
if err != nil && !apierrors.IsNotFound(err) {
|
||||
t.Errorf("error when getting test ingress, expected 'not found' but got: %v", err)
|
||||
}
|
||||
@@ -178,7 +178,7 @@ func TestCleanupIngresses(t *testing.T) {
|
||||
},
|
||||
CheckFn: func(t *testing.T, s *solverFixture, args ...interface{}) {
|
||||
createdIngress := s.testResources[createdIngressKey].(*v1beta1.Ingress)
|
||||
_, err := s.Builder.FakeKubeClient().ExtensionsV1beta1().Ingresses(s.Challenge.Namespace).Get(createdIngress.Name, metav1.GetOptions{})
|
||||
_, err := s.Builder.FakeKubeClient().ExtensionsV1beta1().Ingresses(s.Challenge.Namespace).Get(context.TODO(), createdIngress.Name, metav1.GetOptions{})
|
||||
if apierrors.IsNotFound(err) {
|
||||
t.Errorf("expected ingress resource %q to not be deleted, but it was deleted", createdIngress.Name)
|
||||
}
|
||||
@@ -245,7 +245,7 @@ func TestCleanupIngresses(t *testing.T) {
|
||||
expectedIng := s.KubeObjects[0].(*v1beta1.Ingress).DeepCopy()
|
||||
expectedIng.Spec.Rules = nil
|
||||
|
||||
actualIng, err := s.Builder.FakeKubeClient().ExtensionsV1beta1().Ingresses(s.Challenge.Namespace).Get(expectedIng.Name, metav1.GetOptions{})
|
||||
actualIng, err := s.Builder.FakeKubeClient().ExtensionsV1beta1().Ingresses(s.Challenge.Namespace).Get(context.TODO(), expectedIng.Name, metav1.GetOptions{})
|
||||
if apierrors.IsNotFound(err) {
|
||||
t.Errorf("expected ingress resource %q to not be deleted, but it was deleted", expectedIng.Name)
|
||||
}
|
||||
@@ -332,7 +332,7 @@ func TestCleanupIngresses(t *testing.T) {
|
||||
expectedIng := s.KubeObjects[0].(*v1beta1.Ingress).DeepCopy()
|
||||
expectedIng.Spec.Rules = []v1beta1.IngressRule{expectedIng.Spec.Rules[1]}
|
||||
|
||||
actualIng, err := s.Builder.FakeKubeClient().ExtensionsV1beta1().Ingresses(s.Challenge.Namespace).Get(expectedIng.Name, metav1.GetOptions{})
|
||||
actualIng, err := s.Builder.FakeKubeClient().ExtensionsV1beta1().Ingresses(s.Challenge.Namespace).Get(context.TODO(), expectedIng.Name, metav1.GetOptions{})
|
||||
if apierrors.IsNotFound(err) {
|
||||
t.Errorf("expected ingress resource %q to not be deleted, but it was deleted", expectedIng.Name)
|
||||
}
|
||||
|
||||
@@ -117,7 +117,7 @@ func (s *Solver) cleanupPods(ctx context.Context, ch *cmacme.Challenge) error {
|
||||
log := logf.WithRelatedResource(log, pod).V(logf.DebugLevel)
|
||||
log.Info("deleting pod resource")
|
||||
|
||||
err := s.Client.CoreV1().Pods(pod.Namespace).Delete(pod.Name, nil)
|
||||
err := s.Client.CoreV1().Pods(pod.Namespace).Delete(context.TODO(), pod.Name, metav1.DeleteOptions{})
|
||||
if err != nil {
|
||||
log.Info("failed to delete pod resource", "error", err)
|
||||
errs = append(errs, err)
|
||||
@@ -133,7 +133,9 @@ func (s *Solver) cleanupPods(ctx context.Context, ch *cmacme.Challenge) error {
|
||||
// domain, token and key.
|
||||
func (s *Solver) createPod(ch *cmacme.Challenge) (*corev1.Pod, error) {
|
||||
return s.Client.CoreV1().Pods(ch.Namespace).Create(
|
||||
s.buildPod(ch))
|
||||
context.TODO(),
|
||||
s.buildPod(ch),
|
||||
metav1.CreateOptions{})
|
||||
}
|
||||
|
||||
// buildPod will build a challenge solving pod for the given certificate,
|
||||
|
||||
@@ -96,7 +96,7 @@ func (s *Solver) createService(ch *cmacme.Challenge) (*corev1.Service, error) {
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return s.Client.CoreV1().Services(ch.Namespace).Create(svc)
|
||||
return s.Client.CoreV1().Services(ch.Namespace).Create(context.TODO(), svc, metav1.CreateOptions{})
|
||||
}
|
||||
|
||||
func buildService(ch *cmacme.Challenge) (*corev1.Service, error) {
|
||||
@@ -148,7 +148,7 @@ func (s *Solver) cleanupServices(ctx context.Context, ch *cmacme.Challenge) erro
|
||||
log := logf.WithRelatedResource(log, service).V(logf.DebugLevel)
|
||||
log.Info("deleting service resource")
|
||||
|
||||
err := s.Client.CoreV1().Services(service.Namespace).Delete(service.Name, nil)
|
||||
err := s.Client.CoreV1().Services(service.Namespace).Delete(context.TODO(), service.Name, metav1.DeleteOptions{})
|
||||
if err != nil {
|
||||
log.Info("failed to delete pod resource", "error", err)
|
||||
errs = append(errs, err)
|
||||
|
||||
@@ -329,7 +329,7 @@ func (a *Acme) registerAccount(ctx context.Context, cl client.Interface, eabAcco
|
||||
|
||||
func (a *Acme) getEABKey(ns string) ([]byte, error) {
|
||||
eab := a.issuer.GetSpec().ACME.ExternalAccountBinding.Key
|
||||
sec, err := a.Client.CoreV1().Secrets(ns).Get(eab.Name, metav1.GetOptions{})
|
||||
sec, err := a.Client.CoreV1().Secrets(ns).Get(context.TODO(), eab.Name, metav1.GetOptions{})
|
||||
// Surface IsNotFound API error to not cause re-sync
|
||||
if apierrors.IsNotFound(err) {
|
||||
return nil, err
|
||||
@@ -365,7 +365,7 @@ func (a *Acme) createAccountPrivateKey(sel cmmeta.SecretKeySelector, ns string)
|
||||
return nil, err
|
||||
}
|
||||
|
||||
_, err = a.Client.CoreV1().Secrets(ns).Create(&v1.Secret{
|
||||
_, err = a.Client.CoreV1().Secrets(ns).Create(context.TODO(), &v1.Secret{
|
||||
ObjectMeta: metav1.ObjectMeta{
|
||||
Name: sel.Name,
|
||||
Namespace: ns,
|
||||
@@ -373,7 +373,7 @@ func (a *Acme) createAccountPrivateKey(sel cmmeta.SecretKeySelector, ns string)
|
||||
Data: map[string][]byte{
|
||||
sel.Key: pki.EncodePKCS1PrivateKey(accountPrivKey),
|
||||
},
|
||||
})
|
||||
}, metav1.CreateOptions{})
|
||||
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package dns
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"os"
|
||||
"path/filepath"
|
||||
@@ -38,11 +39,11 @@ var (
|
||||
)
|
||||
|
||||
func (f *fixture) setupNamespace(t *testing.T, name string) (string, func()) {
|
||||
if _, err := f.clientset.CoreV1().Namespaces().Create(&corev1.Namespace{
|
||||
if _, err := f.clientset.CoreV1().Namespaces().Create(context.TODO(), &corev1.Namespace{
|
||||
ObjectMeta: metav1.ObjectMeta{
|
||||
Name: name,
|
||||
},
|
||||
}); err != nil {
|
||||
}, metav1.CreateOptions{}); err != nil {
|
||||
t.Fatalf("error creating test namespace %q: %v", name, err)
|
||||
}
|
||||
|
||||
@@ -78,7 +79,7 @@ func (f *fixture) setupNamespace(t *testing.T, name string) (string, func()) {
|
||||
}
|
||||
|
||||
return name, func() {
|
||||
f.clientset.CoreV1().Namespaces().Delete(name, nil)
|
||||
f.clientset.CoreV1().Namespaces().Delete(context.TODO(), name, metav1.DeleteOptions{})
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package chart
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
@@ -226,13 +227,13 @@ func (c *Chart) SupportsGlobal() bool {
|
||||
|
||||
func (c *Chart) Logs() (map[string]string, error) {
|
||||
kc := c.Base.Details().KubeClient
|
||||
oldLabelPods, err := kc.CoreV1().Pods(c.Namespace).List(metav1.ListOptions{LabelSelector: "release=" + c.ReleaseName})
|
||||
oldLabelPods, err := kc.CoreV1().Pods(c.Namespace).List(context.TODO(), metav1.ListOptions{LabelSelector: "release=" + c.ReleaseName})
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
// also check pods with the new style labels used in the cert-manager chart
|
||||
newLabelPods, err := kc.CoreV1().Pods(c.Namespace).List(metav1.ListOptions{LabelSelector: "app.kubernetes.io/instance=" + c.ReleaseName})
|
||||
newLabelPods, err := kc.CoreV1().Pods(c.Namespace).List(context.TODO(), metav1.ListOptions{LabelSelector: "app.kubernetes.io/instance=" + c.ReleaseName})
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -245,7 +246,7 @@ func (c *Chart) Logs() (map[string]string, error) {
|
||||
resp := kc.CoreV1().Pods(pod.Namespace).GetLogs(pod.Name, &corev1.PodLogOptions{
|
||||
Container: con.Name,
|
||||
Previous: b,
|
||||
}).Do()
|
||||
}).Do(context.TODO())
|
||||
|
||||
err := resp.Error()
|
||||
if err != nil {
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package vault
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"path"
|
||||
|
||||
@@ -420,20 +421,20 @@ func (v *VaultInitializer) setupKubernetesBasedAuth() error {
|
||||
// CreateKubernetesRole creates a service account and ClusterRoleBinding for Kubernetes auth delegation
|
||||
func (v *VaultInitializer) CreateKubernetesRole(client kubernetes.Interface, namespace, roleName, serviceAccountName string) error {
|
||||
serviceAccount := NewVaultServiceAccount(serviceAccountName)
|
||||
_, err := client.CoreV1().ServiceAccounts(namespace).Create(serviceAccount)
|
||||
_, err := client.CoreV1().ServiceAccounts(namespace).Create(context.TODO(), serviceAccount, metav1.CreateOptions{})
|
||||
|
||||
if err != nil {
|
||||
return fmt.Errorf("error creating ServiceAccount for Kubernetes auth: %s", err.Error())
|
||||
}
|
||||
|
||||
role := NewVaultServiceAccountRole(namespace)
|
||||
_, err = client.RbacV1().ClusterRoles().Create(role)
|
||||
_, err = client.RbacV1().ClusterRoles().Create(context.TODO(), role, metav1.CreateOptions{})
|
||||
if err != nil {
|
||||
return fmt.Errorf("error creating Role for Kubernetes auth ServiceAccount: %s", err.Error())
|
||||
}
|
||||
|
||||
roleBinding := NewVaultServiceAccountClusterRoleBinding(role.Name, namespace, serviceAccountName)
|
||||
_, err = client.RbacV1().ClusterRoleBindings().Create(roleBinding)
|
||||
_, err = client.RbacV1().ClusterRoleBindings().Create(context.TODO(), roleBinding, metav1.CreateOptions{})
|
||||
|
||||
if err != nil {
|
||||
return fmt.Errorf("error creating RoleBinding for Kubernetes auth ServiceAccount: %s", err.Error())
|
||||
@@ -457,15 +458,15 @@ func (v *VaultInitializer) CreateKubernetesRole(client kubernetes.Interface, nam
|
||||
|
||||
// CleanKubernetesRole cleans up the ClusterRoleBinding and ServiceAccount for Kubernetes auth delegation
|
||||
func (v *VaultInitializer) CleanKubernetesRole(client kubernetes.Interface, namespace, roleName, serviceAccountName string) error {
|
||||
if err := client.RbacV1().RoleBindings(namespace).Delete(roleName, nil); err != nil {
|
||||
if err := client.RbacV1().RoleBindings(namespace).Delete(context.TODO(), roleName, metav1.DeleteOptions{}); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
if err := client.RbacV1().Roles(namespace).Delete(roleName, nil); err != nil {
|
||||
if err := client.RbacV1().Roles(namespace).Delete(context.TODO(), roleName, metav1.DeleteOptions{}); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
if err := client.CoreV1().ServiceAccounts(namespace).Delete(serviceAccountName, nil); err != nil {
|
||||
if err := client.CoreV1().ServiceAccounts(namespace).Delete(context.TODO(), serviceAccountName, metav1.DeleteOptions{}); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
|
||||
@@ -18,6 +18,7 @@ limitations under the License.
|
||||
package vault
|
||||
|
||||
import (
|
||||
"context"
|
||||
"crypto/rand"
|
||||
"crypto/rsa"
|
||||
"crypto/tls"
|
||||
@@ -140,7 +141,7 @@ func (v *Vault) Provision() error {
|
||||
|
||||
retries := 5
|
||||
for {
|
||||
pods, err := kubeClient.CoreV1().Pods(v.Namespace).List(metav1.ListOptions{
|
||||
pods, err := kubeClient.CoreV1().Pods(v.Namespace).List(context.TODO(), metav1.ListOptions{
|
||||
LabelSelector: "app=vault",
|
||||
})
|
||||
if err != nil {
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package framework
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
. "github.com/onsi/ginkgo"
|
||||
@@ -229,7 +230,7 @@ func (f *Framework) Helper() *helper.Helper {
|
||||
|
||||
func (f *Framework) CertificateDurationValid(c *v1alpha2.Certificate, duration, fuzz time.Duration) {
|
||||
By("Verifying TLS certificate exists")
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(c.Spec.SecretName, metav1.GetOptions{})
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(context.TODO(), c.Spec.SecretName, metav1.GetOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
certBytes, ok := secret.Data[api.TLSCertKey]
|
||||
if !ok {
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package helper
|
||||
|
||||
import (
|
||||
"context"
|
||||
"crypto"
|
||||
"crypto/ecdsa"
|
||||
"crypto/rsa"
|
||||
@@ -43,7 +44,7 @@ func (h *Helper) WaitForCertificateRequestReady(ns, name string, timeout time.Du
|
||||
func() (bool, error) {
|
||||
var err error
|
||||
log.Logf("Waiting for CertificateRequest %s to be ready", name)
|
||||
cr, err = h.CMClient.CertmanagerV1alpha2().CertificateRequests(ns).Get(name, metav1.GetOptions{})
|
||||
cr, err = h.CMClient.CertmanagerV1alpha2().CertificateRequests(ns).Get(context.TODO(), name, metav1.GetOptions{})
|
||||
if err != nil {
|
||||
return false, fmt.Errorf("error getting CertificateRequest %s: %v", name, err)
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package helper
|
||||
|
||||
import (
|
||||
"context"
|
||||
"crypto/ecdsa"
|
||||
"crypto/rsa"
|
||||
"crypto/x509"
|
||||
@@ -44,7 +45,7 @@ func (h *Helper) WaitForCertificateReady(ns, name string, timeout time.Duration)
|
||||
func() (bool, error) {
|
||||
var err error
|
||||
log.Logf("Waiting for Certificate %v to be ready", name)
|
||||
certificate, err = h.CMClient.CertmanagerV1alpha2().Certificates(ns).Get(name, metav1.GetOptions{})
|
||||
certificate, err = h.CMClient.CertmanagerV1alpha2().Certificates(ns).Get(context.TODO(), name, metav1.GetOptions{})
|
||||
if err != nil {
|
||||
return false, fmt.Errorf("error getting Certificate %v: %v", name, err)
|
||||
}
|
||||
@@ -72,7 +73,7 @@ func (h *Helper) WaitForCertificateNotReady(ns, name string, timeout time.Durati
|
||||
func() (bool, error) {
|
||||
var err error
|
||||
log.Logf("Waiting for Certificate %v to be ready", name)
|
||||
certificate, err = h.CMClient.CertmanagerV1alpha2().Certificates(ns).Get(name, metav1.GetOptions{})
|
||||
certificate, err = h.CMClient.CertmanagerV1alpha2().Certificates(ns).Get(context.TODO(), name, metav1.GetOptions{})
|
||||
if err != nil {
|
||||
return false, fmt.Errorf("error getting Certificate %v: %v", name, err)
|
||||
}
|
||||
@@ -97,7 +98,7 @@ func (h *Helper) WaitForCertificateNotReady(ns, name string, timeout time.Durati
|
||||
// correct as defined by the Certificate's spec.
|
||||
func (h *Helper) ValidateIssuedCertificate(certificate *cmapi.Certificate, rootCAPEM []byte) (*x509.Certificate, error) {
|
||||
log.Logf("Getting the TLS certificate Secret resource")
|
||||
secret, err := h.KubeClient.CoreV1().Secrets(certificate.Namespace).Get(certificate.Spec.SecretName, metav1.GetOptions{})
|
||||
secret, err := h.KubeClient.CoreV1().Secrets(certificate.Namespace).Get(context.TODO(), certificate.Spec.SecretName, metav1.GetOptions{})
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -266,7 +267,7 @@ func (h *Helper) defaultKeyUsagesToAdd(ns string, issuerRef *cmmeta.ObjectRefere
|
||||
var issuerSpec *cmapi.IssuerSpec
|
||||
switch issuerRef.Kind {
|
||||
case "ClusterIssuer":
|
||||
issuerObj, err := h.CMClient.CertmanagerV1alpha2().ClusterIssuers().Get(issuerRef.Name, metav1.GetOptions{})
|
||||
issuerObj, err := h.CMClient.CertmanagerV1alpha2().ClusterIssuers().Get(context.TODO(), issuerRef.Name, metav1.GetOptions{})
|
||||
if err != nil {
|
||||
return 0, nil, fmt.Errorf("failed to find referenced ClusterIssuer %v: %s",
|
||||
issuerRef, err)
|
||||
@@ -274,7 +275,7 @@ func (h *Helper) defaultKeyUsagesToAdd(ns string, issuerRef *cmmeta.ObjectRefere
|
||||
|
||||
issuerSpec = &issuerObj.Spec
|
||||
default:
|
||||
issuerObj, err := h.CMClient.CertmanagerV1alpha2().Issuers(ns).Get(issuerRef.Name, metav1.GetOptions{})
|
||||
issuerObj, err := h.CMClient.CertmanagerV1alpha2().Issuers(ns).Get(context.TODO(), issuerRef.Name, metav1.GetOptions{})
|
||||
if err != nil {
|
||||
return 0, nil, fmt.Errorf("failed to find referenced Issuer %v: %s",
|
||||
issuerRef, err)
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package helper
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"time"
|
||||
|
||||
@@ -45,7 +46,7 @@ func (h *Helper) WaitForAllPodsRunningInNamespace(ns string) error {
|
||||
func (h *Helper) WaitForAllPodsRunningInNamespaceTimeout(ns string, timeout time.Duration) error {
|
||||
ginkgo.By("Waiting " + timeout.String() + " for all pods in namespace '" + ns + "' to be Ready")
|
||||
return wait.PollImmediate(Poll, timeout, func() (bool, error) {
|
||||
pods, err := h.KubeClient.CoreV1().Pods(ns).List(metav1.ListOptions{})
|
||||
pods, err := h.KubeClient.CoreV1().Pods(ns).List(context.TODO(), metav1.ListOptions{})
|
||||
if err != nil {
|
||||
return false, err
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package helper
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"time"
|
||||
|
||||
@@ -35,7 +36,7 @@ func (h *Helper) WaitForSecretCertificateData(ns, name string, timeout time.Dura
|
||||
func() (bool, error) {
|
||||
var err error
|
||||
log.Logf("Waiting for Secret %s:%s to contain a certificate", ns, name)
|
||||
secret, err = h.KubeClient.CoreV1().Secrets(ns).Get(name, metav1.GetOptions{})
|
||||
secret, err = h.KubeClient.CoreV1().Secrets(ns).Get(context.TODO(), name, metav1.GetOptions{})
|
||||
if err != nil {
|
||||
return false, fmt.Errorf("error getting secret %s: %s", name, err)
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package matcher
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"reflect"
|
||||
|
||||
@@ -54,11 +55,11 @@ func toGenericCondition(c interface{}) (*genericCondition, error) {
|
||||
func (c *conditionMatcher) getUpToDateResource(obj interface{}) (interface{}, error) {
|
||||
switch obj := obj.(type) {
|
||||
case *cmapi.Certificate:
|
||||
return c.f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(obj.Namespace).Get(obj.Name, metav1.GetOptions{})
|
||||
return c.f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(obj.Namespace).Get(context.TODO(), obj.Name, metav1.GetOptions{})
|
||||
case *cmapi.Issuer:
|
||||
return c.f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(obj.Namespace).Get(obj.Name, metav1.GetOptions{})
|
||||
return c.f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(obj.Namespace).Get(context.TODO(), obj.Name, metav1.GetOptions{})
|
||||
case *cmapi.CertificateRequest:
|
||||
return c.f.CertManagerClientSet.CertmanagerV1alpha2().CertificateRequests(obj.Namespace).Get(obj.Name, metav1.GetOptions{})
|
||||
return c.f.CertManagerClientSet.CertmanagerV1alpha2().CertificateRequests(obj.Namespace).Get(context.TODO(), obj.Name, metav1.GetOptions{})
|
||||
default:
|
||||
return nil, fmt.Errorf("unsupported resource type %T", c)
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package framework
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"time"
|
||||
|
||||
@@ -43,7 +44,7 @@ func (f *Framework) CreateKubeNamespace(baseName string) (*v1.Namespace, error)
|
||||
},
|
||||
}
|
||||
|
||||
return f.KubeClientSet.CoreV1().Namespaces().Create(ns)
|
||||
return f.KubeClientSet.CoreV1().Namespaces().Create(context.TODO(), ns, metav1.CreateOptions{})
|
||||
}
|
||||
|
||||
// CreateKubeResourceQuota provisions a ResourceQuota resource in the target
|
||||
@@ -65,12 +66,12 @@ func (f *Framework) CreateKubeResourceQuota() (*v1.ResourceQuota, error) {
|
||||
},
|
||||
},
|
||||
}
|
||||
return f.KubeClientSet.CoreV1().ResourceQuotas(f.Namespace.Name).Create(quota)
|
||||
return f.KubeClientSet.CoreV1().ResourceQuotas(f.Namespace.Name).Create(context.TODO(), quota, metav1.CreateOptions{})
|
||||
}
|
||||
|
||||
// DeleteKubeNamespace will delete a namespace resource
|
||||
func (f *Framework) DeleteKubeNamespace(namespace string) error {
|
||||
return f.KubeClientSet.CoreV1().Namespaces().Delete(namespace, nil)
|
||||
return f.KubeClientSet.CoreV1().Namespaces().Delete(context.TODO(), namespace, metav1.DeleteOptions{})
|
||||
}
|
||||
|
||||
// WaitForKubeNamespaceNotExist will wait for the namespace with the given name
|
||||
@@ -81,7 +82,7 @@ func (f *Framework) WaitForKubeNamespaceNotExist(namespace string) error {
|
||||
|
||||
func namespaceNotExist(c kubernetes.Interface, namespace string) wait.ConditionFunc {
|
||||
return func() (bool, error) {
|
||||
_, err := c.CoreV1().Namespaces().Get(namespace, metav1.GetOptions{})
|
||||
_, err := c.CoreV1().Namespaces().Get(context.TODO(), namespace, metav1.GetOptions{})
|
||||
if apierrors.IsNotFound(err) {
|
||||
return true, nil
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package framework
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"time"
|
||||
|
||||
@@ -58,7 +59,7 @@ func RbacClusterRoleHasAccessToResource(f *Framework, clusterRole string, verb s
|
||||
},
|
||||
}
|
||||
serviceAccountClient := f.KubeClientSet.CoreV1().ServiceAccounts(f.Namespace.Name)
|
||||
serviceAccount, err := serviceAccountClient.Create(viewServiceAccount)
|
||||
serviceAccount, err := serviceAccountClient.Create(context.TODO(), viewServiceAccount, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
viewServiceAccountName := serviceAccount.Name
|
||||
|
||||
@@ -77,7 +78,7 @@ func RbacClusterRoleHasAccessToResource(f *Framework, clusterRole string, verb s
|
||||
},
|
||||
}
|
||||
roleBindingClient := f.KubeClientSet.RbacV1().ClusterRoleBindings()
|
||||
_, err = roleBindingClient.Create(viewRoleBinding)
|
||||
_, err = roleBindingClient.Create(context.TODO(), viewRoleBinding, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Sleeping for a second.")
|
||||
@@ -103,7 +104,7 @@ func RbacClusterRoleHasAccessToResource(f *Framework, clusterRole string, verb s
|
||||
},
|
||||
},
|
||||
}
|
||||
response, err := sarClient.Create(sar)
|
||||
response, err := sarClient.Create(context.TODO(), sar, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
return response.Status.Allowed
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package acme
|
||||
|
||||
import (
|
||||
"context"
|
||||
"encoding/base64"
|
||||
|
||||
. "github.com/onsi/ginkgo"
|
||||
@@ -112,12 +113,12 @@ type acmeIssuerProvisioner struct {
|
||||
|
||||
func (a *acmeIssuerProvisioner) delete(f *framework.Framework, ref cmmeta.ObjectReference) {
|
||||
if a.eab != nil {
|
||||
err := f.KubeClientSet.CoreV1().Secrets(a.secretNamespace).Delete(a.eab.Key.Name, nil)
|
||||
err := f.KubeClientSet.CoreV1().Secrets(a.secretNamespace).Delete(context.TODO(), a.eab.Key.Name, metav1.DeleteOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
}
|
||||
|
||||
if ref.Kind == "ClusterIssuer" {
|
||||
err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(ref.Name, nil)
|
||||
err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(context.TODO(), ref.Name, metav1.DeleteOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
}
|
||||
}
|
||||
@@ -139,7 +140,7 @@ func (a *acmeIssuerProvisioner) createHTTP01Issuer(f *framework.Framework) cmmet
|
||||
Spec: a.createHTTP01IssuerSpec(f.Config.Addons.ACMEServer.URL),
|
||||
}
|
||||
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(issuer)
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), issuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create acme HTTP01 issuer")
|
||||
|
||||
return cmmeta.ObjectReference{
|
||||
@@ -160,7 +161,7 @@ func (a *acmeIssuerProvisioner) createHTTP01ClusterIssuer(f *framework.Framework
|
||||
Spec: a.createHTTP01IssuerSpec(f.Config.Addons.ACMEServer.URL),
|
||||
}
|
||||
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(issuer)
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(context.TODO(), issuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create acme HTTP01 cluster issuer")
|
||||
|
||||
return cmmeta.ObjectReference{
|
||||
@@ -207,7 +208,7 @@ func (a *acmeIssuerProvisioner) createDNS01Issuer(f *framework.Framework) cmmeta
|
||||
},
|
||||
Spec: a.createDNS01IssuerSpec(f.Config.Addons.ACMEServer.URL),
|
||||
}
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(issuer)
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), issuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create acme DNS01 Issuer")
|
||||
|
||||
return cmmeta.ObjectReference{
|
||||
@@ -227,7 +228,7 @@ func (a *acmeIssuerProvisioner) createDNS01ClusterIssuer(f *framework.Framework)
|
||||
},
|
||||
Spec: a.createDNS01IssuerSpec(f.Config.Addons.ACMEServer.URL),
|
||||
}
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(issuer)
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(context.TODO(), issuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create acme DNS01 ClusterIssuer")
|
||||
|
||||
return cmmeta.ObjectReference{
|
||||
@@ -271,7 +272,7 @@ func (a *acmeIssuerProvisioner) ensureEABSecret(f *framework.Framework, ns strin
|
||||
if ns == "" {
|
||||
ns = f.Namespace.Name
|
||||
}
|
||||
sec, err := f.KubeClientSet.CoreV1().Secrets(ns).Create(&corev1.Secret{
|
||||
sec, err := f.KubeClientSet.CoreV1().Secrets(ns).Create(context.TODO(), &corev1.Secret{
|
||||
ObjectMeta: metav1.ObjectMeta{
|
||||
GenerateName: "external-account-binding-",
|
||||
Namespace: ns,
|
||||
@@ -280,7 +281,7 @@ func (a *acmeIssuerProvisioner) ensureEABSecret(f *framework.Framework, ns strin
|
||||
// base64 url encode (without padding) the HMAC key
|
||||
"key": []byte(base64.RawURLEncoding.EncodeToString([]byte("kid-secret-1"))),
|
||||
},
|
||||
})
|
||||
}, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
a.eab.Key = cmmeta.SecretKeySelector{
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package ca
|
||||
|
||||
import (
|
||||
"context"
|
||||
. "github.com/onsi/ginkgo"
|
||||
. "github.com/onsi/gomega"
|
||||
corev1 "k8s.io/api/core/v1"
|
||||
@@ -50,17 +51,17 @@ type ca struct {
|
||||
func (c *ca) createCAIssuer(f *framework.Framework) cmmeta.ObjectReference {
|
||||
By("Creating a CA Issuer")
|
||||
|
||||
rootCertSecret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(newSigningKeypairSecret("root-ca-cert-"))
|
||||
rootCertSecret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(context.TODO(), newSigningKeypairSecret("root-ca-cert-"), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create root signing keypair secret")
|
||||
|
||||
c.secretName = rootCertSecret.Name
|
||||
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(&cmapi.Issuer{
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), &cmapi.Issuer{
|
||||
ObjectMeta: metav1.ObjectMeta{
|
||||
GenerateName: "ca-issuer-",
|
||||
},
|
||||
Spec: createCAIssuerSpec(rootCertSecret.Name),
|
||||
})
|
||||
}, metav1.CreateOptions{})
|
||||
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create ca issuer")
|
||||
|
||||
@@ -74,17 +75,17 @@ func (c *ca) createCAIssuer(f *framework.Framework) cmmeta.ObjectReference {
|
||||
func (c *ca) createCAClusterIssuer(f *framework.Framework) cmmeta.ObjectReference {
|
||||
By("Creating a CA ClusterIssuer")
|
||||
|
||||
rootCertSecret, err := f.KubeClientSet.CoreV1().Secrets(f.Config.Addons.CertManager.ClusterResourceNamespace).Create(newSigningKeypairSecret("root-ca-cert-"))
|
||||
rootCertSecret, err := f.KubeClientSet.CoreV1().Secrets(f.Config.Addons.CertManager.ClusterResourceNamespace).Create(context.TODO(), newSigningKeypairSecret("root-ca-cert-"), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create root signing keypair secret")
|
||||
|
||||
c.secretName = rootCertSecret.Name
|
||||
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(&cmapi.ClusterIssuer{
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(context.TODO(), &cmapi.ClusterIssuer{
|
||||
ObjectMeta: metav1.ObjectMeta{
|
||||
GenerateName: "ca-cluster-issuer-",
|
||||
},
|
||||
Spec: createCAIssuerSpec(rootCertSecret.Name),
|
||||
})
|
||||
}, metav1.CreateOptions{})
|
||||
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create ca issuer")
|
||||
|
||||
@@ -98,10 +99,10 @@ func (c *ca) createCAClusterIssuer(f *framework.Framework) cmmeta.ObjectReferenc
|
||||
func (c *ca) deleteCAClusterIssuer(f *framework.Framework, issuer cmmeta.ObjectReference) {
|
||||
By("Deleting CA ClusterIssuer")
|
||||
|
||||
err := f.KubeClientSet.CoreV1().Secrets(f.Config.Addons.CertManager.ClusterResourceNamespace).Delete(c.secretName, nil)
|
||||
err := f.KubeClientSet.CoreV1().Secrets(f.Config.Addons.CertManager.ClusterResourceNamespace).Delete(context.TODO(), c.secretName, metav1.DeleteOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to delete root signing keypair secret")
|
||||
|
||||
err = f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(issuer.Name, nil)
|
||||
err = f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(context.TODO(), issuer.Name, metav1.DeleteOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to delete ca issuer")
|
||||
}
|
||||
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package selfsigned
|
||||
|
||||
import (
|
||||
"context"
|
||||
. "github.com/onsi/ginkgo"
|
||||
. "github.com/onsi/gomega"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
@@ -43,12 +44,12 @@ var _ = framework.ConformanceDescribe("Certificates", func() {
|
||||
func createSelfSignedIssuer(f *framework.Framework) cmmeta.ObjectReference {
|
||||
By("Creating a SelfSigned Issuer")
|
||||
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(&cmapi.Issuer{
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), &cmapi.Issuer{
|
||||
ObjectMeta: metav1.ObjectMeta{
|
||||
GenerateName: "selfsigned-issuer-",
|
||||
},
|
||||
Spec: createSelfSignedIssuerSpec(),
|
||||
})
|
||||
}, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create self signed issuer")
|
||||
|
||||
return cmmeta.ObjectReference{
|
||||
@@ -59,19 +60,19 @@ func createSelfSignedIssuer(f *framework.Framework) cmmeta.ObjectReference {
|
||||
}
|
||||
|
||||
func deleteSelfSignedClusterIssuer(f *framework.Framework, issuer cmmeta.ObjectReference) {
|
||||
err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(issuer.Name, nil)
|
||||
err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(context.TODO(), issuer.Name, metav1.DeleteOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
}
|
||||
|
||||
func createSelfSignedClusterIssuer(f *framework.Framework) cmmeta.ObjectReference {
|
||||
By("Creating a SelfSigned ClusterIssuer")
|
||||
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(&cmapi.ClusterIssuer{
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(context.TODO(), &cmapi.ClusterIssuer{
|
||||
ObjectMeta: metav1.ObjectMeta{
|
||||
GenerateName: "selfsigned-cluster-issuer-",
|
||||
},
|
||||
Spec: createSelfSignedIssuerSpec(),
|
||||
})
|
||||
}, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create self signed issuer")
|
||||
|
||||
return cmmeta.ObjectReference{
|
||||
|
||||
@@ -451,11 +451,11 @@ func (s *Suite) Define() {
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to generate expected name for created Certificate")
|
||||
|
||||
Expect(f.CertManagerClientSet.CertmanagerV1alpha2().
|
||||
CertificateRequests(f.Namespace.Name).Delete(expectedReqName, &metav1.DeleteOptions{})).
|
||||
CertificateRequests(f.Namespace.Name).Delete(context.TODO(), expectedReqName, metav1.DeleteOptions{})).
|
||||
NotTo(HaveOccurred(), "failed to delete owned CertificateRequest")
|
||||
|
||||
sec, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).
|
||||
Get(testCertificate.Spec.SecretName, metav1.GetOptions{})
|
||||
Get(context.TODO(), testCertificate.Spec.SecretName, metav1.GetOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to get secret containing signed certificate key pair data")
|
||||
|
||||
sec = sec.DeepCopy()
|
||||
@@ -465,7 +465,7 @@ func (s *Suite) Define() {
|
||||
|
||||
sec.Data[corev1.TLSCertKey] = []byte{}
|
||||
|
||||
_, err = f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Update(sec)
|
||||
_, err = f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Update(context.TODO(), sec, metav1.UpdateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to update secret by deleting the signed certificate data")
|
||||
|
||||
By("Waiting for the Certificate to re-issue a certificate")
|
||||
@@ -492,11 +492,11 @@ func (s *Suite) Define() {
|
||||
secretName := "testcert-ingress-tls"
|
||||
|
||||
By("Creating an Ingress with the issuer name annotation set")
|
||||
ingress, err := ingClient.Create(e2eutil.NewIngress(name, secretName, map[string]string{
|
||||
ingress, err := ingClient.Create(context.TODO(), e2eutil.NewIngress(name, secretName, map[string]string{
|
||||
"cert-manager.io/issuer": issuerRef.Name,
|
||||
"cert-manager.io/issuer-kind": issuerRef.Kind,
|
||||
"cert-manager.io/issuer-group": issuerRef.Group,
|
||||
}, s.newDomain()))
|
||||
}, s.newDomain()), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
certName := ingress.Spec.TLS[0].SecretName
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package vault
|
||||
|
||||
import (
|
||||
"context"
|
||||
"path"
|
||||
|
||||
. "github.com/onsi/ginkgo"
|
||||
@@ -79,11 +80,11 @@ func (v *vaultAppRoleProvisioner) delete(f *framework.Framework, ref cmmeta.Obje
|
||||
Expect(v.vaultInit.Clean()).NotTo(HaveOccurred(), "failed to deprovision vault initializer")
|
||||
Expect(v.vault.Deprovision()).NotTo(HaveOccurred(), "failed to deprovision vault")
|
||||
|
||||
err := f.KubeClientSet.CoreV1().Secrets(v.secretNamespace).Delete(v.secretName, nil)
|
||||
err := f.KubeClientSet.CoreV1().Secrets(v.secretNamespace).Delete(context.TODO(), v.secretName, metav1.DeleteOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
if ref.Kind == "ClusterIssuer" {
|
||||
err = f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(ref.Name, nil)
|
||||
err = f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(context.TODO(), ref.Name, metav1.DeleteOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
}
|
||||
}
|
||||
@@ -93,18 +94,18 @@ func (v *vaultAppRoleProvisioner) createIssuer(f *framework.Framework) cmmeta.Ob
|
||||
|
||||
v.vaultSecrets = v.initVault(f)
|
||||
|
||||
sec, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(vault.NewVaultAppRoleSecret(vaultSecretAppRoleName, v.secretID))
|
||||
sec, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(context.TODO(), vault.NewVaultAppRoleSecret(vaultSecretAppRoleName, v.secretID), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "vault to store app role secret from vault")
|
||||
|
||||
v.secretName = sec.Name
|
||||
v.secretNamespace = sec.Namespace
|
||||
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(&cmapi.Issuer{
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), &cmapi.Issuer{
|
||||
ObjectMeta: metav1.ObjectMeta{
|
||||
GenerateName: "vault-issuer-",
|
||||
},
|
||||
Spec: v.createIssuerSpec(f),
|
||||
})
|
||||
}, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create vault issuer")
|
||||
|
||||
return cmmeta.ObjectReference{
|
||||
@@ -119,18 +120,18 @@ func (v *vaultAppRoleProvisioner) createClusterIssuer(f *framework.Framework) cm
|
||||
|
||||
v.vaultSecrets = v.initVault(f)
|
||||
|
||||
sec, err := f.KubeClientSet.CoreV1().Secrets(f.Config.Addons.CertManager.ClusterResourceNamespace).Create(vault.NewVaultAppRoleSecret(vaultSecretAppRoleName, v.secretID))
|
||||
sec, err := f.KubeClientSet.CoreV1().Secrets(f.Config.Addons.CertManager.ClusterResourceNamespace).Create(context.TODO(), vault.NewVaultAppRoleSecret(vaultSecretAppRoleName, v.secretID), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "vault to store app role secret from vault")
|
||||
|
||||
v.secretName = sec.Name
|
||||
v.secretNamespace = sec.Namespace
|
||||
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(&cmapi.ClusterIssuer{
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(context.TODO(), &cmapi.ClusterIssuer{
|
||||
ObjectMeta: metav1.ObjectMeta{
|
||||
GenerateName: "vault-cluster-issuer-",
|
||||
},
|
||||
Spec: v.createIssuerSpec(f),
|
||||
})
|
||||
}, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create vault issuer")
|
||||
|
||||
return cmmeta.ObjectReference{
|
||||
|
||||
@@ -13,6 +13,7 @@ go_library(
|
||||
"//test/e2e/suite/issuers/venafi/addon:go_default_library",
|
||||
"@com_github_onsi_ginkgo//:go_default_library",
|
||||
"@com_github_onsi_gomega//:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/apis/meta/v1:go_default_library",
|
||||
],
|
||||
)
|
||||
|
||||
|
||||
@@ -17,8 +17,11 @@ limitations under the License.
|
||||
package venafi
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
. "github.com/onsi/ginkgo"
|
||||
. "github.com/onsi/gomega"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
|
||||
cmapi "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
cmmeta "github.com/jetstack/cert-manager/pkg/apis/meta/v1"
|
||||
@@ -63,7 +66,7 @@ func (v *venafiProvisioner) delete(f *framework.Framework, ref cmmeta.ObjectRefe
|
||||
Expect(v.tpp.Deprovision()).NotTo(HaveOccurred(), "failed to deprovision tpp venafi")
|
||||
|
||||
if ref.Kind == "ClusterIssuer" {
|
||||
err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(ref.Name, nil)
|
||||
err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(context.TODO(), ref.Name, metav1.DeleteOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
}
|
||||
}
|
||||
@@ -84,7 +87,7 @@ func (v *venafiProvisioner) createIssuer(f *framework.Framework) cmmeta.ObjectRe
|
||||
Expect(v.tpp.Provision()).NotTo(HaveOccurred(), "failed to provision tpp venafi")
|
||||
|
||||
issuer := v.tpp.Details().BuildIssuer()
|
||||
issuer, err = f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(issuer)
|
||||
issuer, err = f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), issuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create issuer for venafi")
|
||||
|
||||
return cmmeta.ObjectReference{
|
||||
@@ -110,7 +113,7 @@ func (v *venafiProvisioner) createClusterIssuer(f *framework.Framework) cmmeta.O
|
||||
Expect(v.tpp.Provision()).NotTo(HaveOccurred(), "failed to provision tpp venafi")
|
||||
|
||||
issuer := v.tpp.Details().BuildClusterIssuer()
|
||||
issuer, err = f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(issuer)
|
||||
issuer, err = f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(context.TODO(), issuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "failed to create issuer for venafi")
|
||||
|
||||
return cmmeta.ObjectReference{
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package certificate
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
. "github.com/onsi/ginkgo"
|
||||
@@ -77,7 +78,7 @@ func testDNSProvider(name string, p dns01Provider) bool {
|
||||
},
|
||||
}))
|
||||
issuer.Namespace = f.Namespace.Name
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(issuer)
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), issuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Waiting for Issuer to become Ready")
|
||||
err = util.WaitForIssuerCondition(f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name),
|
||||
@@ -98,7 +99,7 @@ func testDNSProvider(name string, p dns01Provider) bool {
|
||||
})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying ACME account private key exists")
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(testingACMEPrivateKey, metav1.GetOptions{})
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(context.TODO(), testingACMEPrivateKey, metav1.GetOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
if len(secret.Data) != 1 {
|
||||
Fail("Expected 1 key in ACME account private key secret, but there was %d", len(secret.Data))
|
||||
@@ -107,9 +108,9 @@ func testDNSProvider(name string, p dns01Provider) bool {
|
||||
|
||||
AfterEach(func() {
|
||||
By("Cleaning up")
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(issuerName, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(testingACMEPrivateKey, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(certificateSecretName, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(context.TODO(), issuerName, metav1.DeleteOptions{})
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(context.TODO(), testingACMEPrivateKey, metav1.DeleteOptions{})
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(context.TODO(), certificateSecretName, metav1.DeleteOptions{})
|
||||
})
|
||||
|
||||
It("should obtain a signed certificate for a regular domain", func() {
|
||||
@@ -124,7 +125,7 @@ func testDNSProvider(name string, p dns01Provider) bool {
|
||||
)
|
||||
cert.Namespace = f.Namespace.Name
|
||||
|
||||
cert, err := certClient.Create(cert)
|
||||
cert, err := certClient.Create(context.TODO(), cert, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, certificateName, time.Minute*5)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
@@ -140,7 +141,7 @@ func testDNSProvider(name string, p dns01Provider) bool {
|
||||
)
|
||||
cert.Namespace = f.Namespace.Name
|
||||
|
||||
cert, err := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name).Create(cert)
|
||||
cert, err := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name).Create(context.TODO(), cert, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, certificateName, time.Minute*5)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
@@ -156,7 +157,7 @@ func testDNSProvider(name string, p dns01Provider) bool {
|
||||
)
|
||||
cert.Namespace = f.Namespace.Name
|
||||
|
||||
cert, err := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name).Create(cert)
|
||||
cert, err := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name).Create(context.TODO(), cert, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
// use a longer timeout for this, as it requires performing 2 dns validations in serial
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, certificateName, time.Minute*10)
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package certificate
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"strings"
|
||||
"time"
|
||||
@@ -82,7 +83,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
},
|
||||
}
|
||||
By("Creating an Issuer")
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(acmeIssuer)
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), acmeIssuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Waiting for Issuer to become Ready")
|
||||
err = util.WaitForIssuerCondition(f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name),
|
||||
@@ -103,7 +104,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying ACME account private key exists")
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(testingACMEPrivateKey, metav1.GetOptions{})
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(context.TODO(), testingACMEPrivateKey, metav1.GetOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
if len(secret.Data) != 1 {
|
||||
Fail("Expected 1 key in ACME account private key secret, but there was %d", len(secret.Data))
|
||||
@@ -116,8 +117,8 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
|
||||
AfterEach(func() {
|
||||
By("Cleaning up")
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(issuerName, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(testingACMEPrivateKey, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(context.TODO(), issuerName, metav1.DeleteOptions{})
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(context.TODO(), testingACMEPrivateKey, metav1.DeleteOptions{})
|
||||
})
|
||||
|
||||
It("should obtain a signed certificate with a single CN from the ACME server", func() {
|
||||
@@ -131,7 +132,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
)
|
||||
cert.Namespace = f.Namespace.Name
|
||||
|
||||
_, err := certClient.Create(cert)
|
||||
_, err := certClient.Create(context.TODO(), cert, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying the Certificate is valid")
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, certificateName, time.Minute*5)
|
||||
@@ -151,7 +152,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
gen.SetCertificateKeyAlgorithm(v1alpha2.ECDSAKeyAlgorithm),
|
||||
)
|
||||
cert.Namespace = f.Namespace.Name
|
||||
_, err := certClient.Create(cert)
|
||||
_, err := certClient.Create(context.TODO(), cert, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying the Certificate is valid and of type ECDSA")
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, certificateName, time.Minute*5)
|
||||
@@ -173,7 +174,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
)
|
||||
cert.Namespace = f.Namespace.Name
|
||||
|
||||
_, err := certClient.Create(cert)
|
||||
_, err := certClient.Create(context.TODO(), cert, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, certificateName, time.Minute*5)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
@@ -190,7 +191,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
)
|
||||
cert.Namespace = f.Namespace.Name
|
||||
|
||||
_, err := certClient.Create(cert)
|
||||
_, err := certClient.Create(context.TODO(), cert, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying the Certificate is valid")
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, certificateName, time.Minute*5)
|
||||
@@ -208,7 +209,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
)
|
||||
cert.Namespace = f.Namespace.Name
|
||||
|
||||
_, err := certClient.Create(cert)
|
||||
_, err := certClient.Create(context.TODO(), cert, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Verifying the Certificate is valid")
|
||||
@@ -216,7 +217,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Getting the latest version of the Certificate")
|
||||
cert, err = certClient.Get(certificateName, metav1.GetOptions{})
|
||||
cert, err = certClient.Get(context.TODO(), certificateName, metav1.GetOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Adding an additional dnsName to the Certificate")
|
||||
@@ -224,7 +225,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
cert.Spec.DNSNames = append(cert.Spec.DNSNames, newDNSName)
|
||||
|
||||
By("Updating the Certificate in the apiserver")
|
||||
cert, err = certClient.Update(cert)
|
||||
cert, err = certClient.Update(context.TODO(), cert, metav1.UpdateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Waiting for the Certificate to be not ready")
|
||||
@@ -246,7 +247,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
)
|
||||
cert.Namespace = f.Namespace.Name
|
||||
|
||||
cert, err := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name).Create(cert)
|
||||
cert, err := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name).Create(context.TODO(), cert, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
notReadyCondition := v1alpha2.CertificateCondition{
|
||||
@@ -262,9 +263,9 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
certClient := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name)
|
||||
|
||||
By("Creating an Ingress with the issuer name annotation set")
|
||||
_, err := ingClient.Create(util.NewIngress(certificateSecretName, certificateSecretName, map[string]string{
|
||||
_, err := ingClient.Create(context.TODO(), util.NewIngress(certificateSecretName, certificateSecretName, map[string]string{
|
||||
"cert-manager.io/issuer": issuerName,
|
||||
}, acmeIngressDomain))
|
||||
}, acmeIngressDomain), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Waiting for Certificate to exist")
|
||||
@@ -284,7 +285,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
// but I haven't been able to make this happen. Create a TLS cert via
|
||||
// the self-sign issuer to make it have a "proper" TLS cert
|
||||
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(util.NewCertManagerSelfSignedIssuer("selfsign"))
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), util.NewCertManagerSelfSignedIssuer("selfsign"), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Waiting for (self-sign) Issuer to become Ready")
|
||||
err = util.WaitForIssuerCondition(f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name),
|
||||
@@ -299,7 +300,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
const secretname = "dummy-tls-secret"
|
||||
|
||||
selfcert := util.NewCertManagerBasicCertificate("dummy-tls", secretname, "selfsign", v1alpha2.IssuerKind, nil, nil, acmeIngressDomain)
|
||||
_, err = certClient.Create(selfcert)
|
||||
_, err = certClient.Create(context.TODO(), selfcert, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, dummycert, time.Minute*5)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
@@ -307,7 +308,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
// create an ingress that points at nothing, but has the TLS redirect annotation set
|
||||
// using the TLS secret that we just got from the self-sign
|
||||
ingress := f.KubeClientSet.ExtensionsV1beta1().Ingresses(f.Namespace.Name)
|
||||
_, err = ingress.Create(&ext.Ingress{
|
||||
_, err = ingress.Create(context.TODO(), &ext.Ingress{
|
||||
ObjectMeta: metav1.ObjectMeta{
|
||||
Name: fixedIngressName,
|
||||
Annotations: map[string]string{
|
||||
@@ -341,7 +342,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
}, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Creating a Certificate")
|
||||
@@ -358,7 +359,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
"testing.cert-manager.io/fixed-ingress": "true",
|
||||
}
|
||||
|
||||
_, err = certClient.Create(cert)
|
||||
_, err = certClient.Create(context.TODO(), cert, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Verifying the Certificate is valid")
|
||||
@@ -376,7 +377,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
gen.SetCertificateDNSNames(acmeIngressDomain),
|
||||
)
|
||||
cert.Namespace = f.Namespace.Name
|
||||
_, err := certClient.Create(cert)
|
||||
_, err := certClient.Create(context.TODO(), cert, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("killing the solver pod")
|
||||
@@ -385,7 +386,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
err = wait.PollImmediate(1*time.Second, time.Minute,
|
||||
func() (bool, error) {
|
||||
log.Logf("Waiting for solver pod to exist")
|
||||
podlist, err := podClient.List(metav1.ListOptions{})
|
||||
podlist, err := podClient.List(context.TODO(), metav1.ListOptions{})
|
||||
if err != nil {
|
||||
return false, err
|
||||
}
|
||||
@@ -404,7 +405,7 @@ var _ = framework.CertManagerDescribe("ACME Certificate (HTTP01)", func() {
|
||||
)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
err = podClient.Delete(pod.Name, &metav1.DeleteOptions{})
|
||||
err = podClient.Delete(context.TODO(), pod.Name, metav1.DeleteOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
// The pod should get remade and the certificate should be made valid.
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package certificate
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
. "github.com/onsi/ginkgo"
|
||||
@@ -74,7 +75,7 @@ var _ = framework.CertManagerDescribe("ACME webhook DNS provider", func() {
|
||||
},
|
||||
}))
|
||||
issuer.Namespace = f.Namespace.Name
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(issuer)
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), issuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Waiting for Issuer to become Ready")
|
||||
err = util.WaitForIssuerCondition(f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name),
|
||||
@@ -95,7 +96,7 @@ var _ = framework.CertManagerDescribe("ACME webhook DNS provider", func() {
|
||||
})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying ACME account private key exists")
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(testingACMEPrivateKey, metav1.GetOptions{})
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(context.TODO(), testingACMEPrivateKey, metav1.GetOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
if len(secret.Data) != 1 {
|
||||
Fail("Expected 1 key in ACME account private key secret, but there was %d", len(secret.Data))
|
||||
@@ -104,9 +105,9 @@ var _ = framework.CertManagerDescribe("ACME webhook DNS provider", func() {
|
||||
|
||||
AfterEach(func() {
|
||||
By("Cleaning up")
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(issuerName, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(testingACMEPrivateKey, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(certificateSecretName, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(context.TODO(), issuerName, metav1.DeleteOptions{})
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(context.TODO(), testingACMEPrivateKey, metav1.DeleteOptions{})
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(context.TODO(), certificateSecretName, metav1.DeleteOptions{})
|
||||
})
|
||||
|
||||
It("should call the dummy webhook provider and mark the challenges as presented=true", func() {
|
||||
@@ -121,7 +122,7 @@ var _ = framework.CertManagerDescribe("ACME webhook DNS provider", func() {
|
||||
)
|
||||
cert.Namespace = f.Namespace.Name
|
||||
|
||||
cert, err := certClient.Create(cert)
|
||||
cert, err := certClient.Create(context.TODO(), cert, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
var order *cmacme.Order
|
||||
@@ -173,7 +174,7 @@ var _ = framework.CertManagerDescribe("ACME webhook DNS provider", func() {
|
||||
})
|
||||
|
||||
func listOwnedChallenges(cl versioned.Interface, owner *cmacme.Order) ([]*cmacme.Challenge, error) {
|
||||
l, err := cl.AcmeV1alpha2().Challenges(owner.Namespace).List(metav1.ListOptions{})
|
||||
l, err := cl.AcmeV1alpha2().Challenges(owner.Namespace).List(context.TODO(), metav1.ListOptions{})
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -190,7 +191,7 @@ func listOwnedChallenges(cl versioned.Interface, owner *cmacme.Order) ([]*cmacme
|
||||
}
|
||||
|
||||
func listOwnedOrders(cl versioned.Interface, owner *v1alpha2.Certificate) ([]*cmacme.Order, error) {
|
||||
l, err := cl.AcmeV1alpha2().Orders(owner.Namespace).List(metav1.ListOptions{})
|
||||
l, err := cl.AcmeV1alpha2().Orders(owner.Namespace).List(context.TODO(), metav1.ListOptions{})
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package certificate
|
||||
|
||||
import (
|
||||
"context"
|
||||
"crypto/x509"
|
||||
"time"
|
||||
|
||||
@@ -81,7 +82,7 @@ func testDNSProvider(name string, p dns01Provider) bool {
|
||||
},
|
||||
}))
|
||||
issuer.Namespace = f.Namespace.Name
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(issuer)
|
||||
issuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), issuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Waiting for Issuer to become Ready")
|
||||
err = util.WaitForIssuerCondition(f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name),
|
||||
@@ -102,7 +103,7 @@ func testDNSProvider(name string, p dns01Provider) bool {
|
||||
})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying ACME account private key exists")
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(testingACMEPrivateKey, metav1.GetOptions{})
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(context.TODO(), testingACMEPrivateKey, metav1.GetOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
if len(secret.Data) != 1 {
|
||||
Fail("Expected 1 key in ACME account private key secret, but there was %d", len(secret.Data))
|
||||
@@ -111,8 +112,8 @@ func testDNSProvider(name string, p dns01Provider) bool {
|
||||
|
||||
AfterEach(func() {
|
||||
By("Cleaning up")
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(issuerName, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(testingACMEPrivateKey, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(context.TODO(), issuerName, metav1.DeleteOptions{})
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(context.TODO(), testingACMEPrivateKey, metav1.DeleteOptions{})
|
||||
})
|
||||
|
||||
It("should obtain a signed certificate for a regular domain", func() {
|
||||
@@ -124,7 +125,7 @@ func testDNSProvider(name string, p dns01Provider) bool {
|
||||
[]string{dnsDomain}, nil, nil, x509.RSA)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
cr, err = crClient.Create(cr)
|
||||
cr, err = crClient.Create(context.TODO(), cr, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
err = h.WaitCertificateRequestIssuedValid(f.Namespace.Name, certificateRequestName, time.Minute*5, key)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
@@ -137,7 +138,7 @@ func testDNSProvider(name string, p dns01Provider) bool {
|
||||
[]string{"*." + dnsDomain}, nil, nil, x509.RSA)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
cr, err = f.CertManagerClientSet.CertmanagerV1alpha2().CertificateRequests(f.Namespace.Name).Create(cr)
|
||||
cr, err = f.CertManagerClientSet.CertmanagerV1alpha2().CertificateRequests(f.Namespace.Name).Create(context.TODO(), cr, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
err = h.WaitCertificateRequestIssuedValid(f.Namespace.Name, certificateRequestName, time.Minute*5, key)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
@@ -150,7 +151,7 @@ func testDNSProvider(name string, p dns01Provider) bool {
|
||||
[]string{"*." + dnsDomain, dnsDomain}, nil, nil, x509.RSA)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
cr, err = f.CertManagerClientSet.CertmanagerV1alpha2().CertificateRequests(f.Namespace.Name).Create(cr)
|
||||
cr, err = f.CertManagerClientSet.CertmanagerV1alpha2().CertificateRequests(f.Namespace.Name).Create(context.TODO(), cr, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
// use a longer timeout for this, as it requires performing 2 dns validations in serial
|
||||
err = h.WaitCertificateRequestIssuedValid(f.Namespace.Name, certificateRequestName, time.Minute*10, key)
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package certificate
|
||||
|
||||
import (
|
||||
"context"
|
||||
"crypto/x509"
|
||||
"fmt"
|
||||
"strings"
|
||||
@@ -75,7 +76,7 @@ var _ = framework.CertManagerDescribe("ACME CertificateRequest (HTTP01)", func()
|
||||
},
|
||||
}
|
||||
By("Creating an Issuer")
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(acmeIssuer)
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), acmeIssuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Waiting for Issuer to become Ready")
|
||||
err = util.WaitForIssuerCondition(f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name),
|
||||
@@ -96,7 +97,7 @@ var _ = framework.CertManagerDescribe("ACME CertificateRequest (HTTP01)", func()
|
||||
})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying ACME account private key exists")
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(testingACMEPrivateKey, metav1.GetOptions{})
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(context.TODO(), testingACMEPrivateKey, metav1.GetOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
if len(secret.Data) != 1 {
|
||||
Fail("Expected 1 key in ACME account private key secret, but there was %d", len(secret.Data))
|
||||
@@ -109,8 +110,8 @@ var _ = framework.CertManagerDescribe("ACME CertificateRequest (HTTP01)", func()
|
||||
|
||||
AfterEach(func() {
|
||||
By("Cleaning up")
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(issuerName, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(testingACMEPrivateKey, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(context.TODO(), issuerName, metav1.DeleteOptions{})
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(context.TODO(), testingACMEPrivateKey, metav1.DeleteOptions{})
|
||||
})
|
||||
|
||||
It("should obtain a signed certificate with a single CN from the ACME server", func() {
|
||||
@@ -121,7 +122,7 @@ var _ = framework.CertManagerDescribe("ACME CertificateRequest (HTTP01)", func()
|
||||
[]string{acmeIngressDomain}, nil, nil, x509.RSA)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
cr, err = crClient.Create(cr)
|
||||
cr, err = crClient.Create(context.TODO(), cr, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Verifying the Certificate is valid")
|
||||
@@ -137,7 +138,7 @@ var _ = framework.CertManagerDescribe("ACME CertificateRequest (HTTP01)", func()
|
||||
[]string{acmeIngressDomain}, nil, nil, x509.ECDSA)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
_, err = crClient.Create(cr)
|
||||
_, err = crClient.Create(context.TODO(), cr, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying the Certificate is valid and of type ECDSA")
|
||||
err = h.WaitCertificateRequestIssuedValid(f.Namespace.Name, certificateRequestName, time.Minute*5, key)
|
||||
@@ -155,7 +156,7 @@ var _ = framework.CertManagerDescribe("ACME CertificateRequest (HTTP01)", func()
|
||||
nil, nil, x509.RSA)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
_, err = crClient.Create(cr)
|
||||
_, err = crClient.Create(context.TODO(), cr, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
err = h.WaitCertificateRequestIssuedValid(f.Namespace.Name, certificateRequestName, time.Minute*5, key)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
@@ -170,7 +171,7 @@ var _ = framework.CertManagerDescribe("ACME CertificateRequest (HTTP01)", func()
|
||||
nil, nil, x509.RSA)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
_, err = crClient.Create(cr)
|
||||
_, err = crClient.Create(context.TODO(), cr, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying the CertificateRequest is valid")
|
||||
err = h.WaitCertificateRequestIssuedValid(f.Namespace.Name, certificateRequestName, time.Minute*5, key)
|
||||
@@ -184,7 +185,7 @@ var _ = framework.CertManagerDescribe("ACME CertificateRequest (HTTP01)", func()
|
||||
[]string{"google.com"}, nil, nil, x509.RSA)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
cr, err = f.CertManagerClientSet.CertmanagerV1alpha2().CertificateRequests(f.Namespace.Name).Create(cr)
|
||||
cr, err = f.CertManagerClientSet.CertmanagerV1alpha2().CertificateRequests(f.Namespace.Name).Create(context.TODO(), cr, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
notReadyCondition := v1alpha2.CertificateRequestCondition{
|
||||
@@ -203,7 +204,7 @@ var _ = framework.CertManagerDescribe("ACME CertificateRequest (HTTP01)", func()
|
||||
[]string{acmeIngressDomain}, nil, nil, x509.RSA)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
_, err = crClient.Create(cr)
|
||||
_, err = crClient.Create(context.TODO(), cr, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("killing the solver pod")
|
||||
@@ -212,7 +213,7 @@ var _ = framework.CertManagerDescribe("ACME CertificateRequest (HTTP01)", func()
|
||||
err = wait.PollImmediate(1*time.Second, time.Minute,
|
||||
func() (bool, error) {
|
||||
log.Logf("Waiting for solver pod to exist")
|
||||
podlist, err := podClient.List(metav1.ListOptions{})
|
||||
podlist, err := podClient.List(context.TODO(), metav1.ListOptions{})
|
||||
if err != nil {
|
||||
return false, err
|
||||
}
|
||||
@@ -231,7 +232,7 @@ var _ = framework.CertManagerDescribe("ACME CertificateRequest (HTTP01)", func()
|
||||
)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
err = podClient.Delete(pod.Name, &metav1.DeleteOptions{})
|
||||
err = podClient.Delete(context.TODO(), pod.Name, metav1.DeleteOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
// The pod should get remade and the certificate should be made valid.
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package dnsproviders
|
||||
|
||||
import (
|
||||
"context"
|
||||
corev1 "k8s.io/api/core/v1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
|
||||
@@ -77,7 +78,7 @@ func (b *Cloudflare) Provision() error {
|
||||
},
|
||||
}
|
||||
|
||||
s, err := b.Base.Details().KubeClient.CoreV1().Secrets(b.Namespace).Create(secret)
|
||||
s, err := b.Base.Details().KubeClient.CoreV1().Secrets(b.Namespace).Create(context.TODO(), secret, metav1.CreateOptions{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -100,7 +101,7 @@ func (b *Cloudflare) Provision() error {
|
||||
}
|
||||
|
||||
func (b *Cloudflare) Deprovision() error {
|
||||
b.Base.Details().KubeClient.CoreV1().Secrets(b.createdSecret.Namespace).Delete(b.createdSecret.Name, nil)
|
||||
b.Base.Details().KubeClient.CoreV1().Secrets(b.createdSecret.Namespace).Delete(context.TODO(), b.createdSecret.Name, metav1.DeleteOptions{})
|
||||
return nil
|
||||
}
|
||||
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package acme
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
|
||||
. "github.com/onsi/ginkgo"
|
||||
@@ -41,15 +42,15 @@ var _ = framework.CertManagerDescribe("ACME Issuer", func() {
|
||||
|
||||
AfterEach(func() {
|
||||
By("Cleaning up")
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(issuerName, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(testingACMEPrivateKey, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(context.TODO(), issuerName, metav1.DeleteOptions{})
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(context.TODO(), testingACMEPrivateKey, metav1.DeleteOptions{})
|
||||
})
|
||||
|
||||
It("should register ACME account", func() {
|
||||
acmeIssuer := util.NewCertManagerACMEIssuer(issuerName, f.Config.Addons.ACMEServer.URL, testingACMEEmail, testingACMEPrivateKey)
|
||||
|
||||
By("Creating an Issuer")
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(acmeIssuer)
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), acmeIssuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Waiting for Issuer to become Ready")
|
||||
@@ -73,7 +74,7 @@ var _ = framework.CertManagerDescribe("ACME Issuer", func() {
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Verifying ACME account private key exists")
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(testingACMEPrivateKey, metav1.GetOptions{})
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(context.TODO(), testingACMEPrivateKey, metav1.GetOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
if len(secret.Data) != 1 {
|
||||
Fail("Expected 1 key in ACME account private key secret, but there was %d", len(secret.Data))
|
||||
@@ -84,7 +85,7 @@ var _ = framework.CertManagerDescribe("ACME Issuer", func() {
|
||||
acmeIssuer := util.NewCertManagerACMEIssuer(issuerName, f.Config.Addons.ACMEServer.URL, testingACMEEmail, testingACMEPrivateKey)
|
||||
|
||||
By("Creating an Issuer")
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(acmeIssuer)
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), acmeIssuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Waiting for Issuer to become Ready")
|
||||
@@ -110,7 +111,7 @@ var _ = framework.CertManagerDescribe("ACME Issuer", func() {
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Verifying ACME account private key exists")
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(testingACMEPrivateKey, metav1.GetOptions{})
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(context.TODO(), testingACMEPrivateKey, metav1.GetOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
if len(secret.Data) != 1 {
|
||||
@@ -118,12 +119,12 @@ var _ = framework.CertManagerDescribe("ACME Issuer", func() {
|
||||
}
|
||||
|
||||
By("Deleting the Issuer")
|
||||
err = f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(acmeIssuer.Name, &metav1.DeleteOptions{})
|
||||
err = f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(context.TODO(), acmeIssuer.Name, metav1.DeleteOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Recreating the Issuer")
|
||||
acmeIssuer = util.NewCertManagerACMEIssuer(issuerName, f.Config.Addons.ACMEServer.URL, testingACMEEmail, testingACMEPrivateKey)
|
||||
_, err = f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(acmeIssuer)
|
||||
_, err = f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), acmeIssuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Waiting for Issuer to become Ready")
|
||||
@@ -155,7 +156,7 @@ var _ = framework.CertManagerDescribe("ACME Issuer", func() {
|
||||
acmeIssuer := util.NewCertManagerACMEIssuer(issuerName, invalidACMEURL, testingACMEEmail, testingACMEPrivateKey)
|
||||
|
||||
By("Creating an Issuer with an invalid server")
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(acmeIssuer)
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), acmeIssuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Waiting for Issuer to become non-Ready")
|
||||
@@ -172,7 +173,7 @@ var _ = framework.CertManagerDescribe("ACME Issuer", func() {
|
||||
acmeIssuer := util.NewCertManagerACMEIssuer(issuerName, f.Config.Addons.ACMEServer.URL, testingACMEEmail, testingACMEPrivateKey)
|
||||
|
||||
By("Creating an Issuer")
|
||||
acmeIssuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(acmeIssuer)
|
||||
acmeIssuer, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), acmeIssuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Waiting for Issuer to become Ready")
|
||||
@@ -196,7 +197,7 @@ var _ = framework.CertManagerDescribe("ACME Issuer", func() {
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Verifying ACME account private key exists")
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(testingACMEPrivateKey, metav1.GetOptions{})
|
||||
secret, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Get(context.TODO(), testingACMEPrivateKey, metav1.GetOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
if len(secret.Data) != 1 {
|
||||
Fail("Expected 1 key in ACME account private key secret, but there was %d", len(secret.Data))
|
||||
@@ -215,9 +216,9 @@ var _ = framework.CertManagerDescribe("ACME Issuer", func() {
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Changing the email field")
|
||||
acmeIssuer, err = f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Get(acmeIssuer.Name, metav1.GetOptions{})
|
||||
acmeIssuer, err = f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Get(context.TODO(), acmeIssuer.Name, metav1.GetOptions{})
|
||||
acmeIssuer.Spec.ACME.Email = testingACMEEmailAlternative
|
||||
acmeIssuer, err = f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Update(acmeIssuer)
|
||||
acmeIssuer, err = f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Update(context.TODO(), acmeIssuer, metav1.UpdateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Waiting for Issuer to become Ready")
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package ca
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
. "github.com/onsi/ginkgo"
|
||||
@@ -41,7 +42,7 @@ var _ = framework.CertManagerDescribe("CA Certificate", func() {
|
||||
|
||||
JustBeforeEach(func() {
|
||||
By("Creating an Issuer")
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(util.NewCertManagerCAIssuer(issuerName, issuerSecretName))
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), util.NewCertManagerCAIssuer(issuerName, issuerSecretName), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Waiting for Issuer to become Ready")
|
||||
err = util.WaitForIssuerCondition(f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name),
|
||||
@@ -55,14 +56,14 @@ var _ = framework.CertManagerDescribe("CA Certificate", func() {
|
||||
|
||||
AfterEach(func() {
|
||||
By("Cleaning up")
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(issuerSecretName, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(issuerName, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(context.TODO(), issuerSecretName, metav1.DeleteOptions{})
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(context.TODO(), issuerName, metav1.DeleteOptions{})
|
||||
})
|
||||
|
||||
Context("when the CA is the root", func() {
|
||||
BeforeEach(func() {
|
||||
By("Creating a signing keypair fixture")
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(newSigningKeypairSecret(issuerSecretName))
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(context.TODO(), newSigningKeypairSecret(issuerSecretName), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
})
|
||||
|
||||
@@ -70,7 +71,7 @@ var _ = framework.CertManagerDescribe("CA Certificate", func() {
|
||||
certClient := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name)
|
||||
|
||||
By("Creating a Certificate")
|
||||
_, err := certClient.Create(util.NewCertManagerBasicCertificate(certificateName, certificateSecretName, issuerName, v1alpha2.IssuerKind, nil, nil))
|
||||
_, err := certClient.Create(context.TODO(), util.NewCertManagerBasicCertificate(certificateName, certificateSecretName, issuerName, v1alpha2.IssuerKind, nil, nil), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying the Certificate is valid")
|
||||
err = h.WaitCertificateIssuedValidTLS(f.Namespace.Name, certificateName, time.Second*30, []byte(rootCert))
|
||||
@@ -85,7 +86,7 @@ var _ = framework.CertManagerDescribe("CA Certificate", func() {
|
||||
crt.Spec.KeySize = 521
|
||||
|
||||
By("Creating a Certificate")
|
||||
_, err := certClient.Create(crt)
|
||||
_, err := certClient.Create(context.TODO(), crt, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Verifying the Certificate is valid")
|
||||
@@ -118,7 +119,7 @@ var _ = framework.CertManagerDescribe("CA Certificate", func() {
|
||||
certClient := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name)
|
||||
|
||||
By("Creating a Certificate")
|
||||
cert, err := certClient.Create(util.NewCertManagerBasicCertificate(certificateName, certificateSecretName, issuerName, v1alpha2.IssuerKind, v.inputDuration, v.inputRenewBefore))
|
||||
cert, err := certClient.Create(context.TODO(), util.NewCertManagerBasicCertificate(certificateName, certificateSecretName, issuerName, v1alpha2.IssuerKind, v.inputDuration, v.inputRenewBefore), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying the Certificate is valid")
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, certificateName, time.Second*30)
|
||||
@@ -131,7 +132,7 @@ var _ = framework.CertManagerDescribe("CA Certificate", func() {
|
||||
Context("when the CA is an issuer", func() {
|
||||
BeforeEach(func() {
|
||||
By("Creating a signing keypair fixture")
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(newSigningIssuer1KeypairSecret(issuerSecretName))
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(context.TODO(), newSigningIssuer1KeypairSecret(issuerSecretName), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
})
|
||||
|
||||
@@ -139,7 +140,7 @@ var _ = framework.CertManagerDescribe("CA Certificate", func() {
|
||||
certClient := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name)
|
||||
|
||||
By("Creating a Certificate")
|
||||
_, err := certClient.Create(util.NewCertManagerBasicCertificate(certificateName, certificateSecretName, issuerName, v1alpha2.IssuerKind, nil, nil))
|
||||
_, err := certClient.Create(context.TODO(), util.NewCertManagerBasicCertificate(certificateName, certificateSecretName, issuerName, v1alpha2.IssuerKind, nil, nil), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying the Certificate is valid")
|
||||
err = h.WaitCertificateIssuedValidTLS(f.Namespace.Name, certificateName, time.Second*30, []byte(rootCert))
|
||||
@@ -150,7 +151,7 @@ var _ = framework.CertManagerDescribe("CA Certificate", func() {
|
||||
Context("when the CA is a second level issuer", func() {
|
||||
BeforeEach(func() {
|
||||
By("Creating a signing keypair fixture")
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(newSigningIssuer2KeypairSecret(issuerSecretName))
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(context.TODO(), newSigningIssuer2KeypairSecret(issuerSecretName), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
})
|
||||
|
||||
@@ -158,7 +159,7 @@ var _ = framework.CertManagerDescribe("CA Certificate", func() {
|
||||
certClient := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name)
|
||||
|
||||
By("Creating a Certificate with Usages")
|
||||
_, err := certClient.Create(gen.Certificate(certificateName, gen.SetCertificateNamespace(f.Namespace.Name), gen.SetCertificateCommonName("test.domain.com"), gen.SetCertificateSecretName(certificateSecretName), gen.SetCertificateIssuer(cmmeta.ObjectReference{Name: issuerName, Kind: v1alpha2.IssuerKind}), gen.SetCertificateKeyUsages(v1alpha2.UsageServerAuth, v1alpha2.UsageClientAuth)))
|
||||
_, err := certClient.Create(context.TODO(), gen.Certificate(certificateName, gen.SetCertificateNamespace(f.Namespace.Name), gen.SetCertificateCommonName("test.domain.com"), gen.SetCertificateSecretName(certificateSecretName), gen.SetCertificateIssuer(cmmeta.ObjectReference{Name: issuerName, Kind: v1alpha2.IssuerKind}), gen.SetCertificateKeyUsages(v1alpha2.UsageServerAuth, v1alpha2.UsageClientAuth)), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying the Certificate is valid")
|
||||
err = h.WaitCertificateIssuedValidTLS(f.Namespace.Name, certificateName, time.Second*30, []byte(rootCert))
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package ca
|
||||
|
||||
import (
|
||||
"context"
|
||||
"crypto/x509"
|
||||
"net"
|
||||
"net/url"
|
||||
@@ -57,7 +58,7 @@ var _ = framework.CertManagerDescribe("CA CertificateRequest", func() {
|
||||
|
||||
JustBeforeEach(func() {
|
||||
By("Creating an Issuer")
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(util.NewCertManagerCAIssuer(issuerName, issuerSecretName))
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), util.NewCertManagerCAIssuer(issuerName, issuerSecretName), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Waiting for Issuer to become Ready")
|
||||
err = util.WaitForIssuerCondition(f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name),
|
||||
@@ -71,14 +72,14 @@ var _ = framework.CertManagerDescribe("CA CertificateRequest", func() {
|
||||
|
||||
AfterEach(func() {
|
||||
By("Cleaning up")
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(issuerSecretName, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(issuerName, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(context.TODO(), issuerSecretName, metav1.DeleteOptions{})
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(context.TODO(), issuerName, metav1.DeleteOptions{})
|
||||
})
|
||||
|
||||
Context("when the CA is the root", func() {
|
||||
BeforeEach(func() {
|
||||
By("Creating a signing keypair fixture")
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(newSigningKeypairSecret(issuerSecretName))
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(context.TODO(), newSigningKeypairSecret(issuerSecretName), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
})
|
||||
|
||||
@@ -92,7 +93,7 @@ var _ = framework.CertManagerDescribe("CA CertificateRequest", func() {
|
||||
},
|
||||
exampleDNSNames, exampleIPAddresses, exampleURIs, x509.RSA)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
_, err = certRequestClient.Create(cr)
|
||||
_, err = certRequestClient.Create(context.TODO(), cr, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying the Certificate is valid")
|
||||
err = h.WaitCertificateRequestIssuedValidTLS(f.Namespace.Name, certificateRequestName, time.Second*30, key, []byte(rootCert))
|
||||
@@ -109,7 +110,7 @@ var _ = framework.CertManagerDescribe("CA CertificateRequest", func() {
|
||||
},
|
||||
exampleDNSNames, exampleIPAddresses, exampleURIs, x509.ECDSA)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
_, err = certRequestClient.Create(cr)
|
||||
_, err = certRequestClient.Create(context.TODO(), cr, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Verifying the Certificate is valid")
|
||||
err = h.WaitCertificateRequestIssuedValidTLS(f.Namespace.Name, certificateRequestName, time.Second*30, key, []byte(rootCert))
|
||||
@@ -141,13 +142,13 @@ var _ = framework.CertManagerDescribe("CA CertificateRequest", func() {
|
||||
csr, key, err := gen.CSR(x509.RSA, gen.SetCSRDNSNames(exampleDNSNames...), gen.SetCSRIPAddresses(exampleIPAddresses...), gen.SetCSRURIs(exampleURLs()...))
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
cr := gen.CertificateRequest(certificateRequestName, gen.SetCertificateRequestNamespace(f.Namespace.Name), gen.SetCertificateRequestIssuer(cmmeta.ObjectReference{Kind: v1alpha2.IssuerKind, Name: issuerName}), gen.SetCertificateRequestDuration(v.inputDuration), gen.SetCertificateRequestCSR(csr))
|
||||
cr, err = crClient.Create(cr)
|
||||
cr, err = crClient.Create(context.TODO(), cr, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Verifying the CertificateRequest is valid")
|
||||
err = h.WaitCertificateRequestIssuedValid(f.Namespace.Name, certificateRequestName, time.Second*30, key)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
cr, err = crClient.Get(cr.Name, metav1.GetOptions{})
|
||||
cr, err = crClient.Get(context.TODO(), cr.Name, metav1.GetOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
f.CertificateRequestDurationValid(cr, v.expectedDuration, 0)
|
||||
})
|
||||
|
||||
@@ -17,8 +17,11 @@ limitations under the License.
|
||||
package ca
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
. "github.com/onsi/ginkgo"
|
||||
. "github.com/onsi/gomega"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
|
||||
"github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
cmmeta "github.com/jetstack/cert-manager/pkg/apis/meta/v1"
|
||||
@@ -35,20 +38,20 @@ var _ = framework.CertManagerDescribe("CA ClusterIssuer", func() {
|
||||
|
||||
BeforeEach(func() {
|
||||
By("Creating a signing keypair fixture")
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Config.Addons.CertManager.ClusterResourceNamespace).Create(newSigningKeypairSecret(secretName))
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Config.Addons.CertManager.ClusterResourceNamespace).Create(context.TODO(), newSigningKeypairSecret(secretName), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
})
|
||||
|
||||
AfterEach(func() {
|
||||
By("Cleaning up")
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Config.Addons.CertManager.ClusterResourceNamespace).Delete(secretName, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(issuerName, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Config.Addons.CertManager.ClusterResourceNamespace).Delete(context.TODO(), secretName, metav1.DeleteOptions{})
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(context.TODO(), issuerName, metav1.DeleteOptions{})
|
||||
})
|
||||
|
||||
It("should validate a signing keypair", func() {
|
||||
By("Creating an Issuer")
|
||||
clusterIssuer := util.NewCertManagerCAClusterIssuer(issuerName, secretName)
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(clusterIssuer)
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(context.TODO(), clusterIssuer, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Waiting for Issuer to become Ready")
|
||||
err = util.WaitForClusterIssuerCondition(f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers(),
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package ca
|
||||
|
||||
import (
|
||||
"context"
|
||||
. "github.com/onsi/ginkgo"
|
||||
. "github.com/onsi/gomega"
|
||||
|
||||
@@ -24,6 +25,7 @@ import (
|
||||
cmmeta "github.com/jetstack/cert-manager/pkg/apis/meta/v1"
|
||||
"github.com/jetstack/cert-manager/test/e2e/framework"
|
||||
"github.com/jetstack/cert-manager/test/e2e/util"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
)
|
||||
|
||||
var _ = framework.CertManagerDescribe("CA Issuer", func() {
|
||||
@@ -34,18 +36,18 @@ var _ = framework.CertManagerDescribe("CA Issuer", func() {
|
||||
|
||||
BeforeEach(func() {
|
||||
By("Creating a signing keypair fixture")
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(newSigningKeypairSecret(secretName))
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(context.TODO(), newSigningKeypairSecret(secretName), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
})
|
||||
|
||||
AfterEach(func() {
|
||||
By("Cleaning up")
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(secretName, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(context.TODO(), secretName, metav1.DeleteOptions{})
|
||||
})
|
||||
|
||||
It("should generate a signing keypair", func() {
|
||||
By("Creating an Issuer")
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(util.NewCertManagerCAIssuer(issuerName, secretName))
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), util.NewCertManagerCAIssuer(issuerName, secretName), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Waiting for Issuer to become Ready")
|
||||
err = util.WaitForIssuerCondition(f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name),
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package selfsigned
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"time"
|
||||
|
||||
@@ -43,7 +44,7 @@ var _ = framework.CertManagerDescribe("Self Signed Certificate", func() {
|
||||
|
||||
certClient := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name)
|
||||
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(util.NewCertManagerSelfSignedIssuer(issuerName))
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), util.NewCertManagerSelfSignedIssuer(issuerName), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Waiting for Issuer to become Ready")
|
||||
err = util.WaitForIssuerCondition(f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name),
|
||||
@@ -54,7 +55,7 @@ var _ = framework.CertManagerDescribe("Self Signed Certificate", func() {
|
||||
})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Creating a Certificate")
|
||||
_, err = certClient.Create(util.NewCertManagerBasicCertificate(certificateName, certificateSecretName, issuerName, v1alpha2.IssuerKind, nil, nil))
|
||||
_, err = certClient.Create(context.TODO(), util.NewCertManagerBasicCertificate(certificateName, certificateSecretName, issuerName, v1alpha2.IssuerKind, nil, nil), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, certificateName, time.Minute*5)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
@@ -86,7 +87,7 @@ var _ = framework.CertManagerDescribe("Self Signed Certificate", func() {
|
||||
|
||||
By("Creating an Issuer")
|
||||
issuerDurationName := fmt.Sprintf("%s-%d", issuerName, v.expectedDuration)
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(util.NewCertManagerSelfSignedIssuer(issuerDurationName))
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), util.NewCertManagerSelfSignedIssuer(issuerDurationName), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Waiting for Issuer to become Ready")
|
||||
err = util.WaitForIssuerCondition(f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name),
|
||||
@@ -98,7 +99,7 @@ var _ = framework.CertManagerDescribe("Self Signed Certificate", func() {
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Creating a Certificate")
|
||||
cert, err := certClient.Create(util.NewCertManagerBasicCertificate(certificateName, certificateSecretName, issuerDurationName, v1alpha2.IssuerKind, v.inputDuration, v.inputRenewBefore))
|
||||
cert, err := certClient.Create(context.TODO(), util.NewCertManagerBasicCertificate(certificateName, certificateSecretName, issuerDurationName, v1alpha2.IssuerKind, v.inputDuration, v.inputRenewBefore), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, certificateName, time.Second*30)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
@@ -111,14 +112,14 @@ var _ = framework.CertManagerDescribe("Self Signed Certificate", func() {
|
||||
|
||||
certClient := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name)
|
||||
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(util.NewCertManagerSelfSignedIssuer(issuerName))
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), util.NewCertManagerSelfSignedIssuer(issuerName), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
crt := util.NewCertManagerBasicCertificate(certificateName, certificateSecretName, issuerName, v1alpha2.IssuerKind, nil, nil)
|
||||
crt.Spec.KeyEncoding = v1alpha2.PKCS8
|
||||
|
||||
By("Creating a Certificate")
|
||||
_, err = certClient.Create(crt)
|
||||
_, err = certClient.Create(context.TODO(), crt, metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Verifying the Certificate is valid")
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package selfsigned
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
. "github.com/onsi/ginkgo"
|
||||
@@ -42,7 +43,7 @@ var _ = framework.CertManagerDescribe("SelfSigned CertificateRequest", func() {
|
||||
|
||||
JustBeforeEach(func() {
|
||||
By("Creating an Issuer")
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(util.NewCertManagerSelfSignedIssuer(issuerName))
|
||||
_, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), util.NewCertManagerSelfSignedIssuer(issuerName), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
By("Waiting for Issuer to become Ready")
|
||||
err = util.WaitForIssuerCondition(f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name),
|
||||
@@ -70,16 +71,16 @@ var _ = framework.CertManagerDescribe("SelfSigned CertificateRequest", func() {
|
||||
|
||||
AfterEach(func() {
|
||||
By("Cleaning up")
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(certificateRequestSecretName, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(issuerName, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Delete(context.TODO(), certificateRequestSecretName, metav1.DeleteOptions{})
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(context.TODO(), issuerName, metav1.DeleteOptions{})
|
||||
})
|
||||
|
||||
Context("Self Signed and private key", func() {
|
||||
|
||||
BeforeEach(func() {
|
||||
By("Creating a signing keypair fixture")
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(newPrivateKeySecret(
|
||||
certificateRequestSecretName, f.Namespace.Name, rootRSAKey))
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Create(context.TODO(), newPrivateKeySecret(
|
||||
certificateRequestSecretName, f.Namespace.Name, rootRSAKey), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
})
|
||||
|
||||
@@ -90,9 +91,9 @@ var _ = framework.CertManagerDescribe("SelfSigned CertificateRequest", func() {
|
||||
csr, err := generateRSACSR()
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
_, err = crClient.Create(gen.CertificateRequestFrom(basicCR,
|
||||
_, err = crClient.Create(context.TODO(), gen.CertificateRequestFrom(basicCR,
|
||||
gen.SetCertificateRequestCSR(csr),
|
||||
))
|
||||
), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Verifying the Certificate is valid")
|
||||
@@ -102,8 +103,8 @@ var _ = framework.CertManagerDescribe("SelfSigned CertificateRequest", func() {
|
||||
|
||||
It("should be able to obtain an ECDSA Certificate backed by a ECSDA key", func() {
|
||||
// Replace RSA key secret with ECDSA one
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Update(newPrivateKeySecret(
|
||||
certificateRequestSecretName, f.Namespace.Name, rootECKey))
|
||||
_, err := f.KubeClientSet.CoreV1().Secrets(f.Namespace.Name).Update(context.TODO(), newPrivateKeySecret(
|
||||
certificateRequestSecretName, f.Namespace.Name, rootECKey), metav1.UpdateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
crClient := f.CertManagerClientSet.CertmanagerV1alpha2().CertificateRequests(f.Namespace.Name)
|
||||
@@ -111,9 +112,9 @@ var _ = framework.CertManagerDescribe("SelfSigned CertificateRequest", func() {
|
||||
csr, err := generateECCSR()
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
_, err = crClient.Create(gen.CertificateRequestFrom(basicCR,
|
||||
_, err = crClient.Create(context.TODO(), gen.CertificateRequestFrom(basicCR,
|
||||
gen.SetCertificateRequestCSR(csr),
|
||||
))
|
||||
), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Verifying the Certificate is valid")
|
||||
@@ -145,15 +146,15 @@ var _ = framework.CertManagerDescribe("SelfSigned CertificateRequest", func() {
|
||||
csr, err := generateRSACSR()
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
_, err = crClient.Create(gen.CertificateRequestFrom(basicCR,
|
||||
_, err = crClient.Create(context.TODO(), gen.CertificateRequestFrom(basicCR,
|
||||
gen.SetCertificateRequestCSR(csr),
|
||||
))
|
||||
), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Verifying the CertificateRequest is valid")
|
||||
err = h.WaitCertificateRequestIssuedValid(f.Namespace.Name, certificateRequestName, time.Second*30, rootRSAKeySigner)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
cr, err := crClient.Get(certificateRequestName, metav1.GetOptions{})
|
||||
cr, err := crClient.Get(context.TODO(), certificateRequestName, metav1.GetOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
f.CertificateRequestDurationValid(cr, v.expectedDuration, 0)
|
||||
})
|
||||
|
||||
@@ -20,6 +20,7 @@ go_library(
|
||||
"//test/e2e/util:go_default_library",
|
||||
"@com_github_onsi_ginkgo//:go_default_library",
|
||||
"@com_github_onsi_gomega//:go_default_library",
|
||||
"@io_k8s_apimachinery//pkg/apis/meta/v1:go_default_library",
|
||||
],
|
||||
)
|
||||
|
||||
|
||||
@@ -17,6 +17,7 @@ limitations under the License.
|
||||
package certificate
|
||||
|
||||
import (
|
||||
"context"
|
||||
"path"
|
||||
"time"
|
||||
|
||||
@@ -92,7 +93,7 @@ func runVaultAppRoleTests(issuerKind string) {
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
roleId, secretId, err = vaultInit.CreateAppRole()
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
sec, err := f.KubeClientSet.CoreV1().Secrets(vaultSecretNamespace).Create(vaultaddon.NewVaultAppRoleSecret(vaultSecretAppRoleName, secretId))
|
||||
sec, err := f.KubeClientSet.CoreV1().Secrets(vaultSecretNamespace).Create(context.TODO(), vaultaddon.NewVaultAppRoleSecret(vaultSecretAppRoleName, secretId), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
vaultSecretName = sec.Name
|
||||
@@ -103,12 +104,12 @@ func runVaultAppRoleTests(issuerKind string) {
|
||||
Expect(vaultInit.Clean()).NotTo(HaveOccurred())
|
||||
|
||||
if issuerKind == cmapi.IssuerKind {
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(vaultIssuerName, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(context.TODO(), vaultIssuerName, metav1.DeleteOptions{})
|
||||
} else {
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(vaultIssuerName, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(context.TODO(), vaultIssuerName, metav1.DeleteOptions{})
|
||||
}
|
||||
|
||||
f.KubeClientSet.CoreV1().Secrets(vaultSecretNamespace).Delete(vaultSecretName, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(vaultSecretNamespace).Delete(context.TODO(), vaultSecretName, metav1.DeleteOptions{})
|
||||
})
|
||||
|
||||
It("should generate a new valid certificate", func() {
|
||||
@@ -119,12 +120,12 @@ func runVaultAppRoleTests(issuerKind string) {
|
||||
|
||||
var err error
|
||||
if issuerKind == cmapi.IssuerKind {
|
||||
iss, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(util.NewCertManagerVaultIssuerAppRole("test-vault-issuer-", vaultURL, vaultPath, roleId, vaultSecretName, authPath, vault.Details().VaultCA))
|
||||
iss, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), util.NewCertManagerVaultIssuerAppRole("test-vault-issuer-", vaultURL, vaultPath, roleId, vaultSecretName, authPath, vault.Details().VaultCA), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
vaultIssuerName = iss.Name
|
||||
} else {
|
||||
iss, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(util.NewCertManagerVaultClusterIssuerAppRole("test-vault-issuer-", vaultURL, vaultPath, roleId, vaultSecretName, authPath, vault.Details().VaultCA))
|
||||
iss, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(context.TODO(), util.NewCertManagerVaultClusterIssuerAppRole("test-vault-issuer-", vaultURL, vaultPath, roleId, vaultSecretName, authPath, vault.Details().VaultCA), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
vaultIssuerName = iss.Name
|
||||
@@ -151,7 +152,7 @@ func runVaultAppRoleTests(issuerKind string) {
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Creating a Certificate")
|
||||
_, err = certClient.Create(util.NewCertManagerVaultCertificate(certificateName, certificateSecretName, vaultIssuerName, issuerKind, nil, nil))
|
||||
_, err = certClient.Create(context.TODO(), util.NewCertManagerVaultCertificate(certificateName, certificateSecretName, vaultIssuerName, issuerKind, nil, nil), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, certificateName, time.Minute*5)
|
||||
@@ -199,12 +200,12 @@ func runVaultAppRoleTests(issuerKind string) {
|
||||
|
||||
var err error
|
||||
if issuerKind == cmapi.IssuerKind {
|
||||
iss, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(util.NewCertManagerVaultIssuerAppRole("test-vault-issuer-", vault.Details().Host, vaultPath, roleId, vaultSecretName, authPath, vault.Details().VaultCA))
|
||||
iss, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), util.NewCertManagerVaultIssuerAppRole("test-vault-issuer-", vault.Details().Host, vaultPath, roleId, vaultSecretName, authPath, vault.Details().VaultCA), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
vaultIssuerName = iss.Name
|
||||
} else {
|
||||
iss, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(util.NewCertManagerVaultClusterIssuerAppRole("test-vault-issuer-", vault.Details().Host, vaultPath, roleId, vaultSecretName, authPath, vault.Details().VaultCA))
|
||||
iss, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(context.TODO(), util.NewCertManagerVaultClusterIssuerAppRole("test-vault-issuer-", vault.Details().Host, vaultPath, roleId, vaultSecretName, authPath, vault.Details().VaultCA), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
vaultIssuerName = iss.Name
|
||||
@@ -230,7 +231,7 @@ func runVaultAppRoleTests(issuerKind string) {
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Creating a Certificate")
|
||||
cert, err := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name).Create(util.NewCertManagerVaultCertificate(certificateName, certificateSecretName, vaultIssuerName, issuerKind, v.inputDuration, v.inputRenewBefore))
|
||||
cert, err := f.CertManagerClientSet.CertmanagerV1alpha2().Certificates(f.Namespace.Name).Create(context.TODO(), util.NewCertManagerVaultCertificate(certificateName, certificateSecretName, vaultIssuerName, issuerKind, v.inputDuration, v.inputRenewBefore), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, certificateName, time.Minute*5)
|
||||
|
||||
@@ -17,11 +17,13 @@ limitations under the License.
|
||||
package certificate
|
||||
|
||||
import (
|
||||
"context"
|
||||
"path"
|
||||
"time"
|
||||
|
||||
. "github.com/onsi/ginkgo"
|
||||
. "github.com/onsi/gomega"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
|
||||
cmapi "github.com/jetstack/cert-manager/pkg/apis/certmanager/v1alpha2"
|
||||
cmmeta "github.com/jetstack/cert-manager/pkg/apis/meta/v1"
|
||||
@@ -90,7 +92,7 @@ func runVaultCustomAppRoleTests(issuerKind string) {
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
roleId, secretId, err = vaultInit.CreateAppRole()
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
sec, err := f.KubeClientSet.CoreV1().Secrets(vaultSecretNamespace).Create(vaultaddon.NewVaultAppRoleSecret(vaultSecretAppRoleName, secretId))
|
||||
sec, err := f.KubeClientSet.CoreV1().Secrets(vaultSecretNamespace).Create(context.TODO(), vaultaddon.NewVaultAppRoleSecret(vaultSecretAppRoleName, secretId), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
vaultSecretName = sec.Name
|
||||
@@ -101,12 +103,12 @@ func runVaultCustomAppRoleTests(issuerKind string) {
|
||||
Expect(vaultInit.Clean()).NotTo(HaveOccurred())
|
||||
|
||||
if issuerKind == cmapi.IssuerKind {
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(vaultIssuerName, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Delete(context.TODO(), vaultIssuerName, metav1.DeleteOptions{})
|
||||
} else {
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(vaultIssuerName, nil)
|
||||
f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Delete(context.TODO(), vaultIssuerName, metav1.DeleteOptions{})
|
||||
}
|
||||
|
||||
f.KubeClientSet.CoreV1().Secrets(vaultSecretNamespace).Delete(vaultSecretName, nil)
|
||||
f.KubeClientSet.CoreV1().Secrets(vaultSecretNamespace).Delete(context.TODO(), vaultSecretName, metav1.DeleteOptions{})
|
||||
})
|
||||
|
||||
It("should generate a new valid certificate", func() {
|
||||
@@ -117,12 +119,12 @@ func runVaultCustomAppRoleTests(issuerKind string) {
|
||||
|
||||
var err error
|
||||
if issuerKind == cmapi.IssuerKind {
|
||||
iss, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(util.NewCertManagerVaultIssuerAppRole("test-vault-issuer-", vaultURL, vaultPath, roleId, vaultSecretName, authPath, vault.Details().VaultCA))
|
||||
iss, err := f.CertManagerClientSet.CertmanagerV1alpha2().Issuers(f.Namespace.Name).Create(context.TODO(), util.NewCertManagerVaultIssuerAppRole("test-vault-issuer-", vaultURL, vaultPath, roleId, vaultSecretName, authPath, vault.Details().VaultCA), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
vaultIssuerName = iss.Name
|
||||
} else {
|
||||
iss, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(util.NewCertManagerVaultClusterIssuerAppRole("test-vault-issuer-", vaultURL, vaultPath, roleId, vaultSecretName, authPath, vault.Details().VaultCA))
|
||||
iss, err := f.CertManagerClientSet.CertmanagerV1alpha2().ClusterIssuers().Create(context.TODO(), util.NewCertManagerVaultClusterIssuerAppRole("test-vault-issuer-", vaultURL, vaultPath, roleId, vaultSecretName, authPath, vault.Details().VaultCA), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
vaultIssuerName = iss.Name
|
||||
@@ -148,7 +150,7 @@ func runVaultCustomAppRoleTests(issuerKind string) {
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
By("Creating a Certificate")
|
||||
_, err = certClient.Create(util.NewCertManagerVaultCertificate(certificateName, certificateSecretName, vaultIssuerName, issuerKind, nil, nil))
|
||||
_, err = certClient.Create(context.TODO(), util.NewCertManagerVaultCertificate(certificateName, certificateSecretName, vaultIssuerName, issuerKind, nil, nil), metav1.CreateOptions{})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
err = h.WaitCertificateIssuedValid(f.Namespace.Name, certificateName, time.Minute*5)
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user