Jump to content

Recommended Posts

Hey,

 

I haven't found any usefull informations about nginx. Maybe someone here can help

 

I'm currently running

Quote

 

       location /aZU0XBqAa7qt2XNhrbdsk{

            auth_basic "Admin access";

            auth_basic_user_file /usr/local/www/access_login;

            alias /usr/local/www/nginx/DomainXYZ/aZU0XBqAa7qt2XNhrbdsk;

        }

 

        location / {

            try_files $uri $uri/ /index.php?$query_string;

        }

 

        location ~ \.php$ {

            try_files $uri =404;

            fastcgi_split_path_info ^(.+\.php)(/.+)$;

            fastcgi_index index.php;

            fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;

            fastcgi_pass 127.0.0.1:9000;

            include fastcgi_params;

        }

 

Location aZU0XBqAa7qt2XNhrbdsk is linked to phpmyadmin with secured auth_basic. Problem is this:

 

When I'm at 127.0.0.1/index.php, the website display works as it should, when you go into other page from index.php to let's say download.php, you get 404 Not Found.

PhpMyAdmin doesn't have the issue with going within the app anywhere, but the root directory does have this problem.

Would anyone know, how to configure the nginx.conf? Parametrs are transfer within nginx, so I'm not really sure, where to look -> what to look for

 

Thanks in advance brothers

Link to comment
https://metin2.dev/topic/31089-nginx-config/
Share on other sites

  • 3 weeks later...
  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Try this 

 

Quote

server {
    listen 80;
    server_name example.com;  # Replace with your domain

    location /aZU0XBqAa7qt2XNhrbdsk {
        auth_basic "Admin access";
        auth_basic_user_file /usr/local/www/access_login;
        alias /usr/local/www/nginx/DomainXYZ/aZU0XBqAa7qt2XNhrbdsk;
    }

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

    location ~ \.php$ {
        try_files $uri =404;
        fastcgi_split_path_info ^(.+\.php)(/.+)$;
        fastcgi_index index.php;
        fastcgi_param SCRIPT_FILENAME $request_filename;
        fastcgi_pass 127.0.0.1:9000;  # Adjust this if your PHP-FPM is running on a different port
        include fastcgi_params;
    }
}
 

 

Link to comment
https://metin2.dev/topic/31089-nginx-config/#findComment-158975
Share on other sites

Don't use any images from : imgur, turkmmop, freakgamers, inforge, hizliresim... Or your content will be deleted without notice...
Use : https://metin2.download/media/add/

Please use https://metin2.download/ when uploading files smaller than 100MB, otherwise the approval will take longer due to manual upload.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.