From 2c373c5ac4a3fd226ea88700d56976a2e3e7aa71 Mon Sep 17 00:00:00 2001 From: casjay Date: Mon, 3 Jul 2023 21:55:45 -0400 Subject: [PATCH] =?UTF-8?q?=F0=9F=97=83=EF=B8=8F=20Committing=20everything?= =?UTF-8?q?=20that=20changed=20=F0=9F=97=83=EF=B8=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit rootfs/usr/local/bin/entrypoint.sh rootfs/usr/local/etc/docker/init.d/zz-default.sh --- rootfs/usr/local/bin/entrypoint.sh | 2 +- rootfs/usr/local/etc/docker/init.d/zz-default.sh | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/rootfs/usr/local/bin/entrypoint.sh b/rootfs/usr/local/bin/entrypoint.sh index 2be232d..bffdf1f 100755 --- a/rootfs/usr/local/bin/entrypoint.sh +++ b/rootfs/usr/local/bin/entrypoint.sh @@ -79,7 +79,7 @@ PGSQL_CONFIG_FILE="${PGSQL_CONFIG_FILE:-$(__find_pgsql_conf)}" MONGODB_CONFIG_FILE="${MONGODB_CONFIG_FILE:-$(__find_mongodb_conf)}" # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # Overwrite variables - +export PATH_SQLITE_DB="${PATH_SQLITE_DB:-/data/db/rarbg/database.sqlite}" # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # Last thing to run before options __run_pre() { diff --git a/rootfs/usr/local/etc/docker/init.d/zz-default.sh b/rootfs/usr/local/etc/docker/init.d/zz-default.sh index ae1e952..8fd8c0b 100755 --- a/rootfs/usr/local/etc/docker/init.d/zz-default.sh +++ b/rootfs/usr/local/etc/docker/init.d/zz-default.sh @@ -167,8 +167,11 @@ __update_conf_files() { __pre_execute() { local exitCode=0 # default exit code local user="${SERVICE_USER:-root}" # specifiy different user + local rargb_dir="/data/db/rarbg" + local rargb_db="/usr/local/share/template-files/data/db/rarbg/database.sqlite" # define commands - + [ -d "$rargb_dir" ] || mkdir -p "$rargb_dir" + [ -f "$rargb_dir/database.sqlite" ] || cp -Rf "$rargb_db" "$rargb_dir/database.sqlite" # execute if directories is empty #__is_dir_empty "" &&