Apple App Site Association (AASA) 文件未在 app-site-association.cdn-apple.com 上更新。

huangapple go评论58阅读模式
英文:

Apple App Site Association (AASA) file is not being updated on app-site-association.cdn-apple.com

问题

我的应用有三个不同的环境,分别命名为

  1. int
  2. sbx
  3. prod

以下是我网站服务器上的三个 AASA 文件链接。

  1. https://app.int.croissant.com/.well-known/apple-app-site-association
  2. https://app.sbx.croissant.com/.well-known/apple-app-site-association
  3. https://app.croissant.com/.well-known/apple-app-site-association

以下是相同的三个 AASA 文件在苹果的 CDN 上的链接

  1. https://app-site-association.cdn-apple.com/a/v1/app.int.croissant.com
  2. https://app-site-association.cdn-apple.com/a/v1/app.sbx.croissant.com
  3. https://app-site-association.cdn-apple.com/a/v1/app.croissant.com

我有两个问题。

  1. 我如何使苹果 CDN 失效,以便拉取我的新 AASA 文件?
  2. 我的新 AASA 文件是否看起来支持所有可能的路径?* 是否可以捕获任何路径,例如 /collection/123,/wallet/oauth?code=123,/sign-in

我已经进行了一般的谷歌搜索和文档阅读,但似乎找不到与苹果 CDN 相关的具体信息。

英文:

My app has three separate environments named

  1. int
  2. sbx
  3. prod

Here are my three AASA files on my webservers.

  1. https://app.int.croissant.com/.well-known/apple-app-site-association
  2. https://app.sbx.croissant.com/.well-known/apple-app-site-association
  3. https://app.croissant.com/.well-known/apple-app-site-association

Here are the same three AASA files on Apple's CDN

  1. https://app-site-association.cdn-apple.com/a/v1/app.int.croissant.com
  2. https://app-site-association.cdn-apple.com/a/v1/app.sbx.croissant.com
  3. https://app-site-association.cdn-apple.com/a/v1/app.croissant.com

I have two questions.

  1. How can I invalidate the Apple CDN so that my new AASA files are pulled in?
  2. Do my new AASA files look like they will support all possible paths? Does * capture any path e.g., /collection/123, /wallet/oauth?code=123, /sign-in

I've done the generic Googling and docs reading around this. I can't seem to find anything specifically related to Apple's CDN.

答案1

得分: 0

将我的AASA文件的Cache-Control标头更新为no-cache解决了我的问题。

我使用Next.js,所以这是我的next.config.js,解决了这个问题。

{
  source: "/.well-known/apple-app-site-association",
  headers: [
    { key: "Content-Type", value: "application/json" },
    { key: "Cache-Control", value: "no-cache" },
  ],
}
英文:

Updating my AASA file's Cache-Control header to no-cache fixed this for me.

I use Next.js, so here is my next.config.js that fixed this for me.

 {
    source: "/.well-known/apple-app-site-association",
    headers: [
      { key: "Content-Type", value: "application/json" },
      { key: "Cache-Control", value: "no-cache" },
    ],
  },

huangapple
  • 本文由 发表于 2023年7月6日 21:45:25
  • 转载请务必保留本文链接:https://go.coder-hub.com/76629519.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定