I’m experiencing the exact same symptoms, except I’m using AWS S3 as my CDN. Works great, uploads to S3, show the images from S3 on the front-end, but all the image links in the Media Gallery are not being re-written and are instead pointing to non-existant files on the local host.