mirror of
https://github.com/YunoHost-Apps/onlyoffice_ynh.git
synced 2024-09-03 19:56:11 +02:00
Fixes
This commit is contained in:
parent
5e3e306a8f
commit
40e2c06f5f
3 changed files with 8 additions and 13 deletions
|
@ -21,7 +21,8 @@
|
||||||
"nginx"
|
"nginx"
|
||||||
],
|
],
|
||||||
"arguments": {
|
"arguments": {
|
||||||
"install": [{
|
"install" : [
|
||||||
|
{
|
||||||
"name": "domain",
|
"name": "domain",
|
||||||
"type": "domain",
|
"type": "domain",
|
||||||
"ask": {
|
"ask": {
|
||||||
|
@ -29,8 +30,7 @@
|
||||||
"fr": "Choisissez un nom de domaine pour OnlyOffice"
|
"fr": "Choisissez un nom de domaine pour OnlyOffice"
|
||||||
},
|
},
|
||||||
"example": "example.com"
|
"example": "example.com"
|
||||||
},
|
},
|
||||||
|
|
||||||
{
|
{
|
||||||
"name": "nextclouddomain",
|
"name": "nextclouddomain",
|
||||||
"type": "string",
|
"type": "string",
|
||||||
|
@ -40,8 +40,7 @@
|
||||||
},
|
},
|
||||||
"example": "example.com",
|
"example": "example.com",
|
||||||
"default": "example.com"
|
"default": "example.com"
|
||||||
},
|
},
|
||||||
|
|
||||||
{
|
{
|
||||||
"name": "is_public",
|
"name": "is_public",
|
||||||
"type": "boolean",
|
"type": "boolean",
|
||||||
|
|
|
@ -25,7 +25,6 @@ ynh_abort_if_errors
|
||||||
# RETRIEVE ARGUMENTS FROM THE MANIFEST
|
# RETRIEVE ARGUMENTS FROM THE MANIFEST
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
# Retrieve arguments
|
|
||||||
domain=$YNH_APP_ARG_DOMAIN
|
domain=$YNH_APP_ARG_DOMAIN
|
||||||
path_url="/"
|
path_url="/"
|
||||||
is_public=$YNH_APP_ARG_IS_PUBLIC
|
is_public=$YNH_APP_ARG_IS_PUBLIC
|
||||||
|
@ -65,9 +64,9 @@ ynh_webpath_register $app $domain $path_url
|
||||||
ynh_print_info "Storing installation settings..."
|
ynh_print_info "Storing installation settings..."
|
||||||
|
|
||||||
ynh_app_setting_set $app domain $domain
|
ynh_app_setting_set $app domain $domain
|
||||||
ynh_app_setting_set $app nextclouddomain $nextclouddomain
|
|
||||||
ynh_app_setting_set $app path $path_url
|
ynh_app_setting_set $app path $path_url
|
||||||
ynh_app_setting_set $app is_public $is_public
|
ynh_app_setting_set $app is_public $is_public
|
||||||
|
ynh_app_setting_set $app nextclouddomain $nextclouddomain
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# STANDARD MODIFICATIONS
|
# STANDARD MODIFICATIONS
|
||||||
|
@ -82,7 +81,7 @@ ynh_print_info "Configuring firewall..."
|
||||||
### - Remove the section "CLOSE A PORT" in the remove script
|
### - Remove the section "CLOSE A PORT" in the remove script
|
||||||
|
|
||||||
# Find a free port
|
# Find a free port
|
||||||
port=$(ynh_find_port 9980)
|
port=$(ynh_find_port 8095)
|
||||||
# Open this port
|
# Open this port
|
||||||
#ynh_exec_warn_less yunohost firewall allow --no-upnp TCP $port
|
#ynh_exec_warn_less yunohost firewall allow --no-upnp TCP $port
|
||||||
ynh_app_setting_set $app port $port
|
ynh_app_setting_set $app port $port
|
||||||
|
@ -190,7 +189,7 @@ ynh_install_app_dependencies postgresql libstdc++6 redis-server rabbitmq-server
|
||||||
ynh_print_info "Fix config file..."
|
ynh_print_info "Fix config file..."
|
||||||
|
|
||||||
# Fix https://github.com/ONLYOFFICE/onlyoffice-owncloud/issues/172#issuecomment-411746394
|
# Fix https://github.com/ONLYOFFICE/onlyoffice-owncloud/issues/172#issuecomment-411746394
|
||||||
cp -f ../conf/default.json /etc/onlyoffice/documentserver/default.json
|
#cp -f ../conf/default.json /etc/onlyoffice/documentserver/default.json
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# STORE THE CONFIG FILE CHECKSUM
|
# STORE THE CONFIG FILE CHECKSUM
|
||||||
|
@ -215,7 +214,7 @@ cp -f ../conf/default.json /etc/onlyoffice/documentserver/default.json
|
||||||
### that really need such authorization.
|
### that really need such authorization.
|
||||||
|
|
||||||
# Set permissions to app files
|
# Set permissions to app files
|
||||||
chown -R $app: $final_path
|
#chown -R $app: $final_path
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# SETUP SSOWAT
|
# SETUP SSOWAT
|
||||||
|
|
|
@ -31,8 +31,6 @@ final_path=$(ynh_app_setting_get $app final_path)
|
||||||
ynh_print_info "Removing the PostgreSQL database"
|
ynh_print_info "Removing the PostgreSQL database"
|
||||||
|
|
||||||
# Remove a database if it exists, along with the associated user
|
# Remove a database if it exists, along with the associated user
|
||||||
ynh_psql_execute_as_root "\connect $db_name
|
|
||||||
SELECT pg_terminate_backend (pg_stat_activity.pid) FROM pg_stat_activity WHERE pg_stat_activity.datname = '$db_name';"
|
|
||||||
ynh_psql_remove_db $db_name $db_name
|
ynh_psql_remove_db $db_name $db_name
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -93,7 +91,6 @@ ynh_secure_remove "/var/log/$app/"
|
||||||
ynh_print_info "Removing the dedicated system user"
|
ynh_print_info "Removing the dedicated system user"
|
||||||
|
|
||||||
# Delete a system user
|
# Delete a system user
|
||||||
gpasswd -d www-data onlyoffice
|
|
||||||
ynh_system_user_delete $app
|
ynh_system_user_delete $app
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
Loading…
Add table
Reference in a new issue