Add auth.conf.d support to archives
Allow APT_AUTH.CONF(5) config files to be used with archives. Note that config/archives/*.conf are assumed to be apt.conf files, so the apt_auth files are required to end with .auth and will be renamed to .conf when copied into the chroot. Closes: #991065
This commit is contained in:
parent
70994cd304
commit
f04dc6dc49
|
@ -92,6 +92,26 @@ case "${_ACTION}" in
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
|
# Adding local apt auth (chroot)
|
||||||
|
# Note: .conf is assumed to be apt.conf, so use new suffix .auth
|
||||||
|
for FILE in config/archives/*.auth
|
||||||
|
do
|
||||||
|
if [ -e "${FILE}" ]
|
||||||
|
then
|
||||||
|
cp ${FILE} chroot/etc/apt/auth.conf.d/$(basename ${FILE} .auth).conf
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
# Adding local apt auth (chroot)
|
||||||
|
# Note: .conf is assumed to be apt.conf, so use new suffix .auth
|
||||||
|
for FILE in config/archives/*.auth.chroot
|
||||||
|
do
|
||||||
|
if [ -e "${FILE}" ]
|
||||||
|
then
|
||||||
|
cp ${FILE} chroot/etc/apt/auth.conf.d/$(basename ${FILE} .auth.chroot).conf
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
# Check local archive keys (chroot)
|
# Check local archive keys (chroot)
|
||||||
if Find_files config/archives/*.key || \
|
if Find_files config/archives/*.key || \
|
||||||
Find_files config/archives/*.key.chroot
|
Find_files config/archives/*.key.chroot
|
||||||
|
@ -364,6 +384,16 @@ case "${_ACTION}" in
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
|
# Remve chroot-only apt auth
|
||||||
|
# Note: .conf is assumed to be apt.conf, so use new suffix .auth
|
||||||
|
for FILE in config/archives/*.auth.chroot
|
||||||
|
do
|
||||||
|
if [ -e "${FILE}" ]
|
||||||
|
then
|
||||||
|
rm "chroot/etc/apt/auth.conf.d/$(basename ${FILE} .auth.chroot).conf"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
# Adding local apt sources (binary)
|
# Adding local apt sources (binary)
|
||||||
for FILE in config/archives/*.list config/archives/*.list.binary
|
for FILE in config/archives/*.list config/archives/*.list.binary
|
||||||
do
|
do
|
||||||
|
@ -401,6 +431,16 @@ case "${_ACTION}" in
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
|
# Adding local apt auth (chroot)
|
||||||
|
# Note: .conf is assumed to be apt.conf, so use new suffix .auth
|
||||||
|
for FILE in config/archives/*.auth.binary
|
||||||
|
do
|
||||||
|
if [ -e "${FILE}" ]
|
||||||
|
then
|
||||||
|
cp ${FILE} chroot/etc/apt/auth.conf.d/$(basename ${FILE} .auth.binary).conf
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
# Adding local apt keys (binary)
|
# Adding local apt keys (binary)
|
||||||
for FILE in config/archives/*.key config/archives/*.key.binary
|
for FILE in config/archives/*.key config/archives/*.key.binary
|
||||||
do
|
do
|
||||||
|
|
Loading…
Reference in New Issue