Add Gandalf Bunny infrastructure gateway
All checks were successful
Test / test (push) Successful in 8s
All checks were successful
Test / test (push) Successful in 8s
This commit is contained in:
parent
484abbeadd
commit
dec3f970f3
3 changed files with 4 additions and 4 deletions
|
|
@ -37,7 +37,7 @@ jobs:
|
|||
with:
|
||||
directory: dist
|
||||
storage-zone: example-org
|
||||
purge-endpoint: https://tionis-static-site-purge.bunny.run
|
||||
purge-endpoint: https://gandalf.bunny.run
|
||||
env:
|
||||
BUNNY_STORAGE_PASSWORD: ${{ secrets.BUNNY_STORAGE_PASSWORD }}
|
||||
```
|
||||
|
|
|
|||
|
|
@ -278,8 +278,8 @@ def purge_bunny_gateway(endpoint: str, zone: str, password: str) -> None:
|
|||
):
|
||||
raise DeployError("BUNNY_PURGE_ENDPOINT must be an HTTPS origin without a path")
|
||||
url = (
|
||||
f"https://{parsed.hostname}/v1/purge/"
|
||||
f"{urllib.parse.quote(zone, safe='')}"
|
||||
f"https://{parsed.hostname}/v1/static-sites/"
|
||||
f"{urllib.parse.quote(zone, safe='')}/purge"
|
||||
)
|
||||
request = urllib.request.Request(
|
||||
url,
|
||||
|
|
|
|||
|
|
@ -196,7 +196,7 @@ class StaticSiteTests(unittest.TestCase):
|
|||
request = urlopen.call_args.args[0]
|
||||
self.assertEqual(
|
||||
request.full_url,
|
||||
"https://purge.example/v1/purge/example-org",
|
||||
"https://purge.example/v1/static-sites/example-org/purge",
|
||||
)
|
||||
self.assertEqual(request.method, "POST")
|
||||
self.assertEqual(
|
||||
|
|
|
|||
Loading…
Reference in a new issue