# Deployment Mimarisi - FikoYT

## 🚀 Build Process

**Angular:**
```bash
ng build --configuration production
# Output: dist/
```

**Go:**
```bash
go build -o server
# Static binary
```

**Flutter:**
```bash
flutter build apk        # Android
flutter build windows    # Windows
flutter build web        # Web
```

## 🐳 Docker Build

**Multi-stage:**
```dockerfile
# Stage 1: Build
FROM golang:1.23 AS builder
WORKDIR /app
COPY . .
RUN go build -o server

# Stage 2: Runtime
FROM golang:1.23-slim
WORKDIR /app
COPY --from=builder /app/server .
EXPOSE 9000
CMD ["./server"]
```

## 📦 Deployment

**Docker Compose:**
```yaml
services:
  fikoyt-sunucu:
    build: .
    ports:
      - "9000:9000"
    environment:
      - NODE_ENV=production
    restart: unless-stopped
```

## 🔧 Production

**Ports:**
- **4200** → Nginx proxy
- **9000** → Go API
- **8090** → Python API
- **27017** → MongoDB (internal)

**SSL:** Let's Encrypt
**CDN:** CloudFlare
**Monitoring:** Logs + metrics

---
2025-11-06