· 1 min read
How this site is built
Three static sites, one repo, one design system, with big files on Cloudflare R2. The whole setup and why.
This site is really three sites: a personal hub, an academic page and this blog. They share one codebase and one design. Here’s how the pieces fit together.
The layout
flowchart LR
repo[(GitHub repo)] --> pages[Cloudflare Pages]
pages --> main[muztahidabrar.com]
pages --> acad[academic.muztahidabrar.com]
pages --> blog[blog.muztahidabrar.com]
r2[(Cloudflare R2)] --> files[files.muztahidabrar.com]
files -. images, PDFs .-> main & acad & blog
Each site is a separate Astro app in an npm workspace. A shared @ma/ui
package holds the layout, header, theme and a few components, so a change there shows up
everywhere.
Where files live
The rule is simple: if it’s small and part of the page, it goes in git. If it’s big, it goes in R2.
| What | Where |
|---|---|
| Icons, small SVG diagrams | repo (public/ or next to the post) |
| Photos, paper PDFs, CV, layout screenshots | R2 → files.muztahidabrar.com |
| Video | YouTube embed |
Uploading is one command:
npm run upload -- ./photos/bench.jpg blog/2026/how-this-site-is-built
# → resizes, converts to WebP, uploads, prints the Markdown to paste
Writing posts
Posts are plain Markdown with a small header. Math works inline, like , and as blocks:
Code is highlighted at build time, so no JavaScript is needed to read a post:
def parallel(*rs: float) -> float:
"""Equivalent resistance of resistors in parallel."""
return 1 / sum(1 / r for r in rs)
Why static
No server, no database and nothing to patch. The whole site is files on a CDN. If I ever change the tooling, the posts are just Markdown and move with me.