Skip to content
This repository was archived by the owner on Jun 11, 2025. It is now read-only.

Feat/private byok cluster#335

Merged
nxtcoder17 merged 2 commits into
mainfrom
feat/private-byok-cluster
Jun 13, 2024
Merged

Feat/private byok cluster#335
nxtcoder17 merged 2 commits into
mainfrom
feat/private-byok-cluster

Conversation

@nxtcoder17
Copy link
Copy Markdown
Member

@nxtcoder17 nxtcoder17 commented Jun 13, 2024

Resolves kloudlite/kloudlite#219
Resolves kloudlite/kloudlite#246
Resolves kloudlite/kloudlite#247

Summary by Sourcery

This pull request introduces support for filtering Global VPN connections by public and private clusters. It refactors the getGlobalVPNConnectionPeers function to accept a struct with filtering options, updates the ensureGlobalVPNConnection function to remove the clusterPublicEndpoint parameter, and adds new constants for cluster visibility. Additionally, new GraphQL types and resolvers for cluster visibility have been implemented.

  • New Features:
    • Introduced support for filtering Global VPN connections by public and private clusters.
  • Enhancements:
    • Refactored the getGlobalVPNConnectionPeers function to accept a struct with filtering options.
    • Updated the ensureGlobalVPNConnection function to remove the clusterPublicEndpoint parameter.
    • Added new constants for cluster visibility and related fields in the generated constants file.
    • Implemented new GraphQL types and resolvers for cluster visibility.

- each public gvpn gateway has:
    + all other public gvpn gateways as its peers
    + as well as, kloudlite gvpn gateway as its peer, (it acts like a
      central hub in communication to/from all other devices, and
      private gateways)

- each private gvpn gateway has:
    + only kloudlite gvpn gateway as its peer, and cluster CIDRs of all
      other public/private clusters in AllowedIPs
@nxtcoder17 nxtcoder17 self-assigned this Jun 13, 2024
@nxtcoder17 nxtcoder17 requested a review from karthik1729 as a code owner June 13, 2024 11:24
@sourcery-ai
Copy link
Copy Markdown

sourcery-ai Bot commented Jun 13, 2024

Reviewer's Guide by Sourcery

This pull request introduces a new feature to support private BYOK (Bring Your Own Key) clusters. The changes primarily involve modifications to the global VPN connection logic to handle private and public clusters differently. Additionally, new fields and constants related to cluster visibility are added to various files.

File-Level Changes

Files Changes
apps/infra/internal/domain/global-vpn-cluster-connection.go
apps/infra/internal/domain/global-vpn-devices.go
Refactored VPN connection logic to handle private and public clusters differently.
apps/infra/internal/entities/field-constants/generated_constants.go
apps/infra/internal/entities/byok-cluster.go
apps/infra/internal/entities/global-vpn-connection.go
Added new fields and constants for cluster visibility.
apps/infra/internal/app/graph/model/models_gen.go
apps/infra/internal/app/graph/byokcluster.resolvers.go
Added new types and resolvers for cluster visibility in GraphQL schema.

Tips
  • Trigger a new Sourcery review by commenting @sourcery-ai review on the pull request.
  • You can change your review settings at any time by accessing your dashboard:
    • Enable or disable the Sourcery-generated pull request summary or reviewer's guide;
    • Change the review language;
  • You can always contact us if you have any questions or feedback.

Copy link
Copy Markdown

@sourcery-ai sourcery-ai Bot left a comment

Choose a reason for hiding this comment

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

Hey @nxtcoder17 - I've reviewed your changes and they look great!

Here's what I looked at during the review
  • 🟡 General issues: 1 issue found
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟢 Documentation: all looks good

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment to tell me if it was helpful.

AuthSecretKeys *GithubComKloudliteAPIAppsInfraInternalEntitiesAWSAuthSecretKeysIn `json:"authSecretKeys,omitempty"`
}

type GithubComKloudliteAPIAppsInfraInternalEntitiesClusterVisbility struct {
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

issue (typo): Fix typo in struct name.

The struct name 'GithubComKloudliteAPIAppsInfraInternalEntitiesClusterVisbility' contains a typo. It should be 'GithubComKloudliteAPIAppsInfraInternalEntitiesClusterVisibility'.

- upgrades github.com/kloudlite/operator to latest commit
@nxtcoder17 nxtcoder17 force-pushed the feat/private-byok-cluster branch from 31fb0d7 to 494031a Compare June 13, 2024 11:43
@nxtcoder17 nxtcoder17 merged commit 700eb2f into main Jun 13, 2024
@nxtcoder17 nxtcoder17 deleted the feat/private-byok-cluster branch June 13, 2024 12:07
abdheshnayak pushed a commit that referenced this pull request Nov 5, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

1 participant