Bug 1436283 - Put package artifact repositories in different sources.lists. r=dustin

When running setup_packages in a docker image that derives from another,
we're currently overwriting the file that contains the apt sources for
the package artifact repositories that were used for the parent docker
image.

This doesn't cause practical problems for the existing docker images,
but in some cases where a user gets a one-click loaner, it might cause
problems when they try to install a package that has a dependency that
can't be fulfilled once those sources are overwritten.

To give a practical example, installing the gdb package from wheezy
requires libpython2.7, but if you try to do that on a derivative of the
debian7-base image, you don't have the deb7-python artifact repository
in your sources.list, and would fail to install gdb because apt can't
install a version of libpython2.7 that can be installed alongside the
python2.7 that is installed.

By putting easy repository in a separate file, named after the task id
of the corresponding package task, we ensure each an every one of them
is uniquely represented in /etc/apt/sources.list.d.

--HG--
extra : rebase_source : efb83b8c292a28c43ede24d5a3879dfbbfe94af7
This commit is contained in:
Mike Hommey 2018-02-07 16:41:08 +09:00
Родитель fdb3acbc2e
Коммит b8fc72430b
1 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -1,5 +1,5 @@
#!/bin/sh
for task in "$@"; do
echo "deb [trusted=yes] https://queue.taskcluster.net/v1/task/$task/runs/0/artifacts/public/build/ debian/"
done > /etc/apt/sources.list.d/99packages.list
echo "deb [trusted=yes] https://queue.taskcluster.net/v1/task/$task/runs/0/artifacts/public/build/ debian/" > "/etc/apt/sources.list.d/99$task.list"
done