我正在我的iOS应用程序中设置应用程序剪辑功能,我已经为该应用程序创建了一个apple应用程序站点关联文件,并将其放置在/.well-known/目录中。
我将content-type设置为application/json,如下所示:
server {
...
location /.well-known/apple-app-site-association {
default_type application/json;
}
}我还尝试强制设置内容类型,如下所示:
server {
...
location /.well-known/apple-app-site-association {
types { } default_type "application/json; charset=utf-8";
}
}但是,当我使用命令行卷曲它时,我得到的content-type是text/html。
我正在使用以下curl命令:
curl -v https://your_domain.com/apple-app-site-association
请指导我在nginx配置上为apple-app-site-association文件设置content-type的正确方法。
谢谢!
发布于 2021-08-19 03:23:43
这是我为AASA文件添加到我的server块中的部分:
location ~ "^/apple-app-site-association$" {
default_type application/json;
}https://stackoverflow.com/questions/67899230
复制相似问题