RT NonCustomerEmailRegexp option, #15847
[freeside.git] / rt / etc / RT_Config.pm
1
2 package RT;
3
4 =head1 NAME
5
6 RT::Config
7
8 =for testing
9
10 use RT::Config;
11
12 =cut
13
14 =head1 WARNING
15
16 NEVER EDIT RT_Config.pm.
17
18 Instead, copy any sections you want to change to F<RT_SiteConfig.pm> and edit them there.
19
20 =cut
21
22 =head1 Base Configuration
23
24 =over 4
25
26 =item C<$rtname>
27
28 C<$rtname> is the string that RT will look for in mail messages to
29 figure out what ticket a new piece of mail belongs to.
30
31 Your domain name is recommended, so as not to pollute the namespace.
32 once you start using a given tag, you should probably never change it.
33 (otherwise, mail for existing tickets won't get put in the right place)
34
35 =cut
36
37 Set($rtname , "example.com");
38
39
40 =item C<$EmailSubjectTagRegex>
41
42 This regexp controls what subject tags RT recognizes as its own.
43 If you're not dealing with historical C<$rtname> values, you'll likely
44 never have to enable this feature.
45
46 Be VERY CAREFUL with it. Note that it overrides C<$rtname> for subject
47 token matching and that you should use only "non-capturing" parenthesis
48 grouping. For example:
49
50 C<Set($EmailSubjectTagRegex, qr/(?:example.com|example.org)/i );>
51
52 and NOT
53
54 C<Set($EmailSubjectTagRegex, qr/(example.com|example.org)/i );>
55
56 This setting would make RT behave exactly as it does without the 
57 setting enabled.
58
59 =cut
60
61 #Set($EmailSubjectTagRegex, qr/\Q$rtname\E/i );
62
63
64
65 =item C<$Organization>
66
67 You should set this to your organization's DNS domain. For example,
68 I<fsck.com> or I<asylum.arkham.ma.us>. It's used by the linking interface to
69 guarantee that ticket URIs are unique and easy to construct.
70
71 =cut
72
73 Set($Organization , "example.com");
74
75 =item C<$MinimumPasswordLength>
76
77 C<$MinimumPasswordLength> defines the minimum length for user
78 passwords. Setting it to 0 disables this check.
79
80 =cut
81
82 Set($MinimumPasswordLength , "5");
83
84 =item C<$Timezone>
85
86 C<$Timezone> is used to convert times entered by users into GMT and back again
87 It should be set to a timezone recognized by your local unix box.
88
89 =cut
90
91 Set($Timezone , 'US/Eastern');
92
93 =back
94
95 =head1 Database Configuration
96
97 =over 4
98
99 =item C<$DatabaseType>
100
101 Database driver being used; case matters.
102
103 Valid types are "mysql", "Oracle" and "Pg"
104
105 =cut
106
107 Set($DatabaseType , 'Pg');
108
109 =item C<$DatabaseHost>, C<$DatabaseRTHost>
110
111 The domain name of your database server.
112
113 If you're running mysql and it's on localhost,
114 leave it blank for enhanced performance
115
116 =cut
117
118 Set($DatabaseHost   , 'localhost');
119 Set($DatabaseRTHost , 'localhost');
120
121 =item C<$DatabasePort>
122
123 The port that your database server is running on.  Ignored unless it's
124 a positive integer. It's usually safe to leave this blank
125
126 =cut
127
128 Set($DatabasePort , '');
129
130 =item C<$DatabaseUser>
131
132 The name of the database user (inside the database)
133
134 =cut
135
136 Set($DatabaseUser , 'freeside');
137
138 =item C<$DatabasePassword>
139
140 Password the C<$DatabaseUser> should use to access the database
141
142 =cut
143
144 Set($DatabasePassword , '');
145
146 =item C<$DatabaseName>
147
148 The name of the RT's database on your database server. For Oracle
149 it's SID, DB objects are created in L<$DatabaseUser>'s schema.
150
151 =cut
152
153 Set($DatabaseName , 'freeside');
154
155 =item C<$DatabaseRequireSSL>
156
157 If you're using Postgres and have compiled in SSL support,
158 set C<$DatabaseRequireSSL> to 1 to turn on SSL communication
159
160 =cut
161
162 Set($DatabaseRequireSSL , undef);
163
164 =item C<$UseSQLForACLChecks>
165
166 In RT for ages ACL are checked after search what in some situtations
167 result in empty search pages and wrong count of tickets.
168
169 Set C<$UseSQLForACLChecks> to 1 to use SQL and get rid of these problems.
170
171 However, this option is beta. In some cases it result in performance
172 improvements, but some setups can not handle it.
173
174 =cut
175
176 Set($UseSQLForACLChecks, undef);
177
178 =item C<$TicketsItemMapSize>
179
180 In RT at display page of a ticket and there is the current search,
181 then links for first, next, previous and last ticket are shown in
182 the menu.
183
184 To build full map RT has to fetch full result set out of DB what can
185 eat lots of resourses. Using this option it's possible to limit number
186 of tickets fetched.
187
188 Set C<$TicketsItemMapSize> to number of tickets you want RT to look
189 at to build the map. If full result set is bigger than that number
190 then there would be no 'last' link in the menu.
191
192 Set this to zero to return back to old behaviour.
193
194 =cut
195
196 Set($TicketsItemMapSize, 1000);
197
198 =back
199
200 =head1 Incoming Mail Gateway Configuration
201
202 =over 4
203
204 =item C<$OwnerEmail>
205
206 C<$OwnerEmail> is the address of a human who manages RT. RT will send
207 errors generated by the mail gateway to this address.  This address
208 should _not_ be an address that's managed by your RT instance.
209
210 =cut
211
212 Set($OwnerEmail , 'root');
213
214 =item C<$LoopsToRTOwner>
215
216 If C<$LoopsToRTOwner> is defined, RT will send mail that it believes
217 might be a loop to C<$OwnerEmail>
218
219 =cut
220
221 Set($LoopsToRTOwner , 1);
222
223 =item C<$StoreLoops>
224
225 If C<$StoreLoops> is defined, RT will record messages that it believes
226 to be part of mail loops.
227
228 As it does this, it will try to be careful not to send mail to the
229 sender of these messages
230
231 =cut
232
233 Set($StoreLoops , undef);
234
235 =item C<$MaxAttachmentSize>
236
237 C<$MaxAttachmentSize> sets the maximum size (in bytes) of attachments stored
238 in the database.
239
240 For mysql and oracle, we set this size at 10 megabytes.
241 If you're running a postgres version earlier than 7.1, you will need
242 to drop this to 8192. (8k)
243
244 =cut
245
246
247 Set($MaxAttachmentSize , 10000000);
248
249 =item C<$TruncateLongAttachments>
250
251 C<$TruncateLongAttachments>: if this is set to a non-undef value,
252 RT will truncate attachments longer than C<$MaxAttachmentSize>.
253
254 =cut
255
256 Set($TruncateLongAttachments , undef);
257
258 =item C<$DropLongAttachments>
259
260 C<$DropLongAttachments>: if this is set to a non-undef value,
261 RT will silently drop attachments longer than C<MaxAttachmentSize>.
262
263 =cut
264
265 Set($DropLongAttachments , undef);
266
267 =item C<$ParseNewMessageForTicketCcs>
268
269 If C<$ParseNewMessageForTicketCcs> is true, RT will attempt to divine
270 Ticket 'Cc' watchers from the To and Cc lines of incoming messages
271 Be forewarned that if you have _any_ addresses which forward mail to
272 RT automatically and you enable this option without modifying
273 C<$RTAddressRegexp> below, you will get yourself into a heap of trouble.
274
275 =cut
276
277 Set($ParseNewMessageForTicketCcs , undef);
278
279 =item C<$RTAddressRegexp> 
280
281 C<$RTAddressRegexp> is used to make sure RT doesn't add itself as a ticket CC if
282 the setting above is enabled.  It is important that you set this to a 
283 regular expression that matches all addresses used by your RT.  This lets RT
284 avoid sending mail to itself.  It will also hide RT addresses from the list of 
285 "One-time Cc" and Bcc lists on ticket reply.
286
287 If you have a number of addresses configured in your RT database already, you
288 can generate a naive first pass regexp by using
289
290     perl etc/upgrade/generate-rtaddressregexp
291
292 =cut
293
294 Set($RTAddressRegexp , undef);
295
296 =item C<$IgnoreCcRegexp>
297
298 C<$IgnoreCcRegexp> is a regexp to exclude addresses from automatic addition 
299 to the Cc list.  Use this for addresses that are I<not> received by RT but
300 are sometimes added to Cc lists by mistake.  Unlike C<$RTAddressRegexp>, 
301 these addresses can still receive email from RT otherwise.
302
303 =cut
304
305 Set($IgnoreCcRegexp, undef);
306
307 =item C<$CanonicalizeEmailAddressMatch>, C<$CanonicalizeEmailAddressReplace>
308
309 RT provides functionality which allows the system to rewrite
310 incoming email addresses.  In its simplest form,
311 you can substitute the value in $<CanonicalizeEmailAddressReplace>
312 for the value in $<CanonicalizeEmailAddressMatch>
313 (These values are passed to the $<CanonicalizeEmailAddress> subroutine in
314  F<RT/User.pm>)
315
316 By default, that routine performs a C<s/$Match/$Replace/gi> on any address
317 passed to it.
318
319 =cut
320
321 #Set($CanonicalizeEmailAddressMatch , '@subdomain\.example\.com$');
322 #Set($CanonicalizeEmailAddressReplace , '@example.com');
323
324 =item C<$CanonicalizeEmailAddressMatch>
325
326 Set this to true and the create new user page will use the values that you
327 enter in the form but use the function CanonicalizeUserInfo in
328 F<RT/User_Local.pm>
329
330 =cut
331
332 Set($CanonicalizeOnCreate, 0);
333
334 =item C<$ValidateUserEmailAddresses>
335
336 If C<$ValidateUserEmailAddresses> is true, RT will refuse to create users with
337 an invalid email address (as specified in RFC 2822) or with an email address
338 made of multiple email adresses.
339
340 =cut
341
342 Set($ValidateUserEmailAddresses, undef);
343
344 =item C<$NonCustomerEmailRegexp>
345
346 Normally, when a ticket is linked to a customer, any requestors on that
347 ticket that didn't previously have customer memberships are linked to 
348 the customer also.  C<$NonCustomerEmailRegexp> is a regexp for email 
349 addresses that should I<not> automatically be linked to a customer in 
350 this way.
351
352 =cut
353
354 Set($NonCustomerEmailRegexp, undef);
355
356 =item C<@MailPlugins>
357
358 C<@MailPlugins> is a list of auth plugins for L<RT::Interface::Email>
359 to use; see L<rt-mailgate>
360
361 =cut
362
363 =item C<$UnsafeEmailCommands>
364
365 C<$UnsafeEmailCommands>, if set to true, enables 'take' and 'resolve'
366 as possible actions via the mail gateway.  As its name implies, this
367 is very unsafe, as it allows email with a forged sender to possibly
368 resolve arbitrary tickets!
369
370 =cut
371
372 =item C<$ExtractSubjectTagMatch>, C<$ExtractSubjectTagNoMatch>
373
374 The default "extract remote tracking tags" scrip settings; these
375 detect when your RT is talking to another RT, and adjusts the
376 subject accordingly.
377
378 =cut
379
380 Set($ExtractSubjectTagMatch, qr/\[.+? #\d+\]/);
381 Set($ExtractSubjectTagNoMatch, ( ${RT::EmailSubjectTagRegex}
382        ? qr/\[(?:${RT::EmailSubjectTagRegex}) #\d+\]/
383        : qr/\[\Q$RT::rtname\E #\d+\]/));
384
385 =back
386
387 =head1 Outgoing Mail Configuration
388
389 =over 4
390
391 =item C<$MailCommand>
392
393 C<$MailCommand> defines which method RT will use to try to send mail.
394 We know that 'sendmailpipe' works fairly well.  If 'sendmailpipe'
395 doesn't work well for you, try 'sendmail'.  Other options are 'smtp'
396 or 'qmail'.
397
398 Note that you should remove the '-t' from C<$SendmailArguments>
399 if you use 'sendmail' rather than 'sendmailpipe'
400
401 For testing purposes, or to simply disable sending mail out into the world, you
402 can set C<$MailCommand> to 'testfile' which writes all mail to a temporary
403 file.  RT will log the location of the temporary file so you can extract mail
404 from it afterwards.
405
406 =cut
407
408 Set($MailCommand , 'sendmailpipe');
409
410 =item C<$SetOutgoingMailFrom>
411
412 C<$SetOutgoingMailFrom> tells RT to set the sender envelope with the correspond
413 mail address of the ticket's queue.
414
415 Warning: If you use this setting, bounced mails will appear to be incoming
416 mail to the system, thus creating new tickets.
417
418 =cut
419
420 Set($SetOutgoingMailFrom, 0);
421
422 =item C<$OverrideOutgoingMailFrom>
423
424 C<$OverrideOutgoingMailFrom> is used for overwriting the Correspond
425 address of the queue as it is handed to sendmail -f. This helps force
426 the From_ header away from www-data or other email addresses that show
427 up in the "Sent by" line in Outlook.
428
429 The option is a hash reference of queue name to email address.
430
431 If there is no ticket involved, then the value of the C<Default> key will be
432 used.
433
434 =cut
435
436 Set($OverrideOutgoingMailFrom, {
437 #    'Default' => 'admin@rt.example.com',
438 #    'General' => 'general@rt.example.com',
439 });
440
441 =back
442
443 =item C<$DefaultMailPrecedence>
444
445 C<$DefaultMailPrecedence> is used to control the default
446 Precedence level of outgoing mail where none is specified.
447 By default it is C<bulk>, but if you only send mail to
448 your staff, you may wish to change it.
449
450 Note that you can set the precedence of individual templates
451 by including an explicit Precedence header.
452
453 If you set this value to C<undef> then we do not set a default
454 Precedence header to outgoing mail. However, if there already is a
455 Precedence header it will be preserved.
456
457 =cut
458
459 Set($DefaultMailPrecedence, 'bulk');
460
461 =back
462
463 =item C<$DefaultErrorMailPrecedence>
464
465 C<$DefaultErrorMailPrecedence> is used to control the default
466 Precedence level of outgoing mail that indicates some kind of
467 error condition. By default it is C<bulk>, but if you only send
468 mail to your staff, you may wish to change it.
469
470 If you set this value to C<undef> then we do not add a Precedence
471 header to error mail.
472
473 =cut
474
475 Set($DefaultErrorMailPrecedence, 'bulk');
476
477 =back
478
479 =item C<$UseOriginatorHeader>
480
481 C<$UseOriginatorHeader> is used to control the insertion of an
482 RT-Originator Header in every outgoing mail, containing the
483 mail address of the transaction creator.
484
485 =cut
486
487 Set($UseOriginatorHeader, 1);
488
489 =back
490
491 =head1 Sendmail Configuration
492
493 These options only take effect if C<$MailCommand> is 'sendmail' or
494 'sendmailpipe'
495
496 =over 4
497
498 =item C<$SendmailArguments> 
499
500 C<$SendmailArguments> defines what flags to pass to C<$SendmailPath>
501 If you picked 'sendmailpipe', you MUST add a -t flag to C<$SendmailArguments>
502 These options are good for most sendmail wrappers and workalikes
503
504 These arguments are good for sendmail brand sendmail 8 and newer
505 C<Set($SendmailArguments,"-oi -t -ODeliveryMode=b -OErrorMode=m");>
506
507 =cut
508
509 Set($SendmailArguments , "-oi -t");
510
511
512 =item C<$SendmailBounceArguments>
513
514 C<$SendmailBounceArguments> defines what flags to pass to C<$Sendmail>
515 assuming RT needs to send an error (ie. bounce).
516
517 =cut
518
519 Set($SendmailBounceArguments , '-f "<>"');
520
521 =item C<$SendmailPath>
522
523 If you selected 'sendmailpipe' above, you MUST specify the path to
524 your sendmail binary in C<$SendmailPath>.
525
526 =cut
527
528 Set($SendmailPath , "/usr/sbin/sendmail");
529
530
531 =back
532
533 =head1 SMTP Configuration
534
535 These options only take effect if C<$MailCommand> is 'smtp'
536
537 =over 4
538
539 =item C<$SMTPServer>
540
541 C<$SMTPServer> should be set to the hostname of the SMTP server to use
542
543 =cut
544
545 Set($SMTPServer, undef);
546
547 =item C<$SMTPFrom>
548
549 C<$SMTPFrom> should be set to the 'From' address to use, if not the
550 email's 'From'
551
552 =cut
553
554 Set($SMTPFrom, undef);
555
556 =item C<$SMTPDebug> 
557
558 C<$SMTPDebug> should be set to true to debug SMTP mail sending
559
560 =cut
561
562 Set($SMTPDebug, 0);
563
564 =back
565
566 =head1 Other Mailer Configuration
567
568 =over 4
569
570 =item C<@MailParams>
571
572 C<@MailParams> defines a list of options passed to $MailCommand if it
573 is not 'sendmailpipe', 'sendmail', or 'smtp'
574
575 =cut
576
577 Set(@MailParams, ());
578
579 =item C<$CorrespondAddress>, C<$CommentAddress>
580
581 RT is designed such that any mail which already has a ticket-id associated
582 with it will get to the right place automatically.
583
584 C<$CorrespondAddress> and C<$CommentAddress> are the default addresses
585 that will be listed in From: and Reply-To: headers of correspondence
586 and comment mail tracked by RT, unless overridden by a queue-specific
587 address.
588
589 =cut
590
591 Set($CorrespondAddress , '');
592
593 Set($CommentAddress , '');
594
595 =item C<$DashboardAddress>
596
597 The email address from which RT will send dashboards. If none is set, then
598 C<$OwnerEmail> will be used.
599
600 =cut
601
602 Set($DashboardAddress, '');
603
604 =item C<$UseFriendlyFromLine>
605
606 By default, RT sets the outgoing mail's "From:" header to
607 "SenderName via RT".  Setting C<$UseFriendlyFromLine> to 0 disables it.
608
609 =cut
610
611 Set($UseFriendlyFromLine, 1);
612
613 =item C<$FriendlyFromLineFormat>
614
615 C<sprintf()> format of the friendly 'From:' header; its arguments
616 are SenderName and SenderEmailAddress.
617
618 =cut
619
620 Set($FriendlyFromLineFormat, "\"%s via RT\" <%s>");
621
622 =item C<$UseFriendlyToLine>
623
624 RT can optionally set a "Friendly" 'To:' header when sending messages to
625 Ccs or AdminCcs (rather than having a blank 'To:' header.
626
627 This feature DOES NOT WORK WITH SENDMAIL[tm] BRAND SENDMAIL
628 If you are using sendmail, rather than postfix, qmail, exim or some other MTA,
629 you _must_ disable this option.
630
631 =cut
632
633 Set($UseFriendlyToLine, 0);
634
635 =item C<$FriendlyToLineFormat>
636
637 C<sprintf()> format of the friendly 'To:' header; its arguments
638 are WatcherType and TicketId.
639
640 =cut
641
642 Set($FriendlyToLineFormat, "\"%s of ". RT->Config->Get('rtname') ." Ticket #%s\":;");
643
644 =item C<$NotifyActor>
645
646 By default, RT doesn't notify the person who performs an update, as they
647 already know what they've done. If you'd like to change this behaviour,
648 Set C<$NotifyActor> to 1
649
650 =cut
651
652 Set($NotifyActor, 0);
653
654 =item C<$RecordOutgoingEmail>
655
656 By default, RT records each message it sends out to its own internal database.
657 To change this behavior, set C<$RecordOutgoingEmail> to 0 
658
659 =cut
660
661 Set($RecordOutgoingEmail, 1);
662
663 =item C<$VERPPrefix>, C<$VERPPrefix>
664
665 VERP support (http://cr.yp.to/proto/verp.txt)
666
667 uncomment the following two directives to generate envelope senders
668 of the form C<${VERPPrefix}${originaladdress}@${VERPDomain}>
669 (i.e. rt-jesse=fsck.com@rt.example.com ).
670
671 This currently only works with sendmail and sendmailppie.
672
673 =cut
674
675 # Set($VERPPrefix, 'rt-');
676 # Set($VERPDomain, $RT::Organization);
677
678
679 =item C<$ForwardFromUser>
680
681 By default, RT forwards a message using queue's address and adds RT's tag into
682 subject of the outgoing message, so recipients' replies go into RT as correspondents.
683
684 To change this behavior, set C<$ForwardFromUser> to true value and RT will use
685 address of the current user and leave subject without RT's tag.
686
687 =cut
688
689 Set($ForwardFromUser, 0);
690
691 =item C<$ShowBccHeader>
692
693 By default RT hides from the web UI information about blind copies user sent on
694 reply or comment.
695
696 To change this set the following option to true value.
697
698 =cut
699
700 Set($ShowBccHeader, 0);
701
702 =item C<$DashboardSubject>
703
704 Lets you set the subject of dashboards. Arguments are the frequency (Daily,
705 Weekly, Monthly) of the dashboard and the dashboard's name. [_1] for the name
706 of the dashboard.
707
708 =cut
709
710 Set($DashboardSubject, '%s Dashboard: %s');
711
712 =back
713
714 =head1 GnuPG Configuration
715
716 A full description of the (somewhat extensive) GnuPG integration can be found 
717 by running the command `perldoc L<RT::Crypt::GnuPG>`  (or `perldoc
718         lib/RT/Crypt/GnuPG.pm` from your RT install directory).
719
720 =over 4
721
722 =item C<%GnuPG>
723
724 Set C<OutgoingMessagesFormat> to 'inline' to use inline encryption and
725 signatures instead of 'RFC' (GPG/MIME: RFC3156 and RFC1847) format.
726
727 If you want to allow people to encrypt attachments inside the DB then
728 set C<AllowEncryptDataInDB> to true
729
730 Set C<RejectOnMissingPrivateKey> to false if you don't want to reject
731 emails encrypted for key RT doesn't have and can not decrypt.
732
733 Set C<RejectOnBadData> to false if you don't want to reject letters
734 with incorrect GnuPG data.
735
736 =cut
737
738 Set( %GnuPG,
739     Enable => 1,
740     OutgoingMessagesFormat => 'RFC', # Inline
741     AllowEncryptDataInDB   => 0,
742
743     RejectOnMissingPrivateKey => 1,
744     RejectOnBadData           => 1,
745 );
746
747 =item C<%GnuPGOptions>
748
749 Options of GnuPG program.
750
751 If you override this in your RT_SiteConfig, you should be sure
752 to include a homedir setting.
753
754 NOTE that options with '-' character MUST be quoted.
755
756 =cut
757
758 Set(%GnuPGOptions,
759     homedir => '/opt/rt3/var/data/gpg',
760
761 # URL of a keyserver
762 #    keyserver => 'hkp://subkeys.pgp.net',
763
764 # enables the automatic retrieving of keys when encrypting
765 #    'auto-key-locate' => 'keyserver',
766
767 # enables the automatic retrieving of keys when verifying signatures
768 #    'auto-key-retrieve' => undef,
769 );
770
771
772 =back
773
774 =head1 Logging Configuration
775
776 The default is to log anything except debugging
777 information to syslog.  Check the L<Log::Dispatch> POD for
778 information about how to get things by syslog, mail or anything
779 else, get debugging info in the log, etc.
780
781 It might generally make sense to send error and higher by email to
782 some administrator.  If you do this, be careful that this email
783 isn't sent to this RT instance.  Mail loops will generate a critical
784 log message.
785
786 =over 4
787
788 =item C<$LogToSyslog>, C<$LogToScreen>
789
790 The minimum level error that will be logged to the specific device.
791 From lowest to highest priority, the levels are:
792  debug info notice warning error critical alert emergency
793
794 =cut
795
796 Set($LogToSyslog    , 'info');
797 Set($LogToScreen    , 'info');
798
799 =item C<$LogToFile>, C<$LogDir>, C<$LogToFileNamed>
800
801 Logging to a standalone file is also possible, but note that the
802 file should needs to both exist and be writable by all direct users
803 of the RT API.  This generally include the web server, whoever
804 rt-crontool runs as.  Note that as rt-mailgate and the RT CLI go
805 through the webserver, so their users do not need to have write
806 permissions to this file. If you expect to have multiple users of
807 the direct API, Best Practical recommends using syslog instead of
808 direct file logging.
809
810 =cut
811
812 Set($LogToFile      , undef);
813 Set($LogDir, '/opt/rt3/var/log');
814 Set($LogToFileNamed , "rt.log");    #log to rt.log
815
816 =item C<$LogStackTraces>
817
818 If set to a log level then logging will include stack traces for
819 messages with level equal to or greater than specified.
820
821 NOTICE: Stack traces include parameters supplied to functions or
822 methods. It is possible for stack trace logging to reveal sensitive
823 information such as passwords or ticket content in your logs.
824
825 =cut
826
827 Set($LogStackTraces, '');
828
829 =item C<@LogToSyslogConf>
830
831 On Solaris or UnixWare, set to ( socket => 'inet' ).  Options here
832 override any other options RT passes to L<Log::Dispatch::Syslog>.
833 Other interesting flags include facility and logopt.  (See the
834 L<Log::Dispatch::Syslog> documentation for more information.)  (Maybe
835 ident too, if you have multiple RT installations.)
836
837 =cut
838
839 Set(@LogToSyslogConf, ());
840
841 =item C<$StatementLog>,
842
843 RT has rudimentary SQL statement logging support if you have
844 DBIx-SearchBuilder 1.31_1 or higher; simply set C<$StatementLog> to be
845 the level that you wish SQL statements to be logged at.
846
847 =cut
848
849 Set($StatementLog, undef);
850
851 =back
852
853 =head1 Web Interface Configuration
854
855 =over 4
856
857 =item C<$WebDefaultStylesheet>
858
859 This determines the default stylesheet the RT web interface will use.
860 RT ships with several themes by default:
861
862   web2            The totally new, default layout for RT 3.8
863   3.5-default     RT 3.5 and 3.6 original layout
864   3.4-compat      A 3.4 compatibility stylesheet to make RT look
865                   (mostly) like 3.4
866
867 This bundled distibution of RT also includes (enabled by default):
868   freeside2.1     Integration with Freeside
869
870 This value actually specifies a directory in F<share/html/NoAuth/css/>
871 from which RT will try to load the file main.css (which should
872 @import any other files the stylesheet needs).  This allows you to
873 easily and cleanly create your own stylesheets to apply to RT.  This
874 option can be overridden by users in their preferences.
875
876 =cut
877
878 Set($WebDefaultStylesheet, 'freeside2.1');
879
880 =item C<$UsernameFormat>
881
882 This determines how user info is displayed. 'concise' will show one of 
883 either NickName, RealName, Name or EmailAddress, depending on what exists 
884 and whether the user is privileged or not. 'verbose' will show RealName and
885 EmailAddress.
886
887 =cut
888
889 Set($UsernameFormat, 'verbose');
890
891 =item C<$WebDomain>
892
893 Domain name of the RT server, eg 'www.example.com'. It should not contain
894 anything else, but server name.
895
896 =cut
897
898 Set( $WebDomain, 'localhost' );
899
900 =item C<$WebPort>
901
902 If we're running as a superuser, run on port 80
903 Otherwise, pick a high port for this user.
904
905 443 is default port for https protocol.
906
907 =cut
908
909 Set($WebPort, 80);# + ($< * 7274) % 32766 + ($< && 1024));
910
911 =item C<$WebPath>
912
913 If you're putting the web ui somewhere other than at the root of
914 your server, you should set C<$WebPath> to the path you'll be 
915 serving RT at.
916
917 C<$WebPath> requires a leading / but no trailing /, or it can be blank.
918
919 In most cases, you should leave C<$WebPath> set to '' (an empty value).
920
921 =cut
922
923 Set($WebPath, "");
924
925 =item C<$WebBaseURL>, C<$WebURL>
926
927 Usually you don't want to set these options. The only obviouse reason is
928 RT accessible via https protocol on non standard port, eg
929 'https://rt.example.com:9999'. In all other cases these options are computed
930 using C<$WebDomain>, C<$WebPort> and C<$WebPath>.
931
932 C<$WebBaseURL> is the scheme, server and port (eg 'http://rt.example.com')
933 for constructing urls to the web UI. C<$WebBaseURL> doesn't need a trailing /.
934
935 C<$WebURL> is the C<$WebBaseURL>, C<$WebPath> and trailing /, for example:
936 'http://www.example.com/rt/'.
937
938 =cut
939
940 my $port = RT->Config->Get('WebPort');
941 Set($WebBaseURL,
942     ($port == 443? 'https': 'http') .'://'
943     . RT->Config->Get('WebDomain')
944     . ($port != 80 && $port != 443? ":$port" : '')
945 );
946
947 Set($WebURL, RT->Config->Get('WebBaseURL') . RT->Config->Get('WebPath') . "/");
948
949 =item C<$WebImagesURL>
950
951 C<$WebImagesURL> points to the base URL where RT can find its images.
952 Define the directory name to be used for images in rt web
953 documents.
954
955 =cut
956
957 Set($WebImagesURL, RT->Config->Get('WebPath') . "/NoAuth/images/");
958
959 =item C<$LogoURL>
960
961 C<$LogoURL> points to the URL of the RT logo displayed in the web UI
962
963 =cut
964
965 Set($LogoURL, RT->Config->Get('WebImagesURL') . "bplogo.gif");
966
967 =item C<$LogoLinkURL>
968
969 C<$LogoLinkURL> is the URL that the RT logo hyperlinks to.
970
971 =cut
972
973 Set($LogoLinkURL, "http://bestpractical.com");
974
975 =item C<$LogoAltText>
976
977 C<$LogoAltText> is a string of text for the alt-text of the logo. It
978 will be passed through C<loc> for localization.
979
980 =cut
981
982 Set($LogoAltText, "Best Practical Solutions, LLC corporate logo");
983
984 =item C<$LogoImageHeight>
985
986 C<$LogoImageHeight> is the value of the C<height> attribute of the logo
987 C<img> tag.
988
989 =cut
990
991 Set($LogoImageHeight, 33);
992
993 =item C<$LogoImageWidth>
994
995 C<$LogoImageWidth> is the value of the C<width> attribute of the logo
996 C<img> tag.
997
998 =cut
999
1000 Set($LogoImageWidth, 177);
1001
1002 =item C<$WebNoAuthRegex>
1003
1004 What portion of RT's URL space should not require authentication.
1005
1006 This is mostly for extension and doesn't mean RT will work without
1007 login if you change it.
1008
1009 =cut
1010
1011 Set($WebNoAuthRegex, qr{^ /rt (?:/+NoAuth/ | /+REST/\d+\.\d+/NoAuth/) }x );
1012
1013 =item C<$SelfServiceRegex>
1014
1015 What portion of RT's URLspace should be accessible to Unprivileged users
1016 This does not override the redirect from F</Ticket/Display.html> to
1017 F</SelfService/Display.html> when Unprivileged users attempt to access
1018 ticked displays
1019
1020 =cut
1021
1022 Set($SelfServiceRegex, qr!^(?:/+SelfService/)!x );
1023
1024 =item C<$MessageBoxWidth>, C<$MessageBoxHeight>
1025
1026 For message boxes, set the entry box width, height and what type of
1027 wrapping to use.  These options can be overridden by users in their
1028 preferences.
1029
1030 Default width: 72, height: 15
1031
1032 These settings only apply to the non-RichText message box.
1033 See below for Rich Text settings.
1034
1035 =cut
1036
1037 Set($MessageBoxWidth, 72);
1038 Set($MessageBoxHeight, 15);
1039
1040 =item C<$MessageBoxWrap>
1041
1042 Default wrapping: "HARD"  (choices "SOFT", "HARD")
1043
1044 Wrapping is disabled when using MessageBoxRichText because
1045 of a bad interaction between IE and wrapping with the Rich
1046 Text Editor.
1047
1048 =cut
1049
1050 Set($MessageBoxWrap, "HARD");
1051
1052 =item C<$MessageBoxRichText>
1053
1054 Should "rich text" editing be enabled? This option lets your users send html email messages from the web interface.
1055
1056 =cut
1057
1058 Set($MessageBoxRichText, 1);
1059
1060 =item C<$MessageBoxRichTextHeight>
1061
1062 Height of RichText javascript enabled editing boxes (in pixels)
1063
1064 =cut
1065
1066 Set($MessageBoxRichTextHeight, 200);
1067
1068 =item C<$MessageBoxIncludeSignature>
1069
1070 Should your user's signatures (from their Preferences page) be included in Comments and Replies
1071
1072 =cut
1073
1074 Set($MessageBoxIncludeSignature, 1);
1075
1076 =item C<$MessageBoxIncludeSignatureOnComment>
1077
1078 Should your user's signatures (from their Preferences page) be included in Comments. Setting this to false overrides C<$MessageBoxIncludeSignature>.
1079
1080 =cut
1081
1082 Set($MessageBoxIncludeSignatureOnComment, 1);
1083
1084 =item C<$WikiImplicitLinks>
1085
1086 Support implicit links in WikiText custom fields?  A true value
1087 causes InterCapped or ALLCAPS words in WikiText fields to
1088 automatically become links to searches for those words.  If used on
1089 RTFM articles, it links to the RTFM article with that name.
1090
1091 =cut
1092
1093 Set($WikiImplicitLinks, 0);
1094
1095 =item C<$TrustHTMLAttachments>
1096
1097 if C<TrustHTMLAttachments> is not defined, we will display them
1098 as text. This prevents malicious HTML and javascript from being
1099 sent in a request (although there is probably more to it than that)
1100
1101 =cut
1102
1103 Set($TrustHTMLAttachments, undef);
1104
1105 =item C<$AlwaysDownloadAttachments>
1106
1107 Always download attachments, regardless of content type. If set,
1108 this overrides C<TrustHTMLAttachments>.
1109
1110 =cut
1111
1112 Set($AlwaysDownloadAttachments, undef);
1113
1114 =item C<$AttachmentUnits>
1115
1116 Controls the units (kilobytes or bytes) that attachment sizes use
1117 for display. The default is to display kilobytes if the attachment
1118 is larger than 1024 bytes, bytes otherwise. If you set
1119 C<$AttachmentUnits> to C<'k'> then attachment sizes will always be
1120 displayed in kilobytes. If set to C<'b'>, then sizes will be bytes.
1121
1122 =cut
1123
1124 Set($AttachmentUnits, undef);
1125
1126 =item C<$EditCustomFieldsSingleColumn>
1127
1128 When displaying a list of Ticket Custom Fields for editing, RT defaults
1129 to a 2 column list.  If you set this to 1, it will instead display the
1130 Custom Fields in a single column.
1131
1132 =cut
1133
1134 Set($EditCustomFieldsSingleColumn, 0);
1135
1136 =item C<$RedistributeAutoGeneratedMessages>
1137
1138 Should RT redistribute correspondence that it identifies as
1139 machine generated? A true value will do so; setting this to '0'
1140 will cause no such messages to be redistributed.
1141 You can also use 'privileged' (the default), which will redistribute
1142 only to privileged users. This helps to protect against malformed
1143 bounces and loops caused by autocreated requestors with bogus addresses.
1144
1145 =cut
1146
1147 Set($RedistributeAutoGeneratedMessages, 'privileged');
1148
1149 =item C<$PreferRichText>
1150
1151 If C<$PreferRichText> is set to a true value, RT will show HTML/Rich text
1152 messages in preference to their plaintext alternatives. RT "scrubs" the 
1153 html to show only a minimal subset of HTML to avoid possible contamination
1154 by cross-site-scripting attacks.
1155
1156 =cut
1157
1158 Set($PreferRichText, undef);
1159
1160 =item C<$WebExternalAuth>
1161
1162 If C<$WebExternalAuth> is defined, RT will defer to the environment's
1163 REMOTE_USER variable.
1164
1165 =cut
1166
1167 Set($WebExternalAuth, undef);
1168
1169 =item C<$WebExternalAuthContinuous>
1170
1171 If C<$WebExternalAuthContinuous> is defined, RT will check for the
1172 REMOTE_USER on each access.  If you would prefer this to only happen
1173 once (at initial login) set this to a false value.  The default setting
1174 will help ensure that if your external auth system deauthenticates a
1175 user, RT notices as soon as possible.
1176
1177 =cut
1178
1179 Set($WebExternalAuthContinuous, 1);
1180
1181 =item C<$WebFallbackToInternalAuth>
1182
1183 If C<$WebFallbackToInternalAuth> is defined, the user is allowed a chance
1184 of fallback to the login screen, even if REMOTE_USER failed.
1185
1186 =cut
1187
1188 Set($WebFallbackToInternalAuth , undef);
1189
1190 =item C<$WebExternalGecos>
1191
1192 C<$WebExternalGecos> means to match 'gecos' field as the user identity);
1193 useful with mod_auth_pwcheck and IIS Integrated Windows logon.
1194
1195 =cut
1196
1197 Set($WebExternalGecos , undef);
1198
1199 =item C<$WebExternalAuto>
1200
1201 C<$WebExternalAuto> will create users under the same name as REMOTE_USER
1202 upon login, if it's missing in the Users table.
1203
1204 =cut
1205
1206 Set($WebExternalAuto , undef);
1207
1208 =item C<$AutoCreate>
1209
1210 If C<$WebExternalAuto> is true, C<$AutoCreate> will be passed to User's
1211 Create method.  Use it to set defaults, such as creating 
1212 Unprivileged users with C<{ Privileged => 0 }>
1213 ( Must be a hashref of arguments )
1214
1215 =cut
1216
1217 Set($AutoCreate, undef);
1218
1219 =item C<$WebSessionClass>
1220
1221 C<$WebSessionClass> is the class you wish to use for managing Sessions.
1222 It defaults to use your SQL database, but if you are using MySQL 3.x and
1223 plans to use non-ascii Queue names, uncomment and add this line to
1224 F<RT_SiteConfig.pm> will prevent session corruption.
1225
1226 =cut
1227
1228 # Set($WebSessionClass , 'Apache::Session::File');
1229
1230 =item C<$AutoLogoff>
1231
1232 By default, RT's user sessions persist until a user closes his or her 
1233 browser. With the C<$AutoLogoff> option you can setup session lifetime in 
1234 minutes. A user will be logged out if he or she doesn't send any requests 
1235 to RT for the defined time.
1236
1237 =cut
1238
1239 Set($AutoLogoff, 0);
1240
1241 =item C<$LogoutRefresh>
1242
1243 The number of seconds to wait after logout before sending the user to the
1244 login page. By default, 1 second, though you may want to increase this if
1245 you display additional information on the logout page.
1246
1247 =cut
1248
1249 Set($LogoutRefresh, 1);
1250
1251 =item C<$WebSecureCookies>
1252
1253 By default, RT's session cookie isn't marked as "secure" Some web browsers 
1254 will treat secure cookies more carefully than non-secure ones, being careful
1255 not to write them to disk, only send them over an SSL secured connection 
1256 and so on. To enable this behaviour, set C<$WebSecureCookies> to a true value. 
1257 NOTE: You probably don't want to turn this on _unless_ users are only connecting
1258 via SSL encrypted HTTP connections.
1259
1260 =cut
1261
1262 Set($WebSecureCookies, 0);
1263
1264 =item C<$WebFlushDbCacheEveryRequest>
1265
1266 By default, RT clears its database cache after every page view.
1267 This ensures that you've always got the most current information 
1268 when working in a multi-process (mod_perl or FastCGI) Environment
1269 Setting C<$WebFlushDbCacheEveryRequest> to '0' will turn this off,
1270 which will speed RT up a bit, at the expense of a tiny bit of data 
1271 accuracy.
1272
1273 =cut
1274
1275 Set($WebFlushDbCacheEveryRequest, '1');
1276
1277
1278 =item C<$MaxInlineBody>
1279
1280 C<$MaxInlineBody> is the maximum attachment size that we want to see
1281 inline when viewing a transaction.  RT will inline any text if value
1282 is undefined or 0.  This option can be overridden by users in their
1283 preferences.
1284
1285 =cut
1286
1287 Set($MaxInlineBody, 12000);
1288
1289 =item C<$DefaultSummaryRows>
1290
1291 C<$DefaultSummaryRows> is default number of rows displayed in for search
1292 results on the frontpage.
1293
1294 =cut
1295
1296 Set($DefaultSummaryRows, 10);
1297
1298 =item C<$HomePageRefreshInterval>
1299
1300 C<$HomePageRefreshInterval> is default number of seconds to refresh the RT
1301 home page. Choose from [0, 120, 300, 600, 1200, 3600, 7200].
1302
1303 =cut
1304
1305 Set($HomePageRefreshInterval, 0);
1306
1307 =item C<$SearchResultsRefreshInterval>
1308
1309 C<$SearchResultsRefreshInterval> is default number of seconds to refresh
1310 search results in RT. Choose from [0, 120, 300, 600, 1200, 3600, 7200].
1311
1312 =cut
1313
1314 Set($SearchResultsRefreshInterval, 0);
1315
1316 =item C<$ResolveDefaultUpdateType>
1317
1318 Set the default Update Type when clicking the Resolve link in the Ticket
1319 links tab.
1320
1321   Comment            Comments (Not sent to requestors)
1322   Respond            Reply to requestors
1323
1324 =cut
1325
1326 Set($ResolveDefaultUpdateType, 'Comment');
1327
1328 =item C<$SuppressAutoOpenOnUpdate>
1329
1330 When users click Comment or Reply on a new ticket in the web UI, the default
1331 status for the ticket gets set to 'open' if the status is currently 'new'.
1332 Setting this option to 1 will suppress that behavior and leave the default
1333 status as 'new'. This option can be overridden by users in their preferences.
1334
1335 =cut
1336
1337 Set($SuppressAutoOpenOnUpdate, 0);
1338
1339 =item C<$OldestTransactionsFirst>
1340
1341 By default, RT shows newest transactions at the bottom of the ticket
1342 history page, if you want see them at the top set this to '0'.  This
1343 option can be overridden by users in their preferences.
1344
1345 =cut
1346
1347 Set($OldestTransactionsFirst, '1');
1348
1349 =item C<$ShowTransactionImages>
1350
1351 By default, RT shows images attached to incoming (and outgoing) ticket updates
1352 inline. Set this variable to 0 if you'd like to disable that behaviour
1353
1354 =cut
1355
1356 Set($ShowTransactionImages, 1);
1357
1358 =item C<$PlainTextPre>
1359
1360 Normally plaintext attachments are displayed as HTML with line
1361 breaks preserved.  This causes space- and tab-based formatting not
1362 to be displayed correctly.  By setting $PlainTextPre they'll be
1363 displayed using <pre> instead so such formatting works, but they'll
1364 use a monospaced font, no matter what the value of C<$PlainTextMono> is.
1365
1366 =cut
1367
1368 Set($PlainTextPre, 0);
1369
1370
1371 =item C<$PlainTextMono> 
1372 To display plaintext attachments,
1373 Set C<$PlainTextMono> to 1 to use monospaced font and preserve
1374 formatting, but unlike PlainTextPre, the text will wrap to fit into the
1375 UI.
1376
1377 =cut
1378
1379 Set($PlainTextMono, 0);
1380
1381 =item C<$ShowUnreadMessageNotifications>
1382
1383 By default, RT will prompt users when there are new, unread messages on
1384 tickets they are viewing.
1385
1386 Set C<$ShowUnreadMessageNotifications> to a false value to disable this feature.
1387
1388 =cut
1389
1390 Set($ShowUnreadMessageNotifications, 1);
1391
1392
1393 =item C<$HomepageComponents>
1394
1395 C<$HomepageComponents> is an arrayref of allowed components on a user's
1396 customized homepage ("RT at a glance").
1397
1398 =cut
1399
1400 Set($HomepageComponents, [qw(QuickCreate Quicksearch MyCalendar MyAdminQueues MySupportQueues MyReminders RefreshHomepage Dashboards)]);
1401
1402 =item C<@MasonParameters>
1403
1404 C<@MasonParameters> is the list of parameters for the constructor of
1405 HTML::Mason's Apache or CGI Handler.  This is normally only useful
1406 for debugging, eg. profiling individual components with:
1407
1408     use MasonX::Profiler; # available on CPAN
1409     Set(@MasonParameters, (preamble => 'my $p = MasonX::Profiler->new($m, $r);'));
1410
1411 =cut
1412
1413 Set(@MasonParameters, ());
1414
1415 =item C<$DefaultSearchResultFormat>
1416
1417 C<$DefaultSearchResultFormat> is the default format for RT search results
1418
1419 =cut
1420
1421 Set ($DefaultSearchResultFormat, qq{
1422    '<B><A HREF="__WebPath__/Ticket/Display.html?id=__id__">__id__</a></B>/TITLE:#',
1423    '<B><A HREF="__WebPath__/Ticket/Display.html?id=__id__">__Subject__</a></B>/TITLE:Subject',
1424    Customer,
1425    Status,
1426    QueueName, 
1427    OwnerName, 
1428    Priority, 
1429    '__NEWLINE__',
1430    '', 
1431    '<small>__Requestors__</small>',
1432    '<small>__CustomerTags__</small>',
1433    '<small>__CreatedRelative__</small>',
1434    '<small>__ToldRelative__</small>',
1435    '<small>__LastUpdatedRelative__</small>',
1436    '<small>__TimeLeft__</small>'});
1437
1438 =item C<$DefaultSelfServiceSearchResultFormat>
1439
1440 C<$DefaultSelfServiceSearchResultFormat> is the default format of searches displayed in the 
1441 SelfService interface.
1442
1443 =cut
1444
1445 Set($DefaultSelfServiceSearchResultFormat, qq{
1446    '<B><A HREF="__WebPath__/SelfService/Display.html?id=__id__">__id__</a></B>/TITLE:#',
1447    '<B><A HREF="__WebPath__/SelfService/Display.html?id=__id__">__Subject__</a></B>/TITLE:Subject',
1448    Status,
1449    Requestors,
1450    OwnerName});
1451
1452 =item C<%AdminSearchResultFormat>
1453
1454 In admin interface format strings similar to tickets search result
1455 formats are used. Use C<%AdminSearchResultFormat> to define format
1456 strings per RT class.
1457
1458 =cut
1459
1460 Set(%AdminSearchResultFormat,
1461     Queues =>
1462         q{'<a href="__WebPath__/Admin/Queues/Modify.html?id=__id__">__id__</a>/TITLE:#'}
1463         .q{,'<a href="__WebPath__/Admin/Queues/Modify.html?id=__id__">__Name__</a>/TITLE:Name'}
1464         .q{,__Description__,__Address__,__Priority__,__DefaultDueIn__,__Disabled__},
1465
1466     Groups =>
1467         q{'<a href="__WebPath__/Admin/Groups/Modify.html?id=__id__">__id__</a>/TITLE:#'}
1468         .q{,'<a href="__WebPath__/Admin/Groups/Modify.html?id=__id__">__Name__</a>/TITLE:Name'}
1469         .q{,'__Description__'},
1470
1471     Users =>
1472         q{'<a href="__WebPath__/Admin/Users/Modify.html?id=__id__">__id__</a>/TITLE:#'}
1473         .q{,'<a href="__WebPath__/Admin/Users/Modify.html?id=__id__">__Name__</a>/TITLE:Name'}
1474         .q{,__RealName__, __EmailAddress__},
1475
1476     CustomFields =>
1477         q{'<a href="__WebPath__/Admin/CustomFields/Modify.html?id=__id__">__id__</a>/TITLE:#'}
1478         .q{,'<a href="__WebPath__/Admin/CustomFields/Modify.html?id=__id__">__Name__</a>/TITLE:Name'}
1479         .q{,__AppliedTo__, __FriendlyType__, __FriendlyPattern__},
1480
1481     Scrips => 
1482         q{'<a href="__WebPath__/__WebRequestPathDir__/Scrip.html?id=__id__&Queue=__QueueId__">__id__</a>/TITLE:#'}
1483         .q{,'<a href="__WebPath__/__WebRequestPathDir__/Scrip.html?id=__id__&Queue=__QueueId__">__Description__</a>/TITLE:Description'}
1484         .q{,__Stage__, __Condition__, __Action__, __Template__},
1485
1486     Templates =>
1487         q{'<a href="__WebPath__/__WebRequestPathDir__/Template.html?Queue=__QueueId__&Template=__id__">__id__</a>/TITLE:#'}
1488         .q{,'<a href="__WebPath__/__WebRequestPathDir__/Template.html?Queue=__QueueId__&Template=__id__">__Name__</a>/TITLE:Name'}
1489         .q{,'__Description__'},
1490 );
1491
1492 =item C<$SuppressInlineTextFiles>
1493
1494 If C<$SuppressInlineTextFiles> is set to a true value, then uploaded
1495 text files (text-type attachments with file names) are prevented
1496 from being displayed in-line when viewing a ticket's history.
1497
1498 =cut
1499
1500 Set($SuppressInlineTextFiles, undef);
1501
1502 =item C<$DontSearchFileAttachments>
1503
1504 If C<$DontSearchFileAttachments> is set to a true value, then uploaded
1505 files (attachments with file names) are not searched during full-content
1506 ticket searches.
1507
1508 =cut
1509
1510 Set($DontSearchFileAttachments, undef);
1511
1512 =item C<%ChartFont>
1513
1514 The L<GD> module (which RT uses for graphs) ships with a builtin font 
1515 that doesn't have full Unicode support. You can use a given TrueType font 
1516 for a specific language by setting %ChartFont to (language =E<gt> the 
1517 absolute path of a font) pairs. Your GD library must have support for
1518 TrueType fonts to use this option. If there is no entry for a language 
1519 in the hash then font with 'others' key is used.
1520
1521 RT comes with two TrueType fonts covering most available languages.
1522
1523 =cut
1524
1525 Set(
1526     %ChartFont,
1527     'zh-cn'  => "$RT::BasePath/share/fonts/DroidSansFallback.ttf",
1528     'zh-tw'  => "$RT::BasePath/share/fonts/DroidSansFallback.ttf",
1529     'ja'     => "$RT::BasePath/share/fonts/DroidSansFallback.ttf",
1530     'others' => "$RT::BasePath/share/fonts/DroidSans.ttf",
1531 );
1532
1533 =item C<$ChartsTimezonesInDB>
1534
1535 RT stores dates using the UTC timezone in the DB, so charts grouped
1536 by dates and time are not representative. Set C<$ChartsTimezonesInDB>
1537 to a true value to enable timezone conversions using your DB's
1538 capabilities. You may need to do some work on the DB side to use this
1539 feature, read more in F<docs/timezones_in_charts.pod>.
1540
1541 At this time, this feature only applies to MySQL and PostgreSQL.
1542
1543 =cut
1544
1545 Set( $ChartsTimezonesInDB, 0 );
1546
1547 =item C<@Active_MakeClicky>
1548
1549 MakeClicky detects various formats of data in headers and email
1550 messages, and extends them with supporting links.  By default, RT
1551 provides two formats:
1552
1553 * 'httpurl': detects http:// and https:// URLs and adds '[Open URL]'
1554   link after the URL.
1555
1556 * 'httpurl_overwrite': also detects URLs as 'httpurl' format, but
1557   replace URL with link and *adds spaces* into text if it's longer
1558   then 30 chars. This allow browser to wrap long URLs and avoid
1559   horizontal scrolling.
1560
1561 See F<share/html/Elements/MakeClicky> for documentation on how to add your own.
1562
1563 =cut
1564
1565 Set(@Active_MakeClicky, qw());
1566
1567 =item C<$DefaultQueue>
1568
1569 Use this to select the default queue name that will be used for creating new
1570 tickets. You may use either the queue's name or its ID. This only affects the
1571 queue selection boxes on the web interface.
1572
1573 =cut
1574
1575 #Set($DefaultQueue, 'General');
1576
1577 =item C<$DefaultTimeUnitsToHours>
1578
1579 Use this to set the default units for time entry to hours instead of minutes.
1580
1581 =cut
1582
1583 Set($DefaultTimeUnitsToHours, 0);
1584
1585 =back
1586
1587 =head1 L<Net::Server> (rt-server) Configuration
1588
1589 =over 4
1590
1591 =item C<$StandaloneMinServers>, C<$StandaloneMaxServers>
1592
1593 The absolute minimum and maximum number of servers that will be created to
1594 handle requests. Having multiple servers means that serving a slow page will
1595 affect other users less.
1596
1597 =cut
1598
1599 Set($StandaloneMinServers, 1);
1600 Set($StandaloneMaxServers, 1);
1601
1602 =item C<$StandaloneMinSpareServers>, C<$StandaloneMaxSpareServers>
1603
1604 These next two options can be used to scale up and down the number of servers
1605 to adjust to load. These two options will respect the C<$StandaloneMinServers
1606 > and C<$StandaloneMaxServers options>.
1607
1608 =cut
1609
1610 Set($StandaloneMinSpareServers, 0);
1611 Set($StandaloneMaxSpareServers, 0);
1612
1613 =item C<$StandaloneMaxRequests>
1614
1615 This sets the absolute maximum number of requests a single server will serve.
1616 Setting this would be useful if, for example, memory usage slowly crawls up
1617 every hit.
1618
1619 =cut
1620
1621 #Set($StandaloneMaxRequests, 50);
1622
1623 =item C<%NetServerOptions>
1624
1625 C<%NetServerOptions> is a hash of additional options to use for
1626 L<Net::Server/DEFAULT ARGUMENTS>. For example, you could set
1627 reverse_lookups to get the hostnames for all users with:
1628
1629 C<Set(%NetServerOptions, (reverse_lookups => 1));>
1630
1631 =cut
1632
1633 Set(%NetServerOptions, ());
1634
1635 =back
1636
1637
1638 =head1 UTF-8 Configuration
1639
1640 =over 4
1641
1642 =item C<@LexiconLanguages>
1643
1644 An array that contains languages supported by RT's internationalization
1645 interface.  Defaults to all *.po lexicons; setting it to C<qw(en ja)> will make
1646 RT bilingual instead of multilingual, but will save some memory.
1647
1648 =cut
1649
1650 Set(@LexiconLanguages, qw(*));
1651
1652 =item C<@EmailInputEncodings>
1653
1654 An array that contains default encodings used to guess which charset
1655 an attachment uses if not specified.  Must be recognized by
1656 L<Encode::Guess>.
1657
1658 =cut
1659
1660 Set(@EmailInputEncodings, qw(utf-8 iso-8859-1 us-ascii));
1661
1662 =item C<$EmailOutputEncoding>
1663
1664 The charset for localized email.  Must be recognized by Encode.
1665
1666 =cut
1667
1668 Set($EmailOutputEncoding, 'utf-8');
1669
1670
1671 =back
1672
1673 =head1 Date Handling Configuration
1674
1675 =over 4
1676
1677 =item C<$DateTimeFormat>
1678
1679 You can choose date and time format.  See "Output formatters"
1680 section in perldoc F<lib/RT/Date.pm> for more options.  This option can
1681 be overridden by users in their preferences.
1682 Some examples:
1683
1684 C<Set($DateTimeFormat, 'LocalizedDateTime');>
1685 C<Set($DateTimeFormat, { Format => 'ISO', Seconds => 0 });>
1686 C<Set($DateTimeFormat, 'RFC2822');>
1687 C<Set($DateTimeFormat, { Format => 'RFC2822', Seconds => 0, DayOfWeek => 0 });>
1688
1689 =cut
1690
1691 Set($DateTimeFormat, 'DefaultFormat');
1692
1693 # Next two options are for Time::ParseDate
1694
1695 =item C<$DateDayBeforeMonth>
1696
1697 Set this to 1 if your local date convention looks like "dd/mm/yy" instead of
1698 "mm/dd/yy". Used only for parsing, not for displaying dates.
1699
1700 =cut
1701
1702 Set($DateDayBeforeMonth , 1);
1703
1704 =item C<$AmbiguousDayInPast>, C<$AmbiguousDayInFuture>
1705
1706 Should an unspecified day or year in a date refer to a future or a
1707 past value? For example, should a date of "Tuesday" default to mean
1708 the date for next Tuesday or last Tuesday? Should the date "March 1"
1709 default to the date for next March or last March?
1710
1711 Set $<AmbiguousDayInPast> for the last date, or $<$AmbiguousDayInFuture> for the
1712 next date.
1713
1714 The default is usually good.
1715
1716 =cut
1717
1718 Set($AmbiguousDayInPast, 0);
1719 Set($AmbiguousDayInFuture, 0);
1720
1721 =back
1722
1723 =head1 Approval Configuration
1724
1725 Configuration for the approval system
1726
1727 =over 4
1728
1729 =item C<$ApprovalRejectionNotes>
1730
1731 Should rejection notes be sent to the requestors?  The default is true.
1732
1733 =cut
1734
1735 Set($ApprovalRejectionNotes, 1);
1736
1737
1738 =back
1739
1740 =head1 Miscellaneous Configuration
1741
1742 =over 4
1743
1744 =item C<@ActiveStatus>, C<@InactiveStatus>
1745
1746 You can define new statuses and even reorder existing statuses here.
1747 WARNING. DO NOT DELETE ANY OF THE DEFAULT STATUSES. If you do, RT
1748 will break horribly. The statuses you add must be no longer than
1749 10 characters.
1750
1751 =cut
1752
1753 Set(@ActiveStatus, qw(new open stalled));
1754 Set(@InactiveStatus, qw(resolved rejected deleted));
1755
1756 =item C<$LinkTransactionsRun1Scrip>
1757
1758 RT-3.4 backward compatibility setting. Add/Delete Link used to record one
1759 transaction and run one scrip. Set this value to 1 if you want
1760 only one of the link transactions to have scrips run.
1761
1762 =cut
1763
1764 Set($LinkTransactionsRun1Scrip, 0);
1765
1766 =item C<$StrictLinkACL>
1767
1768 When this feature is enabled a user needs I<ModifyTicket> rights on both
1769 tickets to link them together, otherwise he can have rights on either of
1770 them.
1771
1772 =cut
1773
1774 Set($StrictLinkACL, 1);
1775
1776 =item C<$PreviewScripMessages>
1777
1778 Set C<$PreviewScripMessages> to 1 if the scrips preview on the ticket
1779 reply page should include the content of the messages to be sent.
1780
1781 =cut
1782
1783 Set($PreviewScripMessages, 0);
1784
1785 =item C<$UseTransactionBatch>
1786
1787 Set C<$UseTransactionBatch> to 1 to execute transactions in batches,
1788 such that a resolve and comment (for example) would happen
1789 simultaneously, instead of as two transactions, unaware of each
1790 others' existence.
1791
1792 =cut
1793
1794 Set($UseTransactionBatch, 1);
1795
1796 =item C<@CustomFieldValuesSources>
1797
1798 Set C<@CustomFieldValuesSources> to a list of class names which extend
1799 L<RT::CustomFieldValues::External>.  This can be used to pull lists of
1800 custom field values from external sources at runtime.
1801
1802 =cut
1803
1804 Set(@CustomFieldValuesSources, ('RT::CustomFieldValues::Queues'));
1805
1806 =item C<$CanonicalizeRedirectURLs>
1807
1808 Set C<$CanonicalizeRedirectURLs> to 1 to use $C<WebURL> when redirecting rather
1809 than the one we get from C<%ENV>.
1810
1811 If you use RT behind a reverse proxy, you almost certainly want to
1812 enable this option.
1813
1814 =cut
1815
1816 Set($CanonicalizeRedirectURLs, 0);
1817 =item C<$EnableReminders>
1818
1819 Hide links/portlets related to Reminders by setting this to 0
1820
1821 =cut
1822
1823 Set($EnableReminders,1);
1824
1825
1826 =item C<@Plugins>
1827
1828 Set C<@Plugins> to a list of external RT plugins that should be enabled (those
1829 plugins have to be previously downloaded and installed).
1830 Example:
1831
1832 C<Set(@Plugins, (qw(Extension::QuickDelete RT::FM)));>
1833
1834 =cut
1835
1836 Set(@Plugins, (qw(RTx::Calendar
1837                   RT::Extension::MobileUI))); #RTx::Checklist ));
1838
1839 =back
1840
1841 =head1 Development Configuration
1842
1843 =over 4
1844
1845 =item C<$DevelMode>
1846
1847 RT comes with a "Development mode" setting. 
1848 This setting, as a convenience for developers, turns on 
1849 all sorts of development options that you most likely don't want in 
1850 production:
1851
1852 * Turns off Mason's 'static_source' directive. By default, you can't 
1853   edit RT's web ui components on the fly and have RT magically pick up
1854   your changes. (It's a big performance hit)
1855
1856  * More to come
1857
1858 =cut
1859
1860 Set($DevelMode, '0');
1861
1862
1863 =back
1864
1865 =head1 Deprecated Options
1866
1867 =over 4
1868
1869 =item C<$AlwaysUseBase64>
1870
1871 Encode blobs as base64 in DB (?)
1872
1873 =item C<$TicketBaseURI>
1874
1875 Base URI to tickets in this system; used when loading (?)
1876
1877 =item C<$UseCodeTickets>
1878
1879 This option is exists for backwards compatibility.  Don't use it.
1880
1881 =back
1882
1883 =cut
1884
1885 1;