AddType helper apis references default to "github.com/crossplane/provider-NAME"
dukanto opened this issue · 0 comments
dukanto commented
What happened?
When using provider.addtype target, all APIs that references to the newly created type in the new controller references to github.com/crossplane/provider-[NAME].
When developing a provider that's not hosted under crossplane org, you then have to go to that controller and modify that reference to the correct package.
How can we reproduce it?
- Create a new provider using this template
- Modify Makefile accordingly (i.e., changing PROJECT_REPO var)
- Run provider.addtype
- Controller gets generated by referencing APIs as github.com/crossplane/provider-[NAME]
I think a few modifications in /hack/controller/KIND_LOWER/KIND_LOWER.go.tmpl (and makefile to pass another variable) will be enough to pass down the correct info and avoid the extra step of changing imports every time.
I'm happy to create a PR on a solution proposal to be reviewed :)