feat: self-hosted LLM backend — point all workflows at the Jetson (Ollama, model=coder)

The Jetson Orin Nano (JetPack 7.2, Ollama on GPU) is live, so ci-ai runs fully
self-hosted: no Anthropic key, no cloud, no per-PR cost. AI_PROVIDER=ollama,
AI_BASE_URL=http://192.168.178.103:11434/v1. The Pi runner reaches it LAN-direct
(SNAT to .48, allowed by the Jetson UFW). Removed the dead ANTHROPIC_API_KEY
secret declarations.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-06-12 21:58:07 +02:00
parent eb0437b0ed
commit 2ae14a51e4
7 changed files with 26 additions and 40 deletions

View File

@@ -7,14 +7,11 @@
# secrets: inherit
#
# Voraussetzungen: globaler Runner `eulernest`, anon-Clone für public Repos.
# Ohne ANTHROPIC_API_KEY überspringt das Skript den KI-Schritt sauber (Job grün).
# KI-Backend = Jetson-Ollama (self-hosted, LAN-direkt). Kein Secret nötig.
name: ci-ai · review (reusable)
on:
workflow_call:
secrets:
ANTHROPIC_API_KEY:
required: false
workflow_call: {}
jobs:
review:
@@ -31,9 +28,9 @@ jobs:
- name: KI-Review (überspringt sauber ohne Key)
env:
AI_PROVIDER: anthropic
AI_MODEL: claude-3-5-haiku-latest
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
AI_PROVIDER: ollama
AI_MODEL: coder
AI_BASE_URL: http://192.168.178.103:11434/v1
GITEA_TOKEN: ${{ github.token }}
GITEA_API: https://git.eulernest.eu/api/v1
run: python /opt/ci-ai/scripts/ai_review.py

View File

@@ -11,10 +11,7 @@
name: ci-ai · commands (reusable)
on:
workflow_call:
secrets:
ANTHROPIC_API_KEY:
required: false
workflow_call: {}
jobs:
command:
@@ -23,9 +20,9 @@ jobs:
image: python:3.12-slim
options: "--memory=512m --memory-swap=768m"
env:
AI_PROVIDER: anthropic
AI_MODEL: claude-3-5-haiku-latest
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
AI_PROVIDER: ollama
AI_MODEL: coder
AI_BASE_URL: http://192.168.178.103:11434/v1
GITEA_TOKEN: ${{ github.token }}
GITEA_API: https://git.eulernest.eu/api/v1
steps:

View File

@@ -8,17 +8,14 @@
# Voraussetzungen (einmalig zentral):
# - Runner instanzweit registriert (Label `eulernest`)
# - anonymer Clone für public Repos erlaubt (für den ci-ai-Clone)
# - optional ANTHROPIC_API_KEY als Org-/Instanz-Secret (für die KI-Erklärung)
# - KI-Backend = Jetson-Ollama (self-hosted, LAN); kein Secret nötig
#
# python:3.12-slim (Debian: bash) + Memory-Cap (Pi). ⚠ ARM64-Binaries.
# Gitleaks (Secrets) + Trivy config (IaC) — hart blockierend über den Gate-Schritt.
name: ci-ai · security (reusable)
on:
workflow_call:
secrets:
ANTHROPIC_API_KEY:
required: false
workflow_call: {}
env:
GITLEAKS_VERSION: "8.18.4"
@@ -74,9 +71,9 @@ jobs:
if: failure()
continue-on-error: true
env:
AI_PROVIDER: anthropic
AI_MODEL: claude-3-5-haiku-latest
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
AI_PROVIDER: ollama
AI_MODEL: coder
AI_BASE_URL: http://192.168.178.103:11434/v1
GITEA_TOKEN: ${{ github.token }}
GITEA_API: https://git.eulernest.eu/api/v1
run: |