Not logged in - Login
< back

Configuration

This page contains reference information about the web.config settings for Roadkill, and expects you to have some knowledge of .NET XML configuration files/web.config files.

Roadkill section

Roadkill stores almost all of its configuration settings in the web.config file. This is written to during the installation, based on the settings you provide.

The web.config file contains a custom roadkill section which contains the bulk of the settings, below is an example:

<roadkill 
    adminRoleName="Admin"
    attachmentsRoutePath="Attachments"
    attachmentsFolder="~/Attachments"
    connectionStringName="Roadkill"
    dataStoreType="SqlServer2005"
    editorRoleName="Editor"
    installed="true"
    isPublicSite="true"
    userManagerType=""
    ldapConnectionString=""
    ldapUsername=""
    ldapPassword=""
    logging="none"
    logErrorsOnly="false"
    ignoreSearchIndexErrors="true"
    resizeImages="true"
    userManagerType=""
    useHtmlWhiteList="true"
    useWindowsAuthentication="false" 
    useBrowserCache="true"
    useObjectCache="true"
    version="1.6.0.0"
/>

adminRoleName the role name for editors. This can also contain one, or a comma separated list of Active Directory groups that are editors if Windows authentication is enabled.

attachmentsRoutePath

This is the virtual path used to serve attachments, which by default is "Attachments". Do not include any trailing or beginning slash, for example for the url /myfiles/uploads/" use "myfiles/uploads".

attachmentsFolder This is the directory that images and files are uploaded to. This can be an absolute file path (including a UNC path), or if the value starts with "~/" then the website root is used.

connectionStringName the name of the connection string from the connectionStrings section, defaults to "Roadkill".

dataStoreType

The kind of database to use. This defaults to SQLServer2008, valid values are:

  • MySQL
  • Postgres
  • MongoDB
  • Sqlite
  • SqlServer2005
  • SqlServer2008
  • SqlServer2012
  • SqlServerCe

These are not case sensitive. If you are using a custom repository (one you've written yourself), this should equal the full type name of the repository. This feature will be supported in future versions.

editorRoleName the role name for editors. This can also contain one, or a comma separated list of Active Directory groups that are editors if Windows authentication is enabled.

installed true/false. If false, the installer wizard will display when you visit the site.

ldapConnectionString If windows authentication is enabled, this should be the connection string to the Active Directory LDAP server, including LDAP:// at the start of the string.

ldapUsername If windows authentication is enabled, this is the username used to connect to the Active Directory server, which is typically a service account.

ldapPassword If windows authentication is enabled, this is the password for the username used to connect to the Active Directory server.

ignoreSearchIndexErrors (optional) true/false. Whether search index errors are ignored when pages are created or edited. Defaults to true.

isPublicSite (optional) true/false. If set to false, then all pages require a log in to view.

resizeImages
(optional) true/false. This setting will cause images that are too big to be automatically resized, using a jQuery plugin. Defaults to true.

userManagerType (optional) if set, this class (which should inherit from Roadkill.Core.UserManager) will be used for authenticating users. The format of this setting should be "Namespace.Type, Assemblyname" or a similar valid type string. See the Users and Permissions page for details on creating your own implementation.

useHtmlWhiteList (optional) if set, this will strip all HTML tags/attributes from the markup of each page (not the Theme HTML, just the markup converted from the Wiki markdown). Tags which exist inside App_Data/htmlwhitelist.xml file will be ignored. True by default.

useWindowsAuthentication Whether Windows Active Directory authentication should be used.

useBrowserCache Enables caching on the browser. This will tell the browser to cache Roadkill pages, and check for updates (If-Modified-Since) each time the page is loaded. If no update is found, no content is returned from the server. Recommended to increase the responsiveness of the site.

useObjectCache

Enables Object caching. Roadkill caches all pages and content in memory after retrieving it from the database. The cache is automatically updated when a page changes. Recommended to increase the responsiveness of the site. Object caching is not currently supported for web gardens or web farms.

version

The current version installed. If this version is less than the current build version, then an upgrade is assumed and the upgrade screen appears. This value takes the format major.minor.0.0 (build numbers are not included in Roadkill), for example "1.6.0.0".


The connection string section will look this for a default roadkill installation:

<connectionStrings>
    <add name="Roadkill" connectionString="(your connection string)" />
</connectionStrings>

There is usually no reason to change the name of the connectionString in this section as it ties in with the connectionName setting inside the roadkill section.

Settings that are stored in the database

The following settings are not stored in the roadkill web.config section but in the database, and are not critical for the running of the application but preferences.

  • AllowedFileTypes
  • AllowUserSignup
  • EnableRecaptcha
  • MarkupType
  • RecaptchaPrivateKey
  • RecaptchaPublicKey
  • SiteUrl
  • Title
  • Theme

Changing the language of the site

If you want to force the language of your site to something other than the one installed on the server, you can do this using the