A NodeJS application to automate binary deployments from Unity Cloud Build to HockeyApp.
Note; This is an initial release which is functional, but needs refactoring.
- Receive a webhook from Unity Cloud Build to notify a build is ready.
- Get the build details from the JSON payload within the webhook.
- Download the app binary from the Unity Cloud Build API.
- Upload the app binary to HockeyApp.
- Setup a Unity Cloud Build account and project.
- Setup a HockeyApp account. HockeyApp will use the app package name to detemine which project to upload to.
-
Clone this repository.
-
Add API keys to '.env' for both Unity Cloud Build and HockeyApp. * UCB API key can be obtained here. * HockeyApp API key can be created here. Be sure to create a key 'Upload' rights (e.g. anything above 'Read Only').
-
Deploy.
* Have only tested running on Heroku. -
Setup the Unity Cloud Build webhook. * Within UCB, view your app. Click 'Notifications', then 'Add New' and enter your app URL with '/build' appended. E.g. 'http://[appurl]/build/' * Use a tool like Request Bin to test web hooks from UCB, ontain the payload and test requests to '/build/'.
- If you use Slack, integrate UCB and HockeyApp to be notified when a new build is ready and has been pused to HockeyApp. See screenshot above.
- You don't need to setup the app on HockeyApp, if you upload the binary it will automatically create a new app instance.
- Configure HockeyApp to automatically notify users after the binary has uploaded. See the 'notify' variable within the 'uploadToHockeyApp()' function. HockeyApp API
- Clean up and comment codebase.
- Populate HockeyApp release notes with Git commit message.
- Add logging feature to show builds processed and deployed.
- Integrate job system to manage/prioritise jobs and view jobs in progress.
Copyright 2016 Nathan Brodbent
This software is licensed under Apache License 2.0.