Skip to content

Commit

Permalink
helm: Separate artist configMap from barebones deployment
Browse files Browse the repository at this point in the history
RyanConnell committed Mar 21, 2024
1 parent 595fe1d commit 662bc37
Showing 3 changed files with 13 additions and 2 deletions.
3 changes: 2 additions & 1 deletion helm/templates/configMap.yaml
Original file line number Diff line number Diff line change
@@ -4,4 +4,5 @@ kind: ConfigMap
metadata:
name: {{ .Values.name }}-config
data:
{{ ( .Files.Glob "files/*" ).AsConfig | indent 2 }}
ticketmaster.yaml: |-
{{ .Files.Get "files/ticketmaster.yaml" | indent 4 }}
8 changes: 7 additions & 1 deletion helm/templates/cron.yaml
Original file line number Diff line number Diff line change
@@ -14,7 +14,7 @@ spec:
command:
- /bin/sh
- -c
- /bin/concert-watcher scan --api-key $TICKETMASTER_API_KEY --artist-file /config/artists --discord-webhook-url $DISCORD_WEBHOOK_URL --ticketmaster-config /config/ticketmaster.yaml --diff --diff-file /data/previous-ids --include-partial-match
- /bin/concert-watcher scan --api-key $TICKETMASTER_API_KEY --artist-file /artists --discord-webhook-url $DISCORD_WEBHOOK_URL --ticketmaster-config /config/ticketmaster.yaml --diff --diff-file /data/previous-ids --include-partial-match
env:
- name: "TICKETMASTER_API_KEY"
{{- if .Values.ticketmaster.apiKey.secret }}
@@ -35,6 +35,9 @@ spec:
value: "{{ .Values.discord.webhookURL.value }}"
{{- end }}
volumeMounts:
- name: artists
mountPath: /artists
subPath: artists
- name: config-map
mountPath: /config
- name: data
@@ -43,6 +46,9 @@ spec:
- name: config-map
configMap:
name: {{ .Values.name }}-config
- name: artists
configMap:
name: {{ .Values.artists.configMap }}
- name: data
persistentVolumeClaim:
claimName: {{ .Values.name }}-pvc
4 changes: 4 additions & 0 deletions helm/values.yaml
Original file line number Diff line number Diff line change
@@ -5,6 +5,10 @@ image:
name: ryanconnell/concert-watcher
tag: latest

artists:
# Name of the configMap containing all of our artists.
configMap: concert-watcher-artists

discord:
# Add a webhook URL to enable discord notifications.
webhookURL:

0 comments on commit 662bc37

Please sign in to comment.