dev: switch to fully containerized Docker Compose workflow
- Replace tmux setup with a full Docker Compose development stack - Update backend Dockerfile to use `cargo-chef` caching and `supervisord` - Containerize frontend development server - Update tests to run in isolated containers - Remove legacy `papercrate.tmux`
This commit is contained in:
+13
-8
@@ -31,28 +31,33 @@ services:
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
|
||||
admin-bootstrap:
|
||||
test-runner:
|
||||
build:
|
||||
context: ./backend
|
||||
dockerfile: Dockerfile
|
||||
target: development
|
||||
depends_on:
|
||||
postgres-test:
|
||||
condition: service_healthy
|
||||
quickwit-test:
|
||||
condition: service_healthy
|
||||
volumes:
|
||||
- ./backend:/app
|
||||
- /app/target
|
||||
environment:
|
||||
DATABASE_URL: postgres://papercrate:papercrate_test@postgres-test:5432/papercrate_test
|
||||
TEST_DATABASE_URL: postgres://papercrate:papercrate_test@postgres-test:5432/papercrate_test
|
||||
DATABASE_MAX_POOL_SIZE: 1
|
||||
S3_BUCKET: documents
|
||||
JWT_SECRET: change-me-super-secret
|
||||
QUICKWIT_ENDPOINT: http://quickwit-test:7280
|
||||
entrypoint: []
|
||||
RUST_LOG: info
|
||||
command: >
|
||||
/bin/sh -c "
|
||||
echo 'Running database migrations' &&
|
||||
diesel migration run
|
||||
/bin/bash -c "
|
||||
echo 'Waiting for Postgres...' &&
|
||||
until pg_isready -h postgres-test -U papercrate; do sleep 1; done &&
|
||||
echo 'Running tests...' &&
|
||||
cargo test
|
||||
"
|
||||
user: root
|
||||
restart: "no"
|
||||
|
||||
volumes:
|
||||
quickwit_test_data:
|
||||
|
||||
Reference in New Issue
Block a user