mirror of
https://git.launchpad.net/ubuntu-dev-tools
synced 2025-03-13 08:01:09 +00:00
pbuilder-dist: pass one --othermirror when local archive found (LP: #1314076)
This commit is contained in:
parent
bdc647404f
commit
105db5752b
@ -249,13 +249,6 @@ class PbuilderDist(object):
|
|||||||
if os.path.exists('/var/cache/archive/'):
|
if os.path.exists('/var/cache/archive/'):
|
||||||
arguments += ['--bindmounts', '/var/cache/archive/']
|
arguments += ['--bindmounts', '/var/cache/archive/']
|
||||||
|
|
||||||
localrepo = '/var/cache/archive/' + self.target_distro
|
|
||||||
if os.path.exists(localrepo):
|
|
||||||
arguments += [
|
|
||||||
'--othermirror',
|
|
||||||
'deb file:///var/cache/archive/ %s/' % self.target_distro,
|
|
||||||
]
|
|
||||||
|
|
||||||
config = UDTConfig()
|
config = UDTConfig()
|
||||||
if self.target_distro in self._debian_distros:
|
if self.target_distro in self._debian_distros:
|
||||||
mirror = os.environ.get('MIRRORSITE',
|
mirror = os.environ.get('MIRRORSITE',
|
||||||
@ -276,6 +269,11 @@ class PbuilderDist(object):
|
|||||||
arguments += ['--mirror', mirror]
|
arguments += ['--mirror', mirror]
|
||||||
|
|
||||||
othermirrors = []
|
othermirrors = []
|
||||||
|
localrepo = '/var/cache/archive/' + self.target_distro
|
||||||
|
if os.path.exists(localrepo):
|
||||||
|
repo = 'deb file:///var/cache/archive/ %s/' % self.target_distro
|
||||||
|
othermirrors.append(repo)
|
||||||
|
|
||||||
if self.target_distro in self._debian_distros:
|
if self.target_distro in self._debian_distros:
|
||||||
debian_info = DebianDistroInfo()
|
debian_info = DebianDistroInfo()
|
||||||
try:
|
try:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user