code update

This commit is contained in:
2013-04-30 08:44:58 +02:00
parent 2220cfbd1e
commit 6d317b997d
3 changed files with 94 additions and 3 deletions

View File

@@ -114,6 +114,9 @@ def vmm_monitor(args):
except:
print("unable to issue monitor command!")
def vmm_authorized(args):
helper.generateAuthorizedKeys()
def main():
#maybe we need to create a lockfile
@@ -125,6 +128,9 @@ def main():
parser_start.add_argument('vmid', action='store', help='the ID of the VM')
parser_start.set_defaults(func=vmm_start)
parser_authorized = subparsers.add_parser('gen-auth-keys', help='Regenerates authorized_keys file')
parser_authorized.set_defaults(func=vmm_authorized)
parser_stop = subparsers.add_parser('stop', help='Shutdown VM with ACPI poweroff')
parser_stop.add_argument('vmid', action='store', help='the ID of the VM')
parser_stop.add_argument('-t', action='store',type=int, help='forcefully quit after given timeout value (signed integer), implies -w')