Oracle Cloud OCI - how to forward effectively
February 22, 2023 03:45AM
Greetings everyone.
I am fairly new in NGINX. however, I am since months using it in my Network.
I believe I grasp the basics.
I already have several services running and forward to application within my network by only exposing port 80 and 443.
I want to take it a step forward; I signed up for a free Oracle Cloud (OCI).
Works very well.
OS: Ubuntu 22.04 server
I installed docker and docker compose and Portainer-CE: all fine.
Now, my problem is that when configuring hosts, I can create even a letsencrypt certification.
The issue is that when I hopen the ports using the ingress rules of the cloud instance, it works. I have to forward to the private IP address. I do also have a subdomain pointing to the private address.
However, I like to only expose port 80 and 443.
When I delete the (example) port 80443 or 9634, my service becomes unavailable.
Now, the public (internal) IP range is 10.0.0.0/16. say, my Ubuntu is on 10.0.0.40.
When I try to forward to 10.0.0.40, I do not access the service. With or without the ingress rule.

Clearly is not as simple as in my network where I can forward to my internal public IP.

Anyone with experience here can help me?
I am using the NGINX GUI to configure it all./
If you need more info, please ask.

Thank you in advance
Re: Oracle Cloud OCI - how to forward effectively
February 24, 2023 03:28AM
To summarize:
I need help on: How to make Nginx PM work when used in a docker on a OCI (Oracle Cloud).
Thank you.
Re: Oracle Cloud OCI - how to forward effectively
February 28, 2023 06:57AM
I did not think it was that difficult.
The silence in this forum means is not an easy task.
I keep searching.
When and if I find a solution, I will post it here to help others with same issue.
I am still open to suggestions ...
Re: Oracle Cloud OCI - how to forward effectively
April 25, 2023 01:09PM
So, I found the solution...
Basically, it is not possible to forward to the public IP 10.0.... that does not work.
In nginx PM, under : Forward Hostname / IP* you have to add the Docker gateway IP, than it works.
Very much different from a home network.
In a home netork all you need is the IP of the machine where the docker is installed.
So: in Oracle Cloud:
Nginx must point to the docker gateway. Thats what it takes.
I could not find this anywhere.. and finally after several tests, that was the only successful way.
I hope it will help others with same issue
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 154
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready