File size: 5,035 Bytes
bd67f06
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
services:
  # --- HRMS (Frappe) ---
  frappe-hrms-mariadb:
    image: ghcr.io/collinear-ai/collinear/frappe-hrms-mariadb:latest
    environment:
      MYSQL_ROOT_PASSWORD: admin
      MARIADB_ROOT_PASSWORD: admin

  frappe-hrms-redis:
    image: ghcr.io/collinear-ai/collinear/frappe-hrms-redis:latest

  frappe-hrms:
    image: ghcr.io/collinear-ai/collinear/frappe-hrms:latest
    environment:
      FRAPPE_SITE_NAME: hrms.localhost
      FRAPPE_ADMIN_PASSWORD: admin
      FRAPPE_DB_HOST: frappe-hrms-mariadb
      FRAPPE_DB_PORT: "3306"
      FRAPPE_DB_ROOT_PASSWORD: admin
      FRAPPE_REDIS_HOST: frappe-hrms-redis
      FRAPPE_REDIS_PORT: "6379"
      FRAPPE_SOCKETIO_PORT: "9000"
      FRAPPE_DEVELOPER_MODE: "1"
      FRAPPE_ENABLE_SCHEDULER: "1"
      FRAPPE_INSTALL_APPS: hrms,collinear_hrms_seed
      FRAPPE_DEPENDENCY_TIMEOUT: "180"
    depends_on:
      frappe-hrms-mariadb:
        condition: service_healthy
      frappe-hrms-redis:
        condition: service_healthy

  frappe-hrms-env:
    image: ghcr.io/collinear-ai/collinear/frappe-hrms-env:latest
    ports:
      - "8030:8030"
    environment:
      FRAPPE_BASE_URL: http://frappe-hrms:8000
      FRAPPE_SITE_NAME: hrms.localhost
      FRAPPE_ADMIN_USERNAME: Administrator
      FRAPPE_ADMIN_PASSWORD: admin
    depends_on:
      frappe-hrms:
        condition: service_healthy
    healthcheck:
      test: ["CMD-SHELL", "python3 -c \"import urllib.request; urllib.request.urlopen('http://localhost:8030/health')\""]
      interval: 15s
      timeout: 5s
      retries: 120
      start_period: 60s

  # --- Email (MailHog) ---
  mailhog:
    image: mailhog/mailhog:v1.0.1
    healthcheck:
      test: ["CMD-SHELL", "wget --spider -q http://localhost:8025/api/v2/messages || exit 1"]
      interval: 10s
      timeout: 5s
      retries: 6
      start_period: 10s

  email-env:
    image: ghcr.io/collinear-ai/collinear/email-env:latest
    ports:
      - "8040:8040"
    environment:
      MAILHOG_BASE_URL: http://mailhog:8025
      MAILHOG_SMTP_HOST: mailhog
      MAILHOG_SMTP_PORT: "1025"
    depends_on:
      mailhog:
        condition: service_healthy
    healthcheck:
      test: ["CMD-SHELL", "python3 -c \"import urllib.request; urllib.request.urlopen('http://localhost:8040/health')\""]
      interval: 10s
      timeout: 5s
      retries: 6
      start_period: 10s

  # --- Calendar (Baikal + Chronos) ---
  baikal:
    image: ckulka/baikal:0.10.1-nginx
    volumes:
      - baikal-config:/var/www/baikal/config
      - baikal-specific:/var/www/baikal/Specific
    healthcheck:
      test: ["CMD-SHELL", "curl -sf http://localhost:80/ > /dev/null || exit 1"]
      interval: 10s
      timeout: 5s
      retries: 10
      start_period: 10s

  chronos-mcp:
    image: ghcr.io/collinear-ai/collinear/chronos-mcp:latest
    environment:
      CALDAV_BASE_URL: http://baikal:80/dav.php
      CALDAV_USERNAME: chronos
      CALDAV_PASSWORD: admin
    depends_on:
      baikal:
        condition: service_healthy

  chronos-server:
    image: ghcr.io/collinear-ai/collinear/chronos-server:latest
    ports:
      - "8050:8050"
    environment:
      CHRONOS_MCP_URL: http://chronos-mcp:8040/mcp
      CALDAV_BASE_URL: http://baikal:80/dav.php
      CALDAV_USERNAME: chronos
      CALDAV_PASSWORD: admin
    depends_on:
      chronos-mcp:
        condition: service_healthy
    healthcheck:
      test: ["CMD-SHELL", "python3 -c \"import urllib.request; urllib.request.urlopen('http://localhost:8050/health')\""]
      interval: 10s
      timeout: 5s
      retries: 18
      start_period: 30s

  # --- RocketChat ---
  rocketchat-mongodb:
    image: ghcr.io/collinear-ai/collinear/rocketchat-mongodb:6-preseeded

  rocketchat:
    image: ghcr.io/collinear-ai/collinear/rocketchat:7.6.0
    depends_on:
      rocketchat-mongodb:
        condition: service_healthy

  rocketchat-env:
    image: ghcr.io/collinear-ai/collinear/rocketchat-env:latest
    ports:
      - "8060:8060"
    environment:
      ROCKETCHAT_BASE_URL: http://rocketchat:3000
    depends_on:
      rocketchat:
        condition: service_healthy
    healthcheck:
      test: ["CMD-SHELL", "python3 -c \"import urllib.request; urllib.request.urlopen('http://localhost:8060/health')\""]
      interval: 10s
      timeout: 5s
      retries: 12
      start_period: 30s

  # --- OpenEnv wrapper ---
  openenv-server:
    build:
      context: .
      dockerfile: server/Dockerfile
    ports:
      - "8000:8000"
    environment:
      HRMS_TOOL_SERVER_URL: http://frappe-hrms-env:8030
      EMAIL_TOOL_SERVER_URL: http://email-env:8040
      CALENDAR_TOOL_SERVER_URL: http://chronos-server:8050
      ROCKETCHAT_TOOL_SERVER_URL: http://rocketchat-env:8060
      COLLINEAR_API_KEY: ${COLLINEAR_API_KEY:-}
    depends_on:
      frappe-hrms-env:
        condition: service_healthy
      email-env:
        condition: service_healthy
      chronos-server:
        condition: service_healthy
      rocketchat-env:
        condition: service_healthy

volumes:
  baikal-config: {}
  baikal-specific: {}