Vesta Control Panel - Forum

Community Forum

Skip to content

Advanced search
  • Quick links
    • Main site
    • Github repo
    • Google Search
  • FAQ
  • Login
  • Register
  • Board index Main Section General Discussion
  • Search

Flarum

General questions about VestaCP
Post Reply
  • Print view
Advanced search
7 posts • Page 1 of 1
insha
Posts: 9
Joined: Tue Feb 02, 2016 4:02 am

Flarum
  • Quote

Post by insha » Tue Jul 26, 2016 6:21 pm

Hello, i have installed flarum http://flarum.org/docs/installation/ on my domain
I use VestaCP with nginx php-fpm
Where to put exactly nginx in my nginx.conf file ?
Top

skurudo
VestaCP Team
Posts: 8099
Joined: Fri Dec 26, 2014 2:23 pm
Contact:
Contact skurudo
Website Facebook Google+ Skype
Twitter

Re: Flarum
  • Quote

Post by skurudo » Wed Jul 27, 2016 6:53 am

discuss.flarum.org don't say anything about this? ;-)
Top

skurudo
VestaCP Team
Posts: 8099
Joined: Fri Dec 26, 2014 2:23 pm
Contact:
Contact skurudo
Website Facebook Google+ Skype
Twitter

Re: Flarum
  • Quote

Post by skurudo » Wed Jul 27, 2016 6:56 am

Try to use this config and make changes for you or search with google something more suitable:
https://gist.github.com/novomirskoy/309 ... b2ffcf2611

PS: It's not tested by me.
Top

skurudo
VestaCP Team
Posts: 8099
Joined: Fri Dec 26, 2014 2:23 pm
Contact:
Contact skurudo
Website Facebook Google+ Skype
Twitter

Re: Flarum
  • Quote

Post by skurudo » Wed Jul 27, 2016 6:59 am

Hmmm
On Flarum site is config section for nginx: http://flarum.org/docs/installation/

Code: Select all

    location / { try_files $uri $uri/ /index.php?$query_string; }
    location /api { try_files $uri $uri/ /api.php?$query_string; }
    location /admin { try_files $uri $uri/ /admin.php?$query_string; }

    location /flarum {
        deny all;
        return 404;
    }

    location ~* \.php$ {
        fastcgi_split_path_info ^(.+.php)(/.+)$;
        fastcgi_pass unix:/var/run/php5-fpm.sock;
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_param HTTP_PROXY ""; # Fix for https://httpoxy.org/ vulnerability
        fastcgi_index index.php;
    }
    
    location ~* \.html$ {
        expires -1;
    }

    location ~* \.(css|js|gif|jpe?g|png)$ {
        expires 1M;
        add_header Pragma public;
        add_header Cache-Control "public, must-revalidate, proxy-revalidate";
    }
Top

saosangmo
Posts: 20
Joined: Sun Sep 21, 2014 2:27 pm
Contact:
Contact saosangmo
Website Google+

Os: Ubuntu 17x
Web: nginx + php-fpm
Re: Flarum
  • Quote

Post by saosangmo » Tue Sep 24, 2019 6:59 pm

In the .conf of your vhost, you only change 2 places:

1. at the line

Code: Select all

root        /home/vip/web/vipsedan.vn/public_html;
change to

Code: Select all

root        /home/vip/web/vipsedan.vn/public_html/public;
....

2. at the line

Code: Select all

    location / {
change to

Code: Select all

    location / {
        try_files $uri $uri/ /index.php?$query_string;
Hope it help you!
Top

SanTi
Posts: 39
Joined: Tue Jan 08, 2019 1:23 am

Os: CentOS 6x
Web: nginx + php-fpm
Re: Flarum
  • Quote

Post by SanTi » Sat Oct 12, 2019 6:05 pm

How can I do it if I want to install flarum to public_html/forum/public ?
Wordpress is installed before and I install flarum to forum subfolder. I guess that I get error if I change nginx file's root line.
Top

SanTi
Posts: 39
Joined: Tue Jan 08, 2019 1:23 am

Os: CentOS 6x
Web: nginx + php-fpm
Re: Flarum
  • Quote

Post by SanTi » Sat Oct 12, 2019 9:26 pm

saosangmo wrote: ↑
Tue Sep 24, 2019 6:59 pm
In the .conf of your vhost, you only change 2 places:

1. at the line

Code: Select all

root        /home/vip/web/vipsedan.vn/public_html;
change to

Code: Select all

root        /home/vip/web/vipsedan.vn/public_html/public;
....

2. at the line

Code: Select all

    location / {
change to

Code: Select all

    location / {
        try_files $uri $uri/ /index.php?$query_string;
Hope it help you!
Sorry but it does not work for me : (
Top


Post Reply
  • Print view

7 posts • Page 1 of 1

Return to “General Discussion”



  • Board index
  • All times are UTC
  • Delete all board cookies
  • The team
Powered by phpBB® Forum Software © phpBB Limited
*Original Author: Brad Veryard
*Updated to 3.2 by MannixMD
 

 

Login  •  Register

I forgot my password