use example.com/pathname/ to host Netlify site, where /pathname/ is the root of my Netlify site.
example.com is a WordPress site hosted somewhere else.
What is working:
- I can get the Netlify site to deploy to a path since that is what the other hosting company said they needed to make this work.
- I’ve sort of followed along with this thread: TL;DR: bash script part of the build process to move all files in Gatsby’s /public folder to a /public/pathname/ folder.
Deploy gatsby site to netlify with --prefix-paths
That script also moves the 404.html page which sort of breaks things. Netlify will build and deploy, but when users hit a route that doesn’t exist, they don’t get my website’s 404 they get Netlify’s generic 404.
I’ve Tried and didn’t work
- Updating the script to move all but the 404.html.
- Update the script to move all files then cd back into the /pathname/ directory and move the 404.html back up to the public/ directory.
This seems all wrong for what I want to do
I sense for what I want to do I’m going about this all wrong.