Add "pull --localcache-repo"

This is a lot like `git clone --reference`, but we chose "localcache" as the
term "reference" is already used.

The main use case I'm targeting this for is the Fedora Atomic Host installer
case where we embed the repo content in the installer, but we may want to
kickstart and download newer content. There, while we want to get a newer ref,
we can still use the local repo as an object cache, since we have it sitting
there in memory anyways.

Another case is where one has a host ostree (say e.g. Fedora Atomic
Workstation), and one wants to create a local archive mirror of FAH. Then one
can use `pull --reference /ostree/repo` and pull the common objects (e.g.
contents of `bash.rpm` etc.)

Closes: https://github.com/ostreedev/ostree/issues/975

Closes: #982
Approved by: jlebon
This commit is contained in:
Colin Walters authored and Atomic Bot committed 2017-06-30 19:37:23 +00:00
1 parent 1782a1c279
commit 4273e670ea
5 files changed
+153 -10

No files matched your search

+10
View File
@@ -73,6 +73,16 @@ Boston, MA 02111-1307, USA.
</para></listitem>
</varlistentry>
<varlistentry>
<term><option>--localcache-repo</option></term>
<listitem><para>
Like git's <literal>clone --reference</literal>. Reuse the provided
OSTree repo as a local object cache of objects when doing HTTP fetches.
May be specified multiple times.
</para></listitem>
</varlistentry>
<varlistentry>
<term><option>--untrusted</option></term>