mirror of
https://github.com/kubernetes-sigs/kind.git
synced 2025-12-01 07:26:05 +07:00
Merge pull request #2260 from conradwt/add-support-for-installing-via-macports
Add support for MacPorts installation.
This commit is contained in:
28
README.md
28
README.md
@@ -2,7 +2,7 @@
|
||||
|
||||
# Please see [Our Documentation](https://kind.sigs.k8s.io/docs/user/quick-start/) for more in-depth installation etc.
|
||||
|
||||
kind is a tool for running local Kubernetes clusters using Docker container "nodes".
|
||||
kind is a tool for running local Kubernetes clusters using Docker container "nodes".
|
||||
kind was primarily designed for testing Kubernetes itself, but may be used for local development or CI.
|
||||
|
||||
If you have [go] ([1.11+][go-supported]) and [docker] installed `GO111MODULE="on" go get sigs.k8s.io/kind@v0.11.0 && kind create cluster` is all you need!
|
||||
@@ -32,7 +32,7 @@ as go get inside a modules enabled project updates dependencies / behaves differ
|
||||
|
||||
This will put `kind` in `$(go env GOPATH)/bin`. If you encounter the error
|
||||
`kind: command not found` after installation then you may need to either add that directory to your `$PATH` as
|
||||
shown [here](https://golang.org/doc/code.html#GOPATH) or do a manual installation by cloning the repo and run
|
||||
shown [here](https://golang.org/doc/code.html#GOPATH) or do a manual installation by cloning the repo and run
|
||||
`make build` from the repository.
|
||||
|
||||
Without installing go, kind can be built reproducibly with docker using `make build`.
|
||||
@@ -42,7 +42,7 @@ generally recommended for CI usage in particular.
|
||||
To install, download the binary for your platform from "Assets" and place this
|
||||
into your `$PATH`:
|
||||
|
||||
On Mac & Linux:
|
||||
On Linux:
|
||||
|
||||
```console
|
||||
curl -Lo ./kind "https://kind.sigs.k8s.io/dl/v0.11.0/kind-$(uname)-amd64"
|
||||
@@ -50,12 +50,26 @@ chmod +x ./kind
|
||||
mv ./kind /some-dir-in-your-PATH/kind
|
||||
```
|
||||
|
||||
On Mac via Homebrew:
|
||||
On macOS via Homebrew:
|
||||
|
||||
```console
|
||||
brew install kind
|
||||
```
|
||||
|
||||
On macOS via MacPorts:
|
||||
|
||||
```console
|
||||
sudo port selfupdate && sudo port install kind
|
||||
```
|
||||
|
||||
On macOS via Bash:
|
||||
|
||||
```console
|
||||
curl -Lo ./kind https://kind.sigs.k8s.io/dl/v0.10.0/kind-darwin-amd64
|
||||
chmod +x ./kind
|
||||
mv ./kind /some-dir-in-your-PATH/kind
|
||||
```
|
||||
|
||||
On Windows:
|
||||
|
||||
```powershell
|
||||
@@ -66,7 +80,7 @@ Move-Item .\kind-windows-amd64.exe c:\some-dir-in-your-PATH\kind.exe
|
||||
choco install kind
|
||||
```
|
||||
|
||||
To use kind, you will need to [install docker].
|
||||
To use kind, you will need to [install docker].
|
||||
Once you have docker running you can create a cluster with:
|
||||
|
||||
```console
|
||||
@@ -93,7 +107,7 @@ file, for more usage see [the docs][user guide] or run `kind [command] --help`
|
||||
|
||||
## Community
|
||||
|
||||
Please reach out for bugs, feature requests, and other issues!
|
||||
Please reach out for bugs, feature requests, and other issues!
|
||||
The maintainers of this project are reachable via:
|
||||
|
||||
- [Kubernetes Slack] in the [#kind] channel
|
||||
@@ -103,7 +117,7 @@ The maintainers of this project are reachable via:
|
||||
Current maintainers are [@BenTheElder], [@munnerz], [@aojea], and [@amwat] - feel free to
|
||||
reach out if you have any questions!
|
||||
|
||||
Pull Requests are very welcome!
|
||||
Pull Requests are very welcome!
|
||||
If you're planning a new feature, please file an issue to discuss first.
|
||||
|
||||
Check the [issue tracker] for `help wanted` issues if you're unsure where to
|
||||
|
||||
@@ -19,7 +19,7 @@ description: |-
|
||||
> but you will not be able to perform some of the examples in our docs without it.
|
||||
> To install `kubectl` see the upstream [kubectl installation docs](https://kubernetes.io/docs/tasks/tools/install-kubectl/).
|
||||
|
||||
You can either install kind with `GO111MODULE="on" go get sigs.k8s.io/kind@{{< stableVersion >}}` or clone this repo
|
||||
You can either install kind with `GO111MODULE="on" go get sigs.k8s.io/kind@{{< stableVersion >}}` or clone this repo
|
||||
and run `make build` from the repository.
|
||||
|
||||
Please use the latest Go when installing KIND from source, ideally go 1.14 or greater.
|
||||
@@ -47,14 +47,24 @@ chmod +x ./kind
|
||||
mv ./kind /some-dir-in-your-PATH/kind
|
||||
{{< /codeFromInline >}}
|
||||
|
||||
On Mac (homebrew):
|
||||
On macOS via Homebrew:
|
||||
|
||||
{{< codeFromInline lang="bash" >}}
|
||||
brew install kind
|
||||
{{< /codeFromInline >}}
|
||||
or
|
||||
|
||||
On macOS via MacPorts:
|
||||
|
||||
{{< codeFromInline lang="bash" >}}
|
||||
sudo port selfupdate && sudo port install kind
|
||||
{{< /codeFromInline >}}
|
||||
|
||||
On macOS via Bash:
|
||||
|
||||
{{< codeFromInline lang="bash" >}}
|
||||
curl -Lo ./kind https://kind.sigs.k8s.io/dl/{{< stableVersion >}}/kind-darwin-amd64
|
||||
chmod +x ./kind
|
||||
mv ./kind /some-dir-in-your-PATH/kind
|
||||
{{< /codeFromInline >}}
|
||||
|
||||
On Windows:
|
||||
@@ -76,7 +86,7 @@ Creating a Kubernetes cluster is as simple as `kind create cluster`.
|
||||
|
||||
This will bootstrap a Kubernetes cluster using a pre-built
|
||||
[node image][node image]. Prebuilt images are hosted at[`kindest/node`][kindest/node], but to find images suitable for a given release currently you should check the [release notes] for your given kind version (check with `kind version`) where
|
||||
you'll find a complete listing of images created for a kind release.
|
||||
you'll find a complete listing of images created for a kind release.
|
||||
|
||||
To specify another image use the `--image` flag -- `kind create cluster --image=...`.
|
||||
|
||||
@@ -154,7 +164,7 @@ Docker images can be loaded into your cluster nodes with:
|
||||
|
||||
`kind load docker-image my-custom-image-0 my-custom-image-1`
|
||||
|
||||
> **Note**: If using a named cluster you will need to specify the name of the
|
||||
> **Note**: If using a named cluster you will need to specify the name of the
|
||||
> cluster you wish to load the images into:
|
||||
> `kind load docker-image my-custom-image-0 my-custom-image-1 --name kind-2`
|
||||
|
||||
@@ -212,15 +222,15 @@ if you have the [Kubernetes][kubernetes] source in your host machine
|
||||
|
||||
### Settings for Docker Desktop
|
||||
|
||||
If you are building Kubernetes (for example - `kind build node-image`) on MacOS or Windows then you need a minimum of 6GB of RAM
|
||||
If you are building Kubernetes (for example - `kind build node-image`) on MacOS or Windows then you need a minimum of 6GB of RAM
|
||||
dedicated to the virtual machine (VM) running the Docker engine. 8GB is recommended.
|
||||
|
||||
To change the resource limits for the Docker on Mac, you'll need to open the
|
||||
**Preferences** menu.
|
||||
**Preferences** menu.
|
||||
<img src="/docs/user/images/docker-pref-1.png"/>
|
||||
|
||||
Now, go to the **Advanced** settings page, and change the
|
||||
settings there, see [changing Docker's resource limits][Docker resource lims].
|
||||
settings there, see [changing Docker's resource limits][Docker resource lims].
|
||||
<img src="/docs/user/images/docker-pref-2.png" alt="Setting 8Gb of memory in Docker for Mac" />
|
||||
|
||||
|
||||
@@ -231,7 +241,7 @@ to do that first before opening "Settings"
|
||||
<img src="/docs/user/images/docker-pref-1-win.png"/>
|
||||
|
||||
Now, go to the **Advanced** settings page, and change the
|
||||
settings there, see [changing Docker's resource limits][Docker resource lims].
|
||||
settings there, see [changing Docker's resource limits][Docker resource lims].
|
||||
|
||||
<img src="/docs/user/images/docker-pref-build-win.png" alt="Setting 8Gb of memory in Docker for Windows" />
|
||||
|
||||
@@ -354,7 +364,7 @@ As you can see, kind placed all the logs for the cluster `kind` in a
|
||||
temporary directory. If you want to specify a location then simply add the path
|
||||
to the directory after the command:
|
||||
```
|
||||
kind export logs ./somedir
|
||||
kind export logs ./somedir
|
||||
Exported logs to: ./somedir
|
||||
```
|
||||
|
||||
@@ -371,7 +381,7 @@ The structure of the logs will look more or less like this:
|
||||
├── kubernetes-version.txt
|
||||
└── pods/
|
||||
```
|
||||
The logs contain information about the Docker host, the containers running
|
||||
The logs contain information about the Docker host, the containers running
|
||||
kind, the Kubernetes cluster itself, etc.
|
||||
|
||||
[go-supported]: https://golang.org/doc/devel/release.html#policy
|
||||
|
||||
Reference in New Issue
Block a user