Issues with my nginx config / aliases / errorsBlank Page: wordpress on nginx+php-fpmphpmyadmin having problems on nginx and php-fpm on RHEL 6NGINX don't parse .php5 as .phpnginx rewrite throw 404 with last and breaknginx PHP files downloading instead of executingFastCGI: Access deniedCodeIgniter nginx rewrite rules for i8ln URL'sHow to serve Autodiscover.xml using Nginxfastcgi issue 7.2 with Nginxlimit_req_zone for the whole PHP

Did I need a visa in 2004 and 2006?

Am I allowed to determine tenets of my contract as a warlock?

Idiom for 'person who gets violent when drunk"

Is fission/fusion to iron the most efficient way to convert mass to energy?

What are some of the expected properties of metallic glasses and some steps to create them? (semi-ELI5)

Jam with honey & without pectin has a saucy consistency always

What is the theme of analysis?

Why do (or did, until very recently) aircraft transponders wait to be interrogated before broadcasting beacon signals?

Are athlete's college degrees discounted by employers and graduate school admissions?

Realistic, logical way for men with medieval-era weaponry to compete with much larger and physically stronger foes

I sent an angry e-mail to my interviewers about a conflict at my home institution. Could this affect my application?

Simple log rotation script

Can we decompose every group element to elements of order 2? (using Cayley's theorem to identificate the group with permutations)

Parsing text written the millitext font

Why are backslashes included in this shell script?

Is it a good security practice to force employees hide their employer to avoid being targeted?

Why would a home insurer offer a discount based on credit score?

How do I type a hyphen in iOS 12?

Why did the Death Eaters wait to reopen the Chamber of Secrets?

Which are the methodologies for interpreting Vedas?

What do I need to do, tax-wise, for a sudden windfall?

Boss making me feel guilty for leaving the company at the end of my internship

The best in flight meal option for those suffering from reflux

Why would a car salesman tell me not to get my credit pulled again?



Issues with my nginx config / aliases / errors


Blank Page: wordpress on nginx+php-fpmphpmyadmin having problems on nginx and php-fpm on RHEL 6NGINX don't parse .php5 as .phpnginx rewrite throw 404 with last and breaknginx PHP files downloading instead of executingFastCGI: Access deniedCodeIgniter nginx rewrite rules for i8ln URL'sHow to serve Autodiscover.xml using Nginxfastcgi issue 7.2 with Nginxlimit_req_zone for the whole PHP






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








0















I have a VPS running CentOS 7, and I'm having some trouble with a few pieces of software that I'm trying to run. My miniflux instance is working, but all the other software I'm trying to setup with aliases is not working. I know the config is a mess as I've just copy and pasted from various install documentations.



Errors



Misc:



directive "index" is not terminated by ";" in /etc/nginx/sites-enabled/mysite.conf:54



Not sure why as index.php is followed by a semicolon



mysite.tld/budget (firefly-iii):



FastCGI sent in stderr: "Access to the script '/var/www/mysite/firefly-iii/public/index.php/login' has been denied (see security.limit_extensions)" while reading response header from upstream, client: myip, server: mysite.tld, request: "GET /budget/login HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm/php-fpm.sock:", host: "www.mysite.tld"



Not sure how to get around this without disabling security.limit_extensions which seems to be a bad idea



mysite.tld/walla (Wallabag):



FastCGI sent in stderr: "Unable to open primary script: /var/www/mysite/app.php (No such file or directory)" while reading response header from upstream, client: 24.246.175.35, server: drewski.xyz, request: "GET /walla HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm/php-fpm.sock:", host: "www.mysite.tld"



For some reason it's trying to find app.php in the wrong folder



mysite.tld/wiki (Bookstack):



directory index of "/var/www/drewski.xyz/BookStack/public" is forbidden, client: myip, server: mysite.tld, request: "GET /wiki/ HTTP/1.1", host: "www.mysite.tld"



It's trying to list the directory index here instead of the index.php file for some reason



Here is my nginx config (with a few identifying infos changed)



server 


root /var/www/mysite;

# Add index.php to the list if you are using PHP
index index.html index.htm index.nginx-debian.html index.php;

server_name mysite.tld www.mysite.tld;

location /
# First attempt to serve request as file, then
# as directory, then fall back to displaying a 404.
try_files $uri $uri/ =404;
# proxy_pass http://localhost:8080;
# proxy_http_version 1.1;
# proxy_set_header Upgrade $http_upgrade;
# proxy_set_header Connection 'upgrade';
# proxy_set_header Host $host;
# proxy_cache_bypass $http_upgrade;


# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
#
location ~ .php$
include fastcgi.conf;
#
# # With php7.0-cgi alone:
# fastcgi_pass 127.0.0.1:9000;
# # With php7.0-fpm:
fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock;


# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
#location ~ /.ht
# deny all;
#

location /flux/
proxy_pass http://127.0.0.1:8080/flux/;
proxy_set_header Host $host;
proxy_redirect off;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;


location /wiki/
alias /var/www/mysite/BookStack/public;
try_files $uri $uri/ /index.php?$query_string;

location ^~ /firefly-iii/
deny all;


location ^~ /budget
alias /var/www/mysite/firefly-iii/public;
try_files $uri $uri/ @budget;

location ~* .php(?:$

location @budget
rewrite ^/budget/(.*)$ /budget/index.php/$1 last;


location ^~ /walla
# try to serve file directly, fallback to app.php
alias /var/www/mysite/wallabag/web;

try_files $uri /app.php$is_args$args;

location ~ ^/app.php(/

server
if ($host = www.mysite.tld)
return 301 https://$host$request_uri;
# managed by Certbot


if ($host = mysite.tld)
return 301 https://$host$request_uri;
# managed by Certbot


listen 80;

server_name mysite.tld www.mysite.tld;
return 404; # managed by Certbot
















share|improve this question




























    0















    I have a VPS running CentOS 7, and I'm having some trouble with a few pieces of software that I'm trying to run. My miniflux instance is working, but all the other software I'm trying to setup with aliases is not working. I know the config is a mess as I've just copy and pasted from various install documentations.



    Errors



    Misc:



    directive "index" is not terminated by ";" in /etc/nginx/sites-enabled/mysite.conf:54



    Not sure why as index.php is followed by a semicolon



    mysite.tld/budget (firefly-iii):



    FastCGI sent in stderr: "Access to the script '/var/www/mysite/firefly-iii/public/index.php/login' has been denied (see security.limit_extensions)" while reading response header from upstream, client: myip, server: mysite.tld, request: "GET /budget/login HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm/php-fpm.sock:", host: "www.mysite.tld"



    Not sure how to get around this without disabling security.limit_extensions which seems to be a bad idea



    mysite.tld/walla (Wallabag):



    FastCGI sent in stderr: "Unable to open primary script: /var/www/mysite/app.php (No such file or directory)" while reading response header from upstream, client: 24.246.175.35, server: drewski.xyz, request: "GET /walla HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm/php-fpm.sock:", host: "www.mysite.tld"



    For some reason it's trying to find app.php in the wrong folder



    mysite.tld/wiki (Bookstack):



    directory index of "/var/www/drewski.xyz/BookStack/public" is forbidden, client: myip, server: mysite.tld, request: "GET /wiki/ HTTP/1.1", host: "www.mysite.tld"



    It's trying to list the directory index here instead of the index.php file for some reason



    Here is my nginx config (with a few identifying infos changed)



    server 


    root /var/www/mysite;

    # Add index.php to the list if you are using PHP
    index index.html index.htm index.nginx-debian.html index.php;

    server_name mysite.tld www.mysite.tld;

    location /
    # First attempt to serve request as file, then
    # as directory, then fall back to displaying a 404.
    try_files $uri $uri/ =404;
    # proxy_pass http://localhost:8080;
    # proxy_http_version 1.1;
    # proxy_set_header Upgrade $http_upgrade;
    # proxy_set_header Connection 'upgrade';
    # proxy_set_header Host $host;
    # proxy_cache_bypass $http_upgrade;


    # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
    #
    location ~ .php$
    include fastcgi.conf;
    #
    # # With php7.0-cgi alone:
    # fastcgi_pass 127.0.0.1:9000;
    # # With php7.0-fpm:
    fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock;


    # deny access to .htaccess files, if Apache's document root
    # concurs with nginx's one
    #
    #location ~ /.ht
    # deny all;
    #

    location /flux/
    proxy_pass http://127.0.0.1:8080/flux/;
    proxy_set_header Host $host;
    proxy_redirect off;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header X-Forwarded-Proto $scheme;


    location /wiki/
    alias /var/www/mysite/BookStack/public;
    try_files $uri $uri/ /index.php?$query_string;

    location ^~ /firefly-iii/
    deny all;


    location ^~ /budget
    alias /var/www/mysite/firefly-iii/public;
    try_files $uri $uri/ @budget;

    location ~* .php(?:$

    location @budget
    rewrite ^/budget/(.*)$ /budget/index.php/$1 last;


    location ^~ /walla
    # try to serve file directly, fallback to app.php
    alias /var/www/mysite/wallabag/web;

    try_files $uri /app.php$is_args$args;

    location ~ ^/app.php(/

    server
    if ($host = www.mysite.tld)
    return 301 https://$host$request_uri;
    # managed by Certbot


    if ($host = mysite.tld)
    return 301 https://$host$request_uri;
    # managed by Certbot


    listen 80;

    server_name mysite.tld www.mysite.tld;
    return 404; # managed by Certbot
















    share|improve this question
























      0












      0








      0








      I have a VPS running CentOS 7, and I'm having some trouble with a few pieces of software that I'm trying to run. My miniflux instance is working, but all the other software I'm trying to setup with aliases is not working. I know the config is a mess as I've just copy and pasted from various install documentations.



      Errors



      Misc:



      directive "index" is not terminated by ";" in /etc/nginx/sites-enabled/mysite.conf:54



      Not sure why as index.php is followed by a semicolon



      mysite.tld/budget (firefly-iii):



      FastCGI sent in stderr: "Access to the script '/var/www/mysite/firefly-iii/public/index.php/login' has been denied (see security.limit_extensions)" while reading response header from upstream, client: myip, server: mysite.tld, request: "GET /budget/login HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm/php-fpm.sock:", host: "www.mysite.tld"



      Not sure how to get around this without disabling security.limit_extensions which seems to be a bad idea



      mysite.tld/walla (Wallabag):



      FastCGI sent in stderr: "Unable to open primary script: /var/www/mysite/app.php (No such file or directory)" while reading response header from upstream, client: 24.246.175.35, server: drewski.xyz, request: "GET /walla HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm/php-fpm.sock:", host: "www.mysite.tld"



      For some reason it's trying to find app.php in the wrong folder



      mysite.tld/wiki (Bookstack):



      directory index of "/var/www/drewski.xyz/BookStack/public" is forbidden, client: myip, server: mysite.tld, request: "GET /wiki/ HTTP/1.1", host: "www.mysite.tld"



      It's trying to list the directory index here instead of the index.php file for some reason



      Here is my nginx config (with a few identifying infos changed)



      server 


      root /var/www/mysite;

      # Add index.php to the list if you are using PHP
      index index.html index.htm index.nginx-debian.html index.php;

      server_name mysite.tld www.mysite.tld;

      location /
      # First attempt to serve request as file, then
      # as directory, then fall back to displaying a 404.
      try_files $uri $uri/ =404;
      # proxy_pass http://localhost:8080;
      # proxy_http_version 1.1;
      # proxy_set_header Upgrade $http_upgrade;
      # proxy_set_header Connection 'upgrade';
      # proxy_set_header Host $host;
      # proxy_cache_bypass $http_upgrade;


      # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
      #
      location ~ .php$
      include fastcgi.conf;
      #
      # # With php7.0-cgi alone:
      # fastcgi_pass 127.0.0.1:9000;
      # # With php7.0-fpm:
      fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock;


      # deny access to .htaccess files, if Apache's document root
      # concurs with nginx's one
      #
      #location ~ /.ht
      # deny all;
      #

      location /flux/
      proxy_pass http://127.0.0.1:8080/flux/;
      proxy_set_header Host $host;
      proxy_redirect off;
      proxy_set_header X-Real-IP $remote_addr;
      proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
      proxy_set_header X-Forwarded-Proto $scheme;


      location /wiki/
      alias /var/www/mysite/BookStack/public;
      try_files $uri $uri/ /index.php?$query_string;

      location ^~ /firefly-iii/
      deny all;


      location ^~ /budget
      alias /var/www/mysite/firefly-iii/public;
      try_files $uri $uri/ @budget;

      location ~* .php(?:$

      location @budget
      rewrite ^/budget/(.*)$ /budget/index.php/$1 last;


      location ^~ /walla
      # try to serve file directly, fallback to app.php
      alias /var/www/mysite/wallabag/web;

      try_files $uri /app.php$is_args$args;

      location ~ ^/app.php(/

      server
      if ($host = www.mysite.tld)
      return 301 https://$host$request_uri;
      # managed by Certbot


      if ($host = mysite.tld)
      return 301 https://$host$request_uri;
      # managed by Certbot


      listen 80;

      server_name mysite.tld www.mysite.tld;
      return 404; # managed by Certbot
















      share|improve this question














      I have a VPS running CentOS 7, and I'm having some trouble with a few pieces of software that I'm trying to run. My miniflux instance is working, but all the other software I'm trying to setup with aliases is not working. I know the config is a mess as I've just copy and pasted from various install documentations.



      Errors



      Misc:



      directive "index" is not terminated by ";" in /etc/nginx/sites-enabled/mysite.conf:54



      Not sure why as index.php is followed by a semicolon



      mysite.tld/budget (firefly-iii):



      FastCGI sent in stderr: "Access to the script '/var/www/mysite/firefly-iii/public/index.php/login' has been denied (see security.limit_extensions)" while reading response header from upstream, client: myip, server: mysite.tld, request: "GET /budget/login HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm/php-fpm.sock:", host: "www.mysite.tld"



      Not sure how to get around this without disabling security.limit_extensions which seems to be a bad idea



      mysite.tld/walla (Wallabag):



      FastCGI sent in stderr: "Unable to open primary script: /var/www/mysite/app.php (No such file or directory)" while reading response header from upstream, client: 24.246.175.35, server: drewski.xyz, request: "GET /walla HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm/php-fpm.sock:", host: "www.mysite.tld"



      For some reason it's trying to find app.php in the wrong folder



      mysite.tld/wiki (Bookstack):



      directory index of "/var/www/drewski.xyz/BookStack/public" is forbidden, client: myip, server: mysite.tld, request: "GET /wiki/ HTTP/1.1", host: "www.mysite.tld"



      It's trying to list the directory index here instead of the index.php file for some reason



      Here is my nginx config (with a few identifying infos changed)



      server 


      root /var/www/mysite;

      # Add index.php to the list if you are using PHP
      index index.html index.htm index.nginx-debian.html index.php;

      server_name mysite.tld www.mysite.tld;

      location /
      # First attempt to serve request as file, then
      # as directory, then fall back to displaying a 404.
      try_files $uri $uri/ =404;
      # proxy_pass http://localhost:8080;
      # proxy_http_version 1.1;
      # proxy_set_header Upgrade $http_upgrade;
      # proxy_set_header Connection 'upgrade';
      # proxy_set_header Host $host;
      # proxy_cache_bypass $http_upgrade;


      # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
      #
      location ~ .php$
      include fastcgi.conf;
      #
      # # With php7.0-cgi alone:
      # fastcgi_pass 127.0.0.1:9000;
      # # With php7.0-fpm:
      fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock;


      # deny access to .htaccess files, if Apache's document root
      # concurs with nginx's one
      #
      #location ~ /.ht
      # deny all;
      #

      location /flux/
      proxy_pass http://127.0.0.1:8080/flux/;
      proxy_set_header Host $host;
      proxy_redirect off;
      proxy_set_header X-Real-IP $remote_addr;
      proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
      proxy_set_header X-Forwarded-Proto $scheme;


      location /wiki/
      alias /var/www/mysite/BookStack/public;
      try_files $uri $uri/ /index.php?$query_string;

      location ^~ /firefly-iii/
      deny all;


      location ^~ /budget
      alias /var/www/mysite/firefly-iii/public;
      try_files $uri $uri/ @budget;

      location ~* .php(?:$

      location @budget
      rewrite ^/budget/(.*)$ /budget/index.php/$1 last;


      location ^~ /walla
      # try to serve file directly, fallback to app.php
      alias /var/www/mysite/wallabag/web;

      try_files $uri /app.php$is_args$args;

      location ~ ^/app.php(/

      server
      if ($host = www.mysite.tld)
      return 301 https://$host$request_uri;
      # managed by Certbot


      if ($host = mysite.tld)
      return 301 https://$host$request_uri;
      # managed by Certbot


      listen 80;

      server_name mysite.tld www.mysite.tld;
      return 404; # managed by Certbot













      nginx centos7 php-fpm alias php7






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked May 28 at 23:31









      HiroHiro

      11




      11




















          0






          active

          oldest

          votes












          Your Answer








          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "2"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f969239%2fissues-with-my-nginx-config-aliases-errors%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Server Fault!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f969239%2fissues-with-my-nginx-config-aliases-errors%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Wikipedia:Vital articles Мазмуну Biography - Өмүр баян Philosophy and psychology - Философия жана психология Religion - Дин Social sciences - Коомдук илимдер Language and literature - Тил жана адабият Science - Илим Technology - Технология Arts and recreation - Искусство жана эс алуу History and geography - Тарых жана география Навигация менюсу

          Bruxelas-Capital Índice Historia | Composición | Situación lingüística | Clima | Cidades irmandadas | Notas | Véxase tamén | Menú de navegacióneO uso das linguas en Bruxelas e a situación do neerlandés"Rexión de Bruxelas Capital"o orixinalSitio da rexiónPáxina de Bruselas no sitio da Oficina de Promoción Turística de Valonia e BruxelasMapa Interactivo da Rexión de Bruxelas-CapitaleeWorldCat332144929079854441105155190212ID28008674080552-90000 0001 0666 3698n94104302ID540940339365017018237

          What should I write in an apology letter, since I have decided not to join a company after accepting an offer letterShould I keep looking after accepting a job offer?What should I do when I've been verbally told I would get an offer letter, but still haven't gotten one after 4 weeks?Do I accept an offer from a company that I am not likely to join?New job hasn't confirmed starting date and I want to give current employer as much notice as possibleHow should I address my manager in my resignation letter?HR delayed background verification, now jobless as resignedNo email communication after accepting a formal written offer. How should I phrase the call?What should I do if after receiving a verbal offer letter I am informed that my written job offer is put on hold due to some internal issues?Should I inform the current employer that I am about to resign within 1-2 weeks since I have signed the offer letter and waiting for visa?What company will do, if I send their offer letter to another company