I have a project is working for android browser. Is there a way to generate the apk file?
Also, are there anything that I shoud know before generating the apk file?
There are a few steps to follow in order to generate the Android application file (.apk
) from a meteor app:
meteor install-sdk android
mobile-config.js
file in your project root (mobile-config.js example)meteor add-platform android
meteor build ~/your-output-dir --server=yourapp.meteor.com
Then you will have your .apk
file in ~/your-output-dir/android/unaligned.apk
If you want to proceed and submit to Google Play Store, here are the steps to follow: https://guide.meteor.com/mobile.html#submitting-android
Hope this helps!
As of now playstore has started giving warning while uploading APK about unoptimised bundle and insisting for uploading Android app bundle. Insted of generating APK why not generate .aab of your project and reduce size of the application.
For people wondering about how to generate .aab for your existing project can read my blog here:
My blog link
You can build an APK file with meteor build
command.
Read more about it in the docs: http://docs.meteor.com/#/full/meteorbuild or by typing meteor help build
in your terminal.
Starting with Meteor 1.2, the bundled Android tools have been removed and a system-wide install of the Android SDK is now required. This should make it easier to keep the development toolchain up to date and helps avoid some difficult to diagnose failures. The meteor install-sdk command no longer attempts to download and install the Android tools for you (it has been deprecated and just points you to these instructions).
like imslavko says, meteor build
works pretty fine, also if you are looking for more information take a look on this Meteorpedia
It work for me
Reegards