Requirements:
The reasoning behind this is that we want to do a limited beta of our app to about 1,000 users, and we need a way to distribute updates to those users' devices without making our beta software accessible to the general public.
We initially explored simply hosting the APKs on an Apache web server, but since we wanted to limit access, we tried putting a username/password on the web server. Well, it turns out that the Android download manager has a bug that prevents downloading files to the phone if it's protected by htaccess.
Next we thought of using an FTP server and then just installing an FTP client on each beta tester's device, but that's pretty janky. This is now our final option.
An "internal" app store server seems to be the best bet. Is there a solution out there for this? Preferably a free/open source one, if that's possible.
For starters: Even if you can't access the APK directly by URL with htaccess in tact, you can hide it behind some server-side code like a php file which simply checks if the user's credentials are valid, and returns a file attachment instead of an html page if everything checks out. If you're going browser-based, I'd recommend this approach over using an FTP client.
However, in your list of requirements: Assuming these are retail, non-rooted, non-custom-ROMMED devices, it's not going to be possible to automatically push application updates to devices. The best you can do is alert the user, and even download the APK- But when you fire the intent to install the APK, the user still has to see the request and manually approve the install. If you look at third party market apps like Amazon and appbrain, they have to do things the same way. Note that in order to install apps this way, the user will have to manually enable installing apps from "unknown sources", which effectively means sources other than the Google Play Store, using the Settings app.
That said, that limitation only applies for replacing the full APK. There's nothing stopping you from downloading updated resources (images, sounds, text, db updates) via a background service, but that's something that would have to be baked into the app, not the private market.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With