-
Notifications
You must be signed in to change notification settings - Fork 21
Description
gcloud compute networks create example-ks --subnet-mode custom
gcloud compute networks subnets create ks-nodes --network example-ks --range 10.240.0.0/24
gcloud compute firewall-rules create example-ks-allow-internal --allow tcp,udp,icmp,ipip --network example-ks --source-ranges 10.240.0.0/24
gcloud compute firewall-rules create example-ks-allow-external --allow tcp:22,tcp:6443,icmp --network example-ks --source-ranges 0.0.0.0/0
gcloud compute instances create controller
--async
--boot-disk-size 200GB
--can-ip-forward
--image-family ubuntu-1804-lts
--image-project ubuntu-os-cloud
--machine-type n1-standard-2
--private-network-ip 10.240.0.11
--scopes compute-rw,storage-ro,service-management,service-control,logging-write,monitoring
--subnet ks-nodes
--zone asia-east1-a
--tags example-ks,controller
for i in 0 1 2; do
gcloud compute instances create worker-${i}
--async
--boot-disk-size 200GB
--can-ip-forward
--image-family ubuntu-1804-lts
--image-project ubuntu-os-cloud
--machine-type n1-standard-2
--private-network-ip 10.240.0.2${i}
--scopes compute-rw,storage-ro,service-management,service-control,logging-write,monitoring
--subnet ks-nodes
--zone asia-east1-a
--tags example-ks,worker
done
https://docs.projectcalico.org/getting-started/kubernetes/self-managed-public-cloud/gce