Skip to content

Buildbot administration

larsbergstrom edited this page Nov 17, 2014 · 106 revisions

Bors

Bors is the service that watches our PRs for approvals and shephards them into the buildbot queue. Its sources are at: https://github.com/servo/bors

It runs as a cron job.

Buildbot master

Build slaves

Their status can be viewed at: http://build.servo.org/buildslaves

Log in as root or servobld; there are no individual accounts on slaves.

Setting up a new build slave

Linux

add-apt-repository -y ppa:saltstack/salt
apt-get update
if on master machine: apt-get install salt-master
apt-get install salt-minion
echo '96.126.125.232 salt' >> /etc/hosts
edit /etc/salt/minon_id to have the name of the machine (e.g., servo-linux1)
service salt-minion restart

OSX

install brew: 
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
install latest Xcode command line tools from https://developer.apple.com/downloads
hdiutil attach command_line_tools_for_osx_mountain_lion_april_2014.dmg 
sudo installer -pkg /Volumes/Command\ Line\ Tools\ \(Mountain\ Lion\)/Command\ Line\ Tools\ \(Mountain\ Lion\).mpkg -target /
brew install git
 echo export PATH='/usr/local/bin:$PATH' >> ~/.bash_profile
logout and back in
brew doctor (should say you are good to go)
sudo easy_install -s /usr/bin pip
brew install saltstack
curl -O https://raw.githubusercontent.com/saltstack/salt/develop/pkg/darwin/com.saltstack.salt.minion.plist
add     <key>EnvironmentVariables</key>
    <dict>
        <key>PATH</key>
        <string>/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin</string>
        <key>HOME</key>
        <string>/Users/administrator</string>
    </dict>
right after the Label section
sudo salt-run launchd.write_launchd_plist salt-minion
sudo cp com.saltstack.salt.minion.plist /Library/LaunchDaemons/
sudo bash -c "echo '96.126.125.232 salt' >> /etc/hosts"
edit /etc/salt/minion and set `id: servo-mac$N` where $N is the number of the slave
sudo launchctl load -w /Library/LaunchDaemons/com.saltstack.salt.minion.plist
install xcode 5.1.1 from developer.apple.com
sudo xcodebuild -license (and agree)
set screen resolution to 1280x960 or else reftests will fail randomly
Create a standard user named 'Tom Servo', give him the same password as admin below, and log in. LEAVE LOGGED IN (else reftests will fail)

Enabling a build slave for the first time

On master use salt-key -L to list pending minon keys. Then use salt-key -a KEY to accept new minion keys.

Verify by logging in to the master and doing salt '*' test.ping. Should see results from all minons.

File configuration notes on servo-master

file_roots:
  base:
    - /srv/salt
    
pillar_roots:
  base:
    - /srv/pillar

credentials need to go into /srv/pillar/

Adding another build flavor

  • bors/bors.cfg needs to know about the build flavor (its string name from master.cfg below)
  • buildbot/master/master.cfg should add another type of build, hooked up in all the same ways as e.g., "mac1"
  • salt servo-master state.highstate
Clone this wiki locally
You can’t perform that action at this time.