diff --git a/ci/lighttpd.conf b/ci/lighttpd.conf index 6006c82..8075011 100644 --- a/ci/lighttpd.conf +++ b/ci/lighttpd.conf @@ -1,5 +1,6 @@ server.modules = ("mod_auth", "mod_fastcgi") +server.pid-file = "/tmp/lighttpd-ci.pid" server.port = 8080 server.document-root = "ci" diff --git a/ci/test-e2e.sh b/ci/test-e2e.sh index 3cdecb4..119b38f 100755 --- a/ci/test-e2e.sh +++ b/ci/test-e2e.sh @@ -15,20 +15,22 @@ echo -e '::endgroup::\n' declare -A servers=( [nginx]="nginx -c ${PWD}/ci/nginx.conf" - [Apache httpd]="apache2 -d ci -f apache2.conf -D FOREGROUND" + [apache2]="apache2 -d ci -f apache2.conf -D FOREGROUND" [lighttpd]="lighttpd -f ci/lighttpd.conf -D" ) for srv in "${!servers[@]}"; do echo "::group::Test with ${srv}" RUST_LOG=trace target/debug/examples/hello-cgi 2> "e2e-logs/hello-cgi-${srv}.log" & + fcgi_pid="$!" + ${servers["$srv"]} 2> "e2e-logs/${srv}.log" & newman run ci/e2e.postman_collection --env-var 'base_url=localhost:8080' \ --color on --timeout 600000 - kill %2 %1 + kill $(cat "/tmp/${srv}-ci.pid") "$fcgi_pid" wait -f echo '::endgroup::' # Avoid spurious socket errors between different servers - sleep 1s + sleep 2s done