Skip to content

Commit 5913599

Browse files
authored
Merge pull request #65 from rostilos/1.2.0-rc
1.2.0 rc
2 parents bcd6ac1 + 9d1bc80 commit 5913599

File tree

429 files changed

+45979
-710
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

429 files changed

+45979
-710
lines changed

.gitignore

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,10 @@
44
*.iml
55
*.ipr
66
.github
7-
docker-compose.yml
7+
.vscode
8+
docker-compose.yml
9+
10+
**/newrelic.jar
11+
**/newrelic.yml
12+
13+
tools/environment/dumps

deployment/config/java-shared/application.properties.sample

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,23 @@ codecrow.webhook.base-url=http://localhost:8082
212212
#MCP CLIENT URL
213213
codecrow.mcp.client.url=http://host.docker.internal:8000/review
214214

215+
# ============================================================================
216+
# LLM Model Sync Configuration
217+
# ============================================================================
218+
# Sync schedule cron expression (default: daily at midnight)
219+
llm.sync.cron=0 0 0 * * *
220+
# Minimum context window for models to be included (default: 50000 tokens)
221+
llm.sync.min-context-window=50000
222+
# Provider API keys (optional - some providers allow listing without auth)
223+
# For OpenRouter: optional, improves rate limits
224+
llm.sync.openrouter.api-key=
225+
# For OpenAI: required for dynamic model list, falls back to static list without
226+
llm.sync.openai.api-key=
227+
# For Google: required for dynamic model list, falls back to static list without
228+
llm.sync.google.api-key=
229+
# For Anthropic: not used (static list, no public API for model listing)
230+
llm.sync.anthropic.api-key=
231+
215232
#RAG
216233
codecrow.rag.api.url=http://host.docker.internal:8001
217234
codecrow.rag.api.enabled=true

deployment/config/rag-pipeline/.env.sample

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ RAG_MAX_FILES_PER_INDEX=40000
2020

2121
RAG_USE_AST_SPLITTER=true
2222

