Skip to content

Commit 90642ce

Browse files
authored
Fix e2e tests after webhook merger (#333)
1 parent 2fc3239 commit 90642ce

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

server/options.go

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package server
22

33
import (
4+
"flag"
45
"fmt"
56
"time"
67

@@ -40,7 +41,7 @@ func NewControllerOptions() *ControllerOptions {
4041
}
4142
}
4243

43-
func (s *ControllerOptions) AddFlags(fs *pflag.FlagSet) {
44+
func (s *ControllerOptions) AddGoFlags(fs *flag.FlagSet) {
4445
fs.StringVar(&s.OpsAddress, "ops-address", s.OpsAddress, "Address to listen on for web interface and telemetry.")
4546
fs.BoolVar(&s.EnableRBAC, "rbac", s.EnableRBAC, "Enable RBAC for operator")
4647
fs.StringVar(&s.ScratchDir, "scratch-dir", s.ScratchDir, "Directory used to store temporary files. Use an `emptyDir` in Kubernetes.")
@@ -49,6 +50,12 @@ func (s *ControllerOptions) AddFlags(fs *pflag.FlagSet) {
4950
fs.DurationVar(&s.ResyncPeriod, "resync-period", s.ResyncPeriod, "If non-zero, will re-list this often. Otherwise, re-list will be delayed aslong as possible (until the upstream source closes the watch or times out.")
5051
}
5152

53+
func (s *ControllerOptions) AddFlags(fs *pflag.FlagSet) {
54+
pfs := flag.NewFlagSet("stash", flag.ExitOnError)
55+
s.AddGoFlags(pfs)
56+
fs.AddGoFlagSet(pfs)
57+
}
58+
5259
func (s *ControllerOptions) ApplyTo(cfg *controller.ControllerConfig) error {
5360
var err error
5461

0 commit comments

Comments
 (0)