1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/nodebb_ynh.git synced 2024-09-03 19:46:29 +02:00
This commit is contained in:
ericgaspar 2021-09-02 13:51:19 +02:00
parent c0aa948474
commit da4d8e4867
No known key found for this signature in database
GPG key ID: 574F281483054D44
2 changed files with 5 additions and 7 deletions

View file

@ -3,6 +3,7 @@
"secret": "__SECRET__", "secret": "__SECRET__",
"database": "postgres", "database": "postgres",
"port": "__PORT__", "port": "__PORT__",
"bind_address": "127.0.0.1",
"admin:username": "__ADMIN__", "admin:username": "__ADMIN__",
"admin:password": "__PASSWORD__", "admin:password": "__PASSWORD__",
"admin:password:confirm": "__PASSWORD__", "admin:password:confirm": "__PASSWORD__",

View file

@ -126,23 +126,20 @@ chown -R $app:www-data "$final_path"
ynh_script_progression --message="Configuring the $app..." --weight=2 ynh_script_progression --message="Configuring the $app..." --weight=2
setup="{ setup="{
\"url\": \"https://${domain}${path_url}\",
\"admin:username\": \"$admin\", \"admin:username\": \"$admin\",
\"admin:password\": \"$password\", \"admin:password\": \"$password\",
\"admin:password:confirm\": \"$password\", \"admin:password:confirm\": \"$password\",
\"admin:email\": \"admin@$domain\", \"admin:email\": \"admin@$domain\",
\"database\": \"postgres\",
\"postgres:host\": \"localhost\",
\"postgres:port\": \"5432\",
\"postgres:username\": \"$db_name\",
\"postgres:password\": \"$db_pwd\",
\"postgres:database\": \"$db_name\"
}" }"
pushd $final_path pushd $final_path
ynh_exec_as $app $ynh_node_load_PATH $final_path/nodebb setup "${setup}" | tee -a $install_log ynh_exec_as $app $ynh_node_load_PATH $final_path/nodebb setup "${setup}" | tee -a $install_log
popd popd
ynh_add_config --template="../conf/config.json" --destination="$final_path/config.json"
chmod 400 "$final_path/config.json"
chown $app:$app "$final_path/config.json"
#================================================= #=================================================
# NGINX CONFIGURATION # NGINX CONFIGURATION
#================================================= #=================================================