|
@@ -21,11 +21,15 @@ def process_one():
|
|
|
pass
|
|
|
print('搜尋結果數量',len(elmts))
|
|
|
n = 0
|
|
|
+ n_run = 0
|
|
|
if len(elmts) == 0:
|
|
|
n+=1
|
|
|
print('異常次數',n)
|
|
|
os.system('python3 reboot.py')
|
|
|
- print('正常')
|
|
|
+ else:
|
|
|
+ print('正常')
|
|
|
+ n_run+=1
|
|
|
+ print('執行次數:',n_run)
|
|
|
|
|
|
def run_once(pport):
|
|
|
global driver
|
|
@@ -51,7 +55,6 @@ try:
|
|
|
os.system('docker container restart tiny10')
|
|
|
time.sleep(1)
|
|
|
run_once(9929)
|
|
|
- print('docker開啟完成')
|
|
|
|
|
|
except:
|
|
|
os.system('docker container restart tiny9')
|