wip:milestone 0 fixes
Some checks failed
CI/CD Pipeline / unit-tests (push) Failing after 1m16s
CI/CD Pipeline / integration-tests (push) Failing after 2m32s
CI/CD Pipeline / lint (push) Successful in 5m22s
CI/CD Pipeline / e2e-tests (push) Has been skipped
CI/CD Pipeline / build (push) Has been skipped

This commit is contained in:
2026-03-15 12:35:42 +02:00
parent 6708cf28a7
commit cffdf8af86
61266 changed files with 4511646 additions and 1938 deletions

17
env/autobase.4server.server1.env vendored Normal file
View File

@@ -0,0 +1,17 @@
# Server 1 (CX11) - Control Plane Only
# No Autobase, No Workers
# Private IP: 10.0.0.1
# Application
PROXY_PORT=8000
CONTROL_PORT=8001
# Proxy - Routes to workers on other servers
CONTROL_UPSTREAM_URL=http://10.0.0.1:8001
WORKER_UPSTREAM_URLS=http://10.0.0.2:8002,http://10.0.0.3:8002,http://10.0.0.3:8003,http://10.0.0.4:8002
# Control Plane - Connects to any Autobase node's HAProxy
DATABASE_URL=postgresql://postgres:password@10.0.0.2:5433/madbase_control
# Grafana
GF_SERVER_HTTP_PORT=3000

22
env/autobase.4server.server2.env vendored Normal file
View File

@@ -0,0 +1,22 @@
# Server 2 (CX11) - Worker 1 + Autobase Node 1
# Private IP: 10.0.0.2
# Worker 1
WORKER_PORT=8002
WORKER_ID=worker1
# Worker - Connects to local HAProxy
DATABASE_URL=postgresql://postgres:password@localhost:5433/postgres
# Autobase Node 1
ETCD_NAME=etcd1
PRIVATE_IP=10.0.0.2
ETCD_INITIAL_CLUSTER=etcd1=http://10.0.0.2:2380,etcd2=http://10.0.0.3:2380,etcd3=http://10.0.0.4:2380
PATRONI_NAME=patroni1
ETCD_HOSTS=10.0.0.2:2379,10.0.0.3:2379,10.0.0.4:2379
POSTGRES_PASSWORD=password
# HAProxy
PRIVATE_IP_1=10.0.0.2
PRIVATE_IP_2=10.0.0.3
PRIVATE_IP_3=10.0.0.4

29
env/autobase.4server.server3.env vendored Normal file
View File

@@ -0,0 +1,29 @@
# Server 3 (CX21 - 4GB RAM) - Worker 3, Worker 4 + Autobase Node 2
# Private IP: 10.0.0.3
# Worker 3
WORKER_PORT=8002
WORKER_ID=worker3
DATABASE_URL=postgresql://postgres:password@localhost:5433/postgres
# Worker 4
WORKER_4_PORT=8003
WORKER_4_ID=worker4
WORKER_4_DATABASE_URL=postgresql://postgres:password@localhost:5433/postgres
# Autobase Node 2
ETCD_NAME=etcd2
PRIVATE_IP=10.0.0.3
ETCD_INITIAL_CLUSTER=etcd1=http://10.0.0.2:2380,etcd2=http://10.0.0.3:2380,etcd3=http://10.0.0.4:2380
PATRONI_NAME=patroni2
ETCD_HOSTS=10.0.0.2:2379,10.0.0.3:2379,10.0.0.4:2379
POSTGRES_PASSWORD=password
# HAProxy
PRIVATE_IP_1=10.0.0.2
PRIVATE_IP_2=10.0.0.3
PRIVATE_IP_3=10.0.0.4
# Metrics
VICTORIA_METRICS_PORT=8428
LOKI_PORT=3100

20
env/autobase.4server.server4.env vendored Normal file
View File

@@ -0,0 +1,20 @@
# Server 4 (CX11) - Worker 5 + Autobase Node 3
# Private IP: 10.0.0.4
# Worker 5
WORKER_PORT=8002
WORKER_ID=worker5
DATABASE_URL=postgresql://postgres:password@localhost:5433/postgres
# Autobase Node 3
ETCD_NAME=etcd3
PRIVATE_IP=10.0.0.4
ETCD_INITIAL_CLUSTER=etcd1=http://10.0.0.2:2380,etcd2=http://10.0.0.3:2380,etcd3=http://10.0.0.4:2380
PATRONI_NAME=patroni3
ETCD_HOSTS=10.0.0.2:2379,10.0.0.3:2379,10.0.0.4:2379
POSTGRES_PASSWORD=password
# HAProxy
PRIVATE_IP_1=10.0.0.2
PRIVATE_IP_2=10.0.0.3
PRIVATE_IP_3=10.0.0.4

10
env/autobase.server1.env vendored Normal file
View File

