Created
April 27, 2024 22:26
-
-
Save supermarsx/849f4a0c48681940e3481e63e1a6a60b to your computer and use it in GitHub Desktop.
Nginx return 200 it works page on 403 error
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
error_page 403 =200 /virtual403.html; | |
location = /virtual403.html { | |
add_header Content-Type text/plain; | |
root /data/nginx/default_www; | |
return 200 '<h1>It works!</h1>'; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment