I've been working on using saltstack to drive proxmox cloud operations through the API. I've come across some issues and it appears I am not alone in this. On one terraform comment on github jamesharr explains this excellently (see https://github.com/Telmate/terraform-provider-proxmox/issues/605):
Some issues that I have come across myself:
I also very quickly hit the limitations of my understanding of this code base as well as the library it uses. Unfortunately, I won't have time to devote to learning it.
Proxmox API related issues I've run into.
The terraform provider currently requires a template, or an iso option. That combined with the non-idempotent behavior means that this might be a much more involved change than I had originally anticipated, possibly involving structural changes.
- The API is non-idempotent when using import-from. The code needs to be smart enough to handle that.
- imported disks are not resized by Proxmox automatically, meaning there's another step in the process that needs to happen
- disk images are referenced by Unix filesystem path, which means only the root user can use this feature. Even generating API keys on the root account won't let you use import-from. I suspect that they'll fix this over time to allow people to reference images via volume path (my-vol:images/foo.qcow2)
- (not specifically related) there is no way to manage custom cloud-init config YAML/atteibutes via the API.
Unfortunately, the likelihood of me completing this feature is pretty slim. Especially in the near future. I'm not sure if the proper etiquette is to close the PR if I no longer intend to work on it, or leave the work out there for someone else to pick up. Let me know what you think I should do.
Some issues that I have come across myself:
- Some operations can only be performed by root@pve using password authentication (found this on the support forum elsewhere).
- Importing a volume is only possible from an absolute file path, not from a different storage type such as an existing LVM volume or a reference to an image.