Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Implementation of API Key Auth #125

Merged
merged 70 commits into from
Jan 21, 2025
Merged

feat: Implementation of API Key Auth #125

merged 70 commits into from
Jan 21, 2025

Conversation

aabchoo
Copy link
Contributor

@aabchoo aabchoo commented Jan 17, 2025

This PR implements APIKey Auth for backendSecurityPolicy. The api key stored in a secret will be mounted to the extproc's pod, and later extracted by the appropriate AuthHandler.

Moved extprocDeployment into the sink as we need to tinker with the deployment if backend/backendSecurityPolicy is updated.

Removed the envoy config yaml's field add_request_header and replaced it with new API Key Auth implementation. CI passes which means that API Key mounted to extproc + specified on backend auth works.

Will work on adding AWS Credential file after this.

Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
@mathetake
Copy link
Member

almost there!

aabchoo and others added 6 commits January 21, 2025 10:25
Co-authored-by: Takeshi Yoneda <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
@aabchoo aabchoo changed the title Implementation of API Key Auth feat: Implementation of API Key Auth Jan 21, 2025
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
@aabchoo aabchoo requested review from yuzisun and mathetake January 21, 2025 20:08
Copy link
Member

@mathetake mathetake left a comment

Choose a reason for hiding this comment

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

minor comments, but LGTM

internal/controller/ai_service_backend_test.go Outdated Show resolved Hide resolved
internal/controller/ai_service_backend_test.go Outdated Show resolved Hide resolved
internal/controller/sink.go Outdated Show resolved Hide resolved
tests/extproc/extproc_test.go Outdated Show resolved Hide resolved
aabchoo and others added 4 commits January 21, 2025 15:42
Co-authored-by: Takeshi Yoneda <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Co-authored-by: Takeshi Yoneda <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Co-authored-by: Takeshi Yoneda <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Co-authored-by: Takeshi Yoneda <[email protected]>
Signed-off-by: Aaron Choo <[email protected]>
Copy link
Member

@mathetake mathetake left a comment

Choose a reason for hiding this comment

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

Nice work!! Thank you for multiple iterations!

@mathetake mathetake enabled auto-merge (squash) January 21, 2025 20:48
@mathetake mathetake merged commit 7dc91db into main Jan 21, 2025
22 checks passed
@mathetake mathetake deleted the aaron/auth-apikey branch January 21, 2025 20:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants