tardis.default_settings package¶
Submodules¶
tardis.default_settings.admins module¶
tardis.default_settings.analytics module¶
tardis.default_settings.apps module¶
-
tardis.default_settings.apps.
USER_MENU_MODIFIERS
= ['tardis.apps.sftp.user_menu_modifiers.add_ssh_keys_menu_item', 'tardis.apps.openid_migration.user_menu_modifiers.add_migrate_account_menu_item']¶ A list of methods which can modify the user menu defined in tardis.tardis_portal.context_processors.user_menu_processor The modifications will be applied in order, so it is possible for one app to overwrite changes made by another app whose modifier method is earlier in the list.
Each modifier method should take a django.http.HttpRequest object and a list of user menu items, and return a modified list of user menu items.
An example from the SFTP app is below:
USER_MENU_MODIFIERS.extend([ 'tardis.apps.sftp.user_menu_modifiers.add_ssh_keys_menu_item' ])
tardis.default_settings.auth module¶
-
tardis.default_settings.auth.
AUTOGENERATE_API_KEY
= False¶ Generate a tastypie API key with user post_save (tardis/tardis_portal/models/hooks.py)
-
tardis.default_settings.auth.
REGISTRATION_OPEN
= True¶ Enable/disable the self-registration link and form in the UI. Note - this does not actually disable the URL endpoints for registration. You must also remove the registration app from INSTALLED_APPS to disable registration.
tardis.default_settings.caches module¶
-
tardis.default_settings.caches.
CACHES
= {'celery-locks': {'LOCATION': 'celery_lock_cache', 'BACKEND': 'django.core.cache.backends.db.DatabaseCache'}, 'default': {'LOCATION': 'default_cache', 'BACKEND': 'django.core.cache.backends.db.DatabaseCache'}}¶ change the CACHES setting to memcached if you prefer. Requires additional dependencies.
tardis.default_settings.celery_settings module¶
tardis.default_settings.custom_views module¶
-
tardis.default_settings.custom_views.
DATASET_VIEWS
= []¶ Dataset view overrides (‘contextual views’) are specified as tuples mapping a Schema namespace to a class-based view (or view function). See: https://mytardis.readthedocs.io/en/develop/apps/contextual_views.html#dataset-and-experiment-views
e.g.:
DATASET_VIEWS = [ ('http://example.org/schemas/dataset/my_awesome_schema', 'tardis.apps.my_awesome_app.views.CustomDatasetViewSubclass'), ]
-
tardis.default_settings.custom_views.
EXPERIMENT_VIEWS
= []¶ Experiment view overrides (‘contextual views’) are specified as tuples mapping a Schema namespace to a class-based view (or view function). See: https://mytardis.readthedocs.io/en/develop/apps/contextual_views.html#dataset-and-experiment-views
e.g.:
EXPERIMENT_VIEWS = [ ('http://example.org/schemas/expt/my_awesome_schema', 'tardis.apps.my_awesome_app.views.CustomExptViewSubclass'), ]
-
tardis.default_settings.custom_views.
INDEX_VIEWS
= {}¶ A custom index page override is defined in as dictionary mapping a class-based view (or view function) to a Django
Site
, specified by SITE_ID (an integer) or the domain name of the incoming request. See: https://mytardis.readthedocs.io/en/develop/apps/contextual_views.html#custom-index-viewe.g.:
INDEX_VIEWS = { 1: 'tardis.apps.my_custom_app.views.MyCustomIndexSubclass', 'store.example.com': 'tardis.apps.myapp.AnotherCustomIndexSubclass' }
-
tardis.default_settings.custom_views.
LOGIN_VIEWS
= {}¶ A custom login page override is defined in as dictionary mapping a class-based view (or view function) to a Django
Site
, specified by SITE_ID (an integer) or the domain name of the incoming request. See: https://mytardis.readthedocs.io/en/develop/apps/contextual_views.html#custom-login-viewe.g.:
LOGIN_VIEWS = { 1: 'tardis.apps.my_custom_app.views.MyCustomLoginSubclass', 'store.example.com': 'tardis.apps.myapp.AnotherCustomLoginSubclass' }
tardis.default_settings.database module¶
tardis.default_settings.debug module¶
-
tardis.default_settings.debug.
ALLOWED_HOSTS
= ['*']¶ For security reasons this needs to be set to your hostname and/or IP address in production.
-
tardis.default_settings.debug.
DEBUG
= True¶ Set to false for production use
-
tardis.default_settings.debug.
INTERNAL_IPS
= ('127.0.0.1',)¶ - A list of IP addresses, as strings, that:
- Allow the debug() context processor to add some variables to the template context.
tardis.default_settings.downloads module¶
-
tardis.default_settings.downloads.
DEFAULT_ARCHIVE_FORMATS
= ['tar']¶ Site’s preferred archive types, with the most preferred first other available option: ‘tgz’. Add to list if desired
tardis.default_settings.email module¶
-
tardis.default_settings.email.
DEFAULT_FROM_EMAIL
= 'webmaster@localhost'¶ This can be set as : “MyTardis Admins <admins@mytardis.org>”
-
tardis.default_settings.email.
EMAIL_HOST
= 'localhost'¶ Set this to your local SMTP server, e.g. ‘smtp.example.edu’ or to a remote SMTP server, e.g. ‘smtp.gmail.com’
-
tardis.default_settings.email.
EMAIL_HOST_PASSWORD
= ''¶ When using a local SMTP server, you probably don’t need to authenticate, so you can leave this blank.
If using a remote SMTP server, this can be set to the password used to authenticate.
-
tardis.default_settings.email.
EMAIL_HOST_USER
= ''¶ When using a local SMTP server, you probably don’t need to authenticate, so you can leave this blank.
If using a remote SMTP server, this can be set to the email address used to authenticate, e.g. ‘bob@bobmail.com’
-
tardis.default_settings.email.
EMAIL_PORT
= 25¶ Some SMTP servers require a different port, e.g. 587. Django’s default value for this setting is 25.
-
tardis.default_settings.email.
EMAIL_USE_TLS
= False¶ Some SMTP servers require this to be set to True. Django’s default value for this setting is False.
tardis.default_settings.filters module¶
tardis.default_settings.frontend module¶
-
tardis.default_settings.frontend.
BLEACH_ALLOWED_ATTRIBUTES
= {'a': ['href', 'title'], 'abbr': ['title'], 'acronym': ['title']}¶ These are the default bleach values and shown here as an example.
-
tardis.default_settings.frontend.
BLEACH_ALLOWED_TAGS
= ['a', 'abbr', 'acronym', 'b', 'blockquote', 'code', 'em', 'i', 'li', 'ol', 'strong', 'ul']¶ These are the default bleach values and shown here as an example.
tardis.default_settings.i18n module¶
tardis.default_settings.localisation module¶
tardis.default_settings.logging module¶
tardis.default_settings.middlewares module¶
tardis.default_settings.publication module¶
tardis.default_settings.search module¶
tardis.default_settings.sharing module¶
tardis.default_settings.site_customisations module¶
-
tardis.default_settings.site_customisations.
SITE_TITLE
= 'MyTardis'¶ customise the title of your site
-
tardis.default_settings.site_customisations.
SPONSORED_TEXT
= None¶ add text to the footer to acknowledge someone
tardis.default_settings.static_files module¶
tardis.default_settings.storage module¶
-
tardis.default_settings.storage.
METADATA_STORE_PATH
= '/home/docs/checkouts/readthedocs.org/user_builds/mytardis/checkouts/v4.1.0-rc2/var/store'¶ storage path for image paths stored in parameters. Better to set to another location if possible
tardis.default_settings.templates module¶
tardis.default_settings.uploads module¶
-
tardis.default_settings.uploads.
UPLOAD_METHOD
= False¶ Old version: UPLOAD_METHOD = “uploadify”. This can be changed to an app that provides an upload_button function, eg. “tardis.apps.filepicker.views.upload_button” to use a fancy commercial uploader. To use filepicker, please also get an API key at http://filepicker.io