[zh] sync tasks\tools\install-kubectl-linux.md

Signed-off-by: ydFu <ader.ydfu@gmail.com>
This commit is contained in:
ydFu 2023-07-28 16:43:50 +08:00
parent 7813cdb86b
commit a76a6f7c43
1 changed files with 10 additions and 10 deletions

View File

@ -22,8 +22,8 @@ card:
## {{% heading "prerequisites" %}} ## {{% heading "prerequisites" %}}
<!-- <!--
You must use a kubectl version that is within one minor version difference of your cluster. You must use a kubectl version that is within one minor version difference of
For example, a v{{< skew currentVersion >}} client can communicate your cluster. For example, a v{{< skew currentVersion >}} client can communicate
with v{{< skew currentVersionAddMinor -1 >}}, v{{< skew currentVersionAddMinor 0 >}}, with v{{< skew currentVersionAddMinor -1 >}}, v{{< skew currentVersionAddMinor 0 >}},
and v{{< skew currentVersionAddMinor 1 >}} control planes. and v{{< skew currentVersionAddMinor 1 >}} control planes.
Using the latest compatible version of kubectl helps avoid unforeseen issues. Using the latest compatible version of kubectl helps avoid unforeseen issues.
@ -93,7 +93,7 @@ The following methods exist for installing kubectl on Linux:
对于 Linux ARM64 来说,请输入: 对于 Linux ARM64 来说,请输入:
```bash ```bash
curl -LO https://dl.k8s.io/release/{{< param "fullversion" >}}/bin/linux/arm64/kubectl curl -LO https://dl.k8s.io/release/v{{< skew currentPatchVersion >}}/bin/linux/arm64/kubectl
``` ```
{{< /note >}} {{< /note >}}
@ -230,7 +230,7 @@ Or use this for detailed view of version:
<!-- <!--
If you use Debian 9 (stretch) or earlier you would also need to install `apt-transport-https`: If you use Debian 9 (stretch) or earlier you would also need to install `apt-transport-https`:
--> -->
如果你使用 Debian 9stretch或更早版本则你还需要安装 `apt-transport-https` 如果你使用 Debian 9stretch或更早版本则你还需要安装 `apt-transport-https`
```shell ```shell
@ -303,7 +303,7 @@ sudo yum install -y kubectl
{{< tabs name="other_kubectl_install" >}} {{< tabs name="other_kubectl_install" >}}
{{% tab name="Snap" %}} {{% tab name="Snap" %}}
<!-- <!--
If you are on Ubuntu or another Linux distribution that supports the If you are on Ubuntu or another Linux distribution that supports the
[snap](https://snapcraft.io/docs/core/install) package manager, kubectl [snap](https://snapcraft.io/docs/core/install) package manager, kubectl
is available as a [snap](https://snapcraft.io/) application. is available as a [snap](https://snapcraft.io/) application.
@ -320,7 +320,7 @@ kubectl version --client
{{% /tab %}} {{% /tab %}}
{{% tab name="Homebrew" %}} {{% tab name="Homebrew" %}}
<!-- <!--
If you are on Linux and using [Homebrew](https://docs.brew.sh/Homebrew-on-Linux) If you are on Linux and using [Homebrew](https://docs.brew.sh/Homebrew-on-Linux)
package manager, kubectl is available for [installation](https://docs.brew.sh/Homebrew-on-Linux#install). package manager, kubectl is available for [installation](https://docs.brew.sh/Homebrew-on-Linux#install).
--> -->
@ -340,7 +340,7 @@ kubectl version --client
<!-- <!--
## Verify kubectl configuration ## Verify kubectl configuration
--> -->
## 验证 kubectl 配置 {#verify-kubectl-configration} ## 验证 kubectl 配置 {#verify-kubectl-configuration}
{{< include "included/verify-kubectl.md" >}} {{< include "included/verify-kubectl.md" >}}
@ -372,7 +372,7 @@ kubectl 为 Bash、Zsh、Fish 和 PowerShell 提供自动补全功能,可以
<!-- <!--
### Install `kubectl convert` plugin ### Install `kubectl convert` plugin
--> -->
### 安装 `kubectl convert` 插件 ### 安装 `kubectl convert` 插件 {#install-kubectl-convert-plugin}
{{< include "included/kubectl-convert-overview.md" >}} {{< include "included/kubectl-convert-overview.md" >}}
@ -381,12 +381,12 @@ kubectl 为 Bash、Zsh、Fish 和 PowerShell 提供自动补全功能,可以
--> -->
1. 用以下命令下载最新发行版: 1. 用以下命令下载最新发行版:
{{< tabs name="download_binary_linux" >}} {{< tabs name="download_convert_binary_linux" >}}
{{< tab name="x86-64" codelang="bash" >}} {{< tab name="x86-64" codelang="bash" >}}
curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl-convert" curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl-convert"
{{< /tab >}} {{< /tab >}}
{{< tab name="ARM64" codelang="bash" >}} {{< tab name="ARM64" codelang="bash" >}}
curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/arm64/kubectl" curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/arm64/kubectl-convert"
{{< /tab >}} {{< /tab >}}
{{< /tabs >}} {{< /tabs >}}