Skip to content
This repository has been archived by the owner on Oct 22, 2021. It is now read-only.

ssh-proxy-public service label fails to match a pod due to incorrect label and pod selector. #1509

Closed
sourix opened this issue Oct 23, 2020 · 0 comments · Fixed by #1517
Closed
Labels
changelog Issue must be present in the release notes. Type: Bug Something isn't working
Milestone

Comments

@sourix
Copy link

sourix commented Oct 23, 2020

Describe the bug
In the KubeCF 2.5.8 release, when using LoadBalancers for the services (NOT ingress controller), it was noted that cf ssh did not work out of the box.
The scheduler pod has a label app.kubernetes.io/component=scheduler
The pod selector in the service definition for ssh-proxy-public looks for app.kubernetes.io/component=ssh-proxy
So quite obviously the pod selector in the service does not match the scheduler pod which has the ssh-proxy container.
The fix for this is quite simple and described in the additional context below and I'd be happy to submit a pull request if needed.

To Reproduce
Deploy KubeCF 2.5.8 on a Kubernetes backbone such as AWS EKS without nginx ingress controller.

Expected behavior
cf ssh should work.

Environment

  • KubeCF 2.5.8
  • ssh-proxy-public service
  • scheduler pod.

Additional context
I edited the service ssh-proxy-public to look like below and can confirm that ssh works after that ...
Name: ssh-proxy-public Namespace: kubecf Labels: app.kubernetes.io/component=scheduler app.kubernetes.io/instance=kubecf app.kubernetes.io/managed-by=Helm app.kubernetes.io/name=kubecf app.kubernetes.io/version=2.5.8 helm.sh/chart=kubecf-2.5.8 Annotations: meta.helm.sh/release-name: kubecf meta.helm.sh/release-namespace: kubecf Selector: app.kubernetes.io/component=scheduler,app.kubernetes.io/instance=kubecf Type: LoadBalancer IP: XX.XX.XX.XX LoadBalancer Ingress: XX.XX.XX.XX Port: ssh 2222/TCP TargetPort: 2222/TCP NodePort: ssh 30017/TCP Endpoints: xx.xx.xx.xx:2222 Session Affinity: None External Traffic Policy: Cluster Events: <none>

@sourix sourix added the Type: Bug Something isn't working label Oct 23, 2020
sourix added a commit to sourix/kubecf that referenced this issue Oct 23, 2020
This is to address cloudfoundry-incubator#1509
This is relevant only for deployments that do not use the nginx ingress-controller.
The proposal is to ppdate the ssh-proxy-public service resource to match the scheduler pods in kubecf with the correct label.
The scheduler pods in 2.5.8 have the following labels app.kubernetes.io/component=scheduler
So the spec.selector having a value of app.kubernetes.io/component: ssh-proxy matches nothing.
@sourirv sourirv mentioned this issue Oct 26, 2020
7 tasks
@fargozhu fargozhu removed their assignment Oct 27, 2020
@fargozhu fargozhu modified the milestones: 2.7.0, 2.6.0 Oct 27, 2020
@fargozhu fargozhu added the changelog Issue must be present in the release notes. label Oct 27, 2020
@fargozhu fargozhu modified the milestones: 2.6.0, 2.7.0 Oct 27, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
changelog Issue must be present in the release notes. Type: Bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants