Skip to content

Commit

Permalink
vesta-nginx 404 error handler
Browse files Browse the repository at this point in the history
  • Loading branch information
serghey-rodin committed Apr 7, 2014
1 parent ff325d4 commit 5216448
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/rpm/conf/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ http {
ssl_session_cache shared:SSL:10m;
ssl_session_timeout 10m;

error_page 404 /error/index.html;
error_page 404 /error/404/index.html;
error_page 403 /error/index.html;
error_page 500 /error/index.html;

Expand Down
26 changes: 26 additions & 0 deletions web/error/404/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"><head>
<title>404 &mdash; page not found</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<meta name="description" content="internal error"/>
<style type="text/css">
body {font-size:14px; color:#777777; font-family:arial; text-align:center; background: black;}
h1 {font-size:180px; color:#99A7AF; margin: 70px 0 0 0;}
h2 {color: #DE6C5D; font-family: arial; font-size: 24px; font-weight: bold; letter-spacing: -1px; padding: 40px 0 0 0;}
p {width:320px; text-align:center; margin-left:auto;margin-right:auto; margin-top: 30px }
div {width:320px; text-align:center; margin-left:auto;margin-right:auto;}
a:link {color: #34536A;}
a:visited {color: #34536A;}
a:active {color: #34536A;}
a:hover {color: #34536A;}
</style>
</head>

<body>
<h2>Page Not Found</h2>
<img src="/error/vesta.jpg">
<div>
Try start again from <a href="/">home page</a> or go back to <a href="javascript:%20history.go(-1)">previous page</a>
</div>
</body>
</html>

0 comments on commit 5216448

Please sign in to comment.