Skip to content

Commit

Permalink
Merge branch 'release-0.2.0' into fix/daniel-fix-frontend-allocation-…
Browse files Browse the repository at this point in the history
…options-1321
  • Loading branch information
hamed-valiollahi authored Dec 5, 2024
2 parents 098de49 + db5664f commit a8e81a7
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
12 changes: 9 additions & 3 deletions backend/lcfs/prestart.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
#!/usr/bin/env bash

echo "running prestart.sh from $(pwd)"
echo "Running prestart.sh from $(pwd)"

# Check for Alembic head conflicts
HEAD_COUNT=$(poetry run alembic heads | wc -l)
if [ "$HEAD_COUNT" -gt 1 ]; then
echo "Alembic head conflict detected: Multiple migration heads present."
exit 1
fi

# Apply base database migrations
echo "Applying base migrations."
Expand All @@ -23,5 +30,4 @@ if [ $? -ne 0 ]; then
fi

echo "Migrations and seeding completed successfully."

echo "done running prestart.sh from $(pwd)"
echo "Done running prestart.sh from $(pwd)"
3 changes: 3 additions & 0 deletions backend/lcfs/start.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
#!/usr/bin/env bash

# Enable strict error handling
set -e

# Wait for the database to be ready
./wait-for-it.sh $LCFS_DB_HOST:5432 --timeout=30

Expand Down

0 comments on commit a8e81a7

Please sign in to comment.