Skip to content

Latest commit

 

History

History
56 lines (46 loc) · 3.01 KB

Repository.md

File metadata and controls

56 lines (46 loc) · 3.01 KB

Capstan Repository

Capstan downloads base unikernel and precompiled packages from OSv Github releases repository (the default) or remote repository in AWS S3. If S3 mode selected (--s3), following S3 repository is used by default:

https://mikelangelo-capstan.s3.amazonaws.com

There is nothing special about S3 repository, it's just a bunch of directories and files that are made available on the internet. So you can easily create your own and make capstan use it. No authentication is supported, just a simple HTTP/HTTPS download.

OSv Github Repository

By default capstan pulls OSv kernel and any required packages from OSv Github repository. The global parameter --release-tag (or -r) can be used to override default behavior and make capstan pull artifacts published for specific release (for example --r v0.53.0) or the latest release (--r latest). By default capstan would pull first found artifact from the list of assets published for all releases (--r any).

S3 Repository Structure

One can use global --s3 parameter to make capstan pull kernel and packages from repository in AWS S3. The default public repository created as part of MIKELANGELO project is structured as follows:

mike
 |- osv-loader                  #
 |   |- index.yaml              # base unikernel (path is hard-coded in Capstan)
 |   |- osv-loader.qemu.gz      #
packages
 |- osv.bootstrap.mpm           # actual package
 |- osv.bootstrap.yaml          # metadata describing package
 |- erlang-7.0.mpm
 |- erlang-7.0.yaml
 |- ...

As shown above, there are two root directories in the repository: mike and packages.

mike root directory

This directory contains base unikernel that Capstan builds your own unikernel upon. The "recipe" to prepare the two files is best shown here. To prepare the osv-loader.qemu.gz file we simply checkout latest OSv master and build it. Then we take the $OSV_DIR/build/last/loader.img file and tar.gz compress it into osv-loader.qemu.gz.

packages root directory

This directory contains all the Capstan packages. Each package is stored in two files that only differ in suffix: {package-name}.mpm and {package-name}.yaml. The former is actually a tar.gz file containing all the package files, but please make use of capstan package build command to compress it, as can be seen in this "recipe". The latter is a simple metafile in yaml format.

Hosting your own repository

It should be very simple to host your own Capstan repository, just make sure that you maintain the directory structure as described above.

Please consult this file to learn how to tell Capstan what remote repository to connect to.