mirror of
https://github.com/YunoHost-Apps/dont-code_ynh.git
synced 2024-09-03 18:26:34 +02:00
commit
301b79282b
3 changed files with 22 additions and 7 deletions
|
@ -8,18 +8,18 @@
|
||||||
public_key="dummy public key"
|
public_key="dummy public key"
|
||||||
is_public=1
|
is_public=1
|
||||||
; Checks
|
; Checks
|
||||||
pkg_linter=1
|
pkg_linter=0
|
||||||
setup_sub_dir=1
|
setup_sub_dir=1
|
||||||
setup_root=1
|
setup_root=0
|
||||||
setup_nourl=0
|
setup_nourl=0
|
||||||
setup_private=0
|
setup_private=0
|
||||||
setup_public=1
|
setup_public=0
|
||||||
upgrade=1
|
upgrade=0
|
||||||
upgrade=0 from_commit=CommitHash
|
upgrade=0 from_commit=CommitHash
|
||||||
backup_restore=1
|
backup_restore=0
|
||||||
multi_instance=0
|
multi_instance=0
|
||||||
port_already_use=1 (8083)
|
port_already_use=0 (8083)
|
||||||
change_url=1
|
change_url=0
|
||||||
;;; Options
|
;;; Options
|
||||||
Email=ger@shared.collin.best
|
Email=ger@shared.collin.best
|
||||||
Notification=Down
|
Notification=Down
|
||||||
|
|
|
@ -27,6 +27,7 @@ db_user=$(ynh_app_setting_get --app=$app --key=db_user)
|
||||||
final_path=$(ynh_app_setting_get --app=$app --key=final_path)
|
final_path=$(ynh_app_setting_get --app=$app --key=final_path)
|
||||||
html_path=$(ynh_app_setting_get --app=$app --key=html_path)
|
html_path=$(ynh_app_setting_get --app=$app --key=html_path)
|
||||||
document_path=$(ynh_app_setting_get --app=$app --key=document_path)
|
document_path=$(ynh_app_setting_get --app=$app --key=document_path)
|
||||||
|
public_key=$(ynh_app_setting_get --app=$app --key=public_key)
|
||||||
|
|
||||||
PORT_LIST=($port_ide $port_preview $port_project $port_data)
|
PORT_LIST=($port_ide $port_preview $port_project $port_data)
|
||||||
|
|
||||||
|
@ -135,6 +136,13 @@ ynh_script_progression --message="Removing various files..." --weight=1
|
||||||
# Remove the log files
|
# Remove the log files
|
||||||
ynh_secure_remove --file="/var/log/$app"
|
ynh_secure_remove --file="/var/log/$app"
|
||||||
|
|
||||||
|
if [ -n "$public_key" ]
|
||||||
|
then
|
||||||
|
ynh_script_progression --message="Removing ssh dev access" --weight=1
|
||||||
|
ynh_secure_remove --file="/etc/sudoers.d/$app-sudoers"
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# GENERIC FINALIZATION
|
# GENERIC FINALIZATION
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
|
@ -319,6 +319,13 @@ ynh_install_mongo() {
|
||||||
# Make sure MongoDB is started and enabled
|
# Make sure MongoDB is started and enabled
|
||||||
systemctl enable $mongodb_servicename --quiet
|
systemctl enable $mongodb_servicename --quiet
|
||||||
systemctl daemon-reload --quiet
|
systemctl daemon-reload --quiet
|
||||||
|
|
||||||
|
# Test mongod to see if it crashes
|
||||||
|
ynh_exec_err /usr/bin/mongod --config /etc/mongodb.conf
|
||||||
|
sleep 60
|
||||||
|
pkill mongod
|
||||||
|
ynh_exec_err cat /var/log/mongodb/mongod.conf
|
||||||
|
|
||||||
ynh_systemd_action --service_name=$mongodb_servicename --action=restart --line_match="aiting for connections" --log_path="systemd" --length=100 --timeout=60
|
ynh_systemd_action --service_name=$mongodb_servicename --action=restart --line_match="aiting for connections" --log_path="systemd" --length=100 --timeout=60
|
||||||
|
|
||||||
# Integrate MongoDB service in YunoHost
|
# Integrate MongoDB service in YunoHost
|
||||||
|
|
Loading…
Reference in a new issue