Thomas O'Donnell
213f714604
Stop Lint from breaking when using required
...
Have updated the required filter so that it doesn't break when linting a
chart. This work is based off #4221 and #4748 which didn't make it into
the v3 branch.
Signed-off-by: Thomas O'Donnell <andy.tom@gmail.com>
5 years ago
Adam Reese
b49db9e6e6
ref(pkg/chartutil): break up chartutil into logical files
...
Signed-off-by: Adam Reese <adam@reese.io>
6 years ago
Matthew Fisher
757eb88d6c
Merge pull request #5441 from hickeyma/update-lib-charts
...
feat(*): Add capability for application charts to be used as library charts
6 years ago
Josh Dolitsky
a12a396aab
Helm 3: registry login/logout ( #5597 )
...
* login/logout placeholders
Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
* use latest oras
Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
* use docker auth system
Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
* working login+push
Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
* working on tests
Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
* fix typo in htpasswd
Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
* rename credsfile to config.json
Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
* add flags for username/password
Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
* disable logout test broken on linux
Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
* upgrade to oras 0.4.0
Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
* re-enable logout test
Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
* panic for uncaught errors
Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
* move login/logout to new registry subcommand
Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
6 years ago
Martin Hickey
0b809dd078
Validate library chart files after chart loaded
...
Validate the library chart files after the chart and
its depoendencies have been loaded. This is an update
following review comment:
- https://github.com/helm/helm/pull/5441#pullrequestreview-231339425
Signed-off-by: Martin Hickey <martin.hickey@ie.ibm.com>
6 years ago
Ian Howell
278594fb0f
fix(pkg/engine): Style changes on template errors
...
Signed-off-by: Ian Howell <ian.howell0@gmail.com>
6 years ago
Ian Howell
92b86f6e74
fix(pkg/engine): Catch non-templating errors when rendering templates
...
Signed-off-by: Ian Howell <ian.howell0@gmail.com>
6 years ago
Ian Howell
33b1ede570
fix(pkg/engine): Clean up template error messages
...
Signed-off-by: Ian Howell <ian.howell0@gmail.com>
6 years ago
Adam Reese
295092cd7d
ref(pkg/action): refactoring dup code and linter fixes
...
Signed-off-by: Adam Reese <adam@reese.io>
6 years ago
Adam Reese
895e9192d4
feat(*): use vanity import helm.sh/helm
...
Signed-off-by: Adam Reese <adam@reese.io>
6 years ago
Adam Reese
849f27d11f
ref(pkg/engine): make template specific functions private
...
Make template specific functions private to ensure they not misused and
make unit tests simpler. We may export the template helpers later if
needed.
This lays the foundation for the new chart pipeline.
Signed-off-by: Adam Reese <adam@reese.io>
6 years ago
Adam Reese
d841a1b1d9
fix(engine): make template rendering thread safe
...
See https://github.com/helm/helm/pull/4828
Signed-off-by: Adam Reese <adam@reese.io>
6 years ago
Adam Reese
2b81eea1e2
ref(*): replace byte array with map for Release config
...
Signed-off-by: Adam Reese <adam@reese.io>
6 years ago
Adam Reese
516c53dae6
ref(chart): use map for chart.Values
...
Signed-off-by: Adam Reese <adam@reese.io>
6 years ago
Adam Reese
4f26b658d8
change copyright to "Copyright The Helm Authors"
6 years ago
Adam Reese
f012940d9c
ref(*): refactor chart/chartutil
...
ref(chartutil): move chart loading out of chartutil into new package
add chart loader interface to allow lazy loading
feat(chart): create chart accessors
ref(*): cleanup requirements
ref(tiller): remove optional template engines
ref(tiller): simplify sorting releases and hooks
ref(*): code simplification
ref(hapi): move chart package out of hapi
ref(chart): add requirements and lock to Chart struct
6 years ago
Adam Reese
726e3c41be
feat(*): print stacktrace on error with debug enabled
7 years ago
Adam Reese
4c95185164
ref(*): replace chart.config with []byte
7 years ago
Adam Reese
36536d77ba
ref(*): remove protobuf any type
7 years ago
Adam Reese
6345f04190
ref(hapi): convert protobuf to go types
7 years ago
scriptonist
5311bf40a8
Now returning error and stopping installation
7 years ago
scriptonist
6cfaa4ebf2
Added code to recover from a tiller pod crash in an event of template render failure
7 years ago
Lukas Eichler
8bc7dede18
fix(helm): Apply PR comments for tpl template name fix
...
Modified existing unit test to verify the changed behavior.
Removed debug print.
7 years ago
Lukas Eichler
1cebc760a0
Fixed warning for missing formating parameter inside error message.
7 years ago
Lukas Eichler
2c338db1bd
fix(helm): Set template context inside tpl function to outer function.
...
docs(helm): Added documentation about tpl function
7 years ago
Lukas Eichler
39db9ec6e8
Merge branch 'master' into master
8 years ago
Lukas Eichler
9cd9fc47df
removed debug file
8 years ago
Lukas Eichler
439f1b31d1
Added unit test for include in tpl function
8 years ago
Lukas Eichler
ce8e8d6778
Added storage of parsed templates in engine
8 years ago
Matt Butcher
8937c775a9
fix(2452): sort templates before parse
...
This sorts templates by depth before sending them to the template
parser. Deepest templates are parsed first, with umbrella templates
parsed last. Since template definition names are LIFO, that means that
the highest level templates will claim the namespace.
Or, to put it simply, you can predictably override a child's defined
template by re-defining it in a parent chart.
Closes #2452
8 years ago
Matt Butcher
5c227bffbb
Merge pull request #2361 from databus23/dont_render_partials
...
Skip rendering partials
8 years ago
Lukas Eichler
2521c526d9
- Changed error behaviour to returning an error instead of writing the error in the template
...
- Added tests for using a function inside a template that is evaluated using the "tpl" function
8 years ago
Lukas Eichler
d01f7978d2
Added implementation for a tpl function that evaluates a string as a template.
...
Implementation for #1978
8 years ago
Fabian Ruff
b94eb82d12
Skip rendering partials
...
The output of a rendered partial is not used and rendering it might fail if it expects different values
8 years ago
Fabian Ruff
124235ffed
Fail template execution if included template fails
8 years ago
Steve Wilkerson
79a3db0a63
feat(helm): add support for required properties
...
Adds the `required` function in enginge.go to support required
properties in values.yml. When a chart developer wishes to specify
intent in requiring a value, they can use this function to declare
an error message that gets returned when chart rendering fails
when a required value is not present in values.yml.
Closes #1580
8 years ago
Fabian Ruff
43a6bcff40
Add .Template.BasePath to template system
8 years ago
Jack Zampolin
fc60d51be9
Add toToml function
8 years ago
YuviPanda
5c52fe6ad6
Add ToJson and FromJson template functions
8 years ago
Matt Butcher
cb0a6c7e07
feat(tiller): add {{.Capabilities}} object
...
This adds the {{.Capabilities}} object to the template variables so that
chart authors can write charts that are aware of teh Kubernetes
capabilities of the current cluster.
Closes #1608
8 years ago
Matt Butcher
d8540d78f1
feat(tiller): add fromYaml to template functions
...
This adds a fromYaml template function.
Closes #1604
8 years ago
Andrew Stuart
6760aa1588
Add Lines method, remove path utils (Sprig pr)
8 years ago
Andrew Stuart
5d58b7792c
Fix erroneous import
8 years ago
Andrew Stuart
9771973888
Add AsSecrets, AsConfig methods for Files object. Move ToYaml to chartutil
8 years ago
Adnan Abdulhussein
f97dbe33da
fix(tests): prefix template names with "templates/"
8 years ago
Matt Butcher
36f7eb0b2a
fix(linter): add engine.FuncMap so linter can use real function list
...
This adds a function engine.FuncMap that returns a function mapping that
better represents the functions passed to a template. The linting logic
is reconfigured to use this function instead of the sprig.FuncMap
function.
Closes #1366
8 years ago
Matt Butcher
431cc46cad
feat(tiller): add toYaml template function
...
This adds the function toYaml to the Engine template functions.
Closes #1225
8 years ago
joe2far
72e7b22999
minor engine unit test fix
8 years ago
vaikas-google
492dbb3791
Add support for NOTES.txt file
8 years ago
Matt Butcher
84761a559a
fix(helm): remove extra linter output
...
Closes #1076
8 years ago