Changeset 1140d1b


Ignore:
Timestamp:
12/27/13 11:54:25 (15 months ago)
Author:
Kris Moore <kris@…>
Branches:
master, releng/10.0, releng/10.0.1, releng/10.0.2, releng/10.0.3, releng/10.1, releng/10.1.1
Children:
67e0ce1, 4f9718b
Parents:
5a94cb0
Message:

Add a work-around for running multiple PBI builders at once

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src-sh/pbi-manager/pbi-manager

    rca510b7 r1140d1b  
    72107210 
    72117211                # Install pkgng into the chroot 
    7212                 pkg-static -c ${PBI_CHROOTDIR} install -y ports-mgmt/pkg 
    7213                 if [ $? -ne 0 ] ; then 
    7214                         exit_err "Failed installing pkgng into chroot" 
    7215                 fi 
     7212                # This can fail when we run multiple builders at once, 
     7213                # due to the pkgng DB being locked :( 
     7214 
     7215                # For now try multiple times, this should be revisited with 
     7216                # a cleaner solution at some point 
     7217                tries=0 
     7218                while : 
     7219                do 
     7220                        pkg-static -c ${PBI_CHROOTDIR} install -y ports-mgmt/pkg 
     7221                        if [ $? -eq 0 ] ; then break ; fi 
     7222 
     7223                        if [ $tries -gt 10 ] ; then 
     7224                                exit_err "Failed installing pkgng into chroot" 
     7225                        else 
     7226                                echo "Pkgng is busy, trying again in 8 seconds" 
     7227                                sleep 8 
     7228                                tries=`tries expr + 1` 
     7229                        fi 
     7230                done 
    72167231 
    72177232        fi 
Note: See TracChangeset for help on using the changeset viewer.