瀏覽代碼

Updated pybuilder example to use 'docker wait'

Solomon Hykes 12 年之前
父節點
當前提交
4004e86fa9
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      examples/pybuilder

+ 1 - 1
examples/pybuilder

@@ -49,7 +49,7 @@ if [ "$CMD" = "build" ]; then
 	fi
 
 	if attach $BUILD_JOB ; then
-		BUILD_STATUS=`docker ps -a | sed -E -n "s/^$BUILD_JOB.*Exit ([0-9]+) *$/\1/p"`
+		BUILD_STATUS=`docker wait $BUILD_JOB`
 		if [ -z "$BUILD_STATUS" -o "$BUILD_STATUS" != 0 ]; then
 			echo "Build failed"
 			exit 1