Rename the command (and test) to admin:MigrateLocalS3MediaURL to reflect its
scope: rewriting stale S3/cloud media URLs only. Remove avatar handling and
the --avatars option; the command now focuses solely on status media
(cdn_url, thumbnail_url, optimized_url).
{id? : A status id (or post URL) to fix; omit with --all}
{--all : Scan every local media row and fix any with a stale host}
{--avatars : Also rebuild stale avatar cdn_urls (implied by --all)}
{--oldDomain= : Only rewrite URLs whose host matches this old backend (default: rewrite all stale hosts)}
{--newDomain= : Target host to rewrite to (default: the configured cloud disk host from .env)}
{--dry-run : Report what would change without writing}
@ -33,7 +30,7 @@ class MigrateLocalMediaURL extends Command
*
* @var string
*/
protected $description = 'Rebuild stale local media URLs (cdn_url, thumbnail_url, optimized_url, avatars) from their storage paths using the configured cloud disk. Replaces media:cloud-url-rewrite.';
protected $description = 'Rewrite stale local media cloud URLs (cdn_url, thumbnail_url, optimized_url) from their storage paths to the configured S3/cloud host. Replaces media:cloud-url-rewrite.';
/**
* The target host to rewrite URLs to.
@ -91,10 +88,9 @@ class MigrateLocalMediaURL extends Command