Skip to content

Commit

Permalink
change config mount path
Browse files Browse the repository at this point in the history
  • Loading branch information
TakGN committed Jul 10, 2024
1 parent 302245c commit 249174c
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 7 deletions.
12 changes: 10 additions & 2 deletions k8s/templates/cron.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
kind: CronJob
metadata:
name: {{ .Values.name }}
name: {{ .Values.name }}-indexer
namespace: {{ .Values.namespace }}
labels:
app: {{ .Values.name }}
Expand Down Expand Up @@ -29,4 +29,12 @@ spec:
{{- range .Values.cronjob.command }}
- {{ . }}
{{- end }}
restartPolicy: {{ .Values.cronjob.restartPolicy }}
volumeMounts:
- name: config-volume
mountPath: /home/nonroot/reflux/config.yaml
subPath: config.yaml
restartPolicy: {{ .Values.cronjob.restartPolicy }}
volumes:
- name: config-volume
configMap:
name: {{ .Values.name }}
8 changes: 4 additions & 4 deletions k8s/templates/deployment.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ .Values.name }}
name: {{ .Values.name }}-solver
namespace: {{ .Values.namespace }}
labels:
app: {{ .Values.name }}
Expand Down Expand Up @@ -62,7 +62,7 @@ spec:
containers:
- name: {{ .Values.name }}
image: {{ .Values.image_name }}:{{ .Values.image_tag }}
command: [ "reflux", "--solver", "--config", "/usr/local/cargo/config.toml" ]
command: [ "reflux", "--solver", "--config", "/home/nonroot/reflux/config.yaml" ]
imagePullPolicy: {{ .Values.imagePullPolicy }}
ports:
- containerPort: {{ .Values.port }}
Expand All @@ -78,8 +78,8 @@ spec:
- mountPath: /var/run/datadog
name: apmsocketpath
- name: config-volume
mountPath: /usr/local/cargo/config.toml
subPath: config.toml
mountPath: /home/nonroot/reflux/config.yaml
subPath: config.yaml
{{- end }}
{{- if .Values.probes }}
livenessProbe:
Expand Down
2 changes: 1 addition & 1 deletion k8s/values.prod.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ cronjob:
- reflux
- --indexer
- --config
- "/usr/local/cargo/config.toml"
- /home/nonroot/reflux/config.toml
restartPolicy: OnFailure


Expand Down

0 comments on commit 249174c

Please sign in to comment.