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: initial implementation of OPA subsystem chart and policy catalogue #16

Merged
merged 11 commits into from
Nov 13, 2024

Conversation

strieflin
Copy link
Member

No description provided.

Copy link

codecov bot commented Oct 25, 2024

Welcome to Codecov 🎉

Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests.

Thanks for integrating Codecov - We've got you covered ☂️

@strieflin
Copy link
Member Author

strieflin commented Oct 25, 2024

The following things have to be done before this PR can be merged:

  • Add a Java client implementation that interacts with the policy catalogue service (see feat: add java client #20)
  • Fullfil license obligations
  • Check whether all required secrets are available for the workflows

@strieflin strieflin force-pushed the add-policy-subsystem branch from 3cd6811 to caaf657 Compare November 12, 2024 13:10
@strieflin strieflin force-pushed the add-policy-subsystem branch from f8f9f0e to ad388d1 Compare November 12, 2024 13:51
@strieflin strieflin marked this pull request as ready for review November 12, 2024 13:53
@strieflin strieflin requested a review from a team as a code owner November 12, 2024 13:53
@strieflin strieflin changed the title feat: initial implementation of OPA deployment and policy catalogue (WIP) feat: initial implementation of OPA subsystem chart and policy catalogue Nov 12, 2024
Signed-off-by: Sven Trieflinger <[email protected]>
@strieflin strieflin force-pushed the add-policy-subsystem branch from 0564d21 to 330347f Compare November 12, 2024 14:45
}

// fetchPolicyFromOPA fetches a single policy from the OPA service by its ID.
// Note that there is no way to fetch a single policy by ID, so we fetch all.
Copy link
Member

Choose a reason for hiding this comment

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

but one could simply call v1/policies/<POLICY_ID>

Copy link
Member

Choose a reason for hiding this comment

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

Copy link
Member Author

Choose a reason for hiding this comment

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

Don't know how I have missed that. Used now.


switch c.GetHeader("Accept") {
case "application/json":
c.JSON(http.StatusOK, policy)
Copy link
Member

Choose a reason for hiding this comment

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

why are ID's encoded when listing, but not when fetching individually. That's kinda inconsistent

Copy link
Member Author

Choose a reason for hiding this comment

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

Correct. The ID is now consistently encoded.

@strieflin strieflin requested a review from sbckr November 13, 2024 09:39
sbckr
sbckr previously approved these changes Nov 13, 2024
Copy link
Member

@sbckr sbckr left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Member

@sbckr sbckr left a comment

Choose a reason for hiding this comment

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

LGTM

@strieflin strieflin merged commit 8284e69 into master Nov 13, 2024
6 checks passed
@strieflin strieflin deleted the add-policy-subsystem branch November 13, 2024 10:15
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