Search code examples
asp.net-coregoogle-app-enginegoogle-cloud-platform

VM-based automatic scaling should NOT have the following parameter. standard_scheduler_settings.max_instances


After a hefting bill from leaving my project turn on for 7 days in GCloud i decided to look for an explanation. I found that app.yaml wasnt configure so that it uses the basic minimum spec. So i found this solution
I am trying to deploy asp .net core app into GAE using gcloud app deploy but i am facing this issue! What i am doing wrong here as i think i am following the correct syntax as in the google docs https://cloud.google.com/appengine/docs/flexible/dotnet/reference/app-yaml

enter image description here

app.yaml

runtime: aspnetcore
env: flex
automatic_scaling:
  min_num_instances: 0
  max_num_instances: 1
  cool_down_period_sec: 180
  cpu_utilization:
    target_utilization: 0.6
  target_concurrent_requests: 100
resources:
  cpu: 1
  memory_gb: 0.5
  disk_size_gb: 10

I tried this version from Pricing of Google App Engine Flexible env, a $500 lesson but i manage to get it to work on the first try but after following deployment i kept getting the same error above.

The version that work the first time round

runtime: aspnetcore
env: flex
instance_class: F1
automatic_scaling:
  max_instances: 1
  min_instances: 0
resources:
  cpu: 1
  memory_gb: 0.5
  disk_size_gb: 10

Solution

  • This configuration seems to work in the end and i found out that i cannot set min_num_instances to 0

    runtime: aspnetcore
    env: flex
    instance_class: F1
    automatic_scaling:
      min_num_instances: 1
      max_num_instances: 1
      cool_down_period_sec: 180
      cpu_utilization:
        target_utilization: 0.6
      target_concurrent_requests: 100
    inbound_services:
    - warmup
    resources:
      cpu: 1
      memory_gb: 0.5
      disk_size_gb: 10