Skip to content
Snippets Groups Projects
Verified Commit 3cda202d authored by Chris Coley's avatar Chris Coley
Browse files

Delay the Cloudflare cache purge so that pages:deploy is finished

My tests indicate that the pages:deploy job typically takes 50-60
seconds to complete, so I'm delaying the cache purge for 180 seconds
parent 02913a62
No related branches found
No related tags found
No related merge requests found
...@@ -84,6 +84,7 @@ purge-cache: ...@@ -84,6 +84,7 @@ purge-cache:
for f in $(find public -type f); do FILES="$FILES,\"$CI_PAGES_URL/${f#public/}\""; done; for f in $(find public -type f); do FILES="$FILES,\"$CI_PAGES_URL/${f#public/}\""; done;
FILES="$FILES] }" FILES="$FILES] }"
- echo $FILES - echo $FILES
- sleep 180s # Give pages:deploy time to finish so the old pages don't get re-cached
- >- - >-
wget -qO- "https://api.cloudflare.com/client/v4/zones/$CF_PURGE_CACHE_ZONE/purge_cache" wget -qO- "https://api.cloudflare.com/client/v4/zones/$CF_PURGE_CACHE_ZONE/purge_cache"
--header "Content-Type: application/json" --header "Content-Type: application/json"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment