Commit 25c3f422 by Leonid Isaev Committed by Stéphane Graber

archlinux: Create per-container pacman host key

Do not copy the pacman master key from the host, as this opens it to attacks; generate a new secret hostkey. Signed-off-by: 's avatarLeonid Isaev <lisaev@umail.iu.edu> Acked-by: 's avatarStéphane Graber <stgraber@ubuntu.com>
parent 12cd132a
......@@ -107,6 +107,9 @@ ln -s /dev/null /etc/systemd/system/systemd-udevd-kernel.socket
ln -s /dev/null /etc/systemd/system/proc-sys-fs-binfmt_misc.automount
# set default systemd target
ln -s /lib/systemd/system/multi-user.target /etc/systemd/system/default.target
# initialize pacman keyring
pacman-key --init
pacman-key --populate archlinux
EOF
return 0
}
......@@ -172,7 +175,8 @@ install_arch() {
pacman_config="${container_pacman_config}"
fi
if ! pacstrap -dcC "${pacman_config}" "${rootfs_path}" ${base_packages[@]}; then
if ! pacstrap -dcGC "${pacman_config}" "${rootfs_path}" \
${base_packages[@]}; then
echo "Failed to install container packages"
return 1
fi
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment