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

Missing listen_port in k8s service #140

Closed
phvalguima opened this issue Sep 7, 2023 · 2 comments
Closed

Missing listen_port in k8s service #140

phvalguima opened this issue Sep 7, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@phvalguima
Copy link
Contributor

Currently, pgbouncer-k8s does not expose the listen_port in k8s service. It is missing something similar to mysql-router-k8s logic to patch k8s service post creation.

I would also recommend to check issue: canonical/mysql-router-k8s-operator#137

As a workaround, it is possible to patch this service manually with:

$ cat <<EOF | kubectl apply -f -
apiVersion: v1                                                
kind: Service                                                 
metadata:                                                     
  name: SERVICE_NAME                                 
  namespace: NAMESPACE                                             
spec:                                                         
  type: TYPE                                          
  selector:                                                   
    app: pgbouncer-k8s                                        
  ports:                                                      
  - name: pgbouncer                                           
    targetPort: 6432                                          
    port: 6432                                                
    protocol: TCP                                                                                                   
  - name: placeholder                                         
    port: 65535                                               
    protocol: TCP                                             
    targetPort: 65535                                         
  selector:                                                   
    app.kubernetes.io/name: pgbouncer-k8s                     
EOF                                                           
@phvalguima phvalguima added the bug Something isn't working label Sep 7, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Sep 7, 2023

@dragomirp
Copy link
Contributor

Should be fixed on edge (rev. 77)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants