Feature #1988
closedAdd API for Host Parameters
Description
The Foreman API is cool, but it's not complete. In particular I'd like to be able to programmatically change the host parameters. A much better way that editing the database directly.
An API was added to retrieve the list of parameters (#1115) but no way to modify them. Also, that patch just added them to the output of the hosts.
I propose a new API entrypoint /hosts/FQDN/parameters which returns just a dictionary (parameter => value), but would also be POSTable for updates. This API would only include parameters actually assigned to the host, not those inherited from the hostgroup.
(It feels to me that this shouldn't be a large change, but Rails has me stumped, I'm completely confused about what code needs to be changed.)
Updated by Joseph Magen about 12 years ago
- Assignee set to Joseph Magen
Martijn, I will look into this. Joseph
Updated by Ohad Levy about 12 years ago
in the meanwhile, see this thread for workarounds https://groups.google.com/group/foreman-users/browse_thread/thread/2dbfdfb0d7502c3b?hl=en
Updated by Martijn van Oosterhout about 12 years ago
Thanks for the link to the workaround, I didn't find that in my google searches and wouldn't have thought of it myself. It's a bit clumsy but solves my immediate problem, thanks!
Updated by Joseph Magen almost 12 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100
Applied in changeset 57526a20744f3f7e9cfdeef6e7f3268da8eab2ad.