Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit93906b9

Browse files
committed
Check for OK status when purging Fastly
In a similar vein to26ec51c, we shouldalso make output from Fastly less verbose by checking for an "ok" responsestatus.
1 parent26ec51c commit93906b9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎cdn.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ def fastly_purge(*args):
1111
hostnames_to_purge= ['www.gov.uk','assets.digital.cabinet-office.gov.uk']
1212
forgovuk_pathinargs:
1313
forhostnameinhostnames_to_purge:
14-
run("curl -s -X PURGE -H 'Host: {0}' {1}{2}".format(hostname,govuk_fastly,govuk_path.strip()))
14+
run("curl -s -X PURGE -H 'Host: {0}' {1}{2} | grep 'ok'".format(hostname,govuk_fastly,govuk_path.strip()))
1515

1616
@task
1717
defpurge_all(*args):

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp