Add complete homelab documentation and configurations

Documentation:
- OpenCode + LiteLLM integration guide
- LiteLLM complete setup with 16 models
- Gitea centralized configuration guide
- Testing procedures and verification
- API keys setup instructions

Configurations:
- OpenCode config pointing to LiteLLM
- Updated LiteLLM config with all models
- Nextcloud docker-compose template

Scripts:
- Gitea setup automation
- OpenCode testing script

Infrastructure:
- Gitea: 192.168.88.200:3000
- LiteLLM: 192.168.88.27:4000
- Nextcloud: 192.168.88.62
This commit is contained in:
2026-04-25 10:56:21 -05:00
parent eba13efd34
commit 290aedf82d
36 changed files with 8074 additions and 6 deletions
+87
View File
@@ -0,0 +1,87 @@
# Nextcloud VM (192.168.88.62) - Updated docker-compose.yml
#
# This configuration pulls OpenCode config from centralized Gitea repository
# instead of managing per-VM configuration files
#
# Updated for centralized config management via http://192.168.88.200:3000
version: '3.8'
services:
# Keep existing Nextcloud service if present
# nextcloud:
# image: nextcloud:latest
# ... (existing config)
opencode:
image: opencode:latest
container_name: opencode
# Volumes for persistent configuration and workspace
volumes:
- opencode-config:/root/.opencode
- opencode-workspace:/workspace
# Expose port (adjust if needed)
ports:
- "8000:8000"
# Environment variables
environment:
HOME: /root
# LiteLLM Gateway endpoint is in the config.json file
# pulled from Gitea
# The key: pull config from Gitea at startup
entrypoint: /bin/sh
command: |
-c "
echo '🔄 Fetching configuration from Gitea...'
mkdir -p /tmp/homelab-configs
# Clone the central configs repo
if git clone http://192.168.88.200:3000/jgitta/homelab-configs.git /tmp/homelab-configs; then
echo '✅ Configuration fetched successfully'
else
echo '⚠️ Could not fetch configs from Gitea, using defaults'
fi
# Set up OpenCode config directory
mkdir -p /root/.opencode
# Copy OpenCode config if available
if [ -f /tmp/homelab-configs/opencode/config.json ]; then
cp /tmp/homelab-configs/opencode/config.json /root/.opencode/config.json
echo '✅ OpenCode config loaded from Gitea'
else
echo '⚠️ Using default OpenCode configuration'
fi
# Start OpenCode
echo '🚀 Starting OpenCode...'
exec opencode
"
# Restart policy
restart: unless-stopped
# Resource limits (adjust as needed)
# deploy:
# resources:
# limits:
# cpus: '2'
# memory: 2G
# reservations:
# cpus: '1'
# memory: 1G
volumes:
opencode-config:
driver: local
opencode-workspace:
driver: local
networks:
default:
driver: bridge