Skip to content

Commit 1e87558

Browse files
Merge upstream develop
2 parents 6d2f333 + 45337dc commit 1e87558

1 file changed

Lines changed: 16 additions & 2 deletions

File tree

.gitlab/ci/scripts/integration-moderation.sh

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,16 @@ trap cleanup EXIT
4444
echo "==> Clearing any stale stack…"
4545
docker compose down -v >/dev/null 2>&1 || true
4646

47-
echo "==> Bringing up the server stack…"
48-
docker compose up -d --build --wait postgres rustfs kafka server
47+
echo "==> Bringing up infrastructure…"
48+
# Start infrastructure services first. Notably, we avoid the scraper
49+
# service because it's unnecessary for the test. Also, in CI's dind environment
50+
# the scraper cannot start because its nftables egress firewall requires
51+
# CAP_NET_ADMIN, and an exited dependency container causes compose v2 to
52+
# return a non-zero exit code, aborting the script.
53+
docker compose up -d --build --wait postgres rustfs kafka
54+
55+
echo "==> Creating object-store bucket…"
56+
docker compose run --rm rustfs-init
4957

5058
if [[ "${CI:-}" == "true" ]]; then
5159
echo "==> Joining the job container to the stack network ($NETWORK)…"
@@ -60,6 +68,12 @@ if [[ "${CI:-}" == "true" ]]; then
6068
export POLYCENTRIC_TEST_KAFKA_BROKERS="kafka:19092"
6169
fi
6270

71+
echo "==> Building and starting the server…"
72+
# Build and start the server without its depends_on chain (--no-deps), so
73+
# the scraper container is not pulled in. The infrastructure is already
74+
# running, so this is safe.
75+
docker compose up -d --no-deps --build --wait server
76+
6377
echo "==> Waiting for the server gRPC port ($SERVER_HOST:$SERVER_PORT)…"
6478
for _ in $(seq 1 60); do
6579
if (exec 3<>"/dev/tcp/$SERVER_HOST/$SERVER_PORT") 2>/dev/null; then

0 commit comments

Comments
 (0)