[rt-users] Fwd: RT 3.8.8 - ParseNewMessageForTicketCcs RTAddressRegexp issue
I originally posted the following message, back in March (apologies if re-posting is frowned upon): -=-=-=-=-=-=-=- I had a quick scan back through the message-archive, but couldn't find anything that answers this issue fully: Have tried to get RT parsing new inbound emails and adding any CC'd addresses as TicketCC entries (excluding the queue address itself) working properly, to save time on manually adding CC'd addresses to each ticket, when required, but am having a few issues with getting it working properly. The parsing part seems to work OK, in that any new tickets emailed into a queue have the CC'd addresses added to the TicketCC field of the ticket. However, despite adding an RTAddressRegexp entry for the queue I was sending a ticket into (I tried it with regex and with the exact email-address of the queue), it still added the queue-address as a CC. Is there any extra config that needs to be added, to get this working properly, as I only had the ParseNewMessageForTicketCcs flag enabled, and then a few RTAddressRegexp entries to cover all of the RT queues? -=-=-=-=-=-=-=- I had a reply, asking for the config used, which was posted as below: -=-=-=-=-=-=-=- Config is as below (added as a new file within the RT_SiteConfig.d folder - was only testing against one queue to start with), I've redacted the domain to try to prevent harvesting: ### start ### # CONFIG CHANGES FOR AUTO-ADDING CC ADDRESSES AS REQUESTORS # First, enable RT to parse new messages for CC'd addresses Set($ParseNewMessageForTicketCcs , 1); # Now, restrict it from using any addresses on the domain Set($RTAddressRegexp , '^[a-z\.\-]+\@domainname.com$'); ### end ### Have also tried the following entries: Set($RTAddressRegexp , '^[a-z.-]+\@domainname.com$'); or Set($RTAddressRegexp , '^noc\-tasks@domainname.com$'); or: Set($RTAddressRegexp , '^noc-tasks@domainname.com$'); All of the above failed to prevent the new ticket from having the queue address added as a CC address, yet the parsing is working fine in that it adds new addresses to the CC-list within RT. -=-=-=-=-=-=-=- After that, I received no further replies, so just wanted to drop this message back into the list, just in case my reply was missed. Regards, -- Dan Baines Systems Administrator, Zen Internet T: 0845 058 9020
Re: [rt-users] Keep some HTML tags attributes
Hello list, I enabled HTML for my templates and in SiteConfig enabled Set($PreferRichText, true); Set($TrustHTMLAttachments, 1); But, I'm looking for a way to allow some HTML attributes into RT tickets, specifically to allow the dir=RTL attribute right now RT strip some of the attributes e.g it's not removing all the attributes of the font tag from where can I control this behavior ? Thanks, *--- Rabin Yasharzadehe*
Re: [rt-users] Fwd: RT 3.8.8 - ParseNewMessageForTicketCcs RTAddressRegexp issue
On 05/01/2012 04:37 AM, Dan Baines wrote: Config is as below (added as a new file within the RT_SiteConfig.d folder - was only testing against one queue to start with), I've redacted the domain to try to prevent harvesting: ### start ### # CONFIG CHANGES FOR AUTO-ADDING CC ADDRESSES AS REQUESTORS # First, enable RT to parse new messages for CC'd addresses Set($ParseNewMessageForTicketCcs , 1); # Now, restrict it from using any addresses on the domain Set($RTAddressRegexp , '^[a-z\.\-]+\@domainname.com$'); ### end ### Have also tried the following entries: Set($RTAddressRegexp , '^[a-z.-]+\@domainname.com$'); or Set($RTAddressRegexp , '^noc\-tasks@domainname.com$'); or: Set($RTAddressRegexp , '^noc-tasks@domainname.com$'); Please show us the actual config, not a censored version with domainname.com in it. Otherwise we can't actually say whether or not your regex is wrong since you may have censored the incorrect part. Please also include an example email as sent to RT that exhibits the problem for you so we can see the address it's supposed to match. Thomas
[rt-users] Deleting tickets recursively
I have a script that creates a ticket, then one or more child tickets of that ticket in a different queue, and then one or more child tickets of them in yet another queue. I also wrote a test to call that script and then verify that the expected tickets exist, etc. However, when I try to clean up at the end of the test, I have a sub that takes the top level ticket and recurses down through the children trying to delete them, but unfortunately only the top level one gets deleted. Here's the code: sub recursiveDelete { my $ticketId = shift; my $ticket = RT::Ticket-new(RT::SystemUser); $ticket-Load($ticketId); my $children = $ticket-Members; while (my $child = $children-Next) { recursiveDelete($child-id); } $ticket-Delete; } I traced through it in the perl debugger, and the problem appears to be in Ticket::SetStatus('deleted') where it calls $self-__Value('status') and it returns 'deleted'. So it thinks it's already deleted and doesn't change the status. Any suggestions why this is happening? -- http://www.linkedin.com/in/paultomblin http://careers.stackoverflow.com/ptomblin
Re: [rt-users] Keep some HTML tags attributes
On 05/01/2012 07:21 AM, Rabin Yasharzadehe wrote: Hello list, I enabled HTML for my templates and in SiteConfig enabled Set($PreferRichText, true); Set($TrustHTMLAttachments, 1); But, I'm looking for a way to allow some HTML attributes into RT tickets, specifically to allow the dir=RTL attribute RT 4.0.6 will allow these attributes. https://github.com/bestpractical/rt/commit/a625c19e right now RT strip some of the attributes e.g it's not removing all the attributes of the font tag from where can I control this behavior ? You don't say what RT version you're using, and the answer depends on that. Thomas
Re: [rt-users] Deleting tickets recursively
On Tue, May 1, 2012 at 9:45 AM, Paul Tomblin ptomb...@xcski.com wrote: recursiveDelete($child-id); Never mind, figured it out. That should be recursiveDelete($child-BaseObj-id); -- http://www.linkedin.com/in/paultomblin http://careers.stackoverflow.com/ptomblin
[rt-users] Nginx + R-T 3.8.10 + static FastCGI on CentOS 6.2: Can't start FastCGI service
Hello, all. Having some difficulty with a FastCGI setup. Summary: When I attempt to start the R-T FastCGI service, it does not start. If I manually execute 'perl /usr/sbin/mason_handler.fcgi', it *does* run correctly and emits the html for the R-T login page. Detail: It is a site standard that web apps must be fronted by nginx and run as a FastCGI process on a socket. Our site standard Linux is CentOS 6.2 x64. RT-3.8.10 is packaged for CentOS by the EPEL group, but starts with the assumption that you'll be running under apache and using PostgreSQL for the back end DB (neither of which are true here). I have been trying to set up an nginx+FastCGI stack for R-T, but although there's documentation around the 'net, it's either extremely out of date or is Ubuntu-specific. I have tried modifying things to match CentOS without success. What I have done so far: Disabled SELinux (off by standard on internal servers). Installed the following packages (mix of EPEL and CentOS) and their prereqs: mysql-server perl-FCGI perl-CPAN make rt3 rt3-mailgate Disabled the httpd service. Created MySQL database for R-T, assigned privileges, and preloaded with data from a testing R-T instance (running successfully on Ubuntu). Installed the CommandByMail extension (this requires make and perl-CPAN). Setup the /etc/rt3/RT_SiteConfig.pm: 8-8- # dynamically find out the current timezone my $zone = UTC; $zone=`/bin/cat /etc/timezone` if -f /etc/timezone; chomp $zone; Set($Timezone, $zone); # THE BASICS: Set($rtname, 'tt.our.site'); Set($Organization, 'our.site'); Set($CorrespondAddress , 'helpd...@our.site'); Set($CommentAddress , 'helpdesk-comm...@our.site'); # THE WEBSERVER: Set($WebPath , /); Set($WebBaseURL , http://tt.our.site;); # THE DATABASE: # map from dbconfig-common database types to their names as known by RT my %typemap = ( mysql = 'mysql', pgsql = 'Pg', sqlite3 = 'SQLite', ); Set($DatabaseType, $typemap{mysql} || UNKNOWN); Set($DatabaseHost, 'localhost'); Set($DatabasePort, ''); Set($DatabaseUser , 'rt'); Set($DatabasePassword , 'Password'); # SQLite needs a special case, since $DatabaseName must be a full pathname my $dbc_dbname = 'rtdb'; if ( mysql eq sqlite3 ) { Set ($DatabaseName, '' . '/' . $dbc_dbname); } else { Set ($DatabaseName, $dbc_dbname); } # EXTENSIONS # CommandByEmail Set(@MailPlugins, qw(Auth::MailFrom Filter::TakeAction)); Set(@Plugins,(qw(RT::Extension::CommandByMail))); Set($CommandByMailGroup, 9804); 1; --88--- Set up the /etc/nginx/conf.d/tt.our.site.conf file: --88--- server { listen 80; server_name tt.our.site; root/usr/share/rt3/html; location / { index index.html; fastcgi_passunix:/var/run/rt/rt.sock; include /etc/nginx/fastcgi.conf; fastcgi_param PATH_INFO $fastcgi_script_name; } location ~* .+\.(html|js|css)$ { index index.html; fastcgi_passunix:/var/run/rt/rt.sock; include /etc/nginx/fastcgi.conf; fastcgi_param PATH_INFO $fastcgi_script_name; } location /NoAuth/images/ { alias /usr/share/rt3/html/NoAuth/images/; } } ---8-8- Created an initrc file for the rt3 service, /etc/init.d/rt3: ---8-8- #!/bin/sh # rt3 - this script starts and stops the perl-FCGI RT3 daemon # # chkconfig: - 85 15 # description: RT3 is a request/issue handling system written in perl served as a FastCGI module. RTPATH=/usr/share/rt3/ RTUSER=nginx FCGI_SOCKET_PATH=/var/run/rt3/rt3.sock case $1 in start) echo -n Starting RT: mason_handler.fcgi cd $RTPATH export FCGI_SOCKET_PATH su $RTUSER -c perl /usr/sbin/mason_handler.fcgi echo ;; stop) echo -n Stopping RT: PIDS=`ps axww | awk '/[m]ason_handler.fcgi/ { print $1}'` if [ -n $PIDS ] then echo -n kill -TERM $PIDS kill $PIDS echo else echo RT not running fi ;; restart|force-reload) $0 stop $0 start ;; *) echo Usage: /etc/init.d/rt3 { stop | start | restart } exit 1 ;; esac 8---8-- Permissions on /usr/share/rt3 are 755 nginx:nginx all the way down Permissions on /var/run/rt3 are 755 nginx:nginx As I mentioned, if I run 'chkconfig rt3 on; service rt3 start' then the process doesn't actually start (possibly it's starting and
[rt-users] How to shred old queues completely
Hi all, I'm looking at shredding everything with respect to a few older queues. I've read the documentation on the wiki and I'm not entirely sure I understand all the things I need to look for to essentially clean up everything to do with these old queues. What other things should I be shredding besides the following: - tickets with Queue='queuename'? - users with no_tickets=1 Specifically, how can I grab all the objects that are not being used anymore after the ticket cleanup, and user cleanup(ie custom fields, groups, the queue record itself etc)? Do I have to know them by name? Is there something like Objects with no reference or something like that? I'm guessing it is more complex than that... but I figured I would see what the list has to say, maybe some folks have found a good way of scripting something :D Thanks! Mike. -- Mike Johnson Datatel Programmer/Analyst Northern Ontario School of Medicine 955 Oliver Road Thunder Bay, ON P7B 5E1 Phone: (807) 766-7331 Email: mike.john...@nosm.ca
Re: [rt-users] Nginx + R-T 3.8.10 + static FastCGI on CentOS 6.2: Can't start FastCGI service
On Tue, May 1, 2012 at 19:32, Chris Doherty chris.dohe...@ca.flextronics.com wrote: Hello, all. Having some difficulty with a FastCGI setup. Summary: When I attempt to start the R-T FastCGI service, it does not start. If I manually execute 'perl /usr/sbin/mason_handler.fcgi', it *does* run correctly and emits the html for the R-T login page. It's one handler, not complete fcgi server. Apache and other web servers have solutions to spawn pool of FCGI processes and serve them requests. RT 3.8 has bin/fastcgi_server that is actually an external fcgi server you can use with nginx without additional spawner. For 4.0 you can use RT-Extension-Nginx. You can use this as a reference to setup 3.8. Detail: It is a site standard that web apps must be fronted by nginx and run as a FastCGI process on a socket. Our site standard Linux is CentOS 6.2 x64. RT-3.8.10 is packaged for CentOS by the EPEL group, but starts with the assumption that you'll be running under apache and using PostgreSQL for the back end DB (neither of which are true here). I have been trying to set up an nginx+FastCGI stack for R-T, but although there's documentation around the 'net, it's either extremely out of date or is Ubuntu-specific. I have tried modifying things to match CentOS without success. What I have done so far: Disabled SELinux (off by standard on internal servers). Installed the following packages (mix of EPEL and CentOS) and their prereqs: mysql-server perl-FCGI perl-CPAN make rt3 rt3-mailgate Disabled the httpd service. Created MySQL database for R-T, assigned privileges, and preloaded with data from a testing R-T instance (running successfully on Ubuntu). Installed the CommandByMail extension (this requires make and perl-CPAN). Setup the /etc/rt3/RT_SiteConfig.pm: 8-8- # dynamically find out the current timezone my $zone = UTC; $zone=`/bin/cat /etc/timezone` if -f /etc/timezone; chomp $zone; Set($Timezone, $zone); # THE BASICS: Set($rtname, 'tt.our.site'); Set($Organization, 'our.site'); Set($CorrespondAddress , 'helpd...@our.site'); Set($CommentAddress , 'helpdesk-comm...@our.site'); # THE WEBSERVER: Set($WebPath , /); Set($WebBaseURL , http://tt.our.site;); # THE DATABASE: # map from dbconfig-common database types to their names as known by RT my %typemap = ( mysql = 'mysql', pgsql = 'Pg', sqlite3 = 'SQLite', ); Set($DatabaseType, $typemap{mysql} || UNKNOWN); Set($DatabaseHost, 'localhost'); Set($DatabasePort, ''); Set($DatabaseUser , 'rt'); Set($DatabasePassword , 'Password'); # SQLite needs a special case, since $DatabaseName must be a full pathname my $dbc_dbname = 'rtdb'; if ( mysql eq sqlite3 ) { Set ($DatabaseName, '' . '/' . $dbc_dbname); } else { Set ($DatabaseName, $dbc_dbname); } # EXTENSIONS # CommandByEmail Set(@MailPlugins, qw(Auth::MailFrom Filter::TakeAction)); Set(@Plugins,(qw(RT::Extension::CommandByMail))); Set($CommandByMailGroup, 9804); 1; --88--- Set up the /etc/nginx/conf.d/tt.our.site.conf file: --88--- server { listen 80; server_name tt.our.site; root /usr/share/rt3/html; location / { index index.html; fastcgi_pass unix:/var/run/rt/rt.sock; include /etc/nginx/fastcgi.conf; fastcgi_param PATH_INFO $fastcgi_script_name; } location ~* .+\.(html|js|css)$ { index index.html; fastcgi_pass unix:/var/run/rt/rt.sock; include /etc/nginx/fastcgi.conf; fastcgi_param PATH_INFO $fastcgi_script_name; } location /NoAuth/images/ { alias /usr/share/rt3/html/NoAuth/images/; } } ---8-8- Created an initrc file for the rt3 service, /etc/init.d/rt3: ---8-8- #!/bin/sh # rt3 - this script starts and stops the perl-FCGI RT3 daemon # # chkconfig: - 85 15 # description: RT3 is a request/issue handling system written in perl served as a FastCGI module. RTPATH=/usr/share/rt3/ RTUSER=nginx FCGI_SOCKET_PATH=/var/run/rt3/rt3.sock case $1 in start) echo -n Starting RT: mason_handler.fcgi cd $RTPATH export FCGI_SOCKET_PATH su $RTUSER -c perl /usr/sbin/mason_handler.fcgi echo ;; stop) echo -n Stopping RT: PIDS=`ps axww | awk '/[m]ason_handler.fcgi/ { print $1}'` if [ -n $PIDS ] then echo -n kill -TERM $PIDS kill $PIDS echo else echo RT not running fi ;;
[rt-users] rt-email-digest -m daily results in blank email?
Running the command rt-email-digest -m daily results in a blank email being delivered to me No Subject No Body Perhaps I'm missing a template or something? RT 4.0.1 Debian 4.3x
Re: [rt-users] rt-email-digest -m daily results in blank email?
Alright I think I found the issue, my Template Email Digest is blank, can someone attach theirs so i can copy it? -Original Message- From: Tony Monfiletto Sent: Tuesday, May 01, 2012 2:55 PM To: 'rt-users@lists.bestpractical.com' Subject: rt-email-digest -m daily results in blank email? Running the command rt-email-digest -m daily results in a blank email being delivered to me No Subject No Body Perhaps I'm missing a template or something? RT 4.0.1 Debian 4.3x
Re: [rt-users] rt-email-digest -m daily results in blank email?
Nevermind I was finally able to pull this out of the anals of the internet Subject: RT Email Digest { $Argument }
[rt-users] no auto reply
hello, We have an RT queue setup from an automated monitoring system. There's no point in sending return emails to the originating address as the 'reply-to' address is invalid and will generate a bounce. Is there any way to have RT not send a reply at all and just add a ticket to the queue? Thanks Tim -- GPG me!! gpg --keyserver pool.sks-keyservers.net --recv-keys F186197B
Re: [rt-users] no auto reply
Create a blank Autoreply template for that queue. -Patrick -Original Message- From: rt-users-boun...@lists.bestpractical.com [mailto:rt-users-boun...@lists.bestpractical.com] On Behalf Of Tim Dunphy Sent: Tuesday, May 01, 2012 2:45 PM To: rt-users@lists.bestpractical.com Subject: [rt-users] no auto reply hello, We have an RT queue setup from an automated monitoring system. There's no point in sending return emails to the originating address as the 'reply-to' address is invalid and will generate a bounce. Is there any way to have RT not send a reply at all and just add a ticket to the queue? Thanks Tim -- GPG me!! gpg --keyserver pool.sks-keyservers.net --recv-keys F186197B
Re: [rt-users] Keep some HTML tags attributes
Thank you for your reply, Sorry for now mentioning this before, I just finish to upgrade our old RT system from v3.6.7 to the latest 4.0.5 and we really liked to use all the new HTML features that this new release come with. I just patched the mention file in your link, and it WORKS, I'm really grateful for your quick reply. *--- Rabin Yasharzadehe* On Tue, May 1, 2012 at 4:46 PM, Thomas Sibley t...@bestpractical.com wrote: On 05/01/2012 07:21 AM, Rabin Yasharzadehe wrote: Hello list, I enabled HTML for my templates and in SiteConfig enabled Set($PreferRichText, true); Set($TrustHTMLAttachments, 1); But, I'm looking for a way to allow some HTML attributes into RT tickets, specifically to allow the dir=RTL attribute RT 4.0.6 will allow these attributes. https://github.com/bestpractical/rt/commit/a625c19e right now RT strip some of the attributes e.g it's not removing all the attributes of the font tag from where can I control this behavior ? You don't say what RT version you're using, and the answer depends on that. Thomas