mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-01-10 09:51:02 +01:00
Update 20-folders.sh
This commit is contained in:
@@ -5,14 +5,12 @@ CONFIGSOURCE=$(bashio::config "CONFIG_LOCATION")
|
||||
CONFIGSOURCE=$(dirname "$CONFIGSOURCE")
|
||||
|
||||
# Create directory
|
||||
mkdir -p "$CONFIGSOURCE" || true
|
||||
mkdir -p "$CONFIGSOURCE/import_files" || true
|
||||
mkdir -p "$CONFIGSOURCE/configurations" || true
|
||||
mkdir -p "$CONFIGSOURCE"
|
||||
|
||||
# Create symlinks
|
||||
cp -rnf /data/configurations "$CONFIGSOURCE"
|
||||
rm -r /data/configurations
|
||||
ln -s "$CONFIGSOURCE"/configurations /data
|
||||
ln -sf "$CONFIGSOURCE" /data/configurations
|
||||
|
||||
# Make sure permissions are right
|
||||
chown -R "$(id -u):$(id -g)" "$CONFIGSOURCE"
|
||||
|
||||
Reference in New Issue
Block a user