Add enable/disable apt-proxy.
This commit is contained in:
parent
84670c22ef
commit
695ed10fd6
|
|
@ -49,6 +49,8 @@ blend_preinst() {
|
||||||
else
|
else
|
||||||
notice "no blend-specific scripts found in ${blend_release_path}/automate"
|
notice "no blend-specific scripts found in ${blend_release_path}/automate"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
enable_apt-proxy
|
||||||
}
|
}
|
||||||
|
|
||||||
blend_postinst() {
|
blend_postinst() {
|
||||||
|
|
@ -66,18 +68,8 @@ blend_postinst() {
|
||||||
install-custdebs || zerr
|
install-custdebs || zerr
|
||||||
install-custscripts || zerr
|
install-custscripts || zerr
|
||||||
|
|
||||||
## remove the apt-proxy if present
|
|
||||||
#if [ -f ${strapdir}/etc/apt/apt.conf.d/02proxy ]; then
|
|
||||||
# rm ${strapdir}/etc/apt/apt.conf.d/02proxy
|
|
||||||
#fi
|
|
||||||
|
|
||||||
## When changes are done to /root and we want those changes transfered
|
|
||||||
# to the live default user but not all future users we use a tmp skel
|
|
||||||
# with system skel copied in.
|
|
||||||
# rsync -avzP --no-o --no-g /etc/skel ${strapdir}/tmp/skel
|
|
||||||
# rsync -avzP --no-o --no-g ${strapdir}/root/ ${strapdir}/tmp/skel
|
|
||||||
|
|
||||||
blend_finalize || zerr
|
blend_finalize || zerr
|
||||||
|
disable_apt-proxy
|
||||||
}
|
}
|
||||||
|
|
||||||
iso_write_isolinux_cfg() {
|
iso_write_isolinux_cfg() {
|
||||||
|
|
@ -529,7 +521,10 @@ disable_apt-proxy() {
|
||||||
|
|
||||||
cat << EOF | sudo tee ${strapdir}/delproxy
|
cat << EOF | sudo tee ${strapdir}/delproxy
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
sed '/^${apt_proxy}/d' /etc/apt/apt.conf.d/02proxy
|
#sed '/^${apt_proxy}/d' /etc/apt/apt.conf.d/02proxy
|
||||||
|
if [ -f /etc/apt/apt.conf.d/02proxy ]; then
|
||||||
|
rm /etc/apt/apt.conf.d/02proxy
|
||||||
|
fi
|
||||||
EOF
|
EOF
|
||||||
chroot-script delproxy || zerr
|
chroot-script delproxy || zerr
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue