File size: 1,159 Bytes
ffb6330
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
version: '3.8'


services:
  webserver:
    build:
      context: .
      dockerfile: Dockerfile
    container_name: ai-infra-guard-webserver
    ports:
      - "8088:8088"
    environment:
      - APP_ENV=production
      - UPLOAD_DIR=/ai-infra-guard/uploads
      - DB_PATH=/ai-infra-guard/db/tasks.db
      - TZ=Asia/Shanghai
    volumes:
      - ./data:/ai-infra-guard/data
      - ./db:/ai-infra-guard/db
      - ./logs:/ai-infra-guard/logs
      - ./uploads:/ai-infra-guard/uploads
    networks:
      - ai-infra-guard-network
    restart: always
    healthcheck:
      test: [ "CMD", "curl",  "http://localhost:8088/" ]
      interval: 30s
      timeout: 3s
      start_period: 5s
      retries: 3
  agent:
    build:
      context: .
      dockerfile: Dockerfile_Agent
    container_name: ai-infra-guard-agent
    environment:
      - TZ=Asia/Shanghai
      - AIG_SERVER=webserver:8088
    security_opt:
      - seccomp:unconfined
    networks:
      - ai-infra-guard-network
    restart: always
    depends_on:
      webserver:
        condition: service_healthy
networks:
  ai-infra-guard-network:
    driver: bridge
    name: ai-infra-guard-network