Skip to content
Tobias von Klipstein edited this page Jun 6, 2012 · 7 revisions

Configuration of dojango

Dojango was designed to get started very fast, but you also have the power to configure everything on your own (just if you really want to :-)). All the definitions below can be set in your project's settings.py file:

DOJANGO_DOJO_PROFILE (default "google")

Sets the dojango profile, that should be used within the dojango context. Possible values:

  • "aol" (default)
  • "aol_uncompressed"
  • "aol_gfx"
  • "aol_gfx_uncompressed"
  • "google" (also accessible via SSL, see DOJANGO_CDN_USE_SSL)
  • "google_uncompressed" (also accessible via SSL, see DOJANGO_CDN_USE_SSL)
  • "local"
  • "local_release"
  • "local_release_uncompressed"

DOJANGO_DOJO_VERSION (default "1.5.0")

This setting defines the dojo version that should be used within dojango. For the local version you can pass in any value, because dojango tries to get a local version from the following directory:

_django project directory_/dojango/media/dojo/_DOJANGO_DOJO_VERSION_

If you want to use a version of the profiles local or local_release you first have to download a dojo version and place it in the above mentioned directory. For details how to do this see DojoBuild.

All other external (crossdomain) builds provide the following versions:

  • "1.5.0" - available in profile: aol, aol_compressed and google profiles
  • "1.5" - available in profile: aol, aol_compressed and google profiles
  • "1.4.3" - available in profile: aol, aol_compressed and google profiles
  • "1.4.1" - available in profile: aol, aol_compressed and google profiles
  • "1.4.0" - available in profile: aol, aol_compressed and google profiles
  • "1.4" - available in profile: aol, aol_compressed and google profiles
  • "1.3.2" - available in profile: aol, aol_compressed and google profiles
  • "1.3.1" - available in profile: aol, aol_compressed and google profiles
  • "1.3.0" - available in profile: aol, aol_compressed and google profiles
  • "1.2.0" - available in profile: aol, aol_compressed and google profiles
  • "1.1.1" - available in profile: all aol and google profiles
  • "1.1.0" - available in profile: all aol profiles
  • "1.0.2" - available in profile: all aol profiles
  • "1.0.0" - available in profile: all aol profiles
  • "0.9.0" - available in profile: all aol profiles

DOJANGO_DOJO_PROFILES

With this setting you can extend the default list of profiles delivered with dojango (see above). Look at conf/settings.py on how to define your own profile.

DOJANGO_DOJO_THEME (default: "claro")

Here you can define the dojo theme, that should be used. Possible values:

  • "claro"
  • "tundra"
  • "soria"
  • "nihilo"

DOJANGO_DOJO_THEME_URL (defaults to the dijit theme URL)

You can set your own theme base URL. It defaults to dojo base url/dijit/themes and there you can look at the dojo theme structure, e.g.:

_dojo base url_/dijit/themes/tundra

_dojo base url_/dijit/themes/tundra/tundra.css

DOJANGO_DOJO_DEBUG (default: settings.DEBUG)

Turning dojo into debug mode. The standard is using the DEBUG setting of your django project. Possible values:

  • True
  • False

DOJANGO_DOJO_SECURE_JSON (default: True)

Defines if the json response (used in dojango decorators / utility functions) should be prepended with:

{}&&\n

This is the recommendation of Dojo since version 1.2.0. Possible values:

  • True
  • False

Several advanced settings for some URLs and paths

Be careful if you modify the following settings. You really should know what you are doing, if you are changing these.

DOJANGO_CDN_USE_SSL (default: False)

It will use SSL for delivering the Dojo files, when this setting is True and Dojo is loaded via CDN. (Note: just the Google CDN supports https!)

DOJANGO_DOJO_MEDIA_URL (default: "dojo-media")

Defining a part of the relative URL where all dojo files are served from.

DOJANGO_BASE_MEDIA_URL (default: /dojango/ + DOJANGO_DOJO_MEDIA_URL)

This sets the absolute URL to the media files of dojango. This directory acts as the base URL, where all dojo media files are served from.

DOJANGO_BUILD_MEDIA_URL (default: DOJANGO_BASE_MEDIA_URL + "/release")

What is the base url when the dojango profile "local_release" is used? A builded release will be available there in a directory with the name of the builded version. See ''Settings for building your own dojo profile'' for details about building dojo releases.

DOJANGO_BASE_MEDIA_ROOT (default: _django project directory_/dojango/media)

With this setting you can define the absolute path to the media files of dojango. You have to change that, if you want to modify the dojo build system.

DOJANGO_BASE_DOJO_ROOT (default: DOJANGO_BASE_MEDIA_ROOT + "/dojo")

Like DOJANGO_BASE_MEDIA_ROOT, but defining the absolute base path to the media files of dojo.