Commit Graph

13 Commits

Author SHA1 Message Date
Phillip Wittrock
5d1a0346b5 Use OpenAPI when merging (3way) resources
- When merging (3way) resources use the patch strategy from the openAPI if the definition exists for the field
- Allow disabling of guessing patch strategy merge keys when no definition exists
- Support defining strategy and key directly on configuration fields through line and header coments
- Support attaching schema to parent fields of lists, and propagating -- e.g. that a field is a PodTemplate
2020-03-02 20:56:53 -08:00
Phillip Wittrock
154939803f better support for reading / writing single resource yaml files 2020-02-19 08:16:07 -08:00
Kubernetes Prow Robot
6d58848970 Merge pull request #2035 from pwittrock/openapi
Introduce OpenAPI kyaml libraries
2020-01-09 09:35:45 -08:00
Phillip Wittrock
abeab51cae Library for getting Resource and field Schema from OpenAPI 2020-01-08 10:47:11 -08:00
Phillip Wittrock
4628705494 Parse metadata directly instead of struct serialization hack 2020-01-07 16:24:52 -08:00
Phillip Wittrock
98431f6a00 fix kyaml issue where dropping Style created issues
dropping the node style creates a compatibility issue where quotes around "on" are dropped
because yaml.v3 interprets it as a string.

other yaml parsers interpret on as a bool value, and parse it as a bool rather than string.

fix: retain the original style so it is kept as quoted.

- fmt: don't drop the styles
- merge2: keep the style when merging elements
- setting a field: if changing the value of a scalar field, retain its style by default
2019-12-19 20:25:31 -08:00
Morten Torkildsen
1b3b8522f9 cli for status 2019-12-11 13:13:09 -08:00
Arthur Mello
e811da14d8 Rename variable, constants and struct fields following stylecheck linter recommendation 2019-12-05 22:39:29 -03:00
Igor Zibarev
301e529a4a kyaml: fix scopelint issues 2019-11-12 23:42:02 +03:00
Phillip Wittrock
b473faccca Improve error handling in kyaml libraries 2019-11-12 08:53:55 -08:00
Phillip Wittrock
3db1111f8e kyaml: rename annotations and fix linting 2019-11-07 15:46:30 -08:00
Phillip Wittrock
2e33a69388 Update documentation for kyaml package 2019-11-07 09:16:27 -08:00
Phillip Wittrock
efd7c8e3f7 kyaml: initial support for yaml and resource manipulation 2019-11-04 11:36:35 -08:00