Skip to content

Commit ab9a269

Browse files
feat(argus): handle generic domain for govcloud (#425)
* feat(argus): handle generic domain for govcloud * feat(argus): added companyDomain examples * feat(argus): added check for empty companyDomain
1 parent 3318a07 commit ab9a269

File tree

5 files changed

+34
-2
lines changed

5 files changed

+34
-2
lines changed

charts/argus/Chart.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ maintainers:
66
77
name: LogicMonitor
88
name: argus
9-
version: 10.3.0-rt01
9+
version: 11.0.0-rc01
1010
home: https://logicmonitor.github.io/helm-charts-qa
11-
appVersion: v14.3.0-rt01
11+
appVersion: v15.0.0-rc01
1212
dependencies:
1313
- name: lmutil
1414
repository: https://logicmonitor.github.io/helm-charts-qa

charts/argus/templates/_helpers.tpl

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,15 @@ Argus proxy details or not, for this we're using Lookup function in helm.
159159
secretKeyRef:
160160
name: {{ include "lmutil.secret-name" . }}
161161
key: account
162+
- name: COMPANY_DOMAIN
163+
{{- if and .Values.global.userDefinedSecret (or (not (hasKey $secretData "companyDomain")) (eq (get $secretData "companyDomain") "")) }}
164+
value: "logicmonitor.com"
165+
{{- else }}
166+
valueFrom:
167+
secretKeyRef:
168+
name: {{ include "lmutil.secret-name" . }}
169+
key: companyDomain
170+
{{- end}}
162171
{{- if $secretData.etcdDiscoveryToken }}
163172
- name: ETCD_DISCOVERY_TOKEN
164173
valueFrom:

charts/argus/templates/secret.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ data:
1515
accessID: {{ if .Values.accessID }} {{ .Values.accessID | b64enc }} {{ else }} {{ required "A valid .Values.accessID or .Values.global.accessID entry is required!" .Values.global.accessID | b64enc }} {{ end }}
1616
accessKey: {{ if .Values.accessKey }} {{ .Values.accessKey | b64enc }} {{ else }} {{ required "A valid .Values.accessKey or .Values.global.accessKey entry is required!" .Values.global.accessKey | b64enc }} {{ end }}
1717
account: {{ if .Values.account }} {{ .Values.account | b64enc }} {{ else }} {{ required "A valid .Values.account or .Values.global.account entry is required!" .Values.global.account | b64enc }} {{ end }}
18+
companyDomain: {{ if not (empty .Values.global.companyDomain) }}{{ .Values.global.companyDomain | b64enc }}{{ else }}{{ "logicmonitor.com" | b64enc }}{{ end }}
1819
etcdDiscoveryToken: {{ default "" .Values.etcdDiscoveryToken | b64enc | quote }}
1920
{{- if .Values.proxy.user }}
2021
proxyUser: {{ default "" .Values.proxy.user | b64enc }}

charts/argus/values.schema.json

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
"accessID": "",
1111
"accessKey": "",
1212
"account": "",
13+
"companyDomain": "",
1314
"clusterName": "",
1415
"clusterTreeParentID": 1,
1516
"enableLegacyResourceTree": false,
@@ -131,6 +132,7 @@
131132
"accessID": "",
132133
"accessKey": "",
133134
"account": "",
135+
"companyDomain": "",
134136
"proxy": {
135137
"url": "",
136138
"user": "",
@@ -189,6 +191,18 @@
189191
],
190192
"$comment": "ui:accessKey-ignore tf:optional"
191193
},
194+
"companyDomain": {
195+
"$comment": "tf:optional",
196+
"$id": "#/properties/companyDomain",
197+
"type": "string",
198+
"title": "The domain schema",
199+
"description": "The Logicmonitor account domain",
200+
"examples": [
201+
"logicmonitor.com",
202+
"qa-lmgov.us",
203+
"lmgov.us"
204+
]
205+
},
192206
"account": {
193207
"$id": "#/properties/account",
194208
"type": "string",
@@ -2304,6 +2318,13 @@
23042318
],
23052319
"$comment": "ui:account tf:optional"
23062320
},
2321+
"companyDomain" : {
2322+
"$comment" : "tf:optional",
2323+
"$id" : "#/properties/global/properties/companyDomain",
2324+
"type" : "string",
2325+
"default": "",
2326+
"description" : "The Logicmonitor account domain"
2327+
},
23072328
"imagePullSecrets": {
23082329
"description": "ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod",
23092330
"examples": [

charts/argus/values.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,7 @@ global:
211211
accessID: ""
212212
accessKey: ""
213213
account: ""
214+
companyDomain: ""
214215
proxy:
215216
url: ""
216217
user: ""

0 commit comments

Comments
 (0)