so @funkysoul was kind of right in terms on installing php.
It was still a nightmare to setup nginx the way i needed it, my solution is:
location / {
try_files $uri $uri/ =404;
}
location ^~ /blog {
alias /srv/www/wordpress;
try_files $uri $uri/ /index.php?/$1 last;
location ~ \.php$ {
index index.php;
include snippets/fastcgi-php.conf;
fastcgi_param SCRIPT_FILENAME $request_filename;
fastcgi_pass unix:/var/run/php/php7.4-fpm.sock;
}
}
location ~ \.php$ {
include snippets/fastcgi-php.conf;
fastcgi_pass unix:/var/run/php/php7.4-fpm.sock;
}
this finally works, as in returns files under “/” with one root and returns wordpress php files under “/blog” with different root
Related Posts:
- How can I have nginx serve WordPress at /blog?
- Serve WordPress site as root domain with WordPress files in subdirectory in nginx server
- How to install WordPress on sub directory in ubuntu 16.4 in same vhost with AngularJS
- How to Install WP to Subdomain but Serve on Subdirectory?
- PHP – Move a file into a different folder on the server
- Compare 2 directories in windows
- get_template_directory() vs bloginfo( ‘template_directory’ ) vs TEMPLATEPATH
- Change upload directory for PDF files
- What’s the purpose of index.php in wp-content directory? [duplicate]
- How do I serve static content on same domain as WordPress
- Can I change get_template_directory_uri()?
- NGinx + WordPress Subdomain Multi with core in Subdirectory
- Custom Post Type Archive in Sub Folder
- How to point my domain to a WordPress install in a sub-directory?
- Can I put my WordPress theme files in another folder?
- Multiple domains for multiple single installs
- How to Create Hierarchical Directory for Nation Wide Mental Health Services
- How do I set up single sign on for multiple WP installs across the same domain?
- Why doesn’t WP_PLUGIN_DIR definition use DIRECTORY_SEPARATOR?
- How to copy one folder to another folder recursively
- issues including a file from a plugin directory
- Disable to create folders for every years and months in uploads folder
- local folder permissions vs chown — security considerations
- How is a student directory best handled in WordPress?
- How would you detect if WordPress is installed in a subdirectory (not root)?
- Two identical wp-includes directories on server
- What is the recommend directory in which I can upload a new library?
- Second wordpress installation on subdirectory
- Install theme on multiple domains
- WordPress multisite subdirectory on nginx behind reverse proxy
- how to create a folder in wordpress
- Accessing WordPress installation in its own directory at domain root
- Right permissions to WordPress directory
- more than one upload directory?
- Subdomain redirects to subdirectory [closed]
- 2 WordPress sites in 2 sibling folders on one domain
- Main WP page and subfolder WP with the same name. How to prioritize for main Wp
- Auto-create a post with last 10 images in WordPress directory
- Copy Folder to another Folder using WP Filesystem
- Unable to update WordPress or install plugins/themes
- Session Expired when WordPress Address (URL) and Site Address (URL) are different
- After changing wp from subdirectory to root I can’t preview any changes to a page or post
- Moved WordPress site to new server, directory permissions not working correctly
- Moving from one test to multiple final environments
- WordPress in a sub directory but not images
- Should I install blog on subdomain or subdirectory?
- Hiding Directory Path
- Moving WP from /blog to root directory
- Should custom directories be created under the wp-content directory?
- Use of Folders within WordPress
- Hosting my WordPress site out of a subdirectory
- Theme file structure best practice
- Path in dev server works; same path in prod server is broken
- What is wp-admin/meta for?
- google xml sitemap won’t work on directory install
- What plugins create a directory on the root directory of WordPress? [closed]
- How can i shift my chosen posts to a subdirectory?
- Where to put robot.txt and sitemap.xml for wordpress installed in its own directory
- How to disable directory files from accessing?
- Move WordPress from Root to Subfolder
- WordPress not handling subdirectory properly
- Wp-CLI not working with WordPress installed with composer
- How to visit php file in my custom directory under site root directory
- Does WordPress refer to any files outside of the main install folder (and database)?
- WordPress File Structure
- Getting Internal server in sub folder pages
- Impossible to index an upload folder with 10k files
- Moving wordpress from /dir to main folder
- Giving WordPress Its Own Directory together with index.html
- wordpress sub-directory sites on a sub-domain?
- Trying to setup a dev subdomain, but url loads as /dev/ instead
- Want to change my site root
- Best way to transfer WordPress install to root of directory when I’m ready to launch?
- Powering only a subfolder with WordPress on a LAMP stack with an nginx reverse proxy
- Is there a way to create folders restricted to specific users to open?
- add 360 (non-WordPress) tours in a subfolder with the same name as the main (WordPress)page of the 360 tours
- WordPress page for one specific page on Google Cloud hosted website?
- WordPress hosted on subfolder of domain causing customizer to constantly refresh and is requesting jquery from root domain
- WordPress Bedrock breaking plugin links
- Editing Listings in a Business Directory
- Bedrock WordPress retro-porting to standard WP installation: is this allowed?
- I need advice for creating native WordPress directory site based on native WordPress functionality only
- Change the WordPress files structure
- Downloadable content file structure
- WordPress makes 404 error when going to domain folder
- Moving wp-config.php when you have a second wordpress install
- Using same root header in subfolder wp blog – Header disapears on Single Posts
- Run multiple installs using the same wp-admin & wp-includes?
- How do I get WP site to show in both root and sub-directory
- How to replace a wordpress installation in root directory with another in a subdirectory?
- Move WordPress with changed name ‘wp-content’
- Create Subfolder that always displays template file
- FTPS Uploads – wp-content cannot be found
- Index (Home) page not displayed when running wordpress in a subdirectory
- How do you create a development site into a subdirectory of the live site?
- Hide/Remove Wp Directory /wp-content/uploads/
- Moving wordpress from TLD to sub-folder (URL structure only)
- @font-face Paths Don’t Seem to be working properly
- Multisite Sub-directories Installation
- Could moving my WordPress installation from /var/www/html/ to /var/www/ break the application?