From 51d2d75f541b8e59bd9898a05ba15fd0d5c25e81 Mon Sep 17 00:00:00 2001 From: simon-mo Date: Mon, 19 Feb 2024 22:02:40 -0800 Subject: [PATCH] Add sanity test --- .github/workflows/rocm.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/rocm.yml b/.github/workflows/rocm.yml index 86b6412ad4fc6..725aa9f14757e 100644 --- a/.github/workflows/rocm.yml +++ b/.github/workflows/rocm.yml @@ -23,7 +23,15 @@ jobs: docker build -t rocm -f Dockerfile.rocm . - name: Run Sanity Test run: | - docker run --detached --p 8000:8000 rocm + # detele any existing container + docker rm -f $(docker ps -a -q) + # run the container + docker run -d --p 8000:8000 rocm + # wait for the server to start while [ "$(curl -s -o /dev/null -w ''%{http_code}'' localhost:8000)" != "200" ]; do sleep 1; done + # run the sanity test python examples/openai_completion_client.py + # remove the container + docker rm -f $(docker ps -a -q) +