The concurrent-call race is fixed (advisory lock + transaction, test TestBootstrap_ConcurrentCallsCreateOneAdmin), but the endpoint is still open and unrate-limited until the first user exists. On a server exposed before someone bootstraps it, anyone can claim it.
Now that the operator no longer calls /api/bootstrap (it authenticates with TERDUT_OPERATOR_KEY), the first human admin is its only caller, so it can be gated:
Require a one-time token from the environment/Secret (TERDUT_BOOTSTRAP_TOKEN), or
Make bootstrap-job.yaml the only path and disable the route otherwise, and
Rate-limit the route like login/signup.
The chart's bootstrap Job also extracts the key with grep -o '"key":"[^"]*"'; use jq or have the server write the Secret.
Update examples/demo/run-demo.sh in terdut-operator if the call shape changes.
The concurrent-call race is fixed (advisory lock + transaction, test `TestBootstrap_ConcurrentCallsCreateOneAdmin`), but the endpoint is still open and unrate-limited until the first user exists. On a server exposed before someone bootstraps it, anyone can claim it.
Now that the operator no longer calls `/api/bootstrap` (it authenticates with `TERDUT_OPERATOR_KEY`), the first human admin is its only caller, so it can be gated:
- Require a one-time token from the environment/Secret (`TERDUT_BOOTSTRAP_TOKEN`), or
- Make `bootstrap-job.yaml` the only path and disable the route otherwise, and
- Rate-limit the route like login/signup.
The chart's bootstrap Job also extracts the key with `grep -o '"key":"[^"]*"'`; use `jq` or have the server write the Secret.
Update `examples/demo/run-demo.sh` in terdut-operator if the call shape changes.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
The concurrent-call race is fixed (advisory lock + transaction, test
TestBootstrap_ConcurrentCallsCreateOneAdmin), but the endpoint is still open and unrate-limited until the first user exists. On a server exposed before someone bootstraps it, anyone can claim it.Now that the operator no longer calls
/api/bootstrap(it authenticates withTERDUT_OPERATOR_KEY), the first human admin is its only caller, so it can be gated:TERDUT_BOOTSTRAP_TOKEN), orbootstrap-job.yamlthe only path and disable the route otherwise, andThe chart's bootstrap Job also extracts the key with
grep -o '"key":"[^"]*"'; usejqor have the server write the Secret.Update
examples/demo/run-demo.shin terdut-operator if the call shape changes.