How can I debug an Apple Enterprise Deployment by manifest?

915 views Asked by At

I'm trying to deploy an app thorough a manifest file. After clicking on button in Safari, nothing happens, no error, just loading. My manifest looks like this:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
  <!-- Array der Downloads. -->
  <key>items</key>
  <array>
   <dict>
    <!-- Array der zu ladenden Ressourcen -->
     <key>assets</key>
      <array>
       <!-- Softwarepaket: die zu installierende ipa-Datei. -->
        <dict>
         <!-- Pflicht: die Art der Ressource. -->
          <key>kind</key>
          <string>software-package</string>
          <!-- Pflicht: die URL der zu ladenden Datei. -->
          <key>url</key>
          <string>%url%</string>
        </dict>
      </array><key>metadata</key>
      <dict>
       <!-- Pflicht -->
       <key>bundle-identifier</key>
       <string>%bundleIdentifier%</string>
       <key>bundle-version</key>
       <string>%bundleVersion%</string>
       <!-- Pflicht: die Art des Downloads. -->
       <key>kind</key>
       <string>software</string>
       <!-- Pflicht: der beim Download anzuzeigende Titel. -->
       <key>title</key>
       <string>%title%</string>
      </dict>
    </dict>
  </array>
</dict>
</plist>

EDIT 1

My link looks like this:

<a href="itms-services://?action=download-manifest&amp;url=https://someSite.de/applications/557170c4ffcb521300cacb59/versions/557170e7ffcb521300cacb5a/manifest.plist?access_token=g3hf32v8h5bfeg4t50zfepwzrb9w8b3rv9382va0we7352635baivo" target="_blank" translate="INSTALL" class="ng-scope">Installieren</a>

EDIT 2

This is one of my plists:

<plist version="1.0">
<dict>
<!--  Array der Downloads.  -->
<key>items</key>
<array>
<dict>
<!--  Array der zu ladenden Ressourcen  -->
<key>assets</key>
<array>
<!--  Softwarepaket: die zu installierende ipa-Datei.  -->
<dict>
<!--  Pflicht: die Art der Ressource.  -->
<key>kind</key>
<string>software-package</string>
<!--  Pflicht: die URL der zu ladenden Datei.  -->
<key>url</key>
<string>
https://someSite.de/applications/557170c4ffcb521300cacb59/versions/557170e7ffcb521300cacb5a/app.ipa?access_token=g3hf32v8h5bfeg4t50zfepwzrb9w8b3rv9382va0we7352635baivo
</string>
</dict>
</array>
<key>metadata</key>
<dict>
<!--  Pflicht  -->
<key>bundle-identifier</key>
<string>com.someSite</string>
<key>bundle-version</key>
<string>0.0.1</string>
<!--  Pflicht: die Art des Downloads.  -->
<key>kind</key>
<string>software</string>
<!--  Pflicht: der beim Download anzuzeigende Titel.  -->
<key>title</key>
<string>MyApp</string>
</dict>
</dict>
</array>
</dict>
</plist>
3

There are 3 answers

1
Florian Mozart On BEST ANSWER

Two steps, that fixed the issue: 1. Specify a display-image 2. Encode manifest-url: e.g.

<a href="itms-services://?action=download-manifest&amp;url=https%3A%2F%2FsomeSite.de%2Fapplications%2F557170c4ffcb521300cacb59%2Fversions%2F557170e7ffcb521300cacb5a%2Fmanifest.plist%3Faccess_token%3Dg3hf32v8h5bfeg4t50zfepwzrb9w8b3rv9382va0we7352635baivo" target="_blank" translate="INSTALL" class="ng-scope">Installieren</a>
5
dijipiji On

Assuming you have a plist something like this:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>items</key>
    <array>
        <dict>
            <key>assets</key>
            <array>
                <dict>
                    <key>kind</key>
                    <string>software-package</string>
                    <key>url</key>
                    <string>http://somewebsite.com/APP.ipa</string>
                </dict>
            </array>
            <key>metadata</key>
            <dict>
                <key>bundle-identifier</key>
                <string>com.mycompany.APP</string>
                <key>bundle-version</key>
                <string>1.0</string>
                <key>kind</key>
                <string>software</string>
                <key>title</key>
                <string>NAME OF APP</string>
            </dict>
        </dict>
    </array>
</dict>
</plist>

And a valid .ipa then if you provide a webpage with a link to the plist like this:

<a href="itms-services://?action=download-manifest&url=http://somewebsite.com/APP.plist">Install App</a>

Then the user should be able to install the Enterprise app assuming they have the right provisioning etc. You also need to ensure that your website allows for the user to execute .IPA files

0
1mike12 On

I've read a lot of conflicting information all over the internet. Because it's such a complex process, a lot of suggestions are made "just to be safe", but it ends up wasting time because they're just one more variable that you think you have to do.

things that don't matter

  • URL encoding of url: you can do <a href="itms-services://?action=download-manifest&url=http://example.com/APP.plist">
  • mime types: It's suggested that plist = application/xml and ipa = application/octet-stream but I regularly drag to s3 and change nothing.
  • plist and ipa locations: they don't need to be in same place or be on same server as the anchor link. I have a site that then links directly to s3
  • html page in https: during testing, I found I could point to a server on the local network at 192.168.1.x which doesn't have https and it downloaded fine

things that matter

  • https - the plist, ipa does need to be https
  • query string parameters - adding ?key=value at then end of my url broke the download.
  • xml headers - my personal problem after 6 hours of debugging. don't forget to include the <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">. The xml parser and writer I was using was stripping it out.