This commit is contained in:
Thomas Anderson 2024-04-28 14:16:32 +03:00
parent f33488c80f
commit a688ae4c7e
No known key found for this signature in database
GPG key ID: 4BFC48FBBFBB935F
2 changed files with 4 additions and 4 deletions

View file

@ -67,9 +67,9 @@ var Flags = []cli.Flag{
Value: cli.NewStringSlice("regcred"),
},
&cli.BoolFlag{
EnvVars: []string{"WOODPECKER_BACKEND_K8S_NATIVE_SECRETS_ALLOW_FROM_STEP"},
Name: "backend-k8s-native-secrets-allow-from-step",
Usage: "whether to allow existing Kubernetes secrets to be referenced from step",
EnvVars: []string{"WOODPECKER_BACKEND_K8S_ALLOW_NATIVE_SECRETS"},
Name: "backend-k8s-allow-native-secrets",
Usage: "whether to allow existing Kubernetes secrets to be referenced from steps",
Value: false,
},
}

View file

@ -93,7 +93,7 @@ func configFromCliContext(ctx context.Context) (*config, error) {
SecurityContext: SecurityContextConfig{
RunAsNonRoot: c.Bool("backend-k8s-secctx-nonroot"),
},
NativeSecretsAllowFromStep: c.Bool("backend-k8s-native-secrets-allow-from-step"),
NativeSecretsAllowFromStep: c.Bool("backend-k8s-allow-native-secrets"),
}
// TODO: remove in next major
if len(config.ImagePullSecretNames) == 1 && config.ImagePullSecretNames[0] == "regcred" {