_upgrade.tpl 653 B

123456789101112131415161718192021
  1. {{/*
  2. Retrieve previous chart version from which we are upgrading to a newer chart version
  3. */}}
  4. {{- define "tn.chart.old_version" -}}
  5. {{- if .Values.ixChartContext.is_upgrade -}}
  6. {{- .Values.ixChartContext.upgradeMetadata.oldChartVersion -}}
  7. {{- else -}}
  8. {{- fail "A chart upgrade is not taking place" -}}
  9. {{- end -}}
  10. {{- end -}}
  11. {{/*
  12. Retrieve new chart version to which we are upgrading from an old chart version
  13. */}}
  14. {{- define "tn.chart.new_version" -}}
  15. {{- if .Values.ixChartContext.is_upgrade -}}
  16. {{- .Values.ixChartContext.upgradeMetadata.newChartVersion -}}
  17. {{- else -}}
  18. {{- fail "A chart upgrade is not taking place" -}}
  19. {{- end -}}
  20. {{- end -}}