CDN on subdomain only serving images only

We have a subdomain linked to an Azure blob storage account. The public blob items are all jpeg images. we currently don’t have CDN enabled on our domain and it looks like this means we can’t enabled CDN for just a subdomain. My query is, is it possible to enable / workaround having the CDN serve just a subdomain? We haven’t enabled CDN on the main website because we are concerned about unpredictable behaviour when it comes to caching our MVC website content e.g. bundle updates when we deploy etc… it would really be easier to start off just doing CDN for image content only to minimise any risks involved. This question: * seems to answer it in part, but the terms and conditions are confusing because it mentions “paid” account (which we have) but doesn’t make it clear if you should or shouldn’t route images only. Any assistance would be appreciated!

What exactly do you mean by “enabled CDN”?

First of all, Cloudflare is strictly speaking not a CDN but a distributed reverse proxy. Secondly, do you have your domain already on Cloudflare? If you do, and you mean by “enabled” that your hosts simply do not proxy through Cloudflare, you can have most of your hosts :grey: and just the one in question :orange:. However I am not sure that is what you are referring to.

The easiest approach, post your domain and all the hosts you are talking about and what you want to achieve.

1 Like

Hi Sandro, thanks for your reply. You are spot on, we are looking to just have HTTP proxy for the Subdomain (and therefore the CDN capability e.g. caching of content) and not for the main domain. I did see in the DNS control panel that you can change if an entry uses HTTP proxy or not. However currently the domain is set to paused e.g. this message when we go to our Cloudflare dashboard “Web traffic to this website is no longer receiving performance and security benefits. Cloudflare continues to resolve the DNS. You can reactivate Cloudflare for this website at anytime. Resume Cloudflare on Site”. Would I be correct in thinking then that if we untick “HTTP Proxy” option in the DNS control panel for the main domain, but leave the subdomain ticked AND resume from the paused state, the main domain will not be proxied?

You’d need to resume the service, make sure all the hosts you do NOT want to go through Cloudflare are set to :grey: and switch that one host you DO want to go through Cloudflare to :orange:.

So yes, your assumption should be correct.

Thanks Sandro, that clears things up.

This topic was automatically closed after 30 days. New replies are no longer allowed.