Kubectl is installable on a variety of Linux platforms, macOS and Windows. Find your preferred operating system below. Install kubectl on Linux; Install kubectl on macOS; Install kubectl on Windows; kind. Kind lets you run Kubernetes on your local computer. A nightly updated Mac OS image is available. Requires Mac OS Mavericks (10.9) or later. Kube is available for a variety of distributions. Environment Mac OS Catalina 10.15.7 Docker Desktop For Mac 3.2.2(61853) with docker engine v20.10.5 Local Kubernetes 1.19.7 Cluster provided by Docker Desktop For Mac. Prometheus Operator version: kube-prometheus-stack 14.4.0. Kubernetes version information: kubectl version. Apr 15, 2019 Time to get your cluster up and running. It’s one command, but, you’ll need your “pull secret” first. Copy it to your Mac’s clipboard so you can paste it into the terminal window. It’s quite simple; at the command line, use the following command: crc start. You will be prompted for your pull secret. Paste it to the command line.
Version v0.3 of the documentation is no longer actively maintained. The site that you are currently viewing is an archived snapshot. For up-to-date documentation, see the latest version.
This document will outline steps that will get your local installation of Kubeflow running on top of Mikikube. Minikube runs a simple, single-node Kubernetes cluster inside a virtual machine (VM).
By the end of this document, you’ll have a local installation of Minikube kubernetes cluster along with all the default core components ofKubeflow deployed as services in the pods. You should be able to access JupyterHub notebooks, and the Kubeflow Dashboard.
Prerequisites
- Laptop, Desktop or a Workstation
- >= 12GB RAM
- >= 8 CPU Cores
- ~100GB or more Disk Capacity
- Optional: GPU card
- Mac OS X or Linux (Ubuntu/RedHat/CentOS)
- sudo or admin access on the local machine
- Access to an Internet connection with reasonable bandwidth
- A hypervisor such as VirtualBox, Vmware Fusion, KVM etc.
If you already have a hypervisor on your system, you can follow the Quick Setup to do a guided Minikube setup.
Install a Hypervisor
If you do not already have a hypervisor or a virtualizer installed, install a new one. Once the hypervisor is installed, you don’t need to start or use it directly. Minikube will automatically invoke the hypervisor to start the VM.
Mac OS X
Install Virtual Box or VMware Fusion.
Ubuntu
Install Virtual Box or KVM.
The KVM2 driver is intended to replace KVM driver. The KVM2 driver is maintained by the minikube team, and is built, tested and released with minikube.For installing KVM:
Then install the driver itself:
CentOS
Install Virtual Box or KVM.
For installing KVM:
Then install the driver itself:
Quick Setup
The following describes a script driven installation that you can use to deploy allthe necessary components including kubectl
, minikube
, kfctl
along with Kubeflow itself. The script requires input from you on some configuration information and then it drives the rest of the installation. Run the following to start the installation:
KUBEFLOW_TAG is a tag corresponding to the version to checkout such as v0.3.0
or master
.
The script asks for some config input as shown below:
Let us consider the example for CPUs configuration. When it asks Assign CPUs between 3..10 [6]:
the 3..10
suggest the range of CPU cores available based on your host machine. [6]
is the suggested default. You can choose any value within the range and enter the value or just press enter to accept the default value suggested in square brackets. In the image above, we choose the default 6 for CPUs and specified 12GB of memory explicitly. Note that:
- You will need to specify the virtualizer installed on the system explicitly and it needs to be one of the values provided as options.
- If you don’t want to mount any local directory into the JupyterHub simply press enter instead of specifying any path.
After the configuration is complete, the script will continue execution for the next few minutes and when finished successfully should output some like:
When the installation finishes successfully, you can access JupyterHub as described in Where to go next. If you have trouble with the installation script or run into errors, you can follow the detailed installation steps manually as described below.
Install Kubectl
GCloud SDK
Mac OS X
Ubuntu
CentOS
Kube Mac Os Catalina
Verify kubectl installed
Try running
This should output something like
Install & Start Minikube
Please see detailed instructions for Minikube installation.For quick setup instructions follow along below.
Mac OS X
OR
Kube Mac Os Downloads
Ubuntu or CentOS
Start your minikube cluster
This takes a couple minutes as it will talk to the hypervisor and create a VM with the specified configuration.
Notes:
- These are the minimum recommended settings on the VM created by minikube for kubeflow deployment. You are free to adjust them higher based on your host machinecapabilities and workload requirements.
- Using certain hypervisors might require you to set –vm-driver option specifying the driveryou want to use.
In case, you have the default minikube VM already created (following detailed installation instructions), please use the following to update the VM.
Installing Kubeflow using kfctl
The following steps will deploy Kubeflow components and start them on the Minikube you created above.
Download Kubeflow source
- KUBEFLOW_SRC is the directory where you want to download the source
- KUBEFLOW_TAG is a tag corresponding to the version to checkout such as
v0.3.0
Run the following to setup and deploy Kubeflow:
- KFAPP is the name of a directory to store your configs. This directory is created when you run init. Please see understanding the deployment process for more details.
The above installation may take a few minutes. At the end of the installation you should see:
Where to go next
Now you can access the Kubeflow dashboard at http://localhost:8080/ and JupyterHub at http://localhost:8080/hub/.For JupyterHub, you’ll be landing on a login page.
- Use any username and password to login
- Pick an available CPU tensorflow image
- Provide at least 2 CPUs
- Provide 4Gi for the memory
- Leave “Extra Resource Limits” alone for now
- Click Spawn.
- You should be redirected to a page that waits while the server is starting.
If the page doesn’t refresh, please seetroubleshooting.
For further exploration refer to the guide.
To help you provision, operate, and maintain Tanzu Kubernetes clusters, specify a default text editor for kubectl .
Purpose
After you provision a Tanzu Kubernetes cluster you need to maintain it. Typical maintenance tasks include upgrading the Kubernetes version and scaling cluster nodes. To perform such tasks you update the cluster manifest.
The most convenient way to update the manifest for a provisioned cluster is to use the kubectl edit command. This command opens the Kubernetes manifest in a text editor of your choice. When you save the changes, Kubernetes automatically applies the changes and updates the cluster.
To use the kubectl edit
command, create a KUBE_EDITOR environment variable and specify your preferred text editor as the variable value. In addition, append the watch flag (-w
) to the value so that kubectl knows when you have committed (saved) your changes.
Windows
On Windows, create a system environment variable named KUBE_EDITOR
with the value set to the path of your preferred text editor. Append the watch flag (-w
) to the value.
For example, the following environment variable sets Visual Studio Code as the default text editor for kubectl and includes the watch flag so that Kubernetes knows when you save your changes:
KUBE_EDITOR=code -w
.
Mac OS
On Mac OS, create an environment variable named KUBE_EDITOR
with the value set to the path of your preferred text editor. Append the watch flag (-w
) to the value so that kubectl knows when you have committed (saved) your changes.
For example, the following addition to the .bash_profile
sets Sublime as the default text editor for kubectl and includes the watch flag so kubectl knows when you have saved any changes.
export KUBE_EDITOR='/Applications/Sublime.app/Contents/SharedSupport/bin/subl-w'
Linux
On Linux (Ubuntu, for example), typically the default command-line EDITOR
is Vim. If so, no further action is needed to use the kubectl edit
command. If you want to use a different editor, create an environment variable named KUBE_EDITOR
with the value set to the path of your preferred text editor.