|
|
@ -53,6 +53,7 @@ var (
|
|
|
|
bootstrapBranch string
|
|
|
|
bootstrapBranch string
|
|
|
|
bootstrapWatchAllNamespaces bool
|
|
|
|
bootstrapWatchAllNamespaces bool
|
|
|
|
bootstrapLogLevel string
|
|
|
|
bootstrapLogLevel string
|
|
|
|
|
|
|
|
bootstrapRequiredComponents = []string{"source-controller", "kustomize-controller"}
|
|
|
|
)
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
|
|
const (
|
|
|
|
const (
|
|
|
@ -90,6 +91,12 @@ func bootstrapValidate() error {
|
|
|
|
return fmt.Errorf("log level %s is not supported, can be %v", bootstrapLogLevel, supportedLogLevels)
|
|
|
|
return fmt.Errorf("log level %s is not supported, can be %v", bootstrapLogLevel, supportedLogLevels)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
for _, component := range bootstrapRequiredComponents {
|
|
|
|
|
|
|
|
if !utils.containsItemString(bootstrapComponents, component) {
|
|
|
|
|
|
|
|
return fmt.Errorf("component %s is required", component)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
return nil
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|