Simple, fast, and reliable CV hosting using GitHub Pages, Cloudflare, and Mozilla's PDF.js.
- English: sveinbjorn.dev
- Íslenska: sveinbjörn.is
├── index.html # PDF.js viewer wrapper
├── SveinbjornGeirsson.pdf # CV document
├── CNAME # Custom domain configuration
└── README.md # This file
This setup provides a zero-cost, highly available CV hosting solution:
- Hosts static files (HTML + PDF)
- Provides baseline availability and global CDN
- Automatic HTTPS for
*.github.iodomains
- CNAME Flattening: Enables root domain (
sveinbjorn.dev) to point to GitHub Pages - Global CDN: Worldwide caching and edge delivery
- Enhanced HTTPS: SSL/TLS termination and security features
- Analytics & Performance: Real-time insights and optimization
- Client-side PDF rendering via
mozilla.github.io/pdf.js - No server-side processing required
- Full-featured PDF viewer with navigation, zoom, search
- Works across all modern browsers
The index.html file is a minimal wrapper that:
- Loads Mozilla's hosted PDF.js viewer
- Passes the PDF URL as a parameter
- Provides a clean, full-screen viewing experience
PDF.js URL structure:
https://mozilla.github.io/pdf.js/web/viewer.html?file=${encodeURIComponent(pdfUrl)}
- Zero hosting costs (GitHub Pages + Cloudflare free tiers)
- Maximum uptime (dependent only on GitHub + Cloudflare)
- Global performance (CDN edge caching worldwide)
- Automatic HTTPS (SSL/TLS encryption)
- No maintenance (static files, no server management)
- Professional features (custom domains, analytics)
- Push changes to the
mainbranch - GitHub Pages automatically deploys updates
- Cloudflare invalidates cache and serves new content globally
- Changes are live within minutes
The CNAME file contains the custom domain, enabling GitHub Pages to serve content at:
sveinbjorn.dev(English version)sveinbjörn.is(Icelandic version)
Cloudflare DNS is configured with CNAME flattening to point the root domains to the respective GitHub Pages URLs.
This architecture demonstrates a modern, cost-effective approach to hosting professional documents with enterprise-grade reliability and performance.