Fixes in updates

This commit is contained in:
absurdo 2023-06-09 01:05:33 +02:00
parent 55a1075c3a
commit 9161c35cac
2 changed files with 10 additions and 6 deletions

View file

@ -17,11 +17,13 @@ class ServerTask(Task):
arr_server=serverdb.set_conditions('WHERE ip=%s', [server]).select_a_row_where()
update_server=UpdateServerScripts(conn)
if arr_server:
arr_update=update_server.set_conditions('WHERE server_id=%s', [arr_server['id']]).select_to_array()
for upd in arr_update:
update_server=UpdateServerScripts(conn)
self.files.append([upd['file'], 0o755])
self.commands_to_execute.append([upd['file'], ''])
arr_update=update_server.set_conditions('WHERE server_id=%s', [arr_server['id']]).select_to_array()
for upd in arr_update:
self.files.append([upd['file'], 0o755])
self.commands_to_execute.append([upd['file'], upd['args']])