fix(ci): allow synthetic executable fixtures on PostgreSQL test tmpfs
This commit is contained in:
1 parent
0ba1dcfef0
commit
354cd6c5ae
1 file changed
+5
-2
@@ -30,9 +30,12 @@ if [[ "$ready" != true ]]; then
|
|||||||
echo 'Synthetic PostgreSQL did not become ready' >&2
|
echo 'Synthetic PostgreSQL did not become ready' >&2
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
# Docker --tmpfs defaults to noexec, unlike the Dockerfile test stage's
|
||||||
|
# BuildKit tmpfs. Test helpers put synthetic pdfinfo/7z executables in TMPDIR.
|
||||||
|
# Keep execution enabled only in this disposable test container's scratch.
|
||||||
docker run --rm --name "$tests" --network "container:$postgres" \
|
docker run --rm --name "$tests" --network "container:$postgres" \
|
||||||
--tmpfs /test-tmp:rw,size=2147483648 \
|
--tmpfs /test-tmp:rw,exec,size=2147483648 \
|
||||||
--env TMPDIR=/test-tmp --env GOTMPDIR=/tmp \
|
--env TMPDIR=/test-tmp --env GOTMPDIR=/tmp \
|
||||||
--env GOPROXY=off --env GOSUMDB=off \
|
--env GOPROXY=off --env GOSUMDB=off \
|
||||||
--env PAGESWIKI_TEST_POSTGRES_DSN='postgres://postgres:pageswiki-synthetic-ci-only@127.0.0.1:5432/pageswiki_test?sslmode=disable' \
|
--env PAGESWIKI_TEST_POSTGRES_DSN='postgres://postgres:pageswiki-synthetic-ci-only@127.0.0.1:5432/pageswiki_test?sslmode=disable' \
|
||||||
"$test_image" go test -p 1 ./...
|
"$test_image" sh -ec 'cp /bin/busybox /test-tmp/busybox; /test-tmp/busybox true; exec go test -p 1 ./...'
|
||||||
Reference in new issue
Block a user