Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What web.config setting will allow apple-app-site-association to be served?

I have added the apple-app-site-association file to the root of a website, but IIS is not delivering the file.

What is the best way to make the server serve this specific file without a file extension? Is there a way within a web.config to explicitly say "serve this file"?

like image 651
ToddBFisher Avatar asked Jan 13 '17 15:01

ToddBFisher


People also ask

How do I add an apple app association to a website?

To add the associated domain file to your website, create a file named apple-app-site-association (without an extension). Update the JSON code in the file for the services you support on the domain. For universal links, be sure to list the app identifiers for your domain in the applinks service.

Does apple-app-site-Association need to be signed?

As of iOS 9 developer seed 2, you no longer need to sign the apple-app-site-association file for Universal links.

How do I host an AASA file?

Hosting the AASA File on Your Domain Once you are ready with your AASA file, you can now host it on your domain either at https://<<yourdomain>>/apple-app-site-association or at https://<<yourdomain>>/.well-known/apple-app-site-association. Upload the apple-app-site-association file to your HTTPS web server.


1 Answers

I was having the same issue and found this amazing post:

Serving apple-app-site-association from IIS IIS only serves files of known types, defined by their file extension. Since apple-app-site-association doesn’t include a file extention, IIS throws a 404 error, when I try to open it with a browser. I fixed this by adding a mimeMap in the web.config file:

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <system.webServer>
    <staticContent>
      <!-- required for apple-app-site-association: -->
      <mimeMap fileExtension="." mimeType="application/json" />
    </staticContent>
  </system.webServer>
</configuration>
like image 165
mogile_oli Avatar answered Sep 18 '22 05:09

mogile_oli