Skip to content

Commit 5ca83ff

Browse files
author
Mengqi Yu
committed
restructure certwriter and certprovisioner packages
1 parent 182c86f commit 5ca83ff

23 files changed

+1211
-1530
lines changed

example/main.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,7 @@ func main() {
103103
as, err := webhook.NewServer("foo-admission-server", mgr, webhook.ServerOptions{
104104
Port: 443,
105105
CertDir: "/tmp/cert",
106-
//Client: mgr.GetClient(),
107-
KVMap: map[string]interface{}{"foo": "bar"},
106+
KVMap: map[string]interface{}{"foo": "bar"},
108107
BootstrapOptions: &webhook.BootstrapOptions{
109108
Secret: &apitypes.NamespacedName{
110109
Namespace: "default",

pkg/webhook/admission/builder/builder.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ func (b *WebhookBuilder) Build(handlers ...admission.Handler) (*admission.Webhoo
195195
Rule: admissionregistrationv1beta1.Rule{
196196
APIGroups: []string{gvk.Group},
197197
APIVersions: []string{gvk.Version},
198-
Resources: []string{mapping.Resource},
198+
Resources: []string{mapping.Resource.Resource},
199199
},
200200
},
201201
}

0 commit comments

Comments
 (0)