My organization is using an external search application. The results are intended to be wrapped in a header and footer to mimic the appearance of the main website.
I've created a couple of custom routes, /wrapper/header and /wrapper/footer, that simply return a (practically) empty page with a partial template. As far as the markup goes, that's working fine; the search app can pull both and wrap them around the results as intended.
However, on the header, we need to use full URL for the aggregated CSS and JS files. I've taken a look at hook_page_attachments_alter(), but that appears to deal with assets attached pre-aggregation. Is there a way for me to override the URLs inserted to replace the placeholders? The CDN module looked promising, but can't be restricted to work on specific routes.