feat: configure e2e database and email host aliases for Gitea Actions environment
CI / Generate Certificates (pull_request) Successful in 33s
CI / Frontend CI (pull_request) Successful in 1m7s
CI / Backend CI (pull_request) Successful in 1m8s
CI / E2E Tests (pull_request) Successful in 5m28s

This commit is contained in:
me
2026-05-05 20:07:14 +05:30
parent c00a954266
commit 133e79c0b3
+12
View File
@@ -55,6 +55,18 @@ until $CONTAINER_BIN exec "$DB_NAME" pg_isready -U "${DB_USER:-test}" >/dev/null
done done
export PIKU_ENV_FILE="$ENV_FILE" export PIKU_ENV_FILE="$ENV_FILE"
# NOTE: When running in Gitea Actions (within container), We must ponint DB and mail to the internal docker host instead.
if [ "$GITEA_ACTIONS" = "true" ]; then
sudo apt-get update && sudo apt-get install -y iproute2
# Sample: "default via <internal docker host IP> dev <network interface> proto dhcp src <IP> metric 100"
HOST_IP=$(ip route show default | awk '/default/ {print $3}')
echo "Running on Gitea. Internal Docker host... $HOST_IP"
export DB_HOST=$HOST_IP
export EMAIL_HOST=$HOST_IP
fi
echo "Starting Backend..." echo "Starting Backend..."
mkdir -p ./tmp/logs mkdir -p ./tmp/logs
( (