Make packer debug faster
Change-Id: Ief29d1b742f88b5979a7628889d1511d2c8eb0b1
diff --git a/common/ubuntu_base.sh b/common/ubuntu_base.sh
index 6f314e9..10f1ee9 100644
--- a/common/ubuntu_base.sh
+++ b/common/ubuntu_base.sh
@@ -1,7 +1,11 @@
#!/bin/bash -xe
+if [ -f /tmp/done_ubuntu_base ] ; then
+ echo "INFO: ubuntu_base already finished.Skipping.."
+ exit 0
+fi
+#
UBUNTU_BASEURL="${UBUNTU_BASEURL:-mirror://mirrors.ubuntu.com/mirrors.txt}"
-
## Base packages and setup
export DEBIAN_FRONTEND=noninteractive
echo -e '#!/bin/sh\nexit 101' > /usr/sbin/policy-rc.d
@@ -69,3 +73,5 @@
systemctl disable ${s} || true
systemctl stop ${s} || true
done
+
+touch /tmp/done_ubuntu_base