crowbar_join: Move some code to a function

Everything related to the initial setup is now in a do_setup function.
crowbar_join: There's no /etc/chef/chef.rb, but client.rb
crowbar_join: Move creating reboot handler to its own "if"
crowbar_join: Move chef-client calls to functions

We create two functions: do_chef_client_after_setup and
do_chef_client.

The first one is to be used only if the setup is being done. The second
one is to be used on each boot.
crowbar_join: Move code to functions

Add wait_for_network and wait_for_hostname.
crowbar_join: Add a header to the log before each run
crowbar_join: Structure script a bit
crowbar_join: Add global variable to control chef-client debug behavior
crowbar_join: Add two modes: setup and start

The setup mode is used for the initial setup done by crowbar_join.

The start mode will be used for later boots of the node, where setup is
not needed anymore.
crowbar_join: Add --debug option

This only controls the debug logging of chef-client for now.
crowbar_join: Do not reboot on hostname error

It doesn't help in any way to reboot, just exit.
crowbar_join: Add --verbose

Also move some echo to only appear in debug mode.
crowbar_join: Add echo_error helper
crowbar_join: Exit with non-0 if final state is not "ready"
crowbar_join: Add --stop mode

This will be used on shutdown/reboot
crowbar_join: Add paranoid check on MODE variable
crowbar_join: Simplify how we set $IP
crowbar_join: Rework interaction with ntp service

Only stop it if it's running, and only start it if we stopped it.
crowbar_join: In start mode, exit if we cannot ping admin server

The node will just work okay, so we should survive.

We don't do this in setup mode, since in that case, we really need the
admin server.
Install /usr/sbin/crowbar_join on non-provisioner-server nodes

We obviously install an init script for it, and also a logrotate
configuration.

We also remove the old /etc/init.d/crowbar_join.sh file that might exist
because of the old way.