project init
This commit is contained in:
57
docker/docker-compose.yml
Normal file
57
docker/docker-compose.yml
Normal file
@ -0,0 +1,57 @@
|
||||
version: '3.8'
|
||||
|
||||
services:
|
||||
postgres:
|
||||
image: pgvector/pgvector:pg16
|
||||
container_name: coursecraft-postgres
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
POSTGRES_USER: postgres
|
||||
POSTGRES_PASSWORD: postgres
|
||||
POSTGRES_DB: coursecraft
|
||||
ports:
|
||||
- "5432:5432"
|
||||
volumes:
|
||||
- ./data/postgres:/var/lib/postgresql/data
|
||||
- ./init-scripts:/docker-entrypoint-initdb.d
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U postgres"]
|
||||
interval: 10s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
|
||||
redis:
|
||||
image: redis:7-alpine
|
||||
container_name: coursecraft-redis
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- "6395:6379"
|
||||
volumes:
|
||||
- ./data/redis:/data
|
||||
command: redis-server --appendonly yes
|
||||
healthcheck:
|
||||
test: ["CMD", "redis-cli", "ping"]
|
||||
interval: 10s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
|
||||
meilisearch:
|
||||
image: getmeili/meilisearch:v1.6
|
||||
container_name: coursecraft-meilisearch
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
MEILI_MASTER_KEY: ${MEILISEARCH_API_KEY:-coursecraft-dev-key}
|
||||
MEILI_ENV: development
|
||||
ports:
|
||||
- "7700:7700"
|
||||
volumes:
|
||||
- ./data/meilisearch:/meili_data
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost:7700/health"]
|
||||
interval: 10s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
|
||||
networks:
|
||||
default:
|
||||
name: coursecraft-network
|
||||
5
docker/init-scripts/01-extensions.sql
Normal file
5
docker/init-scripts/01-extensions.sql
Normal file
@ -0,0 +1,5 @@
|
||||
-- Enable pgvector extension for embeddings storage
|
||||
CREATE EXTENSION IF NOT EXISTS vector;
|
||||
|
||||
-- Enable uuid-ossp for UUID generation
|
||||
CREATE EXTENSION IF NOT EXISTS "uuid-ossp";
|
||||
Reference in New Issue
Block a user