kubernetes service external ip pending

0 votes

I am trying to deploy nginx on kubernetes, kubernetes version is v1.5.2, I have deployed nginx with 3 replica, YAML file is below,

apiVersion: extensions/v1beta1
kind: Deployment
metadata:
  name: deployment-example
spec:
  replicas: 3
  revisionHistoryLimit: 2
  template:
    metadata:
      labels:
        app: nginx
    spec:
      containers:
      - name: nginx
        image: nginx:1.10
        ports:
        - containerPort: 80

and now I want to expose its port 80 on port 30062 of node, for that I created a service below,

kind: Service
apiVersion: v1
metadata:
  name: nginx-ils-service
spec:
  ports:
    - name: http
      port: 80
      nodePort: 30062
  selector:
    app: nginx
  type: LoadBalancer

this service is working good as it should be, but it is showing as pending not only on kubernetes dashboard also on terminal. 

Aug 31, 2018 in Kubernetes by lina
• 8,220 points
2,593 views
Are you deploying this cluster on Minikube?
Yess @Kalgi, i'm using minikube.

2 answers to this question.

0 votes
There is no LoadBalancer when you use Minikube. If you're trying out the service type you need to deploy your application on a cloud platform such as AWS.

These cloud platforms have an inbuild LoadBalancer and you can only use the service type: LoadBalancer in such cases.

Try replacing your service type to NodePort and let me know if it works.
answered Oct 8, 2018 by Kalgi
• 52,350 points
0 votes

This question is very similar to this.

answered Oct 8, 2018 by Nilesh
• 7,060 points

Related Questions In Kubernetes

0 votes
1 answer

External IP not working with Minikube Kubernetes

You can use an ingress controller on ...READ MORE

answered Jan 24, 2019 in Kubernetes by DareDev
• 6,890 points
2,684 views
+5 votes
2 answers

Redirecting host to service path in kubernetes

What you are trying to do is ...READ MORE

answered Mar 27, 2018 in Kubernetes by DragonLord999
• 8,450 points
3,578 views
0 votes
2 answers

How can I access a service installed on Kubernetes from anywhere?

if u want to directly want to ...READ MORE

answered Jul 26, 2020 in Kubernetes by Akash Gupta
1,318 views
0 votes
1 answer

Kubernetes ingress IP is set to docker0 ip

The issue here was the kubelet configuration. ...READ MORE

answered Sep 10, 2018 in Kubernetes by Kalgi
• 52,350 points
718 views
+1 vote
1 answer
0 votes
3 answers

Error while joining cluster with node

Hi Kalgi after following above steps it ...READ MORE

answered Jan 17, 2019 in Others by anonymous
15,476 views
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
4,035 views
0 votes
2 answers

kubernetes service external ip pending

If you are not using GCE or ...READ MORE

answered Aug 31, 2018 in Kubernetes by Nilesh
• 7,060 points
12,699 views
0 votes
1 answer

Filter source ip in kubernetes ingress in GCE

This feature currently works only with nginx. Example ...READ MORE

answered Sep 7, 2018 in Kubernetes by Kalgi
• 52,350 points
1,261 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP