Skip to content

Commit

Permalink
cmd-fetch: include overrides when updating lockfile
Browse files Browse the repository at this point in the history
I'm working on a lockfile updater[1], and I'd like it to just be able to
do `cosa fetch --update-lockfile` the same way a human would. This
normally would run `rpm-ostree compose tree` without passing any
lockfiles and blocking out the pool so that all packages come from the
base repo.

Sadly, that doesn't currently work for FCOS right now we have an
override for crypto-policies from f32 so that we don't pull in Python,
and also have an `exclude-packages` for Python. Which means that without
the f32 crypto-policies, we can't get a depsolve from just the base f31
repos. (This is the same issue that killed bodhi-updates[2].)

As a short-term hack, just include the overrides for now. This dillutes
the meaning of a "base" lockfile of course, because it will now will
include the same packages as the overrides. We can drop this hack once
we move to f32, though I have some ideas too on how to solve this more
correctly.

[1] coreos/fedora-coreos-tracker#293
[2] coreos/fedora-coreos-config#335 (comment)
  • Loading branch information
jlebon committed Apr 22, 2020
1 parent fa4fd7c commit 9647387
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/cmd-fetch
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,10 @@ if [ -n "${UPDATE_LOCKFILE}" ]; then
# Put this under tmprepo so it gets automatically chown'ed if needed
args="--ex-write-lockfile-to=${tmprepo}/tmp/manifest-lock.json"
if [ -f "${manifest_lock_overrides}" ]; then
echo "NB: ignoring overrides ${manifest_lock_overrides}"
sleep 1
# Include the overrides in the resulting lockfile here; otherwise, we
# might not even be able to get a depsolve solely from the non-lockfile
# repos.
args+=" --ex-lockfile=${manifest_lock_overrides}"
fi
else
for lock in "${manifest_lock}" "${manifest_lock_overrides}"; do
Expand Down

0 comments on commit 9647387

Please sign in to comment.