Can only access nextcloud on RPi 3 locally

I setup Nextcloud on my Raspberry Pi 3 and can access it locally using the ddns.net domain I got from noip and through the ip assigned to the raspberry. But I cannot access my cloud outside of my local connection, such as on my phone without wifi enabled.

I forwarded ports 80 and 443 on my router to the raspberry pi. Not sure what else to do.

Double check if your ddns.net domain really points to your public IP.
How do you handle public IP changes? Is your ddns.net domain configured in your router?

I found my public ip via curl ifconfig.me and used this ip on ddns.net. I also entered my ddns.net login credentials on my router if that’s what you mean by configuring the ddns.net domain on the router. Though this ip address is the exact same one as the WAN ip listed on my routers status page.

I have ports 80 and 443 forwarded to a different ip address which is a variation of my default gateway ip: 192.168.0.X.

I also have the NoIP Dynamic Update Client installed and running on my RPi.

If you configured your ddns.net domain in your router, you don’t need the NoIP Client on your Raspberry Pi (which is very sh*tty to be honest), because your router handles the changing public IP.

Technically, dynamic IP service and port forwarding should be all you need to do. I don’t know if this could be an issue, but did you provide your Apache/nginx configuration with your Raspberry Pi’s IP address or with your ddns.net domain?

I followed this tutorial to setup a static IP: http://www.circuitbasics.com/how-to-set-up-a-static-ip-on-the-raspberry-pi

As a result of the tutorial here is what my /etc/dhcpcd.conf looks like:

interface eth0
static ip_address=192.168.0.100/24
static routers=192.168.0.1
static domain_name_servers=8.8.8.8

192.168.0.1 is my default gateway IP. I didn’t use the RPi public IP in any of the steps.

I followed this tutorial for setting up Nextcloud: http://www.instructables.com/id/Personal-Cloud-for-Self-organization/

In this tutorial the Apache commands used are:

sudo apt-get install apache2 -y
sudo apt-get install php5 libapache2-mod-php5 php5-curl php5-gd -y
sudo apt-get install mysql-server php5-mysql -y
mysql -uroot -p
create database cloud;
sudo service apache2 restart

So didn’t provide any IP while installing Apache.

I’m no expert with Apache (I use nginx) so I’m afraid I can’t help you with that…

If you can access the Pi locally on the static IP set it’s very likely a nat issue. Use this to check your ports are open:

http://www.yougetsignal.com/tools/open-ports/

I just found out my ISP blocks port 80 incoming. Do you think this is causing the issue of not being able to access my cloud outside my network?
and
Also, the port checking site says both 443 are closed.

Yes, no open ports = no connectivity.

You’ll have to take that up with your ISP I’m afraid :thumbsdown:

Yes, you need to configure your router so that the ports and redirecting to your local IP.
Refer to your router’s manual.

My ISP says there is no way for them to unblock port 80 unfortunately

We’re somewhat out of options if the ISP blocks ports higher up the chain I’m afraid.
As you didn’t mention 443 (which I suspect is also blocked) you can ask them again, but I wouldn’t hold my breath.

I forwarded ports for my TP-Link router and this is what the router settings look like now. Does everything look normal?


http://imgur.com/zG70s0i
http://imgur.com/euAlH2Y

That looks fine.

My ISP said port 443 isn’t blocked. Not sure why its still coming up as blocked if all the settings are correct.

Another setting on your router? It’s not an NC issue so it’s going to require some digging on your side.

Consider using another port for www, such as 8080.

I was able to access my NextCloud by changing port 80 to 8080.

Is my setup correct?

Right now when I visit my domain.com it redirects to my ddns.net domain which redirects to my WAN ip (difference is the last set of digits) 68.8.3.xxx:8080.

Is there anyway it can just stay as domain.com?