# Cloud-Plattformen

SteelEngine auf Cloud-Plattformen bereitstellen

## Railway

Bereitstellung mit einem Klick und automatischer PostgreSQL-Bereitstellung.

\[

![Auf Railway bereitstellen](https://railway.app/button.svg)

]\([https://railway.com/new/template/steelengine](https://railway.com/new/template/steelengine))

Nach der Bereitstellung fügen Sie Umgebungsvariablen im Railway-Dashboard hinzu:

* `BETTER_AUTH_SECRET`, `ENCRYPTION_KEY`, `INTERNAL_API_SECRET` (automatisch generiert)
* `OPENAI_API_KEY` oder andere KI-Anbieter-Schlüssel
* Benutzerdefinierte Domain in Einstellungen → Netzwerk

## VPS-Bereitstellung

Für DigitalOcean, AWS EC2, Azure VMs oder jeden Linux-Server:

**DigitalOcean**

**Empfohlen:** 16 GB RAM Droplet, Ubuntu 24.04

```bash
# Create Droplet via console, then SSH in
ssh root@your-droplet-ip
```

**AWS EC2**

**Empfohlen:** t3.xlarge (16 GB RAM), Ubuntu 24.04

```bash
ssh -i your-key.pem ubuntu@your-ec2-ip
```

**Azure VM**

**Empfohlen:** Standard\_D4s\_v3 (16 GB RAM), Ubuntu 24.04

```bash
ssh azureuser@your-vm-ip
```

### Docker installieren

```bash
# Install Docker (official method)
curl -fsSL https://get.docker.com | sudo sh
sudo usermod -aG docker $USER

# Logout and reconnect, then verify
docker --version
```

### SteelEngine bereitstellen

```bash
git clone https://github.com/steelengineai/steelengine.git && cd steelengine

# Create .env with secrets
cat > .env << EOF
DATABASE_URL=postgresql://postgres:postgres@db:5432/steelengine
BETTER_AUTH_SECRET=$(openssl rand -hex 32)
ENCRYPTION_KEY=$(openssl rand -hex 32)
INTERNAL_API_SECRET=$(openssl rand -hex 32)
NEXT_PUBLIC_APP_URL=https://steelengine.yourdomain.com
BETTER_AUTH_URL=https://steelengine.yourdomain.com
NEXT_PUBLIC_SOCKET_URL=https://steelengine.yourdomain.com
EOF

# Start
docker compose -f docker-compose.prod.yml up -d
```

### SSL mit Caddy

```bash
# Install Caddy
sudo apt install -y debian-keyring debian-archive-keyring apt-transport-https curl
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/gpg.key' | sudo gpg --dearmor -o /usr/share/keyrings/caddy-stable-archive-keyring.gpg
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/debian.deb.txt' | sudo tee /etc/apt/sources.list.d/caddy-stable.list
sudo apt update && sudo apt install caddy

# Configure (replace domain)
echo 'steelengine.yourdomain.com {
    reverse_proxy localhost:3000
    handle /socket.io/* {
        reverse_proxy localhost:3002
    }
}' | sudo tee /etc/caddy/Caddyfile

sudo systemctl restart caddy
```

Richten Sie den DNS A-Eintrag Ihrer Domain auf die IP-Adresse Ihres Servers.

## Kubernetes (EKS, AKS, GKE)

Siehe den [Kubernetes-Leitfaden](/self-hosting/kubernetes) für Helm-Deployment auf verwaltetem Kubernetes.

## Verwaltete Datenbank (Optional)

Für den Produktivbetrieb sollten Sie einen verwalteten PostgreSQL-Dienst verwenden:

* **AWS RDS** / **Azure Database** / **Cloud SQL** - Aktivieren Sie die pgvector-Erweiterung
* **Supabase** / **Neon** - pgvector enthalten

Setzen Sie `DATABASE_URL` in Ihrer Umgebung:

```bash
DATABASE_URL="postgresql://user:pass@host:5432/db?sslmode=require"
```
