def allocate_machine(action_handler, machine_spec, machine_options)
      # TODO verify that the existing provisioner_url in the node is the same as ours
      ensure_ssh_cluster(action_handler)
      target_name = machine_spec.name
      target_file_path = File.join(cluster_path, "#{machine_spec.name}.json")


      # Chef::Log.debug("======================================>")
      # Chef::Log.debug("acquire_machine - provisioner_options.inspect: #{provisioner_options.inspect}")
      # Chef::Log.debug("======================================>")

      @target_host = get_target_connection_method(machine_options)

      # Chef::Log.debug("======================================>")
      # Chef::Log.debug("acquire_machine - target_host: #{@target_host}")
      # Chef::Log.debug("======================================>")

      # Set up Provisioner Output
      # TODO - make url the chef server url path? maybe disk path if zero?
      machine_spec.location = {
        'driver_url' => driver_url,
        'driver_version' => ChefMetalSsh::VERSION,
        'target_name' => target_name,
        'target_file_path' => target_file_path,
        'allocated_at' => Time.now.utc.to_s
      }

      # Chef::Log.debug("======================================>")
      # Chef::Log.debug("acquire_machine - machine_spec.inspect: #{machine_spec.inspect}")
      # Chef::Log.debug("======================================>")


    end
def allocate_machine(action_handler, machine_spec, machine_options)
      # TODO verify that the existing provisioner_url in the node is the same as ours
      ensure_ssh_cluster(action_handler)
      target_name = machine_spec.name
      target_file_path = File.join(cluster_path, "#{machine_spec.name}.json")


      # Chef::Log.debug("======================================>")
      # Chef::Log.debug("acquire_machine - provisioner_options.inspect: #{provisioner_options.inspect}")
      # Chef::Log.debug("======================================>")

      @target_host = get_target_connection_method(machine_options)

      # Chef::Log.debug("======================================>")
      # Chef::Log.debug("acquire_machine - target_host: #{@target_host}")
      # Chef::Log.debug("======================================>")

      # Set up Provisioner Output
      # TODO - make url the chef server url path? maybe disk path if zero?
      machine_spec.location = {
        'driver_url' => driver_url,
        'driver_version' => ChefMetalSsh::VERSION,
        'target_name' => target_name,
        'target_file_path' => target_file_path,
        'allocated_at' => Time.now.utc.to_s
      }

      # Chef::Log.debug("======================================>")
      # Chef::Log.debug("acquire_machine - machine_spec.inspect: #{machine_spec.inspect}")
      # Chef::Log.debug("======================================>")


    end
Acquire a machine, generally by provisioning it.  Returns a Machine
 object pointing at the machine, allowing useful actions like setup,
 converge, execute, file and directory.  The Machine object will have a
 "node" property which must be saved to the server (if it is any
 different from the original node object).

 ## Parameters
 action_handler - the action_handler object that provides context.
 node - node object (deserialized json) representing this machine.  If
        the node has a provisioner_options hash in it, these will be used
        instead of options provided by the provisioner.  TODO compare and
        fail if different?
        node will have node['normal']['provisioner_options'] in it with any options.
        It is a hash with this format:

           -- provisioner_url: ssh:<@target_host>
           -- target_ip: the IP address of the target machine - IP or FQDN is required
           -- target_fqdn: The Resolvable name of the target machine - IP or FQDN is required
           -- ssh_user: the user to ssh as
           -- ssh_options: options to pass the ssh command. available options are here - https://github.com/net-ssh/net-ssh/blob/master/lib/net/ssh.rb#L61

        node['normal']['provisioner_output'] will be populated with information
        about the created machine.  For ssh, it is a hash with this
        format:

           -- provisioner_url: ssh:<@target_host>
           -- name: container name