Hi.
I'm trying to setup a Committed Use Discount in Compute Engine but it fails with the error:
(Creating commitment "commitment-1" failed. Error: invalid value for type Long)
I get this regardless of commitment name. These are the only other variables.
Anyone have any ideas what the problem is?
Thanks,
Christian.
OK, putting this through via gcloud produces a little more info about the error.
ERROR: (gcloud.compute.commitments.create) argument --resources: invalid <googlecloudsdk.calliope.arg_parsers.ArgDict object at 0x000001AB8991FB80> value: 'vcpu=0.25,memory=1GB'
So, it's a problem with the VCPU. A web search found a Reddit post with similar issues. Turns out that, although an E2 Micro will use 0.25 of a VCPU commitment, you can only purchase a minimum 1 VCPU. So a, E2 commitment is only worth it if you have E2 instances totalling at least 1 VCPU.
The ideal would be the Free Tier as my instance only runs a low traffic website. However, I'm unwilling for it to be hosted on a (required) US server as 99% of traffic is in Finland, so response times would be impacted.