Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Octostache variables no longer evaluate during Deploy a HELM chart #9223

Open
garrettdass opened this issue Jan 23, 2025 · 1 comment
Open
Labels
kind/bug This issue represents a verified problem we are committed to solving

Comments

@garrettdass
Copy link

garrettdass commented Jan 23, 2025

Severity

Blocking

Version

2025.1.7128

Latest Version

None

What happened?

When using variables in Template values on step Deploy a HELM chart, they are not evaluated as expected and print as the unevaluated string:

Image

Image

Unable to find file values/#{Octopus.Environment.Name}.yaml for package nginx v18.2.2
Unable to find file #{Project.HelmYamlFile} for package nginx v18.2.2

Previous versions evaluate correctly and allow the deployment to continue:

Unable to find file values/dev.yaml for package nginx v18.2.2

Reproduction

Internal instance link to repro.

Error and Stacktrace

22:42:32   Verbose  |       Unable to find values files at path `values/#{Octopus.Environment.Name | ToLower}.yaml`. Chart package contains root directory with chart name, so looking for values in there.
22:42:32   Verbose  |       Calamari.Common.Commands.CommandException: Unable to find file `values/#{Octopus.Environment.Name | ToLower}.yaml` for package nginx v18.2.2
22:42:32   Verbose  |       at Calamari.Kubernetes.Helm.PackageValuesFileWriter.FindPackageValuesFiles(RunningDeployment deployment, ICalamariFileSystem fileSystem, ILog log, String valuesFilePaths, String packageId, String packageName, Boolean logIncludedFiles) in C:\BuildAgent\work\e61a42f6adc5dcb6\source\Calamari\Kubernetes\Helm\PackageValuesFileWriter.cs:line 99
22:42:32   Verbose  |       at Calamari.Kubernetes.Helm.HelmTemplateValueSourcesParser.ParseFilenamesFromTemplateValuesArray(RunningDeployment deployment, IEnumerable`1 parsedJsonArray, Boolean logIncludedFiles) in C:\BuildAgent\work\e61a42f6adc5dcb6\source\Calamari\Kubernetes\Helm\HelmTemplateValueSourcesParser.cs:line 73
22:42:32   Verbose  |       at Calamari.Kubernetes.Helm.HelmTemplateValueSourcesParser.ParseTemplateValuesFilesFromDependencies(RunningDeployment deployment, Boolean logIncludedFiles) in C:\BuildAgent\work\e61a42f6adc5dcb6\source\Calamari\Kubernetes\Helm\HelmTemplateValueSourcesParser.cs:line 52
22:42:32   Verbose  |       at Calamari.Kubernetes.Commands.HelmUpgradeCommand.TemplateValuesFiles(RunningDeployment deployment) in C:\BuildAgent\work\e61a42f6adc5dcb6\source\Calamari\Kubernetes\Commands\HelmUpgradeCommand.cs:line 202
22:42:32   Verbose  |       at Calamari.Kubernetes.Commands.HelmUpgradeCommand.<Execute>b__14_2(RunningDeployment d) in C:\BuildAgent\work\e61a42f6adc5dcb6\source\Calamari\Kubernetes\Commands\HelmUpgradeCommand.cs:line 113
22:42:32   Verbose  |       at Calamari.Commands.DelegateInstallConvention.Install(RunningDeployment deployment) in C:\BuildAgent\work\e61a42f6adc5dcb6\source\Calamari.Shared\Commands\DelegateInstallConvention.cs:line 18
22:42:32   Verbose  |       at Calamari.Deployment.ConventionProcessor.RunInstallConventions(IEnumerable`1 installConventions) in C:\BuildAgent\work\e61a42f6adc5dcb6\source\Calamari.Shared\Deployment\ConventionProcessor.cs:line 80
22:42:32   Verbose  |       at Calamari.Deployment.ConventionProcessor.RunConventions(Boolean logExceptions) in C:\BuildAgent\work\e61a42f6adc5dcb6\source\Calamari.Shared\Deployment\ConventionProcessor.cs:line 31
22:42:32   Error    |       Unable to find file `values/#{Octopus.Environment.Name | ToLower}.yaml` for package nginx v18.2.2

More Information

Likely related to: OctopusDeploy/Calamari#1426
Internal ticket

No response

Workaround

Hardcode the variable instead.

@garrettdass garrettdass added the kind/bug This issue represents a verified problem we are committed to solving label Jan 23, 2025
@kevjt
Copy link

kevjt commented Jan 24, 2025

Duplicate of #9224

@kevjt kevjt marked this as a duplicate of #9224 Jan 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug This issue represents a verified problem we are committed to solving
Projects
None yet
Development

No branches or pull requests

2 participants