安装golang
golang语言包可以在此获取:https://golang.google.cn/dl/
1.20版本的k8s需求的是1.6版本的golang
下载页面直接就有安装提示,照做即可
- Extract the archive you downloaded into /usr/local, creating a Go tree in /usr/local/go.
Important: This step will remove a previous installation at /usr/local/go, if any, prior to extracting. Please back up any data before proceeding.
For example, run the following as root or through
sudo
:rm -rf /usr/local/go && tar -C /usr/local -xzf go1.14.3.linux-amd64.tar.gz
- Add /usr/local/go/bin to the
PATH
environment variable.You can do this by adding the following line to your $HOME/.profile or /etc/profile (for a system-wide installation):
export PATH=$PATH:/usr/local/go/bin
Note: Chang