1
0
mirror of https://github.com/newnius/YAO-agent.git synced 2025-06-06 21:31:55 +00:00

all in one

This commit is contained in:
Newnius 2019-12-26 18:12:48 +08:00
parent 93bdc81498
commit 3d8e77d23f

View File

@ -143,6 +143,8 @@ class MyHandler(BaseHTTPRequestHandler):
docker_cmd
])
print('sh -c \'' + script + '\'')
client = docker.from_env()
container = client.containers.get('yao-agent-helper')
exit_code, output = container.exec_run('sh -c \'' + script + '\'')