Fix apt-proxy configuration

pull/1/head
rockstable 2022-12-07 00:01:10 +01:00
parent a8ddc28377
commit 75a12e4399
4 changed files with 8 additions and 3 deletions

View File

@ -13,3 +13,5 @@ username=user
USERPW='$5$n4TiokMaqws2PC/i$eqDh77it8N/haBU6OeE6WqbBjI0E1IUczp2EJ7Tr4J/'
SUPRESS_GNOME_INITIAL_SCREEN=1
APTPROXY=http://hw4f-fai:3142

View File

@ -9,6 +9,11 @@ deb $ubuntumirror/ubuntu $ubuntudist-updates main restricted universe multiverse
deb $ubuntumirror/ubuntu $ubuntudist-security main restricted universe multiverse
EOM
if [ -n "$APTPROXY" ]; then
echo "Acquire::http::Proxy \"$APTPROXY\";" > $target/etc/apt/apt.conf.d/02proxy
else
rm -f $target/etc/apt/apt.conf.d/02proxy
fi
# https://lists.uni-koeln.de/pipermail/linux-fai/2016-July/011398.html
# In Ubuntu 16.04 (but not 14.04), the locales configuration mechanism has

View File

@ -12,5 +12,3 @@ libreoffice-help-de
ubuntu-software
ubuntu-snappy
snapd
APTPROXY=http://hw4f-fai:3142

View File

@ -31,5 +31,5 @@ if contains "$DISTS_TO_UPGRADE" "$release"; then
fi
if [ ! "$KEEP_PROXY_FOR_UPGRADE" ]; then
$ROOTCMD rm -f /etc/apt/apt.conf.d/00-proxy
rm -f $target/etc/apt/apt.conf.d/02proxy
fi