Last active
January 15, 2019 21:13
-
-
Save kwyn/54b03961432fe3af478f802cf114af87 to your computer and use it in GitHub Desktop.
Regional Autoscaling for GKE using Google Deployment Manager
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
resources: | |
- name: provision-test | |
# type: container.v1beta1.cluster | |
type: gcp-types/container-v1beta1:projects.locations.clusters | |
properties: | |
# Region that the cluster will be deployed to | |
parent: 'projects/kwyn-testbed/locations/us-west1' | |
cluster: | |
loggingService: logging.googleapis.com | |
initialClusterVersion: "1.11.5-gke.5" | |
currentMasterVersion: "1.11.5-gke.5" | |
nodePools: | |
- name: "provision-test-np-1" | |
# auto-upgrade node images and auto repair bad nodes | |
management: | |
autoUpgrade: true | |
autoRepair: true | |
# Autoscaling enabled for the given node pool | |
autoscaling: | |
enabled: true | |
minNodeCount: 1 | |
maxNodeCount: 100 | |
# Initial Node Count of 2 will result in a 6 node cluster initially for us-west1 | |
# since there's 3 AZs in use-west1 that means 2 nodes per AZ = 6 nodes | |
initialNodeCount: 2 | |
version: "1.11.5-gke.5" | |
config: | |
machineType: "n1-standard-2" | |
# Oath scopes avaiable to the nodes. Logging and monitoring are always needed since we plan to use all google logging capabilities. | |
oauthScopes: | |
- https://www.googleapis.com/auth/logging.write | |
- https://www.googleapis.com/auth/monitoring | |
# Preemptable means that google can oust our process from the machine in these node pools. | |
# We should have a hard minimum of 2 machines at a time of we keep this true in prod. | |
# It's cheaper for testing purposes though. | |
preemptible: true |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment