archlinux: fix update-proxy-configs to use pacman.d drop-ins
(cherry picked from commit 7cea09711a
)
This commit is contained in:
parent
c439fe3934
commit
ef0155b15e
|
@ -108,6 +108,22 @@ $PROXY_CONF_ENTRY
|
|||
EOF
|
||||
fi
|
||||
|
||||
# Pacman (archlinux) also
|
||||
if [ -d /etc/pacman.d ]; then
|
||||
if [ -n "$PROXY_ADDR" ]; then
|
||||
cat > /etc/pacman.d/01-qubes-proxy.conf <<EOF
|
||||
### This file is automatically generated by Qubes ($0 script).
|
||||
### All modifications here will be lost.
|
||||
### If you want to override some of this settings, create another file under
|
||||
### /etc/pacman.d
|
||||
|
||||
XferCommand = http_proxy=$PROXY_ADDR /usr/bin/curl -C - -f %u > %o
|
||||
EOF
|
||||
else
|
||||
rm -r /etc/pacman.d/01-qubes-proxy.conf
|
||||
fi
|
||||
fi
|
||||
|
||||
# DNF configuration doesn't support including other files
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1352234
|
||||
if [ -e /etc/dnf/dnf.conf ]; then
|
||||
|
@ -119,8 +135,3 @@ fi
|
|||
if [ -e /etc/PackageKit/PackageKit.conf ]; then
|
||||
update_conf /etc/PackageKit/PackageKit.conf "ProxyHTTP=$PROXY_ADDR"
|
||||
fi
|
||||
|
||||
# Pacman (archlinux) also
|
||||
if [ -e /etc/pacman.conf ]; then
|
||||
update_conf /etc/pacman.conf "XferCommand = http_proxy=$PROXY_ADDR /usr/bin/curl -C - -f %u > %o"
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue
Block a user