Remove unused namespace field

This commit is contained in:
Darren Shepherd 2020-02-04 21:31:02 -07:00
parent b51e14edfb
commit 87a107e23e
3 changed files with 0 additions and 13 deletions

View File

@ -11,7 +11,6 @@ type Config struct {
KubeConfig string KubeConfig string
HTTPSListenPort int HTTPSListenPort int
HTTPListenPort int HTTPListenPort int
Namespace string
WebhookConfig authcli.WebhookConfig WebhookConfig authcli.WebhookConfig
} }
@ -36,7 +35,6 @@ func (c *Config) ToServer() (*server.Server, error) {
} }
return &server.Server{ return &server.Server{
Namespace: c.Namespace,
RestConfig: restConfig, RestConfig: restConfig,
AuthMiddleware: auth, AuthMiddleware: auth,
}, nil }, nil
@ -59,12 +57,6 @@ func Flags(config *Config) []cli.Flag {
Value: 8080, Value: 8080,
Destination: &config.HTTPListenPort, Destination: &config.HTTPListenPort,
}, },
cli.StringFlag{
Name: "namespace",
EnvVar: "NAMESPACE",
Value: "steve",
Destination: &config.Namespace,
},
} }
return append(flags, authcli.Flags(&config.WebhookConfig)...) return append(flags, authcli.Flags(&config.WebhookConfig)...)

View File

@ -29,7 +29,6 @@ type Server struct {
RestConfig *rest.Config RestConfig *rest.Config
Namespace string
BaseSchemas *types.APISchemas BaseSchemas *types.APISchemas
AccessSetLookup accesscontrol.AccessSetLookup AccessSetLookup accesscontrol.AccessSetLookup
SchemaTemplates []schema.Template SchemaTemplates []schema.Template

View File

@ -23,10 +23,6 @@ func setDefaults(server *Server) error {
return ErrConfigRequired return ErrConfigRequired
} }
if server.Namespace == "" {
server.Namespace = "steve"
}
if server.Controllers == nil { if server.Controllers == nil {
var err error var err error
server.Controllers, err = NewController(server.RestConfig) server.Controllers, err = NewController(server.RestConfig)