Skip to content
This repository has been archived by the owner on Nov 29, 2020. It is now read-only.

Commit

Permalink
Merge pull request #113 from dazuimao1990/devel
Browse files Browse the repository at this point in the history
[FIX] change the way to check / size
  • Loading branch information
barnettZQG committed Aug 29, 2019
2 parents 7227d73 + 6cd8c54 commit 7349593
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ precheck::check_port(){

# Detection of the disk
precheck::check_disk(){
local disk=$(df -h | grep "/$" | awk '{print $2}' | tr 'G' ' ')
local disk=$(df -h -B 1g | grep "/$" | awk '{print $2}')
DISK_LIMIT=30
DISK_STATUS=$(awk -v num1=$disk -v num2=$DISK_LIMIT 'BEGIN{print(num1>=num2)?"0":"1"}')
if [ "$DISK_STATUS" == '0' ]; then
Expand Down

0 comments on commit 7349593

Please sign in to comment.