Files
appstore/apps/wikijs-linuxserver/2.5.317/scripts/upgrade.sh
T
renovate[bot]andgithub-action update-app-version 29088755a0 Update linuxserver/wikijs Docker tag to v2.5.317 (#8848)
* Update linuxserver/wikijs Docker tag to v2.5.317

* Update app version [skip ci]

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: github-action update-app-version <githubaction@githubaction.com>
2026-11-13 19:20:57 +08:00

34 lines
721 B
Bash
Executable File

#!/usr/bin/env bash
set -euo pipefail
ENV_FILE="${ENV_FILE:-./.env}"
ensure_env_default() {
local key="$1"
local value="$2"
if [[ ! -f "$ENV_FILE" ]]; then
echo "$ENV_FILE not found; skipped $key migration"
return
fi
if grep -qE "^${key}=" "$ENV_FILE"; then
echo "$key already exists"
return
fi
printf '%s=%s\n' "$key" "$value" >> "$ENV_FILE"
echo "Added $key"
}
if [[ -f "$ENV_FILE" ]]; then
ensure_env_default "DB_TYPE" "sqlite"
ensure_env_default "DB_HOST" ""
ensure_env_default "DB_PORT" ""
ensure_env_default "DB_NAME" ""
ensure_env_default "DB_USER" ""
ensure_env_default "DB_PASS" ""
else
echo "$ENV_FILE not found; skipped LinuxServer environment migration"
fi