What Bones

AWS

One cloud for everything hosted — the backend, database, sites, storage, email, and AI — defined as code in the repo.

Why one cloud

Everything hosted runs on AWS: one vendor, one bill, one console. That rules out good products elsewhere (Neon, Railway, Render, Resend) on purpose, not on their merits.

What's in use

ServiceUsed forIn development
Amazon S3Uploads, blog bodies and media, avatars, terms, archived logsRustFS in Docker
Amazon SESTransactional emailMailpit in Docker
Amazon BedrockThe chatbot, on Amazon Nova Micro by defaultOllama on your machine

Each one swaps by environment variable. Application code only talks to the standard API, never to the local stand-in.

Email goes through Nodemailer. It sends through SES, or through Mailpit's SMTP server when EMAIL_SMTP_HOST is set.

How production runs

Production is defined in infra/, as three AWS CDK apps in TypeScript. Every merge to main deploys it — see CI/CD.

  • Backend: the backend/Dockerfile image on one EC2 server, behind CloudFront at api.bonesapp.io.
  • Database: Amazon RDS for Postgres, with daily backups copied to a locked vault in a separate account.
  • Sites: the web app, marketing site, blog, and docs, as static files in a private S3 bucket, each on its own CloudFront distribution. The web app routes /api and /trpc to the backend, so sign-in stays same-origin.
  • DNS and certificates: Route 53 and one ACM certificate for bonesapp.io and its subdomains.
  • Accounts: DNS and the sites, backups, and production each live in their own AWS account, under a $150 monthly budget that stops production if it's reached.

Size is one setting. Tier 1, about $33 a month, is what runs now. Tier 2 swaps the server for Fargate behind a load balancer, for about $100. infra/README.md has the tiers, their limits, and the first-time setup.

Used in