openSUSE:Build Service private installation requirements
Any developer who has experienced the challenge of integrating an Open Source project into a bespoke Linux distribution knows how painstaking and careful you need to be to follow and resolve all the dependencies imposed by each integration. Furthermore if you need to keep track of various upgrades of these 'to be integrated' packages, life can quickly become miserable. To be efficient you need be able to:
- offer the development team the facility to build complex software without having to worry about the complexity of inter-package dependency.
- enable the building of different projects with partial share of packages between them
- enable the rapid creation of test branches to validate the effect of modification in either internal or external packages.
- allow the rebuilding of software identical to what it was 10 years earlier (including the building tools) and then integrate a corrective patch.
- facilitate the integration of partner / customer code in your distribution
- seek solutions which have low start costs but scale well as a project grows and becomes successful
- provide a secure environment for your code and your build
- provide a solution which integrates well with modern source version management (e.g. git).
- provide a solution which does not require a dedicated team to install and maintain
- provide a solution which works very reliably and provides proven track record
- provide a solution which is well documented and easy to use by developers
The Open Build Services (OBS) from the Open Suse project can provide all of that. Documentation is still a bit weak at the time of writing this, but let's hope that is will evolve favourably soon.
The OBS project is a sub system of the openSUSE project and, as such, is available as part of any openSUSE distribution. However, installing and maintaining an OBS instance can be quite tedious.
The openSUSE project maintains OBS Appliances, which as their name suggests, are as simple to install and use as a familiar domestic appliance. This really is a Plug and Play service.
This HowTo favours the use of OBS appliances because practical experience has convinced me that it is the best option for a production environment. If you want to use a more traditional approach, please just ignore my installation guide.
OBS appliances can be found at openSUSE:Build Service Appliance. To fully implement this HowTo, you will need to download the latest stable version of the obs-server and obs-worker.
Appliances are available for different targets (raw, vmware, ISO) depending on your need. As I assume that you will be using a dedicated PC to run this HowTo, all my examples will assume a raw model. Transcription to vmware and ISO is very obvious and easy, should you need that model for your final deployment.
This HowTo was written after deploying a real OBS service to a team of about 50 software engineers who develop a project based on MeeGo with specialised add-ons dedicated to TV business for Amino Communications (Cambridge, UK) with the support of MeeGo community and some key OBS maintainers at Intel.
What do you need
If you simply need to investigate the use of a private OBS instance, you will just need a PC with 2 hard drives (HDD)and 4 GB of RAM on which to run the obs-server and the obs-workers.
I strongly advise you to run some tests before creating a production environment.
For a production system, I would advise you to create a dedicated obs-server - which does not run any workers - and a farm of workers (size depends on your needs).
The reason for this model is that it will allow you, at a later phase, to run a production obs-server and a test obs-server which can share the same obs-workers. This model can be extended to support a dedicated partner or customer obs-server if you plan to use the OBS to deliver and share code with partners and/or customers.
On your workstation
On your workstation you will need to install the osc and the build packages so as to enable access to the obs by command line in order to check-in and check-out code, as well as to create a local build. Most modern distributions provide these packages but due to the permanent improvements added to these tools, I would advise you to point your workstation repository to upload these packages directly from the openSUSE or MeeGo projects. The MeeGo Wiki will provide you a method for installing all the required tools (osc and Mic2) for major distributions.
How to install the tools on MeeGo Wiki
Other usefull ressources
- From openSUSE.org
- From MeeGo.com
- From Meamo.org Likely the most upto-date.
OBS appliances are very flexible but I wanted to keep the number of option changes from default reduced to the minimum. It might be that some of these options were not provided by default at the time of my test and this situation may have changed by the time you run your own test. Here are the general options I will assume during this HowTo.
- use DHCP with a DNS which gives the same internal and external DNS name to the appliance.
- use ntp to provide the time and set the ntp server via DHCP.
- use a dedicated HDD (sda) to receive the appliance software
- use a second HDD to receive the data (for production this should be a pair of HDDs configured as a software mirror (RAID1).
- favour build-compilation speed against hardware costs
- free access to port 80, 82 and 444 toward the server.
- I will not cover backing-up your data in this HowTo but you must do it.
- security is enforced externally to the OBS appliances.
- use my OBS to support-integrate external partners' linked projects.