-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(configmaps): skip creating configmap for Alpha Configurations whe…
…n used with OCP Proxy (#181) (#182) Signed-off-by: Thuan Vo <thuan.votann@gmail.com> (cherry picked from commit 208b142) Co-authored-by: Thuan Vo <thuan.votann@gmail.com>
- Loading branch information
1 parent
66adb75
commit d020ce8
Showing
3 changed files
with
40 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
suite: test alpha_config.yaml | ||
templates: | ||
- templates/alpha_config.yaml | ||
|
||
tests: | ||
- it: should create configmap with correct alpha configurations | ||
asserts: | ||
- matchRegex: | ||
path: data['alpha_config.yaml'] | ||
pattern: "server:\\s*BindAddress: http://0.0.0.0:4180" | ||
- matchRegex: | ||
path: data['alpha_config.yaml'] | ||
pattern: "upstreamConfig:\\s*proxyRawPath: true\\s*upstreams:\\s*- id: cryostat\\s*path: /\\s*uri: http://localhost:8181" | ||
- matchRegex: | ||
path: data['alpha_config.yaml'] | ||
pattern: "- id: grafana\\s*path: /grafana/\\s*uri: http://localhost:3000" | ||
- matchRegex: | ||
path: data['alpha_config.yaml'] | ||
pattern: "- id: storage\\s*path: \\^/storage/\\(\\.\\*\\)\\$\\s*rewriteTarget: /\\$1\\s*uri: http://localhost:8333\\s*passHostHeader: false\\s*proxyWebSockets: false" | ||
- matchRegex: | ||
path: data['alpha_config.yaml'] | ||
pattern: "providers:\\s*- id: dummy\\s*name: Unused - Sign In Below\\s*clientId: CLIENT_ID\\s*clientSecret: CLIENT_SECRET\\s*provider: google" | ||
|
||
- it: should not create alpha_config when openshift authentication is enabled | ||
set: | ||
authentication: | ||
openshift: | ||
enabled: true | ||
asserts: | ||
- hasDocuments: | ||
count: 0 |