[elbe-devel] [PATCH] pkgutils: fix the LOCALMACHINE replace for in initvm code
Torben Hohn
torben.hohn at linutronix.de
Tue Apr 9 14:50:52 CEST 2019
pkgutils was used for elbe-bootstrap downloading code, which
runs outside of initvm. elbe-bootstrap has been removed, and different
code is used to download the debian installer nowadays.
The code in pkgutils is only used by the host sdk downloading code.
This code runs inside the initvm and needs to replace LOCALMACHINE
with 10.0.2.2
Fit it.
Signed-off-by: Torben Hohn <torben.hohn at linutronix.de>
---
elbepack/pkgutils.py | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/elbepack/pkgutils.py b/elbepack/pkgutils.py
index 6cb0c85e..a5355863 100644
--- a/elbepack/pkgutils.py
+++ b/elbepack/pkgutils.py
@@ -27,7 +27,7 @@ def get_sources_list(prj):
if prj.has("mirror/primary_host"):
mirror = "%s://%s/%s" % (prj.text("mirror/primary_proto"),
prj.text("mirror/primary_host").replace(
- "LOCALMACHINE", "localhost"),
+ "LOCALMACHINE", "10.0.2.2"),
prj.text("mirror/primary_path"))
slist += "deb %s %s main\n" % (mirror, suite)
slist += "deb-src %s %s main\n" % (mirror, suite)
@@ -35,10 +35,10 @@ def get_sources_list(prj):
if prj.node("mirror/url-list"):
for n in prj.node("mirror/url-list"):
if n.has("binary"):
- tmp = n.text("binary").replace("LOCALMACHINE", "localhost")
+ tmp = n.text("binary").replace("LOCALMACHINE", "10.0.2.2")
slist += "deb %s\n" % tmp.strip()
if n.has("source"):
- tmp = n.text("source").replace("LOCALMACHINE", "localhost")
+ tmp = n.text("source").replace("LOCALMACHINE", "10.0.2.2")
slist += "deb-src %s\n" % tmp.strip()
return slist
@@ -49,7 +49,7 @@ def get_key_list(prj):
if prj.node("mirror/url-list"):
for n in prj.node("mirror/url-list"):
if n.has("key"):
- tmp = n.text("key").replace("LOCALMACHINE", "localhost")
+ tmp = n.text("key").replace("LOCALMACHINE", "10.0.2.2")
retval.append(tmp.strip())
return retval
--
2.11.0
More information about the elbe-devel
mailing list