今天使用蒲公英给别人发测试 APP(一个游戏的重签名包) 的时候被封禁了,在寻找其余的分发方法的时候顺便也探讨了下蒲公英的这个 app 分发机制.html
OTA 即 Over-the-Air,是 Apple 在 iOS4 中新加的一项技术,目的是让开发者可以脱离 Appstore,实现从服务器下载并安装 iOS 应用。 用户只须要在 iOS 设备的浏览器中,打开itms-services://协议连接,就能够直接安装App。(注意:此处的安装是指,我的帐号须要注册设备,企业帐号无需注册设备)git
manifest.plist内容github
<?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>xxx.ipa</string> </dict> <dict> <key>kind</key> <string>display-image</string> <key>url</key> <string>xxx/icon-57.png</string> </dict> <dict> <key>kind</key> <string>full-size-image</string> <key>url</key> <string>xxx/icon-1024.png</string> </dict> </array> <key>metadata</key> <dict> <key>bundle-identifier</key> <string>xxx.xxx.xxx</string> <key>bundle-version</key> <string>1.0.x</string> <key>kind</key> <string>software</string> <key>title</key> <string>xxxx</string> </dict> </dict> </array> </dict> </plist> 复制代码
字段 | 描述 |
---|---|
software-package | ipa 文件所在地址 |
display-image | 图标缩略图 |
full-size-image | 图标全尺寸 |
bundle-identifier | 包名 com.xxx.xx |
bundle-version | 版本 1.0.x |
title | 应用名 |
静态 html 页面 页面长啥样不重要,重要的是要有如下代码浏览器
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>标题</title> </head> <body> <a href="itms-services://?action=download-manifest&url=manifest.plist的地址">点击安装</a> </body> </html> 复制代码
若是 ipa 包自己小于100MB 的话,用 gitee 或者 github 也能够,有能力的能够本身搭建服务器. 我以腾讯云为例,新用户能够免费领取6个月的对象存储 COSbash
把咱们以前准备好的文件都传到服务器上服务器
而后在浏览器中访问 down.html,点击"点击安装"就能够了 markdown