TykTechnologies / tyk-helm-chart

A Helm chart repository to install Tyk Pro (with Dashboard), Tyk Hybrid or Tyk Headless chart.
https://tyk.io
71 stars 55 forks source link

tyk-pro: recursive template include call #94

Closed gernest closed 3 years ago

gernest commented 3 years ago

Running

 helm template pro ./tyk-pro/

Gives the following error

Error: template: tyk-pro/templates/deployment-gw-repset.yaml:44:28: executing "tyk-pro/templates/deployment-gw-repset.yaml" at <include (print $.Template.BasePath "/deployment-gw-repset.yaml") .>: error calling include: template: tyk-pro/templates/deployment-gw-repset.yaml:44:28: executing "tyk-pro/templates/deployment-gw-repset.yaml" at <include (print $.Template.BasePath "/deployment-gw-repset.yaml") .>: error calling include: template: tyk-pro/templates/deployment-gw-repset.yaml:44:28: executing "tyk-pro/templates/deployment-gw-repset.yaml" at <include (print $.Template.BasePath "/deployment-gw-repset.yaml") .>: error calling inc

....

This error is long and exhaustive until helm bails out

reading the error it seems tyk-pro/templates/deployment-gw-repset.yaml keeps including itself recusively. A quick hunt shows the change was introduced in https://github.com/TykTechnologies/tyk-helm-chart/pull/84

The offending line is

      annotations:
        checksum/config: {{ include (print $.Template.BasePath "/deployment-gw-repset.yaml") . | sha256sum }}
gernest commented 3 years ago

Happy to address this if someone can point me in the right direction, because I need to fix https://github.com/TykTechnologies/tyk-helm-chart/issues/92 so I can unblock myself on my ongoing work to use these charts for operator development.

gernest commented 3 years ago

see #95 and #97