This repository was archived by the owner on Nov 20, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 32
Nginx Rules for the BFAdminCP
Prophet731 edited this page Mar 5, 2015
·
2 revisions
This is an example server configuration block. Note how the root path is set to the public folder of the BFAdminCP. Make sure you do this as this is how it was designed to work.
server {
listen 80 default_server;
root /var/www/laravel/public/;
index index.php index.html index.htm;
location / {
try_files $uri $uri/ /index.php$is_args$args;
}
# pass the PHP scripts to FastCGI server listening on /var/run/php5-fpm.sock
location ~ \.php$ {
try_files $uri /index.php =404;
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
}
If you are using Ajenti with the web hosting addon then you only need this code block to be put under Advanced > Custom configuration.
location / {
try_files $uri $uri/ /index.php$is_args$args;
}
This tutorial explains how to setup the application (built with laravel) with Nginx.