Giter Site home page Giter Site logo

chef-cookbook-hostname's Introduction

hostname cookbook

Build Status Chef cookbook

Description

Sets hostname and FQDN of the node. The latest code is hosted at https://github.com/3ofcoins/chef-cookbook-hostname

Important

Setting hostname on FQDN is not (and won't be) supported. Unfortunately, using dots in the hostname can cause inconsistent results for any system that consumes DNS and is not allowed by RFC952. If a user needs additional info in their shell prompt, they can change PS1 in etc/profile to include the FQDN together with any information they find useful (such as the customer, the environment, etc).

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']['hostsfile_ip'] -- IP used in /etc/hosts to correctly set FQDN (default: 127.0.1.1)
  • node['hostname_cookbook']['hostsfile_aliases'] -- list of aliases used in /etc/hosts for the ip set above (default: [hostname])
  • node['hostname_cookbook']['hostsfile_include_hostname_in_aliases'] -- whether to include the hostname at the end of the aliases list above (default: true)

Recipes

  • hostname::default -- will set node's FQDN to value of set_fqdn attribute, and hostname to its host part (up to first dot).
  • hostname::vmware -- sets hostname automatically using vmtoolsd. You do not need to set node["set_fqdn"].

Author

Author: Maciej Pasternacki [email protected]

chef-cookbook-hostname's People

Contributors

chulkilee avatar esigler avatar gdb avatar guilhem avatar jeanmertz avatar joelmoss avatar mattkasa avatar mburns avatar mpasternacki avatar tily avatar timurb avatar xamebax avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

openai

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.