Lars Kellogg-Stedman
d5e1940fc2
docs: Add documentation for namespace transformer
...
Add a short description of the namespace transformer and example
usage to examples/transformerconfigs/README.md.
References: #629
Signed-off-by: Lars Kellogg-Stedman <lars@oddbit.com >
2022-12-09 14:05:16 -05:00
Anna Song
71eb865cea
Localize configMapGenerator, secretGenerator fields ( #4894 )
...
* Localize configMapGenerator, secretGenerator fields
* Improve readability
* Expose kv parseFileSource
* Add localizeGenerator to Localizer
* Improve and test ParseFileSource error messages
2022-12-02 15:31:53 -08:00
Yannis Zarkadas
a502717460
Make ordering configurable ( #4019 )
...
* api: Add new types for customizeable resource ordering
Signed-off-by: Yannis Zarkadas <yanniszark@arrikto.com >
* plugins: Implement SortOrderTransformer plugin
Implement the SortOrderTransformer plugin. This plugin allows the user
to customize the order that kustomize will output resources in.
The API for the plugin is the following:
sortOptions:
order: legacy | fifo
legacySortOptions:
orderFirst:
- {GVK}
orderLast:
- {GVK}
Signed-off-by: Yannis Zarkadas <yanniszark@arrikto.com >
* plugins: Add boilerplate and generate code for new SortOrderTransformer
Signed-off-by: Yannis Zarkadas <yanniszark@arrikto.com >
* build: Add option to denote if the reorder flag was set by the user
We want to take different actions if the reorder flag was set by the
user or filled by the default value. Thus, we propagate this information
from build to the krusty options.
Signed-off-by: Yannis Zarkadas <yanniszark@gmail.com >
* api/krusty: Ensure sort ordering works with CLI flag and kustomization
Sort order can be defined in two places:
- (new) kustomization file
- (old) CLI flag
We want the kustomization file to take precedence over the CLI flag.
Eventually, we may want to move away from having a CLI flag altogether:
https://github.com/kubernetes-sigs/kustomize/issues/3947
Case 1: Sort order set in kustomization file AND in CLI flag.
Print a warning and let the kustomization file take precedence.
Case 2: Sort order set in CLI flag only or not at all.
Follow the CLI flag (defaults to legacy) and reorder at the end.
Case 3: Sort order set in kustomization file only.
Simply build the kustomization.
Signed-off-by: Yannis Zarkadas <yanniszark@gmail.com >
* krusty: Add e2e test for SortOrderTransformer
Signed-off-by: Yannis Zarkadas <yanniszark@arrikto.com >
* plugins: Purge LegacyOrderTransformer
Signed-off-by: Yannis Zarkadas <yanniszark@gmail.com >
* Update go.work.sum
Signed-off-by: Yannis Zarkadas <yanniszark@gmail.com >
* review: Make review changes
Signed-off-by: Yannis Zarkadas <yanniszark@gmail.com >
Signed-off-by: Yannis Zarkadas <yanniszark@arrikto.com >
Signed-off-by: Yannis Zarkadas <yanniszark@gmail.com >
2022-12-02 13:59:53 -08:00
Kishore Jagannath
1e2e7bbc0b
Refactor 7 return values in parseGitUrl to RepoSpec(issue 4866, Task1) ( #4900 )
...
* initial commit to refactor 7 return values in parseGitUrl to RepoSpec
* fix review comments
2022-12-02 10:01:53 -08:00
Anna Song
e34d5b5608
Localize components ( #4867 )
2022-12-02 09:33:53 -08:00
Kubernetes Prow Robot
0f4f978956
Merge pull request #4895 from KnVerey/remove-local-last
...
Remove local-only resources at the last minute
2022-12-01 13:20:00 -08:00
Kubernetes Prow Robot
663b777910
Merge pull request #4892 from KnVerey/issue_forms
...
Use Github forms for issue templates
2022-12-01 13:19:53 -08:00
Kubernetes Prow Robot
3c8db55f53
Merge pull request #4901 from annasong20/clean-localizer
...
Clean `localizer`
2022-12-01 11:21:54 -08:00
Anna Song
b8611cf0a9
Refactor localizer code
...
* encapsulate kusttarget params
* change dst to string
* ConfirmDir
2022-12-01 09:53:46 -08:00
Kubernetes Prow Robot
588da7e392
Merge pull request #4852 from pacoxu/psp-cleanup
...
remove PSP as v1.25 remove it
2022-11-30 08:44:55 -08:00
Kubernetes Prow Robot
baf777c56e
Merge pull request #4893 from KnVerey/pluginator-linter-bug
...
Fix pluginator incompatibility with nolint lines
2022-11-30 08:32:55 -08:00
Katrina Verey
a612cd2b7e
Fix pluginator incompatibility with nolint lines
2022-11-30 11:22:10 -05:00
Paco Xu
37ad9b1d4e
remove PSP as v1.25 remove it
2022-11-30 10:16:39 +08:00
Katrina Verey
fb0f567b63
Remove local-only resources at the last minute
...
This allows name references to them to be correctly resolved
2022-11-29 19:05:16 -05:00
Kubernetes Prow Robot
f53d018302
Merge pull request #4885 from annasong20/contain-ldr-path
...
Contain `RepoSpec` path in repo
2022-11-29 14:35:08 -08:00
Kubernetes Prow Robot
d9d9785791
Merge pull request #4890 from brianpursley/kustomize-4628
...
merge2: preserve explicitly set null values
2022-11-29 12:35:08 -08:00
Katrina Verey
76fab6e7ba
Use Github forms for issue templates
2022-11-28 18:17:55 -05:00
Anna Song
832b552076
Load built-in plugins for kustomize localize ( #4869 )
...
* Load and filter built-in plugins
* Improve readability
* Process plugins as resources instead of bytes
* Throw error for validators
* Differentiate generators, transformers processing
* Enable validators
* add wrapper error
* improve documentation
2022-11-28 13:23:42 -08:00
Anna Song
0eff094faf
Calculate localized path for remote file ( #4878 )
...
* Calculate localized path for remote file
* Add documentation
2022-11-28 09:36:06 -08:00
Brian Pursley
1b7db20504
merge2: preserve explicitly set null values
...
Fixed bug where an explicitly set null value in yaml was
cleared, even when the patch did not operate on that field.
2022-11-26 16:33:14 -05:00
Claus F. Strasburger
adce67301b
install_kustomize: support linux/aarch64, with fallback to old behavior ( #4619 )
...
* install_kustomize: support linux/aarch64, with fallback to old behavior
* shellcheck
* Comments from first review
* Comments from review
* Review comments: message consistency
2022-11-24 10:20:04 -08:00
Kubernetes Prow Robot
a6eb8e8ce8
Merge pull request #4887 from KnVerey/statik_removal
...
Get rid of statik and fix failing tests
2022-11-23 19:00:04 -08:00
Katrina Verey
7f9f6140ff
Get rid of statik and fix failing tests
2022-11-23 20:34:38 -05:00
Anna Song
07063a2652
Prevent repoSpec path from exiting repo
2022-11-23 14:29:22 -08:00
Kubernetes Prow Robot
e5ab220821
Merge pull request #4868 from emirot/chore_upgrade_helm
...
chore: upgrade helm version
2022-11-21 18:26:13 -08:00
Kubernetes Prow Robot
78978723db
Merge pull request #4840 from oscr/update-golangci-lint
...
Update golangci-lint version (1.49.0 -> 1.50.1) and enable linters: dupword and testableexamples
2022-11-17 10:36:29 -08:00
Kubernetes Prow Robot
8ea5eb22f1
Merge pull request #4877 from KnVerey/go_1.19
...
Update to Go 1.19
2022-11-17 10:18:40 -08:00
Katrina Verey
91a2c2b1a4
Update to Go 1.19
2022-11-17 12:57:17 -05:00
Natasha Sarkar
62f0dab2ac
Merge pull request #4876 from KnVerey/new_token
...
Regenerate token and encrypt without newline (attempt 4)
kyaml/v0.13.10
2022-11-16 13:46:19 -06:00
Katrina Verey
d642b959cf
Regenerate token and encrypt without newline
2022-11-16 14:36:33 -05:00
Natasha Sarkar
d49f6e17ad
Merge pull request #4875 from KnVerey/new_token
...
Third try new token without newline
2022-11-16 13:25:32 -06:00
Katrina Verey
0de4e0ba11
Third try new token without newline
2022-11-16 14:24:20 -05:00
Natasha Sarkar
54569e4591
Merge pull request #4874 from KnVerey/token_again
...
New token, hopefully without trailing whitespace error
2022-11-16 13:12:49 -06:00
Katrina Verey
b2dc88447e
New token, hopefully without trailing whitespace error
2022-11-16 14:11:40 -05:00
Anna Song
314b8fbefa
Implement localizeFile() skeleton for patches ( #4865 )
...
* Implement localizeFile()
* Fix lint
* Address code review feedback
* Remove unnecessary String(), Error() with string formatters
* Remove processing of un-implemented methods
* Improve readability
* Remove unimplemented addLocalizeDir, hitsLocalizeDir
* Improve documentation
* Remove deprecated patchesJson6902 logic
2022-11-16 10:24:48 -08:00
Natasha Sarkar
c0840b6804
Merge pull request #4873 from KnVerey/new_token
...
Rotate token for cloud build
2022-11-16 10:58:14 -06:00
Katrina Verey
1eccbc4e30
Rotate token for cloud build
2022-11-16 11:54:33 -05:00
Anna Song
f79e16b352
Improve localizer readability ( #4860 )
...
* Replace '%s' with %q
* Change ambiguous cli-"Arg" suffix in func arg names
* Remove repetitive "loc" in names
* Apply readability changes to localizer
* Fix comment
2022-11-16 08:42:49 -08:00
Kubernetes Prow Robot
b20e611413
Merge pull request #4723 from koba1t/emit_a_warning_when_deprecated_fields_are_used
...
Emit a warning on build when deprecated fields are used
2022-11-16 08:32:50 -08:00
Kubernetes Prow Robot
e638e408b0
Merge pull request #4802 from oscr/the-the
...
grammar: replace all occurrences of "the the" with "the"
2022-11-16 08:22:48 -08:00
emirot
473c0a5f19
chore: upgrade helm version
2022-11-14 17:14:07 -08:00
Anna Song
84bd402cc0
Fix RepoSpec query extraction ( #4863 )
...
* Clean query processing
* Improve readability
* Remove redundant code
* Add comment
* Return path literal when not parsable
* Handle url.Parse() error in future
2022-11-14 09:38:41 -08:00
Kubernetes Prow Robot
e724e25fec
Merge pull request #4855 from koba1t/chore/add_koba1t_to_reviews
...
add koba1t to reviews
2022-11-10 14:22:09 -08:00
Anna Song
50e731a1d9
Implement localizer skeleton for kustomize localize ( #4859 )
...
* Add localizer outline
* Add localizer unit tests
* include previous change
* Add proper NewLocalizer, Localize unit tests
mock processKust
* Address code review feedback
* Make processKustFn public
* Remove mock testing
2022-11-10 09:24:54 -08:00
Anna Song
beb2825f82
Improve readability of ifc.Loader's Repo() method ( #4857 )
...
* Improve ldr Repo() method readability
* Change Repo() implementations and calls
* Improve readability of conditions in ldr.New()
* Fix details
2022-11-08 14:48:14 -08:00
Anna Song
6d9b54004e
Address TODO in PR #4652 ( #4856 )
...
* Address TODO in PR #4652
* Improve readability
2022-11-08 13:51:01 -08:00
yugo kobayashi
1f04fd2f23
add koba1t to reviews
2022-11-07 18:40:54 +00:00
Kubernetes Prow Robot
6ffd22a1f1
Merge pull request #4854 from koba1t/fix/failed_lint_on_master
...
fix: failed lint on master
2022-11-07 10:16:18 -08:00
yugo kobayashi
3e6ede9645
fix_failed_lint_on_master
2022-11-04 07:12:46 +00:00
Kubernetes Prow Robot
14f3cea24f
Merge pull request #4830 from summer-dev/update-swagto-v0.22.3
...
update kyaml's dependency swag to v0.22.3
2022-11-03 21:06:14 -07:00