cookbook 'hostnames', '= 0.3.1'
hostnames (9) Versions 0.3.1 Follow9
Configures hostname and FQDN
cookbook 'hostnames', '= 0.3.1', :supermarket
knife supermarket install hostnames
knife supermarket download hostnames
hostnames cookbook
Description
Sets hostname and FQDN of the node. The latest code is hosted at
https://github.com/nathantsoi/chef-cookbook-hostname
Attributes
-
node['set_fqdn']
- FQDN to set.
The asterisk character will be replaced with node.name
. This way,
you can add this to base role:
default_attributes :set_fqdn => '*.project-domain.com'
and have node set its FQDN and hostname based on its chef node name
(which is provided on chef-client
first run's command line).
node['hostname_cookbook']['use_node_ip']
-- when true
sets the hostname tonode["ipaddress"]
in/etc/hosts
(default:false
)node['hostname_cookbook']['hostsfile_ip']
-- IP used in
/etc/hosts
to correctly set FQDN (default:127.0.1.1
)
Recipes
hostnames::default
-- will set node's FQDN to value ofset_fqdn
attribute,
and hostname to its host part (up to first dot).hostnames::vmware
-- sets hostname automatically using vmtoolsd.
You do not need to setnode["set_fqdn"]
.
Contributing
Fork.
Make more awesome.
Pull request.
I will bump version and run
knife cookbook site share hostnames "Networking"
Author
Maciej Pasternacki maciej@3ofcoins.net
Nathan nathan@veretile.com
Dependent cookbooks
hostsfile >= 0.0.0 |
Contingent cookbooks
There are no cookbooks that are contingent upon this one.