Add your manifest YAML's to the directory you have created:
`cp *.yaml deploy/addons/<addon name>`
```shell
cp*.yaml deploy/addons/<addon name>
```
Note: If the addon never needs authentication to GCP, then consider adding the following label to the pod's yaml:
`gcp-auth-skip-secret: "true"`
```yaml
gcp-auth-skip-secret:"true"
```
To make the addon appear in `minikube addons list`, add it to `pkg/addons/config.go`. Here is the entry used by the `registry` addon, which will work for any addon which does not require custom code:
@@ -22,7 +22,9 @@ Use Github's repositories and markdown editor as described by [Kubernetes's gene
To serve documentation pages locally, clone the `minikube` repository and run:
`make site`
```shell
make site
```
Notes :
...
...
@@ -33,7 +35,9 @@ Notes :
We recommend installing [markdownlint](https://github.com/markdownlint/markdownlint) to find issues with your markdown file. Once installed, you can use this handy target:
@@ -22,15 +22,18 @@ Alternatively, configure `sudo` to never prompt for the commands issued by minik
minikube's bootstrapper, [Kubeadm](https://github.com/kubernetes/kubeadm) verifies a list of features on the host system before installing Kubernetes. in case you get this error, and you still want to try minikube anyways despite your system's limitation you can skip the verification by starting minikube with this extra option:
## what is the resource allocation for Knative Setup using minikube?
Please allocate sufficient resources for Knative setup using minikube, especially when you run a minikube cluster on your local machine. We recommend allocating at least 6 CPUs and 8G memory.
`minikube start --cpus 6 --memory 8000`
```shell
minikube start --cpus 6 --memory 8000
```
## Do I need to install kubectl locally?
No, minikube comes with built-in kubectl [see minikube's kubectl documentation]({{<ref"docs/handbook/kubectl.md">}}).
If you have a containerized GCP app with a Kubernetes yaml, you can automatically add your credentials to all your deployed pods dynamically with this minikube addon. You just need to have a credentials file, which can be generated with `gcloud auth application-default login`. If you already have a json credentials file you want specify, use the GOOGLE_APPLICATION_CREDENTIALS environment variable.
- Start a cluster:
```
```shell
minikube start
```
```
😄 minikube v1.12.0 on Darwin 10.15.5
✨ Automatically selected the docker driver. Other choices: hyperkit, virtualbox
👍 Starting control plane node minikube in cluster minikube
...
...
@@ -21,8 +24,11 @@ minikube start
```
- Enable the `gcp-auth` addon:
```
```shell
minikube addons enable gcp-auth
```
```
🔎 Verifying gcp-auth addon...
📌 Your GCP credentials will now be mounted into every pod created in the minikube cluster.
📌 If you don't want credential mounted into a specific pod, add a label with the `gcp-auth-skip-secret` key to your pod configuration.
@@ -49,7 +49,9 @@ This flag is repeated, so you can pass it several times with several different v
By default, minikube installs the latest stable version of Kubernetes that was available at the time of the minikube release. You may select a different Kubernetes release by using the `--kubernetes-version` flag, for example:
`minikube start --kubernetes-version=v1.11.10`
```shell
minikube start --kubernetes-version=v1.11.10
```
minikube follows the [Kubernetes Version and Version Skew Support Policy](https://kubernetes.io/docs/setup/version-skew-policy/), so we guarantee support for the latest build for the last 3 minor Kubernetes releases. When practical, minikube aims to support older releases as well so that users can emulate legacy environments.
@@ -50,7 +50,7 @@ Quick guide for configuring minikube and docker on macOS, enabling docker to pus
The first step is to enable the registry addon:
```
```shell
minikube addons enable registry
```
...
...
@@ -58,13 +58,13 @@ When enabled, the registry addon exposes its port 5000 on the minikube's virtual
In order to make docker accept pushing images to this registry, we have to redirect port 5000 on the docker virtual machine over to port 5000 on the minikube machine. We can (ab)use docker's network configuration to instantiate a container on the docker's host, and run socat there:
Once socat is running it's possible to push images to the minikube registry:
```
```shell
docker tag my/image localhost:5000/myimage
docker push localhost:5000/myimage
```
...
...
@@ -77,7 +77,7 @@ Quick guide for configuring minikube and docker on Windows, enabling docker to p
The first step is to enable the registry addon:
```
```shell
minikube addons enable registry
```
...
...
@@ -86,7 +86,7 @@ When enabled, the registry addon exposes its port 5000 on the minikube's virtual
In order to make docker accept pushing images to this registry, we have to redirect port 5000 on the docker virtual machine over to port 5000 on the minikube machine. Unfortunately, the docker vm cannot directly see the IP address of the minikube vm. To fix this, you will have to add one more level of redirection.
Use kubectl port-forward to map your local workstation to the minikube vm
```
```shell
kubectl port-forward --namespace kube-system <name of the registry vm> 5000:5000
```
...
...
@@ -94,13 +94,13 @@ On your local machine you should now be able to reach the minikube registry by u
From this point we can (ab)use docker's network configuration to instantiate a container on the docker's host, and run socat there to redirect traffic going to the docker vm's port 5000 to port 5000 on your host workstation.
minikube stores post-mortem INFO logs in the temporary directory of your system. On macOS or Linux, it's easy to get a list of recent INFO logs:
`find $TMPDIR -mtime -1 -type f -name "*minikube*INFO*" -ls 2>/dev/null`
```shell
find $TMPDIR-mtime-1-type f -name"*minikube*INFO*"-ls 2>/dev/null
```
For instance, this shows:
...
...
@@ -29,7 +31,9 @@ For instance, this shows:
These are plain text log files: you may rename them to "<filename>.log" and then drag/drop them into a GitHub issue for further analysis by the minikube team. You can quickly inspect the final lines of any of these logs via:
`tail -n 10 <filename>`
```shell
tail-n 10 <filename>
```
for example, this shows:
...
...
@@ -83,4 +87,3 @@ minikube logs --problems
```
This will attempt to surface known errors, such as invalid configuration flags. If nothing interesting shows up, try `minikube logs`.