Skip to content

Commit c80f5f8

Browse files
Update .github/workflows/Dockerfile.qa
Co-authored-by: Hans Ott <hansott@hotmail.be>
1 parent 2e95fb0 commit c80f5f8

1 file changed

Lines changed: 1 addition & 22 deletions

File tree

.github/workflows/Dockerfile.qa

Lines changed: 1 addition & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -33,28 +33,7 @@ COPY --from=builder /app .
3333
COPY database.sql /app/database.sql
3434

3535
# Create startup script
36-
RUN echo '#!/bin/bash\n\
37-
\n\
38-
# Parse DATABASE_URL\n\
39-
if [ -z "$DATABASE_URL" ]; then\n\
40-
echo "DATABASE_URL environment variable is required"\n\
41-
exit 1\n\
42-
fi\n\
43-
\n\
44-
# Wait for postgres to be ready\n\
45-
until psql "$DATABASE_URL" -c "\q"; do\n\
46-
echo "Postgres is unavailable - sleeping"\n\
47-
sleep 1\n\
48-
done\n\
49-
\n\
50-
echo "Postgres is up - executing SQL script"\n\
51-
psql "$DATABASE_URL" -f /app/database.sql\n\
52-
echo "Creating tmp dir"\n\
53-
mkdir -pv /app/.tmp\n\
54-
\n\
55-
echo "Starting application"\n\
56-
AIKIDO_TMP_DIR=/app/.tmp make run' > /app/start.sh
57-
36+
COPY start.sh /app/start.sh
5837
RUN chmod 755 /app/start.sh
5938

6039
ENTRYPOINT ["/app/start.sh"]

0 commit comments

Comments
 (0)