Hack around ostree incorrectly configuring repository

When getting a repository from ostree via the OstreeSysroot object some
extra information is stashed in place which seems to confused
ostree_repo_add_remote causing it to put the remote configuration in
/etc (as opposed to the repository itself).

While the proper fix should be in ostree, this allows us to get around
it for now

Signed-off-by: Sjoerd Simons <sjoerd.simons@collabora.co.uk>
This commit is contained in:
Sjoerd Simons
2017-07-31 15:01:25 +02:00
parent 7c1263d1c6
commit fcfeaae71f

View File

@@ -34,7 +34,11 @@ func (ot *OstreeDeployAction) Run(context *YaibContext) {
log.Fatalf("%s", err)
}
dstRepo, err := sysroot.Repo(nil)
/* HACK: Getting the repository form the sysroot gets ostree confused on
* whether it should configure /etc/ostree or the repo configuration,
so reopen by hand */
/* dstRepo, err := sysroot.Repo(nil) */
dstRepo, err = ostree.OpenRepo(path.Join(context.imageMntDir, "ostree/repo"))
if err != nil {
log.Fatalf("%s", err)
}