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

detect when a user is trying to access locally and guide the user #5

Open
cpg opened this issue Mar 28, 2017 · 4 comments
Open

detect when a user is trying to access locally and guide the user #5

cpg opened this issue Mar 28, 2017 · 4 comments

Comments

@cpg
Copy link
Member

cpg commented Mar 28, 2017

this app should detect when a user is trying to access locally and guide the user.

since there are no server components, it probably should be done with JS detecting the Host header and advising the user to:

  • make sure their client device DNS server is their HDA
  • if that is the case, to hard refresh (maybe providing advice based on the browser used)
@MajidSas
Copy link

MajidSas commented Apr 1, 2017

I can fix this as soon as I finish with writing the proposal, if no one is working on it yet.

@MajidSas
Copy link

MajidSas commented Apr 8, 2017

If they reached this website it means that they tried to access their HDA using "amahi.net", so detecting the host-name will always return "amahi.net". In this case, we only need to guide them on how to fix their DNS settings on their client machine, which is what the interactive troubleshooter is providing at the moment. So, what we need to add is the second point (hard refreshing their browser to get the new IP based on the new DNS settings).

Moreover, it is likely that they have an issue with their DNS if they tried to access their HDA through using its IP address. In this case, we need to detect this by adding a small script in the platform (amahi/platform) to show a message that provides a link to amahi.net interactive troubleshooter.

What do you think? Am I getting this right?

@cpg
Copy link
Member Author

cpg commented Apr 13, 2017

This is not correct. They may have tried to access this site with other hostnames, long or short. Anything other than www.amahi.net or amahi.net (exactly, without a host in front) needs to be addressed as a failure and the user must be instructed about possible solutions.

@MajidSas
Copy link

I understand the issue better now, because I was able to reproduce it (or something similar).

I installed a new hda on my server with the home domain set to amahi.net. I found that the new installation did not change the hostname of the server to the new one (amahi.net), so I had to change it manually. When I tried to make some tweaks sometimes a domain like hda.amahi.net work correctly. Other times all the server's domains (*.amahi.net, amahi.net) work correctly but my client device couldn't resolve internet addresses. It could be an issue with the IP address of the DNS server I used, where it might be blocked in my network (my university's network is very restrictive, I can't use 8.8.8.8 for example).

In any case these are some of the things that I think are related to this issue:

  • The server's hostname (it should be amahi.net).
  • The contents of the file /etc/resolv.conf should point to the correct IP addresses.
  • The user might need to clear the DNS cache in their browser (or maybe their OS). For Chrome, it can be cleared through chrome://net-internals/#dns, in Firefox it can be done in about:config. There are probably other ways too.

I'm writing this just to make sure that I got everything right, and to document this for later because I'm very busy at the moment to work on it.

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