mirror of
https://github.com/actions/runner-images.git
synced 2025-12-15 06:08:07 +00:00
[Ubuntu] Remove apt source for podman, buildah and skopeo (#3077)
* remove apt source list * debug * document source repo and fix installation * small fix
This commit is contained in:
committed by
GitHub
parent
6858b9232d
commit
21b8cadc2c
@@ -4,10 +4,14 @@
|
||||
## Desc: Installs container tools: podman, buildah and skopeo onto the image
|
||||
################################################################################
|
||||
|
||||
# Install podman, buildah, scopeo container's tools
|
||||
source $HELPER_SCRIPTS/os.sh
|
||||
|
||||
install_packages=(podman buildah skopeo)
|
||||
REPO_URL="https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable"
|
||||
|
||||
# Install podman, buildah, scopeo container's tools (on Ubuntu20 these tools can be installed without adding new repository)
|
||||
source /etc/os-release
|
||||
sh -c "echo 'deb https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable/x${NAME}_${VERSION_ID}/ /' > /etc/apt/sources.list.d/devel:kubic:libcontainers:stable.list"
|
||||
sh -c "echo 'deb ${REPO_URL}/x${NAME}_${VERSION_ID}/ /' > /etc/apt/sources.list.d/devel:kubic:libcontainers:stable.list"
|
||||
wget -qnv https://download.opensuse.org/repositories/devel:kubic:libcontainers:stable/x${NAME}_${VERSION_ID}/Release.key -O Release.key
|
||||
apt-key add Release.key
|
||||
apt-get update -qq
|
||||
@@ -15,4 +19,10 @@ apt-get -qq -y install ${install_packages[@]}
|
||||
mkdir -p /etc/containers
|
||||
echo -e "[registries.search]\nregistries = ['docker.io', 'quay.io']" | tee /etc/containers/registries.conf
|
||||
|
||||
# Remove source repo
|
||||
rm /etc/apt/sources.list.d/devel:kubic:libcontainers:stable.list
|
||||
|
||||
# Document source repo
|
||||
echo "containers $REPO_URL" >> $HELPER_SCRIPTS/apt-sources.txt
|
||||
|
||||
invoke_tests "Tools" "Containers"
|
||||
|
||||
Reference in New Issue
Block a user