diff options
author | Christoph Berg | 2014-02-17 15:56:46 +0000 |
---|---|---|
committer | Christoph Berg | 2014-02-17 15:56:46 +0000 |
commit | d218abaa8e93a963eef1239a8375639618ab68c8 (patch) | |
tree | c01818b0c8f7ec1279c620a33d7954c57ca660dc | |
parent | 209765b9016cffb370bc7e2b72f965428e13e4b7 (diff) |
Use local approx cache on buildhost.12
-rw-r--r-- | debian/changelog | 6 | ||||
-rw-r--r-- | debian/postinst | 12 |
2 files changed, 16 insertions, 2 deletions
diff --git a/debian/changelog b/debian/changelog index 3759613..eb64fda 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +pgdg-buildenv (12) sid-pgdg; urgency=medium + + * Use local approx cache on buildhost. + + -- Christoph Berg <christoph.berg@credativ.de> Mon, 17 Feb 2014 16:56:24 +0100 + pgdg-buildenv (11) sid-pgdg; urgency=medium * Add logrotate. diff --git a/debian/postinst b/debian/postinst index ac3aa6a..58d3af6 100644 --- a/debian/postinst +++ b/debian/postinst @@ -10,10 +10,18 @@ case $1 in # update sources.list dist=$(lsb_release -cs) + mirror="http://apt.postgresql.org/pub/repos/apt/" + mirror_testing="http://atalia.postgresql.org/pub/repos/apt/" + case $(hostname) in + pgdg*) # use local cache on build host + mirror="http://atalia-approx:9999/atalia" + mirror_testing="$mirror" + ;; + esac cat > /etc/apt/sources.list.d/pgdg.list <<-EOF # do not edit, file maintained by pgdg-buildenv - deb http://apt.postgresql.org/pub/repos/apt/ $dist-pgdg main - deb http://atalia.postgresql.org/pub/repos/apt/ $dist-pgdg-testing main + deb $mirror $dist-pgdg main + deb $mirror_testing $dist-pgdg-testing main EOF # remove existing apt translations so apt does not try to refresh them |