├── .dockerignore ├── .github ├── ISSUE_TEMPLATE │ ├── bug_report.yaml │ ├── config.yml │ └── feature_request.yaml ├── dependabot.yml └── workflows │ ├── apidiff.yml │ ├── go.yml │ └── release.yaml ├── .gitignore ├── .gitmodules ├── .golangci.yml ├── ARCHITECTURE.md ├── CONTRIBUTING.md ├── LICENSE ├── LICENSE_TEMPLATE ├── Makefile ├── Makefile-modules.mk ├── Makefile-plugins.mk ├── Makefile-tools.mk ├── OWNERS ├── OWNERS_ALIASES ├── README.md ├── ROADMAP.md ├── SECURITY_CONTACTS ├── api ├── Makefile ├── builtins │ └── builtins.go ├── filesys │ └── filesys.go ├── filters │ ├── annotations │ │ ├── annotations.go │ │ ├── annotations_test.go │ │ ├── doc.go │ │ └── example_test.go │ ├── doc.go │ ├── fieldspec │ │ ├── doc.go │ │ ├── example_test.go │ │ ├── fieldspec.go │ │ └── fieldspec_test.go │ ├── filtersutil │ │ ├── setters.go │ │ └── setters_test.go │ ├── fsslice │ │ ├── doc.go │ │ ├── example_test.go │ │ ├── fsslice.go │ │ └── fsslice_test.go │ ├── iampolicygenerator │ │ ├── doc.go │ │ ├── example_test.go │ │ ├── iampolicygenerator.go │ │ └── iampolicygenerator_test.go │ ├── imagetag │ │ ├── doc.go │ │ ├── example_test.go │ │ ├── imagetag.go │ │ ├── imagetag_test.go │ │ ├── legacy.go │ │ ├── legacy_test.go │ │ └── updater.go │ ├── labels │ │ ├── doc.go │ │ ├── example_test.go │ │ ├── labels.go │ │ └── labels_test.go │ ├── nameref │ │ ├── doc.go │ │ ├── nameref.go │ │ ├── nameref_test.go │ │ ├── seqfilter.go │ │ └── seqfilter_test.go │ ├── namespace │ │ ├── doc.go │ │ ├── example_test.go │ │ ├── namespace.go │ │ └── namespace_test.go │ ├── patchjson6902 │ │ ├── doc.go │ │ ├── example_test.go │ │ ├── patchjson6902.go │ │ └── patchjson6902_test.go │ ├── patchstrategicmerge │ │ ├── doc.go │ │ ├── example_test.go │ │ ├── patchstrategicmerge.go │ │ └── patchstrategicmerge_test.go │ ├── prefix │ │ ├── doc.go │ │ ├── example_test.go │ │ ├── prefix.go │ │ └── prefix_test.go │ ├── refvar │ │ ├── doc.go │ │ ├── expand.go │ │ ├── expand_test.go │ │ ├── refvar.go │ │ └── refvar_test.go │ ├── replacement │ │ ├── doc.go │ │ ├── example_test.go │ │ ├── replacement.go │ │ └── replacement_test.go │ ├── replicacount │ │ ├── doc.go │ │ ├── example_test.go │ │ ├── replicacount.go │ │ └── replicacount_test.go │ ├── suffix │ │ ├── doc.go │ │ ├── example_test.go │ │ ├── suffix.go │ │ └── suffix_test.go │ └── valueadd │ │ ├── valueadd.go │ │ └── valueadd_test.go ├── go.mod ├── go.sum ├── hasher │ ├── hasher.go │ └── hasher_test.go ├── ifc │ └── ifc.go ├── internal │ ├── accumulator │ │ ├── loadconfigfromcrds.go │ │ ├── loadconfigfromcrds_test.go │ │ ├── namereferencetransformer.go │ │ ├── namereferencetransformer_test.go │ │ ├── refvartransformer.go │ │ ├── refvartransformer_test.go │ │ ├── resaccumulator.go │ │ └── resaccumulator_test.go │ ├── builtins │ │ ├── AnnotationsTransformer.go │ │ ├── ConfigMapGenerator.go │ │ ├── HashTransformer.go │ │ ├── HelmChartInflationGenerator.go │ │ ├── IAMPolicyGenerator.go │ │ ├── ImageTagTransformer.go │ │ ├── LabelTransformer.go │ │ ├── NamespaceTransformer.go │ │ ├── PatchJson6902Transformer.go │ │ ├── PatchStrategicMergeTransformer.go │ │ ├── PatchTransformer.go │ │ ├── PrefixTransformer.go │ │ ├── ReplacementTransformer.go │ │ ├── ReplicaCountTransformer.go │ │ ├── SecretGenerator.go │ │ ├── SortOrderTransformer.go │ │ ├── SuffixTransformer.go │ │ ├── ValueAddTransformer.go │ │ └── doc.go │ ├── generators │ │ ├── configmap.go │ │ ├── configmap_test.go │ │ ├── secret.go │ │ ├── secret_test.go │ │ ├── utils.go │ │ └── utils_test.go │ ├── git │ │ ├── cloner.go │ │ ├── gitrunner.go │ │ ├── repospec.go │ │ └── repospec_test.go │ ├── image │ │ ├── image.go │ │ └── image_test.go │ ├── konfig │ │ └── builtinpluginconsts │ │ │ ├── commonannotations.go │ │ │ ├── commonlabels.go │ │ │ ├── defaultconfig.go │ │ │ ├── doc.go │ │ │ ├── images.go │ │ │ ├── metadatalabels.go │ │ │ ├── nameprefix.go │ │ │ ├── namereference.go │ │ │ ├── namespace.go │ │ │ ├── namesuffix.go │ │ │ ├── replicas.go │ │ │ ├── templatelabels.go │ │ │ └── varreference.go │ ├── kusterr │ │ ├── yamlformaterror.go │ │ └── yamlformaterror_test.go │ ├── loader │ │ ├── errors.go │ │ ├── fileloader.go │ │ ├── fileloader_test.go │ │ ├── loader.go │ │ ├── loadrestrictions.go │ │ └── loadrestrictions_test.go │ ├── localizer │ │ ├── builtinplugins.go │ │ ├── doc.go │ │ ├── errors.go │ │ ├── localizer.go │ │ ├── localizer_test.go │ │ ├── locloader.go │ │ ├── locloader_test.go │ │ ├── util.go │ │ └── util_test.go │ ├── plugins │ │ ├── builtinconfig │ │ │ ├── doc.go │ │ │ ├── loaddefaultconfig.go │ │ │ ├── loaddefaultconfig_test.go │ │ │ ├── namebackreferences.go │ │ │ ├── namebackreferences_test.go │ │ │ ├── transformerconfig.go │ │ │ └── transformerconfig_test.go │ │ ├── builtinhelpers │ │ │ ├── builtinplugintype_string.go │ │ │ └── builtins.go │ │ ├── compiler │ │ │ ├── compiler.go │ │ │ └── compiler_test.go │ │ ├── doc.go │ │ ├── execplugin │ │ │ ├── execplugin.go │ │ │ └── execplugin_test.go │ │ ├── fnplugin │ │ │ └── fnplugin.go │ │ ├── loader │ │ │ ├── load_go_plugin.go │ │ │ ├── load_go_plugin_disabled.go │ │ │ ├── loader.go │ │ │ └── loader_test.go │ │ └── utils │ │ │ ├── utils.go │ │ │ └── utils_test.go │ ├── target │ │ ├── errmissingkustomization.go │ │ ├── kusttarget.go │ │ ├── kusttarget_configplugin.go │ │ ├── kusttarget_test.go │ │ ├── maker_test.go │ │ ├── multitransformer.go │ │ └── vars_test.go │ ├── utils │ │ ├── annotations.go │ │ ├── errtimeout.go │ │ ├── makeResIds.go │ │ ├── stringslice.go │ │ ├── stringslice_test.go │ │ ├── timedcall.go │ │ └── timedcall_test.go │ └── validate │ │ ├── fieldvalidator.go │ │ └── fieldvalidator_test.go ├── konfig │ ├── doc.go │ ├── general.go │ ├── plugins.go │ └── plugins_test.go ├── krusty │ ├── accumulation_test.go │ ├── baseandoverlaymedium_test.go │ ├── baseandoverlaysmall_test.go │ ├── basereusenameprefix_test.go │ ├── basic_io_test.go │ ├── blankvalues_test.go │ ├── chartinflatorplugin_test.go │ ├── complexcomposition_test.go │ ├── component_test.go │ ├── configmaps_test.go │ ├── crd_test.go │ ├── customconfig_test.go │ ├── customconfigofbuiltinplugin_test.go │ ├── customconfigreusable_test.go │ ├── diamondcomposition_test.go │ ├── diamondpatchref_test.go │ ├── diamonds_test.go │ ├── directoryarrangement_test.go │ ├── disablenamesuffix_test.go │ ├── doc.go │ ├── duplicatekeys_test.go │ ├── extendedpatch_test.go │ ├── fnplugin_test.go │ ├── generatormergeandreplace_test.go │ ├── generatoroptions_test.go │ ├── gvknpatch_test.go │ ├── helmchartinflationgenerator_test.go │ ├── iampolicygenerator_test.go │ ├── inlinelabels_test.go │ ├── inlinepatch_test.go │ ├── inlinetransformer_test.go │ ├── intermediateresourceid_test.go │ ├── issue2896_test.go │ ├── issue3377_test.go │ ├── keepemptyarray_test.go │ ├── kustomizationmetadata_test.go │ ├── kustomizer.go │ ├── kustomizer_test.go │ ├── legacy_order_test.go │ ├── legacyprefixsuffixtransformer_test.go │ ├── localconfig_test.go │ ├── localizer │ │ ├── runner.go │ │ └── runner_test.go │ ├── managedbylabel_test.go │ ├── mergeenvfrom_test.go │ ├── multibytecharacter_test.go │ ├── multiplepatch_test.go │ ├── namedspacedserviceaccounts_test.go │ ├── nameprefixsuffixpatch_test.go │ ├── namereference_test.go │ ├── namespacedgenerators_test.go │ ├── namespaces_test.go │ ├── nameupdateinroleref_test.go │ ├── no_list_items_test.go │ ├── nullvalues_test.go │ ├── numericcommonlabels_test.go │ ├── openapicustomschema_test.go │ ├── options.go │ ├── originannotation_test.go │ ├── patchdelete_test.go │ ├── pluginenv_test.go │ ├── poddisruptionbudget_test.go │ ├── remoteloader_test.go │ ├── repeatbase_test.go │ ├── replacementtransformer_test.go │ ├── resourceconflict_test.go │ ├── rolebindingacrossnamespace_test.go │ ├── simple_test.go │ ├── sortordertransformer_test.go │ ├── stringquoteblank_test.go │ ├── testdata │ │ ├── customschema.json │ │ ├── customschema.yaml │ │ ├── helmcharts │ │ │ ├── test-chart │ │ │ │ ├── Chart.yaml │ │ │ │ ├── README.md │ │ │ │ ├── templates │ │ │ │ │ ├── _helpers.tpl │ │ │ │ │ ├── deployment.yaml │ │ │ │ │ └── tests │ │ │ │ │ │ └── test-pod.yaml │ │ │ │ └── values.yaml │ │ │ └── valuesFiles │ │ │ │ ├── file1.yaml │ │ │ │ └── file2.yaml │ │ ├── localize │ │ │ ├── remote │ │ │ │ ├── hpa.yaml │ │ │ │ └── kustomization.yaml │ │ │ └── simple │ │ │ │ ├── deployment.yaml │ │ │ │ ├── kustomization.yaml │ │ │ │ └── service.yaml │ │ ├── openshiftschema.json │ │ ├── remoteload │ │ │ ├── multibase │ │ │ │ ├── base │ │ │ │ │ ├── kustomization.yaml │ │ │ │ │ └── pod.yaml │ │ │ │ └── dev │ │ │ │ │ └── kustomization.yaml │ │ │ ├── simple │ │ │ │ ├── kustomization.yaml │ │ │ │ └── pod.yaml │ │ │ └── with-submodule │ │ │ │ └── README.md │ │ └── repo_read_only_ssh_key.yaml │ ├── transformerannotation_test.go │ ├── transformerplugin_test.go │ ├── transformersarrays_test.go │ ├── transformersimage_test.go │ ├── validatingwebhook_test.go │ └── variableref_test.go ├── kv │ ├── kv.go │ └── kv_test.go ├── main.go ├── pkg │ ├── loader │ │ └── loader.go │ └── util │ │ └── image.go ├── provenance │ ├── provenance.go │ └── provenance_test.go ├── provider │ └── depprovider.go ├── resmap │ ├── factory.go │ ├── factory_test.go │ ├── resmap.go │ ├── resmap_test.go │ ├── reswrangler.go │ ├── reswrangler_test.go │ └── selector_test.go ├── resource │ ├── doc.go │ ├── factory.go │ ├── factory_test.go │ ├── idset.go │ ├── idset_test.go │ ├── origin.go │ ├── origin_test.go │ ├── resource.go │ └── resource_test.go ├── testutils │ ├── filtertest │ │ └── runfilter.go │ ├── kusttest │ │ ├── harness.go │ │ ├── harnessenhanced.go │ │ ├── hasgett.go │ │ ├── ondisk.go │ │ └── plugintestenv.go │ ├── localizertest │ │ └── filesystem.go │ ├── resmaptest │ │ └── rmbuilder.go │ └── valtest │ │ └── fakevalidator.go └── types │ ├── builtinpluginloadingoptions_string.go │ ├── configmapargs.go │ ├── doc.go │ ├── erronlybuiltinpluginsallowed.go │ ├── errunabletofind.go │ ├── fieldspec.go │ ├── fieldspec_test.go │ ├── generationbehavior.go │ ├── generatorargs.go │ ├── generatoroptions.go │ ├── generatoroptions_test.go │ ├── helmchartargs.go │ ├── helmchartargs_test.go │ ├── iampolicygenerator.go │ ├── image.go │ ├── kustomization.go │ ├── kustomization_test.go │ ├── kvpairsources.go │ ├── labels.go │ ├── loadrestrictions.go │ ├── loadrestrictions_string.go │ ├── objectmeta.go │ ├── pair.go │ ├── patch.go │ ├── patch_test.go │ ├── patchstrategicmerge.go │ ├── pluginconfig.go │ ├── pluginrestrictions.go │ ├── pluginrestrictions_string.go │ ├── replacement.go │ ├── replacementfield.go │ ├── replica.go │ ├── secretargs.go │ ├── selector.go │ ├── selector_test.go │ ├── sortoptions.go │ ├── typemeta.go │ ├── var.go │ └── var_test.go ├── archive └── roadmap-2021.md ├── cmd ├── config │ ├── Makefile │ ├── README.md │ ├── completion │ │ └── completion.go │ ├── configcobra │ │ ├── cfg.go │ │ ├── cmds.go │ │ ├── example_test.go │ │ └── fn.go │ ├── doc.go │ ├── docs │ │ ├── api-conventions │ │ │ ├── functions-impl.md │ │ │ ├── functions-spec.md │ │ │ ├── manifest-annotations.md │ │ │ ├── merge2.md │ │ │ └── merge3.md │ │ ├── commands │ │ │ ├── annotate.md │ │ │ ├── cat.md │ │ │ ├── completion.md │ │ │ ├── count.md │ │ │ ├── create-setter.md │ │ │ ├── delete-setter.md │ │ │ ├── fmt.md │ │ │ ├── grep.md │ │ │ ├── init.md │ │ │ ├── list-setters.md │ │ │ ├── merge.md │ │ │ ├── merge3.md │ │ │ ├── run-fns.md │ │ │ ├── set.md │ │ │ ├── sink.md │ │ │ ├── source.md │ │ │ └── tree.md │ │ └── tutorials │ │ │ ├── configuration-basics.md │ │ │ └── function-basics.md │ ├── ext │ │ └── ext.go │ ├── fixgomod.sh │ ├── go.mod │ ├── go.sum │ ├── internal │ │ ├── commands │ │ │ ├── cat.go │ │ │ ├── cat_test.go │ │ │ ├── count.go │ │ │ ├── count_test.go │ │ │ ├── e2e │ │ │ │ ├── e2e_test.go │ │ │ │ ├── e2econtainerconfig │ │ │ │ │ ├── Dockerfile │ │ │ │ │ ├── Makefile │ │ │ │ │ ├── doc.go │ │ │ │ │ ├── go.mod │ │ │ │ │ ├── go.sum │ │ │ │ │ └── main.go │ │ │ │ ├── e2econtainerenvgenerator │ │ │ │ │ ├── Dockerfile │ │ │ │ │ ├── Makefile │ │ │ │ │ ├── doc.go │ │ │ │ │ ├── go.mod │ │ │ │ │ ├── go.sum │ │ │ │ │ └── main.go │ │ │ │ ├── e2econtainermountbind │ │ │ │ │ ├── Dockerfile │ │ │ │ │ ├── Makefile │ │ │ │ │ ├── go.mod │ │ │ │ │ ├── go.sum │ │ │ │ │ └── main.go │ │ │ │ ├── e2econtainersimplegenerator │ │ │ │ │ ├── Dockerfile │ │ │ │ │ ├── Makefile │ │ │ │ │ ├── doc.go │ │ │ │ │ ├── go.mod │ │ │ │ │ ├── go.sum │ │ │ │ │ └── main.go │ │ │ │ ├── starlark │ │ │ │ │ └── annotate.star │ │ │ │ └── test_util_test.go │ │ │ ├── grep.go │ │ │ ├── grep_test.go │ │ │ ├── internal │ │ │ │ └── k8sgen │ │ │ │ │ ├── doc.go │ │ │ │ │ ├── k8scopy.yaml │ │ │ │ │ └── pkg │ │ │ │ │ └── api │ │ │ │ │ └── resource │ │ │ │ │ ├── amount.go │ │ │ │ │ ├── math.go │ │ │ │ │ ├── quantity.go │ │ │ │ │ ├── scale_int.go │ │ │ │ │ └── suffix.go │ │ │ ├── run-fns.go │ │ │ ├── run_test.go │ │ │ ├── test │ │ │ │ ├── override.yaml │ │ │ │ ├── test.sh │ │ │ │ └── testdata │ │ │ │ │ ├── dataset-with-setters │ │ │ │ │ └── mysql │ │ │ │ │ │ ├── Krmfile │ │ │ │ │ │ ├── deployment.yaml │ │ │ │ │ │ ├── nosetters │ │ │ │ │ │ ├── Krmfile │ │ │ │ │ │ └── deployment.yaml │ │ │ │ │ │ └── storage │ │ │ │ │ │ ├── Krmfile │ │ │ │ │ │ └── deployment.yaml │ │ │ │ │ └── dataset-without-setters │ │ │ │ │ └── mysql │ │ │ │ │ ├── Krmfile │ │ │ │ │ ├── deployment.yaml │ │ │ │ │ └── storage │ │ │ │ │ ├── Krmfile │ │ │ │ │ └── deployment.yaml │ │ │ ├── tree.go │ │ │ └── tree_test.go │ │ ├── generateddocs │ │ │ ├── api │ │ │ │ └── docs.go │ │ │ ├── commands │ │ │ │ └── docs.go │ │ │ └── tutorials │ │ │ │ └── docs.go │ │ └── inpututil │ │ │ └── inpututil.go │ ├── kubectl-krm │ │ └── main.go │ └── runner │ │ ├── runner.go │ │ └── runner_test.go ├── depprobcheck │ ├── Makefile │ ├── README.md │ ├── go.mod │ ├── go.sum │ └── main.go ├── gorepomod │ ├── Makefile │ ├── README.md │ ├── go.mod │ ├── go.sum │ ├── gorepomod_test.go │ ├── internal │ │ ├── arguments │ │ │ └── args.go │ │ ├── edit │ │ │ ├── editor.go │ │ │ └── editor_test.go │ │ ├── gen │ │ │ └── main.go │ │ ├── git │ │ │ └── runner.go │ │ ├── misc │ │ │ ├── interfaces.go │ │ │ ├── moduleshortname.go │ │ │ ├── moduleshortname_test.go │ │ │ ├── taggedmodule.go │ │ │ └── trackedrepo.go │ │ ├── mod │ │ │ ├── module.go │ │ │ └── module_test.go │ │ ├── repo │ │ │ ├── dotgitdata.go │ │ │ ├── dotgitdata_test.go │ │ │ ├── manager.go │ │ │ ├── managerfactory.go │ │ │ ├── protomodule.go │ │ │ └── protomodule_test.go │ │ ├── semver │ │ │ ├── semver.go │ │ │ ├── semver_test.go │ │ │ └── svbump.go │ │ └── utils │ │ │ ├── utils.go │ │ │ └── utils_test.go │ ├── main.go │ └── usage.go ├── k8scopy │ ├── Makefile │ ├── go.mod │ ├── go.sum │ ├── internal │ │ ├── copier.go │ │ ├── modulespec.go │ │ ├── modulespec_test.go │ │ ├── utils.go │ │ └── writer.go │ └── main.go ├── mdtogo │ ├── Makefile │ ├── go.mod │ ├── go.sum │ └── main.go └── pluginator │ ├── Makefile │ ├── go.mod │ ├── go.sum │ ├── internal │ ├── builtinplugin │ │ ├── builtinplugin.go │ │ └── plugintype_string.go │ └── krmfunction │ │ ├── cmd.go │ │ ├── converter.go │ │ ├── converter_test.go │ │ └── funcwrappersrc │ │ ├── fakeplugin.go │ │ ├── go.mod.src │ │ └── main.go │ └── main.go ├── code-of-conduct.md ├── examples ├── README.md ├── alphaTestExamples │ ├── MultipleDeployments.md │ └── helloapp.md ├── breakfast.md ├── chart.md ├── combineConfigs.md ├── components.md ├── configGeneration.md ├── configureBuiltinPlugin.md ├── customOpenAPIschema.md ├── generatorOptions.md ├── goGetterGeneratorPlugin.md ├── helloWorld │ ├── README.md │ ├── configMap.yaml │ ├── deployment.yaml │ ├── kustomization.yaml │ └── service.yaml ├── image.md ├── inlinePatch.md ├── integration_tests.sh ├── jsonpatch.md ├── ldap │ ├── README.md │ ├── base │ │ ├── deployment.yaml │ │ ├── env.startup.txt │ │ ├── kustomization.yaml │ │ └── service.yaml │ ├── integration_test.sh │ └── overlays │ │ ├── production │ │ ├── deployment.yaml │ │ └── kustomization.yaml │ │ └── staging │ │ ├── config.env │ │ ├── deployment.yaml │ │ └── kustomization.yaml ├── loadHttp.md ├── loadHttp │ └── kustomization.yaml ├── multibases │ ├── README.md │ ├── base │ │ ├── kustomization.yaml │ │ └── pod.yaml │ ├── dev │ │ └── kustomization.yaml │ ├── kustomization.yaml │ ├── multi-namespace.md │ ├── production │ │ └── kustomization.yaml │ └── staging │ │ └── kustomization.yaml ├── mySql │ ├── README.md │ ├── deployment.yaml │ ├── secret.yaml │ └── service.yaml ├── patchMultipleObjects.md ├── remoteBuild.md ├── replicas.md ├── secretGeneratorPlugin.md ├── springboot │ ├── README.md │ ├── base │ │ ├── application.properties │ │ ├── deployment.yaml │ │ ├── kustomization.yaml │ │ └── service.yaml │ └── overlays │ │ ├── production │ │ ├── application.properties │ │ ├── healthcheck_patch.yaml │ │ ├── kustomization.yaml │ │ ├── memorylimit_patch.yaml │ │ └── patch.yaml │ │ └── staging │ │ ├── application.properties │ │ ├── kustomization.yaml │ │ └── staging.env ├── transformerconfigs │ ├── README.md │ ├── crd │ │ ├── README.md │ │ ├── kustomization.yaml │ │ └── resources.yaml │ └── images │ │ ├── README.md │ │ ├── kustomization.yaml │ │ ├── mykind.yaml │ │ └── resources.yaml ├── validationTransformer │ ├── README.md │ ├── invalid.yaml │ └── valid.yaml ├── validatorPlugin.md ├── valueAdd.md ├── wordpress │ ├── README.md │ ├── kustomization.yaml │ ├── mysql │ │ ├── deployment.yaml │ │ ├── kustomization.yaml │ │ ├── secret.yaml │ │ └── service.yaml │ ├── patch.yaml │ └── wordpress │ │ ├── deployment.yaml │ │ ├── kustomization.yaml │ │ └── service.yaml └── zh │ ├── README.md │ ├── breakfast.md │ ├── chart.md │ ├── combineConfigs.md │ ├── configGeneration.md │ ├── generatorOptions.md │ ├── helloWorld.md │ ├── image.md │ ├── jsonpatch.md │ ├── ldap.md │ ├── multi-namespace.md │ ├── multibases.md │ ├── mysql.md │ ├── patchMultipleObjects.md │ ├── remoteBuild.md │ ├── secretGeneratorPlugin.md │ ├── springboot.md │ ├── transformerconfigs.md │ ├── validationTransformer.md │ └── vars.md ├── functions └── examples │ ├── Makefile-examples-base.mk │ ├── application-cr │ ├── Makefile │ ├── README.md │ ├── config │ │ └── fn-config.yaml │ ├── image │ │ ├── Dockerfile │ │ ├── Makefile │ │ ├── go.mod │ │ ├── go.sum │ │ ├── main.go │ │ └── main_test.go │ └── local-resource │ │ └── example.yaml │ ├── fn-framework-application │ ├── Makefile │ ├── README.md │ ├── cmd │ │ └── main.go │ ├── go.mod │ ├── go.sum │ └── pkg │ │ ├── dispatcher │ │ └── dispatcher.go │ │ └── exampleapp │ │ └── v1alpha1 │ │ ├── crd_gen.sh │ │ ├── example_app_test.go │ │ ├── platform.example.com_exampleapps.yaml │ │ ├── processing.go │ │ ├── templates │ │ ├── job_worker.template.yaml │ │ ├── postgres_secret_env_patch.template.yaml │ │ └── web_worker.template.yaml │ │ ├── testdata │ │ ├── error │ │ │ ├── config.yaml │ │ │ └── errors.txt │ │ └── success │ │ │ ├── basic │ │ │ ├── config.yaml │ │ │ └── expected.yaml │ │ │ └── overrides │ │ │ ├── config.yaml │ │ │ ├── custom-app-env.yaml │ │ │ ├── custom-configmap.yaml │ │ │ ├── expected.yaml │ │ │ └── web-worker-sidecar.yaml │ │ └── types.go │ ├── injection-tshirt-sizes │ ├── Makefile │ ├── README.md │ ├── image │ │ ├── Dockerfile │ │ ├── Makefile │ │ ├── go.mod │ │ ├── go.sum │ │ └── main.go │ └── local-resource │ │ ├── example-use.yaml │ │ ├── kustomization.yaml │ │ └── transformer.yaml │ ├── template-go-nginx │ ├── Makefile │ ├── README.md │ ├── image │ │ ├── Dockerfile │ │ ├── Makefile │ │ ├── go.mod │ │ ├── go.sum │ │ └── main.go │ └── local-resource │ │ ├── example-use.yaml │ │ └── kustomization.yaml │ ├── template-heredoc-cockroachdb │ ├── Makefile │ ├── README.md │ ├── image │ │ ├── Dockerfile │ │ └── cockroachdb-template.sh │ └── local-resource │ │ └── example-use.yaml │ ├── validator-kubeval │ ├── Makefile │ ├── README.md │ ├── image │ │ ├── Dockerfile │ │ ├── Makefile │ │ ├── go.mod │ │ ├── go.sum │ │ └── main.go │ └── local-resource │ │ └── example-use.yaml │ └── validator-resource-requests │ ├── Makefile │ ├── README.md │ ├── image │ ├── Dockerfile │ ├── Makefile │ ├── go.mod │ ├── go.sum │ └── main.go │ └── local-resource │ └── example-use.yaml ├── go.work ├── go.work.sum ├── hack ├── Invoke-PreCommit.ps1 ├── Makefile ├── add-license.sh ├── buildExternalGoPlugins.sh ├── doGoMod.sh ├── for-each-module.sh ├── generateBuiltinKrmFunctions.sh ├── go.mod ├── go.sum ├── imports.sh ├── install_kpt.sh ├── install_kustomize.sh ├── krmFunctionBenchmark │ ├── .gitignore │ ├── benchmark.sh │ ├── cleanup.sh │ ├── example_tshirt │ │ ├── containerfn │ │ │ ├── data.yaml │ │ │ ├── kustomization.yaml │ │ │ └── transf.yaml │ │ └── execfn │ │ │ ├── Dockerfile │ │ │ ├── build.sh │ │ │ ├── data.yaml │ │ │ ├── kustomization.yaml │ │ │ └── transf.yaml │ ├── label_namespace │ │ ├── containerfn │ │ │ ├── containerfn.yaml │ │ │ ├── data1.yaml │ │ │ ├── data2.yaml │ │ │ └── kustomization.yaml │ │ └── execfn │ │ │ ├── Dockerfile │ │ │ ├── build.sh │ │ │ ├── data1.yaml │ │ │ ├── data2.yaml │ │ │ ├── execfn.yaml │ │ │ ├── fn.sh │ │ │ ├── kustomization.yaml │ │ │ ├── package-lock.json │ │ │ └── package.json │ └── readme.md ├── latest_version.sh ├── makeKubectlPr.sh ├── shellHelpers.sh ├── testExamplesAgainstKustomize.sh ├── testExamplesE2EAgainstKustomize.sh ├── testUnitKustomizePlugins.sh ├── tools.go ├── whatApi.sh └── with-unpinned-kust-dev.sh ├── kustomize.Dockerfile ├── kustomize ├── Makefile ├── OWNERS ├── commands │ ├── build │ │ ├── build.go │ │ ├── build_test.go │ │ ├── flagaddmanagedby.go │ │ ├── flagenablehelm.go │ │ ├── flagenableplugins.go │ │ ├── flagloadrestrictor.go │ │ ├── flagoutputpath.go │ │ ├── flagsforfunctions.go │ │ ├── reorderoutput.go │ │ └── writer.go │ ├── commands.go │ ├── create │ │ ├── create.go │ │ └── create_test.go │ ├── edit │ │ ├── add │ │ │ ├── addbase.go │ │ │ ├── addbase_test.go │ │ │ ├── addbuildmetadata.go │ │ │ ├── addbuildmetadata_test.go │ │ │ ├── addcomponent.go │ │ │ ├── addcomponent_test.go │ │ │ ├── addconfigmap.go │ │ │ ├── addconfigmap_test.go │ │ │ ├── addgenerator.go │ │ │ ├── addgenerator_test.go │ │ │ ├── addmetadata.go │ │ │ ├── addmetadata_test.go │ │ │ ├── addpatch.go │ │ │ ├── addpatch_test.go │ │ │ ├── addresource.go │ │ │ ├── addresource_test.go │ │ │ ├── addsecret.go │ │ │ ├── addsecret_test.go │ │ │ ├── addtransformer.go │ │ │ ├── addtransformer_test.go │ │ │ └── all.go │ │ ├── all.go │ │ ├── fix │ │ │ ├── convert.go │ │ │ ├── convert_test.go │ │ │ ├── fix.go │ │ │ └── fix_test.go │ │ ├── listbuiltin │ │ │ └── listbuiltin.go │ │ ├── remove │ │ │ ├── all.go │ │ │ ├── removebuildmetadata.go │ │ │ ├── removebuildmetadata_test.go │ │ │ ├── removeconfigmap.go │ │ │ ├── removeconfigmap_test.go │ │ │ ├── removemetadata.go │ │ │ ├── removemetadata_test.go │ │ │ ├── removepatch.go │ │ │ ├── removepatch_test.go │ │ │ ├── removeresource.go │ │ │ ├── removeresource_test.go │ │ │ ├── removesecret.go │ │ │ ├── removesecret_test.go │ │ │ ├── removetransformer.go │ │ │ └── removetransformer_test.go │ │ └── set │ │ │ ├── all.go │ │ │ ├── set_name_prefix.go │ │ │ ├── set_name_prefix_test.go │ │ │ ├── set_name_suffix.go │ │ │ ├── set_name_suffix_test.go │ │ │ ├── setannotation.go │ │ │ ├── setannotation_test.go │ │ │ ├── setbuildmetadata.go │ │ │ ├── setbuildmetadata_test.go │ │ │ ├── setconfigmap.go │ │ │ ├── setconfigmap_test.go │ │ │ ├── setimage.go │ │ │ ├── setimage_test.go │ │ │ ├── setlabel.go │ │ │ ├── setlabel_test.go │ │ │ ├── setnamespace.go │ │ │ ├── setnamespace_test.go │ │ │ ├── setreplicas.go │ │ │ ├── setreplicas_test.go │ │ │ ├── setsecret.go │ │ │ └── setsecret_test.go │ ├── internal │ │ ├── configmapsecret │ │ │ └── configmapsecret_testutils.go │ │ ├── kustfile │ │ │ ├── kustomizationfile.go │ │ │ └── kustomizationfile_test.go │ │ ├── testutils │ │ │ ├── remove_testutils.go │ │ │ └── testutils.go │ │ └── util │ │ │ ├── configmapSecretFlagsAndArgs.go │ │ │ ├── configmapSecretFlagsAndArgs_test.go │ │ │ ├── util.go │ │ │ ├── util_test.go │ │ │ └── validate.go │ ├── localize │ │ ├── localize.go │ │ └── localize_test.go │ ├── openapi │ │ ├── fetch │ │ │ └── fetch.go │ │ ├── info │ │ │ └── info.go │ │ └── openapi.go │ └── version │ │ └── version.go ├── go.mod ├── go.sum └── main.go ├── kyaml ├── Makefile ├── commandutil │ └── commandutil.go ├── comments │ ├── comments.go │ └── comments_test.go ├── copyutil │ ├── copyutil.go │ └── copyutil_test.go ├── doc.go ├── errors │ └── errors.go ├── ext │ └── ext.go ├── fieldmeta │ └── fieldmeta.go ├── filesys │ ├── confirmeddir.go │ ├── confirmeddir_test.go │ ├── doc.go │ ├── file.go │ ├── fileinfo.go │ ├── fileondisk.go │ ├── filesystem.go │ ├── filesystem_test.go │ ├── fsnode.go │ ├── fsnode_test.go │ ├── fsondisk.go │ ├── fsondisk_test.go │ ├── fsondisk_unix.go │ ├── fsondisk_windows.go │ ├── util.go │ └── util_test.go ├── filtersutil │ ├── doc.go │ ├── example_test.go │ └── filtersutil.go ├── fn │ ├── framework │ │ ├── command │ │ │ ├── command.go │ │ │ ├── command_test.go │ │ │ ├── doc.go │ │ │ ├── example_test.go │ │ │ └── testdata │ │ │ │ └── standalone │ │ │ │ ├── config.yaml │ │ │ │ ├── expected.yaml │ │ │ │ └── input.yaml │ │ ├── doc.go │ │ ├── example │ │ │ ├── Dockerfile │ │ │ ├── doc.go │ │ │ ├── main.go │ │ │ ├── main_test.go │ │ │ ├── templates │ │ │ │ └── service_account.template.yaml │ │ │ └── testdata │ │ │ │ └── basic │ │ │ │ ├── config.yaml │ │ │ │ ├── expected.yaml │ │ │ │ └── input.yaml │ │ ├── example_test.go │ │ ├── framework.go │ │ ├── framework_test.go │ │ ├── frameworktestutil │ │ │ ├── frameworktestutil.go │ │ │ ├── frameworktestutil_test.go │ │ │ └── testdata │ │ │ │ └── update_expectations │ │ │ │ ├── command │ │ │ │ └── important_subdir │ │ │ │ │ ├── config.yaml │ │ │ │ │ ├── expected.yaml │ │ │ │ │ └── input.yaml │ │ │ │ └── processor │ │ │ │ └── important_subdir │ │ │ │ ├── expected.yaml │ │ │ │ └── input.yaml │ │ ├── function_definition.go │ │ ├── matchers.go │ │ ├── parser │ │ │ ├── doc.go │ │ │ ├── parser.go │ │ │ ├── schema.go │ │ │ ├── schema_test.go │ │ │ ├── template.go │ │ │ ├── template_test.go │ │ │ └── testdata │ │ │ │ ├── cm1.template.yaml │ │ │ │ ├── cm2.template.yaml │ │ │ │ ├── ignore.yaml │ │ │ │ ├── schema1.json │ │ │ │ └── schema2.json │ │ ├── patch.go │ │ ├── patch_test.go │ │ ├── processors.go │ │ ├── processors_test.go │ │ ├── result.go │ │ ├── result_test.go │ │ ├── selector.go │ │ ├── selector_test.go │ │ ├── template.go │ │ ├── testdata │ │ │ ├── example │ │ │ │ ├── template │ │ │ │ │ └── config.yaml │ │ │ │ └── templatefiles │ │ │ │ │ ├── config.yaml │ │ │ │ │ └── deployment.template.yaml │ │ │ ├── patch-selector │ │ │ │ ├── annotationselector │ │ │ │ │ ├── config.yaml │ │ │ │ │ ├── expected.yaml │ │ │ │ │ └── input.yaml │ │ │ │ ├── apiversionselector │ │ │ │ │ ├── config.yaml │ │ │ │ │ ├── expected.yaml │ │ │ │ │ └── input.yaml │ │ │ │ ├── filterselector │ │ │ │ │ ├── config.yaml │ │ │ │ │ ├── expected.yaml │ │ │ │ │ └── input.yaml │ │ │ │ ├── kindselector │ │ │ │ │ ├── config.yaml │ │ │ │ │ ├── expected.yaml │ │ │ │ │ └── input.yaml │ │ │ │ ├── labelselector │ │ │ │ │ ├── config.yaml │ │ │ │ │ ├── expected.yaml │ │ │ │ │ └── input.yaml │ │ │ │ ├── longlistpreprocess │ │ │ │ │ ├── config.yaml │ │ │ │ │ ├── expected.yaml │ │ │ │ │ └── input.yaml │ │ │ │ ├── nameselector │ │ │ │ │ ├── config.yaml │ │ │ │ │ ├── expected.yaml │ │ │ │ │ └── input.yaml │ │ │ │ └── namespaceselector │ │ │ │ │ ├── config.yaml │ │ │ │ │ ├── expected.yaml │ │ │ │ │ └── input.yaml │ │ │ ├── template-processor │ │ │ │ ├── container-patches │ │ │ │ │ └── container.template.yaml │ │ │ │ ├── patches │ │ │ │ │ ├── basic │ │ │ │ │ │ └── patch.template.yaml │ │ │ │ │ └── custom-resource │ │ │ │ │ │ └── patch.template.yaml │ │ │ │ ├── schemas │ │ │ │ │ └── foo.json │ │ │ │ └── templates │ │ │ │ │ ├── basic │ │ │ │ │ └── deploy.template.yaml │ │ │ │ │ ├── container-sources │ │ │ │ │ ├── cron_job.template.yaml │ │ │ │ │ ├── daemon_set.template.yaml │ │ │ │ │ ├── deployment.template.yaml │ │ │ │ │ ├── job.template.yaml │ │ │ │ │ ├── pod.template.yaml │ │ │ │ │ ├── pod_template.template.yaml │ │ │ │ │ ├── replica_set.template.yaml │ │ │ │ │ ├── replication_controller.template.yaml │ │ │ │ │ └── stateful_set.template.yaml │ │ │ │ │ └── custom-resource │ │ │ │ │ └── foo.template.yaml │ │ │ └── validation │ │ │ │ └── error │ │ │ │ ├── errors.txt │ │ │ │ └── input.yaml │ │ ├── validation.go │ │ └── validation_test.go │ └── runtime │ │ ├── container │ │ ├── container.go │ │ └── container_test.go │ │ ├── exec │ │ ├── doc.go │ │ ├── exec.go │ │ └── exec_test.go │ │ └── runtimeutil │ │ ├── doc.go │ │ ├── functiontypes.go │ │ ├── runtimeutil.go │ │ ├── runtimeutil_test.go │ │ └── types.go ├── go.mod ├── go.sum ├── inpututil │ └── inpututil.go ├── kio │ ├── byteio_reader.go │ ├── byteio_reader_test.go │ ├── byteio_readwriter_test.go │ ├── byteio_writer.go │ ├── byteio_writer_test.go │ ├── doc.go │ ├── example_test.go │ ├── filters │ │ ├── filters.go │ │ ├── filters_test.go │ │ ├── fmtr.go │ │ ├── fmtr_test.go │ │ ├── grep.go │ │ ├── grep_test.go │ │ ├── local.go │ │ ├── merge.go │ │ ├── merge3.go │ │ ├── merge3_test.go │ │ ├── merge_test.go │ │ ├── modify.go │ │ ├── stripcomments.go │ │ ├── testdata │ │ │ ├── dataset1-expected │ │ │ │ ├── java │ │ │ │ │ ├── java-configmap.resource.yaml │ │ │ │ │ ├── java-deployment.resource.yaml │ │ │ │ │ └── java-service.resource.yaml │ │ │ │ ├── mysql │ │ │ │ │ ├── mysql-configmap.resource.yaml │ │ │ │ │ ├── mysql-service.resource.yaml │ │ │ │ │ └── mysql-statefulset.resource.yaml │ │ │ │ └── wordpress │ │ │ │ │ ├── wordpress-service.resource.yaml │ │ │ │ │ └── wordpress-statefulset.resource.yaml │ │ │ ├── dataset1-localupdates │ │ │ │ ├── java │ │ │ │ │ ├── java-configmap.resource.yaml │ │ │ │ │ ├── java-deployment.resource.yaml │ │ │ │ │ └── java-service.resource.yaml │ │ │ │ └── wordpress │ │ │ │ │ ├── wordpress-service.resource.yaml │ │ │ │ │ └── wordpress-statefulset.resource.yaml │ │ │ ├── dataset1-remoteupdates │ │ │ │ ├── java │ │ │ │ │ ├── java-configmap.resource.yaml │ │ │ │ │ ├── java-deployment.resource.yaml │ │ │ │ │ └── java-service.resource.yaml │ │ │ │ └── mysql │ │ │ │ │ ├── mysql-configmap.resource.yaml │ │ │ │ │ ├── mysql-service.resource.yaml │ │ │ │ │ └── mysql-statefulset.resource.yaml │ │ │ └── dataset1 │ │ │ │ ├── java │ │ │ │ ├── java-configmap.resource.yaml │ │ │ │ ├── java-deployment.resource.yaml │ │ │ │ └── java-service.resource.yaml │ │ │ │ └── rails │ │ │ │ ├── rails-configmap.resource.yaml │ │ │ │ ├── rails-deployment.resource.yaml │ │ │ │ └── rails-service.resource.yaml │ │ ├── testdata2 │ │ │ ├── dataset1-expected │ │ │ │ └── java │ │ │ │ │ ├── java-deployment-1.resource.yaml │ │ │ │ │ └── java-deployment-2.resource.yaml │ │ │ ├── dataset1-localupdates │ │ │ │ └── java │ │ │ │ │ ├── java-deployment-1.resource.yaml │ │ │ │ │ └── java-deployment-2.resource.yaml │ │ │ ├── dataset1-remoteupdates │ │ │ │ └── java │ │ │ │ │ ├── java-deployment-1.resource.yaml │ │ │ │ │ └── java-deployment-2.resource.yaml │ │ │ └── dataset1 │ │ │ │ └── java │ │ │ │ ├── java-deployment-1.resource.yaml │ │ │ │ └── java-deployment-2.resource.yaml │ │ └── testyaml │ │ │ └── testyaml.go │ ├── ignorefilesmatcher.go │ ├── ignorefilesmatcher_test.go │ ├── kio.go │ ├── kio_test.go │ ├── kioutil │ │ ├── kioutil.go │ │ └── kioutil_test.go │ ├── pkgio_reader.go │ ├── pkgio_reader_test.go │ ├── pkgio_writer.go │ ├── pkgio_writer_test.go │ ├── testing_test.go │ ├── tree.go │ └── tree_test.go ├── krmfile │ ├── doc.go │ └── krmfile.go ├── openapi │ ├── Makefile │ ├── README.md │ ├── example_test.go │ ├── kubernetesapi │ │ ├── openapiinfo.go │ │ └── v1_21_2 │ │ │ ├── swagger.go │ │ │ └── swagger.pb │ ├── kustomizationapi │ │ ├── swagger.go │ │ └── swagger.json │ ├── openapi.go │ ├── openapi_benchmark_test.go │ ├── openapi_test.go │ └── scripts │ │ ├── fetchSchemaFromCluster.sh │ │ ├── generateSwaggerDotGo.sh │ │ └── makeOpenApiInfoDotGo.sh ├── order │ ├── syncorder.go │ └── syncorder_test.go ├── pathutil │ ├── pathutil.go │ └── pathutil_test.go ├── resid │ ├── gvk.go │ ├── gvk_test.go │ ├── resid.go │ └── resid_test.go ├── runfn │ ├── runfn.go │ ├── runfn_test.go │ └── test │ │ └── testdata │ │ └── java │ │ ├── java-configmap.resource.yaml │ │ ├── java-deployment.resource.yaml │ │ └── java-service.resource.yaml ├── sets │ ├── sets_test.go │ ├── string.go │ └── stringlist.go ├── sliceutil │ ├── slice.go │ └── sliceutil_test.go ├── testutil │ └── testutil.go ├── utils │ ├── pathsplitter.go │ └── pathsplitter_test.go └── yaml │ ├── alias.go │ ├── compatibility.go │ ├── compatibility_test.go │ ├── const.go │ ├── datamap.go │ ├── datamap_test.go │ ├── doc.go │ ├── example_test.go │ ├── filters.go │ ├── fns.go │ ├── fns_test.go │ ├── internal │ └── k8sgen │ │ ├── doc.go │ │ ├── k8scopy.yaml │ │ └── pkg │ │ ├── labels │ │ ├── copied.deepcopy.go │ │ ├── labels.go │ │ └── selector.go │ │ ├── selection │ │ └── operator.go │ │ └── util │ │ ├── errors │ │ └── errors.go │ │ ├── sets │ │ ├── empty.go │ │ └── string.go │ │ └── validation │ │ ├── field │ │ ├── errors.go │ │ └── path.go │ │ └── validation.go │ ├── kfns.go │ ├── kfns_test.go │ ├── mapnode.go │ ├── mapnode_test.go │ ├── match.go │ ├── match_test.go │ ├── merge2 │ ├── element_test.go │ ├── list_test.go │ ├── map_test.go │ ├── merge2.go │ ├── merge2_old_test.go │ ├── merge2_test.go │ ├── scalar_test.go │ ├── smpdirective.go │ ├── smpdirective_string.go │ └── smpdirective_test.go │ ├── merge3 │ ├── element_test.go │ ├── kustomization_test.go │ ├── list_test.go │ ├── map_test.go │ ├── merge3.go │ ├── merge3_test.go │ ├── scalar_test.go │ └── visitor.go │ ├── order.go │ ├── rnode.go │ ├── rnode_test.go │ ├── schema │ ├── schema.go │ └── schema_test.go │ ├── types.go │ ├── types_test.go │ ├── util.go │ ├── util_test.go │ └── walk │ ├── associative_sequence.go │ ├── map.go │ ├── nonassociative_sequence.go │ ├── scalar.go │ ├── visitor.go │ └── walk.go ├── plugin ├── README.md ├── builtin │ ├── annotationstransformer │ │ ├── AnnotationsTransformer.go │ │ ├── AnnotationsTransformer_test.go │ │ ├── Makefile │ │ ├── go.mod │ │ └── go.sum │ ├── configmapgenerator │ │ ├── ConfigMapGenerator.go │ │ ├── ConfigMapGenerator_test.go │ │ ├── Makefile │ │ ├── go.mod │ │ └── go.sum │ ├── hashtransformer │ │ ├── HashTransformer.go │ │ ├── HashTransformer_test.go │ │ ├── Makefile │ │ ├── go.mod │ │ └── go.sum │ ├── helmchartinflationgenerator │ │ ├── HelmChartInflationGenerator.go │ │ ├── HelmChartInflationGenerator_test.go │ │ ├── Makefile │ │ ├── go.mod │ │ ├── go.sum │ │ ├── include_crds_testdata.txt │ │ └── testdata │ │ │ └── charts │ │ │ ├── issue4905 │ │ │ ├── Chart.yaml │ │ │ ├── templates │ │ │ │ ├── _helpers.tpl │ │ │ │ └── configmap.yaml │ │ │ └── values.yaml │ │ │ ├── test-chart │ │ │ ├── Chart.yaml │ │ │ ├── templates │ │ │ │ └── configmap.yaml │ │ │ └── values.yaml │ │ │ └── values-merge │ │ │ ├── Chart.yaml │ │ │ ├── templates │ │ │ └── test.yaml │ │ │ └── values.yaml │ ├── iampolicygenerator │ │ ├── IAMPolicyGenerator.go │ │ ├── Makefile │ │ ├── go.mod │ │ └── go.sum │ ├── imagetagtransformer │ │ ├── ImageTagTransformer.go │ │ ├── ImageTagTransformer_test.go │ │ ├── Makefile │ │ ├── go.mod │ │ └── go.sum │ ├── labeltransformer │ │ ├── LabelTransformer.go │ │ ├── LabelTransformer_test.go │ │ ├── Makefile │ │ ├── go.mod │ │ └── go.sum │ ├── namespacetransformer │ │ ├── Makefile │ │ ├── NamespaceTransformer.go │ │ ├── NamespaceTransformer_test.go │ │ ├── go.mod │ │ └── go.sum │ ├── patchjson6902transformer │ │ ├── Makefile │ │ ├── PatchJson6902Transformer.go │ │ ├── PatchJson6902Transformer_test.go │ │ ├── go.mod │ │ └── go.sum │ ├── patchstrategicmergetransformer │ │ ├── Makefile │ │ ├── PatchStrategicMergeTransformer.go │ │ ├── PatchStrategicMergeTransformer_test.go │ │ ├── go.mod │ │ └── go.sum │ ├── patchtransformer │ │ ├── Makefile │ │ ├── PatchTransformer.go │ │ ├── PatchTransformer_test.go │ │ ├── go.mod │ │ └── go.sum │ ├── prefixtransformer │ │ ├── Makefile │ │ ├── PrefixTransformer.go │ │ ├── PrefixTransformer_test.go │ │ ├── go.mod │ │ └── go.sum │ ├── replacementtransformer │ │ ├── Makefile │ │ ├── ReplacementTransformer.go │ │ ├── ReplacementTransformer_test.go │ │ ├── go.mod │ │ └── go.sum │ ├── replicacounttransformer │ │ ├── Makefile │ │ ├── ReplicaCountTransformer.go │ │ ├── ReplicaCountTransformer_test.go │ │ ├── go.mod │ │ └── go.sum │ ├── secretgenerator │ │ ├── Makefile │ │ ├── SecretGenerator.go │ │ ├── SecretGenerator_test.go │ │ ├── go.mod │ │ └── go.sum │ ├── sortordertransformer │ │ ├── Makefile │ │ ├── SortOrderTransformer.go │ │ ├── SortOrderTransformer_test.go │ │ ├── go.mod │ │ └── go.sum │ ├── suffixtransformer │ │ ├── Makefile │ │ ├── SuffixTransformer.go │ │ ├── SuffixTransformer_test.go │ │ ├── go.mod │ │ └── go.sum │ └── valueaddtransformer │ │ ├── Makefile │ │ ├── ValueAddTransformer.go │ │ ├── ValueAddTransformer_test.go │ │ ├── go.mod │ │ └── go.sum ├── someteam.example.com │ └── v1 │ │ ├── bashedconfigmap │ │ ├── BashedConfigMap │ │ ├── BashedConfigMap_test.go │ │ ├── Makefile │ │ ├── go.mod │ │ └── go.sum │ │ ├── calvinduplicator │ │ ├── CalvinDuplicator.go │ │ ├── CalvinDuplicator_test.go │ │ ├── Makefile │ │ ├── go.mod │ │ └── go.sum │ │ ├── dateprefixer │ │ ├── DatePrefixer.go │ │ ├── DatePrefixer_test.go │ │ ├── Makefile │ │ ├── go.mod │ │ └── go.sum │ │ ├── printpluginenv │ │ ├── Makefile │ │ ├── PrintPluginEnv │ │ ├── PrintPluginEnv_test.go │ │ ├── go.mod │ │ └── go.sum │ │ ├── secretsfromdatabase │ │ ├── Makefile │ │ ├── SecretsFromDatabase.go │ │ ├── SecretsFromDatabase_test.go │ │ ├── go.mod │ │ └── go.sum │ │ ├── sedtransformer │ │ ├── Makefile │ │ ├── SedTransformer │ │ ├── SedTransformer_test.go │ │ ├── go.mod │ │ └── go.sum │ │ ├── someservicegenerator │ │ ├── Makefile │ │ ├── SomeServiceGenerator.go │ │ ├── SomeServiceGenerator_test.go │ │ ├── go.mod │ │ └── go.sum │ │ ├── stringprefixer │ │ ├── Makefile │ │ ├── StringPrefixer.go │ │ ├── StringPrefixer_test.go │ │ ├── go.mod │ │ └── go.sum │ │ └── validator │ │ ├── Makefile │ │ ├── Validator │ │ ├── go.mod │ │ ├── go.sum │ │ └── validator_test.go └── untested │ └── v1 │ └── gogetter │ ├── GoGetter │ ├── GoGetter_test.go │ ├── Makefile │ ├── go.mod │ └── go.sum ├── proposals ├── 00-00-template.md ├── 21-11-transformer-annotations.md ├── 22-03-value-in-the-structured-data.md ├── 22-04-localize-command.md └── README.md ├── releasing ├── README.md ├── check-release-helper.sh ├── cloudbuild_kustomize_image.yaml ├── compile-changelog.sh ├── create-release.sh └── helpers.sh └── site ├── .nvmrc ├── Dockerfile ├── Makefile ├── OWNERS ├── README.md ├── assets └── scss │ └── _variables_project.scss ├── content ├── en │ ├── _index.html │ ├── blog │ │ ├── _index.md │ │ ├── news │ │ │ ├── _index.md │ │ │ ├── first-post │ │ │ │ ├── featured-sunset-get.png │ │ │ │ └── index.md │ │ │ └── second-post.md │ │ └── releases │ │ │ ├── _index.md │ │ │ └── in-depth-monoliths-detailed-spec.md │ ├── contribute │ │ ├── _index.md │ │ ├── bugs │ │ │ └── _index.md │ │ ├── community │ │ │ └── _index.md │ │ ├── features │ │ │ └── _index.md │ │ ├── howitworks │ │ │ └── _index.md │ │ └── mac │ │ │ └── _index.md │ ├── docs │ │ ├── Concepts │ │ │ ├── _index.md │ │ │ ├── bases.md │ │ │ ├── components.md │ │ │ ├── functions.md │ │ │ ├── generator.md │ │ │ ├── kustomization_file.md │ │ │ └── transformers.md │ │ ├── Getting started │ │ │ ├── _index.md │ │ │ ├── first_kustomization.md │ │ │ └── installation.md │ │ ├── Overview │ │ │ └── _index.md │ │ ├── Reference │ │ │ ├── API │ │ │ │ ├── Common Definitions │ │ │ │ │ ├── FieldSpec.md │ │ │ │ │ └── _index.md │ │ │ │ ├── Generators │ │ │ │ │ ├── ConfigMapGenerator.md │ │ │ │ │ ├── SecretGenerator.md │ │ │ │ │ └── _index.md │ │ │ │ ├── Kustomization File │ │ │ │ │ ├── _index.md │ │ │ │ │ ├── bases.md │ │ │ │ │ ├── buildMetadata.md │ │ │ │ │ ├── commonAnnotations.md │ │ │ │ │ ├── commonLabels.md │ │ │ │ │ ├── components.md │ │ │ │ │ ├── configMapGenerator.md │ │ │ │ │ ├── crds.md │ │ │ │ │ ├── generatorOptions.md │ │ │ │ │ ├── helmCharts.md │ │ │ │ │ ├── images.md │ │ │ │ │ ├── kustomization.md │ │ │ │ │ ├── labels.md │ │ │ │ │ ├── namePrefix.md │ │ │ │ │ ├── nameSuffix.md │ │ │ │ │ ├── namespace.md │ │ │ │ │ ├── openapi.md │ │ │ │ │ ├── patches.md │ │ │ │ │ ├── patchesStrategicMerge.md │ │ │ │ │ ├── patchesjson6902.md │ │ │ │ │ ├── replacements.md │ │ │ │ │ ├── replicas.md │ │ │ │ │ ├── resources.md │ │ │ │ │ ├── secretGenerator.md │ │ │ │ │ ├── sortOptions.md │ │ │ │ │ └── vars.md │ │ │ │ ├── Transformers │ │ │ │ │ ├── AnnotationsTransformer.md │ │ │ │ │ ├── LabelTransformer.md │ │ │ │ │ ├── NamespaceTransformer.md │ │ │ │ │ ├── PrefixTransformer.md │ │ │ │ │ ├── SuffixTransformer.md │ │ │ │ │ └── _index.md │ │ │ │ ├── _index.md │ │ │ │ └── included │ │ │ │ │ ├── _index.md │ │ │ │ │ ├── generatorargs.md │ │ │ │ │ └── secretargs.md │ │ │ ├── CLI │ │ │ │ └── _index.md │ │ │ ├── _index.md │ │ │ └── glossary.md │ │ ├── Tasks │ │ │ ├── _index.md │ │ │ ├── build_metadata.md │ │ │ ├── configmap_generator.md │ │ │ ├── labels_and_annotations.md │ │ │ ├── namespaces_and_names.md │ │ │ └── secret_generator.md │ │ ├── Tutorials │ │ │ ├── _index.md │ │ │ ├── custom_application.md │ │ │ └── off_the_shelf_application.md │ │ └── _index.md │ ├── faq │ │ ├── _index.md │ │ ├── eschewedfeatures.md │ │ └── versioningPolicy.md │ ├── includes │ │ └── index.md │ └── search.md ├── fa │ ├── _index.html │ ├── about │ │ ├── _index.html │ │ └── featured-background.jpg │ ├── blog │ │ ├── _index.md │ │ ├── news │ │ │ ├── _index.md │ │ │ └── first-post │ │ │ │ ├── featured-sunset-get.png │ │ │ │ └── index.md │ │ └── releases │ │ │ └── _index.md │ ├── community │ │ └── _index.md │ ├── docs │ │ └── _index.md │ └── search.md └── no │ ├── _index.html │ ├── docs │ ├── _index.md │ ├── api-reference │ │ ├── _index.md │ │ ├── examples │ │ │ ├── _index.md │ │ │ ├── in-depth-monoliths-detailed-spec.md │ │ │ ├── the-inside-of-cryptography-detailed-spec.md │ │ │ ├── the-inside-of-microservices-how-does-it-work.md │ │ │ ├── the-math-of-java-how-does-it-work.md │ │ │ └── the-math-of-monographs-how-does-it-work.md │ │ ├── the-inside-of-java-the-inner-workings.md │ │ └── the-math-of-monoliths-detailed-spec.md │ ├── big-data │ │ ├── _index.md │ │ ├── examples │ │ │ ├── _index.md │ │ │ └── the-math-of-monographs-how-does-it-work.md │ │ ├── the-math-of-monographs-how-does-it-work.md │ │ └── tutorials │ │ │ ├── _index.md │ │ │ ├── in-depth-go-the-inner-workings.md │ │ │ ├── the-inside-of-cryptography-how-does-it-work.md │ │ │ ├── the-inside-of-java-detailed-spec.md │ │ │ ├── the-inside-of-microservices-detailed-spec.md │ │ │ └── the-math-of-cryptography-the-inner-workings.md │ ├── cloud-computing │ │ ├── _index.md │ │ ├── examples │ │ │ ├── _index.md │ │ │ ├── in-depth-cryptography-the-core-concepts.md │ │ │ ├── in-depth-go-how-does-it-work.md │ │ │ └── the-inside-of-monoliths-how-does-it-work.md │ │ ├── in-depth-go-detailed-spec.md │ │ ├── in-depth-monoliths-detailed-spec.md │ │ ├── the-inside-of-java-how-does-it-work.md │ │ └── tutorials │ │ │ ├── _index.md │ │ │ ├── in-depth-monographs-the-inner-workings.md │ │ │ ├── the-inside-of-go-the-inner-workings.md │ │ │ ├── the-inside-of-microservices-detailed-spec.md │ │ │ ├── the-math-of-java-the-inner-workings.md │ │ │ ├── the-math-of-microservices-detailed-spec.md │ │ │ ├── the-math-of-monographs-detailed-spec.md │ │ │ └── the-math-of-monoliths-the-inner-workings.md │ ├── content-management │ │ ├── _index.md │ │ ├── the-inside-of-cryptography-how-does-it-work.md │ │ ├── the-inside-of-monographs-the-core-concepts.md │ │ ├── the-math-of-microservices-how-does-it-work.md │ │ ├── the-math-of-monoliths-the-inner-workings.md │ │ └── tutorials │ │ │ ├── _index.md │ │ │ ├── in-depth-microservices-the-core-concepts.md │ │ │ ├── the-inside-of-cryptography-the-core-concepts.md │ │ │ ├── the-inside-of-microservices-the-core-concepts.md │ │ │ └── the-inside-of-recursion-the-inner-workings.md │ └── cross-platform │ │ ├── _index.md │ │ ├── examples │ │ ├── _index.md │ │ ├── in-depth-java-detailed-spec.md │ │ ├── the-inside-of-java-the-core-concepts.md │ │ ├── the-math-of-go-the-inner-workings.md │ │ └── the-math-of-recursion-the-inner-workings.md │ │ ├── in-depth-cryptography-detailed-spec.md │ │ ├── the-inside-of-monographs-how-does-it-work.md │ │ ├── the-inside-of-monoliths-the-core-concepts.md │ │ ├── the-inside-of-recursion-how-does-it-work.md │ │ └── tutorials │ │ ├── _index.md │ │ └── the-math-of-cryptography-how-does-it-work.md │ └── search.md ├── docker-compose.yaml ├── hugo.toml ├── i18n └── en.toml ├── layouts ├── 404.html ├── partials │ └── footer.html └── shortcodes │ ├── example-major-version.html │ ├── example-semver-version.html │ ├── example-version.html │ └── include.html ├── netlify.toml ├── package-lock.json ├── package.json ├── scripts └── hash-files.sh └── static └── favicons ├── android-144x144.png ├── android-192x192.png ├── android-36x36.png ├── android-48x48.png ├── android-72x72.png ├── android-96x96.png ├── apple-touch-icon-180x180.png ├── favicon-1024.png ├── favicon-16x16.png ├── favicon-256.png ├── favicon-32x32.png ├── favicon.ico ├── pwa-192x192.png ├── pwa-512x512.png ├── tile150x150.png ├── tile310x150.png ├── tile310x310.png └── tile70x70.png /.dockerignore: -------------------------------------------------------------------------------- 1 | .github 2 | docs 3 | examples 4 | travis 5 | *.md 6 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/config.yml: -------------------------------------------------------------------------------- 1 | contact_links: 2 | - name: Support request 3 | url: https://discuss.kubernetes.io 4 | about: | 5 | Please do not submit support requests or questions as issues. 6 | Ask your question in the Kubernetes Community Forums, or in the #kustomize channel on Kubernetes Slack (https://slack.k8s.io). 7 | -------------------------------------------------------------------------------- /.github/dependabot.yml: -------------------------------------------------------------------------------- 1 | version: 2 2 | updates: 3 | - package-ecosystem: "github-actions" 4 | directory: "/" 5 | schedule: 6 | interval: "weekly" 7 | 8 | - package-ecosystem: gomod 9 | directory: "/" 10 | schedule: 11 | interval: "weekly" 12 | open-pull-requests-limit: 10 13 | vulnerability-alerts: 14 | enabled: true -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Binaries for programs and plugins 2 | *.exe 3 | *.exe~ 4 | *.dll 5 | *.so 6 | *.dylib 7 | 8 | .idea 9 | *.iml 10 | 11 | # Test binary, build with `go test -c` 12 | *.test 13 | 14 | # Output of the go coverage tool, specifically when used with LiteIDE 15 | *.out 16 | 17 | # We use sed -i.bak when doing in-line replace, because it works better cross-platform 18 | .bak 19 | 20 | # macOS 21 | *.DS_store 22 | 23 | .bin 24 | 25 | # Hugo site 26 | publishedSite/ 27 | site/public/ 28 | site/resources/ 29 | site/.hugo_build.lock 30 | **/node_modules/ 31 | 32 | # goreleaser artifacts 33 | **/dist/ 34 | /output/ 35 | -------------------------------------------------------------------------------- /.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "site/themes/docsy"] 2 | path = site/themes/docsy 3 | url = https://github.com/google/docsy.git 4 | -------------------------------------------------------------------------------- /LICENSE_TEMPLATE: -------------------------------------------------------------------------------- 1 | Copyright {{.Year}} {{.Holder}} 2 | SPDX-License-Identifier: Apache-2.0 3 | -------------------------------------------------------------------------------- /OWNERS: -------------------------------------------------------------------------------- 1 | # See https://github.com/kubernetes/community/blob/master/community-membership.md 2 | approvers: 3 | - kustomize-approvers 4 | reviewers: 5 | - kustomize-reviewers 6 | -------------------------------------------------------------------------------- /SECURITY_CONTACTS: -------------------------------------------------------------------------------- 1 | # Defined below are the security contacts for this repo. 2 | # 3 | # They are the contact point for the Product Security Team to reach out 4 | # to for triaging and handling of incoming issues. 5 | # 6 | # The below names agree to abide by the 7 | # [Embargo Policy](https://github.com/kubernetes/sig-release/blob/master/security-release-process-documentation/security-release-process.md#embargo-policy) 8 | # and will be removed and replaced if they violate that agreement. 9 | # 10 | # DO NOT REPORT SECURITY VULNERABILITIES DIRECTLY TO THESE NAMES, FOLLOW THE 11 | # INSTRUCTIONS AT https://kubernetes.io/security/ 12 | eddiezane 13 | KnVerey 14 | natasha41575 15 | soltysh 16 | -------------------------------------------------------------------------------- /api/filters/annotations/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package annotations contains a kio.Filter implementation of the kustomize 5 | // annotations transformer. 6 | package annotations 7 | -------------------------------------------------------------------------------- /api/filters/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package filters 5 | 6 | // Package filters collects various implementations 7 | // sigs.k8s.io/kustomize/kyaml/kio.Filter used by kustomize 8 | // transformers to modify kubernetes objects. 9 | -------------------------------------------------------------------------------- /api/filters/fieldspec/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package fieldspec contains a yaml.Filter to modify a resource 5 | // that matches the FieldSpec. 6 | package fieldspec 7 | -------------------------------------------------------------------------------- /api/filters/fsslice/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package fsslice contains a yaml.Filter to modify a resource if 5 | // it matches one or more FieldSpec entries. 6 | package fsslice 7 | -------------------------------------------------------------------------------- /api/filters/iampolicygenerator/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package gkesagenerator contains a kio.Filter that that generates a 5 | // iampolicy-related resources for a given cloud provider 6 | package iampolicygenerator 7 | -------------------------------------------------------------------------------- /api/filters/imagetag/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package imagetag contains two kio.Filter implementations to cover the 5 | // functionality of the kustomize imagetag transformer. 6 | // 7 | // Filter updates fields based on a FieldSpec and an ImageTag. 8 | // 9 | // LegacyFilter doesn't use a FieldSpec, and instead only updates image 10 | // references if the field is name image and it is underneath a field called 11 | // either containers or initContainers. 12 | package imagetag 13 | -------------------------------------------------------------------------------- /api/filters/labels/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package labels contains a kio.Filter implementation of the kustomize 5 | // labels transformer. 6 | package labels 7 | -------------------------------------------------------------------------------- /api/filters/nameref/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package nameref contains a kio.Filter implementation of the kustomize 5 | // name reference transformer. 6 | package nameref 7 | -------------------------------------------------------------------------------- /api/filters/namespace/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package namespace contains a kio.Filter implementation of the kustomize 5 | // namespace transformer. 6 | // 7 | // Special cases for known Kubernetes resources have been hardcoded in addition 8 | // to those defined by the FsSlice. 9 | package namespace 10 | -------------------------------------------------------------------------------- /api/filters/patchjson6902/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package namespace contains a kio.Filter implementation of the kustomize 5 | // patchjson6902 transformer 6 | package patchjson6902 7 | -------------------------------------------------------------------------------- /api/filters/patchstrategicmerge/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package patchstrategicmerge contains a kio.Filter implementation of the 5 | // kustomize strategic merge patch transformer. 6 | package patchstrategicmerge 7 | -------------------------------------------------------------------------------- /api/filters/prefix/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package prefix contains a kio.Filter implementation of the kustomize 5 | // PrefixTransformer. 6 | package prefix 7 | -------------------------------------------------------------------------------- /api/filters/refvar/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package refvar contains a kio.Filter implementation of the kustomize 5 | // refvar transformer (find and replace $(FOO) style variables in strings). 6 | package refvar 7 | -------------------------------------------------------------------------------- /api/filters/replacement/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package replacement contains a kio.Filter implementation of the kustomize 5 | // replacement transformer (accepts sources and looks for targets to replace 6 | // their values with values from the sources). 7 | package replacement 8 | -------------------------------------------------------------------------------- /api/filters/replicacount/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package replicacount contains a kio.Filter implementation of the kustomize 5 | // ReplicaCountTransformer. 6 | package replicacount 7 | -------------------------------------------------------------------------------- /api/filters/suffix/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package suffix contains a kio.Filter implementation of the kustomize 5 | // SuffixTransformer. 6 | package suffix 7 | -------------------------------------------------------------------------------- /api/internal/builtins/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package builtins holds code generated from the builtin plugins. 5 | // The "builtin" plugins are written as normal plugins and can 6 | // be used as such, but they are also used to generate the code 7 | // in this package so they can be statically linked to client code. 8 | package builtins 9 | -------------------------------------------------------------------------------- /api/internal/konfig/builtinpluginconsts/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package builtinpluginconsts provides builtin plugin 5 | // configuration data. Builtin plugins can also be 6 | // configured individually with plugin config files, 7 | // in which case the constants in this package are ignored. 8 | package builtinpluginconsts 9 | -------------------------------------------------------------------------------- /api/internal/konfig/builtinpluginconsts/images.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package builtinpluginconsts 5 | 6 | const ( 7 | imagesFieldSpecs = ` 8 | images: 9 | - path: spec/containers[]/image 10 | create: true 11 | - path: spec/initContainers[]/image 12 | create: true 13 | - path: spec/volumes[]/image/reference 14 | create: true 15 | - path: spec/template/spec/containers[]/image 16 | create: true 17 | - path: spec/template/spec/initContainers[]/image 18 | create: true 19 | - path: spec/template/spec/volumes[]/image/reference 20 | create: true 21 | ` 22 | ) 23 | -------------------------------------------------------------------------------- /api/internal/konfig/builtinpluginconsts/nameprefix.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package builtinpluginconsts 5 | 6 | const ( 7 | namePrefixFieldSpecs = ` 8 | namePrefix: 9 | - path: metadata/name 10 | ` 11 | ) 12 | -------------------------------------------------------------------------------- /api/internal/konfig/builtinpluginconsts/namespace.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package builtinpluginconsts 5 | 6 | const ( 7 | namespaceFieldSpecs = ` 8 | namespace: 9 | - path: metadata/name 10 | kind: Namespace 11 | create: true 12 | - path: spec/service/namespace 13 | group: apiregistration.k8s.io 14 | kind: APIService 15 | create: true 16 | - path: spec/conversion/webhook/clientConfig/service/namespace 17 | group: apiextensions.k8s.io 18 | kind: CustomResourceDefinition 19 | ` 20 | ) 21 | -------------------------------------------------------------------------------- /api/internal/konfig/builtinpluginconsts/namesuffix.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package builtinpluginconsts 5 | 6 | const ( 7 | nameSuffixFieldSpecs = ` 8 | nameSuffix: 9 | - path: metadata/name 10 | ` 11 | ) 12 | -------------------------------------------------------------------------------- /api/internal/konfig/builtinpluginconsts/replicas.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package builtinpluginconsts 5 | 6 | const replicasFieldSpecs = ` 7 | replicas: 8 | - path: spec/replicas 9 | create: true 10 | kind: Deployment 11 | 12 | - path: spec/replicas 13 | create: true 14 | kind: ReplicationController 15 | 16 | - path: spec/replicas 17 | create: true 18 | kind: ReplicaSet 19 | 20 | - path: spec/replicas 21 | create: true 22 | kind: StatefulSet 23 | ` 24 | -------------------------------------------------------------------------------- /api/internal/konfig/builtinpluginconsts/templatelabels.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package builtinpluginconsts 5 | 6 | const templateLabelFieldSpecs = ` 7 | templateLabels: 8 | ` + metadataLabelsFieldSpecs 9 | -------------------------------------------------------------------------------- /api/internal/loader/errors.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package loader 5 | 6 | import "sigs.k8s.io/kustomize/kyaml/errors" 7 | 8 | var ( 9 | ErrHTTP = errors.Errorf("HTTP Error") 10 | ErrRtNotDir = errors.Errorf("must build at directory") 11 | ) 12 | -------------------------------------------------------------------------------- /api/internal/localizer/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package localizer contains utilities for the command kustomize localize, which is 5 | // documented under proposals/localize-command or at 6 | // https://github.com/kubernetes-sigs/kustomize/blob/master/proposals/22-04-localize-command.md 7 | package localizer 8 | -------------------------------------------------------------------------------- /api/internal/plugins/builtinconfig/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package builtinconfig provides legacy methods for 5 | // configuring builtin plugins from a common config file. 6 | // As a user, its best to configure plugins individually 7 | // with plugin config files specified in the `transformers:` 8 | // or `generators:` field, than to use this legacy 9 | // configuration technique. 10 | package builtinconfig 11 | -------------------------------------------------------------------------------- /api/internal/utils/errtimeout.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package utils 5 | 6 | import ( 7 | "fmt" 8 | "time" 9 | 10 | "sigs.k8s.io/kustomize/kyaml/errors" 11 | ) 12 | 13 | type errTimeOut struct { 14 | duration time.Duration 15 | cmd string 16 | } 17 | 18 | func NewErrTimeOut(d time.Duration, c string) *errTimeOut { 19 | return &errTimeOut{duration: d, cmd: c} 20 | } 21 | 22 | func (e *errTimeOut) Error() string { 23 | return fmt.Sprintf("hit %s timeout running '%s'", e.duration, e.cmd) 24 | } 25 | 26 | func IsErrTimeout(err error) bool { 27 | e := &errTimeOut{} 28 | return errors.As(err, &e) 29 | } 30 | -------------------------------------------------------------------------------- /api/internal/utils/timedcall.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package utils 5 | 6 | import ( 7 | "time" 8 | ) 9 | 10 | // TimedCall runs fn, failing if it doesn't complete in the given duration. 11 | // The description is used in the timeout error message. 12 | func TimedCall(description string, d time.Duration, fn func() error) error { 13 | done := make(chan error, 1) 14 | timer := time.NewTimer(d) 15 | defer timer.Stop() 16 | go func() { done <- fn() }() 17 | select { 18 | case err := <-done: 19 | return err 20 | case <-timer.C: 21 | return NewErrTimeOut(d, description) 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /api/internal/validate/fieldvalidator_test.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package validate_test 5 | -------------------------------------------------------------------------------- /api/konfig/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package konfig provides configuration methods and constants 5 | // for the kustomize API, e.g. the set of file names to look for 6 | // to identify a kustomization root. 7 | package konfig 8 | -------------------------------------------------------------------------------- /api/krusty/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package krusty is intended as the entry point package 5 | // for those seeking to add kustomize ability to other 6 | // programs. 7 | // 8 | // To use, follow the example of the kustomize CLI's 'build' 9 | // command. Also, see the high level tests in this package, 10 | // which serve a dual purpose as examples. 11 | package krusty 12 | -------------------------------------------------------------------------------- /api/krusty/localizer/runner.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package localizer 5 | 6 | import ( 7 | "sigs.k8s.io/kustomize/api/internal/localizer" 8 | "sigs.k8s.io/kustomize/kyaml/errors" 9 | "sigs.k8s.io/kustomize/kyaml/filesys" 10 | ) 11 | 12 | // Run executes `kustomize localize` on fSys given the `localize` arguments and 13 | // returns the path to the created newDir. 14 | func Run(fSys filesys.FileSystem, target, scope, newDir string) (string, error) { 15 | dst, err := localizer.Run(target, scope, newDir, fSys) 16 | return dst, errors.Wrap(err) 17 | } 18 | -------------------------------------------------------------------------------- /api/krusty/testdata/helmcharts/test-chart/Chart.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | appVersion: "1.0" 3 | description: A simple test helm chart. 4 | name: test 5 | version: 1.0.0 6 | -------------------------------------------------------------------------------- /api/krusty/testdata/helmcharts/test-chart/README.md: -------------------------------------------------------------------------------- 1 | This is a simple test chart. -------------------------------------------------------------------------------- /api/krusty/testdata/helmcharts/test-chart/templates/_helpers.tpl: -------------------------------------------------------------------------------- 1 | {{- define "apiversion" -}} 2 | {{- if .Capabilities.APIVersions.Has "foo/v1" -}} 3 | foo/v1 4 | {{- else -}} 5 | apps/v1 6 | {{- end -}} 7 | {{- end -}} -------------------------------------------------------------------------------- /api/krusty/testdata/helmcharts/test-chart/templates/deployment.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | apiVersion: {{ template "apiversion" . }} 3 | kind: Deployment 4 | metadata: 5 | labels: 6 | chart: "{{ .Chart.Name }}-{{ .Chart.Version }}" 7 | name: my-deploy 8 | namespace: {{ .Values.data.namespace }} 9 | spec: 10 | replicas: 1 11 | selector: 12 | matchLabels: 13 | app: {{ .Chart.Name }} 14 | template: 15 | spec: 16 | containers: 17 | - image: "{{ .Values.data.image.name }}:{{ .Values.data.image.tag }}" 18 | imagePullPolicy: {{ .Values.data.image.imagePullPolicy }} -------------------------------------------------------------------------------- /api/krusty/testdata/helmcharts/test-chart/templates/tests/test-pod.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: {{ template "apiversion" . }} 2 | kind: Pod 3 | metadata: 4 | name: {{ .Release.Name }} 5 | annotations: 6 | "helm.sh/hook": test -------------------------------------------------------------------------------- /api/krusty/testdata/helmcharts/test-chart/values.yaml: -------------------------------------------------------------------------------- 1 | data: 2 | namespace: default 3 | image: 4 | name: test-image 5 | tag: v1.0.0 6 | imagePullPolicy: Always 7 | -------------------------------------------------------------------------------- /api/krusty/testdata/helmcharts/valuesFiles/file1.yaml: -------------------------------------------------------------------------------- 1 | data: 2 | image: 3 | name: test-image-file1 4 | tag: file1 5 | imagePullPolicy: Never -------------------------------------------------------------------------------- /api/krusty/testdata/helmcharts/valuesFiles/file2.yaml: -------------------------------------------------------------------------------- 1 | data: 2 | namespace: file-2 -------------------------------------------------------------------------------- /api/krusty/testdata/localize/remote/hpa.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: autoscaling/v2 2 | kind: HorizontalPodAutoscaler 3 | metadata: 4 | name: hpa-deployment 5 | spec: 6 | scaleTargetRef: 7 | apiVersion: apps/v1 8 | kind: Deployment 9 | name: localize-test-deployment-simple 10 | minReplicas: 1 11 | maxReplicas: 10 -------------------------------------------------------------------------------- /api/krusty/testdata/localize/remote/kustomization.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: kustomize.config.k8s.io/v1beta1 2 | kind: Kustomization 3 | 4 | resources: 5 | - https://github.com/kubernetes-sigs/kustomize//api/krusty/testdata/localize/simple?submodules=0&ref=kustomize/v4.5.7&timeout=300 6 | - hpa.yaml 7 | 8 | commonLabels: 9 | purpose: remoteReference 10 | -------------------------------------------------------------------------------- /api/krusty/testdata/localize/simple/deployment.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment 3 | metadata: 4 | name: test-deployment-simple 5 | labels: 6 | app: deployment-simple 7 | spec: 8 | selector: 9 | matchLabels: 10 | app: simple 11 | template: 12 | metadata: 13 | labels: 14 | app: simple 15 | spec: 16 | containers: 17 | - name: nginx 18 | image: nginx:1.16 19 | ports: 20 | - containerPort: 8080 21 | -------------------------------------------------------------------------------- /api/krusty/testdata/localize/simple/kustomization.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: kustomize.config.k8s.io/v1beta1 2 | kind: Kustomization 3 | 4 | resources: 5 | - ./deployment.yaml 6 | - ./service.yaml 7 | 8 | namePrefix: localize- 9 | -------------------------------------------------------------------------------- /api/krusty/testdata/localize/simple/service.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Service 3 | metadata: 4 | name: test-service-simple 5 | spec: 6 | selector: 7 | app: deployment-simple 8 | ports: 9 | - protocol: TCP 10 | port: 80 11 | targetPort: 8080 12 | -------------------------------------------------------------------------------- /api/krusty/testdata/remoteload/multibase/base/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - pod.yaml -------------------------------------------------------------------------------- /api/krusty/testdata/remoteload/multibase/base/pod.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Pod 3 | metadata: 4 | name: myapp-pod 5 | labels: 6 | app: myapp 7 | spec: 8 | containers: 9 | - name: nginx 10 | image: nginx:1.7.9 11 | -------------------------------------------------------------------------------- /api/krusty/testdata/remoteload/multibase/dev/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - ../base 3 | namePrefix: dev- 4 | -------------------------------------------------------------------------------- /api/krusty/testdata/remoteload/simple/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - pod.yaml -------------------------------------------------------------------------------- /api/krusty/testdata/remoteload/simple/pod.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Pod 3 | metadata: 4 | name: myapp-pod 5 | labels: 6 | app: myapp 7 | spec: 8 | containers: 9 | - name: nginx 10 | image: nginx:1.7.9 11 | -------------------------------------------------------------------------------- /api/krusty/testdata/remoteload/with-submodule/README.md: -------------------------------------------------------------------------------- 1 | # submodule 2 | 3 | This repo demonstrates kustomize's ability to download git repos 4 | with submodules. The following branches contain 5 | * main: submodule via absolute path 6 | * relative-submodule: submodule via relative path 7 | 8 | For the submodule accessed via a relative path, we include a random hash in the 9 | submodule name to avoid accessing an unintended directory in the case kustomize 10 | contains loader bugs (issue #5131). -------------------------------------------------------------------------------- /api/main.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // A dummy main to help with releasing the kustomize API module. 5 | package main 6 | 7 | import ( 8 | "fmt" 9 | 10 | "sigs.k8s.io/kustomize/api/provenance" 11 | ) 12 | 13 | // TODO: delete this when we find a better way to generate release notes. 14 | func main() { 15 | fmt.Println(`This 'main' exists only to create release notes for the API.`) 16 | fmt.Println(provenance.GetProvenance()) 17 | } 18 | -------------------------------------------------------------------------------- /api/pkg/util/image.go: -------------------------------------------------------------------------------- 1 | // Copyright 2024 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package util 5 | 6 | import ( 7 | "sigs.k8s.io/kustomize/api/internal/image" 8 | ) 9 | 10 | // Splits image string name into name, tag and digest 11 | func SplitImageName(imageName string) (name string, tag string, digest string) { 12 | return image.Split(imageName) 13 | } 14 | -------------------------------------------------------------------------------- /api/resmap/resmap_test.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package resmap_test 5 | 6 | // See reswrangler_test.go 7 | -------------------------------------------------------------------------------- /api/resource/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package resource implements representations of k8s API resources. 5 | package resource 6 | -------------------------------------------------------------------------------- /api/resource/idset.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package resource 5 | 6 | import "sigs.k8s.io/kustomize/kyaml/resid" 7 | 8 | type IdSet struct { 9 | ids map[resid.ResId]bool 10 | } 11 | 12 | func MakeIdSet(slice []*Resource) *IdSet { 13 | set := make(map[resid.ResId]bool) 14 | for _, r := range slice { 15 | id := r.CurId() 16 | if _, ok := set[id]; !ok { 17 | set[id] = true 18 | } 19 | } 20 | return &IdSet{ids: set} 21 | } 22 | 23 | func (s IdSet) Contains(id resid.ResId) bool { 24 | _, ok := s.ids[id] 25 | return ok 26 | } 27 | 28 | func (s IdSet) Size() int { 29 | return len(s.ids) 30 | } 31 | -------------------------------------------------------------------------------- /api/types/configmapargs.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package types 5 | 6 | // ConfigMapArgs contains the metadata of how to generate a configmap. 7 | type ConfigMapArgs struct { 8 | // GeneratorArgs for the configmap. 9 | GeneratorArgs `json:",inline,omitempty" yaml:",inline,omitempty"` 10 | } 11 | -------------------------------------------------------------------------------- /api/types/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package types holds the definition of the kustomization struct and 5 | // supporting structs. It's the k8s API conformant object that describes 6 | // a set of generation and transformation operations to create and/or 7 | // modify k8s resources. 8 | // A kustomization file is a serialization of this struct. 9 | package types 10 | -------------------------------------------------------------------------------- /api/types/loadrestrictions.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package types 5 | 6 | // Restrictions on what things can be referred to 7 | // in a kustomization file. 8 | // 9 | //go:generate stringer -type=LoadRestrictions 10 | type LoadRestrictions int 11 | 12 | const ( 13 | LoadRestrictionsUnknown LoadRestrictions = iota 14 | 15 | // Files referenced by a kustomization file must be in 16 | // or under the directory holding the kustomization 17 | // file itself. 18 | LoadRestrictionsRootOnly 19 | 20 | // The kustomization file may specify absolute or 21 | // relative paths to patch or resources files outside 22 | // its own tree. 23 | LoadRestrictionsNone 24 | ) 25 | -------------------------------------------------------------------------------- /api/types/objectmeta.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package types 5 | 6 | // ObjectMeta partially copies apimachinery/pkg/apis/meta/v1.ObjectMeta 7 | // No need for a direct dependence; the fields are stable. 8 | type ObjectMeta struct { 9 | Name string `json:"name,omitempty" yaml:"name,omitempty"` 10 | Namespace string `json:"namespace,omitempty" yaml:"namespace,omitempty"` 11 | Labels map[string]string `json:"labels,omitempty" yaml:"labels,omitempty"` 12 | Annotations map[string]string `json:"annotations,omitempty" yaml:"annotations,omitempty"` 13 | } 14 | -------------------------------------------------------------------------------- /api/types/pair.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package types 5 | 6 | // Pair is a key value pair. 7 | type Pair struct { 8 | Key string 9 | Value string 10 | } 11 | -------------------------------------------------------------------------------- /api/types/patchstrategicmerge.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package types 5 | 6 | // PatchStrategicMerge represents a relative path to a 7 | // stategic merge patch with the format 8 | // https://github.com/kubernetes/community/blob/master/contributors/devel/sig-api-machinery/strategic-merge-patch.md 9 | type PatchStrategicMerge string 10 | -------------------------------------------------------------------------------- /api/types/replacementfield.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package types 5 | 6 | type ReplacementField struct { 7 | Replacement `json:",inline,omitempty" yaml:",inline,omitempty"` 8 | Path string `json:"path,omitempty" yaml:"path,omitempty"` 9 | } 10 | -------------------------------------------------------------------------------- /api/types/replica.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package types 5 | 6 | // Replica specifies a modification to a replica config. 7 | // The number of replicas of a resource whose name matches will be set to count. 8 | // This struct is used by the ReplicaCountTransform, and is meant to supplement 9 | // the existing patch functionality with a simpler syntax for replica configuration. 10 | type Replica struct { 11 | // The name of the resource to change the replica count 12 | Name string `json:"name,omitempty" yaml:"name,omitempty"` 13 | 14 | // The number of replicas required. 15 | Count int64 `json:"count" yaml:"count"` 16 | } 17 | -------------------------------------------------------------------------------- /api/types/secretargs.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package types 5 | 6 | // SecretArgs contains the metadata of how to generate a secret. 7 | type SecretArgs struct { 8 | // GeneratorArgs for the secret. 9 | GeneratorArgs `json:",inline,omitempty" yaml:",inline,omitempty"` 10 | 11 | // Type of the secret. 12 | // 13 | // This is the same field as the secret type field in v1/Secret: 14 | // It can be "Opaque" (default), or "kubernetes.io/tls". 15 | // 16 | // If type is "kubernetes.io/tls", then "literals" or "files" must have exactly two 17 | // keys: "tls.key" and "tls.crt" 18 | Type string `json:"type,omitempty" yaml:"type,omitempty"` 19 | } 20 | -------------------------------------------------------------------------------- /api/types/typemeta.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package types 5 | 6 | // TypeMeta partially copies apimachinery/pkg/apis/meta/v1.TypeMeta 7 | // No need for a direct dependence; the fields are stable. 8 | type TypeMeta struct { 9 | Kind string `json:"kind,omitempty" yaml:"kind,omitempty"` 10 | APIVersion string `json:"apiVersion,omitempty" yaml:"apiVersion,omitempty"` 11 | } 12 | -------------------------------------------------------------------------------- /cmd/config/README.md: -------------------------------------------------------------------------------- 1 | # cmd/config 2 | 3 | This package exists to expose config filters directly as cli commands for the purposes 4 | of development of the kyaml package and as a reference implementation for using the libraries. 5 | 6 | ## Docs 7 | 8 | All documentation is also built directly into the `config` command group using 9 | `kustomize help cfg`. 10 | 11 | - [tutorials](docs/tutorials) 12 | - [commands](docs/commands) 13 | - [api-conventions](docs/api-conventions) 14 | 15 | ## Build Command 16 | 17 | Build the `config` command under `GOBIN` 18 | 19 | $ make 20 | 21 | ## Run Tests 22 | 23 | Run all tests, linting, etc and build 24 | 25 | $ make all -------------------------------------------------------------------------------- /cmd/config/configcobra/cfg.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package configcobra 5 | 6 | import ( 7 | "github.com/spf13/cobra" 8 | "sigs.k8s.io/kustomize/cmd/config/internal/commands" 9 | ) 10 | 11 | func GetCfg(name string) *cobra.Command { 12 | cmd := &cobra.Command{ 13 | Use: "cfg", 14 | Short: "Commands for reading and writing configuration", 15 | } 16 | 17 | cmd.AddCommand(commands.CatCommand(name)) 18 | cmd.AddCommand(commands.CountCommand(name)) 19 | cmd.AddCommand(commands.GrepCommand(name)) 20 | cmd.AddCommand(commands.TreeCommand(name)) 21 | 22 | return cmd 23 | } 24 | -------------------------------------------------------------------------------- /cmd/config/configcobra/example_test.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package configcobra_test 5 | 6 | import ( 7 | "os" 8 | 9 | "github.com/spf13/cobra" 10 | "sigs.k8s.io/kustomize/cmd/config/configcobra" 11 | "sigs.k8s.io/kustomize/kyaml/commandutil" 12 | ) 13 | 14 | // ExampleAddCommands demonstrates how to embed the config command as a command inside 15 | // another group. 16 | func ExampleAddCommands() { 17 | // enable the config commands 18 | os.Setenv(commandutil.EnableAlphaCommmandsEnvName, "true") 19 | _ = configcobra.AddCommands(&cobra.Command{ 20 | Use: "my-cmd", 21 | Short: "My command.", 22 | Long: `My command.`, 23 | }, "my-cmd") 24 | } 25 | -------------------------------------------------------------------------------- /cmd/config/configcobra/fn.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package configcobra 5 | 6 | import ( 7 | "github.com/spf13/cobra" 8 | "sigs.k8s.io/kustomize/cmd/config/internal/commands" 9 | ) 10 | 11 | func GetFn(name string) *cobra.Command { 12 | cmd := &cobra.Command{ 13 | Use: "fn", 14 | Short: "Commands for running functions against configuration", 15 | } 16 | 17 | cmd.AddCommand(commands.RunCommand(name)) 18 | return cmd 19 | } 20 | -------------------------------------------------------------------------------- /cmd/config/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | //go:generate $GOBIN/mdtogo docs/api-conventions internal/generateddocs/api --full=true --license=none 5 | //go:generate $GOBIN/mdtogo docs/tutorials internal/generateddocs/tutorials --full=true --license=none 6 | //go:generate $GOBIN/mdtogo docs/commands internal/generateddocs/commands --license=none 7 | package config 8 | -------------------------------------------------------------------------------- /cmd/config/docs/api-conventions/manifest-annotations.md: -------------------------------------------------------------------------------- 1 | # Manifest Annotations 2 | 3 | This document lists the annotations that can be declared in resource manifests. 4 | 5 | ### `config.kubernetes.io/local-config` 6 | 7 | A value of `"true"` for this annotation declares that the resource is only consumed by 8 | client-side tooling and should not be applied to the API server. 9 | 10 | A value of `"false"` can be used to declare that a resource should be applied to 11 | the API server even when it is assumed to be local. 12 | -------------------------------------------------------------------------------- /cmd/config/docs/commands/annotate.md: -------------------------------------------------------------------------------- 1 | ## annotate 2 | 3 | [Alpha] Set an annotation on Resources. 4 | 5 | ### Synopsis 6 | 7 | [Alpha] Set an annotation on Resources. 8 | 9 | DIR: 10 | Path to local directory. 11 | 12 | ### Examples 13 | 14 | kustomize cfg annotate my-dir/ --kv foo=bar 15 | 16 | kustomize cfg annotate my-dir/ --kv foo=bar --kv a=b 17 | 18 | kustomize cfg annotate my-dir/ --kv foo=bar --kind Deployment --name foo 19 | -------------------------------------------------------------------------------- /cmd/config/docs/commands/cat.md: -------------------------------------------------------------------------------- 1 | ## cat 2 | 3 | [Alpha] Print Resource Config from a local directory. 4 | 5 | ### Synopsis 6 | 7 | [Alpha] Print Resource Config from a local directory. 8 | 9 | DIR: 10 | Path to local directory. 11 | 12 | ### Examples 13 | 14 | # print Resource config from a directory 15 | kustomize cfg cat my-dir/ 16 | 17 | # wrap Resource config from a directory in an ResourceList 18 | kustomize cfg cat my-dir/ --wrap-kind ResourceList --wrap-version config.kubernetes.io/v1alpha1 --function-config fn.yaml 19 | 20 | # unwrap Resource config from a directory in an ResourceList 21 | ... | kustomize cfg cat 22 | -------------------------------------------------------------------------------- /cmd/config/docs/commands/completion.md: -------------------------------------------------------------------------------- 1 | ## completion 2 | 3 | Generate shell completion. 4 | 5 | ### Synopsis 6 | 7 | Generate shell completion for `kustomize` -- supports bash, zsh, fish and powershell. 8 | 9 | ### Examples 10 | 11 | # load completion for Bash 12 | source <(kustomize completion bash) 13 | 14 | # install for Bash in Linux 15 | kustomize completion bash > /etc/bash_completion.d/kustomize 16 | 17 | # install for Bash in MacOS 18 | kustomize completion bash > /usr/local/etc/bash_completion.d/kustomize 19 | 20 | # package for Bash 21 | kustomize completion bash > /usr/share/bash-completion/completions/kustomize 22 | 23 | # package for zsh 24 | kustomize completion zsh > /usr/share/zsh/site-functions/_kustomize 25 | 26 | -------------------------------------------------------------------------------- /cmd/config/docs/commands/count.md: -------------------------------------------------------------------------------- 1 | ## count 2 | 3 | [Alpha] Count Resources Config from a local directory. 4 | 5 | ### Synopsis 6 | 7 | [Alpha] Count Resources Config from a local directory. 8 | 9 | DIR: 10 | Path to local directory. 11 | 12 | ### Examples 13 | 14 | # print Resource counts from a directory 15 | kustomize cfg count my-dir/ -------------------------------------------------------------------------------- /cmd/config/docs/commands/init.md: -------------------------------------------------------------------------------- 1 | ## init 2 | 3 | [Alpha] Initialize a directory with a Krmfile. 4 | 5 | ### Synopsis 6 | 7 | [Alpha] Initialize a directory with a Krmfile. 8 | 9 | DIR: 10 | Path to local directory. 11 | 12 | ### Examples 13 | 14 | # create a Krmfile in the local directory 15 | kustomize cfg init 16 | 17 | # create a Krmfile in my-dir/ 18 | kustomize cfg init my-dir/ 19 | -------------------------------------------------------------------------------- /cmd/config/docs/commands/list-setters.md: -------------------------------------------------------------------------------- 1 | ## set 2 | 3 | [Alpha] List setters for Resources. 4 | 5 | ### Synopsis 6 | 7 | List setters for Resources. 8 | 9 | DIR 10 | 11 | A directory containing Resource configuration. 12 | 13 | NAME 14 | 15 | Optional. The name of the setter to display. 16 | 17 | ### Examples 18 | 19 | Show setters: 20 | 21 | $ kustomize cfg list-setters DIR/ 22 | NAME DESCRIPTION VALUE TYPE COUNT SETBY 23 | name-prefix '' PREFIX string 2 24 | -------------------------------------------------------------------------------- /cmd/config/docs/commands/sink.md: -------------------------------------------------------------------------------- 1 | ## sink 2 | 3 | [Alpha] Implement a Sink by writing input to a local directory. 4 | 5 | ### Synopsis 6 | 7 | [Alpha] Implement a Sink by writing input to a local directory. 8 | 9 | kustomize fn sink [DIR] 10 | 11 | DIR: 12 | Path to local directory. If unspecified, sink will write to stdout as if it were a single file. 13 | 14 | `sink` writes its input to a directory 15 | 16 | ### Examples 17 | 18 | kustomize fn source DIR/ | your-function | kustomize fn sink DIR/ 19 | -------------------------------------------------------------------------------- /cmd/config/docs/commands/source.md: -------------------------------------------------------------------------------- 1 | ## source 2 | 3 | [Alpha] Implement a Source by reading a local directory. 4 | 5 | ### Synopsis 6 | 7 | [Alpha] Implement a Source by reading a local directory. 8 | 9 | kustomize fn source DIR... 10 | 11 | DIR: 12 | One or more paths to local directories. Contents from directories will be concatenated. 13 | If no directories are provided, source will read from stdin as if it were a single file. 14 | 15 | `source` emits configuration to act as input to a function 16 | 17 | ### Examples 18 | 19 | # emity configuration directory as input source to a function 20 | kustomize fn source DIR/ 21 | 22 | kustomize fn source DIR/ | your-function | kustomize fn sink DIR/ 23 | -------------------------------------------------------------------------------- /cmd/config/ext/ext.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package ext 5 | 6 | // KRMFileName returns the name of the KRM file. KRM file determines package 7 | // boundaries and contains the openapi information for a package. 8 | var KRMFileName = func() string { 9 | return "Krmfile" 10 | } 11 | -------------------------------------------------------------------------------- /cmd/config/fixgomod.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # Copyright 2019 The Kubernetes Authors. 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | set -e 6 | 7 | : "${kyaml_major?Need to source VERSIONS}" 8 | : "${kyaml_minor?Need to source VERSIONS}" 9 | : "${kyaml_patch?Need to source VERSIONS}" 10 | 11 | go mod edit -dropreplace=sigs.k8s.io/kustomize/kyaml@v0.0.0 12 | go mod edit -dropreplace=sigs.k8s.io/kustomize/kyaml@v0.1.13 13 | go mod edit -require=sigs.k8s.io/kustomize/kyaml@v$kyaml_major.$kyaml_minor.$kyaml_patch 14 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/e2e/e2econtainerconfig/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | FROM public.ecr.aws/docker/library/golang:1.22.7-bullseye 5 | ENV CGO_ENABLED=0 6 | WORKDIR /go/src/ 7 | 8 | # download modules 9 | # COPY go.mod go.mod 10 | # COPY go.sum go.sum 11 | # RUN go mod download 12 | 13 | COPY . . 14 | RUN go build -v -o /usr/local/bin/function ./cmd/config/internal/commands/e2e/e2econtainerconfig 15 | 16 | FROM alpine:latest 17 | COPY --from=0 /usr/local/bin/function /usr/local/bin/function 18 | CMD ["function"] 19 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/e2e/e2econtainerconfig/Makefile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | include ../../../../../../Makefile-modules.mk 5 | 6 | .PHONY: image 7 | image: 8 | docker build . -t gcr.io/kustomize-functions/e2econtainerconfig 9 | docker push gcr.io/kustomize-functions/e2econtainerconfig 10 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/e2e/e2econtainerconfig/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package main contains a function to be used for e2e testing. 5 | // 6 | // The function is written using the framework, and parses the ResourceList.functionConfig 7 | // into a go struct. 8 | // 9 | // The function will set 3 annotations on each resource. 10 | // 11 | // See https://github.com/kubernetes-sigs/kustomize/blob/master/cmd/config/docs/api-conventions/functions-spec.md 12 | package main 13 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/e2e/e2econtainerenvgenerator/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | FROM public.ecr.aws/docker/library/golang:1.22.7-bullseye 5 | ENV CGO_ENABLED=0 6 | WORKDIR /go/src/ 7 | 8 | # download modules 9 | # COPY go.mod go.mod 10 | # COPY go.sum go.sum 11 | # RUN go mod download 12 | 13 | COPY . . 14 | RUN go build -v -o /usr/local/bin/function ./cmd/config/internal/commands/e2e/e2econtainerenvgenerator 15 | 16 | FROM alpine:latest 17 | COPY --from=0 /usr/local/bin/function /usr/local/bin/function 18 | CMD ["function"] 19 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/e2e/e2econtainerenvgenerator/Makefile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | include ../../../../../../Makefile-modules.mk 5 | 6 | .PHONY: image 7 | image: 8 | docker build . -t gcr.io/kustomize-functions/e2econtainerenvgenerator 9 | docker push gcr.io/kustomize-functions/e2econtainerenvgenerator 10 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/e2e/e2econtainerenvgenerator/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package main contains a function to be used for e2e testing. 5 | // See https://github.com/kubernetes-sigs/kustomize/blob/master/cmd/config/docs/api-conventions/functions-spec.md 6 | package main 7 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/e2e/e2econtainermountbind/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | FROM public.ecr.aws/docker/library/golang:1.22.7-bullseye 5 | ENV CGO_ENABLED=0 6 | WORKDIR /go/src/ 7 | 8 | # download modules 9 | # COPY go.mod go.mod 10 | # COPY go.sum go.sum 11 | # RUN go mod download 12 | 13 | COPY . . 14 | RUN go build -v -o /usr/local/bin/function ./cmd/config/internal/commands/e2e/e2econtainermountbind 15 | 16 | FROM alpine:latest 17 | COPY --from=0 /usr/local/bin/function /usr/local/bin/function 18 | CMD ["function"] 19 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/e2e/e2econtainermountbind/Makefile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | include ../../../../../../Makefile-modules.mk 5 | 6 | .PHONY: image 7 | image: 8 | docker build . -t gcr.io/kustomize-functions/e2econtainermountbind 9 | docker push gcr.io/kustomize-functions/e2econtainermountbind 10 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/e2e/e2econtainersimplegenerator/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | FROM public.ecr.aws/docker/library/golang:1.22.7-bullseye 5 | ENV CGO_ENABLED=0 6 | WORKDIR /go/src/ 7 | 8 | # download modules 9 | # COPY go.mod go.mod 10 | # COPY go.sum go.sum 11 | # RUN go mod download 12 | 13 | COPY . . 14 | RUN go build -v -o /usr/local/bin/function ./cmd/config/internal/commands/e2e/e2econtainersimplegenerator 15 | 16 | FROM alpine:latest 17 | COPY --from=0 /usr/local/bin/function /usr/local/bin/function 18 | CMD ["function"] 19 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/e2e/e2econtainersimplegenerator/Makefile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | include ../../../../../../Makefile-modules.mk 5 | 6 | .PHONY: image 7 | image: 8 | docker build . -t gcr.io/kustomize-functions/e2econtainersimplegenerator 9 | docker push gcr.io/kustomize-functions/e2econtainersimplegenerator 10 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/e2e/e2econtainersimplegenerator/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package main contains a function to be used for e2e testing. 5 | // See https://github.com/kubernetes-sigs/kustomize/blob/master/cmd/config/docs/api-conventions/functions-spec.md 6 | package main 7 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/e2e/starlark/annotate.star: -------------------------------------------------------------------------------- 1 | def run(r, fc): 2 | for resource in r: 3 | resource["metadata"]["annotations"]["a-string-value"] = fc["data"]["stringValue"] 4 | resource["metadata"]["annotations"]["a-int-value"] = fc["data"]["intValue"] 5 | resource["metadata"]["annotations"]["a-bool-value"] = fc["data"]["boolValue"] 6 | 7 | run(ctx.resource_list["items"], ctx.resource_list["functionConfig"]) 8 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/internal/k8sgen/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // All code below this directory is generated. 5 | // See {repo}/cmd/k8scopy/main.go for more info. 6 | //go:generate k8scopy k8scopy.yaml internal/commands 7 | package k8sgen 8 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/internal/k8sgen/k8scopy.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2020 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | # The files to vendor (copy). 5 | # See {repo}/cmd/k8scopy/main.go for more info. 6 | module: k8s.io/apimachinery 7 | version: v0.19.8 8 | packages: 9 | - name: pkg/api/resource 10 | files: 11 | - amount.go 12 | - math.go 13 | - quantity.go 14 | - scale_int.go 15 | - suffix.go 16 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/test/override.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | 5 | 6 | apiVersion: apps/v1 7 | kind: Deployment 8 | metadata: 9 | name: test 10 | spec: 11 | template: 12 | spec: 13 | containers: 14 | - name: test 15 | image: nginx:v1.9 16 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/test/testdata/dataset-with-setters/mysql/deployment.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | namespace: myspace # {"$openapi":"namespace"} 8 | name: mysql-deployment 9 | spec: 10 | replicas: 3 11 | template: 12 | spec: 13 | containers: 14 | - name: mysql 15 | image: mysql:1.7.9 # {"$openapi":"image-tag"} 16 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/test/testdata/dataset-with-setters/mysql/nosetters/Krmfile: -------------------------------------------------------------------------------- 1 | apiVersion: krm.dev/v1alpha1 2 | kind: Krmfile 3 | metadata: 4 | name: storage 5 | packageMetadata: 6 | shortDescription: sample description 7 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/test/testdata/dataset-with-setters/mysql/nosetters/deployment.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | namespace: myspace 8 | name: nosetters-deployment 9 | spec: 10 | replicas: 4 11 | template: 12 | spec: 13 | containers: 14 | - name: nosetters 15 | image: nosetters:1.7.7 16 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/test/testdata/dataset-with-setters/mysql/storage/Krmfile: -------------------------------------------------------------------------------- 1 | apiVersion: krm.dev/v1alpha1 2 | kind: Krmfile 3 | metadata: 4 | name: storage 5 | packageMetadata: 6 | shortDescription: sample description 7 | openAPI: 8 | definitions: 9 | io.k8s.cli.setters.namespace: 10 | x-k8s-cli: 11 | setter: 12 | name: namespace 13 | value: myspace 14 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/test/testdata/dataset-with-setters/mysql/storage/deployment.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | namespace: myspace # {"$openapi":"namespace"} 8 | name: storage-deployment 9 | spec: 10 | replicas: 4 11 | template: 12 | spec: 13 | containers: 14 | - name: storage 15 | image: storage:1.7.7 16 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/test/testdata/dataset-without-setters/mysql/Krmfile: -------------------------------------------------------------------------------- 1 | apiVersion: krm.dev/v1alpha1 2 | kind: Krmfile 3 | metadata: 4 | name: mysql 5 | packageMetadata: 6 | shortDescription: sample description -------------------------------------------------------------------------------- /cmd/config/internal/commands/test/testdata/dataset-without-setters/mysql/deployment.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | namespace: myspace 8 | name: mysql-deployment 9 | spec: 10 | replicas: 3 11 | template: 12 | spec: 13 | containers: 14 | - name: mysql 15 | image: mysql:1.7.9 16 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/test/testdata/dataset-without-setters/mysql/storage/Krmfile: -------------------------------------------------------------------------------- 1 | apiVersion: krm.dev/v1alpha1 2 | kind: Krmfile 3 | metadata: 4 | name: storage 5 | packageMetadata: 6 | shortDescription: sample description 7 | -------------------------------------------------------------------------------- /cmd/config/internal/commands/test/testdata/dataset-without-setters/mysql/storage/deployment.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | namespace: myspace 8 | name: storage-deployment 9 | spec: 10 | replicas: 4 11 | template: 12 | spec: 13 | containers: 14 | - name: storage 15 | image: storage:1.7.7 16 | -------------------------------------------------------------------------------- /cmd/config/kubectl-krm/main.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package main 5 | 6 | import ( 7 | "os" 8 | 9 | "github.com/spf13/cobra" 10 | 11 | "sigs.k8s.io/kustomize/cmd/config/configcobra" 12 | "sigs.k8s.io/kustomize/kyaml/commandutil" 13 | ) 14 | 15 | func main() { 16 | os.Setenv(commandutil.EnableAlphaCommmandsEnvName, "true") 17 | cmd := configcobra.AddCommands(&cobra.Command{ 18 | Use: "kubectl-krm", 19 | Short: "Plugin for configuration based commands.", 20 | Long: `Plugin for configuration based commands. 21 | 22 | Provides commands for working with Kubernetes resource configuration. 23 | `, 24 | }, "") 25 | if err := cmd.Execute(); err != nil { 26 | os.Exit(1) 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /cmd/depprobcheck/Makefile: -------------------------------------------------------------------------------- 1 | # Copyright 2022 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | include ../../Makefile-modules.mk 5 | 6 | lint: 7 | echo "Skipping lint for broken module depprobcheck" 8 | 9 | test: 10 | echo "Skipping test for broken module depprobcheck" 11 | 12 | build: 13 | echo "Skipping build for broken module depprobcheck" 14 | -------------------------------------------------------------------------------- /cmd/depprobcheck/main.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package main 5 | 6 | import ( 7 | "fmt" 8 | 9 | "k8s.io/cli-runtime/pkg/genericclioptions" 10 | "k8s.io/kube-openapi/pkg/validation/spec" 11 | //"github.com/go-openapi/swag" 12 | ) 13 | 14 | func main() { 15 | //hey := yaml.TypeMeta{} 16 | //fmt.Printf("%v\n", hey) 17 | 18 | // fmt.Printf("%v\n", swag.BooleanProperty()) 19 | 20 | genericclioptions.NewConfigFlags(true) 21 | fmt.Printf("%v\n", spec.Schema{}) 22 | } 23 | -------------------------------------------------------------------------------- /cmd/gorepomod/Makefile: -------------------------------------------------------------------------------- 1 | MYGOBIN = $(shell go env GOBIN) 2 | ifeq ($(MYGOBIN),) 3 | MYGOBIN = $(shell go env GOPATH)/bin 4 | endif 5 | 6 | include ../../Makefile-modules.mk 7 | 8 | $(MYGOBIN)/gorepomod: usage.go 9 | go install . 10 | 11 | .PHONY: test 12 | test: $(MYGOBIN)/gorepomod 13 | go test -v ./... 14 | 15 | usage.go: README.md $(MYGOBIN)/goimports 16 | go generate . 17 | $(MYGOBIN)/goimports -w usage.go 18 | -------------------------------------------------------------------------------- /cmd/gorepomod/internal/misc/trackedrepo.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package misc 5 | 6 | // TrackedRepo identifies a git remote repository. 7 | type TrackedRepo string 8 | -------------------------------------------------------------------------------- /cmd/gorepomod/internal/mod/module_test.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package mod_test 5 | -------------------------------------------------------------------------------- /cmd/gorepomod/internal/repo/dotgitdata_test.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package repo 5 | 6 | import ( 7 | "testing" 8 | ) 9 | 10 | func TestLoadRepoManager(t *testing.T) { 11 | t.Skip() 12 | } 13 | -------------------------------------------------------------------------------- /cmd/gorepomod/internal/semver/svbump.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package semver 5 | 6 | type SvBump int 7 | 8 | const ( 9 | Patch SvBump = iota 10 | Minor 11 | Major 12 | ) 13 | 14 | func (b SvBump) String() string { 15 | return map[SvBump]string{ 16 | Patch: "Patch", 17 | Minor: "Minor", 18 | Major: "Major", 19 | }[b] 20 | } 21 | -------------------------------------------------------------------------------- /cmd/k8scopy/Makefile: -------------------------------------------------------------------------------- 1 | ../../Makefile-modules.mk -------------------------------------------------------------------------------- /cmd/k8scopy/go.mod: -------------------------------------------------------------------------------- 1 | module sigs.k8s.io/kustomize/cmd/k8scopy 2 | 3 | go 1.22.7 4 | 5 | require ( 6 | github.com/stretchr/testify v1.10.0 7 | sigs.k8s.io/yaml v1.5.0 8 | ) 9 | 10 | require ( 11 | github.com/davecgh/go-spew v1.1.1 // indirect 12 | github.com/google/go-cmp v0.6.0 // indirect 13 | github.com/kr/pretty v0.3.1 // indirect 14 | github.com/pmezard/go-difflib v1.0.0 // indirect 15 | github.com/rogpeppe/go-internal v1.12.0 // indirect 16 | go.yaml.in/yaml/v2 v2.4.2 // indirect 17 | gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect 18 | gopkg.in/yaml.v3 v3.0.1 // indirect 19 | ) 20 | -------------------------------------------------------------------------------- /cmd/mdtogo/Makefile: -------------------------------------------------------------------------------- 1 | ../../Makefile-modules.mk -------------------------------------------------------------------------------- /cmd/mdtogo/go.mod: -------------------------------------------------------------------------------- 1 | module sigs.k8s.io/kustomize/cmd/mdtogo 2 | 3 | go 1.22.7 4 | -------------------------------------------------------------------------------- /cmd/mdtogo/go.sum: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/cmd/mdtogo/go.sum -------------------------------------------------------------------------------- /cmd/pluginator/Makefile: -------------------------------------------------------------------------------- 1 | .PHONY: test all clean generate run 2 | 3 | FUNC_WRAPPER_SRC_DIR = funcwrappersrc 4 | FUNC_WRAPPER_DST_DIR = funcwrapper 5 | 6 | include ../../Makefile-modules.mk 7 | 8 | all: test build 9 | 10 | test: 11 | go test -v ./... 12 | 13 | build: 14 | go build -o $(MYGOBIN) main.go 15 | 16 | install: 17 | go install . 18 | 19 | run: 20 | go run . $(ARGS) 21 | 22 | clean: 23 | rm -f pluginator 24 | -------------------------------------------------------------------------------- /cmd/pluginator/internal/krmfunction/funcwrappersrc/fakeplugin.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package funcwrappersrc 5 | 6 | import ( 7 | "sigs.k8s.io/kustomize/api/resmap" 8 | ) 9 | 10 | type plugin struct{} 11 | 12 | var KustomizePlugin plugin //nolint:gochecknoglobals 13 | 14 | func (p *plugin) Config( 15 | _ *resmap.PluginHelpers, _ []byte) (err error) { 16 | return nil 17 | } 18 | 19 | func (p *plugin) Transform(_ resmap.ResMap) error { 20 | return nil 21 | } 22 | -------------------------------------------------------------------------------- /cmd/pluginator/internal/krmfunction/funcwrappersrc/go.mod.src: -------------------------------------------------------------------------------- 1 | module main 2 | 3 | go 1.22.7 4 | 5 | require ( 6 | github.com/spf13/cobra v1.4.0 7 | sigs.k8s.io/kustomize/api v0.12.1 8 | sigs.k8s.io/kustomize/kyaml v0.13.9 9 | sigs.k8s.io/yaml v1.2.0 10 | ) 11 | -------------------------------------------------------------------------------- /code-of-conduct.md: -------------------------------------------------------------------------------- 1 | # Kubernetes Community Code of Conduct 2 | 3 | Please refer to our [Kubernetes Community Code of Conduct](https://git.k8s.io/community/code-of-conduct.md) 4 | -------------------------------------------------------------------------------- /examples/helloWorld/configMap.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: ConfigMap 3 | metadata: 4 | name: the-map 5 | data: 6 | altGreeting: "Good Morning!" 7 | enableRisky: "false" 8 | -------------------------------------------------------------------------------- /examples/helloWorld/kustomization.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: kustomize.config.k8s.io/v1beta1 2 | kind: Kustomization 3 | metadata: 4 | name: arbitrary 5 | 6 | # Example configuration for the webserver 7 | # at https://github.com/monopole/hello 8 | commonLabels: 9 | app: hello 10 | 11 | resources: 12 | - deployment.yaml 13 | - service.yaml 14 | - configMap.yaml 15 | -------------------------------------------------------------------------------- /examples/helloWorld/service.yaml: -------------------------------------------------------------------------------- 1 | kind: Service 2 | apiVersion: v1 3 | metadata: 4 | name: the-service 5 | spec: 6 | selector: 7 | deployment: hello 8 | type: LoadBalancer 9 | ports: 10 | - protocol: TCP 11 | port: 8666 12 | targetPort: 8080 13 | -------------------------------------------------------------------------------- /examples/ldap/base/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - deployment.yaml 3 | - service.yaml 4 | configMapGenerator: 5 | - name: ldap-configmap 6 | files: 7 | - env.startup.txt 8 | -------------------------------------------------------------------------------- /examples/ldap/base/service.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Service 3 | metadata: 4 | labels: 5 | app: ldap 6 | name: ldap-service 7 | spec: 8 | ports: 9 | - port: 389 10 | selector: 11 | app: ldap 12 | -------------------------------------------------------------------------------- /examples/ldap/overlays/production/deployment.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment 3 | metadata: 4 | name: ldap 5 | spec: 6 | replicas: 6 7 | template: 8 | spec: 9 | volumes: 10 | - name: ldap-data 11 | emptyDir: null 12 | gcePersistentDisk: 13 | pdName: ldap-persistent-storage 14 | -------------------------------------------------------------------------------- /examples/ldap/overlays/production/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - ../../base 3 | patches: 4 | - path: deployment.yaml 5 | namePrefix: production- 6 | -------------------------------------------------------------------------------- /examples/ldap/overlays/staging/config.env: -------------------------------------------------------------------------------- 1 | DB_USERNAME=admin 2 | DB_PASSWORD=somepw 3 | -------------------------------------------------------------------------------- /examples/ldap/overlays/staging/deployment.yaml: -------------------------------------------------------------------------------- 1 | 2 | apiVersion: apps/v1 3 | kind: Deployment 4 | metadata: 5 | name: ldap 6 | spec: 7 | replicas: 2 8 | -------------------------------------------------------------------------------- /examples/ldap/overlays/staging/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - ../../base 3 | patches: 4 | - path: deployment.yaml 5 | namePrefix: staging- 6 | configMapGenerator: 7 | - name: env-config 8 | files: 9 | - config.env 10 | -------------------------------------------------------------------------------- /examples/loadHttp.md: -------------------------------------------------------------------------------- 1 | # load file from http 2 | 3 | Resource and patch files could be loaded from http 4 | 5 | <!-- @loadHttp --> 6 | ```sh 7 | DEMO_HOME=$(mktemp -d) 8 | 9 | cat <<EOF >$DEMO_HOME/kustomization.yaml 10 | resources: 11 | - https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/examples/helloWorld/configMap.yaml 12 | EOF 13 | ``` 14 | 15 | <!-- @loadHttp --> 16 | ```sh 17 | test 1 == \ 18 | $(kustomize build $DEMO_HOME | grep "Good Morning!" | wc -l); \ 19 | echo $? 20 | ``` 21 | 22 | Kustomize will try loading resource as a file either from local or http. If it 23 | fails, try to load it as a directory or git repository. 24 | 25 | Http load applies to patches as well. See full example in [loadHttp](loadHttp/). 26 | -------------------------------------------------------------------------------- /examples/loadHttp/kustomization.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: kustomize.config.k8s.io/v1beta1 2 | kind: Kustomization 3 | resources: 4 | - https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/examples/wordpress/wordpress/deployment.yaml 5 | - https://github.com/knative/serving/releases/download/v0.12.0/serving.yaml # redirects to s3 6 | patches: 7 | - path: https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/examples/wordpress/patch.yaml 8 | - patch: |- 9 | apiVersion: rbac.authorization.k8s.io/v1 10 | kind: RoleBinding 11 | metadata: 12 | name: custom-metrics-auth-reader 13 | namespace: kube-system 14 | $patch: delete 15 | -------------------------------------------------------------------------------- /examples/multibases/base/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - pod.yaml -------------------------------------------------------------------------------- /examples/multibases/base/pod.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Pod 3 | metadata: 4 | name: myapp-pod 5 | labels: 6 | app: myapp 7 | spec: 8 | containers: 9 | - name: nginx 10 | image: nginx:1.7.9 11 | -------------------------------------------------------------------------------- /examples/multibases/dev/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - ../base 3 | namePrefix: dev- 4 | -------------------------------------------------------------------------------- /examples/multibases/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - dev 3 | - staging 4 | - production 5 | namePrefix: cluster-a- 6 | -------------------------------------------------------------------------------- /examples/multibases/production/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - ../base 3 | namePrefix: prod- 4 | -------------------------------------------------------------------------------- /examples/multibases/staging/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - ../base 3 | namePrefix: staging- 4 | -------------------------------------------------------------------------------- /examples/mySql/secret.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Secret 3 | metadata: 4 | creationTimestamp: null 5 | name: mysql-pass 6 | type: Opaque 7 | data: 8 | # Default password is "admin". 9 | password: YWRtaW4= 10 | -------------------------------------------------------------------------------- /examples/mySql/service.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Service 3 | metadata: 4 | name: mysql 5 | labels: 6 | app: mysql 7 | spec: 8 | ports: 9 | - port: 3306 10 | selector: 11 | app: mysql 12 | -------------------------------------------------------------------------------- /examples/springboot/base/application.properties: -------------------------------------------------------------------------------- 1 | app.name=Staging Kinflate Demo 2 | spring.jpa.hibernate.ddl-auto=update 3 | spring.datasource.url=jdbc:mysql://<production_db_ip>:3306/db_example 4 | spring.datasource.username=root 5 | spring.datasource.password=admin 6 | -------------------------------------------------------------------------------- /examples/springboot/base/deployment.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment 3 | metadata: 4 | name: sbdemo 5 | labels: 6 | app: sbdemo 7 | spec: 8 | selector: 9 | matchLabels: 10 | app: sbdemo 11 | template: 12 | metadata: 13 | labels: 14 | app: sbdemo 15 | spec: 16 | containers: 17 | - name: sbdemo 18 | image: jingfang/sbdemo 19 | ports: 20 | - containerPort: 8080 21 | volumeMounts: 22 | - name: demo-config 23 | mountPath: /config 24 | volumes: 25 | - name: "demo-config" 26 | configMap: 27 | name: "demo-configmap" 28 | -------------------------------------------------------------------------------- /examples/springboot/base/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - deployment.yaml 3 | - service.yaml 4 | configMapGenerator: 5 | - name: demo-configmap 6 | # behavior: merge 7 | files: 8 | - application.properties 9 | -------------------------------------------------------------------------------- /examples/springboot/base/service.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Service 3 | metadata: 4 | name: sbdemo 5 | labels: 6 | app: sbdemo 7 | spec: 8 | ports: 9 | - port: 8080 10 | selector: 11 | app: sbdemo 12 | type: LoadBalancer 13 | -------------------------------------------------------------------------------- /examples/springboot/overlays/production/application.properties: -------------------------------------------------------------------------------- 1 | app.name=Staging Kinflate Demo 2 | spring.jpa.hibernate.ddl-auto=update 3 | spring.datasource.url=jdbc:mysql://<production_db_ip>:3306/db_example 4 | spring.datasource.username=root 5 | spring.datasource.password=admin 6 | -------------------------------------------------------------------------------- /examples/springboot/overlays/production/healthcheck_patch.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment 3 | metadata: 4 | name: sbdemo 5 | spec: 6 | replicas: 2 7 | template: 8 | spec: 9 | containers: 10 | - name: sbdemo 11 | livenessProbe: 12 | httpGet: 13 | path: /actuator/health 14 | port: 8080 15 | initialDelaySeconds: 10 16 | periodSeconds: 3 17 | readinessProbe: 18 | initialDelaySeconds: 20 19 | periodSeconds: 10 20 | httpGet: 21 | path: /actuator/info 22 | port: 8080 23 | -------------------------------------------------------------------------------- /examples/springboot/overlays/production/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - ../../base 3 | patches: 4 | - path: patch.yaml 5 | - path: healthcheck_patch.yaml 6 | - path: memorylimit_patch.yaml 7 | namePrefix: production- 8 | -------------------------------------------------------------------------------- /examples/springboot/overlays/production/memorylimit_patch.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment 3 | metadata: 4 | name: sbdemo 5 | spec: 6 | replicas: 2 7 | template: 8 | spec: 9 | containers: 10 | - name: sbdemo 11 | resources: 12 | limits: 13 | memory: 1250Mi 14 | requests: 15 | memory: 1250Mi 16 | env: 17 | - name: MEM_TOTAL_MB 18 | valueFrom: 19 | resourceFieldRef: 20 | resource: limits.memory 21 | -------------------------------------------------------------------------------- /examples/springboot/overlays/production/patch.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: ConfigMap 3 | metadata: 4 | name: demo-configmap 5 | data: 6 | application.properties: | 7 | app.name=Production Kinflate Demo 8 | spring.jpa.hibernate.ddl-auto=update 9 | spring.datasource.url=jdbc:mysql://<production_db_ip>:3306/db_example 10 | spring.datasource.username=root 11 | spring.datasource.password=admin 12 | server.tomcat.max-threads=20 13 | server.tomcat.min-spare-threads=3 14 | -------------------------------------------------------------------------------- /examples/springboot/overlays/staging/application.properties: -------------------------------------------------------------------------------- 1 | app.name=Staging Kinflate Demo 2 | spring.jpa.hibernate.ddl-auto=update 3 | spring.datasource.url=jdbc:mysql://<staging_db_ip>:3306/db_example 4 | spring.datasource.username=root 5 | spring.datasource.password=admin 6 | -------------------------------------------------------------------------------- /examples/springboot/overlays/staging/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - ../../base 3 | namePrefix: staging- 4 | configMapGenerator: 5 | - name: demo-configmap 6 | behavior: merge 7 | files: 8 | - application.properties 9 | literals: 10 | - foo=bar 11 | env: staging.env 12 | -------------------------------------------------------------------------------- /examples/springboot/overlays/staging/staging.env: -------------------------------------------------------------------------------- 1 | staging -------------------------------------------------------------------------------- /examples/transformerconfigs/crd/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - resources.yaml 3 | 4 | namePrefix: test- 5 | 6 | commonLabels: 7 | foo: bar 8 | 9 | vars: 10 | - name: BEE_ACTION 11 | objref: 12 | kind: Bee 13 | name: bee 14 | apiVersion: v1beta1 15 | fieldref: 16 | fieldpath: spec.action 17 | -------------------------------------------------------------------------------- /examples/transformerconfigs/crd/resources.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Secret 3 | metadata: 4 | name: crdsecret 5 | data: 6 | PATH: YmJiYmJiYmIK 7 | --- 8 | apiVersion: v1beta1 9 | kind: Bee 10 | metadata: 11 | name: bee 12 | spec: 13 | action: fly 14 | --- 15 | apiVersion: jingfang.example.com/v1beta1 16 | kind: MyKind 17 | metadata: 18 | name: mykind 19 | spec: 20 | secretRef: 21 | name: crdsecret 22 | beeRef: 23 | name: bee 24 | action: $(BEE_ACTION) 25 | containers: 26 | - command: 27 | - "echo" 28 | - "$(BEE_ACTION)" 29 | image: myapp 30 | -------------------------------------------------------------------------------- /examples/transformerconfigs/images/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - resources.yaml 3 | 4 | configurations: 5 | - kustomizeconfig/mykind.yaml 6 | 7 | images: 8 | - name: crd-image 9 | newName: new-crd-image 10 | newTag: new-v1-tag 11 | - name: my-app 12 | newName: new-app-1 13 | newTag: MYNEWTAG-1 14 | - name: my-mysql 15 | newName: prod-mysql 16 | newTag: v3 17 | - name: docker 18 | newName: my-docker2 19 | digest: sha256:25a0d4 -------------------------------------------------------------------------------- /examples/transformerconfigs/images/mykind.yaml: -------------------------------------------------------------------------------- 1 | images: 2 | - path: spec/runLatest/container/image 3 | kind: MyKind -------------------------------------------------------------------------------- /examples/transformerconfigs/images/resources.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: config/v1 2 | kind: MyKind 3 | metadata: 4 | name: testSvc 5 | spec: 6 | runLatest: 7 | container: 8 | image: crd-image 9 | containers: 10 | - image: docker 11 | name: ecosystem 12 | - image: my-mysql 13 | name: testing-1 14 | --- 15 | group: apps 16 | apiVersion: v1 17 | kind: Deployment 18 | metadata: 19 | name: deploy1 20 | spec: 21 | template: 22 | spec: 23 | initContainers: 24 | - name: nginx2 25 | image: my-app 26 | - name: init-alpine 27 | image: alpine:1.8.0 -------------------------------------------------------------------------------- /examples/validationTransformer/invalid.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: ConfigMap 3 | metadata: 4 | name: cm 5 | data: 6 | - foo: bar -------------------------------------------------------------------------------- /examples/validationTransformer/valid.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: ConfigMap 3 | metadata: 4 | name: cm 5 | data: 6 | foo: bar 7 | -------------------------------------------------------------------------------- /examples/wordpress/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - wordpress 3 | - mysql 4 | patches: 5 | - path: patch.yaml 6 | namePrefix: demo- 7 | 8 | vars: 9 | - name: WORDPRESS_SERVICE 10 | objref: 11 | kind: Service 12 | name: wordpress 13 | apiVersion: v1 14 | - name: MYSQL_SERVICE 15 | objref: 16 | kind: Service 17 | name: mysql 18 | apiVersion: v1 19 | 20 | -------------------------------------------------------------------------------- /examples/wordpress/mysql/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - deployment.yaml 3 | - service.yaml 4 | - secret.yaml 5 | -------------------------------------------------------------------------------- /examples/wordpress/mysql/secret.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Secret 3 | metadata: 4 | name: mysql-pass 5 | type: Opaque 6 | data: 7 | # Default password is "admin". 8 | password: YWRtaW4= 9 | -------------------------------------------------------------------------------- /examples/wordpress/mysql/service.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Service 3 | metadata: 4 | name: mysql 5 | labels: 6 | app: mysql 7 | spec: 8 | ports: 9 | - port: 3306 10 | selector: 11 | app: mysql 12 | -------------------------------------------------------------------------------- /examples/wordpress/patch.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment 3 | metadata: 4 | name: wordpress 5 | spec: 6 | template: 7 | spec: 8 | initContainers: 9 | - name: init-command 10 | image: debian 11 | command: ["/bin/sh"] 12 | args: ["-c", "echo $(WORDPRESS_SERVICE); echo $(MYSQL_SERVICE)"] 13 | containers: 14 | - name: wordpress 15 | env: 16 | - name: WORDPRESS_DB_HOST 17 | value: $(MYSQL_SERVICE) 18 | - name: WORDPRESS_DB_PASSWORD 19 | valueFrom: 20 | secretKeyRef: 21 | name: mysql-pass 22 | key: password 23 | -------------------------------------------------------------------------------- /examples/wordpress/wordpress/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - deployment.yaml 3 | - service.yaml 4 | -------------------------------------------------------------------------------- /examples/wordpress/wordpress/service.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Service 3 | metadata: 4 | name: wordpress 5 | labels: 6 | app: wordpress 7 | spec: 8 | ports: 9 | - port: 80 10 | selector: 11 | app: wordpress 12 | type: LoadBalancer 13 | -------------------------------------------------------------------------------- /functions/examples/application-cr/Makefile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | include ../Makefile-examples-base.mk 5 | 6 | .PHONY: image 7 | image: 8 | docker build image -t gcr.io/kustomize-functions/create-application:v0.1.0 9 | docker push gcr.io/kustomize-functions/create-application:v0.1.0 10 | -------------------------------------------------------------------------------- /functions/examples/application-cr/config/fn-config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | apiVersion: examples.config.kubernetes.io/v1beta1 4 | kind: CreateApp 5 | metadata: 6 | annotations: 7 | config.kubernetes.io/function: | 8 | container: 9 | image: gcr.io/kustomize-functions/create-application:v0.1.0 10 | spec: 11 | managedBy: jingfang 12 | name: example-app 13 | namespace: example-namespace 14 | -------------------------------------------------------------------------------- /functions/examples/application-cr/image/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | FROM public.ecr.aws/docker/library/golang:1.22.7-bullseye 5 | ENV CGO_ENABLED=0 6 | WORKDIR /go/src/ 7 | COPY go.mod . 8 | COPY go.sum . 9 | RUN go mod download 10 | COPY main.go . 11 | RUN go build -v -o /usr/local/bin/config-function ./ 12 | 13 | FROM alpine:latest 14 | COPY --from=0 /usr/local/bin/config-function /usr/local/bin/config-function 15 | CMD ["config-function"] 16 | -------------------------------------------------------------------------------- /functions/examples/application-cr/image/Makefile: -------------------------------------------------------------------------------- 1 | ../../../../Makefile-modules.mk -------------------------------------------------------------------------------- /functions/examples/fn-framework-application/Makefile: -------------------------------------------------------------------------------- 1 | export KUSTOMIZE_ROOT ?= $(shell pwd | sed -E 's|(.*\/kustomize)/(.*)|\1|') 2 | include $(KUSTOMIZE_ROOT)/Makefile-modules.mk 3 | 4 | generate: $(MYGOBIN)/controller-gen $(MYGOBIN)/embedmd 5 | go generate ./... 6 | embedmd -w README.md 7 | 8 | build: generate 9 | go build -v -o $(MYGOBIN)/app-fn cmd/main.go 10 | 11 | .PHONY: example 12 | example: build 13 | $(MYGOBIN)/app-fn pkg/exampleapp/testdata/success/basic/config.yaml 14 | 15 | test: generate 16 | go test -v -timeout 45m -cover ./... 17 | -------------------------------------------------------------------------------- /functions/examples/fn-framework-application/cmd/main.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package main 5 | 6 | import "sigs.k8s.io/kustomize/functions/examples/fn-framework-application/pkg/dispatcher" 7 | 8 | func main() { 9 | _ = dispatcher.NewCommand().Execute() 10 | } 11 | -------------------------------------------------------------------------------- /functions/examples/fn-framework-application/pkg/exampleapp/v1alpha1/example_app_test.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package v1alpha1_test 5 | 6 | import ( 7 | "testing" 8 | 9 | "sigs.k8s.io/kustomize/functions/examples/fn-framework-application/pkg/dispatcher" 10 | "sigs.k8s.io/kustomize/kyaml/fn/framework/frameworktestutil" 11 | ) 12 | 13 | func TestExampleApp_GoldenFiles(t *testing.T) { 14 | c := frameworktestutil.CommandResultsChecker{ 15 | Command: dispatcher.NewCommand, 16 | // TestDataDirectory: "testdata/success", 17 | // UpdateExpectedFromActual: true, 18 | } 19 | c.Assert(t) 20 | } 21 | -------------------------------------------------------------------------------- /functions/examples/fn-framework-application/pkg/exampleapp/v1alpha1/templates/postgres_secret_env_patch.template.yaml: -------------------------------------------------------------------------------- 1 | env: 2 | - name: DATABASE_URL 3 | valueFrom: 4 | secretKeyRef: 5 | name: database-url 6 | key: DATABASE_URL 7 | -------------------------------------------------------------------------------- /functions/examples/fn-framework-application/pkg/exampleapp/v1alpha1/testdata/error/config.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: platform.example.com/v1alpha1 2 | kind: ExampleApp 3 | metadata: 4 | name: simple-app-sample 5 | env: invalid 6 | workloads: 7 | webWorkers: 8 | - name: web-worker 9 | replicas: -1 10 | resources: small 11 | domains: 12 | - example.com 13 | - name: web-worker-2 14 | domains: 15 | - example.com 16 | jobWorkers: 17 | - name: job-worker-$ 18 | queues: [] 19 | datastores: 20 | mongoDB: simple-app-sample-mongo 21 | extraProperty: true 22 | -------------------------------------------------------------------------------- /functions/examples/fn-framework-application/pkg/exampleapp/v1alpha1/testdata/error/errors.txt: -------------------------------------------------------------------------------- 1 | validation failure list: 2 | .extraProperty in body is a forbidden property 3 | workloads.jobWorkers\[0\].name in body should match 4 | workloads.jobWorkers\[0\].queues in body should have at least 1 items 5 | workloads.webWorkers\[0\].replicas in body should be greater than or equal to 0 6 | datastores.mongoDB in body is a forbidden property 7 | env in body should be one of \[production staging development\] 8 | duplicate domain \"example.com\" in worker 1 9 | -------------------------------------------------------------------------------- /functions/examples/fn-framework-application/pkg/exampleapp/v1alpha1/testdata/success/basic/config.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: platform.example.com/v1alpha1 2 | kind: ExampleApp 3 | metadata: 4 | name: simple-app-sample 5 | env: production 6 | workloads: 7 | webWorkers: 8 | - name: web-worker 9 | domains: 10 | - example.com 11 | jobWorkers: 12 | - name: job-worker 13 | replicas: 10 14 | resources: medium 15 | queues: 16 | - high 17 | - medium 18 | - low 19 | - name: job-worker-2 20 | replicas: 5 21 | queues: 22 | - bg2 23 | datastores: 24 | postgresInstance: simple-app-sample-postgres 25 | -------------------------------------------------------------------------------- /functions/examples/fn-framework-application/pkg/exampleapp/v1alpha1/testdata/success/overrides/config.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: platform.example.com/v1alpha1 2 | kind: ExampleApp 3 | metadata: 4 | name: simple-app-sample 5 | env: production 6 | workloads: 7 | webWorkers: 8 | - name: web-worker 9 | domains: 10 | - first.example.com 11 | - name: web-worker-no-sidecar 12 | domains: 13 | - second.example.com 14 | 15 | overrides: 16 | additionalResources: 17 | - custom-configmap.yaml 18 | resourcePatches: 19 | - web-worker-sidecar.yaml 20 | containerPatches: 21 | - custom-app-env.yaml 22 | -------------------------------------------------------------------------------- /functions/examples/fn-framework-application/pkg/exampleapp/v1alpha1/testdata/success/overrides/custom-app-env.yaml: -------------------------------------------------------------------------------- 1 | env: 2 | - name: MY_NEW_VAR 3 | value: "new value" 4 | envFrom: 5 | - configMapRef: 6 | name: custom-configmap 7 | -------------------------------------------------------------------------------- /functions/examples/fn-framework-application/pkg/exampleapp/v1alpha1/testdata/success/overrides/custom-configmap.yaml: -------------------------------------------------------------------------------- 1 | kind: ConfigMap 2 | apiVersion: v1 3 | metadata: 4 | name: custom-configmap 5 | data: 6 | LOADED: "true" 7 | -------------------------------------------------------------------------------- /functions/examples/fn-framework-application/pkg/exampleapp/v1alpha1/testdata/success/overrides/web-worker-sidecar.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment 3 | metadata: 4 | name: web-worker 5 | spec: 6 | template: 7 | spec: 8 | containers: 9 | - name: sidecar 10 | image: registry.example.com/path/to/custom-sidecar 11 | args: 12 | - run 13 | -------------------------------------------------------------------------------- /functions/examples/injection-tshirt-sizes/Makefile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | include ../Makefile-examples-base.mk 5 | 6 | .PHONY: image 7 | image: 8 | docker build image -t gcr.io/kustomize-functions/example-tshirt:v0.3.0 9 | docker push gcr.io/kustomize-functions/example-tshirt:v0.3.0 10 | -------------------------------------------------------------------------------- /functions/examples/injection-tshirt-sizes/image/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | FROM public.ecr.aws/docker/library/golang:1.22.7-bullseye 5 | ENV CGO_ENABLED=0 6 | WORKDIR /go/src/ 7 | COPY go.mod . 8 | COPY go.sum . 9 | RUN go mod download 10 | COPY main.go . 11 | RUN go build -v -o /usr/local/bin/config-function ./ 12 | 13 | FROM alpine:latest 14 | COPY --from=0 /usr/local/bin/config-function /usr/local/bin/config-function 15 | CMD ["config-function"] 16 | -------------------------------------------------------------------------------- /functions/examples/injection-tshirt-sizes/image/Makefile: -------------------------------------------------------------------------------- 1 | ../../../../Makefile-modules.mk -------------------------------------------------------------------------------- /functions/examples/injection-tshirt-sizes/local-resource/example-use.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2020 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | apiVersion: apps/v1 4 | kind: Deployment 5 | metadata: 6 | name: nginx 7 | labels: 8 | app: nginx 9 | annotations: 10 | tshirt-size: small # this injects the resource reservations 11 | spec: 12 | selector: 13 | matchLabels: 14 | app: nginx 15 | template: 16 | metadata: 17 | labels: 18 | app: nginx 19 | spec: 20 | containers: 21 | - name: nginx 22 | image: nginx 23 | -------------------------------------------------------------------------------- /functions/examples/injection-tshirt-sizes/local-resource/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - example-use.yaml 3 | transformers: 4 | - transformer.yaml 5 | -------------------------------------------------------------------------------- /functions/examples/injection-tshirt-sizes/local-resource/transformer.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: examples.config.kubernetes.io/v1beta1 2 | kind: tshirt 3 | metadata: 4 | name: tshirt 5 | annotations: 6 | config.kubernetes.io/function: |- 7 | container: 8 | image: gcr.io/kustomize-functions/example-tshirt:v0.3.0 9 | -------------------------------------------------------------------------------- /functions/examples/template-go-nginx/Makefile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | include ../Makefile-examples-base.mk 5 | 6 | .PHONY: image 7 | image: 8 | docker build image -t gcr.io/kustomize-functions/example-nginx:v0.2.0 9 | docker push gcr.io/kustomize-functions/example-nginx:v0.2.0 10 | -------------------------------------------------------------------------------- /functions/examples/template-go-nginx/image/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | FROM public.ecr.aws/docker/library/golang:1.22.7-bullseye 5 | ENV CGO_ENABLED=0 6 | WORKDIR /go/src/ 7 | COPY go.mod . 8 | COPY go.sum . 9 | RUN go mod download 10 | COPY main.go . 11 | RUN go build -v -o /usr/local/bin/config-function ./ 12 | 13 | FROM alpine:latest 14 | COPY --from=0 /usr/local/bin/config-function /usr/local/bin/config-function 15 | CMD ["config-function"] 16 | -------------------------------------------------------------------------------- /functions/examples/template-go-nginx/image/Makefile: -------------------------------------------------------------------------------- 1 | ../../../../Makefile-modules.mk -------------------------------------------------------------------------------- /functions/examples/template-go-nginx/local-resource/example-use.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: examples.config.kubernetes.io/v1beta1 # call `kustomize fn run` on a directory containing this file 5 | kind: Nginx 6 | metadata: 7 | name: demo 8 | annotations: 9 | config.kubernetes.io/function: | 10 | container: 11 | image: gcr.io/kustomize-functions/example-nginx:v0.3.0 12 | spec: 13 | replicas: 4 14 | -------------------------------------------------------------------------------- /functions/examples/template-go-nginx/local-resource/kustomization.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: kustomize.config.k8s.io/v1beta1 2 | kind: Kustomization 3 | 4 | generators: 5 | - example-use.yaml 6 | -------------------------------------------------------------------------------- /functions/examples/template-heredoc-cockroachdb/image/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | ARG KUSTOMIZE_IMAGE_TAG 5 | ARG KUSTOMIZE_IMAGE_SHA 6 | 7 | FROM registry.k8s.io/kustomize/kustomize:${KUSTOMIZE_IMAGE_TAG}@${KUSTOMIZE_IMAGE_SHA} 8 | RUN apk add --no-cache bash 9 | COPY cockroachdb-template.sh /usr/local/bin/config-function 10 | CMD ["config-function"] 11 | -------------------------------------------------------------------------------- /functions/examples/template-heredoc-cockroachdb/local-resource/example-use.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | # call `kustomize fn run` on a directory containing this file 5 | apiVersion: examples.config.kubernetes.io/v1beta1 6 | kind: CockroachDB 7 | metadata: 8 | name: demo 9 | annotations: 10 | config.kubernetes.io/function: | 11 | container: 12 | image: gcr.io/kustomize-functions/example-cockroachdb:v0.1.0 13 | spec: 14 | replicas: 3 15 | -------------------------------------------------------------------------------- /functions/examples/validator-kubeval/Makefile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | include ../Makefile-examples-base.mk 5 | 6 | .PHONY: image 7 | image: 8 | docker build image -t gcr.io/kustomize-functions/example-validator-kubeval:v0.1.0 9 | docker push gcr.io/kustomize-functions/example-validator-kubeval:v0.1.0 10 | -------------------------------------------------------------------------------- /functions/examples/validator-kubeval/image/Makefile: -------------------------------------------------------------------------------- 1 | ../../../../Makefile-modules.mk -------------------------------------------------------------------------------- /functions/examples/validator-resource-requests/Makefile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | include ../Makefile-examples-base.mk 5 | 6 | .PHONY: image 7 | image: 8 | docker build image -t gcr.io/kustomize-functions/example-validator:v0.1.0 9 | docker push gcr.io/kustomize-functions/example-validator:v0.1.0 10 | -------------------------------------------------------------------------------- /functions/examples/validator-resource-requests/image/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | FROM public.ecr.aws/docker/library/golang:1.22.7-bullseye 5 | ENV CGO_ENABLED=0 6 | WORKDIR /go/src/ 7 | COPY go.mod . 8 | COPY go.sum . 9 | RUN go mod download 10 | COPY main.go . 11 | RUN go build -v -o /usr/local/bin/config-function ./ 12 | 13 | FROM alpine:latest 14 | COPY --from=0 /usr/local/bin/config-function /usr/local/bin/config-function 15 | CMD ["config-function"] 16 | -------------------------------------------------------------------------------- /functions/examples/validator-resource-requests/image/Makefile: -------------------------------------------------------------------------------- 1 | ../../../../Makefile-modules.mk -------------------------------------------------------------------------------- /hack/Makefile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | export KUSTOMIZE_ROOT ?= $(shell pwd | sed -E 's|(.*\/kustomize)/(.*)|\1|') 5 | include $(KUSTOMIZE_ROOT)/Makefile-modules.mk 6 | 7 | .PHONY: lint 8 | # No file to lint for this module 9 | lint: 10 | true 11 | 12 | .PHONY: test 13 | # No tests for this module 14 | test: 15 | true 16 | 17 | .PHONY: build 18 | # No command to build for this module 19 | build: 20 | true 21 | -------------------------------------------------------------------------------- /hack/doGoMod.sh: -------------------------------------------------------------------------------- 1 | # Copyright 2022 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | # Usage: From repo root: 5 | # ./hack/doGoMod.sh tidy 6 | # ./hack/doGoMod.sh verify 7 | 8 | operation=$1 9 | for f in $(find ./ -name 'go.mod'); do 10 | echo $f 11 | d=$(dirname "$f") 12 | (cd $d; go mod $operation) 13 | done 14 | -------------------------------------------------------------------------------- /hack/imports.sh: -------------------------------------------------------------------------------- 1 | # Copyright 2022 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | for f in $(find $1 -name '*.go'); do 5 | echo $f 6 | # go get golang.org/x/tools/cmd/goimports 7 | # {or} go run go.coder.com/go-tools/cmd/goimports 8 | goimports -w $f 9 | done 10 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | dist 3 | example_tshirt/execfn/tshirt 4 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/cleanup.sh: -------------------------------------------------------------------------------- 1 | #! /bin/bash 2 | # Copyright 2022 The Kubernetes Authors. 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | set -e 6 | echo "You may need to run as root to clean." 7 | 8 | rm -rf example_tshirt/execfn/tshirt label_namespace/execfn/dist label_namespace/execfn/node_modules 9 | 10 | if [ "$1" == "--image" ]; then 11 | docker image rm label_namespace_build:latest 12 | docker image rm tshirt_example_build:latest 13 | fi 14 | 15 | echo "Done" 16 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/example_tshirt/containerfn/data.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment 3 | metadata: 4 | name: nginx 5 | labels: 6 | app: nginx 7 | annotations: 8 | tshirt-size: small # this injects the resource reservations 9 | spec: 10 | selector: 11 | matchLabels: 12 | app: nginx 13 | template: 14 | metadata: 15 | labels: 16 | app: nginx 17 | spec: 18 | containers: 19 | - name: nginx 20 | image: nginx 21 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/example_tshirt/containerfn/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - data.yaml 3 | transformers: 4 | - transf.yaml 5 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/example_tshirt/containerfn/transf.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: examples.config.kubernetes.io/v1beta1 2 | kind: tshirt 3 | metadata: 4 | name: tshirt 5 | annotations: 6 | config.kubernetes.io/function: |- 7 | container: 8 | image: gcr.io/kustomize-functions/example-tshirt:v0.2.0 9 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/example_tshirt/execfn/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright 2022 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | FROM alpine:latest 5 | 6 | ENV BUILD_HOME=/usr/local/build 7 | RUN apk update && apk add --no-cache git go 8 | 9 | RUN mkdir -p $BUILD_HOME 10 | 11 | WORKDIR $BUILD_HOME 12 | 13 | RUN git clone https://github.com/kubernetes-sigs/kustomize.git . 14 | RUN git checkout tags/kustomize/v3.6.1 15 | WORKDIR $BUILD_HOME/functions/examples/injection-tshirt-sizes/image/ 16 | 17 | ENV CGO_ENABLED=0 18 | RUN go mod download 19 | RUN go build -o tshirt . 20 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/example_tshirt/execfn/build.sh: -------------------------------------------------------------------------------- 1 | #! /bin/bash 2 | # Copyright 2022 The Kubernetes Authors. 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | 6 | IMAGE_LABEL="tshirt_example_build:latest" 7 | BUILD_HOME=/usr/local/build 8 | 9 | docker build -t $IMAGE_LABEL . 10 | 11 | docker run --rm -v $(pwd):/out $IMAGE_LABEL \ 12 | cp -r $BUILD_HOME/functions/examples/injection-tshirt-sizes/image/tshirt /out 13 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/example_tshirt/execfn/data.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment 3 | metadata: 4 | name: nginx 5 | labels: 6 | app: nginx 7 | annotations: 8 | tshirt-size: small # this injects the resource reservations 9 | spec: 10 | selector: 11 | matchLabels: 12 | app: nginx 13 | template: 14 | metadata: 15 | labels: 16 | app: nginx 17 | spec: 18 | containers: 19 | - name: nginx 20 | image: nginx 21 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/example_tshirt/execfn/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - data.yaml 3 | transformers: 4 | - transf.yaml 5 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/example_tshirt/execfn/transf.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: examples.config.kubernetes.io/v1beta1 2 | kind: tshirt 3 | metadata: 4 | name: tshirt 5 | annotations: 6 | config.kubernetes.io/function: |- 7 | exec: 8 | path: ./tshirt 9 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/label_namespace/containerfn/containerfn.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: ConfigMap 3 | metadata: 4 | name: label_namespace 5 | annotations: 6 | config.kubernetes.io/function: |- 7 | container: 8 | image: gcr.io/kpt-functions/label-namespace@sha256:4f030738d6d25a207641ca517916431517578bd0eb8d98a8bde04e3bb9315dcd 9 | data: 10 | label_name: my-ns-name 11 | label_value: function-test 12 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/label_namespace/containerfn/data1.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Namespace 3 | metadata: 4 | name: my-namespace 5 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/label_namespace/containerfn/data2.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Namespace 3 | metadata: 4 | name: another-namespace 5 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/label_namespace/containerfn/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - data1.yaml 3 | - data2.yaml 4 | transformers: 5 | - containerfn.yaml 6 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/label_namespace/execfn/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright 2022 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | FROM alpine:latest 5 | 6 | ENV BUILD_HOME=/usr/local/build 7 | RUN apk update && apk add --no-cache git nodejs npm 8 | COPY ["./package.json", "./package-lock.json", "./"] 9 | RUN npm install -g 10 | 11 | RUN mkdir -p $BUILD_HOME 12 | 13 | WORKDIR $BUILD_HOME 14 | 15 | RUN git clone https://github.com/GoogleContainerTools/kpt-functions-sdk.git . 16 | RUN git checkout tags/release-kpt-functions-v0.14.2 17 | WORKDIR $BUILD_HOME/ts/hello-world/ 18 | RUN npm install 19 | RUN npm run build 20 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/label_namespace/execfn/build.sh: -------------------------------------------------------------------------------- 1 | #! /bin/bash 2 | # Copyright 2022 The Kubernetes Authors. 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | 6 | IMAGE_LABEL="label_namespace_build:latest" 7 | BUILD_HOME=/usr/local/build 8 | 9 | docker build -t $IMAGE_LABEL . 10 | 11 | docker run --rm -v $(pwd):/out $IMAGE_LABEL \ 12 | cp -r $BUILD_HOME/ts/hello-world/dist $BUILD_HOME/ts/hello-world/node_modules /out 13 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/label_namespace/execfn/data1.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Namespace 3 | metadata: 4 | name: my-namespace 5 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/label_namespace/execfn/data2.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Namespace 3 | metadata: 4 | name: another-namespace 5 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/label_namespace/execfn/execfn.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: ConfigMap 3 | metadata: 4 | name: label_namespace 5 | annotations: 6 | config.kubernetes.io/function: |- 7 | exec: 8 | path: ./fn.sh 9 | data: 10 | label_name: my-ns-name 11 | label_value: function-test 12 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/label_namespace/execfn/fn.sh: -------------------------------------------------------------------------------- 1 | #! /bin/bash 2 | # Copyright 2022 The Kubernetes Authors. 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | 6 | node ./dist/label_namespace_run.js 7 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/label_namespace/execfn/kustomization.yaml: -------------------------------------------------------------------------------- 1 | resources: 2 | - data1.yaml 3 | - data2.yaml 4 | transformers: 5 | - execfn.yaml 6 | -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/label_namespace/execfn/package-lock.json: -------------------------------------------------------------------------------- 1 | { 2 | "requires": true, 3 | "lockfileVersion": 1, 4 | "dependencies": { 5 | "help": { 6 | "version": "3.0.2", 7 | "resolved": "https://registry.npmjs.org/help/-/help-3.0.2.tgz", 8 | "integrity": "sha512-jDd0MU+9xzvOQRC6CIzdjvb+agCvpzQY/Fp11quDnugDO4QQzh134EsLkRQMvFIJBleFkvnXagHFm4MTefkkpA==" 9 | }, 10 | "typescript": { 11 | "version": "5.2.2", 12 | "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.2.2.tgz", 13 | "integrity": "sha512-mI4WrpHsbCIcwT9cF4FZvr80QUeKvsUsUvKDoR+X/7XHQH98xYD8YHZg7ANtz2GtZt/CBq2QJ0thkGJMHfqc1w==" 14 | } 15 | } 16 | } -------------------------------------------------------------------------------- /hack/krmFunctionBenchmark/label_namespace/execfn/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "execfn", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "", 10 | "license": "ISC" 11 | } 12 | -------------------------------------------------------------------------------- /hack/shellHelpers.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright 2019 The Kubernetes Authors. 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | # TODO: Make the code ignorant of the CI environment "brand name". 6 | # We used to run CI tests on travis, and disabled certain tests 7 | # when running there. Now we run on Prow, so look for that. 8 | # https://github.com/kubernetes/test-infra/blob/master/prow/jobs.md 9 | # Might be useful to eschew using the brand name of the CI environment 10 | # (replace "travis" with "RemoteCI" or something - not just switch to "prow"). 11 | 12 | function onLinuxAndNotOnRemoteCI { 13 | [[ ("linux" == "$(go env GOOS)") && (-z ${PROW_JOB_ID+x}) ]] && return 14 | false 15 | } 16 | -------------------------------------------------------------------------------- /hack/testExamplesE2EAgainstKustomize.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # 3 | # Copyright 2019 The Kubernetes Authors. 4 | # SPDX-License-Identifier: Apache-2.0 5 | 6 | set -o nounset 7 | set -o errexit 8 | set -o pipefail 9 | 10 | mdrip --blockTimeOut 60m0s --mode test \ 11 | --label testE2EAgainstLatestRelease examples/alphaTestExamples 12 | 13 | echo "Example e2e tests passed against ." 14 | -------------------------------------------------------------------------------- /kustomize.Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright 2022 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | # build 5 | FROM public.ecr.aws/docker/library/golang:1.22.7-bullseye AS builder 6 | ARG VERSION 7 | ARG DATE 8 | RUN mkdir /build 9 | ADD . /build/ 10 | WORKDIR /build/kustomize 11 | RUN CGO_ENABLED=0 GO111MODULE=on go build \ 12 | -ldflags="-s -X sigs.k8s.io/kustomize/api/provenance.version=${VERSION} \ 13 | -X sigs.k8s.io/kustomize/api/provenance.buildDate=${DATE}" 14 | 15 | # only copy binary 16 | FROM public.ecr.aws/docker/library/alpine 17 | # install dependencies 18 | RUN apk add --no-cache git openssh 19 | COPY --from=builder /build/kustomize/kustomize /app/ 20 | WORKDIR /app 21 | ENV PATH="$PATH:/app" 22 | ENTRYPOINT ["/app/kustomize"] 23 | -------------------------------------------------------------------------------- /kustomize/Makefile: -------------------------------------------------------------------------------- 1 | ../Makefile-modules.mk -------------------------------------------------------------------------------- /kustomize/OWNERS: -------------------------------------------------------------------------------- 1 | # See https://github.com/kubernetes/community/blob/master/community-membership.md 2 | approvers: 3 | - commands-approvers 4 | 5 | reviewers: 6 | - commands-reviewers 7 | -------------------------------------------------------------------------------- /kustomize/commands/build/flagaddmanagedby.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package build 5 | 6 | import ( 7 | "os" 8 | 9 | "github.com/spf13/pflag" 10 | "sigs.k8s.io/kustomize/api/konfig" 11 | ) 12 | 13 | const managedByFlag = "enable-managedby-label" 14 | 15 | func AddFlagEnableManagedbyLabel(set *pflag.FlagSet) { 16 | set.BoolVar( 17 | &theFlags.enable.managedByLabel, 18 | managedByFlag, 19 | false, 20 | `enable adding `+konfig.ManagedbyLabelKey) 21 | } 22 | 23 | func isManagedByLabelEnabled() bool { 24 | if theFlags.enable.managedByLabel { 25 | return true 26 | } 27 | enableLabel, isSet := os.LookupEnv(konfig.EnableManagedbyLabelEnv) 28 | return isSet && enableLabel == "on" 29 | } 30 | -------------------------------------------------------------------------------- /kustomize/commands/build/flagenableplugins.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package build 5 | 6 | import ( 7 | "github.com/spf13/pflag" 8 | ) 9 | 10 | func AddFlagEnablePlugins(set *pflag.FlagSet) { 11 | set.BoolVar( 12 | &theFlags.enable.plugins, 13 | "enable-alpha-plugins", 14 | false, 15 | "enable kustomize plugins") 16 | } 17 | -------------------------------------------------------------------------------- /kustomize/commands/build/flagoutputpath.go: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package build 5 | 6 | import ( 7 | "github.com/spf13/pflag" 8 | ) 9 | 10 | func AddFlagOutputPath(set *pflag.FlagSet) { 11 | set.StringVarP( 12 | &theFlags.outputPath, 13 | "output", 14 | "o", // abbreviation 15 | "", // default 16 | "If specified, write output to this path.") 17 | } 18 | -------------------------------------------------------------------------------- /kustomize/commands/openapi/info/info.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package info 5 | 6 | import ( 7 | "fmt" 8 | "io" 9 | 10 | "github.com/spf13/cobra" 11 | "sigs.k8s.io/kustomize/kyaml/openapi/kubernetesapi" 12 | ) 13 | 14 | // NewCmdInfo makes a new info command. 15 | func NewCmdInfo(w io.Writer) *cobra.Command { 16 | infoCmd := cobra.Command{ 17 | Use: "info", 18 | Short: "Prints the `info` field from the kubernetes OpenAPI data", 19 | Example: `kustomize openapi info`, 20 | Run: func(cmd *cobra.Command, args []string) { 21 | fmt.Fprintln(w, kubernetesapi.Info) 22 | }, 23 | } 24 | return &infoCmd 25 | } 26 | -------------------------------------------------------------------------------- /kustomize/main.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // The kustomize CLI. 5 | package main 6 | 7 | import ( 8 | "os" 9 | 10 | "sigs.k8s.io/kustomize/kustomize/v5/commands" 11 | ) 12 | 13 | func main() { 14 | if err := commands.NewDefaultCommand().Execute(); err != nil { 15 | os.Exit(1) 16 | } 17 | os.Exit(0) 18 | } 19 | -------------------------------------------------------------------------------- /kyaml/commandutil/commandutil.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package commandutil 5 | 6 | import ( 7 | "os" 8 | ) 9 | 10 | // EnabkeAlphaCommmandsEnvName is the environment variable used to enable Alpha kustomize commands. 11 | // If set to "true" alpha commands will be enabled. 12 | const EnableAlphaCommmandsEnvName = "KUSTOMIZE_ENABLE_ALPHA_COMMANDS" 13 | 14 | // GetAlphaEnabled returns true if alpha commands should be enabled. 15 | func GetAlphaEnabled() bool { 16 | return os.Getenv(EnableAlphaCommmandsEnvName) == "true" 17 | } 18 | -------------------------------------------------------------------------------- /kyaml/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package kyaml contains libraries for reading and writing Kubernetes Resource configuration 5 | // as yaml. 6 | // 7 | // Resources 8 | // 9 | // Individual Resources are manipulated using the yaml package. 10 | // import ( 11 | // "sigs.k8s.io/kustomize/kyaml/yaml" 12 | // ) 13 | // 14 | // Collections of Resources 15 | // 16 | // Collections of Resources are manipulated using the kio package. 17 | // import ( 18 | // "sigs.k8s.io/kustomize/kyaml/kio" 19 | // ) 20 | package kyaml 21 | -------------------------------------------------------------------------------- /kyaml/ext/ext.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package ext 5 | 6 | // IgnoreFileName returns the name for ignore files in 7 | // packages. It can be overridden by tools using this library. 8 | var IgnoreFileName = func() string { 9 | return ".krmignore" 10 | } 11 | -------------------------------------------------------------------------------- /kyaml/filesys/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package filesys provides a file system abstraction, 5 | // a subset of that provided by golang.org/pkg/os, 6 | // with an on-disk and in-memory representation. 7 | package filesys 8 | -------------------------------------------------------------------------------- /kyaml/filesys/file.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package filesys 5 | 6 | import ( 7 | "io" 8 | "os" 9 | ) 10 | 11 | // File groups the basic os.File methods. 12 | type File interface { 13 | io.ReadWriteCloser 14 | Stat() (os.FileInfo, error) 15 | } 16 | -------------------------------------------------------------------------------- /kyaml/filesys/fsondisk_unix.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | //go:build !windows 5 | // +build !windows 6 | 7 | package filesys 8 | 9 | import ( 10 | "path/filepath" 11 | ) 12 | 13 | func getOSRoot() (string, error) { 14 | return string(filepath.Separator), nil 15 | } 16 | -------------------------------------------------------------------------------- /kyaml/filesys/fsondisk_windows.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package filesys 5 | 6 | import ( 7 | "path/filepath" 8 | 9 | "golang.org/x/sys/windows" 10 | ) 11 | 12 | func getOSRoot() (string, error) { 13 | sysDir, err := windows.GetSystemDirectory() 14 | if err != nil { 15 | return "", err 16 | } 17 | return filepath.VolumeName(sysDir) + `\`, nil 18 | } 19 | -------------------------------------------------------------------------------- /kyaml/filtersutil/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package filtersutil provides utilities for working with yaml.Filter and 5 | // kio.Filter interfaces. 6 | package filtersutil 7 | -------------------------------------------------------------------------------- /kyaml/fn/framework/command/testdata/standalone/config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1alpha1 5 | kind: Foo 6 | a: c 7 | b: 1 8 | -------------------------------------------------------------------------------- /kyaml/fn/framework/command/testdata/standalone/expected.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: bar2 8 | namespace: default 9 | annotations: 10 | foo: bar2 11 | a: 'c' 12 | b: '1' 13 | --- 14 | apiVersion: apps/v1 15 | kind: Deployment 16 | metadata: 17 | name: bar1 18 | namespace: default 19 | annotations: 20 | foo: bar1 21 | a: 'c' 22 | b: '1' 23 | -------------------------------------------------------------------------------- /kyaml/fn/framework/command/testdata/standalone/input.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: bar2 8 | namespace: default 9 | annotations: 10 | foo: bar2 -------------------------------------------------------------------------------- /kyaml/fn/framework/example/Dockerfile: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | FROM public.ecr.aws/docker/library/golang:1.22.7-bullseye 5 | ENV CGO_ENABLED=0 6 | WORKDIR /go/src/ 7 | COPY . . 8 | RUN go build -v -o /usr/local/bin/function ./ 9 | 10 | FROM alpine:latest 11 | COPY --from=0 /usr/local/bin/function /usr/local/bin/function 12 | CMD ["function"] 13 | -------------------------------------------------------------------------------- /kyaml/fn/framework/example/main_test.go: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package main 5 | 6 | import ( 7 | "testing" 8 | 9 | "sigs.k8s.io/kustomize/kyaml/fn/framework/frameworktestutil" 10 | ) 11 | 12 | func TestRun(t *testing.T) { 13 | prc := frameworktestutil.CommandResultsChecker{ 14 | Command: buildCmd, 15 | } 16 | prc.Assert(t) 17 | } 18 | -------------------------------------------------------------------------------- /kyaml/fn/framework/example/templates/service_account.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: v1 5 | kind: ServiceAccount 6 | metadata: 7 | name: {{ .Value }} 8 | -------------------------------------------------------------------------------- /kyaml/fn/framework/example/testdata/basic/config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1alpha1 5 | kind: Tester 6 | value: foo 7 | -------------------------------------------------------------------------------- /kyaml/fn/framework/example/testdata/basic/expected.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | kind: ConfigMap 5 | apiVersion: v1 6 | metadata: 7 | name: tester 8 | annotations: 9 | value: foo 10 | data: 11 | some: data 12 | --- 13 | # Copyright 2021 The Kubernetes Authors. 14 | # SPDX-License-Identifier: Apache-2.0 15 | 16 | apiVersion: v1 17 | kind: ServiceAccount 18 | metadata: 19 | name: foo 20 | annotations: 21 | value: foo 22 | -------------------------------------------------------------------------------- /kyaml/fn/framework/example/testdata/basic/input.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | kind: ConfigMap 5 | apiVersion: v1 6 | metadata: 7 | name: tester 8 | data: 9 | some: data 10 | -------------------------------------------------------------------------------- /kyaml/fn/framework/frameworktestutil/testdata/update_expectations/command/important_subdir/config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1alpha1 5 | kind: Demo 6 | spec: 7 | value: a 8 | -------------------------------------------------------------------------------- /kyaml/fn/framework/frameworktestutil/testdata/update_expectations/command/important_subdir/expected.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | updated: "true" 10 | --- 11 | apiVersion: apps/v1 12 | kind: Deployment 13 | metadata: 14 | name: test-2 15 | annotations: 16 | updated: "true" 17 | -------------------------------------------------------------------------------- /kyaml/fn/framework/frameworktestutil/testdata/update_expectations/command/important_subdir/input.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | --- 11 | apiVersion: apps/v1 12 | kind: Deployment 13 | metadata: 14 | name: test-2 15 | annotations: 16 | foo: bar 17 | -------------------------------------------------------------------------------- /kyaml/fn/framework/frameworktestutil/testdata/update_expectations/processor/important_subdir/expected.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: 2 | kind: ResourceList 3 | items: 4 | - apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | updated: "true" 10 | - apiVersion: apps/v1 11 | kind: Deployment 12 | metadata: 13 | name: test-2 14 | annotations: 15 | updated: "true" 16 | functionConfig: 17 | apiVersion: example.com/v1alpha1 18 | kind: Demo 19 | spec: 20 | value: a 21 | -------------------------------------------------------------------------------- /kyaml/fn/framework/frameworktestutil/testdata/update_expectations/processor/important_subdir/input.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | kind: ResourceList 5 | items: 6 | - apiVersion: apps/v1 7 | kind: Deployment 8 | metadata: 9 | name: test-1 10 | annotations: 11 | baz: foo 12 | - apiVersion: apps/v1 13 | kind: Deployment 14 | metadata: 15 | name: test-2 16 | annotations: 17 | foo: bar 18 | functionConfig: 19 | apiVersion: example.com/v1alpha1 20 | kind: Demo 21 | spec: 22 | value: a 23 | -------------------------------------------------------------------------------- /kyaml/fn/framework/parser/testdata/cm1.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: v1 5 | kind: ConfigMap 6 | metadata: 7 | name: appconfig 8 | labels: 9 | app: {{ .Name }} 10 | data: 11 | app: {{ .Name }} 12 | -------------------------------------------------------------------------------- /kyaml/fn/framework/parser/testdata/cm2.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: v1 5 | kind: ConfigMap 6 | metadata: 7 | name: env 8 | labels: 9 | app: {{ .Name }} 10 | data: 11 | env: production 12 | -------------------------------------------------------------------------------- /kyaml/fn/framework/parser/testdata/ignore.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | not: a_resource 5 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/example/template/config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1alpha1 5 | kind: Example 6 | key: a 7 | value: b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/example/templatefiles/config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1alpha1 5 | kind: Example 6 | key: a 7 | value: b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/example/templatefiles/deployment.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: foo 8 | namespace: default 9 | annotations: 10 | {{ .Key }}: {{ .Value }} 11 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/annotationselector/config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1alpha1 5 | kind: patcher 6 | selector: 7 | annotations: 8 | foo: bar 9 | a: a 10 | b: b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/annotationselector/expected.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | --- 11 | apiVersion: apps/v1 12 | kind: Deployment 13 | metadata: 14 | name: test-2 15 | annotations: 16 | foo: bar 17 | patched: 'a' 18 | spec: 19 | template: 20 | spec: 21 | containers: 22 | - name: foo 23 | image: example/sidecar:b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/annotationselector/input.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | --- 11 | apiVersion: apps/v1 12 | kind: Deployment 13 | metadata: 14 | name: test-2 15 | annotations: 16 | foo: bar 17 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/apiversionselector/config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1alpha1 5 | kind: patcher 6 | selector: 7 | apiVersions: ["apps/v1alpha1"] 8 | a: a 9 | b: b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/apiversionselector/expected.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1alpha1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | patched: 'a' 11 | spec: 12 | template: 13 | spec: 14 | containers: 15 | - name: foo 16 | image: example/sidecar:b 17 | --- 18 | apiVersion: apps/v1 19 | kind: Deployment 20 | metadata: 21 | name: test-2 22 | annotations: 23 | foo: bar 24 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/apiversionselector/input.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1alpha1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | --- 11 | apiVersion: apps/v1 12 | kind: Deployment 13 | metadata: 14 | name: test-2 15 | annotations: 16 | foo: bar 17 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/filterselector/config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1alpha1 5 | kind: patcher 6 | a: a 7 | b: b 8 | special: bar -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/filterselector/expected.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | patched: 'a' 11 | spec: 12 | template: 13 | spec: 14 | containers: 15 | - name: foo 16 | image: example/sidecar:b 17 | --- 18 | apiVersion: apps/v1 19 | kind: Deployment 20 | metadata: 21 | name: test-2 22 | namespace: test 23 | annotations: 24 | foo: bar 25 | patched: 'a' 26 | filterPatched: 'a' 27 | spec: 28 | template: 29 | spec: 30 | containers: 31 | - name: foo 32 | image: example/sidecar:b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/filterselector/input.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | --- 11 | apiVersion: apps/v1 12 | kind: Deployment 13 | metadata: 14 | name: test-2 15 | namespace: test 16 | annotations: 17 | foo: bar 18 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/kindselector/config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1alpha1 5 | kind: patcher 6 | selector: 7 | kinds: ["Deployment"] 8 | a: a 9 | b: b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/kindselector/expected.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | patched: 'a' 11 | spec: 12 | template: 13 | spec: 14 | containers: 15 | - name: foo 16 | image: example/sidecar:b 17 | --- 18 | apiVersion: apps/v1 19 | kind: StatefulSet 20 | metadata: 21 | name: test-2 22 | annotations: 23 | foo: bar 24 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/kindselector/input.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | --- 11 | apiVersion: apps/v1 12 | kind: StatefulSet 13 | metadata: 14 | name: test-2 15 | annotations: 16 | foo: bar 17 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/labelselector/config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1alpha1 5 | kind: patcher 6 | selector: 7 | labels: 8 | foo: bar 9 | a: a 10 | b: b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/labelselector/expected.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | labels: 9 | baz: foo 10 | --- 11 | apiVersion: apps/v1 12 | kind: Deployment 13 | metadata: 14 | name: test-2 15 | labels: 16 | foo: bar 17 | annotations: 18 | patched: 'a' 19 | spec: 20 | template: 21 | spec: 22 | containers: 23 | - name: foo 24 | image: example/sidecar:b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/labelselector/input.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | labels: 9 | baz: foo 10 | --- 11 | apiVersion: apps/v1 12 | kind: Deployment 13 | metadata: 14 | name: test-2 15 | labels: 16 | foo: bar 17 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/longlistpreprocess/config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1alpha1 5 | kind: patcher 6 | selector: 7 | kinds: ["Deployment"] 8 | a: a 9 | b: b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/longlistpreprocess/input.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | --- 11 | apiVersion: apps/v1 12 | kind: StatefulSet 13 | metadata: 14 | name: test-2 15 | annotations: 16 | foo: bar 17 | --- 18 | apiVersion: apps/v1 19 | kind: Deployment 20 | metadata: 21 | name: test-3 22 | annotations: 23 | foo: bar 24 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/nameselector/config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1alpha1 5 | kind: patcher 6 | selector: 7 | names: ["test-2"] 8 | a: a 9 | b: b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/nameselector/expected.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | --- 11 | apiVersion: apps/v1 12 | kind: Deployment 13 | metadata: 14 | name: test-2 15 | annotations: 16 | foo: bar 17 | patched: 'a' 18 | spec: 19 | template: 20 | spec: 21 | containers: 22 | - name: foo 23 | image: example/sidecar:b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/nameselector/input.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | --- 11 | apiVersion: apps/v1 12 | kind: Deployment 13 | metadata: 14 | name: test-2 15 | annotations: 16 | foo: bar 17 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/namespaceselector/config.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1alpha1 5 | kind: patcher 6 | selector: 7 | namespaces: ["test"] 8 | a: a 9 | b: b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/namespaceselector/expected.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | --- 11 | apiVersion: apps/v1 12 | kind: Deployment 13 | metadata: 14 | name: test-2 15 | namespace: test 16 | annotations: 17 | foo: bar 18 | patched: 'a' 19 | spec: 20 | template: 21 | spec: 22 | containers: 23 | - name: foo 24 | image: example/sidecar:b -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/patch-selector/namespaceselector/input.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: test-1 8 | annotations: 9 | baz: foo 10 | --- 11 | apiVersion: apps/v1 12 | kind: Deployment 13 | metadata: 14 | name: test-2 15 | namespace: test 16 | annotations: 17 | foo: bar 18 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/container-patches/container.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | env: 5 | - name: {{ .Spec.Key }} 6 | value: {{ .Spec.Value }} 7 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/patches/basic/patch.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | spec: 5 | replicas: {{ .Spec.Replicas }} 6 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/patches/custom-resource/patch.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | spec: 5 | targets: 6 | - app: B 7 | size: small 8 | - app: C 9 | type: Ruby 10 | size: large 11 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/templates/basic/deploy.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: foo 8 | namespace: bar 9 | spec: 10 | template: 11 | spec: 12 | containers: 13 | - name: foo 14 | image: {{ .Image }} 15 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/templates/container-sources/cron_job.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: batch/v1 5 | kind: CronJob 6 | metadata: 7 | name: hello 8 | spec: 9 | schedule: "*/1 * * * *" 10 | jobTemplate: 11 | spec: 12 | template: 13 | spec: 14 | containers: 15 | - name: hello 16 | image: nginx 17 | env: 18 | - name: EXISTING 19 | value: variable 20 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/templates/container-sources/daemon_set.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: DaemonSet 6 | metadata: 7 | name: hello 8 | spec: 9 | selector: 10 | matchLabels: 11 | name: hello 12 | template: 13 | metadata: 14 | labels: 15 | name: hello 16 | spec: 17 | containers: 18 | - name: hello 19 | image: nginx 20 | env: 21 | - name: EXISTING 22 | value: variable 23 | 24 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/templates/container-sources/deployment.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: Deployment 6 | metadata: 7 | name: hello 8 | spec: 9 | selector: 10 | matchLabels: 11 | app: hello 12 | template: 13 | metadata: 14 | labels: 15 | app: hello 16 | spec: 17 | containers: 18 | - name: hello 19 | image: nginx 20 | env: 21 | - name: EXISTING 22 | value: variable 23 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/templates/container-sources/job.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: batch/v1 5 | kind: Job 6 | metadata: 7 | name: hello 8 | spec: 9 | template: 10 | spec: 11 | containers: 12 | - name: hello 13 | image: nginx 14 | env: 15 | - name: EXISTING 16 | value: variable 17 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/templates/container-sources/pod.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: v1 5 | kind: Pod 6 | metadata: 7 | name: hello 8 | spec: 9 | containers: 10 | - name: hello 11 | image: nginx 12 | env: 13 | - name: EXISTING 14 | value: variable 15 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/templates/container-sources/pod_template.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: v1 5 | kind: PodTemplate 6 | metadata: 7 | name: hello 8 | labels: 9 | tier: hello 10 | template: 11 | spec: 12 | containers: 13 | - name: hello 14 | image: nginx 15 | env: 16 | - name: EXISTING 17 | value: variable 18 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/templates/container-sources/replica_set.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: ReplicaSet 6 | metadata: 7 | name: hello 8 | spec: 9 | selector: 10 | matchLabels: 11 | app: hello 12 | template: 13 | metadata: 14 | labels: 15 | app: hello 16 | spec: 17 | containers: 18 | - name: hello 19 | image: nginx 20 | env: 21 | - name: EXISTING 22 | value: variable 23 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/templates/container-sources/replication_controller.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: v1 5 | kind: ReplicationController 6 | metadata: 7 | name: hello 8 | spec: 9 | selector: 10 | app: hello 11 | template: 12 | metadata: 13 | name: hello 14 | labels: 15 | app: hello 16 | spec: 17 | containers: 18 | - name: hello 19 | image: nginx 20 | env: 21 | - name: EXISTING 22 | value: variable 23 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/templates/container-sources/stateful_set.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: apps/v1 5 | kind: StatefulSet 6 | metadata: 7 | name: hello 8 | spec: 9 | serviceName: "nginx" 10 | selector: 11 | matchLabels: 12 | app: hello 13 | template: 14 | metadata: 15 | labels: 16 | app: hello 17 | spec: 18 | containers: 19 | - name: hello 20 | image: nginx 21 | env: 22 | - name: EXISTING 23 | value: variable 24 | 25 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/template-processor/templates/custom-resource/foo.template.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | apiVersion: example.com/v1 5 | kind: Foo 6 | metadata: 7 | name: example 8 | spec: 9 | targets: 10 | - app: A 11 | type: Go 12 | size: small 13 | - app: B 14 | type: Go 15 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/validation/error/errors.txt: -------------------------------------------------------------------------------- 1 | validation failure list: 2 | spec.domain in body should match 'example\\.com\#39; 3 | spec.image should not have latest tag 4 | metadata.name in body should be at least 1 chars long 5 | spec.replicas in body should be less than or equal to 9 6 | -------------------------------------------------------------------------------- /kyaml/fn/framework/testdata/validation/error/input.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2021 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | kind: ResourceList 5 | apiVersion: config.kubernetes.io/v1 6 | functionConfig: 7 | apiVersion: example.com/v1alpha1 8 | kind: JavaSpringBoot 9 | metadata: 10 | name: "" 11 | spec: 12 | replicas: 1000 13 | image: foo:latest 14 | domain: bad 15 | -------------------------------------------------------------------------------- /kyaml/fn/runtime/exec/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package exec contains the exec function implementation. 5 | package exec 6 | -------------------------------------------------------------------------------- /kyaml/fn/runtime/runtimeutil/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package runtimeutil contains libraries for implementing function runtimes. 5 | package runtimeutil 6 | -------------------------------------------------------------------------------- /kyaml/fn/runtime/runtimeutil/types.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package runtimeutil 5 | 6 | type DeferFailureFunction interface { 7 | GetExit() error 8 | } 9 | -------------------------------------------------------------------------------- /kyaml/kio/filters/modify.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package filters 5 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1-expected/java/java-configmap.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: ConfigMap 6 | metadata: 7 | name: app-config 8 | labels: 9 | app.kubernetes.io/component: undefined 10 | app.kubernetes.io/instance: undefined 11 | data: {} 12 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1-expected/java/java-service.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: Service 6 | metadata: 7 | name: app 8 | labels: 9 | app: java 10 | spec: 11 | selector: 12 | app: java 13 | ports: 14 | - name: "8080" 15 | port: 8080 16 | targetPort: 8080 17 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1-expected/mysql/mysql-configmap.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: ConfigMap 6 | metadata: 7 | name: mysql 8 | labels: 9 | app: mysql 10 | annotations: 11 | file/index: "0" 12 | file/path: mysql-configmap.resource.yaml 13 | package/name: mysql 14 | package/original-name: mysql 15 | data: 16 | master.cnf: | 17 | # Apply this config only on the master. 18 | [mysqld] 19 | log-bin 20 | slave.cnf: | 21 | # Apply this config only on slaves. 22 | [mysqld] 23 | super-read-only 24 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1-expected/mysql/mysql-service.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: Service 6 | metadata: 7 | name: mysql 8 | labels: 9 | app: mysql 10 | spec: 11 | selector: 12 | app: mysql 13 | ports: 14 | - name: mysql 15 | port: 3306 16 | clusterIP: None 17 | --- 18 | apiVersion: v1 19 | kind: Service 20 | metadata: 21 | name: mysql-read 22 | labels: 23 | app: mysql 24 | spec: 25 | selector: 26 | app: mysql 27 | ports: 28 | - name: mysql 29 | port: 3306 30 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1-expected/wordpress/wordpress-service.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: Service 6 | metadata: 7 | name: wordpress 8 | labels: 9 | app: wordpress 10 | spec: 11 | type: NodePort 12 | selector: 13 | app: wordpress 14 | tier: frontend 15 | ports: 16 | - port: 80 17 | nodePort: 30000 18 | --- 19 | apiVersion: v1 20 | kind: Service 21 | metadata: 22 | name: wordpress-identity 23 | labels: 24 | app: wordpress-identity 25 | spec: 26 | selector: 27 | app: wordpress 28 | tier: frontend 29 | ports: 30 | - port: 80 31 | nodePort: 30000 32 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1-localupdates/java/java-configmap.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: ConfigMap 6 | metadata: 7 | name: app-config 8 | labels: 9 | app.kubernetes.io/component: undefined 10 | app.kubernetes.io/instance: undefined 11 | data: {} 12 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1-localupdates/java/java-service.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: Service 6 | metadata: 7 | name: app 8 | labels: 9 | app: java 10 | spec: 11 | selector: 12 | app: java 13 | ports: 14 | - name: "8080" 15 | port: 8080 16 | targetPort: 8080 17 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1-localupdates/wordpress/wordpress-service.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: Service 6 | metadata: 7 | name: wordpress 8 | labels: 9 | app: wordpress 10 | spec: 11 | type: NodePort 12 | selector: 13 | app: wordpress 14 | tier: frontend 15 | ports: 16 | - port: 80 17 | nodePort: 30000 18 | --- 19 | apiVersion: v1 20 | kind: Service 21 | metadata: 22 | name: wordpress-identity 23 | labels: 24 | app: wordpress-identity 25 | spec: 26 | selector: 27 | app: wordpress 28 | tier: frontend 29 | ports: 30 | - port: 80 31 | nodePort: 30000 32 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1-remoteupdates/java/java-configmap.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: ConfigMap 6 | metadata: 7 | name: app-config 8 | labels: 9 | app.kubernetes.io/component: undefined 10 | app.kubernetes.io/instance: undefined 11 | data: {} 12 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1-remoteupdates/java/java-service.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: Service 6 | metadata: 7 | name: app 8 | labels: 9 | app: java 10 | spec: 11 | selector: 12 | app: java 13 | ports: 14 | - name: "8080" 15 | port: 8080 16 | targetPort: 8080 17 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1-remoteupdates/mysql/mysql-configmap.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: ConfigMap 6 | metadata: 7 | name: mysql 8 | labels: 9 | app: mysql 10 | annotations: 11 | file/index: "0" 12 | file/path: mysql-configmap.resource.yaml 13 | package/name: mysql 14 | package/original-name: mysql 15 | data: 16 | master.cnf: | 17 | # Apply this config only on the master. 18 | [mysqld] 19 | log-bin 20 | slave.cnf: | 21 | # Apply this config only on slaves. 22 | [mysqld] 23 | super-read-only 24 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1-remoteupdates/mysql/mysql-service.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: Service 6 | metadata: 7 | name: mysql 8 | labels: 9 | app: mysql 10 | spec: 11 | selector: 12 | app: mysql 13 | ports: 14 | - name: mysql 15 | port: 3306 16 | clusterIP: None 17 | --- 18 | apiVersion: v1 19 | kind: Service 20 | metadata: 21 | name: mysql-read 22 | labels: 23 | app: mysql 24 | spec: 25 | selector: 26 | app: mysql 27 | ports: 28 | - name: mysql 29 | port: 3306 30 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1/java/java-configmap.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: ConfigMap 6 | metadata: 7 | name: app-config 8 | labels: 9 | app.kubernetes.io/component: undefined 10 | app.kubernetes.io/instance: undefined 11 | data: {} 12 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1/java/java-service.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: Service 6 | metadata: 7 | name: app 8 | labels: 9 | app: java 10 | spec: 11 | selector: 12 | app: java 13 | ports: 14 | - name: "8080" 15 | port: 8080 16 | targetPort: 8080 17 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1/rails/rails-configmap.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: ConfigMap 6 | metadata: 7 | name: rails-app-config 8 | labels: 9 | app.kubernetes.io/component: undefined 10 | app.kubernetes.io/instance: undefined 11 | data: {} 12 | -------------------------------------------------------------------------------- /kyaml/kio/filters/testdata/dataset1/rails/rails-service.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | apiVersion: v1 5 | kind: Service 6 | metadata: 7 | name: rails-app 8 | labels: 9 | app: rails 10 | spec: 11 | selector: 12 | app: rails 13 | ports: 14 | - name: "8080" 15 | port: 8080 16 | targetPort: 8080 17 | -------------------------------------------------------------------------------- /kyaml/krmfile/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Package krmfile provides functionality for working with Krmfiles. 5 | // 6 | // Example Krmfile 7 | // 8 | // apiVersion: config.k8s.io/v1alpha1 9 | // kind: Krmfile 10 | // openAPI: 11 | // definitions: 12 | // io.k8s.cli.setters.replicas: 13 | // x-k8s-cli: 14 | // setter: 15 | // name: replicas 16 | // value: "3" 17 | // setBy: me 18 | // description: "hello world" 19 | package krmfile 20 | -------------------------------------------------------------------------------- /kyaml/krmfile/krmfile.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package krmfile 5 | 6 | // KRMFileName is the file where Krm metadata is stored 7 | const ( 8 | // KrmfileName is the name of the file that KRM metadata is written to 9 | KrmfileName = "Krmfile" 10 | ) 11 | -------------------------------------------------------------------------------- /kyaml/openapi/kubernetesapi/openapiinfo.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // Code generated by ./scripts/makeOpenApiInfoDotGo.sh; DO NOT EDIT. 5 | 6 | package kubernetesapi 7 | 8 | import ( 9 | "sigs.k8s.io/kustomize/kyaml/openapi/kubernetesapi/v1_21_2" 10 | ) 11 | 12 | const Info = "{title:Kubernetes,version:v1.21.2}" 13 | 14 | var OpenAPIMustAsset = map[string]func(string) []byte{ 15 | "v1.21.2": v1_21_2.MustAsset, 16 | } 17 | 18 | const DefaultOpenAPI = "v1.21.2" 19 | -------------------------------------------------------------------------------- /kyaml/openapi/kubernetesapi/v1_21_2/swagger.pb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/kyaml/openapi/kubernetesapi/v1_21_2/swagger.pb -------------------------------------------------------------------------------- /kyaml/openapi/scripts/generateSwaggerDotGo.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # Copyright 2020 The Kubernetes Authors. 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | MYGOBIN=$(go env GOBIN) 6 | MYGOBIN="${MYGOBIN:-$(go env GOPATH)/bin}" 7 | VERSION=$1 8 | 9 | $MYGOBIN/go-bindata \ 10 | --pkg "${VERSION//./_}" \ 11 | -o kubernetesapi/"${VERSION//./_}"/swagger.go \ 12 | kubernetesapi/"${VERSION//./_}"/swagger.pb 13 | -------------------------------------------------------------------------------- /kyaml/runfn/test/testdata/java/java-configmap.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | apiVersion: v1 4 | kind: ConfigMap 5 | metadata: 6 | name: app-config 7 | labels: 8 | app.kubernetes.io/component: undefined 9 | app.kubernetes.io/instance: undefined 10 | data: {} 11 | -------------------------------------------------------------------------------- /kyaml/runfn/test/testdata/java/java-service.resource.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | apiVersion: v1 4 | kind: Service 5 | metadata: 6 | name: app 7 | labels: 8 | app: java 9 | spec: 10 | selector: 11 | app: java 12 | ports: 13 | - name: "8080" 14 | port: 8080 15 | targetPort: 8080 16 | -------------------------------------------------------------------------------- /kyaml/sliceutil/slice.go: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package sliceutil 5 | 6 | // Contains return true if string e is present in slice s 7 | func Contains(s []string, e string) bool { 8 | for _, a := range s { 9 | if a == e { 10 | return true 11 | } 12 | } 13 | return false 14 | } 15 | 16 | // Remove removes the first occurrence of r in slice s 17 | // and returns remaining slice 18 | func Remove(s []string, r string) []string { 19 | for i, v := range s { 20 | if v == r { 21 | return append(s[:i], s[i+1:]...) 22 | } 23 | } 24 | return s 25 | } 26 | -------------------------------------------------------------------------------- /kyaml/yaml/internal/k8sgen/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // All code below this directory is generated. 5 | // See {repo}/cmd/k8scopy/main.go for more info. 6 | //go:generate k8scopy k8scopy.yaml yaml 7 | package k8sgen 8 | -------------------------------------------------------------------------------- /kyaml/yaml/internal/k8sgen/k8scopy.yaml: -------------------------------------------------------------------------------- 1 | # Copyright 2020 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | # The files to vendor (copy). 5 | # See {repo}/cmd/k8scopy/main.go for more info. 6 | module: k8s.io/apimachinery 7 | version: v0.19.8 8 | packages: 9 | - name: pkg/labels 10 | files: 11 | - labels.go 12 | - selector.go 13 | - zz_generated.deepcopy.go 14 | - name: pkg/selection 15 | files: 16 | - operator.go 17 | - name: pkg/util/sets 18 | files: 19 | - empty.go 20 | - string.go 21 | - name: pkg/util/errors 22 | files: 23 | - errors.go 24 | - name: pkg/util/validation 25 | files: 26 | - validation.go 27 | - name: pkg/util/validation/field 28 | files: 29 | - errors.go 30 | - path.go 31 | -------------------------------------------------------------------------------- /kyaml/yaml/walk/nonassociative_sequence.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package walk 5 | 6 | import ( 7 | "sigs.k8s.io/kustomize/kyaml/yaml" 8 | ) 9 | 10 | // walkNonAssociativeSequence returns the value of VisitList 11 | func (l Walker) walkNonAssociativeSequence() (*yaml.RNode, error) { 12 | return l.VisitList(l.Sources, l.Schema, NonAssociateList) 13 | } 14 | -------------------------------------------------------------------------------- /kyaml/yaml/walk/scalar.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Kubernetes Authors. 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | package walk 5 | 6 | import "sigs.k8s.io/kustomize/kyaml/yaml" 7 | 8 | // walkScalar returns the value of VisitScalar 9 | func (l Walker) walkScalar() (*yaml.RNode, error) { 10 | return l.VisitScalar(l.Sources, l.Schema) 11 | } 12 | -------------------------------------------------------------------------------- /plugin/builtin/annotationstransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/configmapgenerator/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/hashtransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/helmchartinflationgenerator/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/helmchartinflationgenerator/testdata/charts/issue4905/templates/configmap.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: ConfigMap 3 | metadata: 4 | name: {{ include "issue4905.fullname" . }} 5 | data: 6 | config.yaml: |- 7 | {{- .Values.config | toYaml | nindent 4 }} 8 | -------------------------------------------------------------------------------- /plugin/builtin/helmchartinflationgenerator/testdata/charts/issue4905/values.yaml: -------------------------------------------------------------------------------- 1 | config: # null 2 | -------------------------------------------------------------------------------- /plugin/builtin/helmchartinflationgenerator/testdata/charts/test-chart/templates/configmap.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: ConfigMap 3 | metadata: 4 | name: {{ .Values.foo }} 5 | -------------------------------------------------------------------------------- /plugin/builtin/helmchartinflationgenerator/testdata/charts/test-chart/values.yaml: -------------------------------------------------------------------------------- 1 | foo: bar 2 | -------------------------------------------------------------------------------- /plugin/builtin/helmchartinflationgenerator/testdata/charts/values-merge/Chart.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | apiVersion: v2 3 | name: values-merge 4 | version: 1.0.0 -------------------------------------------------------------------------------- /plugin/builtin/helmchartinflationgenerator/testdata/charts/values-merge/templates/test.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | apiVersion: test.kustomize.io/v1 3 | kind: ValuesMergeTest 4 | metadata: 5 | name: {{ .Chart.Name }} 6 | obj: 7 | a: {{ .Values.a }} 8 | b: {{ .Values.b }} 9 | c: {{ .Values.c }} 10 | list: {{ .Values.list | toYaml | nindent 2 }} 11 | map: 12 | a: {{ .Values.map.a }} 13 | b: {{ .Values.map.b }} 14 | c: {{ .Values.map.c }} 15 | -------------------------------------------------------------------------------- /plugin/builtin/helmchartinflationgenerator/testdata/charts/values-merge/values.yaml: -------------------------------------------------------------------------------- 1 | a: 1 2 | b: 2 3 | list: 4 | - a 5 | - b 6 | map: 7 | a: 4 8 | b: 5 9 | -------------------------------------------------------------------------------- /plugin/builtin/iampolicygenerator/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/imagetagtransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/labeltransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/namespacetransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/patchjson6902transformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/patchstrategicmergetransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/patchtransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/prefixtransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/replacementtransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/replicacounttransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/secretgenerator/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/sortordertransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/suffixtransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/builtin/valueaddtransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/someteam.example.com/v1/bashedconfigmap/BashedConfigMap: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Skip the config file name argument. 4 | shift 5 | 6 | cat <<EOF 7 | kind: ConfigMap 8 | apiVersion: v1 9 | metadata: 10 | name: example-configmap-test 11 | annotations: 12 | kustomize.config.k8s.io/needs-hash: "true" 13 | data: 14 | username: $1 15 | password: $2 16 | EOF 17 | -------------------------------------------------------------------------------- /plugin/someteam.example.com/v1/bashedconfigmap/Makefile: -------------------------------------------------------------------------------- 1 | ../../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/someteam.example.com/v1/calvinduplicator/Makefile: -------------------------------------------------------------------------------- 1 | ../../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/someteam.example.com/v1/dateprefixer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/someteam.example.com/v1/printpluginenv/Makefile: -------------------------------------------------------------------------------- 1 | ../../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/someteam.example.com/v1/printpluginenv/PrintPluginEnv: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | echo " 5 | kind: GeneratedEnv 6 | apiVersion: v1 7 | metadata: 8 | name: hello 9 | env: 10 | pwd: $PWD 11 | kustomize_plugin_home: $KUSTOMIZE_PLUGIN_HOME 12 | kustomize_plugin_config_root: $KUSTOMIZE_PLUGIN_CONFIG_ROOT 13 | " 14 | -------------------------------------------------------------------------------- /plugin/someteam.example.com/v1/secretsfromdatabase/Makefile: -------------------------------------------------------------------------------- 1 | ../../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/someteam.example.com/v1/sedtransformer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/someteam.example.com/v1/sedtransformer/SedTransformer: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Skip the config file name argument. 4 | shift 5 | args=() 6 | for arg in "$@"; do 7 | args+=(-e "$arg") 8 | done 9 | 10 | sed "${args[@]}" 11 | -------------------------------------------------------------------------------- /plugin/someteam.example.com/v1/someservicegenerator/Makefile: -------------------------------------------------------------------------------- 1 | ../../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/someteam.example.com/v1/stringprefixer/Makefile: -------------------------------------------------------------------------------- 1 | ../../../../Makefile-modules.mk -------------------------------------------------------------------------------- /plugin/someteam.example.com/v1/validator/Makefile: -------------------------------------------------------------------------------- 1 | # Copyright 2022 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | include ./../../../../Makefile-modules.mk 5 | 6 | lint: 7 | echo "Skipping lint for broken module someteam.example.com/v1/validator" 8 | -------------------------------------------------------------------------------- /plugin/untested/v1/gogetter/Makefile: -------------------------------------------------------------------------------- 1 | # Copyright 2022 The Kubernetes Authors. 2 | # SPDX-License-Identifier: Apache-2.0 3 | 4 | include ./../../../../Makefile-modules.mk 5 | 6 | lint: 7 | echo "Skipping lint for broken module untested/v1/gogetter" 8 | -------------------------------------------------------------------------------- /site/.nvmrc: -------------------------------------------------------------------------------- 1 | lts/* 2 | -------------------------------------------------------------------------------- /site/OWNERS: -------------------------------------------------------------------------------- 1 | # See https://github.com/kubernetes/community/blob/master/community-membership.md 2 | approvers: 3 | - docs-approvers 4 | 5 | reviewers: 6 | - docs-reviewers 7 | -------------------------------------------------------------------------------- /site/assets/scss/_variables_project.scss: -------------------------------------------------------------------------------- 1 | /* Kubernetes blue: https://cncf-branding.netlify.app/projects/kubernetes/ */ 2 | $primary: #326ce5; -------------------------------------------------------------------------------- /site/content/en/blog/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Docsy Blog" 3 | linkTitle: "Blog" 4 | menu: 5 | main: 6 | weight: 40 7 | --- 8 | 9 | 10 | This is the **blog** section. It has two categories: News and Releases. 11 | 12 | Files in these directories will be listed in reverse chronological order. 13 | 14 | -------------------------------------------------------------------------------- /site/content/en/blog/news/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "News About Docsy" 4 | linkTitle: "News" 5 | weight: 20 6 | --- 7 | 8 | 9 | -------------------------------------------------------------------------------- /site/content/en/blog/news/first-post/featured-sunset-get.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/content/en/blog/news/first-post/featured-sunset-get.png -------------------------------------------------------------------------------- /site/content/en/blog/releases/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "New Releases" 4 | linkTitle: "Releases" 5 | weight: 20 6 | --- 7 | 8 | 9 | -------------------------------------------------------------------------------- /site/content/en/contribute/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Contribute" 3 | linkTitle: "Contribute" 4 | type: docs 5 | menu: 6 | main: 7 | weight: 30 8 | --- 9 | -------------------------------------------------------------------------------- /site/content/en/contribute/features/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Contributing Features" 3 | linkTitle: "Contributing Features" 4 | type: docs 5 | weight: 30 6 | description: > 7 | How to contribute features 8 | --- 9 | 10 | For feature proposals, please refer to [Kustomize Enhancement Proposal Processes](https://github.com/kubernetes-sigs/kustomize/tree/master/proposals) documentation 11 | -------------------------------------------------------------------------------- /site/content/en/contribute/mac/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "MacOS Dev Guide" 3 | linkTitle: "MacOS Dev Guide" 4 | type: docs 5 | weight: 50 6 | description: > 7 | How to develop on MacOS 8 | --- 9 | 10 | First install the tools to build and run tests 11 | 12 | ### Install go 13 | 14 | [Instructions](https://golang.org/doc/install) 15 | 16 | Add `go` to your PATH 17 | 18 | ### Install tools 19 | 20 | ```sh 21 | make install-tools 22 | ``` 23 | -------------------------------------------------------------------------------- /site/content/en/docs/Concepts/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Concepts" 3 | linkTitle: "Concepts" 4 | weight: 3 5 | description: > 6 | What does your user need to understand about your project in order to use it - or potentially contribute to it? 7 | --- 8 | 9 | Might be nice to have some of those pictures from 10 | 11 | 12 | -------------------------------------------------------------------------------- /site/content/en/docs/Concepts/bases.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Bases" 3 | linkTitle: "Bases" 4 | weight: 20 5 | description: > 6 | What is a base? 7 | --- -------------------------------------------------------------------------------- /site/content/en/docs/Concepts/components.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Components" 3 | linkTitle: "Components" 4 | weight: 50 5 | description: > 6 | What is a component? 7 | --- -------------------------------------------------------------------------------- /site/content/en/docs/Concepts/functions.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Functions" 3 | linkTitle: "Functions" 4 | weight: 60 5 | description: > 6 | What is a function? 7 | --- -------------------------------------------------------------------------------- /site/content/en/docs/Concepts/generator.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Generators" 3 | linkTitle: "Generators" 4 | weight: 30 5 | description: > 6 | What is a generator? 7 | --- -------------------------------------------------------------------------------- /site/content/en/docs/Concepts/kustomization_file.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Kustomizaton File" 3 | linkTitle: "Kustomizaton File" 4 | weight: 10 5 | description: > 6 | What is the Kustomizaton file? 7 | --- -------------------------------------------------------------------------------- /site/content/en/docs/Concepts/transformers.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Transformers" 3 | linkTitle: "Transformers" 4 | weight: 40 5 | description: > 6 | What is a transformer? 7 | --- -------------------------------------------------------------------------------- /site/content/en/docs/Getting started/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Getting Started" 3 | linkTitle: "Getting Started" 4 | weight: 2 5 | --- 6 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/API/Common Definitions/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Common Definitions" 3 | linkTitle: "Common Definitions" 4 | weight: 10 5 | date: 2023-07-28 6 | description: > 7 | Common definitions are fields used across the Kustomize API. 8 | --- -------------------------------------------------------------------------------- /site/content/en/docs/Reference/API/Generators/ConfigMapGenerator.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "ConfigMapGenerator" 3 | linkTitle: "ConfigMapGenerator" 4 | weight: 1 5 | date: 2023-11-16 6 | description: > 7 | Generate ConfigMap objects. 8 | --- 9 | 10 | ## ConfigMapGenerator 11 | ConfigMapGenerator generates [ConfigMap] objects. 12 | 13 | --- 14 | 15 | * **apiVersion**: builtin 16 | * **kind**: ConfigMapGenerator 17 | * **metadata** ([ObjectMeta](https://kubernetes.io/docs/reference/kubernetes-api/common-definitions/object-meta/#ObjectMeta)) 18 | 19 | Kubernetes API object metadata. 20 | 21 | {{< include "../included/generatorargs.md" >}} 22 | 23 | [ConfigMap]: https://kubernetes.io/docs/reference/kubernetes-api/config-and-storage-resources/config-map-v1/ 24 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/API/Generators/SecretGenerator.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "SecretGenerator" 3 | linkTitle: "SecretGenerator" 4 | weight: 2 5 | date: 2023-11-16 6 | description: > 7 | Generate Secret objects. 8 | --- 9 | 10 | ## SecretGenerator 11 | SecretGenerator generates [Secret] objects. 12 | 13 | --- 14 | 15 | * **apiVersion**: builtin 16 | * **kind**: SecretGenerator 17 | * **metadata** ([ObjectMeta](https://kubernetes.io/docs/reference/kubernetes-api/common-definitions/object-meta/#ObjectMeta)) 18 | 19 | Kubernetes API object metadata. 20 | 21 | {{< include "../included/secretargs.md" >}} 22 | 23 | [Secret]: https://kubernetes.io/docs/reference/kubernetes-api/config-and-storage-resources/secret-v1/ 24 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/API/Generators/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Generators" 3 | linkTitle: "Generators" 4 | weight: 2 5 | date: 2023-11-16 6 | description: > 7 | Generators create Kubernetes API resources from metadata. 8 | --- 9 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/API/Kustomization File/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Kustomization File" 3 | linkTitle: "Kustomization File" 4 | weight: 1 5 | date: 2023-09-17 6 | description: > 7 | The Kustomization file is the entry point for Kustomize execution. 8 | --- 9 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/API/Kustomization File/commonAnnotations.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "commonAnnotations" 3 | linkTitle: "commonAnnotations" 4 | type: docs 5 | weight: 3 6 | description: > 7 | Add Annotations to all resources. 8 | --- 9 | `apiVersion: kustomize.config.k8s.io/v1beta1` 10 | 11 | See the [Tasks section] for examples of how to use `commonAnnotations`. 12 | 13 | ### commonAnnotations 14 | Adds [Annotations] to all resources. 15 | 16 | * **commonAnnotations** (map[string]string) 17 | 18 | Map of annotations to add to all resources. 19 | 20 | [Tasks section]: /docs/tasks/labels_and_annotations/ 21 | [Annotations]: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ 22 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/API/Kustomization File/namePrefix.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "namePrefix" 3 | linkTitle: "namePrefix" 4 | type: docs 5 | weight: 11 6 | description: > 7 | Add prefixes to the names of all resources. 8 | --- 9 | `apiVersion: kustomize.config.k8s.io/v1beta1` 10 | 11 | See the [Tasks section] for examples of how to use `namePrefix`. 12 | 13 | ### namePrefix 14 | Add prefixes to the names of all resources. 15 | 16 | * **namePrefix** (string) 17 | 18 | NamePrefix will add a prefix to the names of all resources mentioned in the Kustomization file including generated resources such as ConfigMaps and Secrets. 19 | 20 | 21 | [Tasks section]: /docs/tasks/namespaces_and_names/ 22 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/API/Kustomization File/nameSuffix.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "nameSuffix" 3 | linkTitle: "nameSuffix" 4 | type: docs 5 | weight: 13 6 | description: > 7 | Add suffixes to the names of all resources. 8 | --- 9 | `apiVersion: kustomize.config.k8s.io/v1beta1` 10 | 11 | See the [Tasks section] for examples of how to use `nameSuffix`. 12 | 13 | ### nameSuffix 14 | Add suffixes to the names of all resources. 15 | 16 | * **nameSuffix** (string) 17 | 18 | NameSuffix will add a suffix to the names of all resources mentioned in the Kustomization file including generated resources such as ConfigMaps and Secrets. 19 | 20 | 21 | [Tasks section]: /docs/tasks/namespaces_and_names/ 22 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/API/Kustomization File/namespace.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "namespace" 3 | linkTitle: "namespace" 4 | type: docs 5 | weight: 12 6 | description: > 7 | Adds namespace to all resources. 8 | --- 9 | `apiVersion: kustomize.config.k8s.io/v1beta1` 10 | 11 | See the [Tasks section] for examples of how to use `namespace`. 12 | 13 | ### namespace 14 | Adds namespace to all resources. 15 | 16 | * **namespace** (string) 17 | 18 | Namespace to add to all resources. This will override Namespace values that already exist. 19 | 20 | 21 | [Tasks section]: /docs/tasks/namespaces_and_names/ 22 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/API/Transformers/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Transformers" 3 | linkTitle: "Transformers" 4 | weight: 3 5 | date: 2023-07-28 6 | description: > 7 | Transformers have the ability to modify user-input resources. 8 | --- 9 | 10 | Transformers are Kubernetes objects that dictate how Kustomize changes other Kubernetes objects that users provide. 11 | Besides `spec`, transformers require the same [fields](https://kubernetes.io/docs/concepts/overview/working-with-objects/#required-fields), listed below, as other Kubernetes objects: 12 | 13 | * `apiVersion` 14 | * `kind` 15 | * `metadata` 16 | * `name` 17 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/API/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "API" 3 | linkTitle: "API" 4 | weight: 2 5 | date: 2023-07-28 6 | description: > 7 | The Kustomize API is the set of custom resources that define its behavior. 8 | --- 9 | 10 | This section contains user-friendly definitions of resources custom to Kustomize that define its behavior. 11 | Required fields are marked as such. 12 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/API/included/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "api included" 3 | description: "Snippets to be included in api pages." 4 | headless: true 5 | toc_hide: true 6 | _build: 7 | list: never 8 | render: never 9 | publishResources: false 10 | --- 11 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/API/included/secretargs.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "secretargs" 3 | weight: 2 4 | date: 2023-11-17 5 | description: > 6 | SecretArgs contains arguments to generate Secrets. 7 | headless: true 8 | _build: 9 | list: never 10 | render: never 11 | publishResources: false 12 | --- 13 | 14 | {{< include "generatorargs.md" >}} 15 | 16 | * **type** (string), optional 17 | 18 | Type of the secret. Must be `Opaque` or `kubernetes.io/tls`. Defaults to `Opaque`. 19 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Reference" 3 | linkTitle: "Reference" 4 | weight: 9 5 | date: 2023-07-28 6 | description: > 7 | References are the low-level definitions in Kustomize. 8 | --- 9 | -------------------------------------------------------------------------------- /site/content/en/docs/Reference/glossary.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Glossary" 3 | linkTitle: "Glossary" 4 | weight: 1 5 | date: 2023-07-28 6 | description: > 7 | Glossary defines terminology used to interact with Kustomize. 8 | --- -------------------------------------------------------------------------------- /site/content/en/docs/Tasks/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Tasks" 3 | linkTitle: "Tasks" 4 | weight: 4 5 | date: 2023-10-06 6 | description: > 7 | Kustomize core tasks 8 | --- 9 | 10 | This section of the Kustomize documentation contains pages that show how to do individual tasks. A task page shows how to do a single thing, typically by giving a short sequence of steps. 11 | -------------------------------------------------------------------------------- /site/content/en/docs/Tutorials/custom_application.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Deploying a Custom Application" 3 | linkTitle: "Deploying a Custom Application" 4 | weight: 1 5 | date: 2017-01-05 6 | description: > 7 | How to use Kustomize to deploy an in-house application 8 | --- -------------------------------------------------------------------------------- /site/content/en/docs/Tutorials/off_the_shelf_application.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Deploying an Off-The-Shelf Application" 3 | linkTitle: "Deploying an Off-The-Shelf Application" 4 | weight: 1 5 | date: 2017-01-05 6 | description: > 7 | How to use Kustomize to deploy a third-party application 8 | --- -------------------------------------------------------------------------------- /site/content/en/faq/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "FAQ" 3 | linkTitle: "FAQ" 4 | type: docs 5 | menu: 6 | main: 7 | weight: 70 8 | --- 9 | 10 | <!--- 11 | TODO: add general FAQ info 12 | --> 13 | -------------------------------------------------------------------------------- /site/content/en/faq/eschewedfeatures.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Eschewed Features" 3 | linkTitle: "Eschewed Features" 4 | type: docs 5 | weight: 99 6 | description: > 7 | Eschewed Features 8 | --- 9 | 10 | <!--- 11 | TODO 12 | --> 13 | -------------------------------------------------------------------------------- /site/content/en/faq/versioningPolicy.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Versioning Policy" 3 | linkTitle: "Versioning Policy" 4 | weight: 99 5 | type: docs 6 | --- 7 | <!--- 8 | TODO 9 | --> 10 | -------------------------------------------------------------------------------- /site/content/en/includes/index.md: -------------------------------------------------------------------------------- 1 | --- 2 | headless: true 3 | --- 4 | -------------------------------------------------------------------------------- /site/content/en/search.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Search Results 3 | layout: search 4 | 5 | --- 6 | 7 | -------------------------------------------------------------------------------- /site/content/fa/about/featured-background.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/content/fa/about/featured-background.jpg -------------------------------------------------------------------------------- /site/content/fa/blog/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "بلاگ داکسی" 3 | linkTitle: "بلاگ" 4 | menu: 5 | main: 6 | weight: 30 7 | --- 8 | 9 | اینجا قسمت **بلاگ** است و دو دسته بندی دارد: اخبار و نسخه های منتشر شده. 10 | فایل های داخل این دو پوشه به ترتیب عکس زمانی لیست میشوند. -------------------------------------------------------------------------------- /site/content/fa/blog/news/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "اخبار داکسی" 4 | linkTitle: "اخبار" 5 | weight: 20 6 | --- 7 | 8 | 9 | -------------------------------------------------------------------------------- /site/content/fa/blog/news/first-post/featured-sunset-get.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/content/fa/blog/news/first-post/featured-sunset-get.png -------------------------------------------------------------------------------- /site/content/fa/blog/releases/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "نسخه های منتشر شده" 4 | linkTitle: "نسخه های منتشر شده" 5 | weight: 20 6 | --- 7 | 8 | 9 | -------------------------------------------------------------------------------- /site/content/fa/community/_index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: انجمن 3 | menu: 4 | main: 5 | weight: 40 6 | --- 7 | 8 | <!--add blocks of content here to add more sections to the community page --> 9 | -------------------------------------------------------------------------------- /site/content/fa/search.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: نتایج جستجو 3 | layout: جستجو 4 | 5 | --- 6 | 7 | -------------------------------------------------------------------------------- /site/content/no/_index.html: -------------------------------------------------------------------------------- 1 | +++ 2 | title = "TechOS" 3 | linkTitle = "TechOS" 4 | 5 | +++ 6 | 7 | {{< blocks/cover title="Dette er TechOS!" image_anchor="top" height="full" >}} 8 | <div class="mx-auto"> 9 | <a class="btn btn-lg btn-primary mr-3 mb-4" href="{{< relref "/docs" >}}"> 10 | Dokumentasjon <i class="fas fa-arrow-alt-circle-right ml-2"></i> 11 | </a> 12 | <a class="btn btn-lg btn-secondary mr-3 mb-4" href="https://github.com/bep"> 13 | Last ned <i class="fab fa-github ml-2 "></i> 14 | </a> 15 | <p class="lead mt-5">TechOS kan nå lastes ned i <a href="#">AppStore!</a></p> 16 | <div class="mx-auto mt-5"> 17 | {{< blocks/link-down color="info" >}} 18 | </div> 19 | </div> 20 | {{< /blocks/cover >}} 21 | 22 | 23 | -------------------------------------------------------------------------------- /site/content/no/docs/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "TechOS-Dokumentasjon" 4 | linkTitle: "Dokumentasjon" 5 | weight: 20 6 | menu: 7 | main: 8 | weight: 20 9 | --- 10 | 11 | Dette er landingssiden til en seksjon på øverste nivå. 12 | 13 | * Oppsummer 14 | * Seksjonen din 15 | * Her 16 | 17 | 18 | -------------------------------------------------------------------------------- /site/content/no/docs/api-reference/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "Komplett API-referance" 4 | linkTitle: "API-referanse" 5 | date: 2017-01-02 6 | description: > 7 | En kort oppsummering av denne siden. Tekst kan **utheves** sller skrives i _kursiv_ og kan ha flere avsnitt. 8 | --- 9 | 10 | Dette er landingssiden til en seksjon et sted nede i seksjonshierarkiet. 11 | 12 | * Oppsummer 13 | * Seksjonen din 14 | * Her 15 | 16 | 17 | -------------------------------------------------------------------------------- /site/content/no/docs/api-reference/examples/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "Praktiske eksempler" 4 | linkTitle: "Eksempler" 5 | date: 2017-01-03 6 | description: > 7 | En kort oppsummering av denne siden. Tekst kan **utheves** sller skrives i _kursiv_ og kan ha flere avsnitt. 8 | --- 9 | 10 | Dette er landingssiden til en seksjon et sted nede i seksjonshierarkiet. 11 | 12 | * Oppsummer 13 | * Seksjonen din 14 | * Her 15 | 16 | 17 | -------------------------------------------------------------------------------- /site/content/no/docs/big-data/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "Store mengder data" 4 | linkTitle: "Big Data" 5 | date: 2017-01-01 6 | description: > 7 | En kort oppsummering av denne siden. Tekst kan **utheves** sller skrives i _kursiv_ og kan ha flere avsnitt. 8 | --- 9 | 10 | Dette er landingssiden til en seksjon et sted nede i seksjonshierarkiet. 11 | 12 | * Oppsummer 13 | * Seksjonen din 14 | * Her 15 | 16 | 17 | -------------------------------------------------------------------------------- /site/content/no/docs/big-data/examples/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "Praktiske eksempler" 4 | linkTitle: "Eksempler" 5 | date: 2017-01-02 6 | description: > 7 | En kort oppsummering av denne siden. Tekst kan **utheves** sller skrives i _kursiv_ og kan ha flere avsnitt. 8 | --- 9 | 10 | Dette er landingssiden til en seksjon et sted nede i seksjonshierarkiet. 11 | 12 | * Oppsummer 13 | * Seksjonen din 14 | * Her 15 | 16 | 17 | -------------------------------------------------------------------------------- /site/content/no/docs/big-data/tutorials/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "Steg for steg hjelpeartikler" 4 | linkTitle: "Hjelpeartikler" 5 | date: 2017-01-01 6 | description: > 7 | En kort oppsummering av denne siden. Tekst kan **utheves** sller skrives i _kursiv_ og kan ha flere avsnitt. 8 | --- 9 | 10 | Dette er landingssiden til en seksjon et sted nede i seksjonshierarkiet. 11 | 12 | * Oppsummer 13 | * Seksjonen din 14 | * Her 15 | 16 | 17 | -------------------------------------------------------------------------------- /site/content/no/docs/cloud-computing/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "Data i skyen" 4 | linkTitle: "Sky-data" 5 | date: 2017-01-03 6 | description: > 7 | En kort oppsummering av denne siden. Tekst kan **utheves** sller skrives i _kursiv_ og kan ha flere avsnitt. 8 | --- 9 | 10 | Dette er landingssiden til en seksjon et sted nede i seksjonshierarkiet. 11 | 12 | * Oppsummer 13 | * Seksjonen din 14 | * Her 15 | 16 | 17 | -------------------------------------------------------------------------------- /site/content/no/docs/cloud-computing/examples/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "Praktiske eksempler" 4 | linkTitle: "Eksempler" 5 | date: 2017-01-04 6 | description: > 7 | En kort oppsummering av denne siden. Tekst kan **utheves** sller skrives i _kursiv_ og kan ha flere avsnitt. 8 | --- 9 | 10 | Dette er landingssiden til en seksjon et sted nede i seksjonshierarkiet. 11 | 12 | * Oppsummer 13 | * Seksjonen din 14 | * Her 15 | 16 | 17 | -------------------------------------------------------------------------------- /site/content/no/docs/cloud-computing/tutorials/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "Steg for steg hjelpeartikler" 4 | linkTitle: "Hjelpeartikler" 5 | date: 2017-01-03 6 | description: > 7 | En kort oppsummering av denne siden. Tekst kan **utheves** sller skrives i _kursiv_ og kan ha flere avsnitt. 8 | --- 9 | 10 | Dette er landingssiden til en seksjon et sted nede i seksjonshierarkiet. 11 | 12 | * Oppsummer 13 | * Seksjonen din 14 | * Her 15 | 16 | 17 | -------------------------------------------------------------------------------- /site/content/no/docs/content-management/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "Håndtering av innhold" 4 | linkTitle: "Innholdshåndtering" 5 | date: 2017-01-04 6 | description: > 7 | En kort oppsummering av denne siden. Tekst kan **utheves** sller skrives i _kursiv_ og kan ha flere avsnitt. 8 | --- 9 | 10 | Dette er landingssiden til en seksjon et sted nede i seksjonshierarkiet. 11 | 12 | * Oppsummer 13 | * Seksjonen din 14 | * Her 15 | 16 | 17 | -------------------------------------------------------------------------------- /site/content/no/docs/content-management/tutorials/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "Steg for steg hjelpeartikler" 4 | linkTitle: "Hjelpeartikler" 5 | date: 2017-01-04 6 | description: > 7 | En kort oppsummering av denne siden. Tekst kan **utheves** sller skrives i _kursiv_ og kan ha flere avsnitt. 8 | --- 9 | 10 | Dette er landingssiden til en seksjon et sted nede i seksjonshierarkiet. 11 | 12 | * Oppsummer 13 | * Seksjonen din 14 | * Her 15 | 16 | 17 | -------------------------------------------------------------------------------- /site/content/no/docs/cross-platform/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "Flere plattformer" 4 | linkTitle: "Flerplattform" 5 | date: 2017-01-05 6 | description: > 7 | En kort oppsummering av denne siden. Tekst kan **utheves** sller skrives i _kursiv_ og kan ha flere avsnitt. 8 | --- 9 | 10 | Dette er landingssiden til en seksjon et sted nede i seksjonshierarkiet. 11 | 12 | * Oppsummer 13 | * Seksjonen din 14 | * Her 15 | 16 | 17 | -------------------------------------------------------------------------------- /site/content/no/docs/cross-platform/examples/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "Praktiske eksempler" 4 | linkTitle: "Eksempler" 5 | date: 2017-01-05 6 | description: > 7 | En kort oppsummering av denne siden. Tekst kan **utheves** sller skrives i _kursiv_ og kan ha flere avsnitt. 8 | --- 9 | 10 | Dette er landingssiden til en seksjon et sted nede i seksjonshierarkiet. 11 | 12 | * Oppsummer 13 | * Seksjonen din 14 | * Her 15 | 16 | 17 | -------------------------------------------------------------------------------- /site/content/no/docs/cross-platform/tutorials/_index.md: -------------------------------------------------------------------------------- 1 | 2 | --- 3 | title: "Steg for steg hjelpeartikler" 4 | linkTitle: "Hjelpeartikler" 5 | date: 2017-01-06 6 | description: > 7 | En kort oppsummering av denne siden. Tekst kan **utheves** sller skrives i _kursiv_ og kan ha flere avsnitt. 8 | --- 9 | 10 | Dette er landingssiden til en seksjon et sted nede i seksjonshierarkiet. 11 | 12 | * Oppsummer 13 | * Seksjonen din 14 | * Her 15 | 16 | 17 | -------------------------------------------------------------------------------- /site/content/no/search.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Søkeresultat 3 | layout: search 4 | 5 | --- 6 | 7 | -------------------------------------------------------------------------------- /site/docker-compose.yaml: -------------------------------------------------------------------------------- 1 | version: "3.3" 2 | 3 | services: 4 | 5 | site: 6 | image: kustomize/kustomize-website:alpha 7 | build: 8 | context: . 9 | command: server 10 | ports: 11 | - "1313:1313" 12 | volumes: 13 | - .:/src 14 | -------------------------------------------------------------------------------- /site/i18n/en.toml: -------------------------------------------------------------------------------- 1 | # i18n strings for the English (main) site. 2 | # NOTE: Please keep the entries in alphabetical order when editing 3 | 4 | [main_copyright_notice] 5 | other = """The Linux Foundation ®. All rights reserved. The Linux Foundation has registered trademarks and uses trademarks. For a list of trademarks of The Linux Foundation, please see our <a href="https://www.linuxfoundation.org/trademark-usage" class="light-text">Trademark Usage page</a>""" 6 | 7 | [main_documentation_license] 8 | other = """The Kubernetes Authors | Documentation Distributed under <a href="https://git.k8s.io/website/LICENSE" class="light-text">CC BY 4.0</a>""" 9 | -------------------------------------------------------------------------------- /site/layouts/404.html: -------------------------------------------------------------------------------- 1 | {{ define "main"}} 2 | <main id="main"> 3 | <div> 4 | <h1 id="title">Not found</h1> 5 | <p>Oops! This page doesn't exist. Try going back to our <a href="{{ "/" | relURL }}">home page</a>.</p> 6 | 7 | <p>You can learn how to make a 404 page like this in <a href="https://gohugo.io/templates/404/">Custom 404 Pages</a>.</p> 8 | </div> 9 | </main> 10 | {{ end }} 11 | -------------------------------------------------------------------------------- /site/layouts/shortcodes/example-major-version.html: -------------------------------------------------------------------------------- 1 | {{- $latestVersion := site.Params.kustomize_example_version -}} 2 | {{- $latestSemverParts := (split $latestVersion ".") -}} 3 | {{- $latestSemver := (index $latestSemverParts 0) -}} 4 | {{- $latestSemver -}} 5 | -------------------------------------------------------------------------------- /site/layouts/shortcodes/example-semver-version.html: -------------------------------------------------------------------------------- 1 | {{- $latestVersion := site.Params.kustomize_example_version -}} 2 | {{- $latestSemver := (replace $latestVersion "v" "") -}} 3 | {{- $latestSemver -}} 4 | -------------------------------------------------------------------------------- /site/layouts/shortcodes/example-version.html: -------------------------------------------------------------------------------- 1 | {{- site.Params.kustomize_example_version -}} 2 | -------------------------------------------------------------------------------- /site/netlify.toml: -------------------------------------------------------------------------------- 1 | [build] 2 | base = "site/" 3 | command = "git submodule update --init --recursive --depth 1 && hugo" 4 | publish = "publishedSite/" 5 | 6 | [build.environment] 7 | HUGO_VERSION = "0.120.4" 8 | NODE_ENV = "development" 9 | NETLIFY_BUILD_DEBUG = "true" 10 | 11 | [context.deploy-preview] 12 | command = "git submodule update --init --recursive --depth 1 && hugo --enableGitInfo --buildFuture -b $DEPLOY_PRIME_URL" 13 | 14 | [context.branch-deploy] 15 | ignore = "exit 0" # build PRs (deploy preview env) only, not all branches 16 | 17 | [context.production] 18 | ignore = "exit 0" # never deploy production until we're ready to launch 19 | -------------------------------------------------------------------------------- /site/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "tech-doc-hugo", 3 | "version": "0.0.1", 4 | "description": "Hugo theme for technical documentation.", 5 | "main": "none.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "repository": { 10 | "type": "git", 11 | "url": "git+https://github.com/google/docsy-example.git" 12 | }, 13 | "author": "", 14 | "license": "ISC", 15 | "bugs": { 16 | "url": "https://github.com/google/docsy-example/issues" 17 | }, 18 | "homepage": "https://github.com/google/docsy-example#readme", 19 | "devDependencies": { 20 | "autoprefixer": "^10.4.2", 21 | "postcss": "^8.4.31", 22 | "postcss-cli": "^9.1.0" 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /site/scripts/hash-files.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # this script emits as hash for the files listed in $@ 3 | if command -v shasum >/dev/null 2>&1; then 4 | cat "$@" | shasum -a 256 | cut -d' ' -f1 5 | elif command -v sha256sum >/dev/null 2>&1; then 6 | cat "$@" | sha256sum | cut -d' ' -f1 7 | else 8 | echo "missing shasum tool" 1>&2 9 | exit 1 10 | fi 11 | -------------------------------------------------------------------------------- /site/static/favicons/android-144x144.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/android-144x144.png -------------------------------------------------------------------------------- /site/static/favicons/android-192x192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/android-192x192.png -------------------------------------------------------------------------------- /site/static/favicons/android-36x36.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/android-36x36.png -------------------------------------------------------------------------------- /site/static/favicons/android-48x48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/android-48x48.png -------------------------------------------------------------------------------- /site/static/favicons/android-72x72.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/android-72x72.png -------------------------------------------------------------------------------- /site/static/favicons/android-96x96.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/android-96x96.png -------------------------------------------------------------------------------- /site/static/favicons/apple-touch-icon-180x180.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/apple-touch-icon-180x180.png -------------------------------------------------------------------------------- /site/static/favicons/favicon-1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/favicon-1024.png -------------------------------------------------------------------------------- /site/static/favicons/favicon-16x16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/favicon-16x16.png -------------------------------------------------------------------------------- /site/static/favicons/favicon-256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/favicon-256.png -------------------------------------------------------------------------------- /site/static/favicons/favicon-32x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/favicon-32x32.png -------------------------------------------------------------------------------- /site/static/favicons/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/favicon.ico -------------------------------------------------------------------------------- /site/static/favicons/pwa-192x192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/pwa-192x192.png -------------------------------------------------------------------------------- /site/static/favicons/pwa-512x512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/pwa-512x512.png -------------------------------------------------------------------------------- /site/static/favicons/tile150x150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/tile150x150.png -------------------------------------------------------------------------------- /site/static/favicons/tile310x150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/tile310x150.png -------------------------------------------------------------------------------- /site/static/favicons/tile310x310.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/tile310x310.png -------------------------------------------------------------------------------- /site/static/favicons/tile70x70.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kubernetes-sigs/kustomize/f9ab532a4a686677e930847f83137479730e26db/site/static/favicons/tile70x70.png --------------------------------------------------------------------------------