Share via

Azure web app - Cache-control: Private

PatricS 61 Reputation points
May 14, 2020, 8:14 AM

Hi!

When enabling cache in frontdoor, it caches my wordpress sites backend/wp-admin.
How and where am i suppose to put cache-control: private ?
Do i put it in web.config?

Br
Pat

Azure Front Door
Azure Front Door
An Azure service that provides a cloud content delivery network with threat protection.
726 questions
Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,178 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Ryan Hill 29,561 Reputation points Microsoft Employee
    May 14, 2020, 10:40 PM

    Hi @PatricSten,

    Correct, you can add your cache control as a rewrite action in your web.config of your wordpress site.

    <rule name='AdjustCache'>
    <match serverVariable='RESPONSE_CACHE_CONTROL' pattern='.*' />
    <action type='Rewrite' value='no-cache, no-store, must-revalidate' />
    </rule>
    

    Let me know if this helps.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.