summaryrefslogtreecommitdiff
path: root/rt/sbin
diff options
context:
space:
mode:
Diffstat (limited to 'rt/sbin')
-rw-r--r--rt/sbin/rt-attributes-viewer.in2
-rw-r--r--rt/sbin/rt-clean-sessions.in2
-rw-r--r--rt/sbin/rt-dump-metadata.in2
-rw-r--r--rt/sbin/rt-email-dashboards.in11
-rw-r--r--rt/sbin/rt-email-digest.in2
-rwxr-xr-xrt/sbin/rt-email-group-admin.in3
-rw-r--r--rt/sbin/rt-fulltext-indexer.in20
-rw-r--r--rt/sbin/rt-importer.in2
-rw-r--r--rt/sbin/rt-preferences-viewer.in2
-rw-r--r--rt/sbin/rt-serializer.in2
-rw-r--r--rt/sbin/rt-server.fcgi.in2
-rw-r--r--rt/sbin/rt-server.in2
-rw-r--r--rt/sbin/rt-setup-database.in2
-rw-r--r--rt/sbin/rt-setup-fulltext-index.in2
-rwxr-xr-xrt/sbin/rt-shredder.in3
-rw-r--r--rt/sbin/rt-test-dependencies.in9
-rw-r--r--rt/sbin/rt-validate-aliases.in2
-rw-r--r--rt/sbin/rt-validator.in2
-rw-r--r--rt/sbin/standalone_httpd.in2
19 files changed, 47 insertions, 27 deletions
diff --git a/rt/sbin/rt-attributes-viewer.in b/rt/sbin/rt-attributes-viewer.in
index 03141581c..d6e3de417 100644
--- a/rt/sbin/rt-attributes-viewer.in
+++ b/rt/sbin/rt-attributes-viewer.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
diff --git a/rt/sbin/rt-clean-sessions.in b/rt/sbin/rt-clean-sessions.in
index beed22a19..bdfd312f2 100644
--- a/rt/sbin/rt-clean-sessions.in
+++ b/rt/sbin/rt-clean-sessions.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
diff --git a/rt/sbin/rt-dump-metadata.in b/rt/sbin/rt-dump-metadata.in
index 2b5747645..c212749d6 100644
--- a/rt/sbin/rt-dump-metadata.in
+++ b/rt/sbin/rt-dump-metadata.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
diff --git a/rt/sbin/rt-email-dashboards.in b/rt/sbin/rt-email-dashboards.in
index 1daba86b7..e828002e8 100644
--- a/rt/sbin/rt-email-dashboards.in
+++ b/rt/sbin/rt-email-dashboards.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
@@ -70,7 +70,7 @@ BEGIN { # BEGIN RT CMD BOILERPLATE
my %opts;
use Getopt::Long;
GetOptions( \%opts,
- "help|h", "dryrun", "time=i", "epoch=i", "all"
+ "help|h", "dryrun", "time=i", "epoch=i", "all", "log=s"
);
if ($opts{'help'}) {
@@ -86,6 +86,9 @@ RT::Interface::CLI->import(qw{ loc });
# Load the config file
RT::LoadConfig();
+# adjust logging to the screen according to options
+RT->Config->Set( LogToSTDERR => $opts{log} ) if $opts{log};
+
# Connect to the database and get RT::SystemUser and RT::Nobody loaded
RT::Init();
@@ -156,6 +159,10 @@ Back-compat for --time SECONDS.
Ignore subscription frequency when considering each dashboard (should only be
used with --dryrun for testing and debugging)
+=item --log LEVEL
+
+Adjust LogToSTDERR config option
+
=back
=cut
diff --git a/rt/sbin/rt-email-digest.in b/rt/sbin/rt-email-digest.in
index 8dade9441..52fa45084 100644
--- a/rt/sbin/rt-email-digest.in
+++ b/rt/sbin/rt-email-digest.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
diff --git a/rt/sbin/rt-email-group-admin.in b/rt/sbin/rt-email-group-admin.in
index 17a0850be..e50865c8f 100755
--- a/rt/sbin/rt-email-group-admin.in
+++ b/rt/sbin/rt-email-group-admin.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
@@ -46,7 +46,6 @@
# those contributions and any derivatives thereof.
#
# END BPS TAGGED BLOCK }}}
-
=head1 NAME
rt-email-group-admin - Command line tool for administrating NotifyGroup actions
diff --git a/rt/sbin/rt-fulltext-indexer.in b/rt/sbin/rt-fulltext-indexer.in
index bd55adb9a..ceffc97b8 100644
--- a/rt/sbin/rt-fulltext-indexer.in
+++ b/rt/sbin/rt-fulltext-indexer.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
@@ -99,6 +99,8 @@ if ( !flock main::DATA, LOCK_EX | LOCK_NB ) {
}
}
+my $max_size = RT->Config->Get('MaxFulltextAttachmentSize');
+
my $db_type = RT->Config->Get('DatabaseType');
my $fts_config = $ENV{RT_FTS_CONFIG} ? JSON::from_json($ENV{RT_FTS_CONFIG})
: RT->Config->Get('FullTextSearch') || {};
@@ -201,8 +203,16 @@ sub process_bulk_insert {
my ($attachments) = @_;
my @insert;
my $found = 0;
+
while ( my $a = $attachments->Next ) {
debug("Found attachment #". $a->id );
+ if ( $max_size and $a->ContentLength > $max_size ){
+ debug("Attachment #" . $a->id . " is " . $a->ContentLength .
+ " bytes which is larger than configured MaxFulltextAttachmentSize " .
+ " of " . $max_size . ", skipping");
+ next;
+ }
+
my $text = $a->Content // "";
HTML::Entities::decode_entities($text) if $a->ContentType eq "text/html";
push @insert, $text, $a->id;
@@ -304,9 +314,17 @@ sub process_pg_update {
attachment_loop( sub {
my ($attachments) = @_;
my @insert;
+
while ( my $a = $attachments->Next ) {
debug("Found attachment #". $a->id );
+ if ( $max_size and $a->ContentLength > $max_size ){
+ debug("Attachment #" . $a->id . " is " . $a->ContentLength .
+ " bytes which is larger than configured MaxFulltextAttachmentSize " .
+ " of " . $max_size . ", skipping");
+ next;
+ }
+
my $text = $a->Content // "";
HTML::Entities::decode_entities($text) if $a->ContentType eq "text/html";
diff --git a/rt/sbin/rt-importer.in b/rt/sbin/rt-importer.in
index 8b5bd3230..6d3cda5ea 100644
--- a/rt/sbin/rt-importer.in
+++ b/rt/sbin/rt-importer.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
diff --git a/rt/sbin/rt-preferences-viewer.in b/rt/sbin/rt-preferences-viewer.in
index 64d8e9ce9..b06a2bffc 100644
--- a/rt/sbin/rt-preferences-viewer.in
+++ b/rt/sbin/rt-preferences-viewer.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
diff --git a/rt/sbin/rt-serializer.in b/rt/sbin/rt-serializer.in
index 0e0174472..c008e78ba 100644
--- a/rt/sbin/rt-serializer.in
+++ b/rt/sbin/rt-serializer.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
diff --git a/rt/sbin/rt-server.fcgi.in b/rt/sbin/rt-server.fcgi.in
index 8be361395..fb4aed926 100644
--- a/rt/sbin/rt-server.fcgi.in
+++ b/rt/sbin/rt-server.fcgi.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
diff --git a/rt/sbin/rt-server.in b/rt/sbin/rt-server.in
index 8be361395..fb4aed926 100644
--- a/rt/sbin/rt-server.in
+++ b/rt/sbin/rt-server.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
diff --git a/rt/sbin/rt-setup-database.in b/rt/sbin/rt-setup-database.in
index caeaebae3..9d5a16d24 100644
--- a/rt/sbin/rt-setup-database.in
+++ b/rt/sbin/rt-setup-database.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
diff --git a/rt/sbin/rt-setup-fulltext-index.in b/rt/sbin/rt-setup-fulltext-index.in
index bffd6dd87..01b0cb8f6 100644
--- a/rt/sbin/rt-setup-fulltext-index.in
+++ b/rt/sbin/rt-setup-fulltext-index.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
diff --git a/rt/sbin/rt-shredder.in b/rt/sbin/rt-shredder.in
index a6cb6f47d..c3f2aa8ac 100755
--- a/rt/sbin/rt-shredder.in
+++ b/rt/sbin/rt-shredder.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
@@ -46,7 +46,6 @@
# those contributions and any derivatives thereof.
#
# END BPS TAGGED BLOCK }}}
-
=head1 NAME
rt-shredder - Script which wipe out tickets from RT DB
diff --git a/rt/sbin/rt-test-dependencies.in b/rt/sbin/rt-test-dependencies.in
index 8fbce77c3..144dc8b0a 100644
--- a/rt/sbin/rt-test-dependencies.in
+++ b/rt/sbin/rt-test-dependencies.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
@@ -239,6 +239,7 @@ Mail::Mailer 1.57
MIME::Entity 5.504
Module::Refresh 0.03
Module::Versions::Report 1.05
+Encode 2.64
Net::CIDR
Plack 1.0002
Regexp::Common
@@ -312,14 +313,9 @@ FCGI::ProcManager
.
$deps{'MODPERL1'} = [ text_to_hash( << '.') ];
-Apache::DBI 0.92
Apache::Request
.
-$deps{'MODPERL2'} = [ text_to_hash( << '.') ];
-Apache::DBI
-.
-
$deps{'MYSQL'} = [ text_to_hash( << '.') ];
DBD::mysql 2.1018
.
@@ -382,6 +378,7 @@ Pod::Simple 3.24
my %AVOID = (
'DBD::Oracle' => [qw(1.23)],
'Devel::StackTrace' => [qw(1.28 1.29)],
+ 'DateTime::Locale' => [qw(1.00 1.01)]
);
if ($args{'download'}) {
diff --git a/rt/sbin/rt-validate-aliases.in b/rt/sbin/rt-validate-aliases.in
index 93e28db4d..a7ff4b35f 100644
--- a/rt/sbin/rt-validate-aliases.in
+++ b/rt/sbin/rt-validate-aliases.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
diff --git a/rt/sbin/rt-validator.in b/rt/sbin/rt-validator.in
index 16432a31b..2a62a6f88 100644
--- a/rt/sbin/rt-validator.in
+++ b/rt/sbin/rt-validator.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
diff --git a/rt/sbin/standalone_httpd.in b/rt/sbin/standalone_httpd.in
index 8be361395..fb4aed926 100644
--- a/rt/sbin/standalone_httpd.in
+++ b/rt/sbin/standalone_httpd.in
@@ -3,7 +3,7 @@
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-2016 Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)