mirror of https://github.com/CIRCL/lookyloo
Restart lookyloo after update
parent
97c4d93318
commit
3d17a98799
|
@ -87,6 +87,17 @@ def main():
|
|||
keep_going(args.yes)
|
||||
run_command('tools/3rdparty.py')
|
||||
|
||||
print('* Restarting Lookyloo.')
|
||||
keep_going(args.yes)
|
||||
service = "lookyloo"
|
||||
p = subprocess.Popen(["systemctl", "is-active", service], stdout=subprocess.PIPE)
|
||||
(output, err) = p.communicate()
|
||||
if output.decode('utf-8') == "active\n":
|
||||
run_command('sudo service lookyloo restart')
|
||||
else:
|
||||
run_command('poetry run stop')
|
||||
run_command('poetry run start')
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
|
|
Loading…
Reference in New Issue