2
0
mirror of https://github.com/offen/website.git synced 2024-11-22 17:10:29 +01:00

Merge pull request #146 from offen/404-nginx

Add nginx configuration for 404 page, display build date in footer
This commit is contained in:
Hendrik Niefeld 2019-10-02 12:23:52 +02:00 committed by GitHub
commit 1e2336a4b1
4 changed files with 14 additions and 3 deletions

View File

@ -45,6 +45,13 @@ http {
location /auditorium/ {
try_files $uri $uri/ /auditorium/index.html;
}
error_page 404 /404.html;
location = /404.html {
internal;
root /www/data;
add_header X-Robots-Tag "noindex, nofollow, nosnippet, noarchive" always;
}
}
}

View File

@ -1,7 +1,7 @@
Title: Page not found | offen
description: offen is a free and open source analytics software for websites and web applications that allows respectful handling of data.
save_as: 404/index.html
href: /404/
save_as: 404.html
href: /404.html
![Page not Found](/theme/images/content-404.webp){:class="image-text-560-315"}

View File

@ -1,3 +1,5 @@
from datetime import datetime
from calendar import month_name
# If your site is available via HTTPS, make sure SITEURL begins with https://
RELATIVE_URLS = False
@ -7,6 +9,8 @@ PATH = 'content'
TIMEZONE = 'Europe/Berlin'
DEFAULT_LANG = 'en'
BUILD_DATE = '{} {}'.format(month_name[datetime.today().month], datetime.today().year)
# Feed generation is usually not desired when developing
FEED_ALL_ATOM = None
CATEGORY_FEED_ATOM = None

View File

@ -134,7 +134,7 @@
</p>
</div>
<div class="footer-card">
October 2019
{{ BUILD_DATE }}
</div>
</div>
</div>