mirror of
https://github.com/YunoHost-Apps/leed_ynh.git
synced 2024-09-03 19:26:32 +02:00
Put domain/path check before writing setting
This commit is contained in:
parent
a6df2b0284
commit
a3524837f6
1 changed files with 4 additions and 4 deletions
|
@ -13,16 +13,16 @@ if [[ ! $? -eq 0 ]]; then
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Add settings to YunoHost
|
|
||||||
sudo yunohost app setting leed admin -v $admin
|
|
||||||
sudo yunohost app setting leed language -v $language
|
|
||||||
|
|
||||||
# Check domain/path availability
|
# Check domain/path availability
|
||||||
sudo yunohost app checkurl $domain$path -a leed
|
sudo yunohost app checkurl $domain$path -a leed
|
||||||
if [[ ! $? -eq 0 ]]; then
|
if [[ ! $? -eq 0 ]]; then
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Add settings to YunoHost
|
||||||
|
sudo yunohost app setting leed admin -v $admin
|
||||||
|
sudo yunohost app setting leed language -v $language
|
||||||
|
|
||||||
# Generate random password
|
# Generate random password
|
||||||
db_pwd=$(dd if=/dev/urandom bs=1 count=200 2> /dev/null | tr -c -d 'A-Za-z0-9' | sed -n 's/\(.\{24\}\).*/\1/p')
|
db_pwd=$(dd if=/dev/urandom bs=1 count=200 2> /dev/null | tr -c -d 'A-Za-z0-9' | sed -n 's/\(.\{24\}\).*/\1/p')
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue