Django admin unable to edit site - CMS links always redirect login page

37 views
Skip to first unread message

Angela Checa

unread,
Feb 20, 2019, 2:16:30 AM2/20/19
to Django users

Dear every one:

I've been searching for a solution for this problem but I can find an answer, please help me. The CMS does not allow to edit sites or do anything and always redirect to login page. I have a main site with an app, the domain is something like www.sitioprincipal.com and inside this portal I have three links for access other apps like this:

www.sitioprincipal.co/app2

www.sitioprincipal.co/app3

www.sitioprincipal.co/app4

All the apps were configured in Apache and for sometime the accesss to CMS (admin of the site) worked fine, but recently (i dont know why) when I loggin into any of the cms of app2, app3 and app4 after correct login it displays the first admin interface of site http://www.sitioprincipal.com/es/admin/ with the list of administration options and links:

Authentication and Authorization Groups    
Users    
Cmsplugin_Filer_Image Thumbnail options    
django CMS Pages    
Static placeholders    
Filer Folders          
Thumbnail options    
Sites Sites

but all the links and buttons seems to be bad because always redirects to login page again and it is imposible to edit the site pages or do anything else.  This happend in CMS of all sites but not in the main site www.sitioprincipal.com, in that CMS everything works well.  Please help me to find out how to fix this problem.

This is the version I have:

django-cms                         3.2.5

Django                             1.9.5  

This is a part of the settings.py file of the main site www.sitioprincipal.com

# Application definition

INSTALLED_APPS = [
    'cms',
    'treebeard',
    'menus',
    'sekizai',
    'easy_thumbnails',
    'filer',
    'mptt',
    'cmsplugin_filer_image',
    'cmsplugin_filer_link',
    'djangocms_admin_style',
    'reversion',
    'djangocms_text_ckeditor',
    'djangocms_flash',
    'coleccionesonline.apps.ColeccionesonlineConfig',
    'django.contrib.admin',
    'django.contrib.auth',
    'django.contrib.contenttypes',
    'django.contrib.sessions',
    'django.contrib.messages',
    'django.contrib.staticfiles',
    'django.contrib.sites',
]

# Módulos de migración para los plugins de django-filer
MIGRATION_MODULES = {
    'cmsplugin_filer_image': 'cmsplugin_filer_image.migrations_django',
    'cmsplugin_filer_link': 'cmsplugin_filer_link.migrations_django'
}

MIDDLEWARE_CLASSES = [
    'cms.middleware.utils.ApphookReloadMiddleware',
    'django.middleware.security.SecurityMiddleware',
    'django.contrib.sessions.middleware.SessionMiddleware',
    'django.middleware.common.CommonMiddleware',
    'django.middleware.locale.LocaleMiddleware',
    'django.middleware.csrf.CsrfViewMiddleware',
    'django.contrib.auth.middleware.AuthenticationMiddleware',
    'django.contrib.auth.middleware.SessionAuthenticationMiddleware',
    'django.contrib.messages.middleware.MessageMiddleware',
    'django.middleware.clickjacking.XFrameOptionsMiddleware',
    'cms.middleware.user.CurrentUserMiddleware',
    'cms.middleware.page.CurrentPageMiddleware',
    'cms.middleware.toolbar.ToolbarMiddleware',
    'cms.middleware.language.LanguageCookieMiddleware',
]

# Módulo de urls
ROOT_URLCONF = 'sitioprincipal.urls'

# Sessión manejada por cookies
SESSION_ENGINE = 'django.contrib.sessions.backends.signed_cookies'

TEMPLATES = [
    {
        'BACKEND': 'django.template.backends.django.DjangoTemplates',
        'DIRS': [os.path.join(BASE_DIR,'sitioprincipal','templates'),],
        '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',
                'sekizai.context_processors.sekizai',
                'cms.context_processors.cms_settings',
            ],
        },
    },
]

WSGI_APPLICATION = 'sitioprincipal.wsgi.application'

# CMS settings
SITE_ID = 1

...

Thanks for any kind of help.


Angela.

Jason

unread,
Feb 20, 2019, 5:37:35 AM2/20/19
to Django users
This might be a better question for the django-cms project GitHub than here? I haven’t seen any cms questions here.

gilwell muhati

unread,
Feb 21, 2019, 6:46:41 AM2/21/19
to django...@googlegroups.com
Hello Angela,

Your Apache is acting up, please fix it then we can solve the other issue.
Regards,

Gilwell Muhati | +254 710 739 116 |

~~“The mind is its own place and in itself can make a heaven of hell, a hell of heaven…”~~John Milton


--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/0fc51920-d318-4d96-a1d0-37a4d2affcd7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages