kill axios #46
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# clears the cache on dromzeh.dev for every push | |
name: Clear Site Cache | |
on: push | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
deployments: write | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Wait for CF Pages # waits for CF pages to finish building | |
id: cf-pages | |
uses: WalshyDev/cf-pages-await@v1 | |
with: | |
apiToken: ${{ secrets.CF_API_TOKEN }} | |
accountId: 'ba4e8f7f9ffbc23dba6acd0d9bd3ef46' | |
project: 'dromzeh-dev' | |
githubToken: ${{ secrets.GITHUB_TOKEN }} | |
- run: | # purges cache on CF | |
curl -X \ | |
-H "Authorization: ${{ secrets.CF_API_TOKEN }}" \ | |
-H "Content-Type: application/json" \ | |
--data '{"purge_everything":true}' \ | |
https://api.cloudflare.com/client/v4/zones/2f0aebc3d15e4c1c38f303de3b34aa1f/purge_cache |