aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--build/Makefile2
-rwxr-xr-xbuild/install/install.sh3
-rwxr-xr-xci/clean_cache.sh38
-rw-r--r--deploy/reap.py2
4 files changed, 42 insertions, 3 deletions
diff --git a/build/Makefile b/build/Makefile
index 94e5b3460..fdfb23971 100644
--- a/build/Makefile
+++ b/build/Makefile
@@ -86,7 +86,7 @@ all:
@KERNEL_VER=$$(uname -r); \
KERNEL_ARRAY=($${KERNEL_VER//./ }); \
if [ $${KERNEL_ARRAY[0]} -lt 3 ] || [[ $${KERNEL_ARRAY[0]} -eq 3 && $${KERNEL_ARRAY[1]} -lt 19 ]] ; then (echo 'Kernel version must be 3.19 or newer'; exit 1) ; fi
- @docker/runcontext $(DOCKERIMG) wget -q www.google.com > /dev/null 2>&1 || (echo 'No docker network connectivity or name server - check your network- and docker settings'; exit 1)
+ @docker/runcontext $(DOCKERIMG) wget -q www.google.com -O /dev/null || (echo 'No docker network connectivity or name server - check your network- and docker settings'; exit 1)
@docker/runcontext $(DOCKERIMG) $(MAKE) $(MAKEFLAGS) iso
diff --git a/build/install/install.sh b/build/install/install.sh
index 4e0389ed8..c63241974 100755
--- a/build/install/install.sh
+++ b/build/install/install.sh
@@ -172,7 +172,7 @@ make_live() {
prep_make_iso() {
DEST=$TOP/newiso
REPO=$DEST/ubuntu
- echo "Making ISO..."
+ echo "Preparing ISO..."
echo "Unpack of old ISO..."
if [ -d newiso ]; then
chmod -R 755 newiso
@@ -201,6 +201,7 @@ make_iso_image() {
-no-emul-boot \
-boot-load-size 4 -boot-info-table \
--hide-rr-moved \
+ --joliet-long \
-x "lost+found" -o $NEWISO .
isoinfo -d -i $NEWISO
diff --git a/ci/clean_cache.sh b/ci/clean_cache.sh
new file mode 100755
index 000000000..177fe821b
--- /dev/null
+++ b/ci/clean_cache.sh
@@ -0,0 +1,38 @@
+#!/bin/bash
+##############################################################################
+# Copyright (c) 2016 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+# Clean the build cache according to its expiry date. Invoke with the cache
+# directory as the first argument.
+
+if [ -z "$1" ]; then
+ echo "No cache directory specified, exiting..."
+ exit 1
+else
+ CACHEDIR=$1
+ echo "Operating on cache $CACHEDIR"
+fi
+
+NOW=$(date '+%s')
+
+cd $CACHEDIR
+echo "Step 1, cleaning orphaned meta and blob files"
+ls *.meta *.blob | sed 's/\..*//' | sort | uniq -u | xargs -n 1 -I {} sh -c "rm -vf {}.*"
+echo "Step 2, cleaning expired files"
+for cache in $(ls -1 *.meta | sed 's/\..*//')
+do
+ blob=${cache}.blob
+ meta=${cache}.meta
+ expiry=$(grep Expires: $meta | sed 's/Expires: *//')
+ if [ $expiry -le $NOW ]; then
+ echo "$cache expired $(date -d "@$expiry"), removing..."
+ rm -f $blob $meta
+ fi
+done
+
diff --git a/deploy/reap.py b/deploy/reap.py
index 1262d4c71..c642a4243 100644
--- a/deploy/reap.py
+++ b/deploy/reap.py
@@ -244,7 +244,7 @@ class Reap(object):
fuel[key] = data[key]
for key in fuel['ADMIN_NETWORK'].keys():
if key not in ['ipaddress', 'netmask',
- 'dhcp_pool_start', 'dhcp_pool_end']:
+ 'dhcp_pool_start', 'dhcp_pool_end', 'ssh_network']:
del fuel['ADMIN_NETWORK'][key]
self.write_yaml(self.dea_file, {'fuel': fuel})