Problem:
Is there anyway to automatically delete a provisioned host? I tried looking through the settings but can’t find any. Expected outcome:
Host is automatically deleted after successful provision Foreman and Proxy versions:
2.14 Foreman and Proxy plugin versions:
2.14 Distribution and version:
Short answer is no, I mean not directly with foreman settings. Can you describe your exact need ?
If it’s for CI (create, test, delete), you can use hammer or REST API. And wrap it with Jenkins, Ansible playbooks … Or even with foreman hooks (not advised).
Are you using bare metal hosts, virtualization platforms ? When you said delete, you mean only delete foreman host or delete foreman host & delete virtual host itself ?
The first is a plugin that adds the feature you are interested in. The second is a standalone project that uses Foreman as a provisioning engine and offers such usecase (if I’m not mistaken, it’s been few years sice I’ve seen it)