通过ssh在远程主机上分发命令并在本地并行执行命令的python包。
distlre的Python项目详细描述
#distlre(dist el ar ee)
meta='meta',时间限制=10,内存限制=10)
future=executor.submit(task)
executor.execute\tasks()
executor.wait()
print(future.result().output)
``````
或者在远程主机上运行命令:
```python
import getpass
password=getpass.getpass(“连接到[localhost]的密码):”
executor=distlre(远程主机=[remotehost('localhost',port=31415,password=password)])
other=task(command='cd~,meta='meta',time=10,内存限制=10)
future=executor.submit(task)
other\future=executor.submit(other\task)
executor.execute\tasks()
executor.wait()
print(future.result().output)
`````
meta='meta',时间限制=10,内存限制=10)
future=executor.submit(task)
executor.execute\tasks()
executor.wait()
print(future.result().output)
``````
或者在远程主机上运行命令:
```python
import getpass
password=getpass.getpass(“连接到[localhost]的密码):”
executor=distlre(远程主机=[remotehost('localhost',port=31415,password=password)])
future=executor.submit(task)
other\future=executor.submit(other\task)
executor.execute\tasks()
executor.wait()
print(future.result().output)
`````