podman-desktop/website/docs/lima/creating-a-kubernetes-instance.md
Jeff MAURY 26495fc6f8
chore(deps-dev): switch to prettier 3.6.2 (#12995)
* chore(deps-dev): switch to prettier 3.6.2

Signed-off-by: Jeff MAURY <jmaury@redhat.com>
2025-06-27 15:21:06 +00:00

2.3 KiB

sidebar_position title description tags keywords
3 Lima instance for Kubernetes Podman Desktop can assist you to create a custom Lima instance on Linux and macOS.
podman-desktop
kubernetes
onboarding
linux
macOS
podman desktop
kubernetes
lima
onboarding
linux
macos

Creating a Lima instance for Kubernetes workloads with Podman Desktop

To use the Lima provider you need a Lima instance running a Linux machine.

In the future, Podman Desktop might be able to create Lima instances.

Consider creating a custom Lima instance to:

  • Control the assigned resources: CPUs, memory, and disk size.
  • Control which Kubernetes distribution (template) to install.

Prerequisites

Procedure

  1. In a terminal, create the Lima instance.

    • To create a single-node Kubernetes cluster running k3s:

      $ limactl start template://k3s
      
    • To create a single-node Kubernetes cluster running k8s:

      $ limactl start template://k8s
      
    • To select the number of CPUs, the memory, and the disk size, add the options to the limactl start command:

      --cpus=4 --memory=4 --disk=100
      
  2. Wait for the instance to start, and restart the Lima extension.

    • Go to Settings > Preferences > Extension: Lima to change the instance name and type.

      • k3s

        • Type: kubernetes
        • Name: k3s Lima preferences k3s
      • k8s

        • Type: kubernetes
        • Name: k8s Lima preferences k8s
    • Go to Settings > Extensions > Lima to disable or enable the extension after changes.

Verification

  1. When the installation is done, the location of the KUBECONFIG file is printed. See Configuring access to a Kubernetes cluster.

    • Go to Settings > Preferences > Kubernetes to set the path of the file.
  2. Use the kubectl.lima wrapper script to connect to the cluster:

    $ kubectl.lima version