Closed agriffit79 closed 1 year ago
They've completely changed how the API works for Puppet in Foreman v3. You can no longer update puppet class assignments as part of the standard hostgroup or host calls, instead there are dedicated endpoints for applying classes. Not only that but there is no update functionality, only add and delete. Which makes it's difficult to implement CRUD semantics.
Maybe we need a check what version foreman is running and disable puppet classes for 3.0 and newer in that case. You can probably work around it but I have personally never worked with puppet and its not a high priority on my list.
In the end I figured out a simple way to do it. I'll also add the feature request from #92. Will submit a PR in a day or so.
This is not working against Foreman 3.4 with the latest (0.5.7) provider.
We're setting
puppet_class_ids
which is being ignored.Either there was a bug in my original code or the API has changed in more recent versions of Foreman. Will try and submit a fix.