Set up wordpress in subfolder alongside Django for example

PHOTO EMBED

Sat Feb 13 2021 14:25:20 GMT+0000 (Coordinated Universal Time)

Saved by @alex.balaboshko #nginx #wordpress

server {
  ...
    location /wp {
        alias /home/user/www/.../wordpress/;
        index index.php index.html index.htm;
        try_files $uri $uri/ /wp/index.php?$is_args$args;
    }
    location ~ \.php$ {
        root /home/user/www/.../wordpress/;
        fastcgi_pass unix:/var/run/php/php7.2-fpm.sock;
        fastcgi_split_path_info ^/wp(/.+\.php)(.*)$;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        include fastcgi_params;
    }

  ...
}
content_copyCOPY