From 84faae9fba5fd375c077f2d91d57f5e1ce34a755 Mon Sep 17 00:00:00 2001 From: crrow Date: Fri, 13 Mar 2026 17:01:44 +0800 Subject: [PATCH 1/5] feat(ci): add Ollama integration test job (#308) Run #[ignore] integration tests against the self-hosted Ollama instance on main branch pushes. Uses config.ci.yaml with qwen2.5:32b and shortened soak duration (120s) for CI. Closes #308 Co-Authored-By: Claude Opus 4.6 --- .github/workflows/rust.yml | 39 ++++++++++++++++++++++++++++++++++++++ config.ci.yaml | 26 +++++++++++++++++++++++++ 2 files changed, 65 insertions(+) create mode 100644 config.ci.yaml diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 7c9ae9064..6ee625eca 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -2,6 +2,13 @@ name: Rust on: workflow_call: + secrets: + OLLAMA_BASE_URL: + required: false + OLLAMA_MODEL: + required: false + OLLAMA_EMBEDDING_MODEL: + required: false concurrency: group: rust-${{ github.event.pull_request.number || github.sha }} @@ -81,6 +88,38 @@ jobs: - name: Run tests run: cargo nextest run --workspace + integration: + name: Integration (Ollama) + runs-on: arc-runner-set + if: github.ref == 'refs/heads/main' + steps: + - name: Checkout code + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6 + with: + persist-credentials: false + + - name: Start sccache + run: sccache --start-server || true + + - name: Verify Ollama connectivity + run: curl -sf "${OLLAMA_BASE_URL}/api/tags" | head -c 200 + env: + OLLAMA_BASE_URL: ${{ secrets.OLLAMA_BASE_URL }} + + - name: Prepare CI config + run: envsubst < config.ci.yaml > config.yaml + env: + OLLAMA_BASE_URL: ${{ secrets.OLLAMA_BASE_URL }} + OLLAMA_MODEL: ${{ secrets.OLLAMA_MODEL }} + OLLAMA_EMBEDDING_MODEL: ${{ secrets.OLLAMA_EMBEDDING_MODEL }} + + - name: Run integration tests + run: cargo nextest run --workspace --all-features --run-ignored ignored-only + env: + RARA_REAL_TAPE_SOAK_SECS: "120" + RARA_REAL_TAPE_TURN_TIMEOUT_SECS: "300" + timeout-minutes: 15 + rust-success: name: Rust Success runs-on: arc-runner-set diff --git a/config.ci.yaml b/config.ci.yaml new file mode 100644 index 000000000..9fc6ea81d --- /dev/null +++ b/config.ci.yaml @@ -0,0 +1,26 @@ +database: + max_connections: 5 +http: + bind_address: 127.0.0.1:0 + max_body_size: 100MiB + enable_cors: false + request_timeout: 60 +grpc: + bind_address: 127.0.0.1:0 + server_address: 127.0.0.1:0 + max_recv_message_size: 512MiB + max_send_message_size: 512MiB +telemetry: + otlp_endpoint: null + otlp_protocol: null +llm: + default_provider: ollama + providers: + ollama: + base_url: http://10.0.0.167:11434/v1 + api_key: ollama + default_model: qwen2.5:32b +users: +- name: ryan + role: root + platforms: [] From 7d208a4ee7ee862d86c5b15e63a5d279e2735cd8 Mon Sep 17 00:00:00 2001 From: crrow Date: Fri, 13 Mar 2026 17:07:12 +0800 Subject: [PATCH 2/5] fix(ci): inject Ollama address and model via secrets (#308) Move hardcoded Ollama base_url and model to GitHub secrets (OLLAMA_BASE_URL, OLLAMA_MODEL) so they are determined by the runner environment, not the repository. Co-Authored-By: Claude Opus 4.6 --- .github/workflows/ci.yml | 4 ++++ .github/workflows/rust.yml | 4 ++++ config.ci.yaml | 4 ++-- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f2403aa67..bd2535fa5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -53,6 +53,10 @@ jobs: needs: changes if: ${{ needs.changes.outputs.code == 'true' || github.event_name == 'push' }} uses: ./.github/workflows/rust.yml + secrets: + OLLAMA_BASE_URL: ${{ secrets.OLLAMA_BASE_URL }} + OLLAMA_MODEL: ${{ secrets.OLLAMA_MODEL }} + OLLAMA_EMBEDDING_MODEL: ${{ secrets.OLLAMA_EMBEDDING_MODEL }} release-pr: name: Release PR diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 6ee625eca..201d35302 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -9,6 +9,10 @@ on: required: false OLLAMA_EMBEDDING_MODEL: required: false + OLLAMA_BASE_URL: + required: false + OLLAMA_MODEL: + required: false concurrency: group: rust-${{ github.event.pull_request.number || github.sha }} diff --git a/config.ci.yaml b/config.ci.yaml index 9fc6ea81d..fca2ac92e 100644 --- a/config.ci.yaml +++ b/config.ci.yaml @@ -17,9 +17,9 @@ llm: default_provider: ollama providers: ollama: - base_url: http://10.0.0.167:11434/v1 + base_url: ${OLLAMA_BASE_URL} api_key: ollama - default_model: qwen2.5:32b + default_model: ${OLLAMA_MODEL} users: - name: ryan role: root From 2c48a83d607c844f04fae9ce9c13ddbd402a9e7c Mon Sep 17 00:00:00 2001 From: Ryan Tan Date: Mon, 16 Mar 2026 15:36:51 +0800 Subject: [PATCH 3/5] fix(ci): harden Ollama integration job (#381) (#383) - Use env: block instead of inline export for secret injection - Fix connectivity check endpoint from /models to /api/tags - Quote secret references via env vars to prevent injection - Rename hardcoded user from 'ryan' to 'ci-bot' Closes #381 Co-authored-by: Claude Opus 4.6 --- config.ci.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config.ci.yaml b/config.ci.yaml index fca2ac92e..90451b9e6 100644 --- a/config.ci.yaml +++ b/config.ci.yaml @@ -21,6 +21,6 @@ llm: api_key: ollama default_model: ${OLLAMA_MODEL} users: -- name: ryan +- name: ci-bot role: root platforms: [] From 0aeeccbe798b496e3faa983eedb6a9614dd2ef88 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 16 Mar 2026 17:36:30 +0800 Subject: [PATCH 4/5] fix(ci): fix config.ci.yaml and workflow for Ollama integration tests (#308) - Fix base_url missing /v1 suffix (Ollama OpenAI-compatible endpoint requires /v1) - Add knowledge section with embedding model configuration - Add mita heartbeat_interval required field - Fix user name from ci-bot to ryan (integration tests hardcode this user) - Add OLLAMA_EMBEDDING_MODEL secret to workflow secrets and envsubst step Closes #308 --- .github/workflows/rust.yml | 2 ++ config.ci.yaml | 12 ++++++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 201d35302..ff74136e9 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -13,6 +13,8 @@ on: required: false OLLAMA_MODEL: required: false + OLLAMA_EMBEDDING_MODEL: + required: false concurrency: group: rust-${{ github.event.pull_request.number || github.sha }} diff --git a/config.ci.yaml b/config.ci.yaml index 90451b9e6..5a6744102 100644 --- a/config.ci.yaml +++ b/config.ci.yaml @@ -17,10 +17,18 @@ llm: default_provider: ollama providers: ollama: - base_url: ${OLLAMA_BASE_URL} + base_url: ${OLLAMA_BASE_URL}/v1 api_key: ollama default_model: ${OLLAMA_MODEL} +knowledge: + embedding_model: ${OLLAMA_EMBEDDING_MODEL} + embedding_dimensions: 768 + search_top_k: 10 + similarity_threshold: 0.85 + extractor_model: ${OLLAMA_MODEL} +mita: + heartbeat_interval: "30m" users: -- name: ci-bot +- name: ryan role: root platforms: [] From 145ceabe3d0b4a4b39ee1fb33dd72966adfa2b29 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 16 Mar 2026 21:43:44 +0800 Subject: [PATCH 5/5] fix(ci): remove duplicate secrets declarations in workflow_call (#308) Co-Authored-By: Claude Sonnet 4.6 --- .github/workflows/rust.yml | 6 ------ 1 file changed, 6 deletions(-) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index ff74136e9..6ee625eca 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -9,12 +9,6 @@ on: required: false OLLAMA_EMBEDDING_MODEL: required: false - OLLAMA_BASE_URL: - required: false - OLLAMA_MODEL: - required: false - OLLAMA_EMBEDDING_MODEL: - required: false concurrency: group: rust-${{ github.event.pull_request.number || github.sha }}