wiki:Obsolete/Doc/SCDB/SWRepositories

Software Repositories Management

SCDB provides an optional, lightweight alternative to Quattor SWrep used to serve software packages (RPMs or Solaris PKGs). It requires no additional component to the base SCDB, relying on http server to serve RPMs.

SCDB Software repositories are implemented through directories associated with templates describing directories contents. These templates are maintained through SCDB standard management tool, based on ant.

This page describes SCDB software repositories layout and management operations related to them.

RPM Repositories Layout

Repository Directories

A software repositoryis a container for an arbitrary set of software packages (usually grouped by topic, e.g. OS, middleware...). One repository can contain several version of the same package. There is no limit in the number of repositories that can be configured and used at the same time.

In SCDB, every repository corresponds to one specific directory in http server document area. For example, if your Quattor http server is configured with document root /www/quattor, you can create a directory /www/quattor/packages to store software repositories. In this directory, you could create the following repositories :

  • ca : production version of CA RPMs
  • grid/glite-xxx and grid/lcg-xxxx : RPMs for gLite version xxx and LCG version xxx. For gLite, the recommendation is to create 3 repositories (as subdirectories of grid/glite-xxx) matching the 3 APT repositories : External, Release-xxx, updates.
  • lemon : RPMs for Lemon
  • os : directory root for OS related RPMs. The recommendation is to use one subdirectory for each OS version/architecture combination and for each version/architecture, to create 2 sub-directories base (to receive a copy of the OS standard distribution, e.g. CD-Rom) and updates to receive updates to base RPMs. Base RPMs repository will be the the directory containing RPMs in standard distribution.
  • quattor : Quattor related RPMs, except ncm-components. This is generally the root for Quattor related repositories, with one repository per Quattor version/archicture.
  • ncm-components : ncm-components RPMS.
  • site : Miscellanous RPMs used at local site.

This is the repository layout used in examples provided with QWG templates.

Associated Templates

PAN need to know about repositories contents to be able to check if required packages are available at compile time. Thus for each software repository, there is an associated structure template describing the packages available in the repository. For PAN to know about repository content changes, the template must be updated. This is done with ant, SCDB management tool.

Generally, templates associated with software repositories are grouped in one directory of SCDB. Recommandation is to put them in a directory called repository in your site sub-directory. e.g. cfg/sites/example/repository.

When adding a new repository, you need to create manually the base template for the repository. This template must contain only the initial comment describing where the software repository is located, what is its associated URL... The easiest is to copy an existing repository template, remove every thing starting at contents and update the remaining lines to match the new repository. An example for the required comments is :

# 
# Generated by RepositoryTask on 9/17/06 3:22 PM 
# 
# name = lal_glite_3_0_0_updates 
# owner = grid.support@lal.in2p3.fr 
# url = http://quattor.web.lal.in2p3.fr/packages/glite-3.0.0-i386/updates/ 
#

structure template repository_lal_glite_3_0_0_updates;

Updating RPM Repositories

A repository update can consist of :

  • Creating a new repository
  • Adding a new package in an existing repository
  • Removing a package from an existing repository

In every case, the management operations required are the same :

  • Update of directory contents for the repository
  • If this is a new repository, creation of associated template.
  • Update of associated templates for all existing repositories. This done with ant tool, using update.rep.templates task. For this, you need to have a valid working copy of your SCDB. The command to execute is :
    ant update.rep.templates
    

The result of this command is a new set of templates associated with software repositories in your working area. As every template modification, this has no impact until the new version of these templates are committed to the CDB repository. And until commit, the changes can be reverted with svn revert.

Last modified 18 years ago Last modified on Sep 18, 2006, 9:01:23 AM