Repository Management: Difference between revisions

From iPhone Development Wiki
No edit summary
Line 7: Line 7:
== Advanced ==
== Advanced ==


saurik [http://www.saurik.com/id/7 wrote a pretty detailed explanation] on how to get a repository set up a while back.
Cydia uses a Debian APT-like implementation to manage packages. If you have no experience with Debian APT, then you can read saurik's [http://www.saurik.com/id/7 detailed writeup on the subject], which should be more than enough to get you started.
 
=== Quick and dirty summary ===
 
==== Repository structure ====
 
The basic idea is that you have two files in your server, <tt>Packages</tt> and <tt>Release</tt>. These files can be bzipped to save bandwidth (i.e. <tt>Packages.bz2</tt> and <tt>Release.bz2</tt>). <tt>Packages</tt> contains all of the information related to the different packages on your server (and where to download them, more on that later) and <tt>Release</tt> contains all of the information related to your server.
 
If you want to see an example of a typical <tt>Packages</tt> and <tt>Release</tt> file, go to your sources in Cydia and find a repository hosted by a 3rd party. Copy-paste the URL in your browser and append <tt>Release.bz2</tt> (or <tt>Release</tt> if you get a 404) to the end. Same thing applies with Packages.
 
==== .deb files ====
 
The <tt>Packages</tt> file mentioned earlier points to .deb files in your server that you can download. These are made with dpkg-deb. [http://man.he.net/man1/dpkg-deb Manpage here].


== Private repos ==
== Private repos ==

Revision as of 05:26, 15 May 2014

This page contains instructions for getting a personal repository set up, and general tips and tricks.

Novice

If you have no interest in setting up your own server, you can always use MyRepoSpace.

Advanced

Cydia uses a Debian APT-like implementation to manage packages. If you have no experience with Debian APT, then you can read saurik's detailed writeup on the subject, which should be more than enough to get you started.

Quick and dirty summary

Repository structure

The basic idea is that you have two files in your server, Packages and Release. These files can be bzipped to save bandwidth (i.e. Packages.bz2 and Release.bz2). Packages contains all of the information related to the different packages on your server (and where to download them, more on that later) and Release contains all of the information related to your server.

If you want to see an example of a typical Packages and Release file, go to your sources in Cydia and find a repository hosted by a 3rd party. Copy-paste the URL in your browser and append Release.bz2 (or Release if you get a 404) to the end. Same thing applies with Packages.

.deb files

The Packages file mentioned earlier points to .deb files in your server that you can download. These are made with dpkg-deb. Manpage here.

Private repos

The most trivial way to get private repository is to restrict access based on UDID. Cydia sends the user's UDID via the HTTP_X_UNIQUE_ID HTTP header, so your server could check that against a database in order to ensure that the user has rightful access.

PHP implementation

A PHP implementation can be found here.