Documentation
¶
Overview ¶
Package cmd contains common command options and utilities
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CommonOpts ¶
type CommonOpts struct {
Context context.Context
ApplicationVersion string
ApplicationBuildDate string
}
CommonOpts contains common options for all commands
func (*CommonOpts) SetCommonOpts ¶
func (c *CommonOpts) SetCommonOpts(cc CommonOpts)
SetCommonOpts sets the common options
type Server ¶
type Server struct {
Addr string `long:"addr" env:"ADDR" description:"address to listen on" default:":8080"`
Timeout time.Duration `long:"timeout" env:"TIMEOUT" description:"HTTP client timeout" default:"90s"`
BaseURL string `long:"base-url" env:"BASE_URL" description:"base URL for webhook" required:"true"`
Secret string `long:"secret" env:"SECRET" description:"secret for sealing webhook configurations" required:"true"` //nolint:gosec // intentional secret field
Password string `long:"password" env:"PASSWORD" description:"password for basic auth, if not set, basic auth is disabled"` //nolint:gosec // intentional secret field
CommonOpts
}
Server command starts the HTTP server.
Click to show internal directories.
Click to hide internal directories.