New alert system and panel de control page
This commit is contained in:
43
Tiltfile
43
Tiltfile
@@ -48,14 +48,42 @@ def python_live_update(service_name, service_path):
|
||||
# =============================================================================
|
||||
# FRONTEND (React + Vite)
|
||||
# =============================================================================
|
||||
# Multi-stage build with optimized memory settings for large Vite builds
|
||||
# Set FRONTEND_DEBUG=true environment variable to build with development mode (no minification)
|
||||
# for easier debugging of React errors
|
||||
|
||||
# Check for FRONTEND_DEBUG environment variable (Starlark uses os.getenv)
|
||||
frontend_debug_env = os.getenv('FRONTEND_DEBUG', 'false')
|
||||
frontend_debug = frontend_debug_env.lower() == 'true'
|
||||
|
||||
# Log the build mode
|
||||
if frontend_debug:
|
||||
print("""
|
||||
🐛 FRONTEND DEBUG MODE ENABLED
|
||||
Building frontend with NO minification for easier debugging.
|
||||
Full React error messages will be displayed.
|
||||
To disable: unset FRONTEND_DEBUG or set FRONTEND_DEBUG=false
|
||||
""")
|
||||
else:
|
||||
print("""
|
||||
📦 FRONTEND PRODUCTION MODE
|
||||
Building frontend with minification for optimized performance.
|
||||
To enable debug mode: export FRONTEND_DEBUG=true
|
||||
""")
|
||||
|
||||
docker_build(
|
||||
'bakery/dashboard',
|
||||
context='./frontend',
|
||||
dockerfile='./frontend/Dockerfile.kubernetes',
|
||||
dockerfile='./frontend/Dockerfile.kubernetes.debug' if frontend_debug else './frontend/Dockerfile.kubernetes',
|
||||
# Remove target to build the full image, including the build stage
|
||||
live_update=[
|
||||
sync('./frontend/src', '/app/src'),
|
||||
sync('./frontend/public', '/app/public'),
|
||||
],
|
||||
# Increase Node.js memory for build stage
|
||||
build_args={
|
||||
'NODE_OPTIONS': '--max-old-space-size=8192'
|
||||
},
|
||||
# Ignore test artifacts and reports
|
||||
ignore=[
|
||||
'playwright-report/**',
|
||||
@@ -157,7 +185,7 @@ build_python_service('production-service', 'production')
|
||||
build_python_service('procurement-service', 'procurement') # NEW: Sprint 3
|
||||
build_python_service('orchestrator-service', 'orchestrator') # NEW: Sprint 2
|
||||
build_python_service('ai-insights-service', 'ai_insights') # NEW: AI Insights Platform
|
||||
build_python_service('alert-processor', 'alert_processor')
|
||||
build_python_service('alert-processor', 'alert_processor') # Unified Alert Service with enrichment
|
||||
build_python_service('demo-session-service', 'demo_session')
|
||||
|
||||
# =============================================================================
|
||||
@@ -181,7 +209,7 @@ k8s_resource('production-db', resource_deps=['security-setup'], labels=['databas
|
||||
k8s_resource('procurement-db', resource_deps=['security-setup'], labels=['databases']) # NEW: Sprint 3
|
||||
k8s_resource('orchestrator-db', resource_deps=['security-setup'], labels=['databases']) # NEW: Sprint 2
|
||||
k8s_resource('ai-insights-db', resource_deps=['security-setup'], labels=['databases']) # NEW: AI Insights Platform
|
||||
k8s_resource('alert-processor-db', resource_deps=['security-setup'], labels=['databases'])
|
||||
k8s_resource('alert-processor-db', resource_deps=['security-setup'], labels=['databases']) # Unified Alert Service
|
||||
k8s_resource('demo-session-db', resource_deps=['security-setup'], labels=['databases'])
|
||||
|
||||
k8s_resource('redis', resource_deps=['security-setup'], labels=['infrastructure'])
|
||||
@@ -373,6 +401,11 @@ k8s_resource('demo-seed-orchestration-runs',
|
||||
resource_deps=['orchestrator-migration', 'demo-seed-tenants'],
|
||||
labels=['demo-init'])
|
||||
|
||||
# Weight 28: Seed alerts (alert processor service) - after orchestration runs as alerts reference recent data
|
||||
k8s_resource('demo-seed-alerts',
|
||||
resource_deps=['alert-processor-migration', 'demo-seed-tenants'],
|
||||
labels=['demo-init'])
|
||||
|
||||
k8s_resource('demo-seed-pos-configs',
|
||||
resource_deps=['demo-seed-tenants'],
|
||||
labels=['demo-init'])
|
||||
@@ -526,8 +559,8 @@ k8s_resource('frontend',
|
||||
|
||||
# Update check interval - how often Tilt checks for file changes
|
||||
update_settings(
|
||||
max_parallel_updates=3,
|
||||
k8s_upsert_timeout_secs=60
|
||||
max_parallel_updates=2, # Reduce parallel updates to avoid resource exhaustion on local machines
|
||||
k8s_upsert_timeout_secs=120 # Increase timeout for slower local builds
|
||||
)
|
||||
|
||||
# Watch settings - configure file watching behavior
|
||||
|
||||
Reference in New Issue
Block a user