I need to get access from the world to my nextcloud

maxudak

Dabbler
Joined
Jan 26, 2020
Messages
10
Hello everyone! I need to get access from the world to my nextcloud, which is installed on my trunas server in jail. Default installation via plugin. Important! Trunas is behind nat on a gray ip. I want to configure access only by means of trunas! I do not want to configure a local network router for this. How can this be done?
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,703
I do not want to configure a local network router for this
This will be a limiting factor since without port forwarding, you have no option to even run a reverse proxy locally... you will need to use a network VPN technology like wireguard (maybe with tailscale as a helper) or ZeroTier that reaches out from the host to make its own connection to some kind of infrastructure hosting the network.

You would then connect other clients and maybe a reverse proxy to that network to allow access either via VPN only or directly from the Internet (reverse proxy).
 

maxudak

Dabbler
Joined
Jan 26, 2020
Messages
10
The fact is that I already have access to the host via open vpn and I need to configure access in jail. A working solution is to install the open vpn client in the same jail as nextcloud. But I just cannot understand why it is impossible to configure access to jail via vpn from the host. Why is there access without vpn in the local network, but via vpn there is only access to the host. Open Vpn is configured on the host.
 

Attachments

  • Screenshot_20220110-090318346.jpg
    Screenshot_20220110-090318346.jpg
    50.8 KB · Views: 188
  • Screenshot_20220110-090425345.jpg
    Screenshot_20220110-090425345.jpg
    61.7 KB · Views: 177

Kasen

Dabbler
Joined
Sep 15, 2023
Messages
17
Hi, have you solved this problem? Would you share some ideas to access nextcloud on truenas scale outsider of my router?
 

maxudak

Dabbler
Joined
Jan 26, 2020
Messages
10
Hi, have you solved this problem? Would you share some ideas to access nextcloud on truenas scale outsider of my router?
As far as I have found out, the most effective way is to install a VPN on the router and through it you can have access from the world to the local network. I did just that using wg. But actually using only trunas for this is impossible because of its differences from pure freebsd.
That is, I have a virtual machine in a cloud service (oracle) with a VPN server and through it I have access to the VPN client on the router and then to the network behind the router. In the case of wg this is very easy to do.
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
The fact is that I already have access to the host via open vpn and I need to configure access in jail. A working solution is to install the open vpn client in the same jail as nextcloud. But I just cannot understand why it is impossible to configure access to jail via vpn from the host. Why is there access without vpn in the local network, but via vpn there is only access to the host. Open Vpn is configured on the host.
Is the default gateway of your jail set correctly?
 

maxudak

Dabbler
Joined
Jan 26, 2020
Messages
10
Is the default gateway of your jail set correctly?
Everything was correct. The VPN client that is installed on trunas does not provide access to the prison that is installed on the same trunas. If you succeed, please share. The TRUNAS operating system differs from pure Fribsd in that many “dangerous” features are removed from it.
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
Wouldn't you need a VPN server to connect to your TrueNAS from "outside"?
 

Kasen

Dabbler
Joined
Sep 15, 2023
Messages
17
As far as I have found out, the most effective way is to install a VPN on the router and through it you can have access from the world to the local network. I did just that using wg. But actually using only trunas for this is impossible because of its differences from pure freebsd.
That is, I have a virtual machine in a cloud service (oracle) with a VPN server and through it I have access to the VPN client on the router and then to the network behind the router. In the case of wg this is very easy to do.
Thank you for your king reply. Some post showed that the VPN address need to be added to the trust domain of the NextCloud, but I dont know how to try it. Purely freshman in truenas and linux. My Router has no choice for VPN setting.
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
Port forwarding on the Internet router, HTTPS reverse proxy, done. I never used any other way.

Alternatively set up a suitable VPN server on your router, connect from Internet, also done.
 

Kasen

Dabbler
Joined
Sep 15, 2023
Messages
17
Thank you for your reply! My router does not support VPN installation. I will learn port forwarding and proxy, and try the first tip.
 
Top