Skip to content

Commit

Permalink
actually pass the init args to the init command
Browse files Browse the repository at this point in the history
  • Loading branch information
glehmann committed Feb 13, 2023
1 parent 2660dc5 commit c963649
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 16 deletions.
4 changes: 0 additions & 4 deletions helm/ipfs/templates/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@ data:
if [ -e "$repo/config" ]; then
echo "Found IPFS fs-repo at $repo"
else
case "$IPFS_PROFILE" in
"") INIT_ARGS="" ;;
*) INIT_ARGS="--profile=$IPFS_PROFILE" ;;
esac
ipfs init $INIT_ARGS
ipfs config Addresses.Gateway /ip4/0.0.0.0/tcp/8080
Expand Down
14 changes: 2 additions & 12 deletions helm/ipfs/templates/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,18 +33,6 @@ spec:
args:
- daemon
- --migrate=true
{{- if .Values.init.profiles }}
- --profile={{ .Values.init.profiles | join "," }}
{{- end }}
{{- if .Values.init.algorithm }}
- --algorithm={{ .Values.init.argorithm }}
{{- end }}
{{- if .Values.init.bits }}
- --bits={{ .Values.init.bits }}
{{- end }}
{{- if not (kindIs "invalid" .Values.init.emptyRepo) }}
- --empty-repo={{ .Values.init.emptyRepo }}
{{- end }}
ports:
- name: swarm
containerPort: 4001
Expand All @@ -56,6 +44,8 @@ spec:
containerPort: 8080
protocol: TCP
env:
- name: INIT_ARGS
value: "{{- if .Values.init.profiles }}--profile={{ .Values.init.profiles | join "," }}{{- end }}{{- if .Values.init.algorithm }} --algorithm={{ .Values.init.argorithm }}{{- end }}{{- if .Values.init.bits }} --bits={{ .Values.init.bits }}{{- end }}{{- if not (kindIs "invalid" .Values.init.emptyRepo) }} --empty-repo={{ .Values.init.emptyRepo }}{{- end }}"
- name: IPFS_LOGGING
value: {{ .Values.log.level }}
{{- if .Values.privateNetwork.enabled }}
Expand Down

0 comments on commit c963649

Please sign in to comment.