mirror of
https://github.com/YunoHost-Apps/couchdb_ynh.git
synced 2024-09-03 18:16:11 +02:00
commit
41cae71da1
11 changed files with 84 additions and 156 deletions
66
README.md
66
README.md
|
@ -1,68 +1,44 @@
|
|||
# Couchdb for YunoHost
|
||||
<!--
|
||||
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.
|
||||
-->
|
||||
|
||||
# CouchDB for YunoHost
|
||||
|
||||
[![Integration level](https://dash.yunohost.org/integration/couchdb.svg)](https://dash.yunohost.org/appci/app/couchdb) ![](https://ci-apps.yunohost.org/ci/badges/couchdb.status.svg) ![](https://ci-apps.yunohost.org/ci/badges/couchdb.maintain.svg)
|
||||
[![Install couchdb with YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=couchdb)
|
||||
[![Install CouchDB with YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=couchdb)
|
||||
|
||||
*[Lire ce readme en français.](./README_fr.md)*
|
||||
|
||||
> *This package allows you to install couchdb quickly and simply on a YunoHost server.
|
||||
> *This package allows you to install CouchDB 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
|
||||
|
||||
Couchdb is a database system, where entries are json objects (allowing attachments), and that you can access and synchronize via simple http requests.
|
||||
Open-source document-oriented NoSQL database
|
||||
|
||||
As explained in wikipedia:
|
||||
> Apache CouchDB is an open-source document-oriented NoSQL database, implemented in Erlang.
|
||||
**Shipped version:** 3.1.1~ynh2
|
||||
|
||||
And as described in the couchdb official website:
|
||||
> Seamless multi-master sync, that scales from Big Data to Mobile, with an Intuitive HTTP/JSON API and designed for Reliability.
|
||||
|
||||
**Shipped version:** 3.1.1
|
||||
|
||||
|
||||
## Screenshots
|
||||
|
||||
![](https://upload.wikimedia.org/wikipedia/commons/c/c5/Apache_CouchDB_v2.1.1_Fauxton_Console.png)
|
||||
![](./doc/screenshots/Apache_CouchDB_v2.1.1_Fauxton_Console.png)
|
||||
|
||||
## Disclaimers / important information
|
||||
|
||||
## Configuration
|
||||
|
||||
You can do most configuration of couchdb from fauxton, the web interface, accessible at the domain you specified: https://domain.tld/_utils/index.html
|
||||
You can do most configuration of CouchDB from fauxton, the web interface, accessible at the domain you specified: `https://domain.tld/_utils/index.html`
|
||||
|
||||
## Documentation and resources
|
||||
|
||||
## Documentation
|
||||
|
||||
* Official documentation: https://docs.couchdb.org/en/stable/index.html
|
||||
|
||||
|
||||
## YunoHost specific features
|
||||
|
||||
#### Multi-user support
|
||||
|
||||
Couchdb has it's own users management system, so LDAP is not supported.
|
||||
|
||||
#### Supported architectures
|
||||
|
||||
* x86-64 - [![Build Status](https://ci-apps.yunohost.org/ci/logs/couchdb%20%28Apps%29.svg)](https://ci-apps.yunohost.org/ci/apps/couchdb/)
|
||||
* ARMv8-A - [![Build Status](https://ci-apps-arm.yunohost.org/ci/logs/couchdb%20%28Apps%29.svg)](https://ci-apps-arm.yunohost.org/ci/apps/couchdb/)
|
||||
|
||||
|
||||
## Limitations
|
||||
|
||||
By default this package installs couchdb as single node, if you need a different setup, please contribute with pull requests to improve the package :)
|
||||
|
||||
|
||||
## Links
|
||||
|
||||
* Report a bug: https://github.com/YunoHost-Apps/couchdb_ynh/issues
|
||||
* App website: Link to the official website of this app.
|
||||
* Upstream app repository: Link to the official repository of the upstream app.
|
||||
* YunoHost website: https://yunohost.org/
|
||||
|
||||
---
|
||||
|
||||
* Official app website: https://couchdb.apache.org/
|
||||
* Official user documentation: https://yunohost.org/apps
|
||||
* Official admin documentation: https://docs.couchdb.org/en/stable/
|
||||
* Upstream app code repository: https://github.com/apache/couchdb
|
||||
* YunoHost documentation for this app: https://yunohost.org/app_couchdb
|
||||
* Report a bug: https://github.com/YunoHost-Apps/couchdb_ynh/issues
|
||||
|
||||
## Developer info
|
||||
|
||||
|
@ -74,3 +50,5 @@ sudo yunohost app install https://github.com/YunoHost-Apps/couchdb_ynh/tree/test
|
|||
or
|
||||
sudo yunohost app upgrade couchdb -u https://github.com/YunoHost-Apps/couchdb_ynh/tree/testing --debug
|
||||
```
|
||||
|
||||
**More info regarding app packaging:** https://yunohost.org/packaging_apps
|
61
README_fr.md
61
README_fr.md
|
@ -1,65 +1,40 @@
|
|||
# Couchdb pour YunoHost
|
||||
# CouchDB pour YunoHost
|
||||
|
||||
[![Niveau d'intégration](https://dash.yunohost.org/integration/couchdb.svg)](https://dash.yunohost.org/appci/app/couchdb) ![](https://ci-apps.yunohost.org/ci/badges/couchdb.status.svg) ![](https://ci-apps.yunohost.org/ci/badges/couchdb.maintain.svg)
|
||||
[![Installer couchdb avec YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=couchdb)
|
||||
[![Installer CouchDB avec YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=couchdb)
|
||||
|
||||
*[Read this readme in english.](./README.md)*
|
||||
*[Lire ce readme en français.](./README_fr.md)*
|
||||
|
||||
> *Ce package vous permet d'installer couchdb rapidement et simplement sur un serveur YunoHost.
|
||||
Si vous n'avez pas YunoHost, consultez [le guide](https://yunohost.org/#/install) pour apprendre comment l'installer.*
|
||||
> *Ce package vous permet d'installer CouchDB 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.*
|
||||
|
||||
## Vue d'ensemble
|
||||
|
||||
Couchdb est un gestionnaire de bases de données dans lesquelles les entrées sont des documents jsons (avec possibilité de pièces jointes), qui peuvent être manipulées par de simples requêtes http.
|
||||
Système de gestion de base de données orienté documents
|
||||
|
||||
Comme le présente wikipédia:
|
||||
> Apache CouchDB est un système de gestion de base de données orienté documents, écrit en langage Erlang et distribué sous licence Apache.
|
||||
> Conçu pour le Web, il fait partie de la mouvance NoSQL, et a été conçu pour pouvoir être réparti sur une grappe de serveurs.
|
||||
**Version incluse :** 3.1.1~ynh2
|
||||
|
||||
**Version incluse :** 3.1.1
|
||||
|
||||
|
||||
## Captures d'écran
|
||||
|
||||
![](https://upload.wikimedia.org/wikipedia/commons/c/c5/Apache_CouchDB_v2.1.1_Fauxton_Console.png)
|
||||
![](./doc/screenshots/Apache_CouchDB_v2.1.1_Fauxton_Console.png)
|
||||
|
||||
## Avertissements / informations importantes
|
||||
|
||||
## Configuration
|
||||
|
||||
Couchdb peut-être configuré via fauxton, l'interface web accessible sur le domaine que vous avez spécifié: https://domain.tld/_utils/index.html
|
||||
Vous pouvez effectuer la plupart des configurations de CouchDB à partir de fauxton, l'interface Web, accessible sur le domaine que vous avez spécifié : `https://domain.tld/_utils/index.html`
|
||||
|
||||
## Documentations et ressources
|
||||
|
||||
## Documentation
|
||||
|
||||
* Documentation officielle : https://docs.couchdb.org/en/stable/index.html
|
||||
|
||||
|
||||
## Caractéristiques spécifiques YunoHost
|
||||
|
||||
#### Support multi-utilisateur
|
||||
|
||||
Couchdb a sa propre gestion d'utilisateurs, donc LDAP n'est pas supporté.
|
||||
|
||||
#### Architectures supportées
|
||||
|
||||
* x86-64 - [![Build Status](https://ci-apps.yunohost.org/ci/logs/couchdb%20%28Apps%29.svg)](https://ci-apps.yunohost.org/ci/apps/couchdb/)
|
||||
* ARMv8-A - [![Build Status](https://ci-apps-arm.yunohost.org/ci/logs/couchdb%20%28Apps%29.svg)](https://ci-apps-arm.yunohost.org/ci/apps/couchdb/)
|
||||
|
||||
|
||||
## Limitations
|
||||
|
||||
Par défaut, ce paquet install couchdb comme nœud simple. Si vous souhaitez permettre des installations plus avancées les contributions sont bienvenues :)
|
||||
|
||||
|
||||
## Liens
|
||||
|
||||
* Signaler un bug : https://github.com/YunoHost-Apps/couchdb_ynh/issues
|
||||
* Site de l'application : Lien vers le site officiel de cette application.
|
||||
* Dépôt de l'application principale : Lien vers le dépôt officiel de l'application principale.
|
||||
* Site web YunoHost : https://yunohost.org/
|
||||
|
||||
---
|
||||
|
||||
* Site officiel de l'app : https://couchdb.apache.org/
|
||||
* Documentation officielle utilisateur : https://yunohost.org/apps
|
||||
* Documentation officielle de l'admin : https://docs.couchdb.org/en/stable/
|
||||
* Dépôt de code officiel de l'app : https://github.com/apache/couchdb
|
||||
* Documentation YunoHost pour cette app : https://yunohost.org/app_couchdb
|
||||
* Signaler un bug : https://github.com/YunoHost-Apps/couchdb_ynh/issues
|
||||
|
||||
## Informations pour les développeurs
|
||||
|
||||
|
@ -71,3 +46,5 @@ sudo yunohost app install https://github.com/YunoHost-Apps/couchdb_ynh/tree/test
|
|||
ou
|
||||
sudo yunohost app upgrade couchdb -u https://github.com/YunoHost-Apps/couchdb_ynh/tree/testing --debug
|
||||
```
|
||||
|
||||
**Plus d'infos sur le packaging d'applications :** https://yunohost.org/packaging_apps
|
|
@ -1,12 +1,9 @@
|
|||
# See here for more information
|
||||
# https://github.com/YunoHost/package_check#syntax-check_process-file
|
||||
|
||||
;; Test complet
|
||||
; Manifest
|
||||
domain="domain.tld"
|
||||
path="/path"
|
||||
is_public=1
|
||||
password="pass"
|
||||
password="strong-password"
|
||||
; Checks
|
||||
pkg_linter=1
|
||||
setup_sub_dir=1
|
||||
|
@ -17,7 +14,6 @@
|
|||
upgrade=1
|
||||
backup_restore=1
|
||||
multi_instance=0
|
||||
port_already_use=0
|
||||
change_url=1
|
||||
;;; Options
|
||||
Email=squeak@eauchat.org
|
||||
|
|
3
doc/DISCLAIMER.md
Normal file
3
doc/DISCLAIMER.md
Normal file
|
@ -0,0 +1,3 @@
|
|||
## Configuration
|
||||
|
||||
You can do most configuration of CouchDB from fauxton, the web interface, accessible at the domain you specified: `https://domain.tld/_utils/index.html`
|
3
doc/DISCLAIMER_fr.md
Normal file
3
doc/DISCLAIMER_fr.md
Normal file
|
@ -0,0 +1,3 @@
|
|||
## Configuration
|
||||
|
||||
Vous pouvez effectuer la plupart des configurations de CouchDB à partir de fauxton, l'interface Web, accessible sur le domaine que vous avez spécifié : `https://domain.tld/_utils/index.html`
|
BIN
doc/screenshots/Apache_CouchDB_v2.1.1_Fauxton_Console.png
Normal file
BIN
doc/screenshots/Apache_CouchDB_v2.1.1_Fauxton_Console.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 109 KiB |
|
@ -1,13 +1,20 @@
|
|||
{
|
||||
"name": "Couchdb",
|
||||
"name": "CouchDB",
|
||||
"id": "couchdb",
|
||||
"packaging_format": 1,
|
||||
"description": {
|
||||
"en": "An open-source document-oriented NoSQL database.",
|
||||
"fr": "Système de gestion de base de données orienté documents."
|
||||
"en": "Open-source document-oriented NoSQL database",
|
||||
"fr": "Système de gestion de base de données orienté documents"
|
||||
},
|
||||
"version": "3.1.1~ynh1",
|
||||
"version": "3.1.1~ynh2",
|
||||
"url": "https://couchdb.apache.org/",
|
||||
"upstream": {
|
||||
"license": "Apache-2.0",
|
||||
"website": "https://couchdb.apache.org/",
|
||||
"admindoc": "https://docs.couchdb.org/en/stable/",
|
||||
"userdoc": "https://yunohost.org/apps",
|
||||
"code": "https://github.com/apache/couchdb"
|
||||
},
|
||||
"license": "Apache-2.0",
|
||||
"maintainer": {
|
||||
"name": "Squeak",
|
||||
|
@ -38,8 +45,8 @@
|
|||
"name": "is_public",
|
||||
"type": "boolean",
|
||||
"help": {
|
||||
"en": "If enabled, couchdb will be accessible without yunohost account on your server, but couchdb contains it's own user authentication system.",
|
||||
"fr": "Si cette case est cochée, couchdb sera accessible aux personnes n’ayant pas de compte yunohost sur votre serveur, mais couchdb a son propre système d'autentification des utilisateurs."
|
||||
"en": "If enabled, CouchDB will be accessible without YunoHost account on your server, but CouchDB contains it's own user authentication system.",
|
||||
"fr": "Si cette case est cochée, CouchDB sera accessible aux personnes n’ayant pas de compte YunoHost sur votre serveur, mais CouchDB a son propre système d'autentification des utilisateurs."
|
||||
},
|
||||
"default": true
|
||||
},
|
||||
|
|
|
@ -82,7 +82,7 @@ ynh_add_nginx_config
|
|||
#=================================================
|
||||
# INSTALL COUCHDB
|
||||
#=================================================
|
||||
ynh_script_progression --message="Installing couchdb..." --weight=60
|
||||
ynh_script_progression --message="Installing CouchDB..." --weight=60
|
||||
|
||||
COUCHDB_PASSWORD=$password
|
||||
echo "couchdb couchdb/mode select standalone
|
||||
|
@ -95,15 +95,14 @@ couchdb couchdb/adminpass_again password ${COUCHDB_PASSWORD}
|
|||
couchdb couchdb/adminpass_again seen true" | debconf-set-selections
|
||||
DEBIAN_FRONTEND=noninteractive # apt-get install -y --force-yes couchdb
|
||||
|
||||
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 8756C4F765C9AC3CB6B85D62379CE192D401AB61
|
||||
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 390EF70BB1EA12B2773962950EE62FB37A00258D 2>/dev/null
|
||||
|
||||
ynh_install_extra_app_dependencies --repo="https://apache.bintray.com/couchdb-deb buster main" --package="couchdb"
|
||||
# ynh_install_extra_app_dependencies --repo="https://apache.bintray.com/couchdb-deb buster main" --package="couchdb" --key="https://apache.bintray.com/couchdb-deb/dists/buster/Release.gpg"
|
||||
ynh_install_extra_app_dependencies --repo="https://apache.jfrog.io/artifactory/couchdb-deb/ buster main" --package="couchdb"
|
||||
|
||||
#=================================================
|
||||
# ADD SOME CUSTOM CONFIGURATION TO COUCH
|
||||
#=================================================
|
||||
ynh_script_progression --message="Customizing couchdb config..." --weight=2
|
||||
ynh_script_progression --message="Customizing CouchDB config..." --weight=2
|
||||
|
||||
# customize a bit the couch config
|
||||
ynh_add_config --template="../conf/couch_ynh.ini" --destination="$final_path/etc/local.d/couch_ynh.ini"
|
||||
|
|
|
@ -26,7 +26,6 @@ final_path=$(ynh_app_setting_get --app=$app --key=final_path)
|
|||
# REMOVE SERVICE INTEGRATION IN YUNOHOST
|
||||
#=================================================
|
||||
|
||||
# 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
|
||||
then
|
||||
ynh_script_progression --message="Removing $app service integration..." --weight=2
|
||||
|
@ -41,14 +40,6 @@ ynh_script_progression --message="Removing dependencies..." --weight=16
|
|||
# Remove metapackage and its dependencies
|
||||
ynh_remove_app_dependencies
|
||||
|
||||
#=================================================
|
||||
# REMOVE APP MAIN DIR
|
||||
#=================================================
|
||||
ynh_script_progression --message="Removing app main directory..." --weight=4
|
||||
|
||||
# Remove the app directory securely
|
||||
ynh_secure_remove --file="$final_path"
|
||||
|
||||
#=================================================
|
||||
# REMOVE NGINX CONFIGURATION
|
||||
#=================================================
|
||||
|
@ -65,16 +56,6 @@ ynh_script_progression --message="Removing logrotate configuration..." --weight=
|
|||
# Remove the app-specific logrotate config
|
||||
ynh_remove_logrotate
|
||||
|
||||
#=================================================
|
||||
# CLOSE A PORT
|
||||
#=================================================
|
||||
|
||||
if yunohost firewall list | grep -q "\- $port$"
|
||||
then
|
||||
ynh_script_progression --message="Closing port $port..." --weight=2
|
||||
ynh_exec_warn_less yunohost firewall disallow TCP $port
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
# REMOVE FAIL2BAN CONFIGURATION
|
||||
#=================================================
|
||||
|
|
|
@ -93,11 +93,9 @@ couchdb couchdb/adminpass_again password ${COUCHDB_PASSWORD}
|
|||
couchdb couchdb/adminpass_again seen true" | debconf-set-selections
|
||||
DEBIAN_FRONTEND=noninteractive # apt-get install -y --force-yes couchdb
|
||||
|
||||
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 8756C4F765C9AC3CB6B85D62379CE192D401AB61
|
||||
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 390EF70BB1EA12B2773962950EE62FB37A00258D 2>/dev/null
|
||||
|
||||
# ynh_add_app_dependencies --package="ca-certificates" # done before, when installing dependencies
|
||||
ynh_install_extra_app_dependencies --repo="https://apache.bintray.com/couchdb-deb buster main" --package="couchdb"
|
||||
# ynh_install_extra_app_dependencies --repo="https://apache.bintray.com/couchdb-deb buster main" --package="couchdb" --key="https://apache.bintray.com/couchdb-deb/dists/buster/Release.gpg"
|
||||
ynh_install_extra_app_dependencies --repo="https://apache.jfrog.io/artifactory/couchdb-deb/ buster main" --package="couchdb"
|
||||
|
||||
chmod 750 "$final_path"
|
||||
chmod -R o-rwx "$final_path"
|
||||
|
|
|
@ -25,7 +25,6 @@ password=$(ynh_app_setting_get --app=$app --key=password)
|
|||
#=================================================
|
||||
# CHECK VERSION
|
||||
#=================================================
|
||||
ynh_script_progression --message="Checking version..."
|
||||
|
||||
upgrade_type=$(ynh_check_app_version_changed)
|
||||
|
||||
|
@ -43,22 +42,6 @@ ynh_clean_setup () {
|
|||
# Exit if an error occurs during the execution of the script
|
||||
ynh_abort_if_errors
|
||||
|
||||
#=================================================
|
||||
# STANDARD UPGRADE STEPS
|
||||
#=================================================
|
||||
# ENSURE DOWNWARD COMPATIBILITY
|
||||
#=================================================
|
||||
ynh_script_progression --message="Ensuring downward compatibility..." --weight=4
|
||||
|
||||
# Cleaning legacy permissions
|
||||
if ynh_legacy_permissions_exists; then
|
||||
ynh_legacy_permissions_delete_all
|
||||
|
||||
ynh_app_setting_delete --app=$app --key=is_public
|
||||
fi
|
||||
|
||||
ynh_permission_url --permission="main" --url="/_utils/index.html" --add_url="/" --auth_header=false
|
||||
|
||||
#=================================================
|
||||
# NGINX CONFIGURATION
|
||||
#=================================================
|
||||
|
@ -79,23 +62,26 @@ ynh_install_app_dependencies $pkg_dependencies
|
|||
#=================================================
|
||||
# UPGRADING COUCHDB
|
||||
#=================================================
|
||||
ynh_script_progression --message="Upgrading couchdb..." --weight=60
|
||||
|
||||
COUCHDB_PASSWORD=$password
|
||||
echo "couchdb couchdb/mode select standalone
|
||||
couchdb couchdb/mode seen true
|
||||
couchdb couchdb/bindaddress string 127.0.0.1
|
||||
couchdb couchdb/bindaddress seen true
|
||||
couchdb couchdb/adminpass password ${COUCHDB_PASSWORD}
|
||||
couchdb couchdb/adminpass seen true
|
||||
couchdb couchdb/adminpass_again password ${COUCHDB_PASSWORD}
|
||||
couchdb couchdb/adminpass_again seen true" | debconf-set-selections
|
||||
DEBIAN_FRONTEND=noninteractive # apt-get install -y --force-yes couchdb
|
||||
if [ "$upgrade_type" == "UPGRADE_APP" ]
|
||||
then
|
||||
ynh_script_progression --message="Upgrading CouchDB..." --weight=50
|
||||
|
||||
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 8756C4F765C9AC3CB6B85D62379CE192D401AB61
|
||||
COUCHDB_PASSWORD=$password
|
||||
echo "couchdb couchdb/mode select standalone
|
||||
couchdb couchdb/mode seen true
|
||||
couchdb couchdb/bindaddress string 127.0.0.1
|
||||
couchdb couchdb/bindaddress seen true
|
||||
couchdb couchdb/adminpass password ${COUCHDB_PASSWORD}
|
||||
couchdb couchdb/adminpass seen true
|
||||
couchdb couchdb/adminpass_again password ${COUCHDB_PASSWORD}
|
||||
couchdb couchdb/adminpass_again seen true" | debconf-set-selections
|
||||
DEBIAN_FRONTEND=noninteractive # apt-get install -y --force-yes couchdb
|
||||
|
||||
ynh_install_extra_app_dependencies --repo="https://apache.bintray.com/couchdb-deb buster main" --package="couchdb"
|
||||
# ynh_install_extra_app_dependencies --repo="https://apache.bintray.com/couchdb-deb buster main" --package="couchdb" --key="https://apache.bintray.com/couchdb-deb/dists/buster/Release.gpg"
|
||||
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 390EF70BB1EA12B2773962950EE62FB37A00258D 2>/dev/null
|
||||
|
||||
ynh_install_extra_app_dependencies --repo="https://apache.jfrog.io/artifactory/couchdb-deb/ buster main" --package="couchdb"
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
# UPDATE A CONFIG FILE
|
||||
|
|
Loading…
Reference in a new issue