You are here

disable_cache_deliver.html.twig in Fastly 8.3

{% for rule in rules %}
  {% if rule.mode in ['both','browser']  %}
    if (req.url ~ "{{ rule.pattern }}" && fastly.ff.visits_this_service == 0 ) {
      set resp.http.Cache-Control = "no-cache, private";
      unset resp.http.Expires;
      unset resp.http.Pragma;
    }
  {% endif %}
{% endfor %}

File

fastly_edge_modules/templates/disable_cache_deliver.html.twig
View source
  1. {% for rule in rules %}
  2. {% if rule.mode in ['both','browser'] %}
  3. if (req.url ~ "{{ rule.pattern }}" && fastly.ff.visits_this_service == 0 ) {
  4. set resp.http.Cache-Control = "no-cache, private";
  5. unset resp.http.Expires;
  6. unset resp.http.Pragma;
  7. }
  8. {% endif %}
  9. {% endfor %}