add helper scripts for mongodb

This commit is contained in:
gcarq 2017-11-25 03:28:18 +01:00
parent e27a6a7a91
commit 2fe11cd77a
2 changed files with 12 additions and 5 deletions

View File

@ -1,5 +1,12 @@
#!/bin/bash
#!/bin/bash -e
DB_NAME=freqtrade_hyperopt
hyperopt-mongo-worker --mongo=127.0.0.1:1234/${DB_NAME} --poll-interval=0.1
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
WORK_DIR="${DIR}/../.hyperopt/worker"
mkdir -p "${WORK_DIR}"
hyperopt-mongo-worker \
--mongo="127.0.0.1:1234/${DB_NAME}" \
--poll-interval=0.1 \
--workdir="${WORK_DIR}"

View File

@ -1,10 +1,10 @@
#!/bin/bash -e
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
DB_PATH="${DIR}/../.mongodb"
DB_PATH="${DIR}/../.hyperopt/mongodb"
mkdir -p ${DB_PATH}
mongod --dbpath ${DB_PATH} \
mkdir -p "${DB_PATH}"
mongod --dbpath "${DB_PATH}" \
--bind_ip 127.0.0.1 \
--port 1234 \
--directoryperdb \