mirror of
https://github.com/YunoHost-Apps/xwiki_ynh.git
synced 2024-09-03 20:36:11 +02:00
commit
fa7701fb72
21 changed files with 486 additions and 131 deletions
55
.github/ISSUE_TEMPLATE.md
vendored
Normal file
55
.github/ISSUE_TEMPLATE.md
vendored
Normal file
|
@ -0,0 +1,55 @@
|
|||
---
|
||||
name: Bug report
|
||||
about: When creating a bug report, please use the following template to provide all the relevant information and help debugging efficiently.
|
||||
|
||||
---
|
||||
|
||||
**How to post a meaningful bug report**
|
||||
1. *Read this whole template first.*
|
||||
2. *Determine if you are on the right place:*
|
||||
- *If you were performing an action on the app from the webadmin or the CLI (install, update, backup, restore, change_url...), you are on the right place!*
|
||||
- *Otherwise, the issue may be due to the app itself. Refer to its documentation or repository for help.*
|
||||
- *When in doubt, post here and we will figure it out together.*
|
||||
3. *Delete the italic comments as you write over them below, and remove this guide.*
|
||||
---
|
||||
|
||||
### Describe the bug
|
||||
|
||||
*A clear and concise description of what the bug is.*
|
||||
|
||||
### Context
|
||||
|
||||
- Hardware: *VPS bought online / Old laptop or computer / Raspberry Pi at home / Internet Cube with VPN / Other ARM board / ...*
|
||||
- YunoHost version: x.x.x
|
||||
- I have access to my server: *Through SSH | through the webadmin | direct access via keyboard / screen | ...*
|
||||
- Are you in a special context or did you perform some particular tweaking on your YunoHost instance?: *no / yes*
|
||||
- If yes, please explain:
|
||||
- Using, or trying to install package version/branch:
|
||||
- If upgrading, current package version: *can be found in the admin, or with `yunohost app info $app_id`*
|
||||
|
||||
### Steps to reproduce
|
||||
|
||||
- *If you performed a command from the CLI, the command itself is enough. For example:*
|
||||
```sh
|
||||
sudo yunohost app install the_app
|
||||
```
|
||||
- *If you used the webadmin, please perform the equivalent command from the CLI first.*
|
||||
- *If the error occurs in your browser, explain what you did:*
|
||||
1. *Go to '...'*
|
||||
2. *Click on '...'*
|
||||
3. *Scroll down to '...'*
|
||||
4. *See error*
|
||||
|
||||
### Expected behavior
|
||||
|
||||
*A clear and concise description of what you expected to happen. You can remove this section if the command above is enough to understand your intent.*
|
||||
|
||||
### Logs
|
||||
|
||||
*When an operation fails, YunoHost provides a simple way to share the logs.*
|
||||
- *In the webadmin, the error message contains a link to the relevant log page. On that page, you will be able to 'Share with Yunopaste'. If you missed it, the logs of previous operations are also available under Tools > Logs.*
|
||||
- *In command line, the command to share the logs is displayed at the end of the operation and looks like `yunohost log display [log name] --share`. If you missed it, you can find the log ID of a previous operation using `yunohost log list`.*
|
||||
|
||||
*After sharing the log, please copypaste directly the link provided by YunoHost (to help readability, no need to copypaste the entire content of the log here, just the link is enough...)*
|
||||
|
||||
*If applicable and useful, add screenshots to help explain your problem.*
|
16
.github/PULL_REQUEST_TEMPLATE.md
vendored
Normal file
16
.github/PULL_REQUEST_TEMPLATE.md
vendored
Normal file
|
@ -0,0 +1,16 @@
|
|||
## Problem
|
||||
|
||||
- *Description of why you made this PR*
|
||||
|
||||
## Solution
|
||||
|
||||
- *And how do you fix that problem*
|
||||
|
||||
## PR Status
|
||||
|
||||
- [ ] Code finished and ready to be reviewed/tested
|
||||
- [ ] The fix/enhancement were manually tested (if applicable)
|
||||
|
||||
## Automatic tests
|
||||
|
||||
Automatic tests can be triggered on https://ci-apps-dev.yunohost.org/ *after creating the PR*, by commenting "!testme", "!gogogadgetoci" or "By the power of systemd, I invoke The Great App CI to test this Pull Request!". (N.B. : for this to work you need to be a member of the Yunohost-Apps organization)
|
8
ALL_README.md
Normal file
8
ALL_README.md
Normal file
|
@ -0,0 +1,8 @@
|
|||
# All available README files by language
|
||||
|
||||
- [Read the README in English](README.md)
|
||||
- [Lea el README en español](README_es.md)
|
||||
- [Irakurri README euskaraz](README_eu.md)
|
||||
- [Lire le README en français](README_fr.md)
|
||||
- [Le o README en galego](README_gl.md)
|
||||
- [阅读中文(简体)的 README](README_zh_Hans.md)
|
30
README.md
30
README.md
|
@ -1,5 +1,5 @@
|
|||
<!--
|
||||
N.B.: This README was automatically generated by https://github.com/YunoHost/apps/tree/master/tools/README-generator
|
||||
N.B.: This README was automatically generated by <https://github.com/YunoHost/apps/tree/master/tools/readme_generator>
|
||||
It shall NOT be edited by hand.
|
||||
-->
|
||||
|
||||
|
@ -9,18 +9,18 @@ It shall NOT be edited by hand.
|
|||
|
||||
[](https://install-app.yunohost.org/?app=xwiki)
|
||||
|
||||
*[Lire ce readme en français.](./README_fr.md)*
|
||||
*[Read this README in other languages.](./ALL_README.md)*
|
||||
|
||||
> *This package allows you to install XWiki quickly and simply on a YunoHost server.
|
||||
If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/install) to learn how to install it.*
|
||||
> *This package allows you to install XWiki quickly and simply on a YunoHost server.*
|
||||
> *If you don't have YunoHost, please consult [the guide](https://yunohost.org/install) to learn how to install it.*
|
||||
|
||||
## Overview
|
||||
|
||||
XWiki is an Open Source wiki engine (LGPLv2) suitable for use by workgroups (associations, companies, etc.). The software allows the rapid creation of small applications to meet different information management needs.
|
||||
|
||||
**Shipped version:** 15.10.1~ynh1
|
||||
**Shipped version:** 16.4.0~ynh1
|
||||
|
||||
**Demo:** https://playground.xwiki.org/xwiki/bin/view/Main/WebHome
|
||||
**Demo:** <https://playground.xwiki.org/xwiki/bin/view/Main/WebHome>
|
||||
|
||||
## Screenshots
|
||||
|
||||
|
@ -28,20 +28,20 @@ XWiki is an Open Source wiki engine (LGPLv2) suitable for use by workgroups (ass
|
|||
|
||||
## Documentation and resources
|
||||
|
||||
* Official app website: <https://www.xwiki.org/>
|
||||
* Official user documentation: <https://www.xwiki.org/xwiki/bin/view/Documentation/UserGuide/>
|
||||
* Official admin documentation: <https://www.xwiki.org/xwiki/bin/view/Documentation/AdminGuide/>
|
||||
* Upstream app code repository: <https://github.com/xwiki/xwiki-platform>
|
||||
* YunoHost Store: <https://apps.yunohost.org/app/xwiki>
|
||||
* Report a bug: <https://github.com/YunoHost-Apps/xwiki_ynh/issues>
|
||||
- Official app website: <https://www.xwiki.org/>
|
||||
- Official user documentation: <https://www.xwiki.org/xwiki/bin/view/Documentation/UserGuide/>
|
||||
- Official admin documentation: <https://www.xwiki.org/xwiki/bin/view/Documentation/AdminGuide/>
|
||||
- Upstream app code repository: <https://github.com/xwiki/xwiki-platform>
|
||||
- YunoHost Store: <https://apps.yunohost.org/app/xwiki>
|
||||
- Report a bug: <https://github.com/YunoHost-Apps/xwiki_ynh/issues>
|
||||
|
||||
## Developer info
|
||||
|
||||
Please send your pull request to the [testing branch](https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing).
|
||||
Please send your pull request to the [`testing` branch](https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing).
|
||||
|
||||
To try the testing branch, please proceed like that.
|
||||
To try the `testing` branch, please proceed like that:
|
||||
|
||||
``` bash
|
||||
```bash
|
||||
sudo yunohost app install https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing --debug
|
||||
or
|
||||
sudo yunohost app upgrade xwiki -u https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing --debug
|
||||
|
|
50
README_es.md
Normal file
50
README_es.md
Normal file
|
@ -0,0 +1,50 @@
|
|||
<!--
|
||||
Este archivo README esta generado automaticamente<https://github.com/YunoHost/apps/tree/master/tools/readme_generator>
|
||||
No se debe editar a mano.
|
||||
-->
|
||||
|
||||
# XWiki para Yunohost
|
||||
|
||||
[](https://dash.yunohost.org/appci/app/xwiki)  
|
||||
|
||||
[](https://install-app.yunohost.org/?app=xwiki)
|
||||
|
||||
*[Leer este README en otros idiomas.](./ALL_README.md)*
|
||||
|
||||
> *Este paquete le permite instalarXWiki rapidamente y simplement en un servidor YunoHost.*
|
||||
> *Si no tiene YunoHost, visita [the guide](https://yunohost.org/install) para aprender como instalarla.*
|
||||
|
||||
## Descripción general
|
||||
|
||||
XWiki is an Open Source wiki engine (LGPLv2) suitable for use by workgroups (associations, companies, etc.). The software allows the rapid creation of small applications to meet different information management needs.
|
||||
|
||||
**Versión actual:** 16.4.0~ynh1
|
||||
|
||||
**Demo:** <https://playground.xwiki.org/xwiki/bin/view/Main/WebHome>
|
||||
|
||||
## Capturas
|
||||
|
||||

|
||||
|
||||
## Documentaciones y recursos
|
||||
|
||||
- Sitio web oficial: <https://www.xwiki.org/>
|
||||
- Documentación usuario oficial: <https://www.xwiki.org/xwiki/bin/view/Documentation/UserGuide/>
|
||||
- Documentación administrador oficial: <https://www.xwiki.org/xwiki/bin/view/Documentation/AdminGuide/>
|
||||
- Repositorio del código fuente oficial de la aplicación : <https://github.com/xwiki/xwiki-platform>
|
||||
- Catálogo YunoHost: <https://apps.yunohost.org/app/xwiki>
|
||||
- Reportar un error: <https://github.com/YunoHost-Apps/xwiki_ynh/issues>
|
||||
|
||||
## Información para desarrolladores
|
||||
|
||||
Por favor enviar sus correcciones a la [`branch testing`](https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing
|
||||
|
||||
Para probar la rama `testing`, sigue asÍ:
|
||||
|
||||
```bash
|
||||
sudo yunohost app install https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing --debug
|
||||
o
|
||||
sudo yunohost app upgrade xwiki -u https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing --debug
|
||||
```
|
||||
|
||||
**Mas informaciones sobre el empaquetado de aplicaciones:** <https://yunohost.org/packaging_apps>
|
50
README_eu.md
Normal file
50
README_eu.md
Normal file
|
@ -0,0 +1,50 @@
|
|||
<!--
|
||||
Ohart ongi: README hau automatikoki sortu da <https://github.com/YunoHost/apps/tree/master/tools/readme_generator>ri esker
|
||||
EZ editatu eskuz.
|
||||
-->
|
||||
|
||||
# XWiki YunoHost-erako
|
||||
|
||||
[](https://dash.yunohost.org/appci/app/xwiki)  
|
||||
|
||||
[](https://install-app.yunohost.org/?app=xwiki)
|
||||
|
||||
*[Irakurri README hau beste hizkuntzatan.](./ALL_README.md)*
|
||||
|
||||
> *Pakete honek XWiki YunoHost zerbitzari batean azkar eta zailtasunik gabe instalatzea ahalbidetzen dizu.*
|
||||
> *YunoHost ez baduzu, kontsultatu [gida](https://yunohost.org/install) nola instalatu ikasteko.*
|
||||
|
||||
## Aurreikuspena
|
||||
|
||||
XWiki is an Open Source wiki engine (LGPLv2) suitable for use by workgroups (associations, companies, etc.). The software allows the rapid creation of small applications to meet different information management needs.
|
||||
|
||||
**Paketatutako bertsioa:** 16.4.0~ynh1
|
||||
|
||||
**Demoa:** <https://playground.xwiki.org/xwiki/bin/view/Main/WebHome>
|
||||
|
||||
## Pantaila-argazkiak
|
||||
|
||||

|
||||
|
||||
## Dokumentazioa eta baliabideak
|
||||
|
||||
- Aplikazioaren webgune ofiziala: <https://www.xwiki.org/>
|
||||
- Erabiltzaileen dokumentazio ofiziala: <https://www.xwiki.org/xwiki/bin/view/Documentation/UserGuide/>
|
||||
- Administratzaileen dokumentazio ofiziala: <https://www.xwiki.org/xwiki/bin/view/Documentation/AdminGuide/>
|
||||
- Jatorrizko aplikazioaren kode-gordailua: <https://github.com/xwiki/xwiki-platform>
|
||||
- YunoHost Denda: <https://apps.yunohost.org/app/xwiki>
|
||||
- Eman errore baten berri: <https://github.com/YunoHost-Apps/xwiki_ynh/issues>
|
||||
|
||||
## Garatzaileentzako informazioa
|
||||
|
||||
Bidali `pull request`a [`testing` abarrera](https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing).
|
||||
|
||||
`testing` abarra probatzeko, ondorengoa egin:
|
||||
|
||||
```bash
|
||||
sudo yunohost app install https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing --debug
|
||||
edo
|
||||
sudo yunohost app upgrade xwiki -u https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing --debug
|
||||
```
|
||||
|
||||
**Informazio gehiago aplikazioaren paketatzeari buruz:** <https://yunohost.org/packaging_apps>
|
34
README_fr.md
34
README_fr.md
|
@ -1,6 +1,6 @@
|
|||
<!--
|
||||
N.B.: This README was automatically generated by https://github.com/YunoHost/apps/tree/master/tools/README-generator
|
||||
It shall NOT be edited by hand.
|
||||
Nota bene : ce README est automatiquement généré par <https://github.com/YunoHost/apps/tree/master/tools/readme_generator>
|
||||
Il NE doit PAS être modifié à la main.
|
||||
-->
|
||||
|
||||
# XWiki pour YunoHost
|
||||
|
@ -9,18 +9,18 @@ It shall NOT be edited by hand.
|
|||
|
||||
[](https://install-app.yunohost.org/?app=xwiki)
|
||||
|
||||
*[Read this readme in english.](./README.md)*
|
||||
*[Lire le README dans d'autres langues.](./ALL_README.md)*
|
||||
|
||||
> *Ce package vous permet d’installer XWiki rapidement et simplement sur un serveur YunoHost.
|
||||
Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour savoir comment l’installer et en profiter.*
|
||||
> *Ce package vous permet d’installer XWiki rapidement et simplement sur un serveur YunoHost.*
|
||||
> *Si vous n’avez pas YunoHost, consultez [ce guide](https://yunohost.org/install) pour savoir comment l’installer et en profiter.*
|
||||
|
||||
## Vue d’ensemble
|
||||
|
||||
XWiki est un moteur de wiki Open Source (LGPLv2) adapté à un usage pour des groupes de travail (associations, entreprises…). Le logiciel permet la création rapide de petites applications pour répondre à différents besoins de gestion de l'information.
|
||||
|
||||
**Version incluse :** 15.10.1~ynh1
|
||||
**Version incluse :** 16.4.0~ynh1
|
||||
|
||||
**Démo :** https://playground.xwiki.org/xwiki/bin/view/Main/WebHome
|
||||
**Démo :** <https://playground.xwiki.org/xwiki/bin/view/Main/WebHome>
|
||||
|
||||
## Captures d’écran
|
||||
|
||||
|
@ -28,23 +28,23 @@ XWiki est un moteur de wiki Open Source (LGPLv2) adapté à un usage pour des gr
|
|||
|
||||
## Documentations et ressources
|
||||
|
||||
* Site officiel de l’app : <https://www.xwiki.org/>
|
||||
* Documentation officielle utilisateur : <https://www.xwiki.org/xwiki/bin/view/Documentation/UserGuide/>
|
||||
* Documentation officielle de l’admin : <https://www.xwiki.org/xwiki/bin/view/Documentation/AdminGuide/>
|
||||
* Dépôt de code officiel de l’app : <https://github.com/xwiki/xwiki-platform>
|
||||
* YunoHost Store: <https://apps.yunohost.org/app/xwiki>
|
||||
* Signaler un bug : <https://github.com/YunoHost-Apps/xwiki_ynh/issues>
|
||||
- Site officiel de l’app : <https://www.xwiki.org/>
|
||||
- Documentation officielle utilisateur : <https://www.xwiki.org/xwiki/bin/view/Documentation/UserGuide/>
|
||||
- Documentation officielle de l’admin : <https://www.xwiki.org/xwiki/bin/view/Documentation/AdminGuide/>
|
||||
- Dépôt de code officiel de l’app : <https://github.com/xwiki/xwiki-platform>
|
||||
- YunoHost Store : <https://apps.yunohost.org/app/xwiki>
|
||||
- Signaler un bug : <https://github.com/YunoHost-Apps/xwiki_ynh/issues>
|
||||
|
||||
## Informations pour les développeurs
|
||||
|
||||
Merci de faire vos pull request sur la [branche testing](https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing).
|
||||
Merci de faire vos pull request sur la [branche `testing`](https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing).
|
||||
|
||||
Pour essayer la branche testing, procédez comme suit.
|
||||
Pour essayer la branche `testing`, procédez comme suit :
|
||||
|
||||
``` bash
|
||||
```bash
|
||||
sudo yunohost app install https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing --debug
|
||||
ou
|
||||
sudo yunohost app upgrade xwiki -u https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing --debug
|
||||
```
|
||||
|
||||
**Plus d’infos sur le packaging d’applications :** <https://yunohost.org/packaging_apps>
|
||||
**Plus d’infos sur le packaging d’applications :** <https://yunohost.org/packaging_apps>
|
||||
|
|
50
README_gl.md
Normal file
50
README_gl.md
Normal file
|
@ -0,0 +1,50 @@
|
|||
<!--
|
||||
NOTA: Este README foi creado automáticamente por <https://github.com/YunoHost/apps/tree/master/tools/readme_generator>
|
||||
NON debe editarse manualmente.
|
||||
-->
|
||||
|
||||
# XWiki para YunoHost
|
||||
|
||||
[](https://dash.yunohost.org/appci/app/xwiki)  
|
||||
|
||||
[](https://install-app.yunohost.org/?app=xwiki)
|
||||
|
||||
*[Le este README en outros idiomas.](./ALL_README.md)*
|
||||
|
||||
> *Este paquete permíteche instalar XWiki de xeito rápido e doado nun servidor YunoHost.*
|
||||
> *Se non usas YunoHost, le a [documentación](https://yunohost.org/install) para saber como instalalo.*
|
||||
|
||||
## Vista xeral
|
||||
|
||||
XWiki is an Open Source wiki engine (LGPLv2) suitable for use by workgroups (associations, companies, etc.). The software allows the rapid creation of small applications to meet different information management needs.
|
||||
|
||||
**Versión proporcionada:** 16.4.0~ynh1
|
||||
|
||||
**Demo:** <https://playground.xwiki.org/xwiki/bin/view/Main/WebHome>
|
||||
|
||||
## Capturas de pantalla
|
||||
|
||||

|
||||
|
||||
## Documentación e recursos
|
||||
|
||||
- Web oficial da app: <https://www.xwiki.org/>
|
||||
- Documentación oficial para usuarias: <https://www.xwiki.org/xwiki/bin/view/Documentation/UserGuide/>
|
||||
- Documentación oficial para admin: <https://www.xwiki.org/xwiki/bin/view/Documentation/AdminGuide/>
|
||||
- Repositorio de orixe do código: <https://github.com/xwiki/xwiki-platform>
|
||||
- Tenda YunoHost: <https://apps.yunohost.org/app/xwiki>
|
||||
- Informar dun problema: <https://github.com/YunoHost-Apps/xwiki_ynh/issues>
|
||||
|
||||
## Info de desenvolvemento
|
||||
|
||||
Envía a túa colaboración á [rama `testing`](https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing).
|
||||
|
||||
Para probar a rama `testing`, procede deste xeito:
|
||||
|
||||
```bash
|
||||
sudo yunohost app install https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing --debug
|
||||
ou
|
||||
sudo yunohost app upgrade xwiki -u https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing --debug
|
||||
```
|
||||
|
||||
**Máis info sobre o empaquetado da app:** <https://yunohost.org/packaging_apps>
|
50
README_zh_Hans.md
Normal file
50
README_zh_Hans.md
Normal file
|
@ -0,0 +1,50 @@
|
|||
<!--
|
||||
注意:此 README 由 <https://github.com/YunoHost/apps/tree/master/tools/readme_generator> 自动生成
|
||||
请勿手动编辑。
|
||||
-->
|
||||
|
||||
# YunoHost 上的 XWiki
|
||||
|
||||
[](https://dash.yunohost.org/appci/app/xwiki)  
|
||||
|
||||
[](https://install-app.yunohost.org/?app=xwiki)
|
||||
|
||||
*[阅读此 README 的其它语言版本。](./ALL_README.md)*
|
||||
|
||||
> *通过此软件包,您可以在 YunoHost 服务器上快速、简单地安装 XWiki。*
|
||||
> *如果您还没有 YunoHost,请参阅[指南](https://yunohost.org/install)了解如何安装它。*
|
||||
|
||||
## 概况
|
||||
|
||||
XWiki is an Open Source wiki engine (LGPLv2) suitable for use by workgroups (associations, companies, etc.). The software allows the rapid creation of small applications to meet different information management needs.
|
||||
|
||||
**分发版本:** 16.4.0~ynh1
|
||||
|
||||
**演示:** <https://playground.xwiki.org/xwiki/bin/view/Main/WebHome>
|
||||
|
||||
## 截图
|
||||
|
||||

|
||||
|
||||
## 文档与资源
|
||||
|
||||
- 官方应用网站: <https://www.xwiki.org/>
|
||||
- 官方用户文档: <https://www.xwiki.org/xwiki/bin/view/Documentation/UserGuide/>
|
||||
- 官方管理文档: <https://www.xwiki.org/xwiki/bin/view/Documentation/AdminGuide/>
|
||||
- 上游应用代码库: <https://github.com/xwiki/xwiki-platform>
|
||||
- YunoHost 商店: <https://apps.yunohost.org/app/xwiki>
|
||||
- 报告 bug: <https://github.com/YunoHost-Apps/xwiki_ynh/issues>
|
||||
|
||||
## 开发者信息
|
||||
|
||||
请向 [`testing` 分支](https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing) 发送拉取请求。
|
||||
|
||||
如要尝试 `testing` 分支,请这样操作:
|
||||
|
||||
```bash
|
||||
sudo yunohost app install https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing --debug
|
||||
或
|
||||
sudo yunohost app upgrade xwiki -u https://github.com/YunoHost-Apps/xwiki_ynh/tree/testing --debug
|
||||
```
|
||||
|
||||
**有关应用打包的更多信息:** <https://yunohost.org/packaging_apps>
|
91
auto_update/auto_update.sh
Normal file
91
auto_update/auto_update.sh
Normal file
|
@ -0,0 +1,91 @@
|
|||
#!/bin/bash
|
||||
|
||||
set -eu
|
||||
|
||||
readonly app_name=xwiki
|
||||
|
||||
source auto_update_config.sh
|
||||
|
||||
get_from_manifest() {
|
||||
result=$(python3 <<EOL
|
||||
import toml
|
||||
import json
|
||||
with open("../manifest.toml", "r") as f:
|
||||
file_content = f.read()
|
||||
loaded_toml = toml.loads(file_content)
|
||||
json_str = json.dumps(loaded_toml)
|
||||
print(json_str)
|
||||
EOL
|
||||
)
|
||||
echo "$result" | jq -r "$1"
|
||||
}
|
||||
|
||||
check_app_version() {
|
||||
local app_remote_version=$(curl https://nexus.xwiki.org/nexus/content/groups/public/org/xwiki/platform/xwiki-platform-distribution-jetty-hsqldb/maven-metadata.xml |
|
||||
xq -x '//metadata/versioning/versions' |
|
||||
sed -E 's|\s*(.*)\s*|\1|g' |
|
||||
grep -v '\-rc-' |
|
||||
grep -v '\-milestone-' |
|
||||
grep -v '^$' |
|
||||
python3 -c 'import sys
|
||||
from packaging.version import Version
|
||||
versions = sys.stdin.read().splitlines()
|
||||
versions.sort(key=Version)
|
||||
print(versions[-1])')
|
||||
|
||||
jdbc_version=$(curl 'https://api.github.com/repos/pgjdbc/pgjdbc/releases/latest' -H 'Host: api.github.com' --compressed | jq -r ".tag_name" | cut -dL -f2)
|
||||
|
||||
## Check if new build is needed
|
||||
if [[ "$app_version" != "$app_remote_version" ]]
|
||||
then
|
||||
app_version="$app_remote_version"
|
||||
return 0
|
||||
else
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
upgrade_app() {
|
||||
(
|
||||
set -eu
|
||||
|
||||
prev_sha256sum_main=$(get_from_manifest ".resources.sources.main.sha256")
|
||||
prev_sha256sum_jdbc=$(get_from_manifest ".resources.sources.jdbc.sha256")
|
||||
|
||||
wget -O main.zip "https://nexus.xwiki.org/nexus/content/groups/public/org/xwiki/platform/xwiki-platform-distribution-jetty-hsqldb/$app_version/xwiki-platform-distribution-jetty-hsqldb-$app_version.zip"
|
||||
sha256sum_main=$(sha256sum main.zip | cut -d' ' -f1)
|
||||
rm main.zip
|
||||
wget -O jdbc.jar "https://jdbc.postgresql.org/download/postgresql-$jdbc_version.jar"
|
||||
sha256sum_jdbc=$(sha256sum jdbc.jar | cut -d' ' -f1)
|
||||
|
||||
# Update manifest
|
||||
sed -r -i 's|version = "[[:alnum:].]{4,8}~ynh[[:alnum:].]{1,2}"|version = "'"${app_version}"'~ynh1"|' ../manifest.toml
|
||||
sed -r -i "s|xwiki-platform-distribution-jetty-hsqldb/[[:alnum:].]{4,10}/xwiki-platform-distribution-jetty-hsqldb-[[:alnum:].]{4,10}.zip|xwiki-platform-distribution-jetty-hsqldb/$app_version/xwiki-platform-distribution-jetty-hsqldb-$app_version.zip|" ../manifest.toml
|
||||
sed -r -i 's|postgresql-[[:alnum:].]{4,10}\.jar|postgresql-'"${jdbc_version}"'.jar|' ../manifest.toml
|
||||
sed -r -i "s|$prev_sha256sum_main|$sha256sum_main|" ../manifest.toml
|
||||
sed -r -i "s|$prev_sha256sum_jdbc|$sha256sum_jdbc|" ../manifest.toml
|
||||
|
||||
git commit -a -m "Upgrade $app_name to $app_version"
|
||||
git push gitea auto_update:auto_update
|
||||
) 2>&1 | tee "${app_name}_build_temp.log"
|
||||
return "${PIPESTATUS[0]}"
|
||||
}
|
||||
|
||||
app_prev_version="$(get_from_manifest ".version" | cut -d'~' -f1)"
|
||||
app_version="$app_prev_version"
|
||||
|
||||
if check_app_version
|
||||
then
|
||||
set +eu
|
||||
upgrade_app
|
||||
res=$?
|
||||
set -eu
|
||||
if [ $res -eq 0 ]; then
|
||||
result="Success"
|
||||
else
|
||||
result="Failed"
|
||||
fi
|
||||
msg="Build: $app_name version $app_version\n"
|
||||
msg+="$(cat ${app_name}_build_temp.log)"
|
||||
echo -e "$msg" | mail.mailutils -a "Content-Type: text/plain; charset=UTF-8" -s "Autoupgrade $app_name : $result" "$notify_email"
|
||||
fi
|
1
auto_update/auto_update_config_example.sh
Normal file
1
auto_update/auto_update_config_example.sh
Normal file
|
@ -0,0 +1 @@
|
|||
notify_email="hello@world.tld"
|
|
@ -2,7 +2,7 @@
|
|||
<jobRequest xmlns="http://www.xwiki.org">
|
||||
<id>
|
||||
<element>extension</element>
|
||||
<element>provision</element>
|
||||
<element>action</element>
|
||||
<element>__JOB_ID__</element>
|
||||
<!-- <string>wiki:xwiki</string> -->
|
||||
</id>
|
||||
|
@ -29,7 +29,7 @@
|
|||
<key>namespaces</key>
|
||||
<value>
|
||||
<list xmlns="" xmlns:ns2="http://www.xwiki.org">
|
||||
<string>xwiki:xwiki</string>
|
||||
<string>wiki:xwiki</string>
|
||||
</list>
|
||||
</value>
|
||||
</property>
|
||||
|
|
|
@ -340,7 +340,7 @@ environment.permanentDirectory = __DATA_DIR__
|
|||
#-# Type of the openoffice server instance used by officeimporter component.
|
||||
#-# 0 - Internally managed server instance. (Default)
|
||||
#-# 1 - Externally managed (local) server instance.
|
||||
# openoffice.serverType = 0
|
||||
openoffice.serverType = 0
|
||||
|
||||
#-# [Since 12.1RC1]
|
||||
#-# Port numbers used for connecting to the openoffice server instance.
|
||||
|
@ -351,7 +351,7 @@ environment.permanentDirectory = __DATA_DIR__
|
|||
#-# [Since 1.9M2]
|
||||
#-# If the openoffice server should be started / connected upon XE start.
|
||||
#-# Default value is false
|
||||
# openoffice.autoStart = false
|
||||
openoffice.autoStart = true
|
||||
|
||||
#-# [Since 1.8RC3]
|
||||
#-# Path to openoffice installation (serverType:0 only).
|
||||
|
|
|
@ -5,7 +5,7 @@ name = "XWiki"
|
|||
description.en = "Collaboration tool based on the wiki principle"
|
||||
description.fr = "Outil de collaboration basé sur le principe du wiki"
|
||||
|
||||
version = "15.10.1~ynh1"
|
||||
version = "16.4.0~ynh1"
|
||||
|
||||
maintainers = ["Josué Tille"]
|
||||
|
||||
|
@ -61,31 +61,31 @@ ram.runtime = "1G"
|
|||
[resources.sources]
|
||||
|
||||
[resources.sources.main]
|
||||
url = "https://nexus.xwiki.org/nexus/content/groups/public/org/xwiki/platform/xwiki-platform-distribution-jetty-hsqldb/15.10.1/xwiki-platform-distribution-jetty-hsqldb-15.10.1.zip"
|
||||
sha256 = "76efd6e1c58b8557034a3e25271963392b8b5e125af97d932210823510586e9f"
|
||||
url = "https://nexus.xwiki.org/nexus/content/groups/public/org/xwiki/platform/xwiki-platform-distribution-jetty-hsqldb/16.4.0/xwiki-platform-distribution-jetty-hsqldb-16.4.0.zip"
|
||||
sha256 = "5cfc373198bb7386a573dfcbfa8352af4ce0017b49911ec724900fb58cf7bace"
|
||||
format = "zip"
|
||||
|
||||
[resources.sources.jdbc]
|
||||
url = "https://jdbc.postgresql.org/download/postgresql-42.7.0.jar"
|
||||
rename = "postgresql-42.7.0.jar"
|
||||
sha256 = "90c39c97ac309b5767882f9beef913244da029204af2d2982c2b45bcfcb42624"
|
||||
url = "https://jdbc.postgresql.org/download/postgresql-42.7.3.jar"
|
||||
rename = "postgresql-42.7.3.jar"
|
||||
sha256 = "a2644cbfba1baa145ff7e8c8ef582a6eed7a7ec4ca792f7f054122bdec756268"
|
||||
|
||||
# Note that xq is available on debian package since debian 12
|
||||
# So on bookworm should just remove this and use official package
|
||||
[resources.sources.xq_tool]
|
||||
in_subdir= false
|
||||
|
||||
i386.url = "https://github.com/sibprogrammer/xq/releases/download/v1.2.3/xq_1.2.3_linux_386.tar.gz"
|
||||
i386.sha256 = "fc500e887d825f6cbedecdbfb3a272e1a88473b1f1a1b92075cab429d3d6fc64"
|
||||
i386.url = "https://github.com/sibprogrammer/xq/releases/download/v1.2.4/xq_1.2.4_linux_386.tar.gz"
|
||||
i386.sha256 = "f51e27493fb49dee53f3511ad6f4710f8fb7014e6ba0796d3c6d2eee6ceef914"
|
||||
|
||||
amd64.url = "https://github.com/sibprogrammer/xq/releases/download/v1.2.3/xq_1.2.3_linux_amd64.tar.gz"
|
||||
amd64.sha256 = "d510d97a247ad9b5a4e92759ea9b1b6be07d9f18187209b359525744e1bb8947"
|
||||
amd64.url = "https://github.com/sibprogrammer/xq/releases/download/v1.2.4/xq_1.2.4_linux_amd64.tar.gz"
|
||||
amd64.sha256 = "96148dc3ce4fede9ab47b26fa07f1ada950dfd61ae54db7013c76a410945302f"
|
||||
|
||||
armhf.url = "https://github.com/sibprogrammer/xq/releases/download/v1.2.3/xq_1.2.3_linux_armv7.tar.gz"
|
||||
armhf.sha256 = "f9b01ba7d77965f292f3c1b8c164267367507e16a8951b67733a539d7f73eecb"
|
||||
armhf.url = "https://github.com/sibprogrammer/xq/releases/download/v1.2.4/xq_1.2.4_linux_armv7.tar.gz"
|
||||
armhf.sha256 = "9b08c33f1a3dd1f7a6a82dd91ef7dfb5297d0c3ea2ccfc6ee616393667862d56"
|
||||
|
||||
arm64.url = "https://github.com/sibprogrammer/xq/releases/download/v1.2.3/xq_1.2.3_linux_arm64.tar.gz"
|
||||
arm64.sha256 = "a8989b2b1a5254033aebacb72ffea77964d6903d809361001dbf1ed09a0c6550"
|
||||
arm64.url = "https://github.com/sibprogrammer/xq/releases/download/v1.2.4/xq_1.2.4_linux_arm64.tar.gz"
|
||||
arm64.sha256 = "414ea9fde3c6e669f034465c21aa095bc3c10a3e3dd8c2989ee8073605274bf9"
|
||||
|
||||
#
|
||||
# INFO need also to update extensions version on _common.sh
|
||||
|
@ -109,7 +109,7 @@ ram.runtime = "1G"
|
|||
admin.label = "Admins"
|
||||
|
||||
[resources.apt]
|
||||
packages = ["openjdk-17-jre", "postgresql"]
|
||||
packages = ["openjdk-17-jre", "postgresql", "libreoffice"]
|
||||
|
||||
[resources.database]
|
||||
type = "postgresql"
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
|
||||
super_admin_config='#'
|
||||
systemd_match_start_line='oxtjl.NotifyListener:main: ----------------------------------'
|
||||
flavor_version='15.10.1'
|
||||
ldap_version='9.12.0'
|
||||
flavor_version='16.3.1'
|
||||
ldap_version='9.15.2'
|
||||
|
||||
if [ $install_standard_flavor -eq 1 ]; then
|
||||
distribution_default_ui="distribution.defaultUI=org.xwiki.platform:xwiki-platform-distribution-flavor-mainwiki/$flavor_version"
|
||||
|
@ -24,7 +24,7 @@ else
|
|||
install_on_root=false
|
||||
path2=${path/#\//}/ # path=/xwiki -> xwiki/
|
||||
path3=${path/#\//} # path=/xwiki -> xwiki
|
||||
web_inf_path="$install_dir"/webapps$path/WEB-INF
|
||||
web_inf_path="$install_dir/webapps$path/WEB-INF"
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
|
@ -34,18 +34,18 @@ fi
|
|||
enable_super_admin() {
|
||||
super_admin_pwd=$(ynh_string_random)
|
||||
super_admin_config="xwiki.superadminpassword=$super_admin_pwd"
|
||||
ynh_add_config --template=xwiki.cfg --destination=/etc/$app/xwiki_conf.cfg
|
||||
ln -f /etc/$app/xwiki_conf.cfg "$web_inf_path"/xwiki.cfg
|
||||
chmod 400 /etc/$app/xwiki_conf.cfg
|
||||
chown "$app:$app" /etc/$app/xwiki_conf.cfg
|
||||
ynh_add_config --template=xwiki.cfg --destination=/etc/"$app"/xwiki_conf.cfg
|
||||
ln -f /etc/"$app"/xwiki_conf.cfg "$web_inf_path"/xwiki.cfg
|
||||
chmod 400 /etc/"$app"/xwiki_conf.cfg
|
||||
chown "$app:$app" /etc/"$app"/xwiki_conf.cfg
|
||||
}
|
||||
|
||||
disable_super_admin() {
|
||||
super_admin_config='#'
|
||||
ynh_add_config --template=xwiki.cfg --destination=/etc/$app/xwiki_conf.cfg
|
||||
ln -f /etc/$app/xwiki_conf.cfg "$web_inf_path"/xwiki.cfg
|
||||
chmod 400 /etc/$app/xwiki_conf.cfg
|
||||
chown "$app:$app" /etc/$app/xwiki_conf.cfg
|
||||
ynh_add_config --template=xwiki.cfg --destination=/etc/"$app"/xwiki_conf.cfg
|
||||
ln -f /etc/"$app"/xwiki_conf.cfg "$web_inf_path"/xwiki.cfg
|
||||
chmod 400 /etc/"$app"/xwiki_conf.cfg
|
||||
chown "$app:$app" /etc/"$app"/xwiki_conf.cfg
|
||||
}
|
||||
|
||||
install_exension() {
|
||||
|
@ -66,17 +66,17 @@ install_exension() {
|
|||
local status_raw
|
||||
local state_request
|
||||
|
||||
chmod 700 $temp_dir
|
||||
chown root:root $temp_dir
|
||||
chmod 700 "$temp_dir"
|
||||
chown root:root "$temp_dir"
|
||||
|
||||
ynh_add_config --template=install_extensions.xml --destination=$temp_dir/install_extensions.xml
|
||||
ynh_add_config --template=install_extensions.xml --destination="$temp_dir"/install_extensions.xml
|
||||
status_raw=$($curl -i --user "superadmin:$super_admin_pwd" -X PUT -H 'Content-Type: text/xml' "http://127.0.0.1:$port/${path2}rest/jobs?jobType=install&async=true" --upload-file $temp_dir/install_extensions.xml)
|
||||
state_request=$(echo $status_raw | $xq -x '//jobStatus/ns2:state')
|
||||
state_request=$(echo "$status_raw" | $xq -x '//jobStatus/ns2:state')
|
||||
|
||||
while true; do
|
||||
sleep 5
|
||||
|
||||
status_raw=$($curl --user "superadmin:$super_admin_pwd" -X GET -H 'Content-Type: text/xml' "http://127.0.0.1:$port/${path2}rest/jobstatus/extension/provision/$job_id")
|
||||
status_raw=$($curl --user "superadmin:$super_admin_pwd" -X GET -H 'Content-Type: text/xml' "http://127.0.0.1:$port/${path2}rest/jobstatus/extension/action/$job_id")
|
||||
state_request=$(echo "$status_raw" | $xq -x '//jobStatus/state')
|
||||
|
||||
if [ -z "$state_request" ]; then
|
||||
|
@ -96,7 +96,7 @@ install_exension() {
|
|||
}
|
||||
|
||||
wait_xwiki_started() {
|
||||
local res='meta http-equiv="refresh" content="1"'$
|
||||
local res='meta http-equiv="refresh" content="1"'
|
||||
local curl='curl --silent --show-error'
|
||||
|
||||
while echo "$res" | grep -q 'meta http-equiv="refresh" content="1"'; do
|
||||
|
@ -106,31 +106,15 @@ wait_xwiki_started() {
|
|||
}
|
||||
|
||||
wait_for_flavor_install() {
|
||||
local flavor_job_id='org.xwiki.platform%3Axwiki-platform-distribution-flavor-mainwiki/wiki%3Axwiki'
|
||||
local status_raw
|
||||
local state_request
|
||||
local xq=$install_dir/xq_tool/xq
|
||||
local curl='curl --silent --show-error'
|
||||
local status_header
|
||||
|
||||
# Need to call main page to start xwiki service
|
||||
wait_xwiki_started
|
||||
|
||||
while true; do
|
||||
status_raw=$($curl --user "superadmin:$super_admin_pwd" -X GET -H 'Content-Type: text/xml' "http://127.0.0.1:$port/${path2}rest/jobstatus/extension/action/$flavor_job_id")
|
||||
state_request=$(echo "$status_raw" | $xq -x '//jobStatus/state')
|
||||
|
||||
if [ -z "$state_request" ]; then
|
||||
ynh_die --message="Invalid answer: '$status_raw'"
|
||||
elif [ "$state_request" == FINISHED ]; then
|
||||
# Check if error happen
|
||||
error_msg=$(echo "$status_raw" | $xq -x '//jobStatus/errorMessage')
|
||||
if [ -z "$error_msg" ]; then
|
||||
status_header="$(curl --silent --show-error -I "http://127.0.0.1:$port/${path2}bin/view/Main/")"
|
||||
if ! echo "$status_header" | grep -q -E 'Location:[[:space:]].*/Distribution\?xredirect='; then
|
||||
break
|
||||
else
|
||||
ynh_die --message="Error while installing extension 'org.xwiki.platform%3Axwiki-platform-distribution-flavor-mainwiki'. Error: $error_msg"
|
||||
fi
|
||||
elif [ "$state_request" != RUNNING ]; then
|
||||
ynh_die --message="Invalid status '$state_request'"
|
||||
fi
|
||||
sleep 10
|
||||
done
|
||||
|
@ -152,14 +136,14 @@ install_source() {
|
|||
elif [ "$path" == /root ]; then
|
||||
ynh_die --message='Path "/root" not supported'
|
||||
elif [ "$path" != /xwiki ]; then
|
||||
mv "$install_dir"/webapps/xwiki "$install_dir"/webapps$path
|
||||
mv "$install_dir"/webapps/xwiki "$install_dir/webapps$path"
|
||||
fi
|
||||
}
|
||||
|
||||
add_config() {
|
||||
ynh_add_config --template=hibernate.cfg.xml --destination=/etc/$app/hibernate.cfg.xml
|
||||
ynh_add_config --template=xwiki.cfg --destination=/etc/$app/xwiki_conf.cfg
|
||||
ynh_add_config --template=xwiki.properties --destination=/etc/$app/xwiki_conf.properties
|
||||
ynh_add_config --template=hibernate.cfg.xml --destination=/etc/"$app"/hibernate.cfg.xml
|
||||
ynh_add_config --template=xwiki.cfg --destination=/etc/"$app"/xwiki_conf.cfg
|
||||
ynh_add_config --template=xwiki.properties --destination=/etc/"$app"/xwiki_conf.properties
|
||||
|
||||
# Note that using /etc/xwiki/xwiki.cfg or /etc/xwiki/xwiki.properties is hard coded on the application
|
||||
# And using this break multi instance feature so we must use an other path
|
||||
|
@ -172,16 +156,16 @@ set_permissions() {
|
|||
chmod -R u+rwX,o-rwx "$install_dir"
|
||||
chown -R "$app:$app" "$install_dir"
|
||||
|
||||
chmod -R u=rwX,g=rX,o= /etc/$app
|
||||
chown -R "$app:$app" /etc/$app
|
||||
chmod -R u=rwX,g=rX,o= /etc/"$app"
|
||||
chown -R "$app:$app" /etc/"$app"
|
||||
|
||||
chown "$app:$app" -R /var/log/$app
|
||||
chmod u=rwX,g=rX,o= -R /var/log/$app
|
||||
chown "$app:$app" -R /var/log/"$app"
|
||||
chmod u=rwX,g=rX,o= -R /var/log/"$app"
|
||||
|
||||
find $data_dir \( \! -perm u=rwX,g=rX,-o= \
|
||||
-o \! -user $app \
|
||||
-o \! -group $app \) \
|
||||
-exec chown $app:$app {} \; \
|
||||
find "$data_dir" \( \! -perm -o= \
|
||||
-o \! -user "$app" \
|
||||
-o \! -group "$app" \) \
|
||||
-exec chown "$app:$app" {} \; \
|
||||
-exec chmod u=rwX,g=rX,o= {} \;
|
||||
}
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@ source /usr/share/yunohost/helpers
|
|||
#=================================================
|
||||
ynh_print_info --message="Declaring files to be backed up..."
|
||||
|
||||
if [[ ! "$(systemctl status $app)" =~ "Active: inactive (dead)" ]]; then
|
||||
if systemctl is-active "$app" --quiet; then
|
||||
ynh_print_warn --message="It's hightly recommended to make your backup when the service is stopped. Please stop $app service with this command before to run the backup 'systemctl stop $app.service'"
|
||||
fi
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@ source /usr/share/yunohost/helpers
|
|||
#=================================================
|
||||
ynh_script_progression --message="Stopping a systemd service..." --weight=1
|
||||
|
||||
ynh_systemd_action --service_name=$app --action=stop
|
||||
ynh_systemd_action --service_name="$app" --action=stop
|
||||
|
||||
#=================================================
|
||||
# MODIFY URL IN NGINX CONF
|
||||
|
@ -27,15 +27,15 @@ ynh_change_url_nginx_config
|
|||
|
||||
ynh_script_progression --message="Updating xwiki configuration..." --weight=1
|
||||
|
||||
if [ $new_path != $old_path ]; then
|
||||
if $install_on_root; then
|
||||
mv "$install_dir"/webapps$old_path "$install_dir"/webapps/root
|
||||
if [ "$new_path" != "$old_path" ]; then
|
||||
if "$install_on_root"; then
|
||||
mv "$install_dir/webapps$old_path" "$install_dir"/webapps/root
|
||||
elif [ "$path" == /root ]; then
|
||||
ynh_die --message='Path "/root" not supported'
|
||||
elif [ $old_path == / ]; then
|
||||
mv "$install_dir"/webapps/root "$install_dir"/webapps$new_path
|
||||
mv "$install_dir"/webapps/root "$install_dir/webapps$new_path"
|
||||
else
|
||||
mv "$install_dir"/webapps$old_path "$install_dir"/webapps$new_path
|
||||
mv "$install_dir/webapps$old_path" "$install_dir/webapps$new_path"
|
||||
fi
|
||||
fi
|
||||
add_config
|
||||
|
@ -48,7 +48,7 @@ set_permissions
|
|||
#=================================================
|
||||
ynh_script_progression --message="Starting a systemd service..." --weight=1
|
||||
|
||||
ynh_systemd_action --service_name=$app --action=start --log_path=systemd --line_match="$systemd_match_start_line"
|
||||
ynh_systemd_action --service_name="$app" --action=start --log_path=systemd --line_match="$systemd_match_start_line"
|
||||
wait_xwiki_started
|
||||
|
||||
#=================================================
|
||||
|
|
|
@ -13,15 +13,15 @@ source /usr/share/yunohost/helpers
|
|||
# APP "BUILD" (DEPLOYING SOURCES, VENV, COMPILING ETC)
|
||||
#=================================================
|
||||
|
||||
if [ -n "$(ls -A $data_dir)" ]; then
|
||||
if [ -n "$(ls -A "$data_dir")" ]; then
|
||||
old_data_dir_path="${data_dir}_$(date '+%Y%m%d.%H%M%S')"
|
||||
ynh_print_warn "Data directory was not empty. Data was moved to $old_data_dir_path"
|
||||
mkdir -p $old_data_dir_path
|
||||
mkdir -p "$old_data_dir_path"
|
||||
mv -t "$old_data_dir_path" "$data_dir"/*
|
||||
fi
|
||||
|
||||
mkdir -p /var/log/"$app"
|
||||
mkdir -p /etc/$app
|
||||
mkdir -p /etc/"$app"
|
||||
|
||||
#=================================================
|
||||
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
||||
|
@ -52,7 +52,7 @@ ynh_add_systemd_config
|
|||
|
||||
yunohost service add "$app" --description=XWiki --log="/var/log/$app/$app.log"
|
||||
|
||||
ynh_use_logrotate --logfile "/var/log/$app"
|
||||
ynh_use_logrotate --logfile="/var/log/$app"
|
||||
|
||||
#=================================================
|
||||
# INSTALL EXTENSIONS
|
||||
|
@ -61,9 +61,9 @@ ynh_use_logrotate --logfile "/var/log/$app"
|
|||
enable_super_admin
|
||||
|
||||
# Start a systemd service
|
||||
ynh_systemd_action --service_name=$app --action=start --log_path=systemd --line_match="$systemd_match_start_line"
|
||||
ynh_systemd_action --service_name="$app" --action=start --log_path=systemd --line_match="$systemd_match_start_line"
|
||||
|
||||
if [ $install_standard_flavor -eq 1 ]; then
|
||||
if [ "$install_standard_flavor" -eq 1 ]; then
|
||||
ynh_script_progression --message='Installing flavor...'
|
||||
wait_for_flavor_install
|
||||
fi
|
||||
|
@ -72,7 +72,7 @@ ynh_script_progression --message='Installing LDAP extension...' --weight=1
|
|||
install_exension 'org.xwiki.contrib.ldap:ldap-authenticator' "$ldap_version"
|
||||
|
||||
# Disable super admin
|
||||
ynh_systemd_action --service_name=$app --action=stop
|
||||
ynh_systemd_action --service_name="$app" --action=stop
|
||||
disable_super_admin
|
||||
|
||||
#=================================================
|
||||
|
@ -82,7 +82,7 @@ disable_super_admin
|
|||
#=================================================
|
||||
|
||||
ynh_script_progression --message='Starting a systemd service...' --weight=1
|
||||
ynh_systemd_action --service_name=$app --action=start --log_path=systemd --line_match="$systemd_match_start_line"
|
||||
ynh_systemd_action --service_name="$app" --action=start --log_path=systemd --line_match="$systemd_match_start_line"
|
||||
wait_xwiki_started
|
||||
|
||||
#=================================================
|
||||
|
|
|
@ -17,10 +17,10 @@ source /usr/share/yunohost/helpers
|
|||
ynh_script_progression --message="Removing system configurations related to $app..." --weight=1
|
||||
|
||||
# Remove the service from the list of services known by YunoHost (added from `yunohost service add`)
|
||||
if ynh_exec_warn_less yunohost service status $app >/dev/null
|
||||
if ynh_exec_warn_less yunohost service status "$app" >/dev/null
|
||||
then
|
||||
ynh_script_progression --message="Removing $app service integration..." --weight=1
|
||||
yunohost service remove $app
|
||||
yunohost service remove "$app"
|
||||
fi
|
||||
|
||||
ynh_secure_remove --file="/etc/$app"
|
||||
|
|
|
@ -22,7 +22,7 @@ ynh_restore
|
|||
#=================================================
|
||||
ynh_script_progression --message="Restoring the database..." --weight=1
|
||||
|
||||
ynh_psql_connect_as --user=$db_user --password=$db_pwd --database=$db_name < ./db.sql
|
||||
ynh_psql_connect_as --user="$db_user" --password="$db_pwd" --database="$db_name" < ./db.sql
|
||||
|
||||
#=================================================
|
||||
# RESTORE SYSTEM CONFIGURATIONS
|
||||
|
@ -32,10 +32,10 @@ ynh_script_progression --message="Restoring system configurations related to $ap
|
|||
mkdir -p /var/log/"$app"
|
||||
set_permissions
|
||||
|
||||
systemctl enable $app.service --quiet
|
||||
yunohost service add $app --description=XWiki --log="/var/log/$app/$app.log"
|
||||
systemctl enable "$app".service --quiet
|
||||
yunohost service add "$app" --description=XWiki --log="/var/log/$app/$app.log"
|
||||
|
||||
ynh_use_logrotate --logfile "/var/log/$app"
|
||||
ynh_use_logrotate --logfile="/var/log/$app"
|
||||
|
||||
#=================================================
|
||||
# GENERIC FINALIZATION
|
||||
|
@ -44,7 +44,7 @@ ynh_use_logrotate --logfile "/var/log/$app"
|
|||
#=================================================
|
||||
ynh_script_progression --message="Reloading NGINX web server and $app's service..." --weight=1
|
||||
|
||||
ynh_systemd_action --service_name=$app --action=start --log_path=systemd --line_match="$systemd_match_start_line"
|
||||
ynh_systemd_action --service_name="$app" --action=start --log_path=systemd --line_match="$systemd_match_start_line"
|
||||
wait_xwiki_started
|
||||
|
||||
ynh_systemd_action --service_name=nginx --action=reload
|
||||
|
|
|
@ -9,9 +9,9 @@
|
|||
source _common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
upgrade_type=$(ynh_check_app_version_changed)
|
||||
upgrade_type="$(ynh_check_app_version_changed)"
|
||||
|
||||
if ynh_compare_current_package_version --comparison le --version '14.10.8~ynh1'; then
|
||||
if ynh_compare_current_package_version --comparison=le --version='14.10.8~ynh1'; then
|
||||
ynh_die --mesage='Upgrade from this version is not supported. Please backup and restore manually the data after a clean new install'
|
||||
fi
|
||||
|
||||
|
@ -20,7 +20,7 @@ fi
|
|||
#=================================================
|
||||
ynh_script_progression --message='Stopping a systemd service..' --weight=1
|
||||
|
||||
ynh_systemd_action --service_name=$app --action=stop --log_path="/var/log/$app/$app.log"
|
||||
ynh_systemd_action --service_name="$app" --action=stop --log_path="/var/log/$app/$app.log"
|
||||
|
||||
#=================================================
|
||||
# "REBUILD" THE APP (DEPLOY NEW SOURCES, RERUN NPM BUILD...)
|
||||
|
@ -47,7 +47,7 @@ ynh_add_systemd_config
|
|||
|
||||
yunohost service add "$app" --description=XWiki --log="/var/log/$app/$app.log"
|
||||
|
||||
ynh_use_logrotate --logfile "/var/log/$app"
|
||||
ynh_use_logrotate --logfile="/var/log/$app"
|
||||
|
||||
#=================================================
|
||||
# ADD A CONFIGURATION
|
||||
|
@ -63,9 +63,9 @@ set_permissions
|
|||
enable_super_admin
|
||||
|
||||
# Start a systemd service
|
||||
ynh_systemd_action --service_name=$app --action=start --log_path=systemd --line_match="$systemd_match_start_line"
|
||||
ynh_systemd_action --service_name="$app" --action=start --log_path=systemd --line_match="$systemd_match_start_line"
|
||||
|
||||
if [ $install_standard_flavor -eq 1 ]; then
|
||||
if [ "$install_standard_flavor" -eq 1 ]; then
|
||||
ynh_script_progression --message='Upgrading flavor...'
|
||||
wait_for_flavor_install
|
||||
fi
|
||||
|
@ -74,7 +74,7 @@ ynh_script_progression --message='Upgrading LDAP extension...' --weight=1
|
|||
install_exension 'org.xwiki.contrib.ldap:ldap-authenticator' "$ldap_version"
|
||||
|
||||
# Disable super admin
|
||||
ynh_systemd_action --service_name=$app --action=stop
|
||||
ynh_systemd_action --service_name="$app" --action=stop
|
||||
disable_super_admin
|
||||
|
||||
#=================================================
|
||||
|
@ -84,7 +84,7 @@ disable_super_admin
|
|||
#=================================================
|
||||
|
||||
ynh_script_progression --message='Starting a systemd service...' --weight=1
|
||||
ynh_systemd_action --service_name=$app --action=start --log_path=systemd --line_match="$systemd_match_start_line"
|
||||
ynh_systemd_action --service_name="$app" --action=start --log_path=systemd --line_match="$systemd_match_start_line"
|
||||
wait_xwiki_started
|
||||
|
||||
#=================================================
|
||||
|
|
Loading…
Add table
Reference in a new issue