mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 17:09:03 +00:00
Documented absolute path changes to ssh_known_hosts.
This commit is contained in:
parent
f2808f29fc
commit
b1e14b62aa
@ -60,7 +60,9 @@ def present(
|
||||
|
||||
config
|
||||
The location of the authorized keys file relative to the user's home
|
||||
directory, defaults to ".ssh/known_hosts"
|
||||
directory, defaults to ".ssh/known_hosts". If no user is specified,
|
||||
defaults to "/etc/ssh/ssh_known_hosts". If present, must be an
|
||||
absolute path when a user is not specified.
|
||||
|
||||
hash_hostname : True
|
||||
Hash all hostnames and addresses in the output.
|
||||
@ -76,7 +78,7 @@ def present(
|
||||
config = config or '.ssh/known_hosts'
|
||||
|
||||
if not user and not os.path.isabs(config):
|
||||
comment = 'If not specifying a "user", specify an absolute "path".'
|
||||
comment = 'If not specifying a "user", specify an absolute "config".'
|
||||
ret['result'] = False
|
||||
return dict(ret, comment=comment)
|
||||
|
||||
@ -153,7 +155,9 @@ def absent(name, user=None, config=None):
|
||||
|
||||
config
|
||||
The location of the authorized keys file relative to the user's home
|
||||
directory, defaults to ".ssh/known_hosts"
|
||||
directory, defaults to ".ssh/known_hosts". If no user is specified,
|
||||
defaults to "/etc/ssh/ssh_known_hosts". If present, must be an
|
||||
absolute path when a user is not specified.
|
||||
'''
|
||||
ret = {'name': name,
|
||||
'changes': {},
|
||||
@ -166,7 +170,7 @@ def absent(name, user=None, config=None):
|
||||
config = config or '.ssh/known_hosts'
|
||||
|
||||
if not user and not os.path.isabs(config):
|
||||
comment = 'If not specifying a "user", specify an absolute "path".'
|
||||
comment = 'If not specifying a "user", specify an absolute "config".'
|
||||
ret['result'] = False
|
||||
return dict(ret, comment=comment)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user