Skip to content

Commit

Permalink
fix(manager/helmfile): replace all templates (#17210)
Browse files Browse the repository at this point in the history
  • Loading branch information
viceice committed Aug 16, 2022
1 parent 0316a5e commit 24691ac
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions lib/modules/manager/helmfile/__fixtures__/go-template.yaml
Expand Up @@ -37,3 +37,4 @@ releases:
- name: example-public
version: 2.0.0
chart: stable/external-dns
namespace: "{{ env "NAMESPACE" }}"
2 changes: 1 addition & 1 deletion lib/modules/manager/helmfile/extract.spec.ts
Expand Up @@ -335,7 +335,7 @@ describe('modules/manager/helmfile/extract', () => {
datasource: 'helm',
deps: [
{
depName: '{{ requiredEnv "RELEASE_NAME" }}',
depName: '',
skipReason: 'local-chart',
},
{ depName: null, skipReason: 'local-chart' },
Expand Down
2 changes: 1 addition & 1 deletion lib/modules/manager/helmfile/extract.ts
Expand Up @@ -12,7 +12,7 @@ const isValidChartName = (name: string | undefined): boolean =>

function extractYaml(content: string): string {
// regex remove go templated ({{ . }}) values
return content.replace(/(^|:)\s*{{.+}}\s*$/gm, '$1');
return content.replace(regEx(/{{.+?}}/g), '');
}

export function extractPackageFile(
Expand Down

0 comments on commit 24691ac

Please sign in to comment.