diff --git a/.github/workflows/测http-server.yaml b/.github/workflows/测http-server.yaml index 1e5c336..7dee398 100644 --- a/.github/workflows/测http-server.yaml +++ b/.github/workflows/测http-server.yaml @@ -12,5 +12,10 @@ jobs: - name: step1 run: | set -x - npx http-server -p=4251 ./gitea - curl -s http://localhost:4251/ \ No newline at end of file + mkdir -p gitea + echo '

hello world

' > gitea/index.html + npx http-server -p=4251 ./gitea & + SERVER_PID=$! + sleep 1 # 等待服务器启动 + curl -s http://localhost:4251/ + kill $SERVER_PID \ No newline at end of file