curtin vmtests warns about host apt config
Bug #1640527 reported by
Ryan Harper
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
curtin |
Triaged
|
Medium
|
Unassigned |
Bug Description
when running vmtests on digglett where we have an "invalid" apt file present in /etc/apt/
curtin complains
2016-11-09 10:16:22,033 - vmtests - INFO - Target Tarball: yakkety amd64/hwe-y 20161105
N: Ignoring file '50unattended-
Changed in curtin: | |
importance: | Undecided → Medium |
status: | New → Triaged |
To post a comment you must log in.
From Scott:
http:// paste.ubuntu. com/23451558/
=== modified file 'tools/launch'
--- tools/launch 2016-07-15 16:14:53 +0000
+++ tools/launch 2016-11-09 16:23:17 +0000
@@ -235,16 +235,17 @@
find_apt_proxy() {
# pick an apt proxy for the guest
- local out=""
+ local out="" r=""
# if user set uncommon 'apt_proxy', then trust it
[ -n "$apt_proxy" ] && echo "$apt_proxy" && return 0
# see if the host has an apt proxy configured, and use it :HTTP:: Proxy) && :HTTP:: Proxy 2>&1) ||
if command -v apt-config >/dev/null 2>&1; then
- out=$(apt-config shell x Acquire:
+ out=$(apt-config shell x Acquire:
+ { r=$?; error "apt-config shell failed [$r]: $out"; return $r; }
out=$(sh -c 'eval $1 && echo $x' -- "$out") && [ -n "$out" ] &&
- echo "$out" && return
+ echo "$out" && return
fi
return 1