kubernetes / website

Kubernetes website and documentation repo:
https://kubernetes.io
Creative Commons Attribution 4.0 International
4.5k stars 14.45k forks source link

Task "Connect a Frontend to a Backend Using Services" does not work after following instructions #40379

Closed 1dropaflame closed 9 months ago

1dropaflame commented 1 year ago

This is a Bug Report

Problem:

Following the task instructions, it does not work. 1) no instructions given what to do with

/frontend-nginx.conf

2) Hangs and does not get an external ip address even after waiting 10 minutes. The value shows <pending>

$ kubectl get service frontend --watch
NAME       TYPE           CLUSTER-IP     EXTERNAL-IP   PORT(S)        AGE
frontend   LoadBalancer   10.109.154.2   <pending>     80:30460/TCP   33s

Proposed Solution:

please correct the tutorial.

Page to Update:

https://kubernetes.io/docs/tasks/access-application-cluster/connecting-frontend-backend/

1.26.1

Windows 11, minikube, WSL2

k8s-ci-robot commented 1 year ago

This issue is currently awaiting triage.

SIG Docs takes a lead on issue triage for this website, but any Kubernetes member can accept issues by applying the triage/accepted label.

The triage/accepted label can be added by org members by writing /triage accepted in a comment.

Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.
Ritikaa96 commented 1 year ago

3. Hangs and does not get an external ip address even after waiting 10 minutes. The value shows <pending>

$ kubectl get service frontend --watch
NAME       TYPE           CLUSTER-IP     EXTERNAL-IP   PORT(S)        AGE
frontend   LoadBalancer   10.109.154.2   <pending>     80:30460/TCP   33s

Hi @1dropaflame , you are using loadbalancer for minikube. In case where the cluster is created on platform which does not provide externalIPs or will be seen only. External IPs are provided by providers like AWS, Google cloud etc. I suppose yours is baremetal cluster.

For minikube external IP see this: https://minikube.sigs.k8s.io/docs/handbook/accessing/#loadbalancer-access

Ritikaa96 commented 1 year ago

For reference it is written in the doc itself here:

Similar to the backend, the frontend has a Deployment and a Service. An important difference to notice between the backend and frontend services, is that the configuration for the frontend Service has type: LoadBalancer, which means that the Service uses a load balancer provisioned by your cloud provider and will be accessible from outside the cluster.

1dropaflame commented 1 year ago

@Ritikaa96 Thanks for the reply. It will be good if it can be emphasized in the instructions that this requires an external cloud provider's provisioning of a load balancer. Most of us are trying to learn K8s on our home Windows laptops.

Ritikaa96 commented 1 year ago

@1dropaflame I can understand as I have faced similar issues in beginning. however, searching through the following solved most of my queries. as per my experience discussion in these resources also prove to be extremely benefitting for learning k8s

Ritikaa96 commented 1 year ago

@Ritikaa96 Thanks for the reply. It will be good if it can be emphasized in the instructions that this requires an external cloud provider's provisioning of a load balancer. Most of us are trying to learn K8s on our home Windows laptops.

This is already mentioned in the same page , not with a note but in the lines , see:

For reference it is written in the doc itself here:

Similar to the backend, the frontend has a Deployment and a Service. An important difference to notice between the backend and frontend services, is that the configuration for the frontend Service has type: LoadBalancer, which means that the Service uses a load balancer provisioned by your cloud provider and will be accessible from outside the cluster.

sftim commented 1 year ago

I could change the title to: Task "Connect a Frontend to a Backend Using Services" does not list load balancer as prerequisite

except that when I checked, the page does list that detail.

We could mention minikube anyway, I guess. It's not a priority to do that. If someone wants to send in a PR, I think that's fine/

/language en /priority awaiting-more-evidence

Ritikaa96 commented 1 year ago

Hi, I think one workaround can also be to add a note for this like

For external IP in minikube see this: https://minikube.sigs.k8s.io/docs/handbook/accessing/#loadbalancer-access

1dropaflame commented 1 year ago

Or you can also say like in the TV commercials, "Warning! Professional riders shown. Do not try this at home." :)

k8s-triage-robot commented 1 year ago

The Kubernetes project currently lacks enough contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

You can:

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

k8s-triage-robot commented 10 months ago

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

You can:

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle rotten

k8s-triage-robot commented 9 months ago

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues according to the following rules:

You can:

Please send feedback to sig-contributor-experience at kubernetes/community.

/close not-planned

k8s-ci-robot commented 9 months ago

@k8s-triage-robot: Closing this issue, marking it as "Not Planned".

In response to [this](https://github.com/kubernetes/website/issues/40379#issuecomment-1951034411): >The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. > >This bot triages issues according to the following rules: >- After 90d of inactivity, `lifecycle/stale` is applied >- After 30d of inactivity since `lifecycle/stale` was applied, `lifecycle/rotten` is applied >- After 30d of inactivity since `lifecycle/rotten` was applied, the issue is closed > >You can: >- Reopen this issue with `/reopen` >- Mark this issue as fresh with `/remove-lifecycle rotten` >- Offer to help out with [Issue Triage][1] > >Please send feedback to sig-contributor-experience at [kubernetes/community](https://github.com/kubernetes/community). > >/close not-planned > >[1]: https://www.kubernetes.dev/docs/guide/issue-triage/ Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.