How do I change the legacy CDN URLs of images in posts?

I have already changed the CDN URL in app.yml and rebuilt discourse, but the legacy URLs will not be affected, right?
Seems the link is what I’m looking for; I will try it once the backup is done. Thanks for the info!