mirror of
https://github.com/saltstack/salt.git
synced 2025-04-16 09:40:20 +00:00

Using: raise SystemExit('some message') is equivalent to: sys.stderr.write('some message\n') sys.exit(1)
20 lines
337 B
Python
20 lines
337 B
Python
#!/usr/bin/env python2
|
|
'''
|
|
Manage the authentication keys with salt-key
|
|
'''
|
|
|
|
import salt.cli
|
|
|
|
|
|
def main():
|
|
'''
|
|
The main function
|
|
'''
|
|
saltkey = salt.cli.SaltKey()
|
|
saltkey.run()
|
|
|
|
if __name__ == '__main__':
|
|
try:
|
|
main()
|
|
except KeyboardInterrupt:
|
|
raise SystemExit('\nExiting gracefully on Ctrl-c')
|