stefanpejcic / OpenPanel

A highly customizable web hosting control panel built with Docker 🐳
https://openpanel.com
216 stars 33 forks source link

Flarum template for Nginx #261

Open stefanpejcic opened 2 weeks ago

stefanpejcic commented 2 weeks ago

OpenPanel version(s) affected

0.3.5

What OS are you using?

Ubuntu

Description

on OpenPanel > AutoInstaller > Flarum for Apache we do:

    # BEGIN Flarum
    RewriteEngine on
    RewriteCond %{REQUEST_URI} !^public
    RewriteRule ^(.*)$ public/$1 [L]
    # END Flarum

in .htaccess file, but for nginx we need something like:

    # BEGIN Flarum
    if (!-e $request_filename) {
        rewrite ^(.*)$ /public/$1 last;
    }
    # END Flarum

How to reproduce

and configure /public to be /

Possible Solution

No response

Additional Context

No response