Building a Granular Technical Blog Pipeline for Four Fleet Sites
This session involved architecting and implementing an automated technical blog generation system across four separate domain properties: queenofsandiego.com, sailjada.com, dangerouscentaur.com, and burialsatseasandiego.com. The goal was to create a mechanism that captures development work at the granular level—tracking specific file modifications, infrastructure changes, and command execution—and automatically generates detailed technical posts for engineering visibility.
Problem Statement
Without a structured technical documentation system, development work across multiple properties becomes invisible to stakeholders. The need was for near-real-time technical blog posts that record granular details: exact file paths modified, infrastructure resources changed, command execution, and architectural decisions. This required automation that would trigger at the end of development sessions without manual intervention.
Architecture Overview
The solution consists of four primary components:
- Session Capture: Claude Code's session transcripts recording all file operations and commands
- Blog Generator: Python tool parsing session data and creating HTML posts
- Infrastructure Layer: S3 buckets, CloudFront distributions, and DNS records for each tech blog domain
- Automation Hook: Stop hook script that triggers on session end, generating and deploying posts
Infrastructure Setup
Each tech blog required its own S3 bucket and CloudFront distribution:
tech-queenofsandiego-comS3 bucket with CloudFront distribution (using existing*.queenofsandiego.comwildcard ACM certificate)tech-sailjada-comS3 bucket with CloudFront distribution (using existing*.sailjada.comwildcard ACM certificate)dc-sitesS3 bucket with existing CloudFront wildcard distribution at dangerouscentaur.com (addedtech.dangerouscentaur.comas additional domain via Route53 CNAME through Namecheap)tech-burialsatseasandiego-comS3 bucket with new CloudFront distribution (ACM cert validation via GoDaddy DNS API, as burialsatseasandiego.com uses GoDaddy nameservers)
DNS configuration varied by registrar:
- Route53 domains: Direct alias records pointing CloudFront distributions
- Namecheap: CNAME records for dangerouscentaur.com tech blog
- GoDaddy: CNAME records for burialsatseasandiego.com, with ACM validation also via GoDaddy DNS API
Core Implementation Files
tech_blog_generator.py — Main parsing and HTML generation engine:
- Parses Claude Code JSONL session transcripts from
~/.claude/sessions/ - Extracts file modifications (paths, operations: create/write/edit)
- Extracts command execution history with parameters (no credential values)
- Organizes findings into HTML post structure with sections for files, commands, decisions, and next steps
- Sanitizes sensitive data: removes credentials, API keys, database passwords, personal identifiers
- Generates timestamped posts with appropriate site slug (qos, jada, dc, bats)
tech_blog_init.py — Infrastructure initialization script:
- Creates S3 buckets with private ACL and versioning enabled
- Provisions CloudFront distributions with appropriate origin configurations
- Handles certificate validation: Route53 for AWS-managed domains, DNS API calls for GoDaddy/Namecheap
- Creates DNS records (alias or CNAME) pointing to CloudFront endpoints
- Stores infrastructure configuration in
~/.claude/projects/memory/infrastructure_config.jsonfor retrieval - Supports dry-run mode for validation before actual resource creation
tech_blog_stop.sh — Claude Code stop hook:
- Triggered automatically when Claude Code session ends
- Invokes blog generator on current session transcript
- Determines target blog(s) based on files modified (matching file paths to site domains)
- Uploads generated HTML to appropriate S3 bucket
- Invalidates CloudFront cache for the tech blog domain
- Logs execution details to
~/.claude/logs/tech_blog_hook.log
Site Integration
Updated queenofsandiego.com/index.html to add "Tech Blog" link in the Ship's Papers navigation dropdown menu, linking to https://tech.queenofsandiego.com/. Similar nav updates would apply to other fleet sites, making technical documentation discoverable alongside operational resources.
Session Data Flow
Claude Code sessions automatically capture all interactions in JSONL format. Each session transcript includes:
tool_useentries for file operations with exact paths and operation typecommandentries with full command text (excluding values for sensitive parameters)- Timestamps for each operation
- User request context and reasoning notes
The blog generator parses these transcripts, groups related operations, and synthesizes them into a narrative technical post with specific infrastructure details, architectural decisions, and technical reasoning.
Credential and Sensitive Data Handling
Critical security measure: all generated posts are sanitized to remove:
- AWS access keys, secret keys, session tokens
- API credentials (GoDaddy, Namecheap, etc.)
- Database passwords and connection strings
- Personal information or email addresses beyond public context
- Specific values for authentication parameters
Commands and file paths are included for technical clarity; only the sensitive values are stripped.
Tested Deployment
All four tech blog sites are now live and serving HTTP traffic:
https://tech.queenofsandiego.com/— CloudFront distribution, Route53 aliashttps://tech.sailjada.com/— CloudFront distribution, Route53 aliashttps://tech.dangerouscentaur.com/— Wildcard CF distribution, Namecheap CNAMEhttps://tech.burialsatseasandiego.com/— CloudFront distribution, GoDaddy CNAME with ACM validation
Test post was generated from this session transcript and deployed to all four sites.
Key Architectural Decisions
- Session-based automation: Avoids need for manual blog post creation; developers focus on work, not documentation
- Granular capture: Post includes specific file