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

[Feature request] Allow for Service name overrides #405

Open
walkamongus opened this issue Apr 6, 2023 · 3 comments
Open

[Feature request] Allow for Service name overrides #405

walkamongus opened this issue Apr 6, 2023 · 3 comments

Comments

@walkamongus
Copy link

I ran into an issue exposing endpoints externally when trying to use an Ingress resource. If the VitessCluster CRD allowed for overriding Service names via serviceOverrides then users would be able to set a predictable name for Service resources. That would allow users to inject an Ingress resource via Helm or Kustomize that references the correct Service name. Alternatively -- for more work (and likely more fragile implementation) -- the custom resource itself could be extended with Ingress support.

@oavril
Copy link

oavril commented Aug 10, 2023

Hi !

I'm also interested in adding the ability to override the name and add labeling of services to create a helm including an ingress and a loadBalancer.

Unless you provide an official helm chart?

@frouioui
Copy link
Member

frouioui commented Dec 3, 2024

Hi @walkamongus isn't the service field of the vtgate CRD sufficient for this?

Service *ServiceOverrides `json:"service,omitempty"`

@luismacosta
Copy link

luismacosta commented Mar 2, 2025

vitess-operator/pkg/apis/planetscale/v2/vitesscell_types.go

Hello @frouioui @mattlord

This was also reported:

#305
#405

Should be at CRD vitessclusters, define the serviceName for vtgate and vtctld.

For vtgate service I believe that should be here, but there is no serviceName property
For vtctld, I cannot find any reference for service creation in CRD
Also, I would say that the CRD should contain a section to create ingress for vtgate and vtctld

At the moment, once there is no support for this in the helm chart, I've created my own templates:
service-vtgate.yaml
service-vtctld.yaml
ingress-vtgate.yaml
ingress-vtctld.yaml

The same for vtadmin. Would be nice to have a way to expose 2 ingress: UI and api.

Regarding ingress for vtagte/vtctld/vtadmin, maybe in vitessclusters CRD spec:

ingress:
  properties:
    annotations:
      additionalProperties:
        type: string
      type: object
    className:
      type: string
    labels:
      additionalProperties:
        type: string
      type: object
    serviceName:
       type: string
    hostName:
      type: string
    tls:
      items:
        properties:
          hosts:
            items:
              type: string
            type: array
          secretName:
            type: string
        type: object
      type: array
  type: object

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

No branches or pull requests

4 participants