Attention ! Gitlab fournissant maintenant nativement des certificats Let’s Encrypt aux domaines personnalisés des Gitlab Pages, nous avons coupé notre service qui le faisait automatiquement pour vous.

Il est impératif, pour que votre domaine personnalisé continue à avoir un certificat Let’s Encrypt à jour, d’activer la fonctionnalité native dans les paramètres de votre projet. Cette activation remplacera votre certificat actuel par un nouveau certificat Let’s Encrypt géré par Gitlab.

Voir les détails sur https://docs.framasoft.org/fr/gitlab/gitlab-pages-le.html

Commit 8b8c2360 authored by Mathieu Bridon's avatar Mathieu Bridon

Fool around with the settings

This allows reusing the whole Ideascube settings system, so we don't
need to redo it all.

This requires changes in Ideascube though:

    ideascube!900
parent 42a436d0
__pycache__
/.cache
/storage
from ideascube.conf.base import * # pragma: no flakes
# Now override settings just like you would for Ideascube.
LANGUAGE_CODE = 'fr'
from ideascube.conf.dev import * # pragma: no flakes
......@@ -12,109 +12,23 @@ https://docs.djangoproject.com/en/1.11/ref/settings/
import os
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
IRFI_BASE_DIR = os.path.dirname(os.path.dirname(__file__))
os.environ['STORAGE_ROOT'] = os.environ.get(
'STORAGE_ROOT', os.path.join(IRFI_BASE_DIR, 'storage'))
os.environ['IDEASCUBE_SETTINGS_PACKAGE'] = 'irfi'
# Quick-start development settings - unsuitable for production
# See https://docs.djangoproject.com/en/1.11/howto/deployment/checklist/
# SECURITY WARNING: keep the secret key used in production secret!
SECRET_KEY = 'p=w6#%oek^z(+e@f@am2t6upm)ac73g2qav45+l-(v03_y0hlj'
# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = True
ALLOWED_HOSTS = []
# Application definition
INSTALLED_APPS = [
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
]
MIDDLEWARE = [
'django.middleware.security.SecurityMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.common.CommonMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
]
# Reuse most of the Ideascube settings
from ideascube.settings import * # pragma: no flakes
# And add our stuff
INSTALLED_APPS = list(INSTALLED_APPS) + ['irfi'] # pragma: no flakes
ROOT_URLCONF = 'irfi.urls'
TEMPLATES = [
{
'BACKEND': 'django.template.backends.django.DjangoTemplates',
'DIRS': [],
'APP_DIRS': True,
'OPTIONS': {
'context_processors': [
'django.template.context_processors.debug',
'django.template.context_processors.request',
'django.contrib.auth.context_processors.auth',
'django.contrib.messages.context_processors.messages',
],
},
},
]
WSGI_APPLICATION = 'irfi.wsgi.application'
# Database
# https://docs.djangoproject.com/en/1.11/ref/settings/#databases
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
}
}
# Password validation
# https://docs.djangoproject.com/en/1.11/ref/settings/#auth-password-validators
AUTH_PASSWORD_VALIDATORS = [
{
'NAME': 'django.contrib.auth.password_validation.UserAttributeSimilarityValidator',
},
{
'NAME': 'django.contrib.auth.password_validation.MinimumLengthValidator',
},
{
'NAME': 'django.contrib.auth.password_validation.CommonPasswordValidator',
},
{
'NAME': 'django.contrib.auth.password_validation.NumericPasswordValidator',
},
]
# Internationalization
# https://docs.djangoproject.com/en/1.11/topics/i18n/
LANGUAGE_CODE = 'en-us'
TIME_ZONE = 'UTC'
USE_I18N = True
USE_L10N = True
USE_TZ = True
# Static files (CSS, JavaScript, Images)
# https://docs.djangoproject.com/en/1.11/howto/static-files/
# Add our translations
LOCALE_PATHS = (
os.path.join(IRFI_BASE_DIR, 'irfi', 'locale'),
)
STATIC_URL = '/static/'
# Using anything else than English here will break Ideascube migrations
LANGUAGE_CODE = 'en'
"""irfi URL Configuration
from django.conf.urls import i18n
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/1.11/topics/http/urls/
Examples:
Function views
1. Add an import: from my_app import views
2. Add a URL to urlpatterns: url(r'^$', views.home, name='home')
Class-based views
1. Add an import: from other_app.views import Home
2. Add a URL to urlpatterns: url(r'^$', Home.as_view(), name='home')
Including another URLconf
1. Import the include() function: from django.conf.urls import url, include
2. Add a URL to urlpatterns: url(r'^blog/', include('blog.urls'))
"""
from django.conf.urls import url
from django.contrib import admin
from ideascube.urls import urlpatterns
urlpatterns = [
url(r'^admin/', admin.site.urls),
]
urlpatterns += i18n.i18n_patterns(
# URL patterns for RFI will be added here
)
......@@ -5,6 +5,7 @@ import sys
if __name__ == "__main__":
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "irfi.settings")
os.environ.setdefault("IDEASCUBE_ID", "dev")
from django.core.management import execute_from_command_line
......
-r https://framagit.org/ideascube/ideascube/raw/master/requirements.txt
git+https://framagit.org/ideascube/ideascube.git@master#egg=ideascube
# TODO: Eventually this needs to point to a release tag
git+https://framagit.org/ideascube/ideascube.git@rfi-settings#egg=ideascube
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment