修正
This commit is contained in:
10
_check_nas_index.py
Normal file
10
_check_nas_index.py
Normal file
@@ -0,0 +1,10 @@
|
||||
import paramiko
|
||||
c = paramiko.SSHClient()
|
||||
c.set_missing_host_key_policy(paramiko.AutoAddPolicy())
|
||||
c.connect('192.168.0.61', username='root', password='59911784', timeout=15)
|
||||
_, o, _ = c.exec_command('grep -n "bank-statement" /volume1/docker/njts-accounting/frontend/index.html')
|
||||
result = o.read().decode()
|
||||
print("NAS index.html grep結果:", repr(result))
|
||||
_, o2, _ = c.exec_command('wc -l /volume1/docker/njts-accounting/frontend/index.html')
|
||||
print("行数:", o2.read().decode().strip())
|
||||
c.close()
|
||||
Reference in New Issue
Block a user