OPNsense Forum

Archive => 23.7 Legacy Series => Topic started by: chanle on September 12, 2023, 07:49:30 PM

Title: Help with ngnix:local website hosting required
Post by: chanle on September 12, 2023, 07:49:30 PM
Hi all,
i need to make some files available by http stored on a local opnsense instance.
shall become an iPXE boot system
For this i installed os-nginx Plugin and set it up based on this documentation: https://docs.opnsense.org/manual/how-tos/nginx_hosting.html.
But it does not work as expected and required.

IP of my opnsense is 10.13.2.53; vhost folder is /srv/netboot , user = wheel, permissions = 644 for files and folders.
i get as results:
1. http://10.13.2.253:8080 shows the index.html which is in the root of /srv/netboot = OK.
2. http://10.13.2.253/index.html:8080 redirects to https://10.13.2.253/index.html:8080 -> Page not found from OPNsense Webui.
3. renaming index.html to index.htm -> http://10.13.2.253:8080 gets Access Denied, Web Application Protection by OPNsense.
4. i created a folder files into /srv/netboot and put an index.html into this folder.
http://10.13.2.253/files/:8080 or http://10.13.2.253/files/index.html redirects to https://10.13.2.253/...:8080 Page not found from OPNsense Webui.

see my attached screenshots of the settings.

I believe my error may be in the location settings: the <URL pattern> and <Match type> and/or the <path prefix> and the <File System Root>.

Can someone please help me or put me in the right track.

Thanks
Christoph
Title: Re: Help with ngnix:local website hosting required
Post by: Fright on September 13, 2023, 06:42:16 AM
hi
Quotehttp://10.13.2.253/index.html:8080
is this the exact url you are using? with the port number at the end of the url