Philipp Born
604ae96879
feat: allow vmtemplate selection based on tags ( #343 )
...
* feat: allow template selection based on tags
* `sourceNode + templateID` and `templateSelector` are mutually exclusive
* automatically detects both `sourceNode` + `templateID`
* errors out if anything but one (1) VM template with desired flags was found
* revert webhook changes
* introduce TemplateSource
* comment on TemplateSource
* add testcase for VMTemplateNotFound
* add test for SourceNode, TemplateID and TemplateSelector being unset
* revert GetNode() changes
* remove redundant TemplateSelector check
* update TemplateSelector description
* introduce ErrTemplateNotFound error
* add FindVMTemplateByTags test-case with nil vmTags
* Update api/v1alpha1/proxmoxmachine_types_test.go
Co-authored-by: Vic Kerr <wiktor.kerr@ionos.com >
* make the linter happy
* Update proxmoxmachine_types.go
* Update advanced-setups.md
* Update proxmoxmachine_types.go
* refaormat
---------
Co-authored-by: Vic Kerr <wiktor.kerr@ionos.com >
Co-authored-by: Mohamed Chiheb Ben Jemaa <mc.benjemaa@gmail.com >
2025-02-05 16:25:17 +00:00