Commit Graph

7 Commits

Author SHA1 Message Date
Alexander Larsson
9914dff925 tests: Fix test-sideload.sh if ostree is built with curl backend
The soup backend and the curl backend give slightly different error
messages, so we need to tweak the 404 assert check to match both.
2021-10-08 12:05:22 +02:00
Alexander Larsson
15c761d482 Use symlinks instead of xa.sideload-repos config option
Instead of having a global config option we scan a directory for
symlinks into the sideload repos. These come from
/var/lib/flatpak/sideload-repos and /run/flatpak/sideload-repos (for
default system installation).

This is much easier to update atomically, and the two different
options are useful for persistant (the first) or dynamic (the second)
usescase.

Fixes https://github.com/flatpak/flatpak/issues/3494
2020-03-26 11:50:54 +01:00
Alexander Larsson
a843d2d594 sideload: Add api and CLI support to specify sideload repos dynamically 2020-03-24 14:01:20 +01:00
Alexander Larsson
e4df0fa6a6 sideload: Support pulling individual objects from sideload repos
We use the localcache-repos option to ostree_repo_pull to make ostree
directly import any files that are locally available in the sideload
repo even when pulling the main commit from upstream.

This also adds a test that verifies that such files are not
pulled via http.
2020-03-24 11:46:33 +01:00
Alexander Larsson
9208913664 Migrate config: Always enable gpg-verify-summary if collection id is set
This used to not be set for collection-id remotes as we used the
ostree-metadata branch for resolving. However, we now use the summary
always when doing a remote install (and not ostree-metadata for local
sideloads), so we still want to verify summary.

The signature on the summary is a nice security feature, but it is also
a very efficient small file to download to verify that no new summary
needs to be downloaded in the no-op update case.
2020-03-23 17:58:04 +01:00
Alexander Larsson
cd88ddd2af tests: Add more tests for sideloading
* Test that we load from sideload repo even when online
 * Test that when offline we don't update to older version in sideload repo
 * Test update to explicit version in sideload repo
 * Test updates to new version from sideload repo
2020-03-23 17:58:04 +01:00
Alexander Larsson
7710549596 tests: Add tests for sideloading apps 2020-03-23 17:58:04 +01:00