Site icon Hip-Hop Website Design and Development

Cant get wordpress to work on subdirectory

I have an ubuntu server.

I already had nginx and some page there which works.

I wanted to add wordpress on /blog path

I installed wordpress using this setup
https://ubuntu.com/tutorials/install-and-configure-wordpress#1-overview

(I didnt start step 7 because i cant get the page to show up)

With the setup wordpress lives in /srv/www/wordpress where i see index.php and everything else

i did modify my nginx conf file

server {
  
  root /var/www/example;

  server_name example.com www.example.com;

  index index.html index.htm index.nginx-debian.html;

  ...

  location / {
    try_files $uri $uri/ =404;
  }

  location ^~ /blog {
    root /srv/www/wordpress;
    index index.php;
    try_files $uri $uri/ /index.php?$args;

    location ~ .php$ {
        try_files $uri =404;
        include       fastcgi_params;
        fastcgi_pass  127.0.0.1:8090;
    }
  }

  ...

The new part is location ^~ /blog ... and i am unsure how it should look like.

Right now as it is if i go to example.com/blog the browser offers me to download some file. (its a short php file with the name "download")

Thx for any suggestions