The failure that actually bites people here isn’t the upload, it’s the images that only break on a phone-sized viewport because one srcset variant never made it to cloud storage. A spot check on desktop won’t catch that.
Migrations
Migrate a large media library to cloud storage and a CDN
A media-offload plan for moving a large image library to S3-style storage behind a CDN, covering serialized URL rewrites, orphaned file detection, and responsive srcset breakage.
Works with Claude / GPT158 uses★ 4.1
The prompt
migrations-media-library-to-cloud-storage-cdn
The wp-content/uploads folder on [clientsite.com] has grown to [60GB] across roughly [40,000] image files (mostly product photos accumulated over several years), and the host is threatening to charge overage fees. I want to move this to [DigitalOcean Spaces] behind a CDN, keeping the site itself on its current host. Plan this migration to avoid the failure modes that only show up after go-live, covering what a plugin's own setup wizard won't warn about: 1. Reference rewriting: since existing post content and postmeta reference the current local URL structure (some in plain HTML, some inside serialized page builder JSON), explain how the offload plugin actually handles rewriting these versus what it leaves untouched, and where a serialized-data-unsafe rewrite could corrupt content. 2. Orphan detection: how to cross-check the actual files in wp-content/uploads against what the database's postmeta attachment records reference, since after years of accumulation there are usually files on disk with no database record (safe to skip) and database records pointing to files that no longer exist (need to be fixed or the image will 404 after migration either way). 3. Fallback and local-copy decision: whether to keep local copies as a fallback if the CDN has an outage, versus deleting local files entirely to actually solve the disk space problem, and the tradeoff between resilience and the disk-space savings that was the point of doing this. 4. Responsive images: WordPress generates multiple resized versions (thumbnail, medium, large, srcset variants) for every image. Explain how to confirm all of these variants get uploaded to cloud storage, not just the full-size original, since a missed variant shows up as a broken image only on specific screen sizes, making it easy to miss in a quick spot check. 5. Cache and hotlink settings: what CDN cache-control headers and hotlink protection settings need configuring so images load fast for real visitors without breaking for legitimate embeds (like the site's own admin previewing content). Give me a verification method that would catch a missing responsive image variant, since that's the failure mode a quick homepage check won't reveal.