SciPost Code Repository

Skip to content
Snippets Groups Projects
Commit c8ab9674 authored by Jean-Sébastien Caux's avatar Jean-Sébastien Caux
Browse files

Merge branch 'dev_JSC_20180923_sites_plus_maintenance'

parents ba083cfe 5982080d
No related branches found
No related tags found
No related merge requests found
......@@ -77,6 +77,7 @@ INSTALLED_APPS = (
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'django.contrib.sites',
'django_countries',
'django_extensions',
'django_mathjax',
......@@ -113,9 +114,13 @@ INSTALLED_APPS = (
'funders',
'stats',
'petitions',
'webpack_loader'
'sitesserved',
'webpack_loader',
'maintenancemode',
)
SITE_ID = 1
HAYSTACK_CONNECTIONS = {
'default': {
......@@ -172,6 +177,7 @@ MIDDLEWARE = (
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
'django.middleware.security.SecurityMiddleware',
'maintenancemode.middleware.MaintenanceModeMiddleware',
)
ROOT_URLCONF = 'SciPost_v1.urls'
......
......@@ -22,6 +22,7 @@ django-sphinxdoc==1.5.1
django-silk==2.0.0
django-recaptcha==1.3.1
django-webpack-loader==0.5
django-maintenancemode-2==1.1.11
# Documentation Packages
......
# -*- coding: utf-8 -*-
# Generated by Django 1.11.4 on 2018-09-23 11:35
from __future__ import unicode_literals
from django.db import migrations
def set_site_name(apps, schema_editor):
Sites = apps.get_model('sites', 'Site')
try:
site = Sites.objects.get(id=1)
except Sites.DoesNotExist:
site = Sites(id=1)
site.name = 'SciPost'
site.domain = 'scipost.org'
site.save()
class Migration(migrations.Migration):
dependencies = [
('sites', '0002_alter_domain_unique'),
]
operations = [
migrations.RunPython(set_site_name,
reverse_code=migrations.RunPython.noop),
]
{% extends 'scipost/base.html' %}
{% block pagetitle %}: 503{% endblock pagetitle %}
{% block content %}
<div style="text-align: center;">
<img src="//scipost.org/static/scipost/images/logo_scipost_RGB_HTML_groot.png" alt="SciPost logo" width="240" style="margin-top: 20px; margin-bottom: 20px" />
<h1>We are currently in maintenance, please try again in a few minutes!</h1>
<h2>503</h2>
</div>
{% endblock %}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment