mirror of
https://github.com/YunoHost-Apps/abantecart_ynh.git
synced 2024-09-03 18:06:16 +02:00
Update install
This commit is contained in:
parent
71675545e4
commit
d77d4de8da
1 changed files with 4 additions and 5 deletions
|
@ -9,6 +9,7 @@ path=$2
|
||||||
is_public=$3
|
is_public=$3
|
||||||
password=$4
|
password=$4
|
||||||
with_mysql=$5
|
with_mysql=$5
|
||||||
|
user_db=$6
|
||||||
|
|
||||||
app=$YNH_APP_INSTANCE_NAME
|
app=$YNH_APP_INSTANCE_NAME
|
||||||
|
|
||||||
|
@ -31,15 +32,13 @@ ynh_app_setting_set "$app" user "$user"
|
||||||
|
|
||||||
# Initialize database as needed
|
# Initialize database as needed
|
||||||
if [[ $with_mysql -eq 1 ]]; then
|
if [[ $with_mysql -eq 1 ]]; then
|
||||||
dbname=$app
|
dbname=$6
|
||||||
dbuser=$app
|
dbuser=$6
|
||||||
dbpass=$4
|
dbpass=$4
|
||||||
ynh_mysql_create_db "$dbname" "$dbuser" "$dbpass"
|
ynh_mysql_create_db "$dbname" "$dbuser" "$dbpass"
|
||||||
|
|
||||||
# Store the database access
|
# Store the database access
|
||||||
echo -e "# MySQL Database
|
ynh_app_setting_set "$app" mysqlpwd "$dbpass"
|
||||||
name: ${dbname}\nuser: ${dbuser}\npass: ${dbpass}" > ../sources/db_access.txt
|
|
||||||
ynh_app_setting_set "$app" mysqlpwd "$dbpass"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Remove trailing "/" for next commands
|
# Remove trailing "/" for next commands
|
||||||
|
|
Loading…
Add table
Reference in a new issue