Service located in another namespace

I stumbled over the same issue and found a nice solution which does not need any static ip configuration: You can access a service via it’s DNS name (as mentioned by you): servicename.namespace.svc.cluster.local You can use that DNS name to reference it in another namespace via a local service: kind: Service apiVersion: v1 metadata: name: … Read more

Expose port in minikube

I am not exactly sure what you are asking as it seems you already know about the minikube service <SERVICE_NAME> –url command which will give you a url where you can access the service. In order to open the exposed service, the minikube service <SERVICE_NAME> command can be used: $ kubectl run hello-minikube –image=gcr.io/google_containers/echoserver:1.4 –port=8080 … Read more

How do I access the Kubernetes api from within a pod container?

In the official documentation I found this: https://kubernetes.io/docs/tasks/access-application-cluster/access-cluster/#accessing-the-api-from-a-pod Apparently I was missing a security token that I didn’t need in a previous version of Kubernetes. From that, I devised what I think is a simpler solution than running a proxy or installing golang on my container. See this example that gets the information, from the … Read more

What’s the difference between ClusterIP, NodePort and LoadBalancer service types in Kubernetes?

[*] A ClusterIP exposes the following: spec.clusterIp:spec.ports[*].port You can only access this service while inside the cluster. It is accessible from its spec.clusterIp port. If a spec.ports[*].targetPort is set it will route from the port to the targetPort. The CLUSTER-IP you get when calling kubectl get services is the IP assigned to this service within … Read more

pod has unbound PersistentVolumeClaims

You have to define a PersistentVolume providing disc space to be consumed by the PersistentVolumeClaim. When using storageClass Kubernetes is going to enable “Dynamic Volume Provisioning” which is not working with the local file system. To solve your issue: Provide a PersistentVolume fulfilling the constraints of the claim (a size >= 100Mi) Remove the storageClass … Read more

How do I test a ClusterIssuer solver?

apiVersion: cert-manager.io/v1alpha2 kind: Certificate metadata: name: certificate-name spec: secretName: tls-cert duration: 24h renewBefore: 12h commonName: hostname dnsNames: – hostname issuerRef: name: letsencrypt kind: ClusterIssuer apiVersion: certmanager.k8s.io/v1alpha2 kind: ClusterIssuer metadata: name: letsencrypt spec: acme: email: myemail@email.com privateKeySecretRef: name: letsencrypt-private-key server: https://acme-v02.api.letsencrypt.org/directory solvers: – http01: ingress: class: nginx selector: {} apiVersion: extensions/v1beta1 kind: Ingress metadata: annotations: certmanager.k8s.io/acme-challenge-type: … Read more