23+
# Concurrency: Number of Uvicorn workers (allows parallel indexing)
24+
UVICORN_WORKERS=4
25+
2326
# Alternative OpenRouter models (use full format with provider prefix):
2427
# OPENROUTER_MODEL=openai/text-embedding-3-large # Higher quality, more expensive
2528
# OPENROUTER_MODEL=openai/text-embedding-ada-002 # Legacy model
Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,13 @@
11
VITE_API_URL=http://localhost:8081/api
22
VITE_WEBHOOK_URL=http://localhost:8082
33
VITE_GOOGLE_CLIENT_ID=YOUR_GOOGLE_CLIENT_ID
4-
SERVER_PORT=8080
4+
SERVER_PORT=8080
5+
6+
# New Relic Browser Monitoring (Optional - leave empty to disable)
7+
# Get these values from: https://one.newrelic.com -> Browser -> Add data -> Browser monitoring
8+
# License Key: Use the BROWSER (Ingest) license key, NOT the main license key
9+
VITE_NEW_RELIC_LICENSE_KEY=
10+
VITE_NEW_RELIC_APP_ID=
11+
VITE_NEW_RELIC_ACCOUNT_ID=
12+
VITE_NEW_RELIC_TRUST_KEY=
13+
VITE_NEW_RELIC_AGENT_ID=
Lines changed: 256 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,256 @@
1+
services:
2+
postgres:
3+
image: postgres:15-alpine
4+
container_name: codecrow-postgres
5+
environment:
6+
POSTGRES_DB: codecrow_ai
7+
POSTGRES_USER: codecrow_user
8+
POSTGRES_PASSWORD: codecrow_pass
9+
POSTGRES_INITDB_ARGS: "--encoding=UTF-8 --lc-collate=C --lc-ctype=C"
10+
ports:
11+
- "127.0.0.1:5432:5432"
12+
volumes:
13+
- postgres_data:/var/lib/postgresql/data
14+
networks:
15+
- codecrow-network
16+
healthcheck:
17+
test: ["CMD-SHELL", "pg_isready -U codecrow_user -d codecrow_ai"]
18+
interval: 30s
19+
timeout: 10s
20+
retries: 5
21+
start_period: 30s
22+
23+
redis:
24+
image: redis:7-alpine
25+
container_name: codecrow-redis
26+
ports:
27+
- "127.0.0.1:6379:6379"
28+
volumes:
29+
- redis_data:/data
30+
networks:
31+
- codecrow-network
32+
healthcheck:
33+
test: ["CMD", "redis-cli", "ping"]
34+
interval: 30s
35+
timeout: 10s
36+
retries: 5
37+
38+
qdrant:
39+
image: qdrant/qdrant:latest
40+
container_name: codecrow-qdrant
41+
ports:
42+
- "127.0.0.1:6333:6333"
43+
- "127.0.0.1:6334:6334"
44+
volumes:
45+
- qdrant_data:/qdrant/storage
46+
networks:
47+
- codecrow-network
48+
healthcheck:
49+
test: ["CMD-SHELL", "bash -c '>/dev/tcp/localhost/6333'"]
50+
interval: 30s
51+
timeout: 10s
52+
retries: 5
53+
start_period: 30s
54+
restart: unless-stopped
55+
56+
web-server:
57+
build:
58+
context: ../java-ecosystem/services/web-server
59+
dockerfile: Dockerfile.observable
60+
container_name: codecrow-web-application
61+
environment:
62+
SPRING_DATASOURCE_URL: jdbc:postgresql://postgres:5432/codecrow_ai
63+
SPRING_DATASOURCE_USERNAME: codecrow_user
64+
SPRING_DATASOURCE_PASSWORD: codecrow_pass
65+
66+
SPRING_JPA_HIBERNATE_DDL_AUTO: update
67+
SPRING_JPA_SHOW_SQL: "true"
68+
SPRING_JPA_PROPERTIES_HIBERNATE_FORMAT_SQL: "true"
69+
SPRING_JPA_DATABASE_PLATFORM: org.hibernate.dialect.PostgreSQLDialect
70+
SPRING_CONFIG_LOCATION: file:/app/config/application.properties
71+
72+
SERVER_PORT: 8081
73+
74+
SPRING_SESSION_STORE_TYPE: redis
75+
SPRING_REDIS_HOST: redis
76+
SPRING_REDIS_PORT: 6379
77+
MANAGEMENT_ENDPOINTS_WEB_EXPOSURE_INCLUDE: health,info,metrics
78+
MANAGEMENT_ENDPOINT_HEALTH_SHOW_DETAILS: when-authorized
79+
JAVA_OPTS: "-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5005"
80+
LOGGING_FILE_NAME: /app/logs/codecrow-web-application.log
81+
# Internal API secret for service-to-service communication
82+
CODECROW_INTERNAL_API_SECRET: ${INTERNAL_API_SECRET:-codecrow-internal-secret-change-me}
83+
ports:
84+
- "8081:8081"
85+
- "5005:5005"
86+
depends_on:
87+
postgres:
88+
condition: service_healthy
89+
redis:
90+
condition: service_healthy
91+
networks:
92+
- codecrow-network
93+
volumes:
94+
- web_logs:/app/logs
95+
- ./config/java-shared/application.properties:/app/config/application.properties
96+
- ./config/java-shared/github-private-key/codecrow-local.2025-12-09.private-key.pem:/app/config/github-app-private-key.pem
97+
healthcheck:
98+
test: ["CMD", "curl", "-f", "http://localhost:8081/actuator/health"]
99+
interval: 30s
100+
timeout: 10s
101+
retries: 5
102+
start_period: 60s
103+
restart: unless-stopped
104+
105+
pipeline-agent:
106+
build:
107+
context: ../java-ecosystem/services/pipeline-agent
108+
dockerfile: Dockerfile.observable
109+
container_name: codecrow-pipeline-agent
110+
environment:
111+
SPRING_DATASOURCE_URL: jdbc:postgresql://postgres:5432/codecrow_ai
112+
SPRING_DATASOURCE_USERNAME: codecrow_user
113+
SPRING_DATASOURCE_PASSWORD: codecrow_pass
114+
115+
SPRING_JPA_HIBERNATE_DDL_AUTO: update
116+
SPRING_JPA_SHOW_SQL: "true"
117+
SPRING_JPA_PROPERTIES_HIBERNATE_FORMAT_SQL: "true"
118+
SPRING_JPA_DATABASE_PLATFORM: org.hibernate.dialect.PostgreSQLDialect
119+
SPRING_CONFIG_LOCATION: file:/app/config/application.properties
120+
121+
SERVER_PORT: 8082
122+
123+
SPRING_SESSION_STORE_TYPE: redis
124+
SPRING_REDIS_HOST: redis
125+
SPRING_REDIS_PORT: 6379
126+
RAG_API_URL: http://localhost:8001
127+
RAG_ENABLED: "true"
128+
JAVA_OPTS: "-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5006"
129+
LOGGING_FILE_NAME: /app/logs/codecrow-pipeline-agent.log
130+
ports:
131+
- "8082:8082"
132+
- "5006:5006"
133+
depends_on:
134+
postgres:
135+
condition: service_healthy
136+
redis:
137+
condition: service_healthy
138+
fix-permissions:
139+
condition: service_completed_successfully
140+
networks:
141+
- codecrow-network
142+
volumes:
143+
- source_code_tmp:/tmp
144+
- pipeline_agent_logs:/app/logs
145+
- ./config/java-shared/application.properties:/app/config/application.properties
146+
- ./config/java-shared/github-private-key/codecrow-local.2025-12-09.private-key.pem:/app/config/github-app-private-key.pem
147+
healthcheck:
148+
test: [ "CMD", "curl", "-f", "http://localhost:8082/actuator/health" ]
149+
interval: 30s
150+
timeout: 10s
151+
retries: 5
152+
start_period: 60s
153+
restart: unless-stopped
154+
extra_hosts:
155+
- "host.docker.internal:host-gateway"
156+
157+
mcp-client:
158+
build:
159+
context: ../python-ecosystem/mcp-client
160+
container_name: codecrow-mcp-client
161+
ports:
162+
- "127.0.0.1:8000:8000"
163+
depends_on:
164+
- rag-pipeline
165+
networks:
166+
- codecrow-network
167+
volumes:
168+
- ./config/mcp-client/.env:/app/.env
169+
restart: unless-stopped
170+
extra_hosts:
171+
- "host.docker.internal:host-gateway"
172+
deploy:
173+
resources:
174+
limits:
175+
cpus: '1.0'
176+
memory: 1G
177+
reservations:
178+
cpus: '0.5'
179+
memory: 512M
180+
181+
rag-pipeline:
182+
build:
183+
context: ../python-ecosystem/rag-pipeline
184+
container_name: codecrow-rag-pipeline
185+
ports:
186+
- "127.0.0.1:8001:8001"
187+
depends_on:
188+
fix-permissions:
189+
condition: service_completed_successfully
190+
qdrant:
191+
condition: service_healthy
192+
networks:
193+
- codecrow-network
194+
volumes:
195+
- source_code_tmp:/tmp
196+
- rag_logs:/app/logs
197+
- ./config/rag-pipeline/.env:/app/.env
198+
healthcheck:
199+
test: [ "CMD", "curl", "-f", "http://localhost:8001/health" ]
200+
interval: 30s
201+
timeout: 10s
202+
retries: 5
203+
start_period: 60s
204+
restart: unless-stopped
205+
extra_hosts:
206+
- "host.docker.internal:host-gateway"
207+
208+
web-frontend:
209+
build:
210+
context: ../frontend
211+
container_name: codecrow-web-frontend
212+
ports:
213+
- "8080:8080"
214+
networks:
215+
- codecrow-network
216+
volumes:
217+
- web_frontend_logs:/app/logs
218+
- ./config/web-frontend/.env:/app/.env
219+
command: ["sh", "-c", "serve -s dist -l 8080 >> /app/logs/web-frontend.log 2>&1"]
220+
restart: unless-stopped
221+
222+
fix-permissions:
223+
image: busybox
224+
command: sh -c "chmod -R 777 /tmp"
225+
volumes:
226+
- source_code_tmp:/tmp
227+
228+
volumes:
229+
source_code_tmp:
230+
name: source_code_tmp
231+
driver: local
232+
postgres_data:
233+
name: postgres_data
234+
driver: local
235+
redis_data:
236+
name: redis_data
237+
driver: local
238+
qdrant_data:
239+
name: qdrant_data
240+
driver: local
241+
web_logs:
242+
name: web_logs
243+
driver: local
244+
pipeline_agent_logs:
245+
name: agent_logs
246+
driver: local
247+
web_frontend_logs:
248+
name: frontend_logs
249+
driver: local
250+
rag_logs:
251+
name: rag_logs
252+
driver: local
253+
254+
networks:
255+
codecrow-network:
256+
driver: bridge

