start server after migrate, start frontend after server
This commit is contained in:
parent
863918cc4f
commit
0d7a764f50
@ -1,16 +1,7 @@
|
|||||||
version: "3.7"
|
version: "3.7"
|
||||||
|
|
||||||
services:
|
services:
|
||||||
webapp:
|
# Prisma sqlite migration utility
|
||||||
build:
|
|
||||||
context: ./webapp
|
|
||||||
dockerfile: Dockerfile
|
|
||||||
args:
|
|
||||||
- VITE_SERVER_INTERNAL=http://server:8080
|
|
||||||
- VITE_BRANDING=Noteshare.space [preview]
|
|
||||||
ports:
|
|
||||||
- "3000:3000"
|
|
||||||
|
|
||||||
migrate:
|
migrate:
|
||||||
build:
|
build:
|
||||||
context: ./server/prisma
|
context: ./server/prisma
|
||||||
@ -20,6 +11,7 @@ services:
|
|||||||
environment:
|
environment:
|
||||||
- DATABASE_URL=file:/database/db.sqlite
|
- DATABASE_URL=file:/database/db.sqlite
|
||||||
|
|
||||||
|
# Backend server for managing saved notes
|
||||||
server:
|
server:
|
||||||
build:
|
build:
|
||||||
context: ./server
|
context: ./server
|
||||||
@ -35,9 +27,21 @@ services:
|
|||||||
- POST_LIMIT_WINDOW_SECONDS=86400
|
- POST_LIMIT_WINDOW_SECONDS=86400
|
||||||
- POST_LIMIT=50
|
- POST_LIMIT=50
|
||||||
depends_on:
|
depends_on:
|
||||||
- migrate
|
migrate:
|
||||||
|
condition: service_completed_successfully
|
||||||
|
|
||||||
|
# Frontend for serving encrypted notes over HTML (SvelteKit)
|
||||||
|
webapp:
|
||||||
|
build:
|
||||||
|
context: ./webapp
|
||||||
|
dockerfile: Dockerfile
|
||||||
|
args:
|
||||||
|
- VITE_SERVER_INTERNAL=http://server:8080
|
||||||
|
- VITE_BRANDING=Noteshare.space [preview]
|
||||||
|
ports:
|
||||||
|
- "3000:3000"
|
||||||
|
depends_on:
|
||||||
|
- server
|
||||||
|
|
||||||
## By default this config uses default local driver,
|
|
||||||
## For custom volumes replace with volume driver configuration.
|
|
||||||
volumes:
|
volumes:
|
||||||
sqlite:
|
sqlite:
|
Loading…
Reference in New Issue
Block a user