Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
move database initialisation to startup script
Browse files Browse the repository at this point in the history
  • Loading branch information
hydazz committed Mar 5, 2023
1 parent c3ea3f4 commit ca2e1a7
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
1 change: 0 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ RUN \
git checkout ${APP_VERSION} && \
echo "**** build server ****" && \
npm install && \
npx prisma migrate deploy && \
npm ci && \
npm run build && \
npm prune --omit=dev --omit=optional && \
Expand Down
1 change: 0 additions & 1 deletion Dockerfile.aarch64
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ RUN \
git checkout ${APP_VERSION} && \
echo "**** build server ****" && \
npm install && \
npx prisma migrate deploy && \
npm ci && \
npm run build && \
npm prune --omit=dev --omit=optional && \
Expand Down
8 changes: 6 additions & 2 deletions root/etc/s6-overlay/s6-rc.d/init-config-ai-chat-app/run
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
#!/usr/bin/with-contenv bash
# shellcheck shell=bash

# initialise database
cd /app/ai-chat-app
npx prisma migrate deploy &>/dev/null

# permissions
chown -R abc:abc \
/config \
/app
/config \
/app

0 comments on commit ca2e1a7

Please sign in to comment.