-
Notifications
You must be signed in to change notification settings - Fork 264
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature Request: support for Kubernetes CRDs #132
Comments
I'm not sure where "./path/to/application-swagger-latest.json" to points too but the path has to be relative to the root of the folder you have opened For example, if the project hierarchy is:
you should just need to do
and it should pick it up in my_file.yaml. If it doesn't not let me know and I can try and look into it further! |
I tried multiple configurations, no success so far. My environment is vscode with only one folder open. After changing the configuration I reloaded the window. First configuration:
user settings:
I get this error: Second configuration:
user settings:
Error: I get this error: Maybe schema extension does not work for Kubernetes YAMLs? |
So if you're getting that error that means that its at least attempting to associate the schema to the file. Is there anyway you can post the schema and the contents of the text file. Presumably |
the schema is this one:
|
I'd love to see a way to easily exempt certain files from validation. That would be enough for me day-to-day. For example, any file named Is there a way to do that with the current glob support? |
If anyone is still following this, the underlying problem seems to be that the OpenAPIv3 doesn't validate against JSON schema, mainly b/c of circular references. The published K8s Open schemas are converted using openapi2jsonschema. So--
Caveats--
ETA: I am getting back an interesting error:
This doesn't seem to be affecting anything, b/c standard K8s resources are validating/completing, but CRDs do not. So...working as designed, maybe? |
Ok, this is progress of a sort:
So clearly this is an issue with the CRDs. Maybe it's down to the version of kubebuilder or whatever, or specific options therein. |
There's some kind of parse error in here, b/c if I explicitly ask for completion at point, where point is a blank line immediately after the kind, I get a completion offering the fields From the description strings, |
I tried to use
yaml.schemas
to associate kubernetes CRD schemas but this is not working. I added this entry to vscode user settings:I also tried:
with no success.
The text was updated successfully, but these errors were encountered: