Tanzu Mission Control - Deploying Clusters

I’ve written about deploying clusters in the past, but if you are a TMC customer, those steps can be skipped altogether. TMC will let us deploy a Kubernetes cluster and add it to management, all from the GUI or CLI. For this example, I’ll create a new Kubernetes cluster within my AWS account. Before we setup the cluster, we need to configure access to our AWS Account so that TMC can manage resources for us. ...

March 10, 2020 · 3 min · eshanks

Tanzu Mission Control - Namespace Management

When we need to segment resources within a Kubernetes cluster, we often use a namespace. Namespaces can be excellent resources to create a boundary for either networking, role based access, or simply for organizational purposes. It may be common to have some standard namespaces across all of your clusters. Maybe you have corporate monitoring standards and the tools live in a specific namespace, or you always have an ingress namespace thats off limits to developers or something. Managing namespaces across cluster could be tedious, but Tanzu Mission Control lets us manage these namespaces centrally from the TMC console. ...

March 10, 2020 · 3 min · eshanks

Tanzu Mission Control - Resize Clusters

A pretty common task that a Kubernetes administrator must do is to resize the cluster. We need more nodes to handle more workloads, or we’ve overprovisioned a cluster and are trying to save costs. This usually took some custom automation scripts such as node autoscaler, or it was done manually based on request. Tanzu Mission Control can resize our cluster very simply from the TMC portal. Scale Out a Cluster Within the TMC Portal, find the cluster that needs to be resized. Within the cluster screen, find the “Node pools” menu. Node pools define the worker nodes that are part of the Kubernetes cluster thats been deployed. ...

March 10, 2020 · 3 min · eshanks

Use a Private Registry with Kubernetes

Most of the blog posts I write about Kubernetes have examples using publicly available images from public image registries like DockerHub or Google Container Registry. But in the real world, companies use private registries for storing their container images. There are a list of reasons why you might want to do this including: Custom code is inside the container such as business logic or other intellectual property. On-premises private repos provide solutions to bandwidth or firewall restrictions. Custom scanning software is being integrated for vulnerability management. In this post, we’ll setup our Kubernetes cluster to be able to use a private container registry. ...

March 3, 2020 · 3 min · eshanks

Highly Available Envoy Proxies for the Kubernetes Control Plane

Recently I was tasked with setting up some virtual machines to be used as a load balancer for a Kubernetes cluster. The environment we were deploying our Kubernetes cluster didn’t have a load balancer available, so we thought we’d just throw some envoy proxies on some VMs to do the job. This post will show you how the following tasks were completed: Deploy Envoy on a pair of CentOS7 virtual machines. Configure Envoy with health checks for the Kubernetes Control Plane Install keepalived on both servers to manage failover. Configure keepalived to failover if a server goes offline, or the envoy service is not started. Deploy Envoy The first step will be to setup a pair of CentOS 7 servers. I’ve used virtual servers for this post, but baremetal would work the same. Also, similar steps could be used if you prefer debian as your linux flavor. ...

February 24, 2020 · 6 min · eshanks

Kubernetes Logs for Troubleshooting

Sometimes things don’t go quite as we’ve planned. When that happens in a computer system, we turn to the logs to tell us what went wrong, and to give us some clues on either how to fix the issue, or where to look for the next clue.This post focuses on where to look for issues in your Kubernetes deployment. Before we dive into the logs, we must acknowledge that there are different ways to install a kubernetes cluster. The pieces and parts can be deployed as system services or containers, and the way to obtain their logs will change. This post uses a previous post about a k8s install as an example of where to find those logs. ...

February 12, 2020 · 4 min · eshanks

Kubernetes HA on vSphere

If you’ve been on the operations side of the IT house, you know that one of your primary job functions is to ensure High Availability (HA) of production workloads. This blog post focuses on making sure applications deployed on a vSphere Kubernetes cluster will be highly available. The Control Plane Ok, before we talk about workloads, we should discuss the Kubernetes Control plane components. When we deploy Kubernetes on virtual machines, we have to make sure that the brains of the Kubernetes cluster will continue working even if there is a hardware failure. The first step is to make sure that your control plane components are deployed on different physical (ESXi) hosts. This can be done with a vSphere Host Affinity Rule to keep k8s VMs pinned to groups of hosts or anti-affinity rules to make sure two control plane nodes aren’t placed on the same host. After this is done, your Load Balancer should be configured to point to your k8s control plane VMs and a health check is configured for the /healthz path. ...

January 27, 2020 · 7 min · eshanks

Active Directory Authentication for Kubernetes Clusters

You’ve stood up your Kubernetes (k8s) cluster and are really looking forward to all of your coworkers deploying containers on it. How will you get everyone logged in? Creating local service accounts and distributing KUBECONFIG files (securely), seems like a real chore. This post will show how you can use Active Directory authentication for Kubernetes Clusters. This post will use two projects, dex and gangway, to perform the authentication against ldap and return the Kubernetes login information to the user’s browser. The end result will look something like the screen below. The authenticated user will receive instructions on installing the client and setting up certificates for authentication. ...

January 21, 2020 · 11 min · eshanks

Deploy Kubernetes on AWS

The way you deploy Kubernetes (k8s) on AWS will be similar to how it was done in a previous post on vSphere. You still setup nodes, you still deploy kubeadm, and kubectl but there are a few differences when you change your cloud provider. For instance on AWS we can use the LoadBalancer resource against the k8s API and have AWS provision an elastic load balancer for us. These features take a few extra tweaks in AWS. ...

January 13, 2020 · 8 min · eshanks

Deploy Kubernetes on vSphere

If you’re struggling to deploy Kubernetes (k8s) clusters, you’re not alone. There are a bunch of different ways to deploy Kubernetes and there are different settings depending on what cloud provider you’re using. This post will focus on installing Kubernetes on vSphere with Kubeadm. At the end of this post, you should have what you need to manually deploy k8s in a vSphere environment on ubuntu. Prerequisites NOTE: This tutorial uses the “in-tree” cloud provider for vSphere. This is not the preferred method for deployment going forward. More details can be found here for reference. ...

January 8, 2020 · 8 min · eshanks