diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md new file mode 100644 index 0000000..2729a6b --- /dev/null +++ b/.github/ISSUE_TEMPLATE.md @@ -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.* diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md new file mode 100644 index 0000000..ef70e18 --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -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) diff --git a/README.md b/README.md index 6ca2aee..348a216 100644 --- a/README.md +++ b/README.md @@ -18,7 +18,7 @@ It shall NOT be edited by hand. ownCloud Infinite Scale (oCIS) is the new file sync & share platform that will be the foundation of your data management platform. -**Shipped version:** 5.0.0~ynh3 +**Shipped version:** 6.0.0~ynh2 ## Screenshots diff --git a/README_es.md b/README_es.md new file mode 100644 index 0000000..9ed0b39 --- /dev/null +++ b/README_es.md @@ -0,0 +1,47 @@ + + +# ownCloud para Yunohost + +[![Nivel de integración](https://dash.yunohost.org/integration/owncloud.svg)](https://dash.yunohost.org/appci/app/owncloud) ![Estado funcional](https://ci-apps.yunohost.org/ci/badges/owncloud.status.svg) ![Estado En Mantención](https://ci-apps.yunohost.org/ci/badges/owncloud.maintain.svg) + +[![Instalar ownCloud con Yunhost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=owncloud) + +*[Leer este README en otros idiomas.](./ALL_README.md)* + +> *Este paquete le permite instalarownCloud 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 + +ownCloud Infinite Scale (oCIS) is the new file sync & share platform that will be the foundation of your data management platform. + +**Versión actual:** 6.0.0~ynh2 + +## Capturas + +![Captura de ownCloud](./doc/screenshots/screenshot.png) + +## Documentaciones y recursos + +- Sitio web oficial: +- Documentación administrador oficial: +- Repositorio del código fuente oficial de la aplicación : +- Catálogo YunoHost: +- Reportar un error: + +## Información para desarrolladores + +Por favor enviar sus correcciones a la [`branch testing`](https://github.com/YunoHost-Apps/owncloud_ynh/tree/testing + +Para probar la rama `testing`, sigue asÍ: + +```bash +sudo yunohost app install https://github.com/YunoHost-Apps/owncloud_ynh/tree/testing --debug +o +sudo yunohost app upgrade owncloud -u https://github.com/YunoHost-Apps/owncloud_ynh/tree/testing --debug +``` + +**Mas informaciones sobre el empaquetado de aplicaciones:** diff --git a/README_it.md b/README_it.md new file mode 100644 index 0000000..21c3058 --- /dev/null +++ b/README_it.md @@ -0,0 +1,47 @@ + + +# ownCloud per YunoHost + +[![Livello di integrazione](https://dash.yunohost.org/integration/owncloud.svg)](https://dash.yunohost.org/appci/app/owncloud) ![Stato di funzionamento](https://ci-apps.yunohost.org/ci/badges/owncloud.status.svg) ![Stato di manutenzione](https://ci-apps.yunohost.org/ci/badges/owncloud.maintain.svg) + +[![Installa ownCloud con YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=owncloud) + +*[Leggi questo README in altre lingue.](./ALL_README.md)* + +> *Questo pacchetto ti permette di installare ownCloud su un server YunoHost in modo semplice e veloce.* +> *Se non hai YunoHost, consulta [la guida](https://yunohost.org/install) per imparare a installarlo.* + +## Panoramica + +ownCloud Infinite Scale (oCIS) is the new file sync & share platform that will be the foundation of your data management platform. + +**Versione pubblicata:** 5.0.0~ynh9 + +## Screenshot + +![Screenshot di ownCloud](./doc/screenshots/screenshot.png) + +## Documentazione e risorse + +- Sito web ufficiale dell’app: +- Documentazione ufficiale per gli amministratori: +- Repository upstream del codice dell’app: +- Store di YunoHost: +- Segnala un problema: + +## Informazioni per sviluppatori + +Si prega di inviare la tua pull request alla [branch di `testing`](https://github.com/YunoHost-Apps/owncloud_ynh/tree/testing). + +Per provare la branch di `testing`, si prega di procedere in questo modo: + +```bash +sudo yunohost app install https://github.com/YunoHost-Apps/owncloud_ynh/tree/testing --debug +o +sudo yunohost app upgrade owncloud -u https://github.com/YunoHost-Apps/owncloud_ynh/tree/testing --debug +``` + +**Maggiori informazioni riguardo il pacchetto di quest’app:** diff --git a/README_zh_Hans.md b/README_zh_Hans.md index 892c834..3a84740 100644 --- a/README_zh_Hans.md +++ b/README_zh_Hans.md @@ -5,6 +5,7 @@ # YunoHost 的 ownCloud + [![集成程度](https://dash.yunohost.org/integration/owncloud.svg)](https://dash.yunohost.org/appci/app/owncloud) ![工作状态](https://ci-apps.yunohost.org/ci/badges/owncloud.status.svg) ![维护状态](https://ci-apps.yunohost.org/ci/badges/owncloud.maintain.svg) [![使用 YunoHost 安装 ownCloud](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=owncloud) @@ -18,7 +19,8 @@ ownCloud Infinite Scale (oCIS) is the new file sync & share platform that will be the foundation of your data management platform. -**分发版本:** 5.0.0~ynh3 +**分发版本:** 6.0.0~ynh2 + ## 截图 diff --git a/conf/.env b/conf/.env index 308b1c3..7804916 100644 --- a/conf/.env +++ b/conf/.env @@ -1,19 +1,9 @@ +TZ=__TIMEZONE__ OCIS_URL=https://__DOMAIN__ +#OCIS_PUBLIC_URL=https://__DOMAIN__ PROXY_HTTP_ADDR=127.0.0.1:__PORT__ -PROXY_TLS=false -OCIS_INSECURE=true - -OCIS_LOG_LEVEL=warn - -OCIS_FORCE_CONFIG_OVERWRITE=true - -OCIS_CONFIG_DIR=__INSTALL_DIR__ -OCIS_BASE_DATA_PATH=__DATA_DIR__ - -OCIS_DEFAULT_LANGUAGE=__LANGUAGE__ - -#OCIS_EXCLUDE_RUN_SERVICES=thumbnails - +PROXY_TLS=true +OCIS_INSECURE=false #AUTH_BASIC_AUTH_MANAGER=ldap #OCIS_LDAP_URI=ldap://127.0.0.1:389 #OCIS_LDAP_USER_BASE_DN='ou=users,dc=yunohost,dc=org' @@ -28,4 +18,7 @@ NOTIFICATIONS_SMTP_PORT: 25 NOTIFICATIONS_SMTP_SENDER: oCIS notifications NOTIFICATIONS_SMTP_USERNAME: __APP__ NOTIFICATIONS_SMTP_PASSWORD: __MAIL_PWD__ -NOTIFICATIONS_SMTP_INSECURE: true \ No newline at end of file +NOTIFICATIONS_SMTP_INSECURE: true + +# Set this to true if you want to enforce passwords on all public shares. +OCIS_SHARING_PUBLIC_SHARE_MUST_HAVE_PASSWORD=false diff --git a/conf/systemd.service b/conf/systemd.service index c7cf706..9130d78 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -5,7 +5,7 @@ Description=ownCloud: Infinite Scale server Type=simple User=__APP__ Group=__APP__ -EnvironmentFile=__INSTALL_DIR__/ocis.env +EnvironmentFile=__DATA_DIR__/config/ocis.env ExecStart=__INSTALL_DIR__/ocis server Restart=always diff --git a/doc/PRE_INSTALL.md b/doc/PRE_INSTALL.md index 795b938..6ce6430 100644 --- a/doc/PRE_INSTALL.md +++ b/doc/PRE_INSTALL.md @@ -1 +1 @@ -Please note, this package is only intended to test ownCloud Infinite Scale. It should not be used for production. \ No newline at end of file +Please note, this package is only intended to test ownCloud Infinite Scale. It should not be used for production for now. \ No newline at end of file diff --git a/manifest.toml b/manifest.toml index 87c1075..f0d5cbf 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "ownCloud" description.en = "Online storage, file sharing platform" description.fr = "Stockage en ligne, plateforme de partage de fichiers" -version = "5.0.0~ynh3" +version = "6.0.0~ynh2" maintainers = ["eric_G"] @@ -25,8 +25,8 @@ ldap = false sso = false -disk = "50M" -ram.build = "300M" +disk = "100M" +ram.build = "800M" ram.runtime = "50M" [install] @@ -41,7 +41,7 @@ ram.runtime = "50M" ask.en = "Choose the application language" ask.fr = "Choisissez la langue de l'application" type = "select" - choices = ["de", "fr", "en"] + choices = ["cs", "de", "en", "es", "fr", "gl", "it"] default = "fr" [install.password] @@ -50,19 +50,21 @@ ram.runtime = "50M" [resources] [resources.sources.main] - amd64.url = "https://download.owncloud.com/ocis/ocis/testing/5.0.0-alpha.3/ocis-5.0.0-alpha.3-linux-amd64" - amd64.sha256 = "e8712652b74d44e0c34ab92c389ba4751ffaf7e29a0465f2c3bf074a22937dd9" - arm64.url = "https://download.owncloud.com/ocis/ocis/testing/5.0.0-alpha.3/ocis-5.0.0-alpha.3-linux-arm64" - arm64.sha256 = "4d891e35ef68a65460280911e81139b07ec03b98bcf355a70f6cdcf539ff63e5" - armhf.url = "https://download.owncloud.com/ocis/ocis/testing/5.0.0-alpha.3/ocis-5.0.0-alpha.3-linux-arm" - armhf.sha256 = "840f752a1c07d0742e7d6898524740ca7fc6e44fa212c6ce810b6cd0f63f6bd7" - i386.url = "https://download.owncloud.com/ocis/ocis/testing/5.0.0-alpha.3/ocis-5.0.0-alpha.3-linux-386" - i386.sha256 = "71a274c6fdcbfe072daf5188807ed4d0cd4520f31aee707c5f5fa933e1c3e78a" + amd64.url = "https://github.com/owncloud/ocis/releases/download/v6.0.0/ocis-6.0.0-linux-amd64" + amd64.sha256 = "805e512046d6ac3f75da44805e2560a2f64dddb18ebd00d90d891aaf66b3a414" + arm64.url = "https://github.com/owncloud/ocis/releases/download/v6.0.0/ocis-6.0.0-linux-arm64" + arm64.sha256 = "e753278d479aeb8af18278fa3f53e5de6fd54309c307afffb8f4f3f15608f778" + armhf.url = "https://github.com/owncloud/ocis/releases/download/v6.0.0/ocis-6.0.0-linux-arm" + armhf.sha256 = "e55aa0706067f7256a7c3d7828fb69c0178d7b11ebba51c044e163e5f92de7b9" + i386.url = "https://github.com/owncloud/ocis/releases/download/v6.0.0/ocis-6.0.0-linux-386" + i386.sha256 = "c0fe4e6c95611e789f3e11d55afb8a6755b5b129448dc6bf312c9d6236fd093a" in_subdir = false rename = "ocis" - [resources.ports] - main.default = 9200 + autoupdate.strategy = "latest_github_release" + autoupdate.asset.amd64 = "^ocis-.*-linux-amd64$" + autoupdate.asset.arm64 = "^ocis-.*-linux-arm64$" + autoupdate.asset.i386 = "^ocis-.*-linux-386$" [resources.system_user] allow_email = true @@ -70,11 +72,13 @@ ram.runtime = "50M" [resources.install_dir] [resources.data_dir] + subdirs = ["config"] + + [resources.ports] [resources.permissions] main.url = "/" main.auth_header = false - api.url = "/api" api.auth_header = false api.show_tile = false diff --git a/scripts/backup b/scripts/backup index cf2d1b6..3badad1 100755 --- a/scripts/backup +++ b/scripts/backup @@ -28,15 +28,11 @@ ynh_backup --src_path="$install_dir" ynh_backup --src_path="$data_dir" --is_big #================================================= -# BACKUP THE NGINX CONFIGURATION +# SYSTEM CONFIGURATION #================================================= ynh_backup --src_path="/etc/nginx/conf.d/$domain.d/$app.conf" -#================================================= -# BACKUP SYSTEMD -#================================================= - ynh_backup --src_path="/etc/systemd/system/$app.service" #================================================= diff --git a/scripts/change_url b/scripts/change_url index f7c2e52..cac663e 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -9,6 +9,8 @@ source _common.sh source /usr/share/yunohost/helpers +timezone=$(cat /etc/timezone) + #================================================= # STANDARD MODIFICATIONS #================================================= diff --git a/scripts/install b/scripts/install index 6f325e1..cbe9fe2 100755 --- a/scripts/install +++ b/scripts/install @@ -9,6 +9,8 @@ source _common.sh source /usr/share/yunohost/helpers +timezone=$(cat /etc/timezone) + #================================================= # DOWNLOAD, CHECK AND UNPACK SOURCE #================================================= @@ -39,10 +41,10 @@ yunohost service add $app --description="File sharing platform" --log="/var/log/ #================================================= ynh_script_progression --message="Adding a configuration file..." --weight=1 -ynh_add_config --template=".env" --destination="$install_dir/ocis.env" +ynh_add_config --template=".env" --destination="$data_dir/config/ocis.env" -chmod 400 "$install_dir/ocis.env" -chown $app:$app "$install_dir/ocis.env" +chmod 400 "$data_dir/config/ocis.env" +chown $app:$app "$data_dir/config/ocis.env" #================================================= # INSTALL OWNCLOUD @@ -50,12 +52,13 @@ chown $app:$app "$install_dir/ocis.env" ynh_script_progression --message="Installing $app..." --weight=3 pushd "$install_dir" - ./ocis init --insecure=true --force-overwrite=true --admin-password=$password --config-path=$install_dir + ./ocis init --insecure=true --force-overwrite=true --admin-password=$password --config-path=$data_dir/config/ popd chmod 750 "$install_dir" chmod -R o-rwx "$install_dir" chown -R $app:www-data "$install_dir" +chown $app:$app "$data_dir/config/ocis.yaml" #================================================= # START SYSTEMD SERVICE diff --git a/scripts/upgrade b/scripts/upgrade index 525c82c..2cd3f72 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -9,11 +9,7 @@ source _common.sh source /usr/share/yunohost/helpers -#================================================= -# CHECK VERSION -#================================================= - -upgrade_type=$(ynh_check_app_version_changed) +timezone=$(cat /etc/timezone) #================================================= # STANDARD UPGRADE STEPS @@ -24,17 +20,22 @@ ynh_script_progression --message="Stopping a systemd service..." --weight=1 ynh_systemd_action --service_name=$app --action="stop" --log_path="systemd" +#================================================= +# ENSURE DOWNWARD COMPATIBILITY +#================================================= +ynh_script_progression --message="Ensuring downward compatibility..." --weight=1 + +if [[ -f "$install_dir/ocis.yaml" ]]; then + mv "$install_dir/ocis.yaml" "$data_dir/config/ocis.yaml" +fi + #================================================= # DOWNLOAD, CHECK AND UNPACK SOURCE #================================================= +ynh_script_progression --message="Upgrading source files..." --weight=1 -if [ "$upgrade_type" == "UPGRADE_APP" ] -then - ynh_script_progression --message="Upgrading source files..." --weight=1 - - # Download, check integrity, uncompress and patch the source from app.src - ynh_setup_source --dest_dir="$install_dir" #--keep="ocis.env ocis.yaml" -fi +# Download, check integrity, uncompress and patch the source from app.src +ynh_setup_source --dest_dir="$install_dir" --full_replace=1 chmod -R o-rwx "$install_dir" chown -R $app:www-data "$install_dir"