Repository navigation
refactor(restaction): delete the legacy copy path - #91
Merged
Merged
Conversation
braghettos
force-pushed
the
refactor/delete-legacy-resolve
branch
from
November 4, 2026 16:36
710c8d6 to
8b94608
Compare
This was referenced Nov 7, 2026
LegacyResolve served RESTActions without a ${ .token } header by copying
the RESTAction and its endpoint Secrets with the user's token written in.
Demo's hand-applied github-oauth-restaction was the last known user; it
got the header on 2026-11-08, and the GitHub sign-ins after it logged no
fallback. A failed Resolve is now 500 RESTActionFailed, with no retry
through a copy. The Role loses its restactions write rule, checkKeys goes
(extra status fields are ignored, as updateConfig already did), and the
snowplow Go module is no longer a dependency.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TLFnUeufsniBTiPtg82fDb
braghettos
force-pushed
the
refactor/delete-legacy-resolve
branch
from
November 8, 2026 20:47
8b94608 to
f1c8b90
Compare
braghettos
marked this pull request as ready for review
November 8, 2026 20:47
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Deletes the legacy RESTAction copy path. Nothing on 057, demo or acmp's blueprints still needs it.
Why now
krateo-system/github-oauth-restactionwas applied by hand, not from krateo-saas (whose feat: stamp strategy and groups on every <user>-clientconfig Secret (#42) #44 already added the header). On 2026-11-08, with Diego's approval, authn added only${ "Authorization: Bearer " + .token }to itsuserInfostage. The GitHub sign-ins that followed, at 19:59Z and 20:00Z, loggeduser info successfully fetchedand norestaction fell back to the legacy copy path.restActionRef. The parent'srestaction-github-groups.yamlsends the header on both stages.Change
LegacyResolveis deleted, withcopyRestActionWithEndpoints,deleteRestActionCopyWithEndpointsandrestactions.go. It copied the RESTAction and its endpoint Secrets per user and wrote the user's IdP token into each Secret copy. A failedResolveis now500 RESTActionFailedstraight away, with no retry through a copy. The log line isunable to resolve restaction(it was…, stopping). Observability checked: no alert or query matches either string.restactionsget/create/update/delete, which only the copy path used. The cluster-widegetonrestactionsfor groupauthnstays, because snowplow resolves the RESTAction as authn.checkKeysis deleted. Its only effect was to send an oidc RESTAction with extra status fields down the copy path.updateConfigalready type-checks the five fields it reads and ignores the rest. So extra fields now simply don't matter, rather than turning a working RESTAction into a 500.github.com/krateo-platformops/snowplowis no longer a dependency, andgithub.com/google/uuidbecomes indirect.Before upgrading
Any OAuthConfig or OIDCConfig with
spec.restActionRefmust point to a RESTAction whose stages send${ "Authorization: Bearer " + .token }. One that doesn't will fail sign-in with500 RESTActionFailedinstead of falling back. On the release this goes into, authn's log shows the cases to fix before upgrading: everyrestaction fell back to the legacy copy pathwarn names the RESTAction.Tests
oidc/restaction_test.go:POST /call/read, with the user's token in the body;RESTActionFailed("snowplow answered 504 Timeout"), with nothing minted and no second call.The fake apiserver rejects any request other than reading the OIDCConfig, so a write to restactions or Secrets would fail the test. Since the rebase onto main, the test sends
X-Code-Verifier: its OIDCConfig has no client secret, so since #104 it counts as a public client. The full suite passes, and the chart renders.Release: 0.38.0 (behaviour and RBAC change), when Diego decides.
🤖 Generated with Claude Code
https://claude.ai/code/session_01TLFnUeufsniBTiPtg82fDb