Skip to content

Commit d72a7f0

Browse files
committed
symbiont: use system git for private fork fetch on Railway
Railway servers have access to all private AdaWorldAPI repositories by design, so no token wiring is needed. Set CARGO_NET_GIT_FETCH_WITH_CLI=true so cargo fetches the git-dep forks through the system git (which honors Railway's ambient credentials) rather than its built-in libgit2 transport. Drops the obsolete token-injection note. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CcpLeEC3XK8Eye53GKBVvi
1 parent 8201314 commit d72a7f0

2 files changed

Lines changed: 12 additions & 7 deletions

File tree

crates/symbiont/Dockerfile

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,19 @@
1313
# On Railway: set the service's Dockerfile path to `crates/symbiont/Dockerfile`
1414
# and the root directory to the repo root.
1515
#
16-
# AUTH: the AdaWorldAPI forks must be reachable during the build. If they are
17-
# private, provide a token — e.g. mount a git credential or pass a build secret
18-
# and configure `git config --global url."https://x-access-token:$TOKEN@github.com/".insteadOf "https://github.com/"`.
16+
# AUTH: a Railway server has access to all private AdaWorldAPI repositories by
17+
# design, so no token wiring is needed. The build only has to make cargo use
18+
# the SYSTEM git (which honors Railway's ambient credentials) rather than its
19+
# built-in libgit2 transport — done via CARGO_NET_GIT_FETCH_WITH_CLI=true below.
1920

2021
ARG ADA_BRANCH=claude/jirak-math-theorems-harvest-rfii13
2122

2223
# ── builder ──────────────────────────────────────────────────────────────────
2324
FROM rust:1.95-bookworm AS builder
2425
ARG ADA_BRANCH
26+
# Make cargo fetch git deps via the system `git` CLI so it uses Railway's
27+
# ambient credentials for the private AdaWorldAPI forks.
28+
ENV CARGO_NET_GIT_FETCH_WITH_CLI=true
2529
# Native build deps for the closure: aws-lc-sys (C++), zstd/lz4 (C), protoc.
2630
RUN apt-get update && apt-get install -y --no-install-recommends \
2731
cmake clang protobuf-compiler pkg-config libssl-dev git ca-certificates \

crates/symbiont/README.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,11 @@ docker run --rm symbiont
4040
2. Set the Dockerfile path to `crates/symbiont/Dockerfile`.
4141
3. The build proves the stack links; a green build is the deliverable.
4242

43-
**Auth:** the build fetches the AdaWorldAPI forks. If they're private, provide
44-
a token to the build (e.g. `git config --global
45-
url."https://x-access-token:$TOKEN@github.com/".insteadOf
46-
"https://github.com/"` via a Railway build secret).
43+
**Auth:** a Railway server has access to all private AdaWorldAPI repositories
44+
by design — no token wiring needed. The Dockerfile sets
45+
`CARGO_NET_GIT_FETCH_WITH_CLI=true` so cargo fetches the git-dep forks through
46+
the system `git` (which honors Railway's ambient credentials) instead of its
47+
built-in transport.
4748

4849
## Notes
4950

0 commit comments

Comments
 (0)