[projects/cleanbuild] add no tmpfs commandline option
glen
glen at pld-linux.org
Mon Dec 31 10:29:04 CET 2018
commit 8447721f088e61dc473663e15af18340155776d1
Author: Elan Ruusamäe <glen at pld-linux.org>
Date: Mon Dec 31 11:22:16 2018 +0200
add no tmpfs commandline option
cleanbuild-docker.sh | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/cleanbuild-docker.sh b/cleanbuild-docker.sh
index cd3450b..8f4f7c3 100755
--- a/cleanbuild-docker.sh
+++ b/cleanbuild-docker.sh
@@ -7,6 +7,7 @@ PROGRAM=${0##*/}
: ${PACKAGE_NAME=''}
: ${NETWORKING=false}
: ${TRACING=false}
+: ${TMPFS=true}
dir=$(pwd)
image=registry.gitlab.com/pld-linux/cleanbuild
@@ -33,7 +34,7 @@ create_container() {
-v $dir:$home/cleanbuild \
-v $dir/cache/poldek:/var/cache/poldek \
-v $dir/cache/ccache/$PACKAGE_NAME:$home/.ccache \
- --tmpfs $home/rpm/BUILD:rw,exec,nosuid,size=$buildsize \
+ $($TMPFS && echo "--tmpfs $home/rpm/BUILD:rw,exec,nosuid,size=$buildsize") \
$image
# set the homedir
@@ -107,7 +108,7 @@ package_build() {
parse_options() {
local t
- t=$(getopt -o 'x' --long 'network' -n "$PROGRAM" -- "$@")
+ t=$(getopt -o 'x' --long 'network,no-tmpfs,notmpfs' -n "$PROGRAM" -- "$@")
[ $? != 0 ] && exit $?
eval set -- "$t"
@@ -119,6 +120,9 @@ parse_options() {
--network)
NETWORKING=true
;;
+ --no-tmpfs|--notmpfs)
+ TMPFS=false
+ ;;
--)
shift
break
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/projects/cleanbuild.git/commitdiff/2da31caa754f920335a6c371f2b883b570fe717f
More information about the pld-cvs-commit
mailing list