[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: setting username in ./ssh/config



On 2015-05-06 1302 (+0300), Hleb Valoshka wrote:
Возможно я не правильно понимаю man 5 ssh_config, но вот такой конфиг:

В самом начале мана:

    For each parameter, the first obtained value will be used.  The
    configuration files contain sections separated by “Host”
    specifications, and that section is only applied for hosts that
    match one of the patterns given in the specification.  The matched
    host name is the one given on the command line.

    Since the first obtained value for each parameter is used, more
    host-specific declarations should be given near the beginning of the
    file, and general defaults at the end.

Так что выглядеть должно так:

    Host host1
        User login2

    Host host2
        HostName fqdn2

    Host *
        User login1


Reply to: