[why] for user locally deploy compass-ci, ssh-r is not exists, so check when ssh-r already exists, skip ssh-r.
Signed-off-by: Liu Yinsi liuyinsi@163.com --- sparrow/4-docker/buildall | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/sparrow/4-docker/buildall b/sparrow/4-docker/buildall index bb77a1f..8d08603 100755 --- a/sparrow/4-docker/buildall +++ b/sparrow/4-docker/buildall @@ -56,7 +56,10 @@ do_one_run() mkdir $tmpdir/start_$container_name 2>/dev/null && ( cd "$container" - [ "$container_name" == 'ssh-r' ] && exit + [ "$container_name" == "ssh-r" ] && { + container_id=$(docker ps -aqf name="ssh_r") + [ -n "$container_id" ] && exit + } [ -x first-run ] && ./first-run [ -x start ] && ./start [ "$container_name" == 'initrd-lkp' ] && ./run