Default to localhost for workstation install
- ConnectionPanel defaults host to localhost, blank username - Backend OLLAMA_URL defaults to localhost:11434 - Systemd service reads /etc/llm-trainer/env for overrides Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -88,6 +88,7 @@ Restart=always
|
||||
RestartSec=5
|
||||
StandardOutput=append:/var/log/llm-trainer/backend.log
|
||||
StandardError=append:/var/log/llm-trainer/backend.log
|
||||
EnvironmentFile=-/etc/llm-trainer/env
|
||||
Environment=PYTHONUNBUFFERED=1
|
||||
|
||||
[Install]
|
||||
@@ -137,6 +138,15 @@ fi
|
||||
chown -R llm-trainer:llm-trainer /opt/llm-trainer
|
||||
chown -R llm-trainer:llm-trainer /var/log/llm-trainer
|
||||
|
||||
# Write default env config (only on first install)
|
||||
if [ ! -f /etc/llm-trainer/env ]; then
|
||||
cat > /etc/llm-trainer/env <<'ENV'
|
||||
# LLM Trainer configuration
|
||||
# Override Ollama URL if it runs on a different host
|
||||
OLLAMA_URL=http://localhost:11434
|
||||
ENV
|
||||
fi
|
||||
|
||||
# Build Python venv and install deps
|
||||
echo "Installing Python dependencies..."
|
||||
python3 -m venv /opt/llm-trainer/venv
|
||||
|
||||
Reference in New Issue
Block a user