deployment/docker-compose-sample.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ services:
88
POSTGRES_PASSWORD: codecrow_pass
99
POSTGRES_INITDB_ARGS: "--encoding=UTF-8 --lc-collate=C --lc-ctype=C"
1010
ports:
11-
- "5432:5432"
11+
- "127.0.0.1:5432:5432"
1212
volumes:
1313
- postgres_data:/var/lib/postgresql/data
1414
networks:
@@ -24,7 +24,7 @@ services:
2424
image: redis:7-alpine
2525
container_name: codecrow-redis
2626
ports:
27-
- "6379:6379"
27+
- "127.0.0.1:6379:6379"
2828
volumes:
2929
- redis_data:/data
3030
networks:
@@ -39,8 +39,8 @@ services:
3939
image: qdrant/qdrant:latest
4040
container_name: codecrow-qdrant
4141
ports:
42-
- "6333:6333"
43-
- "6334:6334"
42+
- "127.0.0.1:6333:6333"
43+
- "127.0.0.1:6334:6334"
4444
volumes:
4545
- qdrant_data:/qdrant/storage
4646
networks:
@@ -157,7 +157,7 @@ services:
157157
context: ../python-ecosystem/mcp-client
158158
container_name: codecrow-mcp-client
159159
ports:
160-
- "8000:8000"
160+
- "127.0.0.1:8000:8000"
161161
depends_on:
162162
- rag-pipeline
163163
networks:
@@ -181,7 +181,7 @@ services:
181181
context: ../python-ecosystem/rag-pipeline
182182
container_name: codecrow-rag-pipeline
183183
ports:
184-
- "8001:8001"
184+
- "127.0.0.1:8001:8001"
185185
depends_on:
186186
fix-permissions:
187187
condition: service_completed_successfully

0 commit comments

Comments
 (0)