1 Star 0 Fork 93

hejianop/依瞳人工智能平台

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
devenv.py 1.15 KB
一键复制 编辑 原始数据 按行查看 历史
xyttaotao 提交于 2020-07-19 06:24 . template config
#!/usr/bin/python
import os
import time
import datetime
import argparse
import uuid
import subprocess
import sys
import tempfile
import getpass
import pwd
import grp
from os.path import expanduser
sys.path.append("src/utils")
from DockerUtils import run_docker, build_docker
# prefix and tag will be filled by argument parser.
dirname = "devenv"
if __name__ == '__main__':
parser = argparse.ArgumentParser(description = "Run a docker for development of DL workspace")
parser.add_argument("-p", "--prefix",
help="Prefix of the docker name, or [dev]",
action="store",
default="dev" )
parser.add_argument("-t", "--tag",
help="Tag of the docker build, or [current]",
action = "store",
default = "latest" )
parser.add_argument("--nocache",
help="Tag of the docker build, or [current]",
action = "store_true")
args = parser.parse_args()
dockerprefix = args.prefix
dockertag = args.tag
dockername = dockerprefix + ":" + dockertag
#print args.nocache
dockername = build_docker(dockername, dirname, nocache = args.nocache)
run_docker(dockername, "DevDocker", devenv=True)
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Python
1
https://gitee.com/hejianop/apulis_platform.git
git@gitee.com:hejianop/apulis_platform.git
hejianop
apulis_platform
依瞳人工智能平台
v1.5.0

搜索帮助