Using Foreman 3.7 I’d like to know if it’s possible to have the Foreman smartproxy give the correct IP to a host that’s being built?
My situation is, I am using DHCP for initial boot only. Actually I would like to make Foreman’s DHCP smart enough to not offer DHCP leases except to hosts that are being built.
I was surprised this wasn’t the default configuration, actually. Is there a way to make it happen?
(When hosts that aren’t being built reboot from NIC and get a DHCP lease, they pxeboot, and the default pxeboot config then tells them to boot from local hard disk. But it would be faster if they would just fail to get a lease in the first place so they could fall back to local boot directly without going through pxeboot first.)
I’m manually assigning IPs to hosts during provisioning in Foreman, but when I first set up a smartproxy to do DHCP, it failed to give any lease at all until I configured a DHCP range (pool). So now that I’ve done that, it will give a lease, and then the DHCP IP gets overwritten with the statically configured IP during the provisioning templates.
It would also be nice not to have to set the DHCP pool for each separate smart proxy. Again, I was surprised Foreman didn’t do this automatically. (I set in in the foreman_proxy installer class, which I have running as part of my puppet codebase.)
Any advice on these points?