Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unable to access webapp client from mobile #135

Closed
amenak77 opened this issue Jul 29, 2018 · 12 comments
Closed

unable to access webapp client from mobile #135

amenak77 opened this issue Jul 29, 2018 · 12 comments

Comments

@amenak77
Copy link

test_newclient4

After compiling webapp client's project and replacing default polymer client with it into webserver plugin, webapp is correctly found at [server IP address]:8090 address; if you try to access from a pc or notebook within the LAN there is no problem. If you try from a smartphone you have a rightful login panel which deny access even if you enter right data. Ping is sent and received correctly; this probably means an auth problem more than a connection one. Mobile problem only.

@mcicolella
Copy link
Collaborator

Is the pc or the notebook the same which FD is running on when it works?

@amenak77
Copy link
Author

amenak77 commented Aug 3, 2018

Yes, when it works, it is the same notebook and the call is made through localhost; I haven't tried access to freedomotic via webapp from another LAN pc; I'll try ASAP; however, I downloaded firefox mobile app and used it to access freedomotic and I have same bad login message

@amenak77
Copy link
Author

amenak77 commented Aug 3, 2018

Hi all,
I tried to access freedomotic from another LAN computer thriught webapp client; first step is OK: you digit in browswer (chrome) navbar 192.168.1.58:8090 and apperas vue login; then if you enter Fd notebook ip address into server address field, 9111 in server port field plus ususal admin/admin you have THE SAME BAD LOGIN INFORMATION warning; so I think we can change the issue in "unable to access webapp client from another LAN device". PS using localhost (obviously) same failure. Sometimes...

@amenak77
Copy link
Author

amenak77 commented Aug 3, 2018

Ever and ever strange; if you access freedomotic from the same LAN device, access is granted whatever charachter you digit into the first thwo form fields (server address and server port) if you correcly insert admin/admin; otherwise access is denied. The last issue definition should be "errors with auth LAN token ring" I suppose

@mcicolella
Copy link
Collaborator

The problem is here.
RestAPI url is set statically.

@amenak77
Copy link
Author

amenak77 commented Aug 3, 2018

Excuse me, but I don't understand; why is this a problem?

@mcicolella
Copy link
Collaborator

Because it points always to 'localhost'. If the client is on the same machine running FD all is OK.
When you connect from another device (a smartphone for example) the app searches RestAPI on the 'localhost' that isn't the PC where the plugin is running but the client itself. So it doesn't find the API.
Hope it's clear.

@amenak77
Copy link
Author

amenak77 commented Aug 4, 2018

Perfectly clear, thank you; so we can get rid of this annoying bug soon ;)

@mcicolella
Copy link
Collaborator

Just updated the app. The issue should be fixed.
I removed server ip and port number because the first is automatically detected from the URL and the last is set statically on the RestAPI. Less parameters for users :)
Please check.
N.D. remember to delete the browser history

@amenak77
Copy link
Author

amenak77 commented Aug 4, 2018

Great! I'll check ASAP and obviously I'll let you know ;)

@amenak77
Copy link
Author

amenak77 commented Aug 4, 2018

First of all, just to make my point clear: fantastic work! Great Mauro and great Ubaldo. All works very well; the webapp has a great level and personally, command my home lights without install or configure anything. Autodiscovery at its maximum extent; even ip address and restapi port don't reqire any configuration. UI is set automatically depending on type of device you have. Fantastic. We can close the issue

@mcicolella
Copy link
Collaborator

Fixed in 66765a1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants