AWS Copilot CLI, the Good the Bad, and the Results.
Tags: aws, devops, webdev, javascript
Published: 2024-01-27 20:03:11

Let's face it, deployments of web apps are variable and complex. With so many platforms to deploy to, and opinionated guides on a "best approach", it's easy to spend more time doing research than achieving results. As an experienced web developer and colleague, I feel your pain and understand the dilemma, especially since what is considered BCP today, is also guaranteed to be obsolete in `x` years as technology continues down its inexorable ascent of progress.

As a developer who'd rather spend more time adding features or fixing bugs than managing configuration around deployments, I was happy to hear about [AWS Copilot CLI](https://aws.github.io/copilot-cli/). If they could come through on their claim I'd be happy.

> Focus your time on writing business logic instead of connecting AWS resources.

## The Good

AWS Copilot CLI lived up to it's claim, at least in my experience. If you are comfortable working within a CLI and willing to explore the available options and documentation (which is pretty stellar despite [my complaints](https://github.com/aws/copilot-cli/issues/4960#issuecomment-1890474052)) then you'll be a satisfied customer.

You don't need to learn a particular configuration DSL like [CloudFormation](https://docs.aws.amazon.com/cloudformation/) to deploy a full-stack web application. Learn the ins-and-outs of Copilot CLI (`copilot --help`), seek help on their [GitHub Issues](https://github.com/aws/copilot-cli/issues) when necessary, and you'll be deployed on the AWS cloud in no time, and back to adding features to your application.

I would be remiss if I didn't mention that you need to be familiar with concepts like an [Application Load Balancer](https://docs.aws.amazon.com/elasticloadbalancing/latest/application/introduction.html), and [Storage Addons](https://aws.github.io/copilot-cli/docs/developing/storage/), etc., but grasping these basic concepts pales in comparison to learning a new dialect or managing their associated configuration files that evolve with time. The power of the AWS networking infrastructure is at your fingertips and wielded with a few `copilot env` or `copilot svc` commands.

## The Bad

The Aurora storage options offered with AWS Copilot CLI [are expensive](https://www.google.com/search?q=aurora+v2+too+expensive), there's no way around it.  If you want to use the latest `v2` with an engine of PostgreSQL (probably similar with MySQL) you are going to [pay a minimum of around $40/mo](https://ldoughty.com/2022/05/exploring-aws-aurora-serverless-v2-for-cheap-wordpress-usage/). Even if your database sits mostly at rest, particularly in a development or staging environment.

Things get a bit better with `v1`, which can actually scale down to zero, but [`v1` is EOL this 12/31/2024](https://stackoverflow.com/a/74992973/258174). I've personally [let my feelings be known](https://github.com/aws/copilot-cli/issues/4960#issuecomment-1895909360) about this, and it couldn't hurt for others to do the same if you feel similarly slighted in your available offerings.

## The Results

The expensive pricing notwithstanding, the service AWS Copilot CLI offers is pretty great. I was able to deploy [Busmap](https://try.busmap.online/) with ease, a full-stack web application providing real-time arrival and departure times for bus stops in North and South American transit agencies. Rolling out new deployments is also seamless, things just work.

Overall, I would recommend AWS Copilot CLI.

If you ever need to catch a bus and want to know when your vehicle is arriving, check out Busmap at https://try.busmap.online. It is backed by the security, reliability, and availability of the AWS infrastructure, thanks to AWS Copilot CLI. Busmap source code is [hosted on GitHub](https://github.com/morganney/busmap).