Nginx location config (nginx settings)

2 posts / 0 new
Last post
#1 Thu, 12/20/2018 - 20:13
malde

Nginx location config (nginx settings)

hey,

I have got Centos 7 and a LEMP stack with virtualmin and I want to host a Laravel webapp. For this I need some custome nginx config.

At the moment I follow this guide: https://devmarketer.io/learn/deploy-laravel-5-app-lemp-stack-ubuntu-nginx/

And therefore I need to change some settings in nginx, but I don't know, wehre I can find them:

server {
    listen 80 default_server;
    listen [::]:80 default_server;

    root /home/user/public_html/laravel/public;
    index index.php index.html index.htm index.nginx-debian.html;

    server_name 107.191.44.91; (not my ip)

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

    location ~ \.php$ {
        include snippets/fastcgi-php.conf;
        fastcgi_pass unix:/run/php/php7.0-fpm.sock;
    }

    location ~ /\.ht {
        deny all;
    }
}

Maby someone can guide me through these settings and where I find them in virtualmin. Would be great!!!

Sun, 12/30/2018 - 11:51
Doemela

Look in /etc/nginx

Topic locked