Web App hosting on TrueNAS

Hi,I will have to create React web app(Schedule App) that I need to host locally. It will be available only via VPN tunnel I have created on my network with public IP on one of the routers(Wireguard and OpenVPN both available).

I am thinking about spinning up some VM and hosting it there.

What do you think?

A VM is overkill for this. You would be better served by an LXC container or a Docker app running something like this: https://github.com/bigcalendar/react-big-calendar.

Thanks for replying but I really require this particular I will be making in react. Only few people will have access to it and need to be able to create only for selected days of week and to choose 2 people from drop-down list for same time windows(one hour windows). Also it will be possible to make jpg of schedule and share it on Telegram Group chat. I want to recreate app that is already working but only on Android and it is required to work for both iOS and Android(Windows etc might be a plus). Those with access to that app will be admins of app while there will be many more that will be shown JPG(image) only.

From your reply, I surmise your native language isn’t English. Unfortunately, I can’t parse your use cases, so I can’t help any further. Feel free to post in the International forum in your native language.

In my very modest opinion, Samuel_Tai’s advice was 10/10: why would you want to add all the overhead of a VM just to run a single app?
Maybe i’m wrong, but you could easily handle everything with a Docker Compose file, and protect the app behind a reverse proxy, where you only whitelist the VPN IPs you want let access

I am not saying it has to be VM but never done anything production-ready in any docker etc just some basic experiments with it, Also never did any reverse proxy thing not dealt with that.

Do you have any tutorial for creating proxy/reverse proxy?

Depends on which reverse proxy you want to use. Personally i use traefik and followed techno tims traefik3 guide

Instead i use Nginx Proxy Manager, what is needed to achieve that is to navigate into Access List menu, create an access list (allow VPN ips, deny all), then when you create your proxy host you set that list into it. Search for NPM Access List, there are a lot of results, both video and guide.

EDIT: also Caddy is a really valid option

To store my custom apps, i have also built a registry container: i push code from my PC, then i can install the app easily from anywhere in my lan.

is it even possible to use docker on TrueNAS? I only find LXC containers.

yes the menu point is called apps

Basically I am not dead set on one solution so anything I can get some tutorial is fine as long as it can be set up on TrueNAS

IMHO avoid app catalogue, set up your preferred pool to unlock apps (better on fast storage, not on rust disks), then with the custom app mechanism build nust your preferred manager (dockhand, dockge, … totally your preference here).
The installation of each app depends on the app itself, but generally speaking: create datasets to store persistent data as Apps preset, and set snapshot rule on them according to what are your backup needs (if you don’t take them already).

I use and prefer Caddy:

Some folks prefer Nginx Proxy Manager for its GUI, and I have a guide for that too: