-
Notifications
You must be signed in to change notification settings - Fork 289
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix merging Kubernetes configuration (#1253)
(cherry picked from commit 16b5f04)
- Loading branch information
Showing
7 changed files
with
199 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
44 changes: 44 additions & 0 deletions
44
.../source/kubernetes/testdata/TestRouterListMergingNestedFields/override-fields-config.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
event: | ||
types: | ||
- delete | ||
reason: | ||
include: ["reason-include-1-level"] | ||
exclude: ["reason-exclude-1-level"] | ||
message: | ||
include: ["message-include-1-level"] | ||
exclude: ["message-exclude-1-level"] | ||
|
||
annotations: | ||
test: "annotation-1-level" | ||
|
||
labels: | ||
test: "label-1-level" | ||
|
||
namespaces: | ||
include: ["namespace-include-1-level"] | ||
exclude: ["namespace-exclude-1-level"] | ||
|
||
resources: | ||
- type: v1/configmaps # change all nested properties | ||
namespaces: | ||
include: ["namespace-include-2-level"] | ||
exclude: ["namespace-exclude-2-level"] | ||
event: | ||
types: | ||
- create | ||
reason: | ||
include: ["reason-include-2-level"] | ||
exclude: ["reason-exclude-2-level"] | ||
message: | ||
include: ["message-include-2-level"] | ||
exclude: ["message-exclude-2-level"] | ||
annotations: | ||
test: "annotation-2-level" | ||
labels: | ||
test: "label-2-level" | ||
|
||
- type: apps/v1/deployments # change only ns | ||
namespaces: | ||
exclude: | ||
- "other" | ||
- type: v1/pod # use top level properties |
26 changes: 26 additions & 0 deletions
26
...bernetes/testdata/TestRouterListMergingNestedFields/route-apps.v1.deployments.golden.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
- event: delete | ||
routes: | ||
- resourcename: | ||
include: [] | ||
labels: | ||
test: label-1-level | ||
annotations: | ||
test: annotation-1-level | ||
namespaces: | ||
include: [] | ||
exclude: | ||
- other | ||
updatesetting: null | ||
event: | ||
reason: | ||
include: | ||
- reason-include-1-level | ||
exclude: | ||
- reason-exclude-1-level | ||
message: | ||
include: | ||
- message-include-1-level | ||
exclude: | ||
- message-exclude-1-level | ||
types: | ||
- delete |
27 changes: 27 additions & 0 deletions
27
...rce/kubernetes/testdata/TestRouterListMergingNestedFields/route-v1.configmaps.golden.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
- event: create | ||
routes: | ||
- resourcename: | ||
include: [] | ||
labels: | ||
test: label-2-level | ||
annotations: | ||
test: annotation-2-level | ||
namespaces: | ||
include: | ||
- namespace-include-2-level | ||
exclude: | ||
- namespace-exclude-2-level | ||
updatesetting: null | ||
event: | ||
reason: | ||
include: | ||
- reason-include-2-level | ||
exclude: | ||
- reason-exclude-2-level | ||
message: | ||
include: | ||
- message-include-2-level | ||
exclude: | ||
- message-exclude-2-level | ||
types: | ||
- create |
Oops, something went wrong.