CodePush Server is a CodePush program server. The official Microsoft CodePush service is slow in China, therefore we use this to host our own server.
Since the original code-push-server project is not actively maintained, we created this fork to:
- keep dependencies up-to-date
- fix any compatiblity issue with latest official code-push clients
- we only stick to official react-native-code-push client, therefore the customized feature like is_use_diff_text won't be supported.
- we only use react-native-code-push client in production, most of the feature should be no difference for the rest CodePush clients, but if you found any, issues and PRs are always welcome.
- local: store bundle files in local machine
- qiniu: store bundle files in qiniu
- s3: store bundle files in aws
- oss: store bundle files in aliyun
- tencentcloud: store bundle files in tencentcloud
- 苹果 App 允许使用热更新Apple's developer agreement, 为了不影响用户体验,规定必须使用静默更新。 Google Play 不能使用静默更新,必须弹框告知用户 App 有更新。中国的 android 市场必须采用静默更新(如果弹框提示,App 会被“请上传最新版本的二进制应用包”原因驳回)。
- react-native 不同平台 bundle 包不一样,在使用 code-push-server 的时候必须创建不同的应用来区分(eg. CodePushDemo-ios 和 CodePushDemo-android)
- react-native-code-push 只更新资源文件,不会更新 java 和 Objective C,所以 npm 升级依赖包版本的时候,如果依赖包使用的本地化实现, 这时候必须更改应用版本号(ios 修改 Info.plist 中的 CFBundleShortVersionString, android 修改 build.gradle 中的 versionName), 然后重新编译 app 发布到应用商店。
- 推荐使用 code-push release-react 命令发布应用,该命令合并了打包和发布命令(eg. code-push release-react CodePushDemo-ios ios -d Production)
- 每次向 App Store 提交新的版本时,也应该基于该提交版本同时向 code-push-server 发布一个初始版本。(因为后面每次向 code-push-server 发布版本时,code-puse-server 都会和初始版本比较,生成补丁版本)
check out the code-push-cli which works with server for manage apps and publish releases
- docker (recommended)
- manual operation
- account:
admin
- password:
123456
- modify password
- code-push-server normal solution (CN)
- targetBinaryVersion support
*
1.2.3
1.2
/1.2.*
1.2.3 - 1.2.7
>=1.2.3 <1.2.7
~1.2.3
^1.2.3