【问题标题】:Enterprise application download cannot connect to "website address" error企业应用程序下载无法连接到“网站地址”错误
【发布时间】:2014-04-04 01:13:53
【问题描述】:

我创建了一个 Ad Hoc 企业版本。

我用了以下

  • 为企业或 AD Hoc 部署保存
  • 选择我的分发证书
  • 另存为“MyAppName”
  • 选择“为企业发展而保存”
  • 应用程序 URL "https://www.myurl.com/app/
  • 标题“MyAppName”

之后我将构建上传到我的网站

我创建了一个如下所示的 index.html 页面。

<!DOCTYPE html>
<html>
<body>

<a href="itms-services://?action=download-manifest&url=itms-services://?action=download-manifest&url=https://www.myurl.com/app/MyAppName.plist" id="text">Download Here!</a>

</body>
</html>

然后,当我将 iPad 的 Safari 浏览器定向到该 URL 并单击我创建的链接时,会出现一个错误,上面写着

“无法连接到 www.myurl.com”

现在,当我请求“HTTPS”时,我得到的地址最初是“HTTP”,因为 7.1 更新了企业规则,托管公司告诉我它也将支持“HTTPS”,所以我不确定这是否是什么导致问题?还是我的设置有问题?

更新 1

我一直在阅读并设法找到一个有用的苹果链接iOS_Deployment_Technical_Reference 最后几页是最有帮助的。

所以我后来意识到我在 index.html 文件中放置的链接不正确...我试图直接链接到我的应用程序,我以为我在某个地方读到了当您创建存档构建时生成 manifest.plist 并放置在 .ipa 文件中。据我在阅读苹果部署文档后所知,这是错误的。

该链接应该指向您也添加到您的网络目录的 manifest.plist 文件,该清单文件告诉您的 iDevice 去哪里下载应用程序和一些其他详细信息。

iOS_Deployment_Tecgnical_Refrence 的底部是一个示例 manifest.plist 文件,我现在已对其进行编辑并添加到我的 web 目录中,我已更新我的 index.html href 以指向清单文件。

其次,我从浏览器下载了网站证书并将其通过电子邮件发送到我的 iPad 并参考@borrrden 评论进行安装。

完成上述所有操作后,当我点击 iPad 上的链接“无法连接到 www.thewebsitesname.com”时,我仍然收到错误消息,警告框中的唯一选项是点击确定。

这是任何其他感兴趣的人的网络清单示例。

<!DOCTYPE plist PUBLIC “-//Apple//DTD PLIST 1.0//EN” “http://www.apple.com/
DTDs/PropertyList-1.0.dtd”>
<plist version=”1.0”>
<dict>
 <!-- array of downloads. -->
 <key>items</key>
 <array>
 <dict>
 <!-- an array of assets to download -->
 <key>assets</key>
 <array>
 <!-- software-package: the ipa to install. -->
 <dict>
 <!-- required. the asset kind. -->
 <key>kind</key>
 <string>software-package</string>
 <!-- optional. md5 every n bytes. will restart a chunk if md5 fails. -->
 <key>md5-size</key>
 <integer>10485760</integer>
 <!-- optional. array of md5 hashes for each “md5-size” sized chunk. -->
 <key>md5s</key>
 <array>
 <string>41fa64bb7a7cae5a46bfb45821ac8bba</string>
 <string>51fa64bb7a7cae5a46bfb45821ac8bba</string>
 </array>
 <!-- required. the URL of the file to download. -->
 <key>url</key>
 <string>https://www.example.com/app/AppName.ipa</string>
 </dict>
 <!-- display-image: the icon to display during download.-->
 <dict>
 <key>kind</key>
 <string>display-image</string>
 <!-- optional. indicates if icon needs shine effect applied. -->
 <key>needs-shine</key>
 <true/>
 <key>url</key>
 <string>http://www.example.com/image.57x57.png</string><
 </dict>
 <!-- full-size-image: the large 512x512 icon used by iTunes. -->
 <dict>
 <key>kind</key>
 <string>full-size-image</string>
 <!-- optional. one md5 hash for the entire file. -->
 <key>md5</key>
 <string>61fa64bb7a7cae5a46bfb45821ac8bba</string>
 <key>needs-shine</key>
 <true/>
 <key>url</key><string>http://www.example.com/image.512x512.jpg</
