From 989ea84f626fab95848966b7c86b6544bf4a7b0e Mon Sep 17 00:00:00 2001 From: Robert Bailey Date: Wed, 10 Jul 2019 14:56:51 -0700 Subject: [PATCH] Update minikube documentation and dev tooling to 1.12. --- build/includes/minikube.mk | 7 +----- .../content/en/docs/Guides/troubleshooting.md | 23 +++++++++++++++++++ site/content/en/docs/Installation/_index.md | 9 ++++++++ 3 files changed, 33 insertions(+), 6 deletions(-) diff --git a/build/includes/minikube.mk b/build/includes/minikube.mk index 72cbe3019d..29a60a791a 100644 --- a/build/includes/minikube.mk +++ b/build/includes/minikube.mk @@ -27,18 +27,13 @@ # (defaults virtualbox for Linux and macOS, hyperv for windows) if you so desire. minikube-test-cluster: DOCKER_RUN_ARGS+=--network=host -v $(minikube_cert_mount) minikube-test-cluster: $(ensure-build-image) minikube-agones-profile - # localkube bootstrapper fixes issues with profiles - $(MINIKUBE) start --kubernetes-version v1.11.5 --vm-driver $(MINIKUBE_DRIVER) \ - --extra-config=apiserver.authorization-mode=RBAC + $(MINIKUBE) start --kubernetes-version v1.12.10 --vm-driver $(MINIKUBE_DRIVER) # wait until the master is up until docker run --rm $(common_mounts) $(DOCKER_RUN_ARGS) $(build_tag) kubectl cluster-info; \ do \ echo "Waiting for cluster to start..."; \ sleep 1; \ done - # this is needed for kubernetes component to work correctly while RBAC is enabled - -docker run --rm $(common_mounts) $(DOCKER_RUN_ARGS) $(build_tag) \ - kubectl create clusterrolebinding cluster-admin-binding --clusterrole=cluster-admin --serviceaccount=kube-system:default $(MAKE) setup-test-cluster DOCKER_RUN_ARGS="$(DOCKER_RUN_ARGS)" $(MAKE) minikube-post-start diff --git a/site/content/en/docs/Guides/troubleshooting.md b/site/content/en/docs/Guides/troubleshooting.md index 1bf8b8315b..b80924e5c6 100644 --- a/site/content/en/docs/Guides/troubleshooting.md +++ b/site/content/en/docs/Guides/troubleshooting.md @@ -43,11 +43,34 @@ A quick one liner to do this: Once this is done, you can `kubectl delete gs --all` and clean everything up (if it's not gone already). + ## I'm getting Forbidden errors when trying to install Agones +{{% feature expiryVersion="0.12.0" %}} Some troubleshooting steps: 1. Run `kubectl describe clusterrolebinding | grep cluster-admin-binding- -A10` and make sure your email is in there. This may be _case sensitive_ so you may need to compare it to the case you used. 1. In the [GKE tutorial]({{< ref "/docs/Installation#enabling-creation-of-rbac-resources" >}}) `gcloud config get-value accounts` will return a lowercase email address, so if you are using a CamelCase email, you may want to type that in manually. +{{% /feature %}} + +{{% feature publishVersion="0.12.0" %}} +Ensure that you are running Kubernetes 1.12 or later, which does not require any special +clusterrolebindings to install Agones. + +If you want to install Agones on an older version of Kubernetes, you need to create a +clusterrolebinding to add your identity as a cluster admin, e.g. + +```bash +# Kubernetes Engine +kubectl create clusterrolebinding cluster-admin-binding \ + --clusterrole cluster-admin --user `gcloud config get-value account` +# Minikube +kubectl create clusterrolebinding cluster-admin-binding \ + --clusterrole=cluster-admin --serviceaccount=kube-system:default +``` + +On GKE, `gcloud config get-value accounts` will return a lowercase email address, so if +you are using a CamelCase email, you may need to type it in manually. +{{% /feature %}} diff --git a/site/content/en/docs/Installation/_index.md b/site/content/en/docs/Installation/_index.md index a946116c0a..767d06ad79 100644 --- a/site/content/en/docs/Installation/_index.md +++ b/site/content/en/docs/Installation/_index.md @@ -181,12 +181,19 @@ minikube profile agones The following command starts a local minikube cluster via virtualbox - but this can be replaced by a [vm-driver](https://github.com/kubernetes/minikube#requirements) of your choice. +{{% feature expiryVersion="0.12.0" %}} ```bash minikube start --kubernetes-version v1.11.0 --vm-driver virtualbox \ --extra-config=apiserver.authorization-mode=RBAC ``` Continue to [Enabling creation of RBAC resources](#enabling-creation-of-rbac-resources) +{{% /feature %}} +{{% feature publishversion="0.12.0" %}} +```bash +minikube start --kubernetes-version v1.12.10 --vm-driver virtualbox +``` +{{% /feature %}} ## Setting up an Amazon Web Services EKS cluster @@ -280,6 +287,7 @@ Nodes in AKS don't get a Public IP by default. To assign a Public IP to a Node, Continue to [Installing Agones](#installing-agones). +{{% feature expiryVersion="0.12.0" %}} ## Enabling creation of RBAC resources To install Agones, a service account needs permission to create some special RBAC resource types. @@ -292,6 +300,7 @@ kubectl create clusterrolebinding cluster-admin-binding \ kubectl create clusterrolebinding cluster-admin-binding \ --clusterrole=cluster-admin --serviceaccount=kube-system:default ``` +{{% /feature %}} ## Installing Agones