Launches!

Cost Optimizations to reduce your dev cloud bill by up to 94%

Nader Khalil

October 20, 20226 read

Today we’re launching a simple CLI to optimize costs on dev infrastructure. You can use it immediately on your existing dev infrastructure with a simple installation. Our users have already reduced their dev AWS bills by up to 94%, which is of particular value to AI developers who are coding on remote environments to access powerful GPUs

While we heavily believe in remote development, it is significantly more expensive than it needs to be because:

  1. unused compute still has to be paid for
  2. spot instances are drastically cheaper but are not reliable and make for a poor experience
  3. storage volumes/hard drives have to be paid for even when the machine using them is stopped
  4. moving a dev environment isn’t a realistic endeavor, so a GPU is often being paid for when a CPU would suffice

The Brev CLI optimizes your instances to handle these 4 cases reducing dev environment cloud bills by up to 94%. Here’s a quick walkthrough of how the optimizations work and how much money each optimization saves. For this blog post, I’ll base the calculations on the g5.2xl instance that our stable diffusion template uses, which costs $1.45/hour. Usage metrics show, on average, a full-time developer leaves this running for 320 hours per month.

img

1.Unused compute still has to be paid for

The simplest optimization is powering down the instance when it’s no longer in use. Brev does this automatically after 1 hour of inactivity (measured via SSH traffic). To continue where you left off, simply restart it by running “brev start” in your terminal. This alone saves on average, 40% of compute time. Lunches, dinners, and forgetting to turn off your instance at night will no longer cost you money. This saves $185.60 here.

img

2.spot instances are drastically cheaper but are not reliable

Brev makes working with spot instances feasible by automatically finding a new spot instance if yours gets pre-empted, copying over your dev environment, and quickly mounting a snapshot of the volume so your work is uninterrupted. This happens behind the scenes without you needing to think about it. This is saving our users about 66% per hour of compute, or $183.74 here with autostop turned on, or $278.40 alone.

img

3.storage volumes/hard drives have to be paid for even when the instance using them is stopped

Even when your instance is stopped, it costs about $0.08 per gigabyte of storage. An instance might only utilize 1GB of a 64GB volume. When you stop your instance with Brev, we snapshot it, so you only pay for the used storage volumes. In this case, you’d save $0.08 * 63 = ~$5 per instance.

img

And finally,

4.moving a dev environment isn’t a realistic endeavor, so a GPU is often being paid for when a CPU would suffice

The Brev CLI has a scale command, which lets you move your dev environment to cheaper hardware when the GPU isn’t needed. Assuming you can use this for 20% of your uptime, you can move from the $1.45/hour instance to a $0.10/hour instance. This alone reduces the hourly rate by 93%. Add Brev spot instances, and the adjusted hourly rate will only cost $0.04/hour. This saves $28.99 here or $86.40 when used alone.

img

You can immediately start saving by installing Brev on your existing dev environments without making an account! If you create an account, you’ll get access to CLI commands to manage dev infra quickly, brev open to automatically SSH into your instances, and get the latest optimization updates!


See how much Brev can save you and your team. 👇

How much can you save?

These numbers are an example of how much you can save running the Stable Diffusion post on Brev. Add your own numbers to see your situation.

$
USD
%
%

*including when it is mistakenly left on

Cost Without Brev: $0

Cost With Brev: $0

NaN% cheaper

Wanna talk to sales? Book time here with our CEO, Nader.