diff options
author | Daniel Baumann <daniel@debian.org> | 2007-09-23 10:04:40 +0200 |
---|---|---|
committer | Daniel Baumann <daniel@debian.org> | 2007-09-23 10:04:40 +0200 |
commit | 6f5e2da03e5fd1af2200d2f55ca84647bc8d3626 (patch) | |
tree | e2a861c1995eea707b2ac1c72930351191714493 /helpers/lh_configapt | |
parent | 9a9491318d4a0469e4c97b28879ab34391c39095 (diff) | |
download | live-build-6f5e2da03e5fd1af2200d2f55ca84647bc8d3626.zip live-build-6f5e2da03e5fd1af2200d2f55ca84647bc8d3626.tar.gz |
Adding live-package 0.99.22-1.
Diffstat (limited to 'helpers/lh_configapt')
-rwxr-xr-x | helpers/lh_configapt | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/helpers/lh_configapt b/helpers/lh_configapt new file mode 100755 index 0000000..81ff23a --- /dev/null +++ b/helpers/lh_configapt @@ -0,0 +1,51 @@ +#!/bin/sh + +# lh_configapt.sh <action> + +case "${1}" in + apply-proxy) + # Configure ftp proxy + if [ -n "${LIVE_PROXY_FTP}" ] + then + echo "Acquire::ftp::Proxy \"${LIVE_PROXY_FTP}\";" > "${LIVE_CHROOT}"/etc/apt/apt.conf.d/00make-live_ftp-proxy.conf + fi + + # Configure http proxy + if [ -n "${LIVE_PROXY_HTTP}" ] + then + echo "Acquire::http::Proxy \"${LIVE_PROXY_HTTP}\";" > "${LIVE_CHROOT}"/etc/apt/apt.conf.d/00make-live_http-proxy.conf + fi + ;; + + apply-recommends) + # Configure recommends + if [ "${LIVE_RECOMMENDS}" = "yes" ] + then + echo "Aptitude::Recommends-Important \"true\";" > "${LIVE_CHROOT}"/etc/apt/apt.conf.d/00make-live_recommends.conf + else + echo "Aptitude::Recommends-Important \"false\";" > "${LIVE_CHROOT}"/etc/apt/apt.conf.d/00make-live_recommends.conf + fi + ;; + + deapply-proxy) + # Deconfigure ftp proxy + if [ -f "${LIVE_CHROOT}"/etc/apt/apt.conf.d/00make-live_ftp-proxy.conf ] + then + rm -f "${LIVE_CHROOT}"/etc/apt/apt.conf.d/00make-live_ftp-proxy.conf + fi + + # Deconfigure http proxy + if [ -f "${LIVE_CHROOT}"/etc/apt/apt.conf.d/00make-live_http-proxy.conf ] + then + rm -f "${LIVE_CHROOT}"/etc/apt/apt.conf.d/00make-live_http-proxy.conf + fi + ;; + + deapply-recommends) + # Deconfigure recommends + if [ -f "${LIVE_CHROOT}"/etc/apt/apt.conf.d/00make-live_recommends.conf ] + then + rm -f "${LIVE_CHROOT}"/etc/apt/apt.conf.d/00make-live_recommends.conf + fi + ;; +esac |