meili scripting

This commit is contained in:
Bel LaPointe
2021-12-15 15:35:30 -07:00
parent 1e39a34c54
commit b3d26a88c2
4 changed files with 54 additions and 3 deletions

View File

@@ -1,10 +1,12 @@
#! /bin/bash
if [ ! -f ./meilisearch ]; then
if [ ! -f ./.meilisearch ]; then
echo "https://docs.meilisearch.com/learn/getting_started/installation.html#configuration-options"
curl -L https://install.meilisearch.com | sh
mv ./meilisearch ./.meilisearch
fi
args=("$@")
if [ "${#args[@]}" == 0 ]; then
args=(--db-path $PWD/data.ms --http-addr 0.0.0.0:7700)
fi
exec ./meilisearch "${args[@]}"
exec ./.meilisearch "${args[@]}"