http://www.rockbox.org/twiki/bin/view/Main/BuildServerRemake Client-side details * We will demand OpenSSH 4.x something. And perl. * There's a perl script on the client, called 'rb-build' * rb-build connects to the master with ssh and ControlMaster enabled. The ssh session starts in a thread and it has timeouts enabled. * The initial ssh command starts a client command 'rb-client' on the build server. On the command line that starts rb-client, you pass on what capabilities the server has (what platforms can it build), and user+ password of the person running the client. * The config (user name+password, arch support etc) must be kept separately from the script. * 'rb-client' outputs instructions that the script is asked to do: - build a specific build and upload the build log (when it starts a build, it does a special 'ssh rb-client start-build' invoke that says so and an 'ssh rb-client end-build' when done) - optionally upload the final zip too (pinned to the build) - update the rb-build script (or at least parts of it) - stop a particular build (and cleanup log/zip from that) and instead start the next one - stop all builds and cleanup logs/zips - tell the server the list of build targets is drained 'ssh rb-client end-of-list' - respond to a ping * It is important that the client reads the entire list of builds and holds that locally, so that it then can react swiftly on following commands. * the 'rb-client' invoke command line should include: - version number of the rb-client script - user + password (hm really?) - client identifier that let's the user know which client this is when the user runs many clients - list of archs this client can build: m68k, arm, armbe, sh, mipsle, sdl, sdl-win32 etc Server-side details * rb-server accepts connections from rb-clients. Connected clients are all builders. All builders have their own setup of what targets they can build. * rb-server has a list of targets to build during each round. * rb-server gets triggered by a post-commit hook, or like today by scanning for differences in updates * when a commit is detected, rb-build will go over the list of builds and hand out builds to clients. Each client will get several (many) builds to perform. Quite probably all the builds the client can build. * each client's performance is logged. Which build target, exact time of the build, time it took to build, user name, client name * when an 'end-build' command is received for a particular target, go through the list and kill the builds for that same target going on in other clients * when all targets are complete, send 'kill-all' to all clients * support that a client can show up mid-buildround, and simply hand over all the possible builds * support that a client can drop off mid-buildround