Design Decisions
This page documents the architectural decisions that shaped the Antora Themes Gallery.
The Problem
We wanted to create a site that:
-
Indexes Antora themes from the community
-
Shows live previews of each theme
-
Lets theme developers submit their work easily
Approach 1: Centralized Builds (Rejected)
The initial design considered building theme previews on our servers:
How It Would Work
-
Developer submits repository URL
-
Our server clones the repo
-
Runs
gulp bundleto build the UI -
Runs Antora with sample content
-
Hosts the result
Why We Rejected It
| Issue | Details |
|---|---|
Security Risk |
Running untrusted Handlebars templates and build scripts = potential RCE |
Compute Costs |
Every theme submission triggers a build job |
Maintenance Burden |
Need to maintain Docker workers, job queues, etc. |
Inconsistency |
Different Node versions, build failures, etc. |
Approach 2: Decentralized Previews (Adopted)
Instead, we offload builds to the developer’s repository:
How It Works
-
Developer sets up GitHub Actions in their repo
-
Action builds theme and deploys to GitHub Pages
-
Action generates
preview.pngscreenshot -
Developer submits repo URL to gallery
-
Gallery stores metadata and links
Comparison
| Feature | Centralized | Decentralized |
|---|---|---|
Compute Cost |
We pay |
Developer pays (free) |
Security |
High risk |
Zero risk |
Maintenance |
Complex |
Simple |
Consistency |
100% |
Variable |
References
The original design discussion:
-
Gemini conversation exploring both approaches