diff --git a/layouts/robots.txt b/layouts/robots.txt index 16e4cdf6..d26b6e68 100644 --- a/layouts/robots.txt +++ b/layouts/robots.txt @@ -1,5 +1,6 @@ User-Agent: * {{- if eq hugo.Environment "production" }} +Allow: /.well-known/amphtml/apikey.pub Disallow: /403.html Disallow: /404.html diff --git a/netlify.toml b/netlify.toml index 60ca150c..a263723c 100644 --- a/netlify.toml +++ b/netlify.toml @@ -54,6 +54,13 @@ Content-Type = "text/plain; charset=UTF-8" Content-Disposition = "inline; filename=\"jarvis.asc\"" +# AMP cache invalidation key requirements +# https://developers.google.com/amp/cache/update-cache#update-cache-guidelines +[[headers]] + for = "/.well-known/amphtml/apikey.pub" + [headers.values] + Content-Type = "text/plain; charset=UTF-8" + # Redirect Netlify and www subdomains to primary domain: [[redirects]] from = "https://jakejarvis.netlify.com/*" diff --git a/static/.well-known/amphtml/apikey.pub b/static/.well-known/amphtml/apikey.pub new file mode 100644 index 00000000..43a6a67c --- /dev/null +++ b/static/.well-known/amphtml/apikey.pub @@ -0,0 +1,9 @@ +-----BEGIN PUBLIC KEY----- +MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA1upnHtc/v97NGGvSFiJ6 +Krddk+u62ZiZiNjU+urVfBYNZe4H+SDgfmSwi/AEpa3C5O9U0bInGlNJUvL5FYNo +Wjrg8/ZFZ0mkGwe9GqCw/ipeYBiBovIPoWpoHLts5KRLMGro4/gWfivcYFi9+gm8 +x4rbGOgMdQf+p86vxMlo/waeKD3YV1+YOqJDTGib0e9JqZH/RavRPwcp+1kMExYv +DHvpcBnZdg16663mjGGiG4IPS3KzwL7cXxryywPmt/yg/fSh63h2W5MMOKoevjr0 +oZbUNEEjepvuYq0aAcK3Ce33cSKgkHv67Ir/3TDgfAi4l4VgIZm0JZd2W5OwvcvN +/QIDAQAB +-----END PUBLIC KEY----- diff --git a/yarn.lock b/yarn.lock index aeb50d8f..9d642355 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2312,7 +2312,7 @@ https-proxy-agent@^4.0.0: "hugo-extended@git+https://github.com/jakejarvis/hugo-extended.git#master": version "0.63.2" - resolved "git+https://github.com/jakejarvis/hugo-extended.git#32b8bb651270c3875f75160ef8fa375b2951aac9" + resolved "git+https://github.com/jakejarvis/hugo-extended.git#f6b20c2deeabdc9d45f49ee9cfa3f8d7c704737a" dependencies: bin-wrapper "^4.1.0" rimraf "^3.0.1"