fix path so we can find .css files
[freeside.git] / rt / etc / RT_Config.pm.in
1 #
2 # WARNING: NEVER EDIT RT_Config.pm. Instead, copy any sections you want to change to RT_SiteConfig.pm
3 # and edit them there.
4 #
5
6 package RT;
7
8 =head1 NAME
9
10 RT::Config
11
12 =for testing
13
14 use RT::Config;
15
16 =cut
17
18 # {{{ Base Configuration
19
20 # $rtname is the string that RT will look for in mail messages to
21 # figure out what ticket a new piece of mail belongs to
22
23 # Your domain name is recommended, so as not to pollute the namespace.
24 # once you start using a given tag, you should probably never change it.
25 # (otherwise, mail for existing tickets won't get put in the right place
26
27 Set($rtname , "example.com");
28
29
30 # This regexp controls what subject tags RT recognizes as its own.
31 # If you're not dealing with historical $rtname values, you'll likely
32 # never have to enable this feature.
33 #
34 # Be VERY CAREFUL with it. Note that it overrides $rtname for subject
35 # token matching and that you should use only "non-capturing" parenthesis
36 # grouping. For example:
37 #
38 #       Set($EmailSubjectTagRegex, qr/(?:example.com|example.org)/i );
39 #
40 # and NOT
41
42 #       Set($EmailSubjectTagRegex, qr/(example.com|example.org)/i );
43 #
44 # This setting would make RT behave exactly as it does without the 
45 # setting enabled.
46 #
47 # Set($EmailSubjectTagRegex, qr/\Q$rtname\E/i );
48
49
50
51 # You should set this to your organization's DNS domain. For example,
52 # fsck.com or asylum.arkham.ma.us. It's used by the linking interface to
53 # guarantee that ticket URIs are unique and easy to construct.
54
55 Set($Organization , "example.com");
56
57 # $user_passwd_min defines the minimum length for user passwords. Setting
58 # it to 0 disables this check
59 Set($MinimumPasswordLength , "5");
60
61 # $Timezone is used to convert times entered by users into GMT and back again
62 # It should be set to a timezone recognized by your local unix box.
63 Set($Timezone , 'US/Eastern');
64
65 # }}}
66
67 # {{{ Database Configuration
68
69 # Database driver beeing used. Case matters
70 # Valid types are "mysql", "Oracle" and "Pg"
71
72 Set($DatabaseType , '@DB_TYPE@');
73
74 # The domain name of your database server
75 # If you're running mysql and it's on localhost,
76 # leave it blank for enhanced performance
77 Set($DatabaseHost   , '@DB_HOST@');
78 Set($DatabaseRTHost , '@DB_RT_HOST@');
79
80 # The port that your database server is running on.  Ignored unless it's
81 # a positive integer. It's usually safe to leave this blank
82 Set($DatabasePort , '@DB_PORT@');
83
84 #The name of the database user (inside the database)
85 Set($DatabaseUser , '@DB_RT_USER@');
86
87 # Password the DatabaseUser should use to access the database
88 Set($DatabasePassword , '@DB_RT_PASS@');
89
90 # The name of the RT's database on your database server
91 Set($DatabaseName , '@DB_DATABASE@');
92
93 # If you're using Postgres and have compiled in SSL support,
94 # set DatabaseRequireSSL to 1 to turn on SSL communication
95 Set($DatabaseRequireSSL , undef);
96
97 # }}}
98
99 # {{{ Incoming mail gateway configuration
100
101 # OwnerEmail is the address of a human who manages RT. RT will send
102 # errors generated by the mail gateway to this address.  This address
103 # should _not_ be an address that's managed by your RT instance.
104
105 Set($OwnerEmail , 'root');
106
107 # If $LoopsToRTOwner is defined, RT will send mail that it believes
108 # might be a loop to $RT::OwnerEmail
109
110 Set($LoopsToRTOwner , 1);
111
112 # If $StoreLoops is defined, RT will record messages that it believes
113 # to be part of mail loops.
114 # As it does this, it will try to be careful not to send mail to the
115 # sender of these messages
116
117 Set($StoreLoops , undef);
118
119 # $MaxAttachmentSize sets the maximum size (in bytes) of attachments stored
120 # in the database.
121
122 # For mysql and oracle, we set this size at 10 megabytes.
123 # If you're running a postgres version earlier than 7.1, you will need
124 # to drop this to 8192. (8k)
125
126 Set($MaxAttachmentSize , 10000000);
127
128 # $TruncateLongAttachments: if this is set to a non-undef value,
129 # RT will truncate attachments longer than MaxAttachmentSize.
130
131 Set($TruncateLongAttachments , undef);
132
133 # $DropLongAttachments: if this is set to a non-undef value,
134 # RT will silently drop attachments longer than MaxAttachmentSize.
135
136 Set($DropLongAttachments , undef);
137
138 # If $ParseNewMessageForTicketCcs is true, RT will attempt to divine
139 # Ticket 'Cc' watchers from the To and Cc lines of incoming messages
140 # Be forewarned that if you have _any_ addresses which forward mail to
141 # RT automatically and you enable this option without modifying
142 # "RTAddressRegexp" below, you will get yourself into a heap of trouble.
143
144 Set($ParseNewMessageForTicketCcs , undef);
145
146 # RTAddressRegexp is used to make sure RT doesn't add itself as a ticket CC if
147 # the setting above is enabled.
148
149 Set($RTAddressRegexp , '^rt\@example.com$');
150
151 # RT provides functionality which allows the system to rewrite
152 # incoming email addresses.  In its simplest form,
153 # you can substitute the value in CanonicalizeEmailAddressReplace
154 # for the value in CanonicalizeEmailAddressMatch
155 # (These values are passed to the CanonicalizeEmailAddress subroutine in RT/User.pm)
156 # By default, that routine performs a s/$Match/$Replace/gi on any address passed to it
157
158 #Set($CanonicalizeEmailAddressMatch , '@subdomain\.example\.com$');
159 #Set($CanonicalizeEmailAddressReplace , '@example.com');
160
161 # set this to true and the create new user page will use the values that you
162 # enter in the form but use the function CanonicalizeUserInfo in User_Local.pm
163 Set($CanonicalizeOnCreate , 0);
164
165 # If $SenderMustExistInExternalDatabase is true, RT will refuse to
166 # create non-privileged accounts for unknown users if you are using
167 # the "LookupSenderInExternalDatabase" option.
168 # Instead, an error message will be mailed and RT will forward the
169 # message to $RTOwner.
170 #
171 # If you are not using $LookupSenderInExternalDatabase, this option
172 # has no effect.
173 #
174 # If you define an AutoRejectRequest template, RT will use this
175 # template for the rejection message.
176
177 Set($SenderMustExistInExternalDatabase , undef);
178
179 # }}}
180
181 # {{{ Outgoing mail configuration
182
183 # RT is designed such that any mail which already has a ticket-id associated
184 # with it will get to the right place automatically.
185
186 # $CorrespondAddress and $CommentAddress are the default addresses
187 # that will be listed in From: and Reply-To: headers of correspondence
188 # and comment mail tracked by RT, unless overridden by a queue-specific
189 # address.
190
191 Set($CorrespondAddress , 'RT_CorrespondAddressNotSet');
192
193 Set($CommentAddress , 'RT_CommentAddressNotSet');
194
195 #Sendmail Configuration
196
197 # $MailCommand defines which method RT will use to try to send mail
198 # We know that 'sendmailpipe' works fairly well.
199 # If 'sendmailpipe' doesn't work well for you, try 'sendmail'
200 #
201 # Note that you should remove the '-t' from $SendmailArguments
202 # if you use 'sendmail' rather than 'sendmailpipe'
203
204 Set($MailCommand , 'sendmailpipe');
205
206 # $SendmailArguments defines what flags to pass to $Sendmail
207 # assuming you picked 'sendmail' or 'sendmailpipe' as the $MailCommand above.
208 # If you picked 'sendmailpipe', you MUST add a -t flag to $SendmailArguments
209
210 # These options are good for most sendmail wrappers and workalikes
211 Set($SendmailArguments , "-oi -t");
212
213 # $SendmailBounceArguments defines what flags to pass to $Sendmail
214 # assuming RT needs to send an error (ie. bounce).
215
216 Set($SendmailBounceArguments , '-f "<>"');
217
218 # These arguments are good for sendmail brand sendmail 8 and newer
219 #Set($SendmailArguments,"-oi -t -ODeliveryMode=b -OErrorMode=m");
220
221 # If you selected 'sendmailpipe' above, you MUST specify the path
222 # to your sendmail binary in $SendmailPath.
223 # !! If you did not # select 'sendmailpipe' above, this has no effect!!
224 Set($SendmailPath , "/usr/sbin/sendmail");
225
226 # By default, RT sets the outgoing mail's "From:" header to
227 # "SenderName via RT".  Setting this option to 0 disables it.
228
229 Set($UseFriendlyFromLine , 1);
230
231 # sprintf() format of the friendly 'From:' header; its arguments
232 # are SenderName and SenderEmailAddress.
233 Set($FriendlyFromLineFormat , "\"%s via RT\" <%s>");
234
235 # RT can optionally set a "Friendly" 'To:' header when sending messages to
236 # Ccs or AdminCcs (rather than having a blank 'To:' header.
237
238 # This feature DOES NOT WORK WITH SENDMAIL[tm] BRAND SENDMAIL
239 # If you are using sendmail, rather than postfix, qmail, exim or some other MTA,
240 # you _must_ disable this option.
241
242 Set($UseFriendlyToLine , 0);
243
244 # sprintf() format of the friendly 'From:' header; its arguments
245 # are WatcherType and TicketId.
246 Set($FriendlyToLineFormat, "\"%s of $RT::rtname Ticket #%s\":;");
247
248 # By default, RT doesn't notify the person who performs an update, as they
249 # already know what they've done. If you'd like to change this behaviour,
250 # Set $NotifyActor to 1
251
252 Set($NotifyActor, 0);
253
254 # By default, RT records each message it sends out to its own internal database.# To change this behaviour, set $RecordOutgoingEmail to 0 
255
256 Set($RecordOutgoingEmail, 1);
257
258 # VERP support (http://cr.yp.to/proto/verp.txt)
259 # uncomment the following two directives to generate envelope senders
260 # of the form ${VERPPrefix}${originaladdress}@${VERPDomain}
261 # (i.e. rt-jesse=fsck.com@rt.example.com ) This currently only works
262 # with sendmail and sendmailppie.
263 # Set($VERPPrefix, 'rt-');
264 # Set($VERPDomain, $RT::Organization);
265
266 # }}}
267
268 # {{{ Logging
269
270 # Logging.  The default is to log anything except debugging
271 # information to syslog.  Check the Log::Dispatch POD for
272 # information about how to get things by syslog, mail or anything
273 # else, get debugging info in the log, etc.
274
275 #  It might generally make
276 # sense to send error and higher by email to some administrator.
277 # If you do this, be careful that this email isn't sent to this RT instance.
278
279 # the minimum level error that will be logged to the specific device.
280 # levels from lowest to highest:
281 #  debug info notice warning error critical alert emergency
282
283 #  Mail loops will generate a critical log message.
284 Set($LogToSyslog    , 'debug');
285 Set($LogToScreen    , 'error');
286 Set($LogToFile      , undef);
287 Set($LogDir, '@RT_LOG_PATH@');
288 Set($LogToFileNamed , "rt.log");    #log to rt.log
289
290 # If true generates stack traces to file log or screen
291 # never generates traces to syslog
292
293 Set($LogStackTraces , 0);
294
295 # On Solaris or UnixWare, set to ( socket => 'inet' ).  Options here
296 # override any other options RT passes to Log::Dispatch::Syslog.
297 # Other interesting flags include facility and logopt.  (See the
298 # Log::Dispatch::Syslog documentation for more information.)  (Maybe
299 # ident too, if you have multiple RT installations.)
300
301 @LogToSyslogConf = () unless (@LogToSyslogConf);
302
303 # RT has rudimentary SQL statement logging support if you have
304 # DBIx-SearchBuilder 1.31_1 or higher; simply set $StatementLog to be
305 # the level that you wish SQL statements to be logged at.
306 Set($StatementLog, undef);
307
308 # }}}
309
310 # {{{ Web interface configuration
311
312 # This determines the default stylesheet the RT web interface will use.
313 # RT ships with two valid values by default:
314 #
315 #   3.5-default     The totally new, default layout for RT 3.5
316 #   3.4-compat      A 3.4 compatibility stylesheet to make RT 3.5 look
317 #                   (mostly) like 3.4
318 #
319 # This value actually specifies a directory in share/html/NoAuth/css/
320 # from which RT will try to load the file main.css (which should
321 # @import any other files the stylesheet needs).  This allows you to
322 # easily and cleanly create your own stylesheets to apply to RT.
323
324 Set($WebDefaultStylesheet, '3.5-default');
325
326 # Define the directory name to be used for images in rt web
327 # documents.
328
329 # If you're putting the web ui somewhere other than at the root of
330 # your server, you should set $WebPath to the path you'll be 
331 # serving RT at.
332 # $WebPath requires a leading / but no trailing /.
333 #
334 # In most cases, you should leave $WebPath set to '' (an empty value).
335
336 Set($WebPath , "");
337
338 # If we're running as a superuser, run on port 80
339 # Otherwise, pick a high port for this user.
340
341 Set($WebPort , 80);# + ($< * 7274) % 32766 + ($< && 1024));
342
343 # This is the Scheme, server and port for constructing urls to webrt
344 # $WebBaseURL doesn't need a trailing /
345
346 Set($WebBaseURL , "http://localhost:$WebPort");
347
348 Set($WebURL , $WebBaseURL . $WebPath . "/");
349
350 # $WebImagesURL points to the base URL where RT can find its images.
351
352 Set($WebImagesURL , $WebPath . "/NoAuth/images/");
353
354 # $LogoURL points to the URL of the RT logo displayed in the web UI
355
356 Set($LogoURL , $WebImagesURL . "bplogo.gif");
357
358 # WebNoAuthRegex - What portion of RT's URLspace should not require
359 # authentication.
360 Set($WebNoAuthRegex, qr!^/rt(?:/+NoAuth/|
361                             /+REST/\d+\.\d+/NoAuth/)!x );
362
363 # For message boxes, set the entry box width and what type of wrapping
364 # to use.
365 #
366 # Default width: 72
367 Set($MessageBoxWidth , 72);
368
369 # Default wrapping: "HARD"  (choices "SOFT", "HARD")
370 Set($MessageBoxWrap, "HARD");
371
372 # Support implicit links in WikiText custom fields?  A true value
373 # causes InterCapped or ALLCAPS words in WikiText fields to
374 # automatically become links to searches for those words.  If used on
375 # RTFM articles, it links to the RTFM article with that name.
376 Set($WikiImplicitLinks, 0);
377
378 # if TrustHTMLAttachments is not defined, we will display them
379 # as text. This prevents malicious HTML and javascript from being
380 # sent in a request (although there is probably more to it than that)
381 Set($TrustHTMLAttachments , undef);
382
383 # Should RT redistribute correspondence that it identifies as
384 # machine generated? A true value will do so; setting this to '0'
385 # will cause no such messages to be redistributed.
386 # You can also use 'privileged' (the default), which will redistribute
387 # only to privileged users. This helps to protect against malformed
388 # bounces and loops caused by autocreated requestors with bogus addresses.
389 Set($RedistributeAutoGeneratedMessages, 'privileged');
390
391 # If PreferRichText is set to a true value, RT will show HTML/Rich text
392 # messages in preference to their plaintext alternatives. RT "scrubs" the 
393 # html to show only a minimal subset of HTML to avoid possible contamination
394 # by cross-site-scripting attacks.
395 Set($PreferRichText, undef);
396
397 # If $WebExternalAuth is defined, RT will defer to the environment's
398 # REMOTE_USER variable.
399
400 Set($WebExternalAuth , undef);
401
402 # If $WebFallbackToInternalAuth is undefined, the user is allowed a chance
403 # of fallback to the login screen, even if REMOTE_USER failed.
404
405 Set($WebFallbackToInternalAuth , undef);
406
407 # $WebExternalGecos means to match 'gecos' field as the user identity);
408 # useful with mod_auth_pwcheck and IIS Integrated Windows logon.
409
410 Set($WebExternalGecos , undef);
411
412 # $WebExternalAuto will create users under the same name as REMOTE_USER
413 # upon login, if it's missing in the Users table.
414
415 Set($WebExternalAuto , undef);
416
417 # $WebSessionClass is the class you wish to use for managing Sessions.
418 # It defaults to use your SQL database, but if you are using MySQL 3.x and
419 # plans to use non-ascii Queue names, uncomment and add this line to
420 # RT_SiteConfig.pm will prevent session corruption.
421
422 # Set($WebSessionClass , 'Apache::Session::File');
423
424
425 # By default, RT's session cookie isn't marked as "secure" Some web browsers 
426 # will treat secure cookies more carefully than non-secure ones, being careful
427 # not to write them to disk, only send them over an SSL secured connection 
428 # and so on. To enable this behaviour, set # $WebSecureCookies to a true value. 
429 # NOTE: You probably don't want to turn this on _unless_ users are only connecting
430 # via SSL encrypted HTTP connections.
431
432 Set($WebSecureCookies, 0);
433
434
435 # By default, RT clears its database cache after every page view.
436 # This ensures that you've always got the most current information 
437 # when working in a multi-process (mod_perl or FastCGI) Environment
438 # Setting $WebFlushDbCacheEveryRequest to '0' will turn this off,
439 # which will speed RT up a bit, at the expense of a tiny bit of data 
440 # accuracy.
441
442 Set($WebFlushDbCacheEveryRequest, '1');
443
444
445 # $MaxInlineBody is the maximum attachment size that we want to see
446 # inline when viewing a transaction. 13456 is a random sane-sounding
447 # default.
448
449 Set($MaxInlineBody, 13456);
450
451 # $DefaultSummaryRows is default number of rows displayed in for search
452 # results on the frontpage.
453
454 Set($DefaultSummaryRows, 10);
455
456 # By default, RT shows newest transactions at the bottom of the ticket
457 # history page, if you want see them at the top set this to '0'.
458
459 Set($OldestTransactionsFirst, '1');
460
461 # By default, RT shows images attached to incoming (and outgoing) ticket updates
462 # inline. Set this variable to 0 if you'd like to disable that behaviour
463
464 Set($ShowTransactionImages, 1);
465
466
467 # $HomepageComponents is an arrayref of allowed components on a user's
468 # customized homepage ("RT at a glance").
469
470 Set($HomepageComponents, [qw(QuickCreate Quicksearch MyAdminQueues MySupportQueues MyReminders  RefreshHomepage)]);
471
472 # @MasonParameters is the list of parameters for the constructor of
473 # HTML::Mason's Apache or CGI Handler.  This is normally only useful
474 # for debugging, eg. profiling individual components with:
475 #     use MasonX::Profiler; # available on CPAN
476 #     @MasonParameters = (preamble => 'my $p = MasonX::Profiler->new($m, $r);');
477
478 @MasonParameters = () unless (@MasonParameters);
479
480 # $DefaultSearchResultFormat is the default format for RT search results
481 Set ($DefaultSearchResultFormat, qq{
482    '<B><A HREF="$RT::WebPath/Ticket/Display.html?id=__id__">__id__</a></B>/TITLE:#',
483    '<B><A HREF="$RT::WebPath/Ticket/Display.html?id=__id__">__Subject__</a></B>/TITLE:Subject',
484    Status,
485    QueueName, 
486    OwnerName, 
487    Priority, 
488    '__NEWLINE__',
489    '', 
490    '<small>__Requestors__</small>',
491    '<small>__CreatedRelative__</small>',
492    '<small>__ToldRelative__</small>',
493    '<small>__LastUpdatedRelative__</small>',
494    '<small>__TimeLeft__</small>'});
495
496 # If $SuppressInlineTextFiles is set to a true value, then uploaded
497 # text files (text-type attachments with file names) are prevented
498 # from being displayed in-line when viewing a ticket's history.
499
500 Set($SuppressInlineTextFiles, undef);
501
502 # If $DontSearchFileAttachments is set to a true value, then uploaded
503 # files (attachments with file names) are not searched during full-content
504 # ticket searches.
505
506 Set($DontSearchFileAttachments, undef);
507
508
509 # }}}
510
511 # {{{ RT UTF-8 Settings
512
513 # An array that contains languages supported by RT's internationalization
514 # interface.  Defaults to all *.po lexicons; setting it to qw(en ja) will make
515 # RT bilingual instead of multilingual, but will save some memory.
516
517 @LexiconLanguages = qw(*) unless (@LexiconLanguages);
518
519 # An array that contains default encodings used to guess which charset
520 # an attachment uses if not specified.  Must be recognized by
521 # Encode::Guess.
522
523 @EmailInputEncodings = qw(utf-8 iso-8859-1 us-ascii) unless (@EmailInputEncodings);
524
525 # The charset for localized email.  Must be recognized by Encode.
526
527 Set($EmailOutputEncoding , 'utf-8');
528
529 # }}}
530
531 # {{{ RT Date Handling Options (for Time::ParseDate)
532
533 # Set this to 1 if your local date convention looks like "dd/mm/yy"
534 # instead of "mm/dd/yy".
535
536 Set($DateDayBeforeMonth , 1);
537
538 # Should "Tuesday" default to meaning "Next Tuesday" or "Last Tuesday"?
539 # Set to 0 for "Next" or 1 for "Last".
540
541 Set($AmbiguousDayInPast , 1);
542
543 # }}}
544
545 # {{{ Miscellaneous RT Settings
546
547 # You can define new statuses and even reorder existing statuses here.
548 # WARNING. DO NOT DELETE ANY OF THE DEFAULT STATUSES. If you do, RT
549 # will break horribly. The statuses you add must be no longer than
550 # 10 characters.
551
552 @ActiveStatus = qw(new open stalled) unless @ActiveStatus;
553 @InactiveStatus = qw(resolved rejected deleted) unless @InactiveStatus;
554
555 # Backward compatability setting. Add/Delete Link used to record one
556 # transaction and run one scrip. Set this value to 1 if you want
557 # only one of the link transactions to have scrips run.
558 Set($LinkTransactionsRun1Scrip , 0);
559
560 # When this feature is enabled an user need ModifyTicket right on both
561 # tickets to link them together, otherwise he can have right on any of
562 # two.
563 Set($StrictLinkACL, 1);
564
565 # }}}
566
567
568 # {{{ Development Mode
569 #
570 # RT comes with a "Development mode" setting. 
571 # This setting, as a convenience for developers, turns on 
572 # all sorts of development options that you most likely don't want in 
573 # production:
574 #
575 # * Turns off Mason's 'static_source' directive. By default, you can't 
576 #   edit RT's web ui components on the fly and have RT magically pick up
577 #   your changes. (It's a big performance hit)
578 #
579 #  * More to come
580 #
581
582 Set($DevelMode, '@RT_DEVEL_MODE@');
583
584 # }}}
585
586
587 1;