#!/usr/bin/with-contenv bash if [ ! -d "/config/arsse" ] || [ ! "$(ls -A "/config/arsse")" ]; then echo -n "[init-config] Copying defaults to /config/arsse..." cp -R /default/arsse/. /config/arsse echo " done" fi if [ ! -d "/config/nginx" ] || [ ! "$(ls -A "/config/nginx")" ]; then echo -n "[init-config] Copying defaults to /config/nginx..." cp -R /default/nginx/. /config/nginx echo " done" fi if [ ! -d "/config/log" ] || [ ! "$(ls -A "/config/log")" ]; then echo -n "[init-config] Creating log folder at /config/log..." mkdir -p /config/log/php mkdir -p /config/log/nginx echo " done" fi echo -n "[init-config] Setting permissions for ook user..." chown -R ook:ook /app /config /default 2>/dev/null echo " done"