Documentation ¶
Index ¶
Constants ¶
const ( SecretsConfigName = "config-secrets" BuildImagePushSecretKey = "build.imagePushSecrets" GoogleServiceAccountKey = "wi.googleServiceAccount" GoogleProjectIDKey = "wi.googleProjectID" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
// contains filtered or unexported fields
}
func FromContext ¶
FromContext gets the *Config from the context.
func (*Config) Secrets ¶
func (c *Config) Secrets() (*SecretsConfig, error)
Secrets returns the SecretsConfig and an error if there was an issue loading the config.
type SecretsConfig ¶
type SecretsConfig struct { // BuildImagePushSecrets are the names of the Secrets that should be used // in each space to push images via the build pipeline. BuildImagePushSecrets []corev1.ObjectReference // GoogleProjectID is the GCP project ID used with Workload Identity. If // left empty, the metadata server will be used to fetch it. GoogleProjectID string // GoogleServiceAccount is the GSA that is linked to the KSA in each space // for Workload Identity. If it's empty, then WI is disabled and the Kf // controllers will not make calls to the IAM API. GoogleServiceAccount string }
SecretsConfig contains the configuration defined in the build secrets config map.
func NewSecretsConfigFromConfigMap ¶
func NewSecretsConfigFromConfigMap( configMap *corev1.ConfigMap, ) (*SecretsConfig, error)
NewSecretsConfigFromConfigMap creates a SecretConfig from the supplied ConfigMap
type Store ¶
type Store struct {
*configmap.UntypedStore
}
Store is based on configmap.UntypedStore and is used to store and watch for updates to configuration related to Secrets.
func NewSecretsConfigStore ¶
NewSecretsConfigStore creates a secrets config store populated with default keys and values.
func NewStore ¶
func NewStore( logger configmap.Logger, onAfterStore ...func(name string, value interface{}), ) *Store
NewStore creates a configmap.UntypedStore based config store.
logger must be non-nil implementation of configmap.Logger (commonly used loggers conform)
onAfterStore is a variadic list of callbacks to run after the ConfigMap has been processed and stored.
See also: configmap.NewUntypedStore().