From 81d3cb3b2750ddd3da1b1f327e788d842e0ddb8c Mon Sep 17 00:00:00 2001 From: Vladislav Sukhin Date: Fri, 2 Aug 2024 15:59:07 +0300 Subject: [PATCH] feat: test workflow sensitive config parameter Signed-off-by: Vladislav Sukhin --- api/testworkflows/v1/parameter_types.go | 2 ++ config/crd/bases/testworkflows.testkube.io_testworkflows.yaml | 3 +++ .../bases/testworkflows.testkube.io_testworkflowtemplates.yaml | 3 +++ 3 files changed, 8 insertions(+) diff --git a/api/testworkflows/v1/parameter_types.go b/api/testworkflows/v1/parameter_types.go index a20290a8..d9039cd9 100644 --- a/api/testworkflows/v1/parameter_types.go +++ b/api/testworkflows/v1/parameter_types.go @@ -51,6 +51,8 @@ type ParameterSchema struct { // default value - if not provided, the parameter is required // +kubebuilder:validation:XIntOrString Default *intstr.IntOrString `json:"default,omitempty" expr:"template"` + // whether this value should be stored in the secret + Sensitive bool `json:"sensitive,omitempty"` ParameterStringSchema `json:",inline" expr:"include"` ParameterNumberSchema `json:",inline" expr:"include"` diff --git a/config/crd/bases/testworkflows.testkube.io_testworkflows.yaml b/config/crd/bases/testworkflows.testkube.io_testworkflows.yaml index ccdc1943..4a311d18 100644 --- a/config/crd/bases/testworkflows.testkube.io_testworkflows.yaml +++ b/config/crd/bases/testworkflows.testkube.io_testworkflows.yaml @@ -3021,6 +3021,9 @@ spec: pattern: description: regular expression to match type: string + sensitive: + description: whether this value should be stored in the secret + type: boolean type: default: string description: type of the parameter diff --git a/config/crd/bases/testworkflows.testkube.io_testworkflowtemplates.yaml b/config/crd/bases/testworkflows.testkube.io_testworkflowtemplates.yaml index 1c4aa58e..24ca6b97 100644 --- a/config/crd/bases/testworkflows.testkube.io_testworkflowtemplates.yaml +++ b/config/crd/bases/testworkflows.testkube.io_testworkflowtemplates.yaml @@ -2947,6 +2947,9 @@ spec: pattern: description: regular expression to match type: string + sensitive: + description: whether this value should be stored in the secret + type: boolean type: default: string description: type of the parameter