← octto
name: End-to-end
on:
pull_request:
workflow_dispatch:
inputs:
live_model:
description: "Model for the live tier"
required: false
default: "opencode/deepseek-v4-flash-free"
type: string
jobs:
scripted:
# The scripted tier is deterministic and free, so it runs on every PR.
if: github.event_name == 'pull_request'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- name: Build harness
run: docker build -f e2e/Dockerfile -t octto-e2e .
- name: Run scripted tier
run: docker run --rm octto-e2e
live:
# Costs money and needs a real model, so it is manual only and skips
# without a key rather than failing.
if: github.event_name == 'workflow_dispatch' && inputs.live_model != ''
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- name: Build harness
run: docker build -f e2e/Dockerfile -t octto-e2e .
# OPENCODE_AUTH_JSON is the contents of ~/.local/share/opencode/auth.json.
# The default model is free, so this costs nothing to run.
- name: Run live tier
env:
OPENCODE_AUTH_JSON: ${{ secrets.OPENCODE_AUTH_JSON }}
LIVE_MODEL: ${{ inputs.live_model }}
run: |
if [ -z "${OPENCODE_AUTH_JSON}" ]; then
echo "No OPENCODE_AUTH_JSON secret configured; skipping live tier."
exit 0
fi
printf '%s' "${OPENCODE_AUTH_JSON}" > "${RUNNER_TEMP}/auth.json"
docker run --rm \
-v "${RUNNER_TEMP}/auth.json:/auth.json:ro" \
-e OCTTO_E2E_AUTH_FILE=/auth.json \
-e OCTTO_E2E_LIVE_MODEL="${LIVE_MODEL}" \
octto-e2e