APT repository
(steps for new release) |
(update) |
||
| Line 24: | Line 24: | ||
Make sure that the package is built on the relevant architectures (amd64, i386). | Make sure that the package is built on the relevant architectures (amd64, i386). | ||
| − | Create a directory <tt>/srv/wikimedia/pool/''component''/''package basename''/</tt> on [[ | + | Create a directory <tt>/srv/wikimedia/pool/''component''/''package basename''/</tt> on [[brewster]]. E.g. <tt>/srv/wikimedia/pool/main/squid/</tt> for the Squid packages. |
Copy the binary <tt>.debs</tt> files, the <tt>.dsc</tt> file, the <tt>.tar.gz</tt> source tarball and the <tt>.diff.gz</tt> patchfile into the newly created directory. | Copy the binary <tt>.debs</tt> files, the <tt>.dsc</tt> file, the <tt>.tar.gz</tt> source tarball and the <tt>.diff.gz</tt> patchfile into the newly created directory. | ||
Run: | Run: | ||
| − | # | + | # update-repository |
This will create new <tt>Package</tt> and <tt>Source</tt> files, and create a new <tt>Release</tt> file in the distribution root-directory, and sign it with the archive GPG key. | This will create new <tt>Package</tt> and <tt>Source</tt> files, and create a new <tt>Release</tt> file in the distribution root-directory, and sign it with the archive GPG key. | ||
| Line 40: | Line 40: | ||
# <tt>mkdir $RELEASE-wikimedia && cd $RELEASE-wikimedia</tt> | # <tt>mkdir $RELEASE-wikimedia && cd $RELEASE-wikimedia</tt> | ||
# <tt>for c in {main,multiverse,restricted,universe}; do mkdir $c; for a in {i386,amd64,source}; do mkdir $c/binary-$a; echo -e "Archive: $RELEASE-wikimedia\nVersion: $VERSION\nComponent:$c\nOrigin: Wikimedia\nLabel: Wikimedia\nArchitecture: $a" > $c/binary-$a/Release; done; mv $c/binary-source $c/source; done</tt> | # <tt>for c in {main,multiverse,restricted,universe}; do mkdir $c; for a in {i386,amd64,source}; do mkdir $c/binary-$a; echo -e "Archive: $RELEASE-wikimedia\nVersion: $VERSION\nComponent:$c\nOrigin: Wikimedia\nLabel: Wikimedia\nArchitecture: $a" > $c/binary-$a/Release; done; mv $c/binary-source $c/source; done</tt> | ||
| − | # Edit | + | # Edit update-repository (on the puppetmaster host) to include the new release and rerun it |
== See also == | == See also == | ||
Revision as of 15:09, 3 November 2009
Wikimedia maintains its own APT repository, under http://apt.wikimedia.org/wikimedia which lives on khaldun. This repository contains Debian/Ubuntu packages modified for use by Wikimedia, and Wikimedia specific native packages, that don't exist elsewhere.
Contents |
Using
To use this repository, the following lines need to be present in /etc/apt/sources.list:
## Wikimedia APT repository deb http://apt.wikimedia.org/wikimedia dapper-wikimedia main restricted universe multiverse deb-src http://apt.wikimedia.org/wikimedia dapper-wikimedia main restricted universe multiverse
Additionally, to make sure that the system prefers packages from this repository, and not packages from the origin distributions even if they have a higher version number, this APT source is "pinned" with a higher priority in /etc/apt/preferences:
Package: * Pin: release o=Wikimedia Pin-Priority: 1001
The Wikimedia repository is signed with the Wikimedia Archive Automatic Signing Key <root@wikimedia.org>. This public key must be installed in APT's GPG keyring for it to verify packages without nagging about it. This can be accomplished by installing the wikimedia-keyring package.
An automated installation of a Wikimedia server should take care of all of the above.
Updating the repository
To add packages to the Wikimedia repository, so they can be deployed on the servers, take the following steps.
Commit the debian/ directory of the package to Subversion, under:
svn.wikimedia.org/svnroot/mediawiki/trunk/debs/package basename/debian/
Make sure that the package is built on the relevant architectures (amd64, i386).
Create a directory /srv/wikimedia/pool/component/package basename/ on brewster. E.g. /srv/wikimedia/pool/main/squid/ for the Squid packages.
Copy the binary .debs files, the .dsc file, the .tar.gz source tarball and the .diff.gz patchfile into the newly created directory.
Run:
# update-repository
This will create new Package and Source files, and create a new Release file in the distribution root-directory, and sign it with the archive GPG key.
The package should now be available for deployment/installation on the target hosts, after they have done a apt-get update, of course.
Setup of a Wikimedia repository for a new Ubuntu release
- export RELEASE=release
- export VERSION=version
- cd /srv/wikimedia/dists
- mkdir $RELEASE-wikimedia && cd $RELEASE-wikimedia
- for c in {main,multiverse,restricted,universe}; do mkdir $c; for a in {i386,amd64,source}; do mkdir $c/binary-$a; echo -e "Archive: $RELEASE-wikimedia\nVersion: $VERSION\nComponent:$c\nOrigin: Wikimedia\nLabel: Wikimedia\nArchitecture: $a" > $c/binary-$a/Release; done; mv $c/binary-source $c/source; done
- Edit update-repository (on the puppetmaster host) to include the new release and rerun it
See also
- pbuilder for building packages for different distribution versions and architectures