I have a node js application that runs on a VPS, and recently we added a blog to the site, we choose WordPress for the blog CMS, for avoiding configuring VPS for PHP and WP we moved blog to another host with cpanel and different ip on a
blog.domain.com subdomain. Now we decide for some reason (SEO and etc) to move from subdomain to subfolder of the main domain.
So my solution so far is that main domain is point to VPS ip, and nginx handle all requests, and if the requested url followed the
/blog/* pattern, the nginx redirect request to the second host ip with cpanel where blog is hosted.
Now I have these questions:
Is this way a proper way to resolve this challenge? Is there better way?
Is redirecting to another IP BAD for SEO? Or it's OK?