Setting tag Monitor-3.0-34
[monitor.git] / tools / getsshkeys.py
1 #!/usr/bin/python
2
3 import sys
4 sys.path.append('.')
5 sys.path.append('..')
6
7 from monitor.util.file import *
8
9 def main(hosts):
10         k = SSHKnownHosts()
11         if len (hosts) > 0:
12                 for host in hosts:
13                         k.updateDirect(host)
14         else:
15                 k.updateAll()
16         k.write()
17
18 if __name__ == '__main__':
19         main(sys.argv[1:])