Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Web Site show index.html only in static server #4151

Closed
lnavarroa opened this issue May 29, 2023 · 1 comment
Closed

Web Site show index.html only in static server #4151

lnavarroa opened this issue May 29, 2023 · 1 comment
Labels
kind/bug Something isn't working status/done
Projects

Comments

@lnavarroa
Copy link

What is the problem?

Hi, I have a problem, I did deploy my proyect to my production server, the server is a vps, my website is https://www.lnavarroa.cl, the index.html it show normally, but when i try other uri for example https://www.lnavarroa.cl/cv it doesnt show the /cv page and only show the index page

Paste all your error logs here:

there's no error log

PASTE_HERE (leave the ``` marks)

Paste all relevant code snippets here:

there's no relevant code

PASTE_HERE (leave the ``` marks)

What are detailed steps to reproduce this?

  1. go to https://www.lnavarroa.cl
  2. click on any link inside the website or type other link like https://www.lnavarroa.cl/cl

Run blitz -v and paste the output here:

blitz -v
Blitz version: 2.0.0-beta.27 (global)
Blitz version: 2.0.0-beta.27 (local)
Linux 5.10 | linux-x64 | Node: v18.10.0


 Package manager: npm

  System:
    OS: Linux 5.10 Debian GNU/Linux 11 (bullseye) 11 (bullseye)
    CPU: (4) x64 AMD A12-9700P RADEON R7, 10 COMPUTE CORES 4C+6G
    Memory: 4.64 GB / 6.89 GB
    Shell: 5.1.4 - /bin/bash
  Binaries:
    Node: 18.10.0 - ~/.nvm/versions/node/v18.10.0/bin/node
    Yarn: 1.22.10 - /usr/bin/yarn
    npm: 9.5.1 - ~/.nvm/versions/node/v18.10.0/bin/npm
  npmPackages:
    @blitzjs/auth: 2.0.0-beta.27 => 2.0.0-beta.27 
    @blitzjs/next: 2.0.0-beta.27 => 2.0.0-beta.27 
    @blitzjs/rpc: 2.0.0-beta.27 => 2.0.0-beta.27 
    @prisma/client: 4.6.1 => 4.6.1 
    blitz: 2.0.0-beta.27 => 2.0.0-beta.27 
    next: ^13.3.0 => 13.4.4 
    prisma: 4.6.1 => 4.6.1 
    react: 18.2.0 => 18.2.0 
    react-dom: 18.2.0 => 18.2.0 
    typescript: ^4.8.4 => 4.9.5

Please include below any other applicable logs and screenshots that show your problem:

lnavarroa
lnavarroa_cv

@lnavarroa lnavarroa added kind/bug Something isn't working status/triage labels May 29, 2023
@lnavarroa
Copy link
Author

I have solve my problem. This problem was made by .htaccess file
older file was
Options -MultiViews RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^ index.html [QSA,L]

I have changed to:
`Options -MultiViews
RewriteEngine On

RewriteRule ^$ index.html [QSA,L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.+?)(?<!\.html)\/?$ $1.html [QSA,L]

ErrorDocument 404 /404.html`

And finally this have solve my problem

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working status/done
Projects
Development

No branches or pull requests

2 participants