Code Review
/
releng
/
builder.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
review
|
tree
raw
(from parent 2:
4eb92f7
)
Merge "BGPCEP-688: Install default config for bgp/bmp"
author
Thanh Ha
<thanh.ha@linuxfoundation.org>
Wed, 8 Nov 2017 14:38:40 +0000
(14:38 +0000)
committer
Gerrit Code Review
<gerrit@opendaylight.org>
Wed, 8 Nov 2017 14:38:40 +0000
(14:38 +0000)
packer/provision/baseline.sh
patch
|
blob
|
history
diff --git
a/packer/provision/baseline.sh
b/packer/provision/baseline.sh
index 78e3b64a87c1a3c3edeb0fd4aeaa86c8be385fa4..978296bb577415ebdce3b32e4e0414dd720577d4 100644
(file)
--- a/
packer/provision/baseline.sh
+++ b/
packer/provision/baseline.sh
@@
-79,6
+79,10
@@
ensure_ubuntu_install() {
# Retry installing package 5 times if necessary
for i in {0..5}
do
+
+ # Wait for any background apt processes to finish before running apt
+ while pgrep apt > /dev/null; do sleep 1; done
+
echo "$i: Installing $pkg"
if [ "$(dpkg-query -W -f='${Status}' "$pkg" 2>/dev/null | grep -c "ok installed")" -eq 0 ]; then
apt-cache policy "$pkg"