[Bug 1501217] Re: Removing squid-deb-proxy-client leaves a stale but active config file, breaking apt
Marius Gedminas
marius at gedmin.as
Tue Oct 20 10:35:53 UTC 2015
I've some half-formed ideas:
- if apt allows a shell command instead of just an executable name,
maybe the config could be
Acquire::http::ProxyAutoDetect "if [ -x /usr/share/squid-deb-proxy-
client/apt-avahi-discover ]; then /usr/share/squid-deb-proxy-client/apt-
avahi-discover; fi";
- if apt doesn't use the shell, but allows a command with arguments, and
not just an executable name, maybe the config could be
Acquire::http::ProxyAutoDetect "sh -c 'if [ -x /usr/share/squid-deb-
proxy-client/apt-avahi-discover ]; then /usr/share/squid-deb-proxy-
client/apt-avahi-discover; fi'";
- if apt is truly restricted to just a single executable name in that
parameter, maybe the package could ship a small wrapper script that
conditionally runs /apt-avahi-discover if it exists, with the wrapper
script placed somewhre in /etc, so it's not removed on purge, e.g.
Acquire::http::ProxyAutoDetect "/etc/squid-deb-proxy-client/apt-
avahi-discover";
with /etc/squid-deb-proxy-client/apt-avahi-discover containing
# you're not expected to modify this, see LP: #1501217
if [ -x /usr/share/squid-deb-proxy-client/apt-avahi-discover ]; then
/usr/share/squid-deb-proxy-client/apt-avahi-discover
fi
I keep not finding the time to experiment and see if one of the first
two ideas would work. I don't like the 3rd option.
--
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to squid-deb-proxy in Ubuntu.
https://bugs.launchpad.net/bugs/1501217
Title:
Removing squid-deb-proxy-client leaves a stale but active config file,
breaking apt
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/squid-deb-proxy/+bug/1501217/+subscriptions
More information about the Ubuntu-server-bugs
mailing list