Meteor run application is working but not application with meteor build


#1

Hello Friends,
I have created an meteor-android application using blaze template engine. It works well when I install it directly form meteor run android-device command. Now I have used meteor build ~/mobileAPK --server x.x.x.x:3000 to generate apk file and that apk is not working properly. It is taking very much time to switch form one screen to another. Sometimes it won’t work. This is same in signed apk and unsigned apk. Does anyone have any solution for it?


#2

I don’t have a solution to your problem, but I would suggest changing the title, so people who might know will find this thread more easily. From what you describe, it sounds like the problem has nothing to do with signing, but with the difference between meteor run and meteor build.


#3

Thanks for your suggestion. I have changed its title.


#4

I am facing same issue.
When I run code with meteor directly on server, my app works just fine

but when i do meteor build and run it on server, my app stops working.

Its pretty frustating


#5

Do you have an error message or stack trace? I’m pretty sure there’s a solution, but it’s almost impossible for people to help if there is no description of the error, other than “it doesn’t work”.


#6

Finally after debugging for many many hours, i found solutions:

  1. use DDP_DEFAULT_CONNECTION_URL (same as ur root url) - on your server. like
    export DDP_DEFAULT_CONNECTION_URL = IP
    https://github.com/meteor/meteor/issues/3698

  2. I used chrome inspect to see what my app was connecting to, and to my surprise, even on running meteor, it was sometimes trying to connect to old credentials (read server URL), so i did meteor build and checked all apks were updated

now everything works perfectly