Jenkins_slave connects to current hostname instead of fixed

Previously Jenkins clients connected to Jenkins master using the
hostname written to the Perl script by Puppet. This change modifies
the behavior so, that the Perl script queries for the current
hostname and uses that to connect.

Change-Id: I86cad9fe14f179eb9dd5a18ce1eedc28e6184e07
Reviewed-by: Simo Fält <simo.falt@digia.com>
Reviewed-by: Heikki Halmet <heikki.halmet@digia.com>