merging RT 4.0.6
[freeside.git] / rt / etc / RT_Config.pm.in
1 #
2 # RT was configured with:
3 #
4 #   $ @CONFIGURE_INCANT@
5 #
6
7 package RT;
8
9 #############################  WARNING  #############################
10 #                                                                   #
11 #                     NEVER EDIT RT_Config.pm !                     #
12 #                                                                   #
13 #         Instead, copy any sections you want to change to          #
14 #         RT_SiteConfig.pm and edit them there.  Otherwise,         #
15 #         your changes will be lost when you upgrade RT.            #
16 #                                                                   #
17 #############################  WARNING  #############################
18
19 =head1 NAME
20
21 RT::Config
22
23 =head1 Base configuration
24
25 =over 4
26
27 =item C<$rtname>
28
29 C<$rtname> is the string that RT will look for in mail messages to
30 figure out what ticket a new piece of mail belongs to.
31
32 Your domain name is recommended, so as not to pollute the namespace.
33 Once you start using a given tag, you should probably never change it;
34 otherwise, mail for existing tickets won't get put in the right place.
35
36 =cut
37
38 Set($rtname, "example.com");
39
40 =item C<$Organization>
41
42 You should set this to your organization's DNS domain. For example,
43 I<fsck.com> or I<asylum.arkham.ma.us>. It is used by the linking
44 interface to guarantee that ticket URIs are unique and easy to
45 construct.  Changing it after you have created tickets in the system
46 will B<break> all existing ticket links!
47
48 =cut
49
50 Set($Organization, "example.com");
51
52 =item C<$CorrespondAddress>, C<$CommentAddress>
53
54 RT is designed such that any mail which already has a ticket-id
55 associated with it will get to the right place automatically.
56
57 C<$CorrespondAddress> and C<$CommentAddress> are the default addresses
58 that will be listed in From: and Reply-To: headers of correspondence
59 and comment mail tracked by RT, unless overridden by a queue-specific
60 address.  They should be set to email addresses which have been
61 configured as aliases for F<rt-mailgate>.
62
63 =cut
64
65 Set($CorrespondAddress, '');
66
67 Set($CommentAddress, '');
68
69 =item C<$WebDomain>
70
71 Domain name of the RT server, e.g. 'www.example.com'. It should not
72 contain anything except the server name.
73
74 =cut
75
76 Set($WebDomain, "localhost");
77
78 =item C<$WebPort>
79
80 If we're running as a superuser, run on port 80.  Otherwise, pick a
81 high port for this user.
82
83 443 is default port for https protocol.
84
85 =cut
86
87 Set($WebPort, 80);
88
89 =item C<$WebPath>
90
91 If you're putting the web UI somewhere other than at the root of your
92 server, you should set C<$WebPath> to the path you'll be serving RT
93 at.
94
95 C<$WebPath> requires a leading / but no trailing /, or it can be
96 blank.
97
98 In most cases, you should leave C<$WebPath> set to "" (an empty
99 value).
100
101 =cut
102
103 Set($WebPath, "");
104
105 =item C<$Timezone>
106
107 C<$Timezone> is the default timezone, used to convert times entered by
108 users into GMT, as they are stored in the database, and back again;
109 users can override this.  It should be set to a timezone recognized by
110 your server.
111
112 =cut
113
114 Set($Timezone, "US/Eastern");
115
116 =item C<@Plugins>
117
118 Set C<@Plugins> to a list of external RT plugins that should be
119 enabled (those plugins have to be previously downloaded and
120 installed).
121
122 Example:
123
124 C<Set(@Plugins, (qw(Extension::QuickDelete RT::Extension::CommandByMail)));>
125
126 =cut
127
128 Set(@Plugins, (qw(RTx::Calendar
129                   RT::Extension::MobileUI))); #RTx::Checklist ));
130
131 =back
132
133
134
135
136 =head1 Database connection
137
138 =over 4
139
140 =item C<$DatabaseType>
141
142 Database driver being used; case matters.  Valid types are "mysql",
143 "Oracle" and "Pg".
144
145 =cut
146
147 Set($DatabaseType, "@DB_TYPE@");
148
149 =item C<$DatabaseHost>, C<$DatabaseRTHost>
150
151 The domain name of your database server.  If you're running MySQL and
152 on localhost, leave it blank for enhanced performance.
153
154 C<DatabaseRTHost> is the fully-qualified hostname of your RT server,
155 for use in granting ACL rights on MySQL.
156
157 =cut
158
159 Set($DatabaseHost,   "@DB_HOST@");
160 Set($DatabaseRTHost, "@DB_RT_HOST@");
161
162 =item C<$DatabasePort>
163
164 The port that your database server is running on.  Ignored unless it's
165 a positive integer. It's usually safe to leave this blank; RT will
166 choose the correct default.
167
168 =cut
169
170 Set($DatabasePort, "@DB_PORT@");
171
172 =item C<$DatabaseUser>
173
174 The name of the user to connect to the database as.
175
176 =cut
177
178 Set($DatabaseUser, "@DB_RT_USER@");
179
180 =item C<$DatabasePassword>
181
182 The password the C<$DatabaseUser> should use to access the database.
183
184 =cut
185
186 Set($DatabasePassword, q{@DB_RT_PASS@});
187
188 =item C<$DatabaseName>
189
190 The name of the RT database on your database server. For Oracle, the
191 SID and database objects are created in C<$DatabaseUser>'s schema.
192
193 =cut
194
195 Set($DatabaseName, q{@DB_DATABASE@});
196
197 =item C<$DatabaseRequireSSL>
198
199 If you're using PostgreSQL and have compiled in SSL support, set
200 C<$DatabaseRequireSSL> to 1 to turn on SSL communication with the
201 database.
202
203 =cut
204
205 Set($DatabaseRequireSSL, undef);
206
207 =back
208
209
210
211
212 =head1 Logging
213
214 The default is to log anything except debugging information to syslog.
215 Check the L<Log::Dispatch> POD for information about how to get things
216 by syslog, mail or anything else, get debugging info in the log, etc.
217
218 It might generally make sense to send error and higher by email to
219 some administrator.  If you do this, be careful that this email isn't
220 sent to this RT instance.  Mail loops will generate a critical log
221 message.
222
223 =over 4
224
225 =item C<$LogToSyslog>, C<$LogToScreen>
226
227 The minimum level error that will be logged to the specific device.
228 From lowest to highest priority, the levels are:
229
230     debug info notice warning error critical alert emergency
231
232 Many syslogds are configured to discard or file debug messages away, so
233 if you're attempting to debug RT you may need to reconfigure your
234 syslogd or use one of the other logging options.
235
236 Logging to your screen affects scripts run from the command line as well
237 as the STDERR sent to your webserver (so these logs will usually show up
238 in your web server's error logs).
239
240 =cut
241
242 Set($LogToSyslog, "info");
243 Set($LogToScreen, "info");
244
245 =item C<$LogToFile>, C<$LogDir>, C<$LogToFileNamed>
246
247 Logging to a standalone file is also possible. The file needs to both
248 exist and be writable by all direct users of the RT API. This generally
249 includes the web server and whoever rt-crontool runs as. Note that
250 rt-mailgate and the RT CLI go through the webserver, so their users do
251 not need to have write permissions to this file. If you expect to have
252 multiple users of the direct API, Best Practical recommends using syslog
253 instead of direct file logging.
254
255 You should set C<$LogToFile> to one of the levels documented above.
256
257 =cut
258
259 Set($LogToFile, undef);
260 Set($LogDir, q{@RT_LOG_PATH@});
261 Set($LogToFileNamed, "rt.log");    #log to rt.log
262
263 =item C<$LogStackTraces>
264
265 If set to a log level then logging will include stack traces for
266 messages with level equal to or greater than specified.
267
268 NOTICE: Stack traces include parameters supplied to functions or
269 methods. It is possible for stack trace logging to reveal sensitive
270 information such as passwords or ticket content in your logs.
271
272 =cut
273
274 Set($LogStackTraces, "");
275
276 =item C<@LogToSyslogConf>
277
278 On Solaris or UnixWare, set to ( socket => 'inet' ).  Options here
279 override any other options RT passes to L<Log::Dispatch::Syslog>.
280 Other interesting flags include facility and logopt.  (See the
281 L<Log::Dispatch::Syslog> documentation for more information.)  (Maybe
282 ident too, if you have multiple RT installations.)
283
284 =cut
285
286 Set(@LogToSyslogConf, ());
287
288 =back
289
290
291
292 =head1 Incoming mail gateway
293
294 =over 4
295
296 =item C<$EmailSubjectTagRegex>
297
298 This regexp controls what subject tags RT recognizes as its own.  If
299 you're not dealing with historical C<$rtname> values, you'll likely
300 never have to change this configuration.
301
302 Be B<very careful> with it. Note that it overrides C<$rtname> for
303 subject token matching and that you should use only "non-capturing"
304 parenthesis grouping. For example:
305
306 C<Set($EmailSubjectTagRegex, qr/(?:example.com|example.org)/i );>
307
308 and NOT
309
310 C<Set($EmailSubjectTagRegex, qr/(example.com|example.org)/i );>
311
312 The setting below would make RT behave exactly as it does without the
313 setting enabled.
314
315 =cut
316
317 # Set($EmailSubjectTagRegex, qr/\Q$rtname\E/i );
318
319 =item C<$OwnerEmail>
320
321 C<$OwnerEmail> is the address of a human who manages RT. RT will send
322 errors generated by the mail gateway to this address.  This address
323 should I<not> be an address that's managed by your RT instance.
324
325 =cut
326
327 Set($OwnerEmail, 'root');
328
329 =item C<$LoopsToRTOwner>
330
331 If C<$LoopsToRTOwner> is defined, RT will send mail that it believes
332 might be a loop to C<$OwnerEmail>.
333
334 =cut
335
336 Set($LoopsToRTOwner, 1);
337
338 =item C<$StoreLoops>
339
340 If C<$StoreLoops> is defined, RT will record messages that it believes
341 to be part of mail loops.  As it does this, it will try to be careful
342 not to send mail to the sender of these messages.
343
344 =cut
345
346 Set($StoreLoops, undef);
347
348 =item C<$MaxAttachmentSize>
349
350 C<$MaxAttachmentSize> sets the maximum size (in bytes) of attachments
351 stored in the database.
352
353 =cut
354
355 Set($MaxAttachmentSize, 10_000_000);
356
357 =item C<$TruncateLongAttachments>
358
359 If this is set to a non-undef value, RT will truncate attachments
360 longer than C<$MaxAttachmentSize>.
361
362 =cut
363
364 Set($TruncateLongAttachments, undef);
365
366 =item C<$DropLongAttachments>
367
368 If this is set to a non-undef value, RT will silently drop attachments
369 longer than C<MaxAttachmentSize>.  C<$TruncateLongAttachments>, above,
370 takes priority over this.
371
372 =cut
373
374 Set($DropLongAttachments, undef);
375
376 =item C<$RTAddressRegexp>
377
378 C<$RTAddressRegexp> is used to make sure RT doesn't add itself as a
379 ticket CC if C<$ParseNewMessageForTicketCcs>, above, is enabled.  It
380 is important that you set this to a regular expression that matches
381 all addresses used by your RT.  This lets RT avoid sending mail to
382 itself.  It will also hide RT addresses from the list of "One-time Cc"
383 and Bcc lists on ticket reply.
384
385 If you have a number of addresses configured in your RT database
386 already, you can generate a naive first pass regexp by using:
387
388     perl etc/upgrade/generate-rtaddressregexp
389
390 If left blank, RT will generate a regexp for you, based on your
391 comment and correspond address settings on your queues; this comes at
392 a small cost in start-up speed.
393
394 =cut
395
396 Set($RTAddressRegexp, undef);
397
398 =item C<$IgnoreCcRegexp>
399
400 C<$IgnoreCcRegexp> is a regexp to exclude addresses from automatic addition 
401 to the Cc list.  Use this for addresses that are I<not> received by RT but
402 are sometimes added to Cc lists by mistake.  Unlike C<$RTAddressRegexp>, 
403 these addresses can still receive email from RT otherwise.
404
405 =cut
406
407 Set($IgnoreCcRegexp, undef);
408
409 =item C<$CanonicalizeEmailAddressMatch>, C<$CanonicalizeEmailAddressReplace>
410
411 RT provides functionality which allows the system to rewrite incoming
412 email addresses.  In its simplest form, you can substitute the value
413 in C<CanonicalizeEmailAddressReplace> for the value in
414 C<CanonicalizeEmailAddressMatch> (These values are passed to the
415 C<CanonicalizeEmailAddress> subroutine in F<RT/User.pm>)
416
417 By default, that routine performs a C<s/$Match/$Replace/gi> on any
418 address passed to it.
419
420 =cut
421
422 # Set($CanonicalizeEmailAddressMatch, '@subdomain\.example\.com$');
423 # Set($CanonicalizeEmailAddressReplace, '@example.com');
424
425 =item C<$CanonicalizeOnCreate>
426
427 Set this to 1 and the create new user page will use the values that
428 you enter in the form but use the function CanonicalizeUserInfo in
429 F<RT/User_Local.pm>
430
431 =cut
432
433 Set($CanonicalizeOnCreate, 0);
434
435 =item C<$ValidateUserEmailAddresses>
436
437 If C<$ValidateUserEmailAddresses> is 1, RT will refuse to create
438 users with an invalid email address (as specified in RFC 2822) or with
439 an email address made of multiple email addresses.
440
441 =cut
442
443 Set($ValidateUserEmailAddresses, undef);
444
445 =item C<$NonCustomerEmailRegexp>
446
447 Normally, when a ticket is linked to a customer, any requestors on that
448 ticket that didn't previously have customer memberships are linked to 
449 the customer also.  C<$NonCustomerEmailRegexp> is a regexp for email 
450 addresses that should I<not> automatically be linked to a customer in 
451 this way.
452
453 =cut
454
455 Set($NonCustomerEmailRegexp, undef);
456
457 =item C<@MailPlugins>
458
459 C<@MailPlugins> is a list of authentication plugins for
460 L<RT::Interface::Email> to use; see L<rt-mailgate>
461
462 =cut
463
464 =item C<$UnsafeEmailCommands>
465
466 C<$UnsafeEmailCommands>, if set to 1, enables 'take' and 'resolve'
467 as possible actions via the mail gateway.  As its name implies, this
468 is very unsafe, as it allows email with a forged sender to possibly
469 resolve arbitrary tickets!
470
471 =cut
472
473 =item C<$ExtractSubjectTagMatch>, C<$ExtractSubjectTagNoMatch>
474
475 The default "extract remote tracking tags" scrip settings; these
476 detect when your RT is talking to another RT, and adjust the subject
477 accordingly.
478
479 =cut
480
481 Set($ExtractSubjectTagMatch, qr/\[.+? #\d+\]/);
482 Set($ExtractSubjectTagNoMatch, ( ${RT::EmailSubjectTagRegex}
483        ? qr/\[(?:${RT::EmailSubjectTagRegex}) #\d+\]/
484        : qr/\[\Q$RT::rtname\E #\d+\]/));
485
486 =back
487
488
489
490 =head1 Outgoing mail
491
492 =over 4
493
494 =item C<$MailCommand>
495
496 C<$MailCommand> defines which method RT will use to try to send mail.
497 We know that 'sendmailpipe' works fairly well.  If 'sendmailpipe'
498 doesn't work well for you, try 'sendmail'.  Other options are 'smtp'
499 or 'qmail'.
500
501 Note that you should remove the '-t' from C<$SendmailArguments> if you
502 use 'sendmail' rather than 'sendmailpipe'
503
504 For testing purposes, or to simply disable sending mail out into the
505 world, you can set C<$MailCommand> to 'testfile' which writes all mail
506 to a temporary file.  RT will log the location of the temporary file
507 so you can extract mail from it afterward.
508
509 =cut
510
511 Set($MailCommand, "sendmailpipe");
512
513 =item C<$SetOutgoingMailFrom>
514
515 C<$SetOutgoingMailFrom> tells RT to set the sender envelope to the
516 Correspond mail address of the ticket's queue.
517
518 Warning: If you use this setting, bounced mails will appear to be
519 incoming mail to the system, thus creating new tickets.
520
521 =cut
522
523 Set($SetOutgoingMailFrom, 0);
524
525 =item C<$OverrideOutgoingMailFrom>
526
527 C<$OverrideOutgoingMailFrom> is used for overwriting the Correspond
528 address of the queue as it is handed to sendmail -f. This helps force
529 the From_ header away from www-data or other email addresses that show
530 up in the "Sent by" line in Outlook.
531
532 The option is a hash reference of queue name to email address.  If
533 there is no ticket involved, then the value of the C<Default> key will
534 be used.
535
536 This option is irrelevant unless C<$SetOutgoingMailFrom> is set.
537
538 =cut
539
540 Set($OverrideOutgoingMailFrom, {
541 #    'Default' => 'admin@rt.example.com',
542 #    'General' => 'general@rt.example.com',
543 });
544
545 =item C<$DefaultMailPrecedence>
546
547 C<$DefaultMailPrecedence> is used to control the default Precedence
548 level of outgoing mail where none is specified.  By default it is
549 C<bulk>, but if you only send mail to your staff, you may wish to
550 change it.
551
552 Note that you can set the precedence of individual templates by
553 including an explicit Precedence header.
554
555 If you set this value to C<undef> then we do not set a default
556 Precedence header to outgoing mail. However, if there already is a
557 Precedence header, it will be preserved.
558
559 =cut
560
561 Set($DefaultMailPrecedence, "bulk");
562
563 =item C<$DefaultErrorMailPrecedence>
564
565 C<$DefaultErrorMailPrecedence> is used to control the default
566 Precedence level of outgoing mail that indicates some kind of error
567 condition. By default it is C<bulk>, but if you only send mail to your
568 staff, you may wish to change it.
569
570 If you set this value to C<undef> then we do not add a Precedence
571 header to error mail.
572
573 =cut
574
575 Set($DefaultErrorMailPrecedence, "bulk");
576
577 =item C<$UseOriginatorHeader>
578
579 C<$UseOriginatorHeader> is used to control the insertion of an
580 RT-Originator Header in every outgoing mail, containing the mail
581 address of the transaction creator.
582
583 =cut
584
585 Set($UseOriginatorHeader, 1);
586
587 =item C<$UseFriendlyFromLine>
588
589 By default, RT sets the outgoing mail's "From:" header to "SenderName
590 via RT".  Setting C<$UseFriendlyFromLine> to 0 disables it.
591
592 =cut
593
594 Set($UseFriendlyFromLine, 1);
595
596 =item C<$FriendlyFromLineFormat>
597
598 C<sprintf()> format of the friendly 'From:' header; its arguments are
599 SenderName and SenderEmailAddress.
600
601 =cut
602
603 Set($FriendlyFromLineFormat, "\"%s via RT\" <%s>");
604
605 =item C<$UseFriendlyToLine>
606
607 RT can optionally set a "Friendly" 'To:' header when sending messages
608 to Ccs or AdminCcs (rather than having a blank 'To:' header.
609
610 This feature DOES NOT WORK WITH SENDMAIL[tm] BRAND SENDMAIL.  If you
611 are using sendmail, rather than postfix, qmail, exim or some other
612 MTA, you _must_ disable this option.
613
614 =cut
615
616 Set($UseFriendlyToLine, 0);
617
618 =item C<$FriendlyToLineFormat>
619
620 C<sprintf()> format of the friendly 'To:' header; its arguments are
621 WatcherType and TicketId.
622
623 =cut
624
625 Set($FriendlyToLineFormat, "\"%s of ". RT->Config->Get('rtname') ." Ticket #%s\":;");
626
627 =item C<$NotifyActor>
628
629 By default, RT doesn't notify the person who performs an update, as
630 they already know what they've done. If you'd like to change this
631 behavior, Set C<$NotifyActor> to 1
632
633 =cut
634
635 Set($NotifyActor, 0);
636
637 =item C<$RecordOutgoingEmail>
638
639 By default, RT records each message it sends out to its own internal
640 database.  To change this behavior, set C<$RecordOutgoingEmail> to 0
641
642 =cut
643
644 Set($RecordOutgoingEmail, 1);
645
646 =item C<$VERPPrefix>, C<$VERPDomain>
647
648 Setting these options enables VERP support
649 L<http://cr.yp.to/proto/verp.txt>.
650
651 Uncomment the following two directives to generate envelope senders
652 of the form C<${VERPPrefix}${originaladdress}@${VERPDomain}>
653 (i.e. rt-jesse=fsck.com@rt.example.com ).
654
655 This currently only works with sendmail and sendmailpipe.
656
657 =cut
658
659 # Set($VERPPrefix, "rt-");
660 # Set($VERPDomain, $RT::Organization);
661
662
663 =item C<$ForwardFromUser>
664
665 By default, RT forwards a message using queue's address and adds RT's
666 tag into subject of the outgoing message, so recipients' replies go
667 into RT as correspondents.
668
669 To change this behavior, set C<$ForwardFromUser> to 1 and RT
670 will use the address of the current user and remove RT's subject tag.
671
672 =cut
673
674 Set($ForwardFromUser, 0);
675
676 =back
677
678 =head2 Email dashboards
679
680 =over 4
681
682 =item C<$DashboardAddress>
683
684 The email address from which RT will send dashboards. If none is set,
685 then C<$OwnerEmail> will be used.
686
687 =cut
688
689 Set($DashboardAddress, '');
690
691 =item C<$DashboardSubject>
692
693 Lets you set the subject of dashboards. Arguments are the frequency (Daily,
694 Weekly, Monthly) of the dashboard and the dashboard's name.
695
696 =cut
697
698 Set($DashboardSubject, "%s Dashboard: %s");
699
700 =item C<@EmailDashboardRemove>
701
702 A list of regular expressions that will be used to remove content from
703 mailed dashboards.
704
705 =cut
706
707 Set(@EmailDashboardRemove, ());
708
709 =back
710
711
712
713 =head2 Sendmail configuration
714
715 These options only take effect if C<$MailCommand> is 'sendmail' or
716 'sendmailpipe'
717
718 =over 4
719
720 =item C<$SendmailArguments>
721
722 C<$SendmailArguments> defines what flags to pass to C<$SendmailPath>
723 If you picked 'sendmailpipe', you MUST add a -t flag to
724 C<$SendmailArguments> These options are good for most sendmail
725 wrappers and work-a-likes.
726
727 These arguments are good for sendmail brand sendmail 8 and newer:
728 C<Set($SendmailArguments,"-oi -t -ODeliveryMode=b -OErrorMode=m");>
729
730 =cut
731
732 Set($SendmailArguments, "-oi -t");
733
734
735 =item C<$SendmailBounceArguments>
736
737 C<$SendmailBounceArguments> defines what flags to pass to C<$Sendmail>
738 assuming RT needs to send an error (i.e. bounce).
739
740 =cut
741
742 Set($SendmailBounceArguments, '-f "<>"');
743
744 =item C<$SendmailPath>
745
746 If you selected 'sendmailpipe' above, you MUST specify the path to
747 your sendmail binary in C<$SendmailPath>.
748
749 =cut
750
751 Set($SendmailPath, "/usr/sbin/sendmail");
752
753
754 =back
755
756 =head2 SMTP configuration
757
758 These options only take effect if C<$MailCommand> is 'smtp'
759
760 =over 4
761
762 =item C<$SMTPServer>
763
764 C<$SMTPServer> should be set to the hostname of the SMTP server to use
765
766 =cut
767
768 Set($SMTPServer, undef);
769
770 =item C<$SMTPFrom>
771
772 C<$SMTPFrom> should be set to the 'From' address to use, if not the
773 email's 'From'
774
775 =cut
776
777 Set($SMTPFrom, undef);
778
779 =item C<$SMTPDebug>
780
781 C<$SMTPDebug> should be set to 1 to debug SMTP mail sending
782
783 =cut
784
785 Set($SMTPDebug, 0);
786
787 =back
788
789 =head2 Other mailers
790
791 =over 4
792
793 =item C<@MailParams>
794
795 C<@MailParams> defines a list of options passed to $MailCommand if it
796 is not 'sendmailpipe', 'sendmail', or 'smtp'
797
798 =cut
799
800 Set(@MailParams, ());
801
802 =back
803
804
805 =head1 Web interface
806
807 =over 4
808
809 =item C<$WebDefaultStylesheet>
810
811 This determines the default stylesheet the RT web interface will use.
812 RT ships with several themes by default:
813
814   web2            The default layout for RT 3.8
815   aileron         The default layout for RT 4.0
816   ballard         Theme which doesn't rely on JavaScript for menuing
817
818 This bundled distibution of RT also includes:
819   freeside3       Integration with Freeside (enabled by default)
820   freeside2.1     Previous Freeside theme
821
822 This value actually specifies a directory in F<share/html/NoAuth/css/>
823 from which RT will try to load the file main.css (which should @import
824 any other files the stylesheet needs).  This allows you to easily and
825 cleanly create your own stylesheets to apply to RT.  This option can
826 be overridden by users in their preferences.
827
828 =cut
829
830 Set($WebDefaultStylesheet, "freeside3");
831
832 =item C<$DefaultQueue>
833
834 Use this to select the default queue name that will be used for
835 creating new tickets. You may use either the queue's name or its
836 ID. This only affects the queue selection boxes on the web interface.
837
838 =cut
839
840 # Set($DefaultQueue, "General");
841
842 =item C<$RememberDefaultQueue>
843
844 When a queue is selected in the new ticket dropdown, make it the new
845 default for the new ticket dropdown.
846
847 =cut
848
849 # Set($RememberDefaultQueue, 1);
850
851 =item C<$EnableReminders>
852
853 Hide all links and portlets related to Reminders by setting this to 0
854
855 =cut
856
857 Set($EnableReminders, 1);
858
859 =item C<@CustomFieldValuesSources>
860
861 Set C<@CustomFieldValuesSources> to a list of class names which extend
862 L<RT::CustomFieldValues::External>.  This can be used to pull lists of
863 custom field values from external sources at runtime.
864
865 =cut
866
867 Set(@CustomFieldValuesSources, ('RT::CustomFieldValues::Queues'));
868
869 =item C<$CanonicalizeRedirectURLs>
870
871 Set C<$CanonicalizeRedirectURLs> to 1 to use C<$WebURL> when
872 redirecting rather than the one we get from C<%ENV>.
873
874 Apache's UseCanonicalName directive changes the hostname that RT
875 finds in C<%ENV>.  You can read more about what turning it On or Off
876 means in the documentation for your version of Apache.
877
878 If you use RT behind a reverse proxy, you almost certainly want to
879 enable this option.
880
881 =cut
882
883 Set($CanonicalizeRedirectURLs, 0);
884
885 =item C<@JSFiles>
886
887 A list of JavaScript files to be included in head.  Removing any of
888 the default entries is not suggested.
889
890 If you're a plugin author, refer to RT->AddJavaScript.
891
892 =cut
893
894 Set(@JSFiles, qw/
895     jquery-1.4.2.min.js
896     jquery_noconflict.js
897     jquery-ui-1.8.4.custom.min.js
898     jquery-ui-patch-datepicker.js
899     ui.timepickr.js
900     titlebox-state.js
901     util.js
902     userautocomplete.js
903     jquery.event.hover-1.0.js
904     superfish.js
905     supersubs.js
906     jquery.supposition.js
907     history-folding.js
908     late.js
909 /);
910
911 =item C<$JSMinPath>
912
913 Path to the jsmin binary; if specified, it will be used to minify
914 C<JSFiles>.  The default, and the fallback if the binary cannot be
915 found, is to simply concatenate the files.
916
917 jsmin can be installed by running 'make jsmin' from the RT install
918 directory, or from http://www.crockford.com/javascript/jsmin.html
919
920 =cut
921
922 # Set($JSMinPath, "/path/to/jsmin");
923
924 =item C<@CSSFiles>
925
926 A list of additional CSS files to be included in head.
927
928 If you're a plugin author, refer to RT->AddStyleSheets.
929
930 =cut
931
932 Set(@CSSFiles, qw//);
933
934 =item C<$UsernameFormat>
935
936 This determines how user info is displayed. 'concise' will show one of
937 either NickName, RealName, Name or EmailAddress, depending on what
938 exists and whether the user is privileged or not. 'verbose' will show
939 RealName and EmailAddress.
940
941 =cut
942
943 Set($UsernameFormat, "verbose");
944
945 =item C<$WebBaseURL>, C<$WebURL>
946
947 Usually you don't want to set these options. The only obvious reason
948 is if RT is accessible via https protocol on a non standard port, e.g.
949 'https://rt.example.com:9999'. In all other cases these options are
950 computed using C<$WebDomain>, C<$WebPort> and C<$WebPath>.
951
952 C<$WebBaseURL> is the scheme, server and port
953 (e.g. 'http://rt.example.com') for constructing URLs to the web
954 UI. C<$WebBaseURL> doesn't need a trailing /.
955
956 C<$WebURL> is the C<$WebBaseURL>, C<$WebPath> and trailing /, for
957 example: 'http://www.example.com/rt/'.
958
959 =cut
960
961 my $port = RT->Config->Get('WebPort');
962 Set($WebBaseURL,
963     ($port == 443? 'https': 'http') .'://'
964     . RT->Config->Get('WebDomain')
965     . ($port != 80 && $port != 443? ":$port" : '')
966 );
967
968 Set($WebURL, RT->Config->Get('WebBaseURL') . RT->Config->Get('WebPath') . "/");
969
970 =item C<$WebImagesURL>
971
972 C<$WebImagesURL> points to the base URL where RT can find its images.
973 Define the directory name to be used for images in RT web documents.
974
975 =cut
976
977 Set($WebImagesURL, RT->Config->Get('WebPath') . "/NoAuth/images/");
978
979 =item C<$LogoURL>
980
981 C<$LogoURL> points to the URL of the RT logo displayed in the web UI.
982 This can also be configured via the web UI.
983
984 =cut
985
986 Set($LogoURL, RT->Config->Get('WebImagesURL') . "bpslogo.png");
987
988 =item C<$LogoLinkURL>
989
990 C<$LogoLinkURL> is the URL that the RT logo hyperlinks to.
991
992 =cut
993
994 Set($LogoLinkURL, "http://bestpractical.com");
995
996 =item C<$LogoAltText>
997
998 C<$LogoAltText> is a string of text for the alt-text of the logo. It
999 will be passed through C<loc> for localization.
1000
1001 =cut
1002
1003 Set($LogoAltText, "Best Practical Solutions, LLC corporate logo");
1004
1005 =item C<$LogoImageHeight>
1006
1007 C<$LogoImageHeight> is the value of the C<height> attribute of the logo
1008 C<img> tag.
1009
1010 =cut
1011
1012 Set($LogoImageHeight, 38);
1013
1014 =item C<$LogoImageWidth>
1015
1016 C<$LogoImageWidth> is the value of the C<width> attribute of the logo
1017 C<img> tag.
1018
1019 =cut
1020
1021 Set($LogoImageWidth, 181);
1022
1023 =item C<$WebNoAuthRegex>
1024
1025 What portion of RT's URL space should not require authentication.  The
1026 default is almost certainly correct, and should only be changed if you
1027 are extending RT.
1028
1029 =cut
1030
1031 Set($WebNoAuthRegex, qr{^ /rt (?:/+NoAuth/ | /+REST/\d+\.\d+/NoAuth/) }x );
1032
1033 =item C<$SelfServiceRegex>
1034
1035 What portion of RT's URLspace should be accessible to Unprivileged
1036 users This does not override the redirect from F</Ticket/Display.html>
1037 to F</SelfService/Display.html> when Unprivileged users attempt to
1038 access ticked displays.
1039
1040 =cut
1041
1042 Set($SelfServiceRegex, qr!^(?:/+SelfService/)!x );
1043
1044 =item C<$WebFlushDbCacheEveryRequest>
1045
1046 By default, RT clears its database cache after every page view.  This
1047 ensures that you've always got the most current information when
1048 working in a multi-process (mod_perl or FastCGI) Environment.  Setting
1049 C<$WebFlushDbCacheEveryRequest> to 0 will turn this off, which will
1050 speed RT up a bit, at the expense of a tiny bit of data accuracy.
1051
1052 =cut
1053
1054 Set($WebFlushDbCacheEveryRequest, 1);
1055
1056 =item C<%ChartFont>
1057
1058 The L<GD> module (which RT uses for graphs) ships with a built-in font
1059 that doesn't have full Unicode support. You can use a given TrueType
1060 font for a specific language by setting %ChartFont to (language =E<gt>
1061 the absolute path of a font) pairs. Your GD library must have support
1062 for TrueType fonts to use this option. If there is no entry for a
1063 language in the hash then font with 'others' key is used.
1064
1065 RT comes with two TrueType fonts covering most available languages.
1066
1067 =cut
1068
1069 Set(
1070     %ChartFont,
1071     'zh-cn'  => "$RT::BasePath/share/fonts/DroidSansFallback.ttf",
1072     'zh-tw'  => "$RT::BasePath/share/fonts/DroidSansFallback.ttf",
1073     'ja'     => "$RT::BasePath/share/fonts/DroidSansFallback.ttf",
1074     'others' => "$RT::BasePath/share/fonts/DroidSans.ttf",
1075 );
1076
1077 =item C<$ChartsTimezonesInDB>
1078
1079 RT stores dates using the UTC timezone in the DB, so charts grouped by
1080 dates and time are not representative. Set C<$ChartsTimezonesInDB> to 1
1081 to enable timezone conversions using your DB's capabilities. You may
1082 need to do some work on the DB side to use this feature, read more in
1083 F<docs/customizing/timezones_in_charts.pod>.
1084
1085 At this time, this feature only applies to MySQL and PostgreSQL.
1086
1087 =cut
1088
1089 Set($ChartsTimezonesInDB, 0);
1090
1091 =back
1092
1093
1094
1095 =head2 Home page
1096
1097 =over 4
1098
1099 =item C<$DefaultSummaryRows>
1100
1101 C<$DefaultSummaryRows> is default number of rows displayed in for
1102 search results on the front page.
1103
1104 =cut
1105
1106 Set($DefaultSummaryRows, 10);
1107
1108 =item C<$HomePageRefreshInterval>
1109
1110 C<$HomePageRefreshInterval> is default number of seconds to refresh
1111 the RT home page. Choose from [0, 120, 300, 600, 1200, 3600, 7200].
1112
1113 =cut
1114
1115 Set($HomePageRefreshInterval, 0);
1116
1117 =item C<$HomepageComponents>
1118
1119 C<$HomepageComponents> is an arrayref of allowed components on a
1120 user's customized homepage ("RT at a glance").
1121
1122 =cut
1123
1124 Set($HomepageComponents, [qw(QuickCreate Quicksearch MyCalendar MyAdminQueues MySupportQueues MyReminders RefreshHomepage Dashboards SavedSearches)]);
1125
1126 =back
1127
1128
1129
1130
1131 =head2 Ticket search
1132
1133 =over 4
1134
1135 =item C<$UseSQLForACLChecks>
1136
1137 Historically, ACLs were checked on display, which could lead to empty
1138 search pages and wrong ticket counts.  Set C<$UseSQLForACLChecks> to 1
1139 to limit search results in SQL instead, which eliminates these
1140 problems.
1141
1142 This option is still relatively new; it may result in performance
1143 problems in some cases, or significant speedups in others.
1144
1145 =cut
1146
1147 Set($UseSQLForACLChecks, undef);
1148
1149 =item C<$TicketsItemMapSize>
1150
1151 On the display page of a ticket from search results, RT provides links
1152 to the first, next, previous and last ticket from the results.  In
1153 order to build these links, RT needs to fetch the full result set from
1154 the database, which can be resource-intensive.
1155
1156 Set C<$TicketsItemMapSize> to number of tickets you want RT to examine
1157 to build these links. If the full result set is larger than this
1158 number, RT will omit the "last" link in the menu.  Set this to zero to
1159 always examine all results.
1160
1161 =cut
1162
1163 Set($TicketsItemMapSize, 1000);
1164
1165 =item C<$SearchResultsRefreshInterval>
1166
1167 C<$SearchResultsRefreshInterval> is default number of seconds to
1168 refresh search results in RT. Choose from [0, 120, 300, 600, 1200,
1169 3600, 7200].
1170
1171 =cut
1172
1173 Set($SearchResultsRefreshInterval, 0);
1174
1175 =item C<$DefaultSearchResultFormat>
1176
1177 C<$DefaultSearchResultFormat> is the default format for RT search
1178 results
1179
1180 =cut
1181
1182 Set ($DefaultSearchResultFormat, qq{
1183    '<B><A HREF="__WebPath__/Ticket/Display.html?id=__id__">__id__</a></B>/TITLE:#',
1184    '<B><A HREF="__WebPath__/Ticket/Display.html?id=__id__">__Subject__</a></B>/TITLE:Subject',
1185    Customer,
1186    Status,
1187    QueueName,
1188    OwnerName,
1189    Priority,
1190    '__NEWLINE__',
1191    '',
1192    '<small>__Requestors__</small>',
1193    '<small>__CustomerTags__</small>',
1194    '<small>__CreatedRelative__</small>',
1195    '<small>__ToldRelative__</small>',
1196    '<small>__LastUpdatedRelative__</small>',
1197    '<small>__TimeLeft__</small>'});
1198
1199 =item C<$DefaultSelfServiceSearchResultFormat>
1200
1201 C<$DefaultSelfServiceSearchResultFormat> is the default format of
1202 searches displayed in the SelfService interface.
1203
1204 =cut
1205
1206 Set($DefaultSelfServiceSearchResultFormat, qq{
1207    '<B><A HREF="__WebPath__/SelfService/Display.html?id=__id__">__id__</a></B>/TITLE:#',
1208    '<B><A HREF="__WebPath__/SelfService/Display.html?id=__id__">__Subject__</a></B>/TITLE:Subject',
1209    Status,
1210    Requestors,
1211    OwnerName});
1212
1213 =item C<%FullTextSearch>
1214
1215 Full text search (FTS) without database indexing is a very slow
1216 operation, and is thus disabled by default.
1217
1218 Before setting C<Indexed> to 1, read F<docs/full_text_indexing.pod> for
1219 the full details of FTS on your particular database.
1220
1221 It is possible to enable FTS without database indexing support, simply
1222 by setting the C<Enable> key to 1, while leaving C<Indexed> set to 0.
1223 This is not generally suggested, as unindexed full-text searching can
1224 cause severe performance problems.
1225
1226 =cut
1227
1228 Set(%FullTextSearch,
1229     Enable  => 0,
1230     Indexed => 0,
1231 );
1232
1233
1234 =item C<$OnlySearchActiveTicketsInSimpleSearch>
1235
1236 When query in simple search doesn't have status info, use this to only
1237 search active ones.
1238
1239 =cut
1240
1241 Set($OnlySearchActiveTicketsInSimpleSearch, 1);
1242
1243 =item C<$SearchResultsAutoRedirect>
1244
1245 When only one ticket is found in search, use this to redirect to the
1246 ticket display page automatically.
1247
1248 =cut
1249
1250 Set($SearchResultsAutoRedirect, 0);
1251
1252 =back
1253
1254
1255
1256 =head2 Ticket display
1257
1258 =over 4
1259
1260 =item C<$ShowMoreAboutPrivilegedUsers>
1261
1262 This determines if the 'More about requestor' box on
1263 Ticket/Display.html is shown for Privileged Users.
1264
1265 =cut
1266
1267 Set($ShowMoreAboutPrivilegedUsers, 0);
1268
1269 =item C<$MoreAboutRequestorTicketList>
1270
1271 This can be set to Active, Inactive, All or None.  It controls what
1272 ticket list will be displayed in the 'More about requestor' box on
1273 Ticket/Display.html.  This option can be controlled by users also.
1274
1275 =cut
1276
1277 Set($MoreAboutRequestorTicketList, "Active");
1278
1279 =item C<$MoreAboutRequestorExtraInfo>
1280
1281 By default, the 'More about requestor' box on Ticket/Display.html
1282 shows the Requestor's name and ticket list.  If you would like to see
1283 extra information about the user, this expects a Format string of user
1284 attributes.  Please note that not all the attributes are supported in
1285 this display because we're not building a table.
1286
1287 Example:
1288 C<Set($MoreAboutRequestorExtraInfo,"Organization, Address1")>
1289
1290 =cut
1291
1292 Set($MoreAboutRequestorExtraInfo, "");
1293
1294 =item C<$MoreAboutRequestorGroupsLimit>
1295
1296 By default, the 'More about requestor' box on Ticket/Display.html
1297 shows all the groups of the Requestor.  Use this to limit the number
1298 of groups; a value of undef removes the group display entirely.
1299
1300 =cut
1301
1302 Set($MoreAboutRequestorGroupsLimit, 0);
1303
1304 =item C<$UseSideBySideLayout>
1305
1306 Should the ticket create and update forms use a more space efficient
1307 two column layout.  This layout may not work in narrow browsers if you
1308 set a MessageBoxWidth (below).
1309
1310 =cut
1311
1312 Set($UseSideBySideLayout, 1);
1313
1314 =item C<$EditCustomFieldsSingleColumn>
1315
1316 When displaying a list of Ticket Custom Fields for editing, RT
1317 defaults to a 2 column list.  If you set this to 1, it will instead
1318 display the Custom Fields in a single column.
1319
1320 =cut
1321
1322 Set($EditCustomFieldsSingleColumn, 0);
1323
1324 =item C<$ShowUnreadMessageNotifications>
1325
1326 If set to 1, RT will prompt users when there are new,
1327 unread messages on tickets they are viewing.
1328
1329 =cut
1330
1331 Set($ShowUnreadMessageNotifications, 0);
1332
1333 =item C<$AutocompleteOwners>
1334
1335 If set to 1, the owner drop-downs for ticket update/modify and the query
1336 builder are replaced by text fields that autocomplete.  This can
1337 alleviate the sometimes huge owner list for installations where many
1338 users have the OwnTicket right.
1339
1340 =cut
1341
1342 Set($AutocompleteOwners, 0);
1343
1344 =item C<$AutocompleteOwnersForSearch>
1345
1346 If set to 1, the owner drop-downs for the query builder are always
1347 replaced by text field that autocomplete and C<$AutocompleteOwners>
1348 is ignored. Helpful when owners list is huge in the query builder.
1349
1350 =cut
1351
1352 Set($AutocompleteOwnersForSearch, 0);
1353
1354 =item C<$UserAutocompleteFields>
1355
1356 Specifies which fields of L<RT::User> to match against and how to
1357 match each field when autocompleting users.  Valid match methods are
1358 LIKE, STARTSWITH, ENDSWITH, =, and !=.
1359
1360 =cut
1361
1362 Set($UserAutocompleteFields, {
1363     EmailAddress => 'STARTSWITH',
1364     Name         => 'STARTSWITH',
1365     RealName     => 'LIKE',
1366 });
1367
1368 =item C<$AllowUserAutocompleteForUnprivileged>
1369
1370 Should unprivileged users be allowed to autocomplete users.  Setting
1371 this option to 1 means unprivileged users will be able to search all
1372 your users.
1373
1374 =cut
1375
1376 Set($AllowUserAutocompleteForUnprivileged, 0);
1377
1378 =item C<$DisplayTicketAfterQuickCreate>
1379
1380 Enable this to redirect to the created ticket display page
1381 automatically when using QuickCreate.
1382
1383 =cut
1384
1385 Set($DisplayTicketAfterQuickCreate, 0);
1386
1387 =item C<$WikiImplicitLinks>
1388
1389 Support implicit links in WikiText custom fields?  Setting this to 1
1390 causes InterCapped or ALLCAPS words in WikiText fields to automatically
1391 become links to searches for those words.  If used on Articles, it links
1392 to the Article with that name.
1393
1394 =cut
1395
1396 Set($WikiImplicitLinks, 0);
1397
1398 =item C<$PreviewScripMessages>
1399
1400 Set C<$PreviewScripMessages> to 1 if the scrips preview on the ticket
1401 reply page should include the content of the messages to be sent.
1402
1403 =cut
1404
1405 Set($PreviewScripMessages, 0);
1406
1407 =item C<$SimplifiedRecipients>
1408
1409 If C<$SimplifiedRecipients> is set, a simple list of who will receive
1410 B<any> kind of mail will be shown on the ticket reply page, instead of a
1411 detailed breakdown by scrip.
1412
1413 =cut
1414
1415 Set($SimplifiedRecipients, 0);
1416
1417 =item C<$HideResolveActionsWithDependencies>
1418
1419 If set to 1, this option will skip ticket menu actions which can't be
1420 completed successfully because of outstanding active Depends On tickets.
1421
1422 By default, all ticket actions are displayed in the menu even if some of
1423 them can't be successful until all Depends On links are resolved or
1424 transitioned to another inactive status.
1425
1426 =cut
1427
1428 Set($HideResolveActionsWithDependencies, 0);
1429
1430 =back
1431
1432
1433
1434 =head2 Articles
1435
1436 =over 4
1437
1438 =item C<$ArticleOnTicketCreate>
1439
1440 Set this to 1 to display the Articles interface on the Ticket Create
1441 page in addition to the Reply/Comment page.
1442
1443 =cut
1444
1445 Set($ArticleOnTicketCreate, 0);
1446
1447 =item C<$HideArticleSearchOnReplyCreate>
1448
1449 Set this to 1 to hide the search and include boxes from the Article
1450 UI.  This assumes you have enabled Article Hotlist feature, otherwise
1451 you will have no access to Articles.
1452
1453 =cut
1454
1455 Set($HideArticleSearchOnReplyCreate, 0);
1456
1457 =back
1458
1459
1460
1461 =head2 Message box properties
1462
1463 =over 4
1464
1465 =item C<$MessageBoxWidth>, C<$MessageBoxHeight>
1466
1467 For message boxes, set the entry box width, height and what type of
1468 wrapping to use.  These options can be overridden by users in their
1469 preferences.
1470
1471 When the width is set to undef, no column count is specified and the
1472 message box will take up 100% of the available width.  Combining this
1473 with HARD messagebox wrapping (below) is not recommended, as it will
1474 lead to inconsistent width in transactions between browsers.
1475
1476 These settings only apply to the non-RichText message box.  See below
1477 for Rich Text settings.
1478
1479 =cut
1480
1481 Set($MessageBoxWidth, undef);
1482 Set($MessageBoxHeight, 15);
1483
1484 =item C<$MessageBoxWrap>
1485
1486 Wrapping is disabled when using MessageBoxRichText because of a bad
1487 interaction between IE and wrapping with the Rich Text Editor.
1488
1489 =cut
1490
1491 Set($MessageBoxWrap, "SOFT");
1492
1493 =item C<$MessageBoxRichText>
1494
1495 Should "rich text" editing be enabled? This option lets your users
1496 send HTML email messages from the web interface.
1497
1498 =cut
1499
1500 Set($MessageBoxRichText, 1);
1501
1502 =item C<$MessageBoxRichTextHeight>
1503
1504 Height of rich text JavaScript enabled editing boxes (in pixels)
1505
1506 =cut
1507
1508 Set($MessageBoxRichTextHeight, 200);
1509
1510 =item C<$MessageBoxIncludeSignature>
1511
1512 Should your users' signatures (from their Preferences page) be
1513 included in Comments and Replies.
1514
1515 =cut
1516
1517 Set($MessageBoxIncludeSignature, 1);
1518
1519 =item C<$MessageBoxIncludeSignatureOnComment>
1520
1521 Should your users' signatures (from their Preferences page) be
1522 included in Comments. Setting this to false overrides
1523 C<$MessageBoxIncludeSignature>.
1524
1525 =cut
1526
1527 Set($MessageBoxIncludeSignatureOnComment, 1);
1528
1529 =back
1530
1531
1532 =head2 Transaction display
1533
1534 =over 4
1535
1536 =item C<$OldestTransactionsFirst>
1537
1538 By default, RT shows newest transactions at the bottom of the ticket
1539 history page, if you want see them at the top set this to 0.  This
1540 option can be overridden by users in their preferences.
1541
1542 =cut
1543
1544 Set($OldestTransactionsFirst, 1);
1545
1546 =item C<$DeferTransactionLoading>
1547
1548 When set, defers loading ticket history until the user clicks a link.
1549 This should end up serving pages to users quicker, since generating
1550 all the HTML for transaction history can be slow for long tickets.
1551
1552 =cut
1553
1554 # Set($DeferTransactionLoading, 1);
1555
1556 =item C<$ShowBccHeader>
1557
1558 By default, RT hides from the web UI information about blind copies
1559 user sent on reply or comment.
1560
1561 =cut
1562
1563 Set($ShowBccHeader, 0);
1564
1565 =item C<$TrustHTMLAttachments>
1566
1567 If C<TrustHTMLAttachments> is not defined, we will display them as
1568 text. This prevents malicious HTML and JavaScript from being sent in a
1569 request (although there is probably more to it than that)
1570
1571 =cut
1572
1573 Set($TrustHTMLAttachments, undef);
1574
1575 =item C<$AlwaysDownloadAttachments>
1576
1577 Always download attachments, regardless of content type. If set, this
1578 overrides C<TrustHTMLAttachments>.
1579
1580 =cut
1581
1582 Set($AlwaysDownloadAttachments, undef);
1583
1584 =item C<$AttachmentUnits>
1585
1586 Controls the units (kilobytes or bytes) that attachment sizes use for
1587 display. The default is to display kilobytes if the attachment is
1588 larger than 1024 bytes, bytes otherwise. If you set
1589 C<$AttachmentUnits> to C<'k'> then attachment sizes will always be
1590 displayed in kilobytes. If set to C<'b'>, then sizes will be bytes.
1591
1592 =cut
1593
1594 Set($AttachmentUnits, undef);
1595
1596 =item C<$PreferRichText>
1597
1598 If C<$PreferRichText> is set to 1, RT will show HTML/Rich text messages
1599 in preference to their plain-text alternatives. RT "scrubs" the HTML to
1600 show only a minimal subset of HTML to avoid possible contamination by
1601 cross-site-scripting attacks.
1602
1603 =cut
1604
1605 Set($PreferRichText, undef);
1606
1607 =item C<$MaxInlineBody>
1608
1609 C<$MaxInlineBody> is the maximum attachment size that we want to see
1610 inline when viewing a transaction.  RT will inline any text if the
1611 value is undefined or 0.  This option can be overridden by users in
1612 their preferences.
1613
1614 =cut
1615
1616 Set($MaxInlineBody, 12000);
1617
1618 =item C<$ShowTransactionImages>
1619
1620 By default, RT shows images attached to incoming (and outgoing) ticket
1621 updates inline. Set this variable to 0 if you'd like to disable that
1622 behavior.
1623
1624 =cut
1625
1626 Set($ShowTransactionImages, 1);
1627
1628 =item C<$PlainTextPre>
1629
1630 Normally plaintext attachments are displayed as HTML with line breaks
1631 preserved.  This causes space- and tab-based formatting not to be
1632 displayed correctly.  By setting $PlainTextPre messages will be
1633 displayed using <pre>.
1634
1635 =cut
1636
1637 Set($PlainTextPre, 0);
1638
1639
1640 =item C<$PlainTextMono>
1641
1642 Set C<$PlainTextMono> to 1 to use monospaced font and preserve
1643 formatting; unlike C<$PlainTextPre>, the text will wrap to fit width
1644 of the browser window; this option overrides C<$PlainTextPre>.
1645
1646 =cut
1647
1648 Set($PlainTextMono, 0);
1649
1650 =item C<$SuppressInlineTextFiles>
1651
1652 If C<$SuppressInlineTextFiles> is set to 1, then uploaded text files
1653 (text-type attachments with file names) are prevented from being
1654 displayed in-line when viewing a ticket's history.
1655
1656 =cut
1657
1658 Set($SuppressInlineTextFiles, undef);
1659
1660
1661 =item C<@Active_MakeClicky>
1662
1663 MakeClicky detects various formats of data in headers and email
1664 messages, and extends them with supporting links.  By default, RT
1665 provides two formats:
1666
1667 * 'httpurl': detects http:// and https:// URLs and adds '[Open URL]'
1668   link after the URL.
1669
1670 * 'httpurl_overwrite': also detects URLs as 'httpurl' format, but
1671   replaces the URL with a link.
1672
1673 See F<share/html/Elements/MakeClicky> for documentation on how to add
1674 your own styles of link detection.
1675
1676 =cut
1677
1678 Set(@Active_MakeClicky, qw());
1679
1680 =back
1681
1682
1683
1684 =head1 Application logic
1685
1686 =over 4
1687
1688 =item C<$ParseNewMessageForTicketCcs>
1689
1690 If C<$ParseNewMessageForTicketCcs> is set to 1, RT will attempt to
1691 divine Ticket 'Cc' watchers from the To and Cc lines of incoming
1692 messages.  Be forewarned that if you have I<any> addresses which forward
1693 mail to RT automatically and you enable this option without modifying
1694 C<$RTAddressRegexp> below, you will get yourself into a heap of trouble.
1695
1696 =cut
1697
1698 Set($ParseNewMessageForTicketCcs, undef);
1699
1700 =item C<$UseTransactionBatch>
1701
1702 Set C<$UseTransactionBatch> to 1 to execute transactions in batches,
1703 such that a resolve and comment (for example) would happen
1704 simultaneously, instead of as two transactions, unaware of each
1705 others' existence.
1706
1707 =cut
1708
1709 Set($UseTransactionBatch, 1);
1710
1711 =item C<$StrictLinkACL>
1712
1713 When this feature is enabled a user needs I<ModifyTicket> rights on
1714 both tickets to link them together; otherwise, I<ModifyTicket> rights
1715 on either of them is sufficient.
1716
1717 =cut
1718
1719 Set($StrictLinkACL, 1);
1720
1721 =item C<$RedistributeAutoGeneratedMessages>
1722
1723 Should RT redistribute correspondence that it identifies as machine
1724 generated?  A 1 will do so; setting this to 0 will cause no
1725 such messages to be redistributed.  You can also use 'privileged' (the
1726 default), which will redistribute only to privileged users. This helps
1727 to protect against malformed bounces and loops caused by auto-created
1728 requestors with bogus addresses.
1729
1730 =cut
1731
1732 Set($RedistributeAutoGeneratedMessages, "privileged");
1733
1734 =item C<$ApprovalRejectionNotes>
1735
1736 Should rejection notes from approvals be sent to the requestors?
1737
1738 =cut
1739
1740 Set($ApprovalRejectionNotes, 1);
1741
1742 =item C<$ForceApprovalsView>
1743
1744 Should approval tickets only be viewed and modified through the standard
1745 approval interface?  Changing this setting to 1 will redirect any attempt to
1746 use the normal ticket display and modify page for approval tickets.
1747
1748 For example, with this option set to 1 and an approval ticket #123:
1749
1750     /Ticket/Display.html?id=123
1751
1752 is redirected to
1753
1754     /Approval/Display.html?id=123
1755
1756 =back
1757
1758 =cut
1759
1760 Set($ForceApprovalsView, 0);
1761
1762 =head1 Extra security
1763
1764 =over 4
1765
1766 This is a list of extra security measures to enable that help keep your RT
1767 safe.  If you don't know what these mean, you should almost certainly leave the
1768 defaults alone.
1769
1770 =item C<$DisallowExecuteCode>
1771
1772 If set to a true value, the C<ExecuteCode> right will be removed from
1773 all users, B<including> the superuser.  This is intended for when RT is
1774 installed into a shared environment where even the superuser should not
1775 be allowed to run arbitrary Perl code on the server via scrips.
1776
1777 =cut
1778
1779 Set($DisallowExecuteCode, 0);
1780
1781 =item C<$Framebusting>
1782
1783 If set to a false value, framekiller javascript will be disabled and the
1784 X-Frame-Options: DENY header will be suppressed from all responses.
1785 This disables RT's clickjacking protection.
1786
1787 =cut
1788
1789 Set($Framebusting, 1);
1790
1791 =item C<$RestrictReferrer>
1792
1793 If set to a false value, the HTTP C<Referer> (sic) header will not be
1794 checked to ensure that requests come from RT's own domain.  As RT allows
1795 for GET requests to alter state, disabling this opens RT up to
1796 cross-site request forgery (CSRF) attacks.
1797
1798 =cut
1799
1800 Set($RestrictReferrer, 1);
1801
1802 =item C<$RestrictLoginReferrer>
1803
1804 If set to a false value, RT will allow the user to log in from any link
1805 or request, merely by passing in C<user> and C<pass> parameters; setting
1806 it to a true value forces all logins to come from the login box, so the
1807 user is aware that they are being logged in.  The default is off, for
1808 backwards compatability.
1809
1810 =cut
1811
1812 Set($RestrictLoginReferrer, 0);
1813
1814 =item C<$ReferrerWhitelist>
1815
1816 This is a list of hostname:port combinations that RT will treat as being
1817 part of RT's domain. This is particularly useful if you access RT as
1818 multiple hostnames or have an external auth system that needs to
1819 redirect back to RT once authentication is complete.
1820
1821  Set(@ReferrerWhitelist, qw(www.example.com:443  www3.example.com:80));
1822
1823 If the "RT has detected a possible cross-site request forgery" error is triggered
1824 by a host:port sent by your browser that you believe should be valid, you can copy
1825 the host:port from the error message into this list.
1826
1827 =cut
1828
1829 Set(@ReferrerWhitelist, qw());
1830
1831 =back
1832
1833
1834
1835 =head1 Authorization and user configuration
1836
1837 =over 4
1838
1839 =item C<$WebExternalAuth>
1840
1841 If C<$WebExternalAuth> is defined, RT will defer to the environment's
1842 REMOTE_USER variable.
1843
1844 =cut
1845
1846 Set($WebExternalAuth, undef);
1847
1848 =item C<$WebExternalAuthContinuous>
1849
1850 If C<$WebExternalAuthContinuous> is defined, RT will check for the
1851 REMOTE_USER on each access.  If you would prefer this to only happen
1852 once (at initial login) set this to a false value.  The default
1853 setting will help ensure that if your external authentication system
1854 deauthenticates a user, RT notices as soon as possible.
1855
1856 =cut
1857
1858 Set($WebExternalAuthContinuous, 1);
1859
1860 =item C<$WebFallbackToInternalAuth>
1861
1862 If C<$WebFallbackToInternalAuth> is defined, the user is allowed a
1863 chance of fallback to the login screen, even if REMOTE_USER failed.
1864
1865 =cut
1866
1867 Set($WebFallbackToInternalAuth, undef);
1868
1869 =item C<$WebExternalGecos>
1870
1871 C<$WebExternalGecos> means to match 'gecos' field as the user
1872 identity); useful with mod_auth_pwcheck and IIS Integrated Windows
1873 logon.
1874
1875 =cut
1876
1877 Set($WebExternalGecos, undef);
1878
1879 =item C<$WebExternalAuto>
1880
1881 C<$WebExternalAuto> will create users under the same name as
1882 REMOTE_USER upon login, if it's missing in the Users table.
1883
1884 =cut
1885
1886 Set($WebExternalAuto, undef);
1887
1888 =item C<$AutoCreate>
1889
1890 If C<$WebExternalAuto> is set to 1, C<$AutoCreate> will be passed to
1891 User's Create method.  Use it to set defaults, such as creating
1892 Unprivileged users with C<{ Privileged => 0 }> This must be a hashref.
1893
1894 =cut
1895
1896 Set($AutoCreate, undef);
1897
1898 =item C<$WebSessionClass>
1899
1900 C<$WebSessionClass> is the class you wish to use for managing sessions.
1901 It defaults to use your SQL database, except on Oracle, where it
1902 defaults to files on disk.
1903
1904 =cut
1905
1906 # Set($WebSessionClass, "Apache::Session::File");
1907
1908 =item C<$AutoLogoff>
1909
1910 By default, RT's user sessions persist until a user closes his or her
1911 browser. With the C<$AutoLogoff> option you can setup session lifetime
1912 in minutes. A user will be logged out if he or she doesn't send any
1913 requests to RT for the defined time.
1914
1915 =cut
1916
1917 Set($AutoLogoff, 0);
1918
1919 =item C<$LogoutRefresh>
1920
1921 The number of seconds to wait after logout before sending the user to
1922 the login page. By default, 1 second, though you may want to increase
1923 this if you display additional information on the logout page.
1924
1925 =cut
1926
1927 Set($LogoutRefresh, 1);
1928
1929 =item C<$WebSecureCookies>
1930
1931 By default, RT's session cookie isn't marked as "secure". Some web
1932 browsers will treat secure cookies more carefully than non-secure
1933 ones, being careful not to write them to disk, only sending them over
1934 an SSL secured connection, and so on. To enable this behavior, set
1935 C<$WebSecureCookies> to 1.  NOTE: You probably don't want to turn this
1936 on I<unless> users are only connecting via SSL encrypted HTTPS
1937 connections.
1938
1939 =cut
1940
1941 Set($WebSecureCookies, 0);
1942
1943 =item C<$WebHttpOnlyCookies>
1944
1945 Default RT's session cookie to not being directly accessible to
1946 javascript.  The content is still sent during regular and AJAX requests,
1947 and other cookies are unaffected, but the session-id is less
1948 programmatically accessible to javascript.  Turning this off should only
1949 be necessary in situations with odd client-side authentication
1950 requirements.
1951
1952 =cut
1953
1954 Set($WebHttpOnlyCookies, 1);
1955
1956 =item C<$MinimumPasswordLength>
1957
1958 C<$MinimumPasswordLength> defines the minimum length for user
1959 passwords. Setting it to 0 disables this check.
1960
1961 =cut
1962
1963 Set($MinimumPasswordLength, 5);
1964
1965 =back
1966
1967
1968 =head1 Internationalization
1969
1970 =over 4
1971
1972 =item C<@LexiconLanguages>
1973
1974 An array that contains languages supported by RT's
1975 internationalization interface.  Defaults to all *.po lexicons;
1976 setting it to C<qw(en ja)> will make RT bilingual instead of
1977 multilingual, but will save some memory.
1978
1979 =cut
1980
1981 Set(@LexiconLanguages, qw(*));
1982
1983 =item C<@EmailInputEncodings>
1984
1985 An array that contains default encodings used to guess which charset
1986 an attachment uses, if it does not specify one explicitly.  All
1987 options must be recognized by L<Encode::Guess>.  The first element may
1988 also be '*', which enables encoding detection using
1989 L<Encode::Detect::Detector>, if installed.
1990
1991 =cut
1992
1993 Set(@EmailInputEncodings, qw(utf-8 iso-8859-1 us-ascii));
1994
1995 =item C<$EmailOutputEncoding>
1996
1997 The charset for localized email.  Must be recognized by Encode.
1998
1999 =cut
2000
2001 Set($EmailOutputEncoding, "utf-8");
2002
2003 =back
2004
2005
2006
2007
2008
2009
2010
2011 =head1 Date and time handling
2012
2013 =over 4
2014
2015 =item C<$DateTimeFormat>
2016
2017 You can choose date and time format.  See the "Output formatters"
2018 section in perldoc F<lib/RT/Date.pm> for more options.  This option
2019 can be overridden by users in their preferences.
2020
2021 Some examples:
2022
2023 C<Set($DateTimeFormat, "LocalizedDateTime");>
2024 C<Set($DateTimeFormat, { Format => "ISO", Seconds => 0 });>
2025 C<Set($DateTimeFormat, "RFC2822");>
2026 C<Set($DateTimeFormat, { Format => "RFC2822", Seconds => 0, DayOfWeek => 0 });>
2027
2028 =cut
2029
2030 Set($DateTimeFormat, "DefaultFormat");
2031
2032 # Next two options are for Time::ParseDate
2033
2034 =item C<$DateDayBeforeMonth>
2035
2036 Set this to 1 if your local date convention looks like "dd/mm/yy"
2037 instead of "mm/dd/yy". Used only for parsing, not for displaying
2038 dates.
2039
2040 =cut
2041
2042 Set($DateDayBeforeMonth, 1);
2043
2044 =item C<$AmbiguousDayInPast>, C<$AmbiguousDayInFuture>
2045
2046 Should an unspecified day or year in a date refer to a future or a
2047 past value? For example, should a date of "Tuesday" default to mean
2048 the date for next Tuesday or last Tuesday? Should the date "March 1"
2049 default to the date for next March or last March?
2050
2051 Set C<$AmbiguousDayInPast> for the last date, or
2052 C<$AmbiguousDayInFuture> for the next date; the default is usually
2053 correct.  If both are set, C<$AmbiguousDayInPast> takes precedence.
2054
2055 =cut
2056
2057 Set($AmbiguousDayInPast, 0);
2058 Set($AmbiguousDayInFuture, 0);
2059
2060 =item C<$DefaultTimeUnitsToHours>
2061
2062 Use this to set the default units for time entry to hours instead of
2063 minutes.  Note that this only effects entry, not display.
2064
2065 =cut
2066
2067 Set($DefaultTimeUnitsToHours, 0);
2068
2069 =item C<$SimpleSearchIncludeResolved>
2070
2071 By default, the simple ticket search in the top bar excludes "resolved" tickets
2072 unless a status argument is specified.  Set this to a true value to include 
2073 them.
2074
2075 =cut
2076
2077 Set($SimpleSearchIncludeResolved, 0);
2078
2079 =back
2080
2081
2082
2083
2084 =head1 GnuPG integration
2085
2086 A full description of the (somewhat extensive) GnuPG integration can
2087 be found by running the command `perldoc L<RT::Crypt::GnuPG>` (or
2088 `perldoc lib/RT/Crypt/GnuPG.pm` from your RT install directory).
2089
2090 =over 4
2091
2092 =item C<%GnuPG>
2093
2094 Set C<OutgoingMessagesFormat> to 'inline' to use inline encryption and
2095 signatures instead of 'RFC' (GPG/MIME: RFC3156 and RFC1847) format.
2096
2097 If you want to allow people to encrypt attachments inside the DB then
2098 set C<AllowEncryptDataInDB> to 1.
2099
2100 Set C<RejectOnMissingPrivateKey> to false if you don't want to reject
2101 emails encrypted for key RT doesn't have and can not decrypt.
2102
2103 Set C<RejectOnBadData> to false if you don't want to reject letters
2104 with incorrect GnuPG data.
2105
2106 =cut
2107
2108 Set(%GnuPG,
2109     Enable => @RT_GPG@,
2110     OutgoingMessagesFormat => "RFC", # Inline
2111     AllowEncryptDataInDB   => 0,
2112
2113     RejectOnMissingPrivateKey => 1,
2114     RejectOnBadData           => 1,
2115 );
2116
2117 =item C<%GnuPGOptions>
2118
2119 Options to pass to the GnuPG program.
2120
2121 If you override this in your RT_SiteConfig, you should be sure to
2122 include a homedir setting.
2123
2124 Note that options with '-' character MUST be quoted.
2125
2126 =cut
2127
2128 Set(%GnuPGOptions,
2129     homedir => q{@RT_VAR_PATH@/data/gpg},
2130
2131 # URL of a keyserver
2132 #    keyserver => 'hkp://subkeys.pgp.net',
2133
2134 # enables the automatic retrieving of keys when encrypting
2135 #    'auto-key-locate' => 'keyserver',
2136
2137 # enables the automatic retrieving of keys when verifying signatures
2138 #    'auto-key-retrieve' => undef,
2139 );
2140
2141 =back
2142
2143
2144
2145 =head1 Lifecycles
2146
2147 =head2 Lifecycle definitions
2148
2149 Each lifecycle is a list of possible statuses split into three logic
2150 sets: B<initial>, B<active> and B<inactive>. Each status in a
2151 lifecycle must be unique. (Statuses may not be repeated across sets.)
2152 Each set may have any number of statuses.
2153
2154 For example:
2155
2156     default => {
2157         initial  => ['new'],
2158         active   => ['open', 'stalled'],
2159         inactive => ['resolved', 'rejected', 'deleted'],
2160         ...
2161     },
2162
2163 Status names can be from 1 to 64 ASCII characters.  Statuses are
2164 localized using RT's standard internationalization and localization
2165 system.
2166
2167 =over 4
2168
2169 =item initial
2170
2171 You can define multiple B<initial> statuses for tickets in a given
2172 lifecycle.
2173
2174 RT will automatically set its B<Started> date when you change a
2175 ticket's status from an B<initial> state to an B<active> or
2176 B<inactive> status.
2177
2178 =item active
2179
2180 B<Active> tickets are "currently in play" - they're things that are
2181 being worked on and not yet complete.
2182
2183 =item inactive
2184
2185 B<Inactive> tickets are typically in their "final resting state".
2186
2187 While you're free to implement a workflow that ignores that
2188 description, typically once a ticket enters an inactive state, it will
2189 never again enter an active state.
2190
2191 RT will automatically set the B<Resolved> date when a ticket's status
2192 is changed from an B<Initial> or B<Active> status to an B<Inactive>
2193 status.
2194
2195 B<deleted> is still a special status and protected by the
2196 B<DeleteTicket> right, unless you re-defined rights (read below). If
2197 you don't want to allow ticket deletion at any time simply don't
2198 include it in your lifecycle.
2199
2200 =back
2201
2202 Statuses in each set are ordered and listed in the UI in the defined
2203 order.
2204
2205 Changes between statuses are constrained by transition rules, as
2206 described below.
2207
2208 =head2 Default values
2209
2210 In some cases a default value is used to display in UI or in API when
2211 value is not provided. You can configure defaults using the following
2212 syntax:
2213
2214     default => {
2215         ...
2216         defaults => {
2217             on_create => 'new',
2218             on_resolve => 'resolved',
2219             ...
2220         },
2221     },
2222
2223 The following defaults are used.
2224
2225 =over 4
2226
2227 =item on_create
2228
2229 If you (or your code) doesn't specify a status when creating a ticket,
2230 RT will use the this status. See also L</Statuses available during
2231 ticket creation>.
2232
2233 =item on_merge
2234
2235 When tickets are merged, the status of the ticket that was merged
2236 away is forced to this value.  It should be one of inactive statuses;
2237 'resolved' or its equivalent is most probably the best candidate.
2238
2239 =item approved
2240
2241 When an approval is accepted, the status of depending tickets will
2242 be changed to this value.
2243
2244 =item denied
2245
2246 When an approval is denied, the status of depending tickets will
2247 be changed to this value.
2248
2249 =item reminder_on_open
2250
2251 When a reminder is opened, the status will be changed to this value.
2252
2253 =item reminder_on_resolve
2254
2255 When a reminder is resolved, the status will be changed to this value.
2256
2257 =back
2258
2259 =head2 Transitions between statuses and UI actions
2260
2261 A B<Transition> is a change of status from A to B. You should define
2262 all possible transitions in each lifecycle using the following format:
2263
2264     default => {
2265         ...
2266         transitions => {
2267             ''       => [qw(new open resolved)],
2268             new      => [qw(open resolved rejected deleted)],
2269             open     => [qw(stalled resolved rejected deleted)],
2270             stalled  => [qw(open)],
2271             resolved => [qw(open)],
2272             rejected => [qw(open)],
2273             deleted  => [qw(open)],
2274         },
2275         ...
2276     },
2277
2278 =head3 Statuses available during ticket creation
2279
2280 By default users can create tickets with any status, except
2281 deleted. If you want to restrict statuses available during creation
2282 then describe transition from '' (empty string), like in the example
2283 above.
2284
2285 =head3 Protecting status changes with rights
2286
2287 A transition or group of transitions can be protected by a specific
2288 right.  Additionally, you can name new right names, which will be added
2289 to the system to control that transition.  For example, if you wished to
2290 create a lesser right than ModifyTicket for rejecting tickets, you could
2291 write:
2292
2293     default => {
2294         ...
2295         rights => {
2296             '* -> deleted'  => 'DeleteTicket',
2297             '* -> rejected' => 'RejectTicket',
2298             '* -> *'        => 'ModifyTicket',
2299         },
2300         ...
2301     },
2302
2303 This would create a new C<RejectTicket> right in the system which you
2304 could assign to whatever groups you choose.
2305
2306 On the left hand side you can have the following variants:
2307
2308     '<from> -> <to>'
2309     '* -> <to>'
2310     '<from> -> *'
2311     '* -> *'
2312
2313 Valid transitions are listed in order of priority. If a user attempts
2314 to change a ticket's status from B<new> to B<open> then the lifecycle
2315 is checked for presence of an exact match, then for 'any to B<open>',
2316 'B<new> to any' and finally 'any to any'.
2317
2318 If you don't define any rights, or there is no match for a transition,
2319 RT will use the B<DeleteTicket> or B<ModifyTicket> as appropriate.
2320
2321 =head3 Labeling and defining actions
2322
2323 For each transition you can define an action that will be shown in the
2324 UI; each action annotated with a label and an update type.
2325
2326 Each action may provide a default update type, which can be
2327 B<Comment>, B<Respond>, or absent. For example, you may want your
2328 staff to write a reply to the end user when they change status from
2329 B<new> to B<open>, and thus set the update to B<Respond>.  Neither
2330 B<Comment> nor B<Respond> are mandatory, and user may leave the
2331 message empty, regardless of the update type.
2332
2333 This configuration can be used to accomplish what
2334 $ResolveDefaultUpdateType was used for in RT 3.8.
2335
2336 Use the following format to define labels and actions of transitions:
2337
2338     default => {
2339         ...
2340         actions => [
2341             'new -> open'     => { label => 'Open it', update => 'Respond' },
2342             'new -> resolved' => { label => 'Resolve', update => 'Comment' },
2343             'new -> rejected' => { label => 'Reject',  update => 'Respond' },
2344             'new -> deleted'  => { label => 'Delete' },
2345
2346             'open -> stalled'  => { label => 'Stall',   update => 'Comment' },
2347             'open -> resolved' => { label => 'Resolve', update => 'Comment' },
2348             'open -> rejected' => { label => 'Reject',  update => 'Respond' },
2349
2350             'stalled -> open'  => { label => 'Open it' },
2351             'resolved -> open' => { label => 'Re-open', update => 'Comment' },
2352             'rejected -> open' => { label => 'Re-open', update => 'Comment' },
2353             'deleted -> open'  => { label => 'Undelete' },
2354         ],
2355         ...
2356     },
2357
2358 In addition, you may define multiple actions for the same transition.
2359 Alternately, you may use '* -> x' to match more than one transition.
2360 For example:
2361
2362     default => {
2363         ...
2364         actions => [
2365             ...
2366             'new -> rejected' => { label => 'Reject', update => 'Respond' },
2367             'new -> rejected' => { label => 'Quick Reject' },
2368             ...
2369             '* -> deleted' => { label => 'Delete' },
2370             ...
2371         ],
2372         ...
2373     },
2374
2375 =head2 Moving tickets between queues with different lifecycles
2376
2377 Unless there is an explicit mapping between statuses in two different
2378 lifecycles, you can not move tickets between queues with these
2379 lifecycles.  This is true even if the different lifecycles use the exact
2380 same set of statuses.  Such a mapping is defined as follows:
2381
2382     __maps__ => {
2383         'from lifecycle -> to lifecycle' => {
2384             'status in left lifecycle' => 'status in right lifecycle',
2385             ...
2386         },
2387         ...
2388     },
2389
2390 =cut
2391
2392 Set(%Lifecycles,
2393     default => {
2394         initial         => [ 'new' ],
2395         active          => [ 'open', 'stalled' ],
2396         inactive        => [ 'resolved', 'rejected', 'deleted' ],
2397
2398         defaults => {
2399             on_create => 'new',
2400             on_merge  => 'resolved',
2401             approved  => 'open',
2402             denied    => 'rejected',
2403             reminder_on_open     => 'open',
2404             reminder_on_resolve  => 'resolved',
2405         },
2406
2407         transitions => {
2408             ''       => [qw(new open resolved)],
2409
2410             # from   => [ to list ],
2411             new      => [qw(open stalled resolved rejected deleted)],
2412             open     => [qw(new stalled resolved rejected deleted)],
2413             stalled  => [qw(new open rejected resolved deleted)],
2414             resolved => [qw(new open stalled rejected deleted)],
2415             rejected => [qw(new open stalled resolved deleted)],
2416             deleted  => [qw(new open stalled rejected resolved)],
2417         },
2418         rights => {
2419             '* -> deleted'  => 'DeleteTicket',
2420             '* -> *'        => 'ModifyTicket',
2421         },
2422         actions => [
2423             'new -> open'      => {
2424                 label  => 'Open It', # loc
2425                 update => 'Respond',
2426             },
2427             'new -> resolved'  => {
2428                 label  => 'Resolve', # loc
2429                 update => 'Comment',
2430             },
2431             'new -> rejected'  => {
2432                 label  => 'Reject', # loc
2433                 update => 'Respond',
2434             },
2435             'new -> deleted'   => {
2436                 label  => 'Delete', # loc
2437             },
2438
2439             'open -> stalled'  => {
2440                 label  => 'Stall', # loc
2441                 update => 'Comment',
2442             },
2443             'open -> resolved' => {
2444                 label  => 'Resolve', # loc
2445                 update => 'Comment',
2446             },
2447             'open -> rejected' => {
2448                 label  => 'Reject', # loc
2449                 update => 'Respond',
2450             },
2451
2452             'stalled -> open'  => {
2453                 label  => 'Open It', # loc
2454             },
2455             'resolved -> open' => {
2456                 label  => 'Re-open', # loc
2457                 update => 'Comment',
2458             },
2459             'rejected -> open' => {
2460                 label  => 'Re-open', # loc
2461                 update => 'Comment',
2462             },
2463             'deleted -> open'  => {
2464                 label  => 'Undelete', # loc
2465             },
2466         ],
2467     },
2468 # don't change lifecyle of the approvals, they are not capable to deal with
2469 # custom statuses
2470     approvals => {
2471         initial         => [ 'new' ],
2472         active          => [ 'open', 'stalled' ],
2473         inactive        => [ 'resolved', 'rejected', 'deleted' ],
2474
2475         defaults => {
2476             on_create => 'new',
2477             on_merge => 'resolved',
2478             reminder_on_open     => 'open',
2479             reminder_on_resolve  => 'resolved',
2480         },
2481
2482         transitions => {
2483             ''       => [qw(new open resolved)],
2484
2485             # from   => [ to list ],
2486             new      => [qw(open stalled resolved rejected deleted)],
2487             open     => [qw(new stalled resolved rejected deleted)],
2488             stalled  => [qw(new open rejected resolved deleted)],
2489             resolved => [qw(new open stalled rejected deleted)],
2490             rejected => [qw(new open stalled resolved deleted)],
2491             deleted  => [qw(new open stalled rejected resolved)],
2492         },
2493         rights => {
2494             '* -> deleted'  => 'DeleteTicket',
2495             '* -> rejected' => 'ModifyTicket',
2496             '* -> *'        => 'ModifyTicket',
2497         },
2498         actions => [
2499             'new -> open'      => {
2500                 label  => 'Open It', # loc
2501                 update => 'Respond',
2502             },
2503             'new -> resolved'  => {
2504                 label  => 'Resolve', # loc
2505                 update => 'Comment',
2506             },
2507             'new -> rejected'  => {
2508                 label  => 'Reject', # loc
2509                 update => 'Respond',
2510             },
2511             'new -> deleted'   => {
2512                 label  => 'Delete', # loc
2513             },
2514
2515             'open -> stalled'  => {
2516                 label  => 'Stall', # loc
2517                 update => 'Comment',
2518             },
2519             'open -> resolved' => {
2520                 label  => 'Resolve', # loc
2521                 update => 'Comment',
2522             },
2523             'open -> rejected' => {
2524                 label  => 'Reject', # loc
2525                 update => 'Respond',
2526             },
2527
2528             'stalled -> open'  => {
2529                 label  => 'Open It', # loc
2530             },
2531             'resolved -> open' => {
2532                 label  => 'Re-open', # loc
2533                 update => 'Comment',
2534             },
2535             'rejected -> open' => {
2536                 label  => 'Re-open', # loc
2537                 update => 'Comment',
2538             },
2539             'deleted -> open'  => {
2540                 label  => 'Undelete', # loc
2541             },
2542         ],
2543     },
2544 );
2545
2546
2547
2548
2549
2550 =head1 Administrative interface
2551
2552 =over 4
2553
2554 =item C<$ShowRTPortal>
2555
2556 RT can show administrators a feed of recent RT releases and other
2557 related announcements and information from Best Practical on the top
2558 level Configuration page.  This feature helps you stay up to date on
2559 RT security announcements and version updates.
2560
2561 RT provides this feature using an "iframe" on C</Admin/index.html>
2562 which asks the administrator's browser to show an inline page from
2563 Best Practical's website.
2564
2565 If you'd rather not make this feature available to your
2566 administrators, set C<$ShowRTPortal> to a false value.
2567
2568 =cut
2569
2570 Set($ShowRTPortal, 1);
2571
2572 =item C<%AdminSearchResultFormat>
2573
2574 In the admin interface, format strings similar to tickets result
2575 formats are used. Use C<%AdminSearchResultFormat> to define the format
2576 strings used in the admin interface on a per-RT-class basis.
2577
2578 =cut
2579
2580 Set(%AdminSearchResultFormat,
2581     Queues =>
2582         q{'<a href="__WebPath__/Admin/Queues/Modify.html?id=__id__">__id__</a>/TITLE:#'}
2583         .q{,'<a href="__WebPath__/Admin/Queues/Modify.html?id=__id__">__Name__</a>/TITLE:Name'}
2584         .q{,__Description__,__Address__,__Priority__,__DefaultDueIn__,'__Disabled__,__Lifecycle__},
2585
2586     Groups =>
2587         q{'<a href="__WebPath__/Admin/Groups/Modify.html?id=__id__">__id__</a>/TITLE:#'}
2588         .q{,'<a href="__WebPath__/Admin/Groups/Modify.html?id=__id__">__Name__</a>/TITLE:Name'}
2589         .q{,'__Description__'},
2590
2591     Users =>
2592         q{'<a href="__WebPath__/Admin/Users/Modify.html?id=__id__">__id__</a>/TITLE:#'}
2593         .q{,'<a href="__WebPath__/Admin/Users/Modify.html?id=__id__">__Name__</a>/TITLE:Name'}
2594         .q{,__RealName__, __EmailAddress__},
2595
2596     CustomFields =>
2597         q{'<a href="__WebPath__/Admin/CustomFields/Modify.html?id=__id__">__id__</a>/TITLE:#'}
2598         .q{,'<a href="__WebPath__/Admin/CustomFields/Modify.html?id=__id__">__Name__</a>/TITLE:Name'}
2599         .q{,__AppliedTo__, __FriendlyType__, __FriendlyPattern__},
2600
2601     Scrips =>
2602         q{'<a href="__WebPath__/Admin/Queues/Scrip.html?id=__id__&Queue=__QueueId__">__id__</a>/TITLE:#'}
2603         .q{,'<a href="__WebPath__/Admin/Queues/Scrip.html?id=__id__&Queue=__QueueId__">__Description__</a>/TITLE:Description'}
2604         .q{,__Stage__, __Condition__, __Action__, __Template__},
2605
2606     GlobalScrips =>
2607         q{'<a href="__WebPath__/Admin/Global/Scrip.html?id=__id__">__id__</a>/TITLE:#'}
2608         .q{,'<a href="__WebPath__/Admin/Global/Scrip.html?id=__id__">__Description__</a>/TITLE:Description'}
2609         .q{,__Stage__, __Condition__, __Action__, __Template__},
2610
2611     Templates =>
2612         q{'<a href="__WebPath__/__WebRequestPathDir__/Template.html?Queue=__QueueId__&Template=__id__">__id__</a>/TITLE:#'}
2613         .q{,'<a href="__WebPath__/__WebRequestPathDir__/Template.html?Queue=__QueueId__&Template=__id__">__Name__</a>/TITLE:Name'}
2614         .q{,'__Description__'},
2615     Classes =>
2616         q{ '<a href="__WebPath__/Admin/Articles/Classes/Modify.html?id=__id__">__id__</a>/TITLE:#'}
2617         .q{,'<a href="__WebPath__/Admin/Articles/Classes/Modify.html?id=__id__">__Name__</a>/TITLE:Name'}
2618         .q{,__Description__},
2619 );
2620
2621 =back
2622
2623
2624
2625
2626 =head1 Development options
2627
2628 =over 4
2629
2630 =item C<$DevelMode>
2631
2632 RT comes with a "Development mode" setting.  This setting, as a
2633 convenience for developers, turns on several of development options
2634 that you most likely don't want in production:
2635
2636 =over 4
2637
2638 =item *
2639
2640 Disables CSS and JS minification and concatenation.  Both CSS and JS
2641 will be instead be served as a number of individual smaller files,
2642 unchanged from how they are stored on disk.
2643
2644 =item *
2645
2646 Uses L<Module::Refresh> to reload changed Perl modules on each
2647 request.
2648
2649 =item *
2650
2651 Turns off Mason's C<static_source> directive; this causes Mason to
2652 reload template files which have been modified on disk.
2653
2654 =item *
2655
2656 Turns on Mason's HTML C<error_format>; this renders compilation errors
2657 to the browser, along with a full stack trace.  It is possible for
2658 stack traces to reveal sensitive information such as passwords or
2659 ticket content.
2660
2661 =item *
2662
2663 Turns off caching of callbacks; this enables additional callbacks to
2664 be added while the server is running.
2665
2666 =back
2667
2668 =cut
2669
2670 Set($DevelMode, "@RT_DEVEL_MODE@");
2671
2672
2673 =item C<$RecordBaseClass>
2674
2675 What abstract base class should RT use for its records. You should
2676 probably never change this.
2677
2678 Valid values are C<DBIx::SearchBuilder::Record> or
2679 C<DBIx::SearchBuilder::Record::Cachable>
2680
2681 =cut
2682
2683 Set($RecordBaseClass, "DBIx::SearchBuilder::Record::Cachable");
2684
2685
2686 =item C<@MasonParameters>
2687
2688 C<@MasonParameters> is the list of parameters for the constructor of
2689 HTML::Mason's Apache or CGI Handler.  This is normally only useful for
2690 debugging, e.g. profiling individual components with:
2691
2692     use MasonX::Profiler; # available on CPAN
2693     Set(@MasonParameters, (preamble => 'my $p = MasonX::Profiler->new($m, $r);'));
2694
2695 =cut
2696
2697 Set(@MasonParameters, ());
2698
2699 =item C<$StatementLog>
2700
2701 RT has rudimentary SQL statement logging support; simply set
2702 C<$StatementLog> to be the level that you wish SQL statements to be
2703 logged at.
2704
2705 Enabling this option will also expose the SQL Queries page in the
2706 Configuration -> Tools menu for SuperUsers.
2707
2708 =cut
2709
2710 Set($StatementLog, undef);
2711
2712 =back
2713
2714
2715
2716
2717 =head1 Deprecated options
2718
2719 =over 4
2720
2721 =item C<$LinkTransactionsRun1Scrip>
2722
2723 RT-3.4 backward compatibility setting. Add/Delete Link used to record
2724 one transaction and run one scrip. Set this value to 1 if you want
2725 only one of the link transactions to have scrips run.
2726
2727 =cut
2728
2729 Set($LinkTransactionsRun1Scrip, 0);
2730
2731 =item C<$ResolveDefaultUpdateType>
2732
2733 This option has been deprecated.  You can configure this site-wide
2734 with L</Lifecycles> (see L</Labeling and defining actions>).
2735
2736 =cut
2737
2738 1;