Closed atd closed 6 years ago
@atd as you said, export ROOT_URL=http://10.0.13.148:3000
works, because it's the way you should configure your app root URL, its written in the Meteor documentation.
I guess --port
only defines on which port to listen, but does not auto defines the value of ROOT_URL
.
So maybe I should rename the issue:
"jalik/ufs does not support BIND_IP in production and --port=host:port in development"?
https://docs.meteor.com/environment-variables.html#BIND-IP
:wink:
@atd I've tested the following commands with the UFS example project (https://github.com/jalik/ufs-example) :
meteor run
meteor run --port 4000
meteor run --port 192.168.3.1:4000
All executions went normally without the need to define ROOT_URL
and I could upload files without any error, I guess there is something wrong with your setup. You should checkout the ufs-example repository and compare it to your setup.
I cannot help you based on "... breaks uploads", moreover on my side it's working fine.
You said that using ROOT_URL
you setup works fine, so it's related to how your ROOT_URL
is defined, and this env var is used by Meteor in Meteor.absoluteUrl()
.
Note : UploadFS is relying on the official Meteor.absoluteUrl()
method to communicate with upload endpoints (nothing tricky so).
I am afraid I am not able to reproduce it anymore
Thank you @jalik for the detailed explanation and this awesome package
@atd I am glad I could help you in any way. Feel free to create new issues to help fixing / improving the package, you are also welcome for other contributions like sending pull requests. Happy coding.
meteor run --help
showsHowever, using
meteor run --port 10.0.13.148:3000
to run the server breaks uploads. No error is shown in console neither theonError
callbackexport ROOT_URL=http://10.0.13.148:3000 && meteor run
works