'Return the contents of the spinnaker-local.yml configuration file.
Args:
gcloud: [GCloudAgent] Specifies project and zone.
Capable of remote fetching if needed.
instance: [string] The GCE instance name containing the deployment.
Returns:
None or the configuration file contents.'

@staticmethod
def __get_deployed_local_yaml_bindings(gcloud, instance):

    config_dict = ExpressionDict()
    logger = logging.getLogger(__name__)
    if gce_util.am_i(gcloud.project, gcloud.zone, instance):
        yaml_file = os.path.expanduser('~/.spinnaker/spinnaker-local.yml')
        logger.debug('We    are    the    instance.    Config    from    %s', yaml_file)
        if (not os.path.exists(yaml_file)):
            logger.debug('%s    does    not    exist', yaml_file)
            return None
        try:
            yaml_accumulator.load_path(yaml_file, config_dict)
            return config_dict
        except IOError as ex:
            logger.error('Failed    to    load    from    %s:    %s', yaml_file, ex)
            return None
        logger.debug('Load    spinnaker-local.yml    from    instance    %s', instance)
    response = gcloud.remote_command(instance, 'LIST="";    for    i    in    /etc/default/spinnaker    /home/spinnaker/.spinnaker/spinnaker-local.yml    /opt/spinnaker/config/spinnaker-local.yml    $HOME/.spinnaker/spinnaker-local.yml;    do    if    sudo    stat    $i    >&    /dev/null;    then            LIST="$LIST    $i";    fi;    done;    (sudo    tar    czf    -    $LIST    2>    /dev/null    |    base64)')
    if (not response.ok()):
        logger.error('Could    not    determine    configuration:\n%s', response.error)
        return None
    got = response.output
    update_msg_offset = got.find('Updates    are    available')
    if (update_msg_offset > 0):
        got = got[0:update_msg_offset]
    eoln = got.find('\n')
    if ((eoln > 0) and re.match('^Warning:    .+$', got[0:eoln])):
        got = got[(eoln + 1):]
    if (not got):
        return None
    tar = tarfile.open(mode='r', fileobj=StringIO(base64.b64decode(got)))
    try:
        entry = tar.extractfile('etc/default/spinnaker')
    except KeyError:
        pass
    else:
        logger.info('Importing    configuration    from    /etc/default/spinnaker')
        config_dict.update(name_value_to_dict(entry.read()))
    file_list = ['home/spinnaker/.spinnaker/spinnaker-local.yml', 'opt/spinnaker/config/spinnaker-local.yml']
    log_name = os.environ.get('LOGNAME')
    if (log_name is not None):
        file_list.append(os.path.join('home', log_name, '.spinnaker/spinnaker-local.yml'))
    for member in file_list:
        try:
            entry = tar.extractfile(member)
        except KeyError:
            continue
        logger.info(('Importing    configuration    from    ' + member))
        yaml_accumulator.load_string(entry.read(), config_dict)
    return config_dict
