From b2bdf4eb3b40b07915f2d7efca5484a90269106b Mon Sep 17 00:00:00 2001 From: David Zuber Date: Sat, 15 Feb 2020 19:36:30 +0000 Subject: [PATCH] Update to kubernetes 1.17 --- CHANGELOG.md | 8 ++++++++ Dockerfile | 4 ++-- README.md | 20 +++++++++++--------- kind-config.yaml | 6 +++--- manifest/deployment.yaml | 4 ++-- 5 files changed, 26 insertions(+), 16 deletions(-) create mode 100644 CHANGELOG.md diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..4a8422c --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,8 @@ +# 0.2.0 + +* New image storadev/kubedoom:0.2.0 +* Update kubernetes to 1.17.3 + +# 0.1.0 + +* Initial release diff --git a/Dockerfile b/Dockerfile index 52f1a80..61a52ef 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.12-alpine AS gobuild +FROM golang:1.13-alpine AS gobuild WORKDIR /go/src/kubedoom ADD kubedoom.go . @@ -15,7 +15,7 @@ RUN apt-get install -y \ --no-install-recommends \ wget ca-certificates RUN wget http://distro.ibiblio.org/pub/linux/distributions/slitaz/sources/packages/d/doom1.wad -RUN wget -O /usr/bin/kubectl https://storage.googleapis.com/kubernetes-release/release/v1.15.3/bin/linux/amd64/kubectl \ +RUN wget -O /usr/bin/kubectl https://storage.googleapis.com/kubernetes-release/release/$(wget -O- https://storage.googleapis.com/kubernetes-release/release/stable.txt)/bin/linux/amd64/kubectl \ && chmod +x /usr/bin/kubectl FROM ubuntu AS ubuntu-build diff --git a/README.md b/README.md index a270b25..5370297 100644 --- a/README.md +++ b/README.md @@ -13,13 +13,13 @@ which was forked from psdoom. ## Usage -Run `storaxdev/kubedoom:0.1.0` locally: +Run `storaxdev/kubedoom:0.2.0` locally: ```console $ docker run -p5900:5900 \ -v ~/.kube:/root/.kube \ --rm -it --name kubedoom \ - storaxdev/kubedoom:0.1.0 + storaxdev/kubedoom:0.2.0 ``` Now start a VNC viewer and connect to `localhost:5900`. The password is `1234`: @@ -41,17 +41,19 @@ example config from this repository: ```console $ kind create cluster --config kind-config.yaml Creating cluster "kind" ... - ✓ Ensuring node image (kindest/node:v1.15.0) đŸ–ŧ - ✓ Preparing nodes đŸ“ĻđŸ“Ļ - ✓ Creating kubeadm config 📜 + ✓ Ensuring node image (kindest/node:v1.17.0) đŸ–ŧ + ✓ Preparing nodes đŸ“Ļ đŸ“Ļ + ✓ Writing configuration 📜 ✓ Starting control-plane đŸ•šī¸ ✓ Installing CNI 🔌 ✓ Installing StorageClass 💾 ✓ Joining worker nodes 🚜 -Cluster creation complete. You can now use the cluster with: +Set kubectl context to "kind-kind" +You can now use your cluster with: -export KUBECONFIG="$(kind get kubeconfig-path --name="kind")" -kubectl cluster-info +kubectl cluster-info --context kind-kind + +Not sure what to do next? 😅 Check out https://kind.sigs.k8s.io/docs/user/quick-start/ ``` This will spin up a 2 node cluster inside docker, with port 5900 exposed from @@ -67,4 +69,4 @@ serviceaccount/kubedoom created clusterrolebinding.rbac.authorization.k8s.io/kubedoom created ``` Kubedoom requires a service account with permissions to list all pods and delete -them and uses kubectl 1.15.3. +them and uses kubectl 1.17.3. diff --git a/kind-config.yaml b/kind-config.yaml index 773b0de..bdd88c9 100644 --- a/kind-config.yaml +++ b/kind-config.yaml @@ -1,10 +1,10 @@ kind: Cluster -apiVersion: kind.sigs.k8s.io/v1alpha3 +apiVersion: kind.x-k8s.io/v1alpha4 nodes: - role: control-plane - image: kindest/node:v1.15.7 + image: kindest/node:v1.17.0 - role: worker - image: kindest/node:v1.15.7 + image: kindest/node:v1.17.0 extraPortMappings: - containerPort: 5900 hostPort: 5900 diff --git a/manifest/deployment.yaml b/manifest/deployment.yaml index 4ee3b6a..f4feeb1 100644 --- a/manifest/deployment.yaml +++ b/manifest/deployment.yaml @@ -1,4 +1,4 @@ -apiVersion: apps/v1beta2 +apiVersion: apps/v1 kind: Deployment metadata: labels: @@ -18,7 +18,7 @@ spec: hostNetwork: true serviceAccountName: kubedoom containers: - - image: storaxdev/kubedoom:0.1.0 + - image: storaxdev/kubedoom:0.2.0 name: kubedoom ports: - containerPort: 5900