# Script reponsible for execution of all actions required to finish configuration of the database holding a HAF database to work correctly with hivemind.
print_help (){
echo"Usage: $0 [OPTION[=VALUE]]..."
echo
echo"Allows to setup a database already filled by HAF instance, to work with hivemind application."
echo"OPTIONS:"
echo" --host=VALUE Allows to specify a PostgreSQL host location (defaults to /var/run/postgresql)"
echo" --port=NUMBER Allows to specify a PostgreSQL operating port (defaults to 5432)"
echo" --postgres-url=URL Allows to specify a PostgreSQL URL (in opposite to separate --host and --port options)"
#docker run -it --rm --name=haf-hivemind-instance -e POSTGRES_URL=postgresql://haf_app_admin@172.17.0.7:5432/haf_block_log registry.gitlab.syncad.com/hive/hivemind/instance:3c0c897a sync --database-url=postgresql://haf_app_admin@172.17.0.7:5432/haf_block_log
docker run --rm-it-eUID=$(id-u)-eGID=$(id-g)--name"$CONTAINER_NAME"--stop-timeout=180 ${DOCKER_ARGS[@]}-ePOSTGRES_URL="${POSTGRES_ACCESS}""${IMAGE_NAME}""${CMD_ARGS[@]}"