How would we automate networking in a puppet environment?
Solution 1:
AFAIK The Foreman already leads into the right direction, so maybe you should start to play with that.
Besides that take a look at Custom Facts. They are a powerful way to access all kinds of data and make it usable in Puppet manifests. E.g. create a custom fact like $::inventory_ipaddress
or even overwrite the $::ipaddress
fact with the canonical one to be used for configuration.
For 1: For a large number of hosts it is generally advisable not to have hundreds of node
definitions, but rather have a set of roles and profiles.
The general design challenge here is to have a clear flow of information from single source(s) of truth to the provisioning.
For 2+3: you could use puppet to call all kinds of auxillary scripts and tools, but I doubt it is the best tool for the job, because it probably will not be the "source of truth".
For 4: This is somewhere in between. I myself use puppet on EC2 instances to periodically trigger a Zabbix inventory update and use facter to fill e.g. role, OS version, security groups. Caveat here: my normative source of truth is a provisioning tool and my puppet manifests where I can change settings; on the other hand this inventory is only the final outcome to verify results.
Solution 2:
It is possible to configure Arista switches using Puppet running on the EOS operating system on the switch itself. Arista even provides an tutorial how to install Puppet themselves: Installing Puppet on EOS So that doesn't have to be a problem.
For the inventory tasks (IP's, locations, waranty) I would recommend Zabbix.