-
Notifications
You must be signed in to change notification settings - Fork 498
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
Can't change tiproxy service type #5664
Comments
it does support changing the service type now, if you need to use LoadBalancer, you can create another service (with |
I just tried it and it does not work? How are you doing it? |
Do you mean, an extra service manually added does not work? Have you set the same lableSelector as the original one? |
Is there an example some where? I am kind of lost on how to actually set this up, tbh. I would appreciate any help here. |
Hello, here is my tiproxy service config: Original service created by operator apiVersion: v1
kind: Service
metadata:
labels:
app.kubernetes.io/component: tiproxy
app.kubernetes.io/instance: tidb
app.kubernetes.io/managed-by: tidb-operator
app.kubernetes.io/name: tidb-cluster
app.kubernetes.io/used-by: end-user
name: tidb-tiproxy
namespace: tidb
spec:
ipFamilyPolicy: PreferDualStack
ports:
- name: tiproxy-api
nodePort: 21982
port: 3080
protocol: TCP
targetPort: 3080
- name: tiproxy-sql
nodePort: 29742
port: 6000
protocol: TCP
targetPort: 6000
selector:
app.kubernetes.io/component: tiproxy
app.kubernetes.io/instance: tidb
app.kubernetes.io/managed-by: tidb-operator
app.kubernetes.io/name: tidb-cluster
type: NodePort And the LoadBalancer service created by myself apiVersion: v1
kind: Service
metadata:
name: tidb-tiproxy-lb
namespace: tidb
spec:
ipFamilyPolicy: PreferDualStack
ports:
- name: tiproxy-api
port: 3080
protocol: TCP
targetPort: 3080
- name: tiproxy-sql
port: 6000
protocol: TCP
targetPort: 6000
selector:
app.kubernetes.io/component: tiproxy
app.kubernetes.io/instance: tidb
app.kubernetes.io/managed-by: tidb-operator
app.kubernetes.io/name: tidb-cluster
type: LoadBalancer Just copy your original service yaml, delete the |
ok, so here is the issue and where the confusion comes in. If you install via: https://docs.pingcap.com/tidb-in-kubernetes/stable/get-started I just used the above as i have a simplish install trying to play with tidb in my home lab |
not CHANGE the original one, just copy to a new file and give the resource another name |
Bug Report
What version of Kubernetes are you using?
v1.26.6
What version of TiDB Operator are you using?
v1.6.0
What did you do?
add
spec.tiproxy.service.type = LoadBalancer
in TidbClusterWhat did you expect to see?
service type change to LoadBalancer
What did you see instead?
part of my TidbCluster file:
The text was updated successfully, but these errors were encountered: