Hello everyone i am having some trouble trying to make my nextcloud available on the internet.I have installed nextcloud successfully and set it so when i enter the server’s ip address i will be presented with the nextcloud login page, my server is a apache2 on a raspberry pi and the conf file i loaded look like this:
In this example a replace my domain name with example.I bought a domain form namecheap and there customer service assured me that my domain records are set correctly,my port fowarding is correct and ddclient is also set up correctly but i still cannot access my site by just typing the domain name in a browser url.Thanks for your help also i have entered the domain in config.php second after the domain of the pi,and the hosts file look like this:(192.168.0.140 ip of the pi)
Simple trouble shooting, I suppose that 192.168.0.140 is internal IP Address of your Nexctloud Server:
From your local Network try to open your webpage direct via IP, e.g. http://192.168.0.140 and https://192.168.0.140. You should be able to see alt least an Trusted domain error (as here). Works? This means you server set correctly to listen on http and https traffic. Go to step 2.
Check that you ports 80 (http) and better 443 (https) are open and you have set correctly your port forwarding.
For this please find out you external IP, e.g. via Browser https://ipinfo.io/ or run shell command curl ipinfo.io.
After this take you external IP from the first line and do the call via browser: http://ExternalIPAddr and https://ExternalIPAddr.
Or you can use online tools to check if ports 80 and 443 are opened: https://www.yougetsignal.com/tools/open-ports/
If you can again see trusted Domain Error or/and online tools says it open - your port forwarding works fine. Goto step 3.
Check if Domain name bounded to your IP correctly, for this from the Linux Machine simply run command: dig example.site (or use online dig from Google). You will see output something like this:
Where instead of 216.58.207.78 must be your External IP Address from step 2.
If all 3 steps are successfully done, you must be able to communicate to your server from the internet.
Thanks i failed on the second troubleshooting solution, tried the web site https://www.yougetsignal.com/tools/open-ports/ and found out that port 80 and 443 where closed but when i type curl ipinfo.io i get different ips because am using a dynamic ip e.g when i type it the first time i got 11.111.111.21 and the second time 11.111.111.53 (this are e.g. external ip)
Nope there still closed tried another port testing tool www.canyouseeme.org and no luck, even tried nmap -p 80,443 192.168.0.140(pi ip) but get a closed port response is it possible that my ISP may be blocking the ports ?
I’m using ddclient for that and is setup as the domain vendor instructed.
Try to map (in ports forwarding) some other ports, like 4433 or 8080 instead of 80 and 443.
Also if you stays on Point 2, it could be that port forwarding does not work, or your server has kind of IP Whitelisting.
Can you check on your router/modem what is you external IP and call https of it?