@@ -0,0 +1,10 @@
# Server 1 (Proxy + Control + Autobase Node 1)
ETCD_NAME=etcd1
PRIVATE_IP=10.0.0.1
ETCD_INITIAL_CLUSTER=etcd1=http://10.0.0.1:2380,etcd2=http://10.0.0.2:2380,etcd3=http://10.0.0.3:2380
PATRONI_NAME=patroni1
ETCD_HOSTS=10.0.0.1:2379,10.0.0.2:2379,10.0.0.3:2379
POSTGRES_PASSWORD=password
PRIVATE_IP_1=10.0.0.1
PRIVATE_IP_2=10.0.0.2
PRIVATE_IP_3=10.0.0.3

10
env/autobase.server2.env vendored Normal file
View File

@@ -0,0 +1,10 @@
# Server 2 (Metrics + Autobase Node 2)
ETCD_NAME=etcd2
PRIVATE_IP=10.0.0.2
ETCD_INITIAL_CLUSTER=etcd1=http://10.0.0.1:2380,etcd2=http://10.0.0.2:2380,etcd3=http://10.0.0.3:2380
PATRONI_NAME=patroni2
ETCD_HOSTS=10.0.0.1:2379,10.0.0.2:2379,10.0.0.3:2379
POSTGRES_PASSWORD=password
PRIVATE_IP_1=10.0.0.1
PRIVATE_IP_2=10.0.0.2
PRIVATE_IP_3=10.0.0.3

10
env/autobase.server3.env vendored Normal file
View File

@@ -0,0 +1,10 @@
# Server 3 (Workers + Autobase Node 3)
ETCD_NAME=etcd3
PRIVATE_IP=10.0.0.3
ETCD_INITIAL_CLUSTER=etcd1=http://10.0.0.1:2380,etcd2=http://10.0.0.2:2380,etcd3=http://10.0.0.3:2380
PATRONI_NAME=patroni3
ETCD_HOSTS=10.0.0.1:2379,10.0.0.2:2379,10.0.0.3:2379
POSTGRES_PASSWORD=password
PRIVATE_IP_1=10.0.0.1
PRIVATE_IP_2=10.0.0.2
PRIVATE_IP_3=10.0.0.3

8
env/storage.env.example vendored Normal file
View File

@@ -0,0 +1,8 @@
# Hetzner Bucket Storage Configuration
# Get credentials from: https://console.hetzner.cloud/storage
S3_ENDPOINT=https://fsn1.your-objectstorage.com
S3_ACCESS_KEY=your_access_key_here
S3_SECRET_KEY=your_secret_key_here
S3_BUCKET=madbase-production
S3_REGION=us-east-1

27
env/storage.hetzner.example vendored Normal file
View File

@@ -0,0 +1,27 @@
# Storage Configuration - Hetzner Bucket Storage
# This configuration uses Hetzner's S3-compatible Bucket Storage
# Cost: €6.00/month for 1TB (70-75% cheaper than MinIO on VPS)
# Storage Backend Selection
# Options: s3 (Hetzner Bucket Storage), minio (Self-hosted MinIO)
STORAGE_BACKEND=s3
# Hetzner Bucket Storage Credentials
# Get these from your Hetzner Cloud Console -> Object Storage
S3_ENDPOINT=https://fsn1.your-objectstorage.com
S3_ACCESS_KEY=your_hetzner_access_key_here
S3_SECRET_KEY=your_hetzner_secret_key_here
S3_BUCKET=madbase-production
S3_REGION=us-east-1
# Alternative regions (choose closest to your servers):
# FSN1 (Falkenstein, Germany): https://fsn1.your-objectstorage.com
# NBG1 (Nuremberg, Germany): https://nbg1.your-objectstorage.com
# HEL1 (Helsinki, Finland): https://hel1.your-objectstorage.com
# Notes:
# - No need to run MinIO container
# - No storage limits on VPS
# - Automatic scalability
# - 99.9% availability SLA
# - Pre-signed URL support for direct uploads

21
env/storage.minio.example vendored Normal file
View File

@@ -0,0 +1,21 @@
# Storage Configuration - MinIO (Self-hosted)
# Use this for local development or if you want full control over storage
# Storage Backend Selection
# Options: s3 (Hetzner Bucket Storage), minio (Self-hosted MinIO)
STORAGE_BACKEND=minio
# MinIO Credentials
# These are the default MinIO credentials (change in production!)
S3_ENDPOINT=http://localhost:9000
MINIO_ROOT_USER=minioadmin
MINIO_ROOT_PASSWORD=minioadmin
S3_BUCKET=madbase-development
S3_REGION=us-east-1
# Notes:
# - Requires MinIO container running
# - Use docker-compose.yml with MinIO service
# - Higher cost (additional VPS storage or block storage)
# - Full control but maintenance overhead
# - Good for air-gapped environments