aboutsummaryrefslogtreecommitdiffstats
path: root/packer
diff options
context:
space:
mode:
authorJan-Simon Möller <jsmoeller@linuxfoundation.org>2016-09-30 16:06:05 +0200
committerJan-Simon Möller <jsmoeller@linuxfoundation.org>2016-09-30 16:06:05 +0200
commit24126b40b20a4da3c9ad4ae7348bd439781d0769 (patch)
treeb6b3133802a72e041aff28d60bf0d796dea6e429 /packer
parentca10ec28ff901985f5d9e8d84540a26f576b83b3 (diff)
Split mirroring into own script
Change-Id: I1280b5e06ab9ab1fec015b51836d07da85c9f61f Signed-off-by: Jan-Simon Möller <jsmoeller@linuxfoundation.org>
Diffstat (limited to 'packer')
-rw-r--r--packer/provision/agl_dependencies.sh19
-rw-r--r--packer/provision/agl_mirror.sh17
-rw-r--r--packer/templates/basebuild.json1
3 files changed, 20 insertions, 17 deletions
diff --git a/packer/provision/agl_dependencies.sh b/packer/provision/agl_dependencies.sh
index c166e287..4aa45a1b 100644
--- a/packer/provision/agl_dependencies.sh
+++ b/packer/provision/agl_dependencies.sh
@@ -1,5 +1,7 @@
#!/bin/bash
+DEBIAN_FRONTEND=noninteractive apt-get update && apt-get -y -u dist-upgrade
+
DEBIAN_FRONTEND=noninteractive apt-get update && \
apt-get -y install gawk wget git-core diffstat unzip texinfo gcc-multilib build-essential chrpath socat \
libsdl1.2-dev xterm make xsltproc docbook-utils fop dblatex xmlto autoconf automake \
@@ -17,20 +19,3 @@ cat <<EOFHOSTS >> /etc/hosts
199.19.213.77 download-new.automotivelinux.org
EOFHOSTS
-
-
-# Preclone the gerrit repos for speed (use with --reference=/opt/AGL/preclone)
-mkdir -p /opt/AGL/preclone
-cd /opt/AGL/preclone
-repo init -u https://gerrit.automotivelinux.org/gerrit/AGL/AGL-repo
-repo sync
-cd
-
-#mirror sstate-cache into /opt/AGL/sstate-mirror
-mkdir -p /opt/AGL/sstate-mirror
-cd /opt/AGL/sstate-mirror
-wget --mirror -np -nH --convert-links "https://download-new.automotivelinux.org/sstate-mirror/" -A siginfo -A tgz --cut-dirs=1
-ls
-ls *
-cd
-
diff --git a/packer/provision/agl_mirror.sh b/packer/provision/agl_mirror.sh
new file mode 100644
index 00000000..e2a6b8c1
--- /dev/null
+++ b/packer/provision/agl_mirror.sh
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+# Preclone the gerrit repos for speed (use with --reference=/opt/AGL/preclone)
+mkdir -p /opt/AGL/preclone
+cd /opt/AGL/preclone
+repo init -u https://gerrit.automotivelinux.org/gerrit/AGL/AGL-repo
+repo sync
+cd
+
+#mirror sstate-cache into /opt/AGL/sstate-mirror
+mkdir -p /opt/AGL/sstate-mirror
+cd /opt/AGL/sstate-mirror
+wget --mirror -np -nH --convert-links "https://download-new.automotivelinux.org/sstate-mirror/" -A siginfo -A tgz --cut-dirs=1
+ls
+ls *
+cd
+
diff --git a/packer/templates/basebuild.json b/packer/templates/basebuild.json
index cb103f4b..b757f6af 100644
--- a/packer/templates/basebuild.json
+++ b/packer/templates/basebuild.json
@@ -45,6 +45,7 @@
"provision/baseline.sh",
"provision/basebuild.sh",
"provision/agl_dependencies.sh",
+ "provision/agl_mirror.sh",
"provision/system_reseal.sh"
],
"execute_command": "chmod +x {{ .Path }}; if [ \"$UID\" == \"0\" ]; then {{ .Vars }} '{{ .Path }}'; else {{ .Vars }} sudo -E '{{ .Path }}'; fi"