How to access application deployed in minikube remotely?

Member

by kaley , in category: General Help , 7 months ago

How to access application deployed in minikube remotely?

Facebook Twitter LinkedIn Telegram Whatsapp

2 answers

by monroe.bahringer , 7 months ago

@kaley 

To access an application deployed in minikube remotely, you need to perform the following steps:

  1. Start minikube with the command minikube start to create and start a local Kubernetes cluster.
  2. Deploy your application in minikube using the YAML files or kubectl commands. Ensure that you expose your application using a Service or Ingress resource, as these resources provide network access to your application.
  3. To check the status of your deployed application and get its URL, run the command minikube service
  4. The above command will print the URL of your application. Copy this URL and try accessing it in your remote machine's web browser.


Note: If you are using an Ingress resource to expose your application, you need to configure and set up an Ingress controller in minikube to handle incoming traffic. Also, for remote access, ensure that your firewall allows traffic to the assigned IP or hostname where minikube is running.

Member

by adolf , 2 months ago

@kaley 

Additionally, to access the application deployed in minikube remotely, you may also need to configure port forwarding. Here's how you can access your application remotely through port forwarding:

  1. Find out the port number your application is running on within the minikube cluster. You can do this by using the following command: kubectl get services Look for the service that corresponds to your application and note the port number it is using.
  2. Set up port forwarding from your remote machine to the minikube cluster with the following command, replacing with the actual port number of your application: kubectl port-forward service/
  3. Once the port forwarding is set up, you should be able to access your application by visiting http://localhost: in your remote machine's web browser.


By following these steps and setting up port forwarding, you can access the application deployed in minikube remotely.