You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the upjet-generated providers, there are Header template variables on the generated go files. Please see these template files. Header template variable example:
This Header variable adds the license statements to the generated go files. However, there is no header injection mechanism for the generated example manifests. Because of this, the generated example manifests are generated without any header, even if a license statement is specified in the repo.
This issue can be reproduced by any upjet-generated provider by running make generate. This generation will not produce any license statements for the generated example manifests.
Proposed Solution
A mechanism can be added to the example generation pipeline (similar to the other). By this way, we will have the generated license headers in the generated example manifests.
The text was updated successfully, but these errors were encountered:
What happened?
In the upjet-generated providers, there are
Header
template variables on the generated go files. Please see these template files.Header
template variable example:upjet/pkg/pipeline/templates/controller.go.tmpl
Line 1 in 2ef7077
This
Header
variable adds the license statements to the generated go files. However, there is no header injection mechanism for the generated example manifests. Because of this, the generated example manifests are generated without any header, even if a license statement is specified in the repo.Example header statement from provider-upjet-aws: https://github.com/crossplane-contrib/provider-upjet-aws/blob/main/hack/boilerplate.go.txt
Example controller.go that has this generated license header: https://github.com/crossplane-contrib/provider-upjet-aws/blob/main/internal/controller/accessanalyzer/analyzer/zz_controller.go
The generated example manifest does not have a license header: https://github.com/crossplane-contrib/provider-upjet-aws/blob/main/examples-generated/accessanalyzer/v1beta1/analyzer.yaml
How can we reproduce it?
This issue can be reproduced by any upjet-generated provider by running
make generate
. This generation will not produce any license statements for the generated example manifests.Proposed Solution
A mechanism can be added to the example generation pipeline (similar to the other). By this way, we will have the generated license headers in the generated example manifests.
The text was updated successfully, but these errors were encountered: