Skip to content

Commit

Permalink
chore(setup,cleanup): don't template *.sh and *.tf files
Browse files Browse the repository at this point in the history
  • Loading branch information
swiatekm committed Jun 18, 2024
1 parent b561aa0 commit 09d960b
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion deploy/helm/sumologic/conf/setup/monitors.sh
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ if [[ -z "${MONITORS_FOLDER_ID}" ]]; then
)

if [ -z ${SUMOLOGIC_MONITORS_NOTIFICATIONS_RECIPIENTS+x} ]; then
NOTIFICATIONS_CONTENT="subject=\"Monitor Alert: {{ printf `{{TriggerType}}` }} on {{ printf `{{Name}}` }}\",message_body=\"Triggered {{ printf `{{TriggerType}}` }} alert on {{ printf `{{Name}}` }}: {{ printf `{{QueryURL}}` }}\""
NOTIFICATIONS_CONTENT="subject=\"Monitor Alert: {{TriggerType}} on {{Name}}\",message_body=\"Triggered {{TriggerType}} alert on {{Name}}: {{QueryURL}}\""
NOTIFICATIONS_SETTINGS="recipients=${SUMOLOGIC_MONITORS_NOTIFICATIONS_RECIPIENTS},connection_type=\"Email\",time_zone=\"UTC\""
TERRAFORM_ARGS+=(
-var="email_notifications_critical=[{${NOTIFICATIONS_SETTINGS},${NOTIFICATIONS_CONTENT},run_for_trigger_types=[\"Critical\", \"ResolvedCritical\"]}]"
Expand Down
5 changes: 3 additions & 2 deletions deploy/helm/sumologic/templates/cleanup/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ metadata:
app: {{ template "sumologic.labels.app.cleanup.configmap" . }}
{{- include "sumologic.labels.common" . | nindent 4 }}
data:
{{- (tpl (.Files.Glob "conf/cleanup/cleanup.sh").AsConfig .) | nindent 2 }}
{{- (tpl (.Files.Glob "conf/setup/*").AsConfig .) | nindent 2 }}
{{- (.Files.Glob "conf/cleanup/cleanup.sh").AsConfig | nindent 2 }}
{{- (.Files.Glob "conf/setup/*.{tf,sh}").AsConfig | nindent 2 }}
{{- (tpl (.Files.Glob "conf/setup/*.json").AsConfig .) | nindent 2 }}
{{- end }}
3 changes: 2 additions & 1 deletion deploy/helm/sumologic/templates/setup/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,6 @@ metadata:
app: {{ template "sumologic.labels.app.setup.configmap" . }}
{{- include "sumologic.labels.common" . | nindent 4 }}
data:
{{- (tpl (.Files.Glob "conf/setup/*").AsConfig .) | nindent 2 }}
{{- (.Files.Glob "conf/setup/*.{tf,sh}").AsConfig | nindent 2 }}
{{- (tpl (.Files.Glob "conf/setup/*.json").AsConfig .) | nindent 2 }}
{{- end }}

0 comments on commit 09d960b

Please sign in to comment.