typisttech / sunny

Automatically purge Cloudflare cache, including cache everything rules.
https://typist.tech/projects/sunny
GNU General Public License v2.0
35 stars 3 forks source link

Exclude by post type to trigger a purge #118

Open lukecav opened 7 years ago

lukecav commented 7 years ago

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.

tangrufus commented 7 years ago

Good feature to add.

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

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

lukecav commented 7 years ago

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_.*

tangrufus commented 7 years ago

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

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

lukecav commented 7 years ago

Railgun only works on specific hosts that support it.

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