carvel-dev / carvel-dev/kapp-controller

**Explore:** Package authors should be able to customize how InstalledPackage values get included in templating steps

Open
#122 7 comments 6 reactions 0 assignees View on GitHub
carvel-accepted discussion priority/important-soon
Dominant language
Go
Stars
323
Forks
127
Avg merge
2d 16h
Merged PRs (30d)
4

Description

In the current alpha, values from the InstalledPackage are appended to the values of the first templating step, which is quite limiting.

To improve this experience for authors, I propose adding a `valuesConfig` key to the Package definition. Under this key, authors are able to specify which templating step the values will be included in, and can optionally choose to include the namespace as a value as well. It could look something like this: https://gist.github.com/ewrenn8/5d029c1c0c44b12e957119a10733d45f

Some outstanding thoughts:
* What other values may be useful other than namespace, and what is the best way to include them? One example that was brought up was providing the InstalledPackage name as a data value to the templates. If there is a growing list, making them optional keys could get unwieldy.
* Is there a better way to specify which templating step to include the values in?

Making this issue as a discussion ground for potential solutions to this problem, so if there are completely unrelated solutions please post them!

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.