docs: refactoring the kind section to prepare for the additional docs (#1998)

This commit is contained in:
Fabrice Flore-Thébault 2023-04-11 15:49:54 +02:00 committed by GitHub
parent e52cfbe70f
commit b1ff9f90d8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 167 additions and 105 deletions

View file

@ -1,105 +0,0 @@
---
sidebar_position: 1
title: Kind
description: Kind is one way to get Kubernetes running on your workstation.
keywords: [podman desktop, podman, containers, migrating, kubernetes, kind]
tags: [migrating-to-kubernetes, kind]
---
# Running Kubernetes on your workstation with Kind and Podman
[Kind](https://kind.sigs.k8s.io/) is a command line tool for running local Kubernetes clusters on a container engine, such as Podman.
## Configuring Podman for Kind on Windows Subsystem for Linux (WSL) {#configuring}
When you create a Podman machine, Podman creates two system connections:
* The default rootless connection.
* A rootful connection, which has a `-root` suffix.
With a Podman machine running on WSL, Kind:
* Uses the default Podman connection.
* Requires the rootful connection.
Therefore, set the Podman machine default connection to rootful.
#### Procedure
1. List the Podman system connections:
```shell-session
$ podman system connection ls
```
2. Set the Podman system default connection to connection that has the `-root` suffix:
```shell-session
$ podman system connection default podman-machine-default-root
```
#### Next steps
* [Create your Kind cluster](#kind-create-cluster)
## Creating a local Kubernetes cluster with Kind {#kind-create-cluster}
#### Prerequisites
* [You configured Podman](#configuring).
* [You installed Kind](https://kind.sigs.k8s.io/).
#### Procedure
* Create a Kind cluster
```shell-session
$ kind create cluster
```
#### Next steps
* [Work with your Kind cluster](#set-current-context)
## Working with your local Kind-powered Kubernetes cluster {#set-current-context}
Set your Kubernetes context to your local Kind-powered Kubernetes cluster.
#### Procedure
1. Open the Podman Desktop tray.
2. Go to **Kubernetes**.
3. Click on the Kubernetes context with the `kind` suffix.
#### Verification
* The Kubernetes CLI reports that the current context is your cluster with the `kind` suffix:
```shell-session
$ kubectl config current-context
```
## Deleting a local Kubernetes cluster with Kind {#kind-delete-cluster}
#### Prerequisites
* [You configured Podman](#configuring).
* [You installed Kind](https://kind.sigs.k8s.io/).
#### Procedure
* Delete the Kind cluster
```shell-session
$ kind delete cluster
```
## Restarting your local Kubernetes cluster with Kind {#restarting-kind}
Kind has no command to restart a cluster.
#### Workaround
* Consider replacing Kind with a local Kubernetes cluster that you can restart, such as [OpenShift Local](https://developers.redhat.com/products/openshift-local/).
* Consider [deleting your Kind cluster](#kind-delete-cluster), and [creating a Kind cluster](#kind-create-cluster).

View file

@ -0,0 +1,35 @@
---
sidebar_position: 3
title: Configuring Podman for Kind
description: Configuring Podman for Kind on Windows Subsystem for Linux (WSL).
keywords: [podman desktop, podman, containers, migrating, kubernetes, kind]
tags: [migrating-to-kubernetes, kind]
---
# Configuring Podman for Kind on Windows Subsystem for Linux (WSL)
When you create a Podman machine, Podman creates two system connections:
* The default rootless connection.
* A rootful connection, which has a `-root` suffix.
With a Podman machine running on WSL, Kind:
* Uses the default Podman connection.
* Requires the rootful connection.
Therefore, set the Podman machine default connection to rootful.
#### Procedure
1. List the Podman system connections:
```shell-session
$ podman system connection ls
```
2. Set the Podman system default connection to connection that has the `-root` suffix:
```shell-session
$ podman system connection default podman-machine-default-root
```

View file

@ -0,0 +1,34 @@
---
sidebar_position: 4
title: Creating a Kind cluster
description: Creating a local Kind-powered Kubernetes cluster.
keywords: [podman desktop, podman, containers, migrating, kubernetes, kind]
tags: [migrating-to-kubernetes, kind]
---
# Creating a local Kind-powered Kubernetes cluster
You can create multiple local Kind-powered Kubernetes clusters.
#### Prerequisites
* [You installed Kind](installing-kind).
* [On Windows, you configured Podman](configuring-podman-for-kind-on-windows).
#### Procedure
1. Go to **Settings > Resources**
1. In the Kind tile, click on the **Create new ...** button.
1. Choose your options, and click the **Create** button.
The defaults are:
* Name: `kind-cluster`
* Provider type: `podman`
* HTTP port: `9090`
* HTTPS port: `9443`
1. (Optionally) Click the **Show logs** button to display the logs.
1. After successful creation, click on the **Go back to resources** button
#### Verification
1. In **Settings > Resources**, in the **Kind** tile, your `<kind-cluster>` instance is running.
1. In the Podman Desktop tray, open the **Kubernetes** menu, you can set the context to your Kind cluster: `kind-<kind-cluster>`.

View file

@ -0,0 +1,22 @@
---
sidebar_position: 6
title: Deleting your Kind cluster
description: Deleting your local Kind-powered Kubernetes cluster.
keywords: [podman desktop, podman, containers, migrating, kubernetes, kind]
tags: [migrating-to-kubernetes, kind]
---
# Deleting your local Kind-powered Kubernetes cluster
#### Prerequisites
* [You configured Podman](creating-a-kind-cluster.md).
* [You installed Kind](https://kind.sigs.k8s.io/).
#### Procedure
* Delete the Kind cluster
```shell-session
$ kind delete cluster
```

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

View file

@ -0,0 +1,11 @@
---
sidebar_position: 1
title: Kind
description: Kind is one way to get Kubernetes running on your workstation.
keywords: [podman desktop, podman, containers, migrating, kubernetes, kind]
tags: [migrating-to-kubernetes, kind]
---
# Running Kubernetes on your workstation with Kind and Podman
Podman Desktop can help you run [Kind-powered](https://kind.sigs.k8s.io/) local Kubernetes clusters on a container engine, such as Podman.

View file

@ -0,0 +1,24 @@
---
sidebar_position: 2
title: Installing the `kind` CLI
description: Kind is one way to get Kubernetes running on your workstation.
keywords: [podman desktop, podman, containers, migrating, kubernetes, kind]
tags: [migrating-to-kubernetes, kind]
---
# Installing the `kind` CLI
#### Procedure
* In the status bar, click on **Kind**, and follow the prompts.
![Kind in the status bar](img/kind-status-bar.png)
#### Verification
1. The status bar doesn't display **Kind**.
1. **Settings > Resources** contain a **Kind** tile.
![Kind resource tile](img/kind-resource.png)
1. You can run the `kind` CLI:
```shell-session
$ kind get clusters
```

View file

@ -0,0 +1,16 @@
---
sidebar_position: 7
title: Restarting your Kind cluster
description: Restarting your local Kind-powered Kubernetes cluster.
keywords: [podman desktop, podman, containers, migrating, kubernetes, kind]
tags: [migrating-to-kubernetes, kind]
---
# Restarting your local Kind-powered Kubernetes cluster
Kind has no command to restart a cluster.
#### Workaround
* Consider replacing Kind with a local Kubernetes cluster that you can restart, such as [OpenShift Local](https://developers.redhat.com/products/openshift-local/).
* Consider [deleting your Kind cluster](deleting-your-kind-cluster), and [creating a Kind cluster](creating-a-kind-cluster).

View file

@ -0,0 +1,25 @@
---
sidebar_position: 5
title: Working with your Kind cluster
description: Working with your local Kind-powered Kubernetes cluster.
keywords: [podman desktop, podman, containers, migrating, kubernetes, kind]
tags: [migrating-to-kubernetes, kind]
---
# Working with your local Kind-powered Kubernetes cluster
Set your Kubernetes context to your local Kind-powered Kubernetes cluster.
#### Procedure
1. Open the Podman Desktop tray.
2. Go to **Kubernetes**.
3. Click on the Kubernetes context with the `kind` prefix.
#### Verification
* The Kubernetes CLI reports that the current context is your cluster with the `kind` suffix:
```shell-session
$ kubectl config current-context
```