typisttech / sunny

Automatically purge Cloudflare cache, including cache everything rules.

Home Page:https://typist.tech/projects/sunny

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Exclude by post type to trigger a purge

lukecav opened this issue · comments

Currently when a new order is created in WooCommerce, since an order is a custom post type, that will trigger a purge in Cloudflare.

Provide an option to be able to exclude certain post types from causing a purge trigger.

Good feature to add.

For now, you can only remove Sunny from these 2 filters:

  • transition_post_status
  • edit_post

However, using WooCommerce with Cloudflare cache everything rules usually not a good idea.

WooCommerce is fine with page rules in Cloudflare.

https://support.cloudflare.com/hc/en-us/articles/236166048-Caching-Static-HTML-with-WordPress-WooCommerce

Bypass Cache on Cookie
wp-.*|wordpress.*|comment_.*|woocommerce_.*

Are you using the USD $ 200 / month plan (or above)?

If so, check out Cloudflare's Railgun as well.

Railgun only works on specific hosts that support it.

https://www.cloudflare.com/docs/railgun/index.html