Ensure default document_storage directory is really relative to the installation directory (SaintGermain)

This commit is contained in:
Roberto Rosario
2012-02-11 18:08:20 -04:00
parent 7adb3a9ccd
commit 2334a63fe4

View File

@@ -1,5 +1,8 @@
"""Configuration options for the storage app"""
import os
from django.utils.translation import ugettext_lazy as _
from django.conf import settings
from smart_settings.api import register_settings
@@ -10,6 +13,6 @@ register_settings(
{'name': u'GRIDFS_HOST', 'global_name': u'STORAGE_GRIDFS_HOST', 'default': u'localhost'},
{'name': u'GRIDFS_PORT', 'global_name': u'STORAGE_GRIDFS_PORT', 'default': 27017},
{'name': u'GRIDFS_DATABASE_NAME', 'global_name': u'STORAGE_GRIDFS_DATABASE_NAME', 'default': u'document_storage'},
{'name': u'FILESTORAGE_LOCATION', 'global_name': u'STORAGE_FILESTORAGE_LOCATION', 'default': u'document_storage', 'exists': True},
{'name': u'FILESTORAGE_LOCATION', 'global_name': u'STORAGE_FILESTORAGE_LOCATION', 'default': os.path.join(settings.PROJECT_ROOT, u'document_storage'), 'exists': True},
]
)