> kubectl get nodes
NAME STATUS ROLES AGE VERSION
control-plane-us-central1-a-6phb Ready control-plane 46m v1.28.11
nodes-us-central1-a-03z2 Ready node 44m v1.28.11
> kops get instancegroups
NAME ROLE MACHINETYPE MIN MAX ZONES
control-plane-us-central1-a ControlPlane e2-medium 1 1 us-central1-a
nodes-us-central1-a Node e2-medium 1 1 us-central1-a
Increasing the maxSize and minSize Properties
> kops edit instancegroup nodes-us-central1-a
spec.minSize 1 --> 3
spec.minSize 1 --> 3
Applying the Changes to the Cluster
> kops update cluster --yes
Verifying the Changes
> kubectl get nodes
NAME STATUS ROLES AGE VERSION
control-plane-us-central1-a-k4fs Ready control-plane 4h58m v1.27.15
nodes-us-central1-a-4grk Ready node 3m30s v1.27.15
nodes-us-central1-a-bh3z Ready node 4h53m v1.27.15
nodes-us-central1-a-pnmz Ready node 3m25s v1.27.15
> kops get instancegroups
NAME ROLE MACHINETYPE MIN MAX ZONES
control-plane-us-central1-a ControlPlane e2-medium 1 1 us-central1-a
nodes-us-central1-a Node e2-medium 3 3 us-central1-a
Creating a GCloud Bucket
Basic Cluster Management
kops version v1.27.1 kubectl version v1.24.11
Creating a Cluster with
kops
Deleting a Cluster with
kops
Deploying an Nginx server
Verification
Visiting
EXTERNAL-IP
in web browser verifies thatthat the server is running and exposed.Clean up
Allocating Resources
Checking Available Node Resources
Increasing the Number of Nodes in the Cluster
"An instance group is a collection of virtual machine (VM) instances that you can manage as a single entity." (https://cloud.google.com/compute/docs/instance-groups)
Checking the Current Instance Groups
Increasing the maxSize and minSize Properties
spec.minSize 1 --> 3 spec.minSize 1 --> 3
Applying the Changes to the Cluster
Verifying the Changes
Applying default CPU and Memory Limits/Requests
from "./resources/memory-defaults.yaml":
run:
Sets the default limit for the CPU and Memory to 2 CPUs and 2 Gigabytes of memory respectively.
Changing # of Pod Replicas
Creating the Deployments
Reduce Number of Desired Replicas
Clean up
Running a Static Server in a Pod
Clean up
Version Testing
kops version v1.27.2 kubectl version v1.24.11
kops version v1.27.3 kubectl version v1.24.11
kops version v1.28.0 kubectl version v1.24.11
kops version v1.28.7 kubectl version v1.24.11
kops version v1.29.0 kubectl version v1.24.11
kops version v1.29.2 kubectl version v1.24.11