Closed Bug 666282 Opened 14 years ago Closed 14 years ago

adjust clobberer cleanup crontasks

Categories

(Release Engineering :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: dustin, Assigned: dustin)

Details

Attachments

(2 files)

These now need to point to MySQL instead of sqlite And be documented.
Uh, I can't find any related crontasks on dm-wwwbuild01. Any idea where these are hidden?
Bug 656307 set it cron up as root@dm-wwwbuild01.
I think this is a better way to keep the logic where we can edit it, and also make sure the right db is being edited. I'll document this as it lands.
Attachment #541564 - Flags: review?(nrthomas)
Comment on attachment 541564 [details] [diff] [review] m666282-tools-p1-r1.patch Switching review to someone who knows more php+db.
Attachment #541564 - Flags: review?(nrthomas) → review?(catlee)
Attachment #541564 - Flags: review?(catlee) → review+
Attachment #541564 - Flags: checked-in+
OK, this is deployed now, and the cleanup crontask script is living in ~dmitchell/cleanup-clobberer.sh. That's probably not the best place, and it needs to get plugged into the nightly crontab. Amy, can you help with both of those? where would be a good place to put this script?
I disabled the following in root's crontab: MAILTO=catlee@mozilla.com @hourly $HOME/bin/cleanup_clobberer.sh /var/www/html/build/clobberer/db/clobberer.db I made a backup of the old script in /root/bin/cleanup_clobberer.sh (/root/bin/cleanup_clobberer.sh.sqlite) I copied the version from ~dmitchell/cleanup_clobberer.sh to /root/bin/cleanup_clobberer.sh. And, lastly, I added a file called cleanup_clobberer to /etc/cron.hourly which calls /root/bin/cleanup_clobberer.sh if it exists.
This isn't working because /clobberer/ requires LDAP auth, which the wget scripts aren't providing. Hmm.
So, I think that the best option is to just run cleanup.php directly using the CLI SAPI. It will still need some kind of check to make sure it's not run from Apache, although that isn't so critical. Back to the drawing board, then :)
So this allows the cleanup to be run via the PHP cli sapi, with a password required in an env var to discourage people from hitting cleanup.php with their web browsers. The cleanup.php part of this is already deployed, and works from the command line. So this is really just a review before deploying the crontab. Should we have a similar crontab for clobberer-staging?
Attachment #544915 - Flags: review?(catlee)
Attachment #544915 - Flags: feedback?(arich)
Attachment #544915 - Flags: review?(catlee) → review+
I'll land this as part of my transition to IT.
Attachment #544915 - Flags: feedback?(arich) → checked-in+
Crontab deployed. I also committed this: diff --git a/clobberer/cleanup_clobberer.cron b/clobberer/cleanup_clobberer.cron --- a/clobberer/cleanup_clobberer.cron +++ b/clobberer/cleanup_clobberer.cron @@ -1,2 +1,2 @@ MAILTO=catlee@mozilla.com -@hourly CLEANUP_PASSWORD=sekrits /usr/bin/php /var/www/html/build/clobberer/cleanup.php +@hourly root CLEANUP_PASSWORD=sekrits /usr/bin/php /var/www/html/build/clobberer/cleanup.php (oops!) Otherwise, this is finished. I'll watch over the next hour to make sure it runs. Catlee, let me know if you get email (you shouldn't).
Lookin' good.
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Product: mozilla.org → Release Engineering
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: