Skip to content

Commit

Permalink
Fix p.ValuesFile when version is set
Browse files Browse the repository at this point in the history
  • Loading branch information
Dustin Lish committed Mar 22, 2023
1 parent 2da1dbd commit 2dcdc7b
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,11 @@ func (p *plugin) validateArgs() (err error) {
// be under the loader root (unless root restrictions are
// disabled).
if p.ValuesFile == "" {
p.ValuesFile = filepath.Join(p.ChartHome, p.Name, "values.yaml")
if p.Version != "" {
p.ValuesFile = filepath.Join(p.ChartHome, fmt.Sprintf("%s-%s", p.Name, p.Version), p.Name, "values.yaml")
} else {
p.ValuesFile = filepath.Join(p.ChartHome, p.Name, "values.yaml")
}
}
for i, file := range p.AdditionalValuesFiles {
// use Load() to enforce root restrictions
Expand Down

0 comments on commit 2dcdc7b

Please sign in to comment.