def _build_ssh_config(self, config):
        """ build the ssh injection configuration """
        ssh_config_injection = ssh_config_template % {
            'host': config.get('host'),
            'hostname': config.get('hostname'),
            'ssh_key_path': config.get('ssh_key_path'),
            'user': config.get('user')
        }
        if config.has('port'):
            ssh_config_injection += "  Port {0}\n".format(config.get('port'))
        return ssh_config_injection
build the ssh injection configuration