1 Star 1 Fork 3

jkey666/devops

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
start_docker_fast.py 447 Bytes
一键复制 编辑 原始数据 按行查看 历史
leffss 提交于 2020-04-09 11:00 +08:00 . optimization many
#!/usr/bin/env python
import subprocess
def __external_cmd(cmd, code="utf8"):
print(cmd)
process = subprocess.Popen(cmd, shell=True, bufsize=0, stdout=subprocess.PIPE, universal_newlines=True)
while 1:
next_line = process.stdout.readline()
print(next_line.strip())
if next_line == "" and process.poll() is not None:
break
if __name__ == '__main__':
__external_cmd('sh start_docker_fast.sh')
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Python
1
https://gitee.com/jkey666/devops.git
git@gitee.com:jkey666/devops.git
jkey666
devops
devops
master

搜索帮助