浏览代码

[autotest] timeout oracle docker startup after 2 minutes

Morris Jobke 8 年之前
父节点
当前提交
a6daafa3cd
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      autotest.sh

+ 2 - 2
autotest.sh

@@ -167,8 +167,8 @@ function execute_tests {
 
 		echo "Waiting for Oracle initialization ... "
 
-		# grep exits on the first match and then the script continues
-		docker logs -f "$DOCKER_CONTAINER_ID" 2>&1 | grep -q "Grant succeeded."
+		# grep exits on the first match and then the script continues - times out after 2 minutes
+		timeout 120 docker logs -f "$DOCKER_CONTAINER_ID" 2>&1 | grep -q "Grant succeeded."
 
 		DATABASEUSER=autotest
 		DATABASENAME='XE'