Repository navigation
Expand file tree
/
Copy path.env.example
More file actions
111 lines (93 loc) · 3.33 KB
/
Copy path.env.example
File metadata and controls
111 lines (93 loc) · 3.33 KB
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
# Kafka Configuration (external broker reachable from containers)
KAFKA_HOST=kafka
KAFKA_PORT=9092
KAFKA_INPUT_TOPIC=network.data.processed
KAFKA_OUTPUT_TOPIC=network.ml.results
#KAFKA_ENABLED= # true by default
# MLFlow Configuration
MLFLOW_TRACKING_URI=http://mlflow:5000
MLFLOW_EXPERIMENT_NAME=ml-service-default
# Postgres (MLflow backend store)
POSTGRES_USER=mlflow
POSTGRES_PASSWORD=mlflow
POSTGRES_DB=mlflow
POSTGRES_HOST_PORT=5432
POSTGRES_HOST=postgres
# MinIO (S3-compatible storage)
MINIO_ROOT_USER=minio
MINIO_ROOT_PASSWORD=minio123
MINIO_HOST=minio
MINIO_PORT=9000
MINIO_CONSOLE_PORT=9091
MINIO_BUCKET=mlflow
MINIO_HOST_PORT=9090
MINIO_CONSOLE_HOST_PORT=9091
# MLflow server artifact / backend
MLFLOW_DEFAULT_ARTIFACT_ROOT=s3://mlflow
MLFLOW_BACKEND_STORE_URI=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_HOST_PORT}/${POSTGRES_DB}
MLFLOW_S3_ENDPOINT_URL=http://${MINIO_HOST}:${MINIO_PORT}
AWS_ACCESS_KEY_ID=${MINIO_ROOT_USER}
AWS_SECRET_ACCESS_KEY=${MINIO_ROOT_PASSWORD}
AWS_DEFAULT_REGION=us-east-1
MLFLOW_S3_IGNORE_TLS=true
# MLflow listen settings
MLFLOW_HOST=0.0.0.0
MLFLOW_PORT=5000
MLFLOW_VERSION=latest
# Data Storage API Configuration (update if this service is in-stack)
DATA_STORAGE_HOST=data-storage
DATA_STORAGE_HOST_PORT=8000
DATA_STORAGE_API_URL=http://${DATA_STORAGE_HOST}:${DATA_STORAGE_HOST_PORT}
DATA_STORAGE_EXAMPLE_ENDPOINT=/api/v1/processed/example
DATA_STORAGE_EXCLUDED_FIELDS=window_start_time,window_end_time,window_duration_seconds,cell_index,network,sample_count
DATA_STORAGE_DATA_ENDPOINT=/api/v1/processed
DATA_STORAGE_CELL_ENDPOINT=/api/v1/cell
# API Configuration
API_HOST=0.0.0.0
API_PORT=8060
ML_PORT=8060
API_RELOAD=true
# Logging
LOG_LEVEL=INFO
# Database Configuration
DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_HOST_PORT}/ml_service
# Auto-monitoring
MONITORING_ENABLED=true
MONITORING_INTERVAL_SECONDS=300
MONITORING_TRIGGER_MODE=time # time | data | both
MONITORING_DEGRADATION_FACTOR=1.5
MAX_EVAL_CELLS= 20
# Slack Notifications
SLACK_NOTIFY=false
#SLACK_WEBHOOK_URL=https://hooks.slack.com/services/XXX/YYY/ZZZ
# Policy Service Integration
POLICY_SERVICE_URL=http://policy-service:8788
POLICY_COMPONENT_ID=ml-service
POLICY_ENABLED=false
POLICY_FAILOPEN=true
POLICY_ROLENAME=ML
# MLflow listen host (bind address inside container)
MLFLOW_BIND_HOST=0.0.0.0
# Kubernetes training (external controller pattern)
# Set TRAIN_USE_KUBERNETES=true to dispatch training jobs as K8s Jobs instead of local threads
TRAIN_USE_KUBE=false
TRAIN_KUBE_HOST=https://your-cluster-api-server:6443
TRAIN_KUBE_TOKEN=<ServiceAccount token>
TRAIN_KUBE_CA_CERT=<base64-encoded PEM certificate>
TRAIN_KUBE_NAMESPACE=default
TRAIN_KUBE_IMAGE=cnt00/pei-ml-train-worker:latest
# Encryption (DH key exchange + AES-256-GCM)
# Set to true to perform a handshake with data-storage and decrypt responses
# Works both with and without Kubernetes — ENCRYPTION_ENABLED is forwarded to K8s job pods automatically
ENCRYPTION_ENABLED=false
# DLT traceability (blockchain audit trail for data fetches and inference)
DLT_ENABLED=false
DLT_SIDECAR_URL=http://localhost:9337
DLT_TIMEOUT=10.0
# Auth
DEV_MODE=false
KEYCLOAK_URL=http://keycloak:8080/auth
KEYCLOAK_REALM=aion
KEYCLOAK_CLIENT_ID=aion-services
ML_SERVICE_KC_USER=ml-service
ML_SERVICE_KC_PASSWORD=ml-service # change in production