Connection Issues Using Either Apache Or Nginx


  • | 1542 points

    Good Day,

    I am having a difficult time with Laragon.

    First - using Apache. On the computer where Laragon is installed, I can access 192.168.1.5 or local host, resulting in the browser displaying the Laragon page. Again on the same computer if I use either 192.168.1.5 or localhost followed by /dev1 I can access the Wordpress site and log into it. But I have not been able to figure out how to access those on other computers on the LAN.

    Secondly - using Nginx. On the computer where Laragon is installed, when I switch to Nginx the browser cannot connect to 192.168.1.5 or localhost at all. Neither can other computers on the LAN.

    So the question is two part... how do I get LAN computers to connect when using Apache and how can I get anything to work when using Nginx?

    Thanks


  • | 1542 points

    Update

    Yesterday, in an attempt to move this along, I removed V4 anddv installed V3. The results and problems in the first post were from V3. Today, I wanted to get this back to V4 so I installed (over V3). After that even installing WordPress was pretty much impossible. The issue being that when I put in a link for say localhost/dev1/wp-admin then something would remove the dev1 and it would show back up in the browser as localhost/wp-admin. Of course that could not be found and it would say so.

    Just now I decided to try it all one more time... removed Laragon and did a clean install. Program installed without issue, but no Laragon icon on desktop link. Created shortcut but it does not have Laragon icon. Attempts to get it to display icon do not work.

    Next did a Quick App Wordpress install. Laragon applet greyed out, was non-responsive, and was completely covering the Create database screen. Clicked visit site which took me here, "https://dev1.dev/" and got this message in browser:

    Did Not Connect: Potential Security Issue
    Firefox detected a potential security threat and did not continue to dev1.dev because this website requires a secure connection.

    What can you do about it?

    dev1.dev has a security policy called HTTP Strict Transport Security (HSTS), which means that Firefox can only connect to it securely. You can’t add an exception to visit this site. The issue is most likely with the website, and there is nothing you can do to resolve it. You can notify the website’s administrator about the problem.

    Out of the box Laragon install does not have SSL enabled. Check enabled and restart Appache 443 SSl shows as working. No help in loading the page with link: https://dev1.dev. Same error as above. Changed to http:// but that is no help and it simply changes back to https://

    Will wait for help.


  • administrators
    | 113323 points

    @adminnga : You must be used a wrong version of Laragon.
    The default hostname format should be {name}.test:
    https://laragon.org/docs/pretty-urls.html

    To fix it, you must rename C:\laragon to C:\laragon.bak, then re-install Laragon 4.0.12.

    On the Laragon interface, there is an IP address. You can use the IP address to access from LAN. Please also check Apache settings to allow access from your LAN's CIDR.


  • | 1542 points

    Hello Leo. Thanks for the reply.

    The version I have installed is "Laragon Full 4.0.12 190228 php-7.2.11-Win32-VC15-x64 [TS]" Right now, save the one setting below and one WP install, a clean install with no mods at all.

    To insure that I was not creating any of the problems I was having, after the reinstall I specifically only changed one setting ... the host name, which I changed to .dev. I will read the https://laragon.org/docs/pretty-urls.html document you suggested later this morning.

    I cannot access either local host or the IP address when Laragon is set to use Nginx. Nothing at all in Nginx. When using Apache, I can access the Laragon screen in both localhost and 192.168.1.5

    The IP addy cannot be accessed over the LAN in either Nginx or Apache. I am not familier with Apache settings to allow access from LAN's CIDR and will read up on that as well. If you have a link for that it would be a big help.

    Again, thanks.


  • | 1542 points

    I am looking at two httpd.conf files and that one of these is where I would control what Apache allows from LAN, but which one?

    One is in C:\laragon\bin\apache\httpd-2.4.35-win64-VC15\conf\original

    The other is in C:\laragon\bin\apache\httpd-2.4.35-win64-VC15\conf

    Thanks


  • | 1542 points

    By xxxxing out both files, it is the one in \conf that appears to be the one used by Apache


  • | 1542 points

    The solution to all the above issues was to NOT install pretty-urls.

    The addition of pretty-urls insured that URLs typed into the browser would distort. Thus, typing in 192.168.1.5/dev1/wp-admin would get one a screen that was not normal but which had the login fields. Once user and password were entered into those fields it would take one to 192.168.1.5/wp-admin.... WITHOUT the WP site name (dev1) included, and of course the pages would not load, instead throwing error after error.

    Worse, was that the cause of all this was masked by crazy behaviors that led to changing other files such as .conf and WP settings in the database when the site could not be accessed properly. Each time this was done it led one step further, and further, into a maze that effectively hid the real cause of the problems.

    Reinstalling Laragon without this feature meant that changes to the .conf files and the WP DB entries actually worked.


  • | 1542 points

    Lastly, there are a number of issues on this board, as well as in Google, about the pretty-urls not working. So, I am not alone.

    Leo, I don't give up easily and see challenges as a way to learn, but that after more than two days chasing this problem down empty holes that I was millimeters close to chucking Laragon in the trash because this really put Laragon in a bad light. I stuck with it because of what I had read about the great things in Laragon. Others may well walk away and that's a shame.

    Please have a look at pretty-url issues as they cause huge problems for both users and those who support them.

    Thanks for your help.


  • administrators
    | 113323 points

    @adminnga : Why do you insist on changing hostname to {name}.dev? it is a TLD owned by Google.
    https://forum.laragon.org/topic/764/important-dev-domains-chrome-63

    I'm afraid you are not using Laragon properly.


  • | 1542 points

    I only use .dev internally on the LAN, Leo. As you suggest that it would be better not to use it, I will change to something different. Thanks


  • | 1542 points

    How am I not using Laragon properly?


Log in to reply
 

Looks like your connection to Laragon was lost, please wait while we try to reconnect.