Where to put crontool scripts?

Hi all,
I’m just wondering if there’s a conventional place to store scripts that
run crontool jobs? I’ve got one to notify people of old tickets, but I’ll
be making more, now that this one is working. Thanks again for all the help
with that script, by the way.

I’m considering putting them in /opt/rt4/etc, maybe in a "crontool-scripts"
folder, but I don’t know what RT upgrades might do to that. Is it best to
just put them somewhere completely separate, like ~/rt-crontool-scripts, or
can I keep them somewhere in the RT directory tree? Thanks.

Alex Hall
Automatic Distributors, IT department
ahall@autodist.com

Hi all,
I’m just wondering if there’s a conventional place to store scripts that run
crontool jobs? I’ve got one to notify people of old tickets, but I’ll be
making more, now that this one is working. Thanks again for all the help
with that script, by the way.

We just have the whole script in the crontab:

% sudo crontab -l -u rtcrontool
[…]
15 8-16 * * 1-5 /opt/rt4/bin/rt-crontool --log=warning --search
RT::Search::FromSQL --search-arg ’ Queue = “Systems” AND Owner =
“Nobody” AND ( Status = “new” OR Status = “open” ) AND ( Starts IS
NULL OR Starts <= “now” ) ’ --condition
RT::Condition::CreatedBusinessHoursAgo --condition-arg 4 --action
RT::Action::MailAdminCcs --transaction-type Create --transaction last
–template “Unowned Ticket”
[…]

-m

Hi Alex,

We drop ours in /opt/rt4/local/bin.

MartinOn 2017-01-04 16:13, Alex Hall wrote:

Hi all,
I’m just wondering if there’s a conventional place to store scripts
that run crontool jobs? I’ve got one to notify people of old tickets,
but I’ll be making more, now that this one is working. Thanks again
for all the help with that script, by the way.

I’m considering putting them in /opt/rt4/etc, maybe in a
"crontool-scripts" folder, but I don’t know what RT upgrades might do
to that. Is it best to just put them somewhere completely separate,
like ~/rt-crontool-scripts, or can I keep them somewhere in the RT
directory tree? Thanks.

Alex Hall
Automatic Distributors, IT department
ahall@autodist.com

I’m considering putting them in /opt/rt4/etc, maybe in a "crontool-scripts"
folder, but I don’t know what RT upgrades might do to that.

RT upgrades won’t remove any extra files you have lying around.

  • Alex

Thanks for the thoughts, everyone. I think we’ll keep them under local, in their own folder. Good to know upgrading won’t touch anything.> On Jan 5, 2017, at 00:54, Alex Vandiver alex@chmrr.net wrote:

On Wed, 4 Jan 2017 11:13:38 -0500 Alex Hall ahall@autodist.com wrote:

I’m considering putting them in /opt/rt4/etc, maybe in a "crontool-scripts"
folder, but I don’t know what RT upgrades might do to that.

RT upgrades won’t remove any extra files you have lying around.

  • Alex