Spaces:
3SCError404
/
Paused

File size: 1,527 Bytes
6ce65e2
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# Nexus Master Gateway - Local Development Template
# INSTRUCTIONS: 
# 1. Copy this file to 'compose.local.yml'
# 2. Update environment variables in '.env'
# 3. Run: docker compose -f compose.local.yml up

services:
  redis:
    image: redis:7-alpine
    container_name: nexus_search_cache
    ports:
      - "6380:6379"
    restart: always
    healthcheck:
      test: [ "CMD", "redis-cli", "ping" ]
      interval: 5s
      timeout: 3s
      retries: 5
    networks:
      - app-network

  nexus-api:
    build:
      context: .
      target: heavy
    container_name: nexus_master_api
    env_file: .env
    # NOTE: 'host.docker.internal' is required if your Ollama/DB is running on the host OS.
    # extra_hosts:
    #   - "host.docker.internal:host-gateway"
    restart: always
    ports:
      - "8000:8000"
    volumes:
      - .:/app
      - ./uploads:/app/uploads
      - ./logs:/app/logs
    command: [ "uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000", "--reload" ]
    healthcheck:
      test: [ "CMD", "curl", "-f", "http://localhost:8000/health" ]
      interval: 30s
      timeout: 10s
      retries: 3
    networks:
      - app-network

  nexus-worker:
    build:
      context: .
      target: heavy
    container_name: nexus_worker
    env_file: .env
    # extra_hosts:
    #   - "host.docker.internal:host-gateway"
    restart: always
    command: [ "arq", "nexus_worker.WorkerSettings" ]
    volumes:
      - .:/app
    networks:
      - app-network

networks:
  app-network:
    driver: bridge