Add an initial working configuration for LibreTranslate.

This commit is contained in:
2025-07-23 05:55:40 -07:00
parent e661b67b57
commit 593b1fbaf2
6 changed files with 201 additions and 0 deletions

21
Config/LibreTranslate/prep.sh Executable file
View File

@@ -0,0 +1,21 @@
#!/usr/bin/env bash
# 2025-07-22 Hyperling
# Create the necessary folders for LibreTranslate's volumes to work.
# This must be run before the container will start properly.
## Setup ##
DIR="$(dirname -- "${BASH_SOURCE[0]}")"
source $DIR/.env
## Main ##
if [[ $API_KEYS_DIR == "../*" ]]; then
API_KEYS_DIR="$DIR/$API_KEYS_DIR"
fi
mkdir -pv $API_KEYS_DIR
if [[ $MODELS_DIR == "../*" ]]; then
MODELS_DIR="$DIR/$MODELS_DIR"
fi
mkdir -pv $MODELS_DIR