All users were logged out of Bugzilla on October 13th, 2018

Autorun AMO build script for preview

RESOLVED FIXED

Status

RESOLVED FIXED
10 years ago
4 years ago

People

(Reporter: brian, Assigned: xb95)

Tracking

Details

(Reporter)

Description

10 years ago
We have a build script (bin/build.sh) for AMO that concatenates/minifies JS/CSS.  Right now whenever a change is made to JS/CSS files, someone must rerun the build script before checkin so that the changes show up on preview.  Could we setup a cronjob for this script to run right after the `svn up` cronjob (preferably both would run in the same cron call to avoid any intermediate weird period)?  You'll need to cd into the bin directory before running the script, and you'll need to reference the jre binary (since it's not in SVN ;-) ).

Thanks!
(Assignee)

Updated

10 years ago
Assignee: server-ops → mark
(Assignee)

Comment 1

10 years ago
This is done.  AMO preview is done every hour, and now does the additional step of running the build.sh script.

Please let me know if you see any problems, or if this doesn't work for you.

In case it matters, we're using the OpenJDK version 1.6.0.
Status: NEW → RESOLVED
Last Resolved: 10 years ago
Resolution: --- → FIXED
This isn't going to work. We can't run this script on preview, as it modifies revisions.php, which is checked into svn. I've disabled the build script until we come up with a solution... That solution may be as easy as removing revisions.php before updating, but we still need to decide.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee: mark → bkrausz
Group: infra
Status: REOPENED → NEW
It's reasonable to not auto-run this and just require devs to run it when they check stuff in.
I'm also fine with deleting the file to avoid conflicts, that wfm too.
(Reporter)

Comment 5

10 years ago
I like deleting the file...the problem with not auto-running is that when someone inevitably forgets to build everyone has to hunt around tying to figure out what the problem is (this happened recently...confused the crap out of Stephen).  Also, this makes a lot of check-in clutter since every revision will have revisions.php modified, as well as some file recompilations if they change things.
(Reporter)

Comment 6

10 years ago
Since morgamic and I are in agreement, pushing back to Mark: can we have the script delete the revisions.php file before doing svn up so that there's no conflict?

Thanks!
Assignee: bkrausz → mark
There's a couple other things I'm thinking about related to this, so I'll take this for now.
Assignee: mark → reed
Over to Brian again to come up with a clean-up script.
Assignee: reed → bkrausz
(Reporter)

Comment 9

10 years ago
Game plan for those not in the loop:  I'll write a cleanup script that will run before the svn up.  It will delete all svn files modified by the build script so that svn up won't have conflicts.  That way Webdev can maintain both in the same place in case we add more to the script.
(Reporter)

Comment 10

10 years ago
There is now a clean script that deletes all files affected...it's /bin/clean.sh (r17503)

Reassigning to Mark to add this to the svn up cronjob.

Thanks!
Assignee: bkrausz → mark
(Assignee)

Comment 11

10 years ago
Thank you, Brian.  I added this cleaner to the update script and re-enabled the build script.  They're both running on the preview updater.  Let me know of any issues!
Status: NEW → RESOLVED
Last Resolved: 10 years ago10 years ago
Resolution: --- → FIXED
Product: mozilla.org → mozilla.org Graveyard
You need to log in before you can comment on or make changes to this bug.