Skip to content

Commit

Permalink
remove debug code // rework copying config files
Browse files Browse the repository at this point in the history
  • Loading branch information
Drazzilb08 committed Feb 6, 2024
1 parent f018f46 commit db05ca1
Showing 1 changed file with 4 additions and 10 deletions.
14 changes: 4 additions & 10 deletions root/etc/s6-overlay/s6-rc.d/init-setup-app/run
Original file line number Diff line number Diff line change
Expand Up @@ -6,24 +6,18 @@ umask "${UMASK}"
echo "
------------------------------------------------
Starting userScripts
PUID: ${PUID}
PGID: ${PGID}
UMASK: ${UMASK}
CONFIG_DIR: ${CONFIG_DIR}
DATA_DIR: ${DATA_DIR}
APP_DIR: ${APP_DIR}
------------------------------------------------
"

if [[ ! -f "${CONFIG_DIR}/config.yml" || ! -f "${CONFIG_DIR}/config.sample.yml" ]]; then
echo "Config file not found. Copying config.sample.yml to ${CONFIG_DIR}"
if [[ ! -f "${CONFIG_DIR}/config.sample.yml" || ! $(diff /app/config/config.sample.yml "${CONFIG_DIR}/config.sample.yml") ]]; then
echo "Config file not found or different. Copying config.sample.yml to ${CONFIG_DIR}"
cp /app/config/config.sample.yml "${CONFIG_DIR}"
fi
if [[ ! -f "${CONFIG_DIR}/backup-appdata.conf" || ! -f "${CONFIG_DIR}/backup-appdata-example.conf" ]]; then
if [[ ! -f "${CONFIG_DIR}/backup-appdata-example.conf" || ! $(diff /app/config/backup-appdata-example.conf "${CONFIG_DIR}/backup-appdata-example.conf") ]]; then
echo "Backup appdata config file not found. Copying backup-appdata-example.conf to ${CONFIG_DIR}"
cp /app/config/backup-appdata-example.conf "${CONFIG_DIR}"
fi
if [[ ! -f "${CONFIG_DIR}/backup-plex.conf" || ! -f "${CONFIG_DIR}/backup-plex-example.conf" ]]; then
if [[ ! -f "${CONFIG_DIR}/backup-plex-example.conf" || ! $(diff /app/config/backup-plex-example.conf "${CONFIG_DIR}/backup-plex-example.conf") ]]; then
echo "Backup plex config file not found. Copying backup-plex-example.conf to ${CONFIG_DIR}"
cp /app/config/backup-plex-example.conf "${CONFIG_DIR}"
fi
Expand Down

0 comments on commit db05ca1

Please sign in to comment.