print('ERROR: WayDroid is not initialized, run "waydroid init"')
return 0
elif os.geteuid() == 0 and args.action == "init":
- os.mkdir(args.work)
+ if not os.path.exists(args.work):
+ os.mkdir(args.work)
else:
args.log = "/tmp/tools.log"
actions.container_manager.start(args)
elif args.subaction == "stop":
actions.container_manager.stop(args)
+ elif args.subaction == "restart":
+ actions.container_manager.restart(args)
elif args.subaction == "freeze":
actions.container_manager.freeze(args)
elif args.subaction == "unfreeze":