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