Add refresh cache workflow
This commit is contained in:
parent
9696056337
commit
200474dabf
4 changed files with 29 additions and 1 deletions
|
@ -8,6 +8,9 @@ indent_size=4
|
|||
[*.json]
|
||||
indent_size=2
|
||||
|
||||
[*.yml]
|
||||
indent_size=2
|
||||
|
||||
[*.{kt,kts}]
|
||||
disabled_rules=import-ordering,no-wildcard-imports
|
||||
max_line_length=177
|
||||
|
|
20
.github/workflows/refresh-cache.yml
vendored
Normal file
20
.github/workflows/refresh-cache.yml
vendored
Normal file
|
@ -0,0 +1,20 @@
|
|||
name: Purge cloudflare cache
|
||||
|
||||
on: deployment_status
|
||||
|
||||
jobs:
|
||||
publish:
|
||||
if: github.event.deployment_status.state == 'success'
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: "Call API"
|
||||
uses: indiesdev/curl@v1.1
|
||||
with:
|
||||
method: "POST"
|
||||
url: https://api.cloudflare.com/client/v4/zones/0dd93531047ba376c2a1167f841c2bfd/purge_cache
|
||||
headers: ${{ secrets.custom_headers }}
|
||||
bearer-token: ${{ secrets.bearer_token }}
|
||||
body: '{"files": ["https://messages.wulkanowy.net.pl/", "https://messages.wulkanowy.net.pl/v1.json"]}'
|
||||
accept: 200
|
||||
log-response: false
|
||||
retries: 3
|
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -74,3 +74,5 @@ classes
|
|||
.idea/libraries-with-intellij-classes.xml
|
||||
dist/
|
||||
!dist/favicon.ico
|
||||
.idea/jsonSchemas.xml
|
||||
.idea/kotlinc.xml
|
||||
|
|
|
@ -4,8 +4,11 @@
|
|||
<component name="GradleSettings">
|
||||
<option name="linkedExternalProjectsSettings">
|
||||
<GradleProjectSettings>
|
||||
<option name="delegatedBuild" value="true" />
|
||||
<option name="testRunner" value="GRADLE" />
|
||||
<option name="distributionType" value="WRAPPED" />
|
||||
<option name="externalProjectPath" value="$PROJECT_DIR$" />
|
||||
<option name="gradleJvm" value="corretto-17" />
|
||||
<option name="modules">
|
||||
<set>
|
||||
<option value="$PROJECT_DIR$" />
|
||||
|
|
Loading…
Reference in a new issue