Allow multiple mounts

https://github.com/alexbelgium/hassio-addons/issues/786
This commit is contained in:
Alexandre
2023-04-10 18:07:44 +02:00
committed by GitHub
parent 3d267fc9ec
commit 5811ea0bdd

View File

@@ -11,7 +11,7 @@ if bashio::config.has_value 'networkdisks'; then
MOREDISKS=$(bashio::config 'networkdisks')
CIFS_USERNAME=$(bashio::config 'cifsusername')
CIFS_PASSWORD=$(bashio::config 'cifspassword')
MOUNTED=false
SMBVERS=""
SECVERS=""
@@ -50,6 +50,7 @@ if bashio::config.has_value 'networkdisks'; then
disk="${disk//"\040"/ }" #replace \040 with
diskname="${disk//\\//}" #replace \ with /
diskname="${diskname##*/}" # Get only last part of the name
MOUNTED=false
# Data validation
if [[ ! $disk =~ ^.*+[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+[/]+.*+$ ]]; then