Simple Linux Panel
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
mdserver-web/plugins/mongodb/versions/7.0/macos.sh

29 lines
985 B

2 years ago
#!/bin/bash
PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:~/bin
export PATH
curPath=`pwd`
rootPath=$(dirname "$curPath")
rootPath=$(dirname "$rootPath")
2 years ago
rootPath=$(dirname "$rootPath")
2 years ago
serverPath=$(dirname "$rootPath")
install_tmp=${rootPath}/tmp/mw_install.pl
VERSION=7.0.0
MG_DIR=$serverPath/source/mongodb
mkdir -p $MG_DIR
if [ ! -f $MG_DIR/mongodb-macos-x86_64-${VERSION}.tgz ]; then
wget --no-check-certificate -O $MG_DIR/mongodb-macos-x86_64-${VERSION}.tgz https://fastdl.mongodb.org/osx/mongodb-macos-x86_64-${VERSION}.tgz
echo "wget --no-check-certificate -O $MG_DIR/mongodb-macos-x86_64-${VERSION}.tgz https://fastdl.mongodb.org/osx/mongodb-macos-x86_64-${VERSION}.tgz"
fi
if [ ! -d $MG_DIR/mongodb-macos-x86_64-${VERSION} ];then
cd $MG_DIR && tar -zxvf mongodb-macos-x86_64-${VERSION}.tgz
fi
2 years ago
if [ ! -d $serverPath/mongodb/bin ];then
2 years ago
mkdir -p $serverPath/mongodb
cd $MG_DIR/mongodb-macos-x86_64-${VERSION} && cp -rf ./bin $serverPath/mongodb
fi