Reputation: 96
Running npm build using github actions and then deploying to github pages using my gh-pages branch. The index.html file loads fine from https://user.github.io/, but all other http requests go to that url instead of where the resource is, https://user.github.io/Project/
Here is one of the requests: GET /static/css/main.15693543.css HTTP/2 Host: user.github.io User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:127.0) Gecko/20100101 Firefox/127.0 Accept: text/css,/;q=0.1 Accept-Language: en-US,en;q=0.5 Accept-Encoding: gzip, deflate, br, zstd Connection: keep-alive Referer: https:/user.github.io/Project/ Sec-Fetch-Dest: style Sec-Fetch-Mode: no-cors Sec-Fetch-Site: same-origin Priority: u=2 TE: trailers
*Note I replaced urls with user and Project
The file is there when I go to https://user.github.io/static/css/main.15693543.css. Just need to build where all file locations point to Project/static/~ and not /static/~
Here is the root html straight from the build:
Tried:
My temporary solution is a simple find and replace
Edit: The issue may be that going to https://user.github.io/ gives github 404, going to https://user.github.io/Project gives the index.html file. Requests for resources go to https://user.github.io/, which is 404
Upvotes: 0
Views: 70