phase1: use a different name for the Git clone work directory
authorJo-Philipp Wich <jo@mein.io>
Tue, 15 Nov 2016 13:28:41 +0000 (14:28 +0100)
committerJo-Philipp Wich <jo@mein.io>
Tue, 15 Nov 2016 13:28:41 +0000 (14:28 +0100)
Upon first start, the build master expects a clean directory to issue
git init --bare in, therfore we cannot use the clone used for bootstrapping.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
phase1/master.cfg

index 296e9fba63aaf8e95fde7551536701a5854c864e..939649dd70529e4df84fcb369531b100ab9ea97f 100644 (file)
@@ -94,6 +94,9 @@ targets = [ ]
 if not os.path.isdir(home_dir+'/source.git'):
        subprocess.call(["git", "clone", "--depth=1", repo_url, home_dir+'/source.git'])
        subprocess.call(["git", "checkout", repo_branch], cwd = home_dir+'/source.git')
+else:
+       subprocess.call(["git", "checkout", repo_branch], cwd = home_dir+'/source.git')
+       subprocess.call(["git", "pull"], cwd = home_dir+'/source.git')
 
 findtargets = subprocess.Popen([home_dir+'/dumpinfo.pl', 'targets'],
        stdout = subprocess.PIPE, cwd = home_dir+'/source.git')
@@ -113,7 +116,7 @@ from buildbot.changes.gitpoller import GitPoller
 c['change_source'] = []
 c['change_source'].append(GitPoller(
        repo_url,
-       workdir=home_dir+'/source.git', branch='master',
+       workdir=home_dir+'/work.git', branch='master',
        pollinterval=300))
 
 ####### SCHEDULERS