mirror of
https://github.com/ramvignesh-b/pi-ku.git
synced 2026-05-04 08:56:52 +00:00
fix: update e2e script to include e2e env source
This commit is contained in:
@@ -21,7 +21,7 @@ BASE_DIR = Path(__file__).resolve().parent.parent
|
||||
|
||||
# Load dotenv files
|
||||
env = environ.Env()
|
||||
env_file = os.path.join(BASE_DIR.parent, ".env")
|
||||
env_file = os.environ.get("PIKU_ENV_FILE", os.path.join(BASE_DIR.parent, ".env"))
|
||||
if os.path.exists(env_file):
|
||||
environ.Env.read_env(env_file, overwrite=False)
|
||||
|
||||
|
||||
@@ -35,6 +35,7 @@ cleanup() {
|
||||
trap cleanup EXIT
|
||||
|
||||
echo "Starting Database and Mail server..."
|
||||
|
||||
COMPOSE_BIN="$(command -v docker-compose || true)"
|
||||
|
||||
if echo "$CONTAINER_BIN" | grep -q "podman"; then
|
||||
@@ -51,6 +52,7 @@ until $CONTAINER_BIN exec "$DB_NAME" pg_isready -U "${DB_USER:-test}" >/dev/null
|
||||
sleep 2
|
||||
done
|
||||
|
||||
export PIKU_ENV_FILE="$ENV_FILE"
|
||||
echo "Starting Backend..."
|
||||
mkdir -p ./tmp/logs
|
||||
(cd backend && uv run manage.py migrate)
|
||||
|
||||
Reference in New Issue
Block a user