File tree Expand file tree Collapse file tree 1 file changed +21
-2
lines changed
Expand file tree Collapse file tree 1 file changed +21
-2
lines changed Original file line number Diff line number Diff line change 33# Parse command line arguments.
44prune=false
55push=false
6- for key in " $@ " ; do
6+ cpu_shares=0
7+ cpu_quota=-1
8+ while [[ $# -gt 0 ]]; do
9+ key=" $1 "
710 case $key in
811 --prune)
912 prune=true
13+ shift
1014 ;;
1115 --push)
1216 push=true
17+ shift
18+ ;;
19+ --cpu-shares)
20+ cpu_shares=" $2 "
21+ shift
22+ shift
23+ ;;
24+ --cpu-quota)
25+ cpu_quota=" $2 "
26+ shift
27+ shift
28+ ;;
29+ * )
30+ echo " Unknown option $key "
31+ exit 1
1332 ;;
1433 esac
1534done
1837PROJECT_VERSION=" $( cat ./tensorflow_cc/PROJECT_VERSION) "
1938
2039for tag in ubuntu ubuntu-cuda archlinux archlinux-cuda; do
21- docker build --pull -t floopcz/tensorflow_cc:${tag} -f Dockerfiles/${tag} .
40+ docker build --cpu-shares= " ${cpu_shares} " --cpu-quota= " ${cpu_quota} " -- pull -t floopcz/tensorflow_cc:${tag} -f Dockerfiles/${tag} .
2241 docker tag floopcz/tensorflow_cc:${tag} floopcz/tensorflow_cc:${tag} -" ${PROJECT_VERSION} "
2342 if $push ; then
2443 docker push floopcz/tensorflow_cc:${tag}
You can’t perform that action at this time.
0 commit comments