mirror of
https://github.com/YunoHost-Apps/django_example_ynh.git
synced 2024-09-03 18:26:21 +02:00
rename settings and urls
This commit is contained in:
parent
d40e863abe
commit
05be4ad6b4
7 changed files with 6 additions and 12 deletions
|
@ -5,7 +5,7 @@ import sys
|
|||
|
||||
|
||||
def main():
|
||||
os.environ['DJANGO_SETTINGS_MODULE'] = 'django_ynh_demo_settings'
|
||||
os.environ['DJANGO_SETTINGS_MODULE'] = 'settings'
|
||||
from django.core.management import execute_from_command_line
|
||||
|
||||
execute_from_command_line(sys.argv)
|
||||
|
|
|
@ -37,9 +37,6 @@ PATH_URL = PATH_URL.strip('/')
|
|||
|
||||
# -----------------------------------------------------------------------------
|
||||
|
||||
|
||||
ROOT_URLCONF = 'django_ynh_demo_urls'
|
||||
|
||||
YNH_SETUP_USER = 'setup_user.setup_demo_user'
|
||||
|
||||
SECRET_KEY = __get_or_create_secret(FINAL_HOME_PATH / 'secret.txt') # /opt/yunohost/$app/secret.txt
|
|
@ -2,9 +2,7 @@
|
|||
WSGI config
|
||||
"""
|
||||
import os
|
||||
|
||||
|
||||
os.environ['DJANGO_SETTINGS_MODULE'] = 'django_ynh_demo_settings'
|
||||
os.environ['DJANGO_SETTINGS_MODULE'] = 'settings'
|
||||
|
||||
from django.core.wsgi import get_wsgi_application
|
||||
|
||||
|
|
|
@ -7,11 +7,12 @@
|
|||
# -----------------------------------------------------------------------------
|
||||
# settings that should be set in project settings:
|
||||
|
||||
ROOT_URLCONF = None
|
||||
SECRET_KEY = None
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
|
||||
ROOT_URLCONF = 'urls' # .../conf/urls.py
|
||||
|
||||
INSTALLED_APPS = [
|
||||
'django.contrib.admin',
|
||||
'django.contrib.auth',
|
||||
|
|
|
@ -155,8 +155,7 @@ ynh_app_setting_set --app="$app" --key=redis_db --value="$redis_db"
|
|||
|
||||
touch "$final_path/local_settings.py"
|
||||
|
||||
cp "../conf/ynh_authenticate.py" "$final_path/ynh_authenticate.py"
|
||||
cp "../conf/ynh_urls.py" "$final_path/ynh_urls.py"
|
||||
cp "../conf/urls.py" "$final_path/urls.py"
|
||||
|
||||
#=================================================
|
||||
# MIGRATE / COLLECTSTATIC / CREATEADMIN
|
||||
|
|
|
@ -143,8 +143,7 @@ ynh_store_file_checksum --file="$settings"
|
|||
|
||||
touch "$final_path/local_settings.py"
|
||||
|
||||
cp "../conf/ynh_authenticate.py" "$final_path/ynh_authenticate.py"
|
||||
cp "../conf/ynh_urls.py" "$final_path/ynh_urls.py"
|
||||
cp "../conf/urls.py" "$final_path/urls.py"
|
||||
|
||||
#=================================================
|
||||
# MIGRATE django_ynh
|
||||
|
|
Loading…
Add table
Reference in a new issue