Files
wehub-resource-sync e0e362d700
SDK Tests / changes (push) Successful in 2m29s
Real E2E Tests / changes (push) Successful in 2m29s
Deploy Docs Pages / build (push) Has been cancelled
Deploy Docs Pages / deploy (push) Has been cancelled
Real E2E Tests / JavaScript E2E (docker bridge) (push) Has been cancelled
Real E2E Tests / Python E2E (docker bridge) (push) Has been cancelled
Real E2E Tests / Java E2E (docker bridge) (push) Has been cancelled
Real E2E Tests / C# E2E (docker bridge) (push) Has been cancelled
Real E2E Tests / Go E2E (docker bridge) (push) Has been cancelled
Real E2E Tests / Real E2E CI (push) Has been cancelled
SDK Tests / SDK CI (push) Has been cancelled
SDK Tests / CLI Tests (push) Has been cancelled
SDK Tests / Python SDK Quality (code-interpreter) (push) Has been cancelled
SDK Tests / Python SDK Quality (sandbox) (push) Has been cancelled
SDK Tests / Python SDK Tests (code-interpreter) (push) Has been cancelled
SDK Tests / JavaScript SDK Quality And Tests (code-interpreter) (push) Has been cancelled
SDK Tests / JavaScript SDK Quality And Tests (sandbox) (push) Has been cancelled
SDK Tests / Python SDK Tests (sandbox) (push) Has been cancelled
SDK Tests / CLI Quality (push) Has been cancelled
SDK Tests / Kotlin SDK Quality And Tests (sandbox) (push) Has been cancelled
SDK Tests / Kotlin SDK Quality And Tests (code-interpreter) (push) Has been cancelled
SDK Tests / C# SDK Quality And Tests (code-interpreter) (push) Has been cancelled
SDK Tests / C# SDK Quality And Tests (sandbox) (push) Has been cancelled
SDK Tests / Go SDK Quality And Tests (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 13:39:33 +08:00

1.3 KiB

Development Guide (Quick)

Prerequisites

  • Go 1.24+
  • Docker (optional, for image build)
  • Access to a Kubernetes cluster with BatchSandbox CRD installed.

Install deps

cd components/ingress
go mod tidy && go mod vendor

Build & Run

make build          # binary at bin/ingress with ldflags version info
./bin/ingress \
  --namespace <target-namespace> \
  --port 28888 \
  --log-level info

Tests & Lint

make test           # go test ./...
go vet ./...        # included in make build

Docker (with build args)

docker build \
  --build-arg VERSION=$(git describe --tags --always --dirty) \
  --build-arg GIT_COMMIT=$(git rev-parse HEAD) \
  --build-arg BUILD_TIME=$(date -u +"%Y-%m-%dT%H:%M:%SZ") \
  -t opensandbox/ingress:dev .

Key Paths

  • main.go — entrypoint, HTTP routes, provider initialization.
  • pkg/proxy/ — HTTP/WebSocket reverse proxy logic.
  • pkg/sandbox/ — Sandbox provider abstraction and BatchSandbox implementation.
  • version/ — build metadata (ldflags).

Tips

  • Health check: /status.ok
  • Proxy endpoint: / (routes based on OpenSandbox-Ingress-To header or Host)
  • Env overrides: VERSION/GIT_COMMIT/BUILD_TIME usable via Makefile and build.sh.
  • BatchSandbox must have sandbox.opensandbox.io/endpoints annotation with JSON array of IPs.