Is there any way of setting a server's hostname using puppet?
I could write a custom type, but maybe there's a simpler way.
Thanks
[Edit] Sorry, I should've mentioned I run puppet masterless, puppet is setup first and then it sets up everything else.
Take a look at my "renaming" definition for ideas. It assumes Debian, and might work on Ubuntu as well.
Create a sethostname module. Here's the
init.pp
:https://gist.github.com/VertigoRay/6024253