Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

connectivitycheckcontroller: use generic controller #380

Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 2 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,12 @@ require (
github.com/ghodss/yaml v1.0.0
github.com/go-bindata/go-bindata v3.1.2+incompatible
github.com/gonum/graph v0.0.0-20170401004347-50b27dea7ebb
github.com/imdario/mergo v0.3.7
github.com/kubernetes-sigs/kube-storage-version-migrator v0.0.0-20191127225502-51849bc15f17
github.com/openshift/api v0.0.0-20200723134351-89de68875e7c
github.com/openshift/build-machinery-go v0.0.0-20200713135615-1f43d26dccc7
github.com/openshift/client-go v0.0.0-20200722173614-5a1b0aaeff15
github.com/openshift/library-go v0.0.0-20200731053141-ff55255233e3
github.com/openshift/library-go v0.0.0-20200807122248-f5cb4d19a4fe
github.com/spf13/cobra v1.0.0
github.com/spf13/pflag v1.0.5
github.com/stretchr/testify v1.4.0
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -385,8 +385,8 @@ github.com/openshift/client-go v0.0.0-20200722173614-5a1b0aaeff15 h1:b2QkHrmaYtY
github.com/openshift/client-go v0.0.0-20200722173614-5a1b0aaeff15/go.mod h1:yd4Zpcdk+8JyMWi6v+h78jPqK0FvXbJY41Wq3SZxl+c=
github.com/openshift/kubernetes-kube-storage-version-migrator v0.0.3-0.20200312103335-32e07ea4f8ca h1:YNtyJnE53QuEUSjl7L1AARocI021o7cU2bvh4prDtiE=
github.com/openshift/kubernetes-kube-storage-version-migrator v0.0.3-0.20200312103335-32e07ea4f8ca/go.mod h1:unEnEWccGeVxaXSRsWTjRsNxMqYXmuQjzjcPFQ91H9M=
github.com/openshift/library-go v0.0.0-20200731053141-ff55255233e3 h1:CVXMm0ycbY+y61Xsb7seCkiXd1Pj/lF4eNqpPocT7Q0=
github.com/openshift/library-go v0.0.0-20200731053141-ff55255233e3/go.mod h1:q7ebJwBFgDx4nP5jGhd+K9XgOIpKaNVh4RWpKmW61Gg=
github.com/openshift/library-go v0.0.0-20200807122248-f5cb4d19a4fe h1:Dt46qJIjHr4a0R1hEIZegKr1j9mT3E0Sfz4Y+uZ+EGc=
github.com/openshift/library-go v0.0.0-20200807122248-f5cb4d19a4fe/go.mod h1:q7ebJwBFgDx4nP5jGhd+K9XgOIpKaNVh4RWpKmW61Gg=
github.com/pborman/uuid v1.2.0 h1:J7Q5mO4ysT1dv8hyrUGHb9+ooztCXu1D8MY8DZYsu3g=
github.com/pborman/uuid v1.2.0/go.mod h1:X/NO0urCmaxf9VXbdlT7C2Yzkj2IKimNn4k+gtPdI/k=
github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
Expand Down
4 changes: 2 additions & 2 deletions pkg/operator/starter.go
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ func RunOperator(ctx context.Context, controllerConfig *controllercmd.Controller
configInformers.Config().V1().Images().Informer(),
).WithStaticResourcesController(
"APIServerStaticResources",
libgoassets.WithAuditPolicies(operatorclient.TargetNamespace, v311_00_assets.Asset),
libgoassets.WithAuditPolicies("audit", operatorclient.TargetNamespace, v311_00_assets.Asset),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good.

[]string{
"v3.11.0/openshift-apiserver/ns.yaml",
"v3.11.0/openshift-apiserver/apiserver-clusterrolebinding.yaml",
Expand Down Expand Up @@ -275,7 +275,7 @@ func RunOperator(ctx context.Context, controllerConfig *controllercmd.Controller
kubeInformersForNamespaces,
controllerConfig.EventRecorder,
)
auditPolicyPahGetter, err := libgoassets.NewAuditPolicyPathGetter()
auditPolicyPahGetter, err := libgoassets.NewAuditPolicyPathGetter("/var/run/configmaps/audit")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this looks good.

if err != nil {
return err
}
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion vendor/modules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ github.com/openshift/client-go/operator/listers/operator/v1alpha1
github.com/openshift/client-go/operatorcontrolplane/clientset/versioned
github.com/openshift/client-go/operatorcontrolplane/clientset/versioned/scheme
github.com/openshift/client-go/operatorcontrolplane/clientset/versioned/typed/operatorcontrolplane/v1alpha1
# github.com/openshift/library-go v0.0.0-20200731053141-ff55255233e3
# github.com/openshift/library-go v0.0.0-20200807122248-f5cb4d19a4fe
github.com/openshift/library-go/pkg/assets
github.com/openshift/library-go/pkg/config/client
github.com/openshift/library-go/pkg/config/clusteroperator/v1helpers
Expand All @@ -245,6 +245,7 @@ github.com/openshift/library-go/pkg/operator/configobserver
github.com/openshift/library-go/pkg/operator/configobserver/apiserver
github.com/openshift/library-go/pkg/operator/configobserver/etcd
github.com/openshift/library-go/pkg/operator/configobserver/proxy
github.com/openshift/library-go/pkg/operator/connectivitycheckcontroller
github.com/openshift/library-go/pkg/operator/encryption
github.com/openshift/library-go/pkg/operator/encryption/controllers
github.com/openshift/library-go/pkg/operator/encryption/controllers/migrators
Expand Down