SiteConfig: Difference between revisions

From Request Tracker Wiki
Jump to navigation Jump to search
 
Line 20: Line 20:
= Plugins =
= Plugins =


Enable extensions, also called plugins, with a `Plugin` line.
Enable extensions, also called plugins, with a <code>Plugin</code> line.


     Plugin('RT::Extension::ResetPassword');
     Plugin('RT::Extension::ResetPassword');
Line 31: Line 31:
     Set(@Plugins, qw(Extension::QuickDelete));
     Set(@Plugins, qw(Extension::QuickDelete));


When upgrading, convert to the `Plugin` form shown above.
When upgrading, convert to the <code>Plugin</code> form shown above.


==Custom Statuses==
==Custom Statuses==

Latest revision as of 08:26, 25 June 2025

What It Is

The SiteConfig file lives in ${RTHOME}/etc/RT_SiteConfig.pm. Its purpose is to provide you a place to override config settings in ${RTHOME}/etc/RT_Config.pm as well as add new config variables as provided by various user Contributions or for your own purposes.

All of the available configuration options are documented in RT_Config.pm and also available on the web.

You set a config variable like so:

Set($Foo, "Value of Foo");
Set($Bar, 1);
Set(@Baz, "array", "of", "values");
Set(%Zot, "hash" => "of", "keyed" => "values");

You access them like this in RT 3.8 and newer:

RT->Config->Get('Foo') # "Value of option Foo"
RT->Config->Get('Bar')  # 1
RT->Config->Get('Baz')->[0] # get option Baz that is array reference and access first element

Plugins

Enable extensions, also called plugins, with a Plugin line.

   Plugin('RT::Extension::ResetPassword');
   Plugin('RT::Extension::Helpdesk');

Use one line for each plugin.

RT before version 4 used syntax like this:

   Set(@Plugins, qw(Extension::QuickDelete));

When upgrading, convert to the Plugin form shown above.

Custom Statuses

RT 4 and after use the Lifecycles system to define custom statuses, workflows, actions, and more.

RT 3.8 and prior used configuration values to define CustomStatuses.