Commit Graph

330 Commits

Author SHA1 Message Date
Philipp Strube
421ca3fb3c Fix typo in namereference path for cronjobs
Fix namereference for CronJob `path: spec/jobTemplate/spec/template/spec/containers/env/valueFrom/configMapKeyRef/name`
2018-11-05 14:07:32 +01:00
Andrew Lavery
9d82d54c5b add fallback for GVK comparison
only return comparison of 'Kind' indices if they do not match
otherwise fall back to GVK string comparison
this reduces output instability
2018-11-01 12:22:21 -07:00
Jeffrey Regan
a8fbe35ecf Rename disableHash to disableNameSuffixHash 2018-10-30 11:36:00 -07:00
k8s-ci-robot
40e0bbeec2 Merge pull request #502 from Liujingfang1/yml
add support .yml extension for kusotmization file
2018-10-29 12:33:16 -07:00
Jingfang Liu
ecbf3c5f51 add support .yml extension for kusotmization file 2018-10-29 12:21:00 -07:00
jregan
793577d044 Consult history in fileloader.
Fixes #366

To reproduce #366, add

```
bases:
- .
```

to `examples/helloWorld/kustomization.yaml`, attempt to build it, and enjoy the stack overflow.

This PR fixes this by adding history to file loaders,
allowing one to avoid cycles in overlay->base
relationships.  To make entry points clearer, this PR
exposes only two public ways to make a fresh
(no-history) loader

 * rooted at `/`
 * rooted at the process's current working directory.

