-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #17 from nwikeodigwe/comment-test
Comment test
- Loading branch information
Showing
94 changed files
with
13,931 additions
and
9,183 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,12 @@ | ||
/backend/node_modules | ||
/backend/dist | ||
/backend/coverage | ||
/app/node_modules | ||
/app/dist | ||
/app/coverage | ||
|
||
/app/*.env* | ||
/app/*.log | ||
/app/logs | ||
|
||
/.vscode | ||
|
||
/mysql | ||
|
||
/backend/*.env* | ||
/backend/*.log |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
node_modules/ | ||
coverage/ | ||
|
||
package-lock.json | ||
|
||
*.log | ||
*.env* | ||
|
||
.gitignore |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
FROM node:21-alpine | ||
|
||
WORKDIR /app | ||
|
||
RUN apk add --no-cache openssl libssl3 | ||
ENV OPENSSL_DIR=/usr/lib/ssl | ||
|
||
COPY package*.json ./ | ||
|
||
RUN npm install | ||
COPY . . | ||
RUN npm install -g nodemon | ||
|
||
RUN adduser -D -u 1010 theia && chown -R theia /app | ||
USER theia | ||
|
||
RUN chmod +x entrypoint.sh | ||
|
||
EXPOSE 3000 |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#!/bin/sh | ||
MAX_RETRIES=10 | ||
RETRY_DELAY=2 | ||
RETRY_COUNT=0 | ||
|
||
echo "Applying database schema..." | ||
if ! npx prisma db push; then | ||
echo "Database schema push failed! Exiting." | ||
exit 1 | ||
fi | ||
|
||
echo "Running migrations..." | ||
RETRY_COUNT=0 | ||
|
||
until echo "yes" | npx prisma migrate dev; do | ||
echo "Migration failed. Retrying in $RETRY_DELAY seconds..." | ||
RETRY_COUNT=$((RETRY_COUNT + 1)) | ||
if [ $RETRY_COUNT -ge $MAX_RETRIES ]; then | ||
echo "Migration failed after $MAX_RETRIES attempts. Exiting." | ||
exit 1 | ||
fi | ||
sleep $RETRY_DELAY | ||
done | ||
|
||
echo "Migrations complete! Starting app..." | ||
exec npm start |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.