Skip to content
Snippets Groups Projects
Commit 9171938b authored by Michel Memeteau's avatar Michel Memeteau
Browse files

Merge branch 'fb-master-patch-12546' into 'master'

add get_size

See merge request !195
parents 27d6014c aefa3775
No related branches found
No related tags found
No related merge requests found
......@@ -37,6 +37,7 @@ function show_usage {
echo " - update: to update the current folder."
echo " - stats: show docker stats with names."
echo " - delete <domainname>: remove a libre.sh service."
echo " - getsize <domainname>: give you the size of the installed application"
exit 1
}
......@@ -100,6 +101,16 @@ case "$1" in
rm /system/haproxy/haproxy/certs/${2}.pem
fi
fi;;
getsize)
# check the current size
if [ $# -ne 2 ]; then
echo "getsize requires a domainname argument."
exit 1
fi
SIZE="`du -hs ${2}`"
#SIZE=${SIZE%G*}
echo $(du -hs ${2}) |cut -d ' ' -f 1;;
*)
show_usage
esac
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment