if section.startswith("worker "):
if ini.has_option(section, "name") and ini.has_option(section, "password") and \
(not ini.has_option(section, "phase") or ini.getint(section, "phase") == 1):
- sl_props = { 'dl_lock':None, 'ul_lock':None, 'do_cleanup':False, 'shared_wd':True }
+ sl_props = { 'dl_lock':None, 'ul_lock':None, 'do_cleanup':False }
name = ini.get(section, "name")
password = ini.get(section, "password")
if ini.has_option(section, "cleanup"):
sl_props['ul_lock'] = lockname
if lockname not in NetLocks:
NetLocks[lockname] = locks.MasterLock(lockname)
- if ini.has_option(section, "shared_wd"):
- shared_wd = ini.getboolean(section, "shared_wd")
- sl_props['shared_wd'] = shared_wd
c['workers'].append(Worker(name, password, max_builds = 1, properties = sl_props))
# PB port can be either a numeric port or a connection string
# what steps, and which workers can execute them. Note that any particular build will
# only take place on one worker.
-def IsSharedWorkdir(step):
- return bool(step.getProperty("shared_wd"))
-
def IsTaggingRequested(step):
val = step.getProperty("tag")
if val and re.match(r"^[0-9]+\.[0-9]+\.[0-9]+(?:-rc[0-9]+)?$", val):
description = "Setting up shared work directory",
command = 'test -L "$PWD" || (mkdir -p ../shared-workdir && rm -rf "$PWD" && ln -s shared-workdir "$PWD")',
workdir = ".",
- haltOnFailure = True,
- doStepIf = IsSharedWorkdir))
+ haltOnFailure = True))
# find number of cores
factory.addStep(SetPropertyFromCommand(