commit cba7d688790426a77328965bc1eaeda3e713c700
Author: Colin Walters <walters(a)verbum.org>
Date: Mon Mar 16 13:52:28 2015 -0400
lorax-embed-repo: Update to use HTTP-based location
rpm-ostree-toolbox always uses this code path now; we spawn an "ostree
trivial-httpd" even for local use. That way the same template can be
used for both remote repositories and local ones.
atomic-installer/lorax-embed-repo.tmpl | 16 ++++++++++------
1 files changed, 10 insertions(+), 6 deletions(-)
---
diff --git a/atomic-installer/lorax-embed-repo.tmpl b/atomic-installer/lorax-embed-repo.tmpl
index 97dd768..fe5a810 100644
--- a/atomic-installer/lorax-embed-repo.tmpl
+++ b/atomic-installer/lorax-embed-repo.tmpl
@@ -1,10 +1,14 @@
-## Lorax template to embed ostree repo into installer
-
-<%page args="root, ostree_osname, ostree_repo, ostree_ref"/>
+## Lorax template to embed an OSTree repository into the installer.iso
+## and configure an interactive installer use to look for it.
+<%page args='root'/>
mkdir install/ostree
-
runcmd ostree --repo=${root}/install/ostree init --mode=archive-z2
-runcmd ostree --repo=${root}/install/ostree pull-local --disable-fsync ${ostree_repo} ${ostree_ref}
+runcmd ostree remote add ostree-mirror --repo=${root}/install/ostree/ --set=gpg-verify=false @OSTREE_URL@
+runcmd ostree --repo=${root}/install/ostree/ pull --mirror ostree-mirror @OSTREE_REF@
+
+
+append usr/share/anaconda/interactive-defaults.ks "ostreesetup --nogpg --osname=@OSTREE_OSNAME@ --remote=@OSTREE_OSNAME@ --url=file:///install/ostree --ref=@OSTREE_REF@\n"
+append usr/share/anaconda/interactive-defaults.ks "services --disabled cloud-init,cloud-config,cloud-final,cloud-init-local\n"
+append usr/share/anaconda/interactive-defaults.ks "%post --erroronfail\nrm -f /etc/ostree/remotes.d/@OSTREE_OSNAME@.conf\n%end\n"
-append usr/share/anaconda/interactive-defaults.ks "ostreesetup --nogpg --osname=${ostree_osname} --remote=${ostree_osname} --url=file:///install/ostree --ref=${ostree_ref}\n"