When making a new loader from an existing loader,
retaining history along an overlay trace, the only
allowed use is to go deeper into a file hierarchy, or
go up and over to a never before visited sibling. This
fix can probably be defeated by devious symbolic links.
2018-10-29 11:10:21 -07:00
jregan
885c1952a4 Improve test coverage. 2018-10-28 13:52:25 -07:00
Jingfang Liu
1020167e22 Revert "Skip adding nameprefix to namespace" 2018-10-26 14:42:27 -07:00
Jingfang Liu
f8a18ce662 Revert "create namespace resource if not found" 2018-10-26 14:01:53 -07:00
k8s-ci-robot
6a917c5f36 Merge pull request #508 from ryane/fix-507
kustomize build loads transformer configs when path argument omitted
2018-10-26 11:10:14 -07:00
Benjamin Elder
76ba38cec5 make k8sdeps.NewFactory() importable 2018-10-25 17:21:58 -07:00
ryane
9f73341271 kustomize build loads transformer configs when path argument omitted 2018-10-25 09:56:46 -04:00
Jingfang Liu
a5f0d457ec create namespace resource if not found 2018-10-23 13:46:03 -07:00
Jingfang Liu
9ef96e9bb2 enable preserving order with generatorOptions 2018-10-22 16:01:46 -07:00
Jeffrey Regan
6b302443e6 Test field output ordering. 2018-10-19 16:20:23 -07:00
Jingfang Liu
0cb02f1448 allow add labels/annotations to generated resources 2018-10-19 15:40:06 -07:00
Jingfang Liu
23963e854a skip hash transformer when DisableHash is set to true 2018-10-19 14:44:23 -07:00
k8s-ci-robot
04167cf77e Merge pull request #487 from monopole/deletePenultimateUseOfDeprecatedField
Delete penultimate use of Patches field.
2018-10-19 14:28:05 -07:00
k8s-ci-robot
6f0a01fcf4 Merge pull request #490 from Liujingfang1/options
Add generatorOptions in Kustomization type
2018-10-19 14:18:42 -07:00
Jingfang Liu
0824433260 Add generatorOptions in Kustomization type 2018-10-19 14:12:33 -07:00
Jeffrey Regan
3e0f5ea327 Delete penultimate use of Patches field. 2018-10-19 11:26:05 -07:00
k8s-ci-robot
a4be48eb32 Merge pull request #488 from Liujingfang1/prefix
Skip adding nameprefix to namespace
2018-10-19 10:02:43 -07:00
Jingfang Liu
90d03b0afe Skip adding nameprefix to namespace 2018-10-18 13:52:11 -07:00
k8s-ci-robot
37802e1026 Merge pull request #485 from monopole/deleteSomeUnnecessaryParmPassing
Delete some unnecessary parameter passing.
2018-10-18 11:57:28 -07:00
Jingfang Liu
90c88d7f96 skip filtering resmap when the resource is a cluster level resource 2018-10-18 11:09:24 -07:00
Jeffrey Regan
2b0e2725f9 Delete some unnecessary parameter passing. 2018-10-18 10:59:59 -07:00
Jingfang Liu
d5aed20f0a add commonLabel fieldpath for volumeClaimTemplates 2018-10-18 10:25:19 -07:00
Jeffrey Regan
8fd93030b4 Delete unused exec package. 2018-10-18 09:54:45 -07:00
k8s-ci-robot
5db1ef23fe Merge pull request #475 from Liujingfang1/namespace
add namespace to id when create resmap from files
2018-10-17 16:45:00 -07:00
Jingfang Liu
14fc54e323 add namespace to id when create resmap from files 2018-10-17 16:22:19 -07:00
jregan
a5f56027b5 Improve kustomization.go comments. 2018-10-17 14:24:20 -07:00
Jeffrey Regan
b198b65d52 Objectify nbrSlice code. 2018-10-12 16:27:50 -07:00
Jeffrey Regan
d9f9a51e55 Fix names/doc in transformation config code. 2018-10-12 13:36:22 -07:00
Jingfang Liu
40b2bf76ae Add KustFactory as a wrapper of all factories 2018-10-11 13:51:27 -07:00
Jingfang Liu
d33d154e14 split k8sdeps package into sub packages 2018-10-11 11:30:46 -07:00
Jingfang Liu
c33a97fcf2 move transformerconfig package to transformers/config 2018-10-10 15:12:32 -07:00
k8s-ci-robot
ca4a5d33f0 Merge pull request #451 from Liujingfang1/hash
add MakeHashTransformer in TransformerFactory; remove hash interface
2018-10-10 14:10:48 -07:00
Jingfang Liu
2953dad221 add MakeHashTransformer in TransformerFactory; remove hash interface 2018-10-10 14:05:13 -07:00
Jeffrey Regan
8534107fc8 Move crd package to transformerconfig.factory. 2018-10-10 13:14:43 -07:00
Jeffrey Regan
2283c06971 Consolidate transformer config creation to factory. 2018-10-10 12:33:19 -07:00
Jingfang Liu
96091dfcf5 remove decoder interface since it is only used inside k8sdeps 2018-10-10 11:08:23 -07:00
Jingfang Liu
4c7b63a215 remove dependency on apimachinery from gvk package 2018-10-09 16:25:25 -07:00
k8s-ci-robot
1e04a0e943 Merge pull request #445 from Liujingfang1/typemeta
copy TypeMeta from apimachinery
2018-10-09 16:18:09 -07:00
Jingfang Liu
f7353b1295 copy TypeMeta from apimachinery 2018-10-09 16:10:17 -07:00
Jingfang Liu
f783486057 hide core/v1 behind interface 2018-10-09 15:50:52 -07:00
jregan
df5c3ab91e Maintain fields of TransformerConfig in sorted order.
Not needed for execution, just makes logging and tests deterministic.
Related to #428
2018-10-09 10:14:57 -07:00
Jingfang Liu
62f7cdbb43 fix the flaky test in crd package 2018-10-08 16:06:35 -07:00
Jeff Regan
30814302af Fix some minor naming mistakes. (#434)
* Fix some minor naming mistakes.

* Fix some minor naming mistakes.
2018-10-08 15:58:44 -07:00
Jeff Regan
fd3cd64e11 Merge pull request #433 from Liujingfang1/patchtransformer
hide patch transformer behind interface
2018-10-08 15:32:49 -07:00
Jingfang Liu
78de5374ed hide patch transformer behind interface 2018-10-08 15:15:03 -07:00