Skip to content

benchmarks: make install.sh reproduce credential and template rotations - #34

Merged
Jaana Dogan (rakyll) merged 1 commit into
mainfrom
creds
Oct 27, 2026
Merged

Jaana Dogan (rakyll) merged 1 commit into
mainfrom
creds

Conversation

@rakyll

Copy link
Copy Markdown
Collaborator
  • Credentials are now an explicit input. The script fails unless ANTHROPIC_API_KEY, ANTHROPIC_ENVIRONMENT_ID and ANTHROPIC_ENVIRONMENT_KEY are set, or CREDS_SECRET names an existing Secret to load them from. The banner shows the environment ID and short hashes of the keys, never the keys themselves.
  • After applying, check that ate-ant-creds holds exactly these credentials, and that the registered ActorTemplate carries the same ANTHROPIC_ENVIRONMENT_ID. Before, a failed template create fell back to the existing template and could keep an old environment ID.
  • Restart k8s-credential-provider after applying. It caches the Secret and namespace policy, so actors kept getting the old environment key injected at egress.
  • Point ate-ant-controller at TEMPLATE and NAMESPACE. ate-ant manifest doesn't pass these to the controller, which then uses the default template. The same patch bumps restartedAt, so the controller rolls once and reloads ate-ant-creds.
  • Pin defaults to the live cluster: TEMPLATE=ate-ant-actor-template-oct23 and CONTROLLER_REPLICAS=50. Each controller replica polls the Anthropic API, so lower CONTROLLER_REPLICAS if the logs show 429 errors.
  • Update benchmarks/README.md to match.

- Credentials are now an explicit input. The script fails unless
  ANTHROPIC_API_KEY, ANTHROPIC_ENVIRONMENT_ID and
  ANTHROPIC_ENVIRONMENT_KEY are set, or CREDS_SECRET names an existing
  Secret to load them from. The banner shows the environment ID and
  short hashes of the keys, never the keys themselves.
- After applying, check that ate-ant-creds holds exactly these
  credentials, and that the registered ActorTemplate carries the same
  ANTHROPIC_ENVIRONMENT_ID. Before, a failed template create fell back
  to the existing template and could keep an old environment ID.
- Restart k8s-credential-provider after applying. It caches the Secret
  and namespace policy, so actors kept getting the old environment key
  injected at egress.
- Point ate-ant-controller at TEMPLATE and NAMESPACE. `ate-ant manifest`
  doesn't pass these to the controller, which then uses the default
  template. The same patch bumps restartedAt, so the controller rolls
  once and reloads ate-ant-creds.
- Pin defaults to the live cluster: TEMPLATE=ate-ant-actor-template-oct23
  and CONTROLLER_REPLICAS=50. Each controller replica polls the Anthropic
  API, so lower CONTROLLER_REPLICAS if the logs show 429 errors.
- Update benchmarks/README.md to match.

@igooch igooch left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good overall. A few questions inline. One more outside the diff: the architecture table in benchmarks/README.md still says 20 controller replicas, while the edited paragraph says 50.

Comment thread benchmarks/install.sh Resolved
Comment thread benchmarks/install.sh Resolved
Comment thread benchmarks/install.sh Resolved
Comment thread benchmarks/install.sh Resolved
Comment thread benchmarks/install.sh Resolved
@rakyll
Jaana Dogan (rakyll) merged commit b86ca1d into main Oct 27, 2026
11 checks passed
@rakyll
Jaana Dogan (rakyll) deleted the creds branch October 27, 2026 04:01
igooch added a commit that referenced this pull request Oct 27, 2026
Bumps `go.ate.dev/substrate` to v0.6.0 and fixes what the upgrade broke.
No Go API changes were needed.

Fixes #19

## Changes

- **Label the `ate-ant` Namespace `ate.dev/api-access=true`.**
ate-system now ships NetworkPolicies that only let labeled namespaces
reach ateapi. Without the label, every ateapi call from the controller
(and loadgen) times out.
- **`benchmarks/install.sh`: pass the flags `ate-setup deploy
ate-system` now requires.**
- `--credential-provider='{"name":"k8s.io"}'`: needed for egress key
injection.
- `--ingress-allowed-spiffe-ids`: the router only admits listed clients.
Defaults to the controller's `router-client` identity.
- `--snapshot-transfer-gsa-name`: GCS snapshot transfers now run as a
dedicated service account. The script creates it and grants bucket
access.
- `--preview=PerTemplateSnapshotLocation`: needed because our
ActorTemplate sets its own snapshot bucket.
- **README:** list these install flags under prerequisites.
- **`benchmarks/README.md`:** add an "Upgrade Agent Substrate" section.
It scales the WorkerPool to 0 before the upgrade, because v0.6.0's
ateapi crash-loops on worker records written by older releases. Its
`install.sh` step uses `CREDS_SECRET` and the credential provider
restart from #34.
- **Makefile:** `make push` now prints the image digest with Docker as
well as Podman.

## Testing

- Fresh v0.6.0 install on a GKE cluster via `install.sh`, using
placeholder Anthropic credentials:
  - `loadgen --mode=direct` (10 sessions × 2 turns): 60/60 ops OK.
  - `loadgen --mode=valkey` (10 sessions): 30/30 ops OK, stream drained.
- In-place upgrade on two GKE clusters from a pre-v0.6.0 Substrate
commit, following the new README section, with #30, #31 and #34 applied.
Snapshots taken before the upgrade restored, and a `valkey` run drained.
- **Not tested**: a real agent session, because it needs real Anthropic
credentials.

## Follow-ups

- Part of #17.
- To finish it, rebuild the ate-ant and ateworker-gvisor images with
./benchmarks/build-images.sh, which updates the digests pinned in
install.sh and the README.
- Until then, install.sh's default images predate v0.6.0, and the old
worker image likely won't register with a v0.6.0 atelet.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants