From 4c3d33fd691c83856ce372974931226e587a6d97 Mon Sep 17 00:00:00 2001 From: yalh76 Date: Fri, 1 Mar 2019 11:27:32 +0100 Subject: [PATCH 1/6] Fix release --- README.md | 2 ++ manifest.json | 2 +- scripts/_common.sh | 2 ++ scripts/install | 11 ++--------- scripts/restore | 11 ++--------- scripts/upgrade | 3 ++- 6 files changed, 11 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index cb4339f..8a5aeab 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,8 @@ If you don't have YunoHost, please see [here](https://yunohost.org/#/install) to ## Overview OnlyOffice Document Server +**Shipped version:** 5.2.8 + ## YunoHost specific features #### Supported architectures diff --git a/manifest.json b/manifest.json index fd17f2f..08763d2 100644 --- a/manifest.json +++ b/manifest.json @@ -6,7 +6,7 @@ "en": "OnlyOffice Document Server.", "fr": "Serveur de documents OnlyOffice." }, - "version": "1.0~ynh1", + "version": "5.2.8~ynh1", "url": "https://www.onlyoffice.com", "license": "GPL-3.0-or-later", "maintainer": { diff --git a/scripts/_common.sh b/scripts/_common.sh index b905339..252d16c 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -3,6 +3,8 @@ #================================================= # PERSONAL HELPERS #================================================= +source="https://github.com/ONLYOFFICE/DocumentServer/releases/download/ONLYOFFICE-DocumentServer-5.2.8/onlyoffice-documentserver_amd64.deb" +version="5.2.8" #================================================= # EXPERIMENTAL HELPERS diff --git a/scripts/install b/scripts/install index d4d1009..46aba29 100644 --- a/scripts/install +++ b/scripts/install @@ -92,14 +92,6 @@ ynh_print_info "Add nodejs repository..." curl -sL https://deb.nodesource.com/setup_8.x | sudo bash - -#================================================= -# ADD ONLYOFFICE REPOSITORY -#================================================= -ynh_print_info "Add OnlyOffice repository..." - -apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys CB2DE8E5 -echo "deb http://download.onlyoffice.com/repo/debian squeeze main" | sudo tee /etc/apt/sources.list.d/onlyoffice.list - #================================================= # INSTALL DEPENDENCIES #================================================= @@ -188,7 +180,8 @@ echo onlyoffice-documentserver onlyoffice/ds-port select ${port} | sudo debconf- #================================================= ynh_print_info "Install OnlyOffice..." -ynh_package_install onlyoffice-documentserver +wget $source +ynh_package_install onlyoffice-documentserver_amd64.deb #================================================= # MODIFY A CONFIG FILE diff --git a/scripts/restore b/scripts/restore index 975413d..caf8c67 100644 --- a/scripts/restore +++ b/scripts/restore @@ -94,14 +94,6 @@ ynh_print_info "Add nodejs repository..." curl -sL https://deb.nodesource.com/setup_8.x | sudo bash - -#================================================= -# ADD ONLYOFFICE REPOSITORY -#================================================= -ynh_print_info "Add OnlyOffice repository..." - -apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys CB2DE8E5 -echo "deb http://download.onlyoffice.com/repo/debian squeeze main" | sudo tee /etc/apt/sources.list.d/onlyoffice.list - #================================================= # REINSTALL DEPENDENCIES #================================================= @@ -131,7 +123,8 @@ echo onlyoffice-documentserver onlyoffice/ds-port select ${port} | sudo debconf- #================================================= ynh_print_info "Reinstalling OnlyOffice..." -ynh_package_install onlyoffice-documentserver +wget $source +ynh_package_install onlyoffice-documentserver_amd64.deb #================================================= # GENERIC FINALIZATION diff --git a/scripts/upgrade b/scripts/upgrade index 3cc0254..e467898 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -112,7 +112,8 @@ ynh_system_user_create $app $final_path #================================================= ynh_print_info "Upgrading OnlyOffice..." -ynh_package_install onlyoffice-documentserver +wget $source +ynh_package_install onlyoffice-documentserver_amd64.deb ### Verify the checksum of a file, stored by `ynh_store_file_checksum` in the install script. ### And create a backup of this file if the checksum is different. So the file will be backed up if the admin had modified it. From b7b11933cc62b7142542787fce3f91870006dfff Mon Sep 17 00:00:00 2001 From: yalh76 Date: Fri, 1 Mar 2019 11:32:49 +0100 Subject: [PATCH 2/6] Fix .deb install --- scripts/install | 2 +- scripts/restore | 2 +- scripts/upgrade | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/install b/scripts/install index 46aba29..ad78653 100644 --- a/scripts/install +++ b/scripts/install @@ -181,7 +181,7 @@ echo onlyoffice-documentserver onlyoffice/ds-port select ${port} | sudo debconf- ynh_print_info "Install OnlyOffice..." wget $source -ynh_package_install onlyoffice-documentserver_amd64.deb +dpkg -i onlyoffice-documentserver_amd64.deb #================================================= # MODIFY A CONFIG FILE diff --git a/scripts/restore b/scripts/restore index caf8c67..dc588a5 100644 --- a/scripts/restore +++ b/scripts/restore @@ -124,7 +124,7 @@ echo onlyoffice-documentserver onlyoffice/ds-port select ${port} | sudo debconf- ynh_print_info "Reinstalling OnlyOffice..." wget $source -ynh_package_install onlyoffice-documentserver_amd64.deb +dpkg -i onlyoffice-documentserver_amd64.deb #================================================= # GENERIC FINALIZATION diff --git a/scripts/upgrade b/scripts/upgrade index e467898..9995559 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -113,7 +113,7 @@ ynh_system_user_create $app $final_path ynh_print_info "Upgrading OnlyOffice..." wget $source -ynh_package_install onlyoffice-documentserver_amd64.deb +dpkg -i onlyoffice-documentserver_amd64.deb ### Verify the checksum of a file, stored by `ynh_store_file_checksum` in the install script. ### And create a backup of this file if the checksum is different. So the file will be backed up if the admin had modified it. From d7a43b92d084108a5bc3dd4bed1b7aed5ba84156 Mon Sep 17 00:00:00 2001 From: yalh76 Date: Fri, 1 Mar 2019 11:39:31 +0100 Subject: [PATCH 3/6] Add documentserver repository --- scripts/install | 8 ++++++++ scripts/restore | 8 ++++++++ scripts/upgrade | 15 +++++++++++++++ 3 files changed, 31 insertions(+) diff --git a/scripts/install b/scripts/install index ad78653..8bf82dd 100644 --- a/scripts/install +++ b/scripts/install @@ -92,6 +92,14 @@ ynh_print_info "Add nodejs repository..." curl -sL https://deb.nodesource.com/setup_8.x | sudo bash - +#================================================= +# ADD ONLYOFFICE REPOSITORY +#================================================= +ynh_print_info "Add OnlyOffice repository..." + +apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys CB2DE8E5 +echo "deb http://download.onlyoffice.com/repo/debian squeeze main" | sudo tee /etc/apt/sources.list.d/onlyoffice.list + #================================================= # INSTALL DEPENDENCIES #================================================= diff --git a/scripts/restore b/scripts/restore index dc588a5..0b13ac4 100644 --- a/scripts/restore +++ b/scripts/restore @@ -94,6 +94,14 @@ ynh_print_info "Add nodejs repository..." curl -sL https://deb.nodesource.com/setup_8.x | sudo bash - +#================================================= +# ADD ONLYOFFICE REPOSITORY +#================================================= +ynh_print_info "Add OnlyOffice repository..." + +apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys CB2DE8E5 +echo "deb http://download.onlyoffice.com/repo/debian squeeze main" | sudo tee /etc/apt/sources.list.d/onlyoffice.list + #================================================= # REINSTALL DEPENDENCIES #================================================= diff --git a/scripts/upgrade b/scripts/upgrade index 9995559..0fb2214 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -107,6 +107,21 @@ ynh_system_user_create $app $final_path #================================================= # SPECIFIC UPGRADE +#================================================= +# ADD NODEJS REPOSITORY +#================================================= +ynh_print_info "Add nodejs repository..." + +curl -sL https://deb.nodesource.com/setup_8.x | sudo bash - + +#================================================= +# ADD ONLYOFFICE REPOSITORY +#================================================= +ynh_print_info "Add OnlyOffice repository..." + +apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys CB2DE8E5 +echo "deb http://download.onlyoffice.com/repo/debian squeeze main" | sudo tee /etc/apt/sources.list.d/onlyoffice.list + #================================================= # UPGRADE ONLYOFFICE #================================================= From 597d0a4147fc2c2d4c0d5e6f6f14e8870f0230ff Mon Sep 17 00:00:00 2001 From: yalh76 Date: Fri, 1 Mar 2019 12:04:31 +0100 Subject: [PATCH 4/6] fix install --- scripts/install | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/install b/scripts/install index 8bf82dd..d3d39f0 100644 --- a/scripts/install +++ b/scripts/install @@ -100,6 +100,8 @@ ynh_print_info "Add OnlyOffice repository..." apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys CB2DE8E5 echo "deb http://download.onlyoffice.com/repo/debian squeeze main" | sudo tee /etc/apt/sources.list.d/onlyoffice.list +ynh_package_update + #================================================= # INSTALL DEPENDENCIES #================================================= From 0dc1c6aca8d676a170303acba148b7248d15b7e8 Mon Sep 17 00:00:00 2001 From: yalh76 Date: Fri, 1 Mar 2019 12:16:39 +0100 Subject: [PATCH 5/6] Fix install --- scripts/install | 4 +--- scripts/restore | 2 +- scripts/upgrade | 2 +- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/scripts/install b/scripts/install index d3d39f0..219826c 100644 --- a/scripts/install +++ b/scripts/install @@ -100,8 +100,6 @@ ynh_print_info "Add OnlyOffice repository..." apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys CB2DE8E5 echo "deb http://download.onlyoffice.com/repo/debian squeeze main" | sudo tee /etc/apt/sources.list.d/onlyoffice.list -ynh_package_update - #================================================= # INSTALL DEPENDENCIES #================================================= @@ -191,7 +189,7 @@ echo onlyoffice-documentserver onlyoffice/ds-port select ${port} | sudo debconf- ynh_print_info "Install OnlyOffice..." wget $source -dpkg -i onlyoffice-documentserver_amd64.deb +apt install ./onlyoffice-documentserver_amd64.deb #================================================= # MODIFY A CONFIG FILE diff --git a/scripts/restore b/scripts/restore index 0b13ac4..6b4a36b 100644 --- a/scripts/restore +++ b/scripts/restore @@ -132,7 +132,7 @@ echo onlyoffice-documentserver onlyoffice/ds-port select ${port} | sudo debconf- ynh_print_info "Reinstalling OnlyOffice..." wget $source -dpkg -i onlyoffice-documentserver_amd64.deb +apt install ./onlyoffice-documentserver_amd64.deb #================================================= # GENERIC FINALIZATION diff --git a/scripts/upgrade b/scripts/upgrade index 0fb2214..ac82c80 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -128,7 +128,7 @@ echo "deb http://download.onlyoffice.com/repo/debian squeeze main" | sudo tee /e ynh_print_info "Upgrading OnlyOffice..." wget $source -dpkg -i onlyoffice-documentserver_amd64.deb +apt install ./onlyoffice-documentserver_amd64.deb ### Verify the checksum of a file, stored by `ynh_store_file_checksum` in the install script. ### And create a backup of this file if the checksum is different. So the file will be backed up if the admin had modified it. From 6a76112b8328ad871c258697b0b937148ddfe45d Mon Sep 17 00:00:00 2001 From: yalh76 Date: Fri, 1 Mar 2019 12:22:49 +0100 Subject: [PATCH 6/6] Fix install --- scripts/install | 2 +- scripts/restore | 2 +- scripts/upgrade | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/install b/scripts/install index 219826c..ce6f218 100644 --- a/scripts/install +++ b/scripts/install @@ -189,7 +189,7 @@ echo onlyoffice-documentserver onlyoffice/ds-port select ${port} | sudo debconf- ynh_print_info "Install OnlyOffice..." wget $source -apt install ./onlyoffice-documentserver_amd64.deb +apt install -y ./onlyoffice-documentserver_amd64.deb #================================================= # MODIFY A CONFIG FILE diff --git a/scripts/restore b/scripts/restore index 6b4a36b..393921e 100644 --- a/scripts/restore +++ b/scripts/restore @@ -132,7 +132,7 @@ echo onlyoffice-documentserver onlyoffice/ds-port select ${port} | sudo debconf- ynh_print_info "Reinstalling OnlyOffice..." wget $source -apt install ./onlyoffice-documentserver_amd64.deb +apt install -y ./onlyoffice-documentserver_amd64.deb #================================================= # GENERIC FINALIZATION diff --git a/scripts/upgrade b/scripts/upgrade index ac82c80..039ce11 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -128,7 +128,7 @@ echo "deb http://download.onlyoffice.com/repo/debian squeeze main" | sudo tee /e ynh_print_info "Upgrading OnlyOffice..." wget $source -apt install ./onlyoffice-documentserver_amd64.deb +apt install -y ./onlyoffice-documentserver_amd64.deb ### Verify the checksum of a file, stored by `ynh_store_file_checksum` in the install script. ### And create a backup of this file if the checksum is different. So the file will be backed up if the admin had modified it.