mirror of https://github.com/kf7eel/hbnet
limit news on homepage, continue docker stuff
This commit is contained in:
parent
7fc0436c0b
commit
206febcbb3
|
|
@ -18,6 +18,8 @@ services:
|
|||
- ./hbnet/web_service/data:/opt/hbnet_web/data:rw
|
||||
# NGINX logs
|
||||
- ./hbnet/log/web_service:/var/log/nginx:rw
|
||||
# Non SSL config
|
||||
- ./hbnet/web_service/hbnet.conf:/etc/nginx/sites-enabled/hbnet.conf
|
||||
# Path to custom NGINX config for SSL
|
||||
#- ./hbnet/web_service/hbnet_ssl.conf:/etc/nginx/sites-enabled/hbnet.conf
|
||||
# Path to SSL certificates
|
||||
|
|
|
|||
|
|
@ -813,7 +813,7 @@ By using this service, you agree not to do anything malicious. You agree to use
|
|||
content = ''
|
||||
# try:
|
||||
l_news = News.query.order_by(News.time.desc()).first()
|
||||
return render_template('index.html', news = Markup(content), content_block = Markup(home_text.data), text = l_news.text, subject = l_news.subject, date = l_news.date, news_id = l_news.id)
|
||||
return render_template('index.html', news = Markup(content), content_block = Markup(home_text.data), text = l_news.text[:300] + '...', subject = l_news.subject, date = l_news.date, news_id = l_news.id)
|
||||
# except:
|
||||
# content = ''
|
||||
# return render_template('index.html', content_block = Markup(home_text.data))
|
||||
|
|
|
|||
Loading…
Reference in New Issue