Cloud & cost
Count what is running, and price it.
#cloud-costprivate channel3 tool calls
How many machines are running, in which environment, and what they cost. Read from Cloud Monitoring through a read-only service account, grouped by what the machines are for, and priced from their types — with the surprise explained: the “app VMs” were Cloud Run instances.
Mei8:40 AM
@attest_tag how many VMs are running in testing and staging right now, and what do they cost a month?
attest_tagApp8:41 AM
- gcp_query_metrics · compute uptime · testing · last 30m · 10 instances
- gcp_query_metrics · compute uptime · staging · last 30m · 12 instances
- run_js · price by machine type · 2 projects
22 VMs — 10 in testing, 12 in staging — all running and incurring cost.
- Testing: 6 cluster nodes, 2 app instances, 1 NFS server, 1 static webhook host
- Staging: 6 cluster nodes, 5 webhook handlers in an instance group, 1 NFS server
- Rough compute cost across both: about $1,420 a month (testing ≈ $430, staging ≈ $990); the always-on services are most of it
The two “app VMs” in testing are Cloud Run service instances, not machines — billed for the CPU and memory they use, and at a much lower rate while idle.
google/gemini-flash15.7k in720 out$0.0081Configure
How the turn went
Two projects, two queries, priced in the sandbox, with the surprise explained.
- 01
Two projects, two queries
Uptime over the last half hour, per project the connection may read. A project it may not read answers 403, and it says so rather than inventing a number for it.
- 02
Grouping and pricing in the sandbox
Instances go into
run_jswith their machine types; groups and a monthly figure come out. The figure is labelled rough because it is compute only. - 03
The surprise, explained
Names that look like VMs and are not. It checked the logs for the resource type before answering, and the answer says what they are and how they bill.
What it needs
The setup, in the console.
What it will not do
Enforced outside the model.
It cannot stop, resize or delete anything: the presets carry no write. The saving it recommends is a person's to make.
A project the key cannot read stays unread; it will not try another credential.
Try it
Say it in a channel it is in.
The sentence as it was typed. It works in any channel the bot has been invited to that carries the connection above — no command syntax, no form, and follow-ups in the thread need no mention.
@attest_tag how many VMs are running in testing and staging right now, and what do they cost a month?
gcp_query_metricsgcp_query_logsrun_js
More in Cloud & cost
The cloud bill, answered from the metrics.
- Why six are running, and what two would save.#cloud-cost · what are these six webhook instances, why are six running, and what do they cost?
- Find the environments nobody tore down.#cloud-cost · which temporary environments are still up on the testing cluster?
- Arithmetic it works out rather than recalls.#payments · 0.4% of checkout calls timed out. at 225,000 checkouts a day, how many is that per hour, per minute, and over a two-day weekend?
Bring the channel this would live in.
Sign up, connect the service above in one channel, and type this sentence yourself — or run the same binary on your own infrastructure.