#!/bin/sh

set -e
exec 2>&1

action="$(basename "$0")"

set -x
apt-get remove -qy auto-apt-proxy
apt-get install -qy auto-apt-proxy

eval "$(apt-config shell proxy Acquire::http::Proxy-Auto-Detect)"
test "$proxy" = '/usr/bin/auto-apt-proxy'