string>
</dict>
 </array><key>metadata</key>
 <dict>
 <!-- required -->
 <key>bundle-identifier</key>
 <string>com.example.fooapp</string>
 <!-- optional (software only) -->
 <key>bundle-version</key>
iOS Deployment Technical Reference Guide
 44 <string>1.0</string>
 <!-- required. the download kind. -->
 <key>kind</key>
 <string>software</string>
 <!-- optional. displayed during download; typically company name -->
 <key>subtitle</key>
 <string>Apple</string>
 <!-- required. the title to display during the download. -->
 <key>title</key>
 <string>App Name</string>
 </dict>
 </dict>
 </array>
</dict>
</plist>

我的问题是,你应该自己生成 manifest.plist 文件吗?或者有没有办法从xcode做到这一点?其次,当我选择链接并收到无法连接到网站地址时,可能导致此错误的原因是什么?

【问题讨论】:

  • 我刚刚阅读了其他可能是网址中的 itms-services 的地方。我还能尝试什么?
  • 您是否在 iDevice 上安装了 Web 服务器的 SSL 证书作为可信证书?
  • 不,我还没有这样做......所以我只是要求他们向我发送 SSL 证书,然后我将其添加到捆绑包中吗?并重新部署它?
  • 这可能是也可能不是问题,但请查看此页面以获取更多信息:blog.httpwatch.com/2013/12/12/…(提示 #2)
  • 这对我不起作用.. 将 SSL 证书添加到构建文件并再次执行所有步骤,但仍然没有

标签: ios objective-c ipad adhoc


【解决方案1】:

原来我的清单文件完全错误。 我以此为例。

http://gknops.github.io/adHocGenerate/

所以对于你上传的网页

  • myApp.ipa
  • manifest.plist
  • index.html

希望这会有所帮助。

【讨论】:

  • 记得接受你自己的答案。 :) 如果您有太多问题没有接受答案,您的声誉将受到惩罚。
【解决方案2】:

我也遇到过同样的问题,但按照以下步骤解决了。

在配置的站点服务器中添加了以下 MIME 类型。

扩展名.plist

MIME 类型文本/xml

扩展名 .ipa

MIME 类型 application/octet-stream

.html

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>App Name</title>
</head>

<body>
    <p><b>iOS App: Demo App</b></p>
<p>
    <a href="itms-services://?action=download-manifest&url=https://www.server.com/appname.plist">
        click this link to install
    </a>
</p>

</body>
</html>

.plist

<?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>https://www.server.com/Adhoc/Addhocdemo.ipa</string>
                </dict>
            </array>
            <key>metadata</key>
            <dict>
                <key>bundle-identifier</key>
                <string>com.companyname.appname</string>
                <key>bundle-version</key>
                <string>1.0</string>
                <key>kind</key>
                <string>software</string>
                <key>title</key>
                <string>AdHoc Demo</string>
            </dict>
        </dict>
    </array>
</dict>
</plist>

IOS 版本 10.3.1 工作正常,但在 IOS 设备的 IOS 版本低于 10.3 时失败。

【讨论】:

  • 感谢 @Ashwin 让我记住了 Nginx 的 mime 类型 :)
【解决方案3】:

我收到了相同或非常相似的错误。

我的解决方案是向 Internet 信息服务 (IIS) 托管的网站添加适当的 mime 类型。

即“.ipa”和“.plist”。

【讨论】:

    【解决方案4】:

    我遇到了这个问题,结果证明是 .ipa 文件名中的空格。删除了空间,它安装得很好。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2019-08-10
      • 1970-01-01
      • 1970-01-01
      • 2016-01-29
      • 1970-01-01
      • 2018-04-22
      • 1970-01-01
      相关资源
      最近更新 更多