Changeset 3209 in /cluster/svnroot


Ignore:
Timestamp:
May 25, 2011 1:29:07 AM (10 years ago)
Author:
fitz
Message:

(#631) Working script now.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • bccd-ng/branches/fitz-devel/bin/bccd-build.pl

    r3204 r3209  
    3434# Verify given branch is a valid branch
    3535#
    36 # Allowed formats for subject:
     36# Allowed formats for branch:
    3737#       - Relative path, in relation to SVNROOT, e.g., tags/bccd-3.0.0 or trunk
    3838#       - Relative path, in relation to branches/, e.g., fitz-devel
     
    4242        my ($subject) = @_;
    4343        my ($branch, $revision);
    44        
     44
    4545        if (($revision = get_svn_rev($SVNROOT . "/" . $subject)) != 0) {
    4646                $branch = $subject;
     
    7878  }
    7979}
     80
     81# To avoid unnecessary processing, only deal with requests starting with
     82# the keyword "build"
     83exit if ($subject !~ m/^build/);
     84$subject =~ s/^build //g;
     85
     86# TODO Could be extended to have multiple "commands" or "operations"
    8087
    8188# "Authorized" developers are those that are in the software group on
     
    137144        echo "ARCH=\$arch
    138145DBUSER=dc_tester
    139 WEBSVN=\"$SVNROOT/\"
    140 BRANCH=\"$branch/\"
    141 BINDIR=\"/bin/\"
    142 BLDCD=\"build_livecd.pl\"
     146WEBSVN=\\\"$SVNROOT/\\\"
     147BRANCH=\\\"\\\${WEBSVN}/$branch/\\\"
     148BINDIR=\\\"/bin/\\\"
     149BLDCD=\\\"build_livecd.pl\\\"
    143150PATH=\\\$PATH:/sbin:/usr/sbin
    144 OUTBASE=/cluster/bccd-ng/testing/from
     151OUTBASE=/cluster/bccd-ng/testing/$user
    145152OUTISO=\\\$OUTBASE/$isoprefix.\\\${ARCH}.iso
    146153TEMPISO=\\\$(mktemp \\\${OUTISO}.XXXXXXXX)" > build.\${arch}.conf
    147154
    148         sudo ./auto_build_wrapper.sh -c ./build.\${arch}.conf
     155        sudo \$tmp/auto_build_wrapper.sh -c ./build.\${arch}.conf
    149156done
    150157
     
    157164print $tmp $script;
    158165
    159 my @qsub = ('qsub', '-q', '@t-voc', '-e', 'edu-grid.org:/home/fitz', '-o', 'edu-grid.org:/home/fitz', $tmp);
     166my @qsub = ('/usr/local/bin/qsub', '-q', '@t-voc', '-e', 'edu-grid.org:/home/bccd', '-o', 'edu-grid.org:/home/bccd', $tmp);
    160167system(@qsub);
    161168
    162 # TODO Wait for job to complete, send informative email
     169# TODO Wait for job to complete, send informative email. This could just happen
     170# TODO as part of the qsub script.
    163171
    164172__END__
Note: See TracChangeset for help on using the changeset viewer.