Closed patriziobrunops closed 2 years ago
Hi @patriziobrunops - thank you for informing us.
This issue should be fixed with #500
Hi @patriziobrunops - thank you for informing us.
This issue should be fixed with #500
Hi @buraksekili - #500 fixes the manifest validation error, but if you set use_go_plugin_auth
to false
you'll get a failure from the Dashboard API, because of omitempty
.
@patriziobrunops I tried to reproduce the following error:
The ApiDefinition "remote-payments-receipts-config" is invalid: spec.use_go_plugin_auth: Required value
Correct me if I am wrong but this error does not belong to Dashboard API but belongs to validation webhooks. This error happens because the required
field spec.use_go_plugin_auth
has omitempty
tag. Even though CRD expects this field to present, if it is set as false
, which is the nil
value for boolean, your YAML file won't be validated because of omitempty
tag.
So, as in #500, if CRD does not require users to provide the use_go_plugin_auth
field, you can either set use_go_plugin_auth
to false
or not set it at all.
If you have access to the repository, you can try this approach.
use_go_plugin_auth
from helm crds https://github.com/TykTechnologies/tyk-operator/blob/master/helm/crds/crds.yaml#L1697 kubectl apply -f ./helm/crds
This command will update Tyk CRDs and since use_go_plugin_auth
is deleted from the required field, you are not required to provide it, or setting it to false
won't cause any problems.
Please let me know if I wasn't clear or if you have further questions.
Ever since I upgraded to latest
tyk-operator
I've been unable to create/udpate api definitions that don't haveuse_go_plugin_auth
or when it is set tofalse
.Expected Behavior
When
use_go_plugin_auth
is not set, should default tofalse
Current Behavior
When
use_go_plugin_auth
is not set:When
use_go_plugin_auth
is set tofalse
Possible Solution
Remove
omitempty
fromUseGoPluginAuth
. Removeuse_go_plugin_auth
from requiredApiDefinition.spec
properties incrds.yaml
.Steps to Reproduce
1. 2. 3.
Screenshots/Video
Logs/Errors
Context
Your Environment
tyk-operator
version/commit: