1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/invoiceninja_ynh.git synced 2024-09-03 19:26:22 +02:00

Merge pull request #32 from YunoHost-Apps/testing

Testing
This commit is contained in:
Sebastian Gumprich 2022-07-18 07:55:02 +02:00 committed by GitHub
commit 903a9369cd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 77 additions and 53 deletions

View file

@ -5,7 +5,7 @@ It shall NOT be edited by hand.
# InvoiceNinja for YunoHost
[![Integration level](https://dash.yunohost.org/integration/invoiceninja.svg)](https://dash.yunohost.org/appci/app/invoiceninja) ![](https://ci-apps.yunohost.org/ci/badges/invoiceninja.status.svg) ![](https://ci-apps.yunohost.org/ci/badges/invoiceninja.maintain.svg)
[![Integration level](https://dash.yunohost.org/integration/invoiceninja.svg)](https://dash.yunohost.org/appci/app/invoiceninja) ![Working status](https://ci-apps.yunohost.org/ci/badges/invoiceninja.status.svg) ![Maintenance status](https://ci-apps.yunohost.org/ci/badges/invoiceninja.maintain.svg)
[![Install InvoiceNinja with YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=invoiceninja)
*[Lire ce readme en français.](./README_fr.md)*
@ -15,15 +15,15 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in
## Overview
Create and email invoices, track payments and expenses, and time tasks
Create and email invoices, track payments and expenses
**Shipped version:** 4.5.45~ynh1
**Shipped version:** 4.5.47~ynh1
**Demo:** https://app.invoiceninja.com/dashboard
## Screenshots
![](./doc/screenshots/screenshot.png)
![Screenshot of InvoiceNinja](./doc/screenshots/screenshot.png)
## Disclaimers / important information
@ -39,21 +39,22 @@ Create and email invoices, track payments and expenses, and time tasks
## Documentation and resources
* Official app website: https://invoiceninja.org
* Official admin documentation: https://docs.invoiceninja.com/index.html
* Upstream app code repository: https://github.com/invoiceninja/invoiceninja
* YunoHost documentation for this app: https://yunohost.org/app_invoiceninja
* Report a bug: https://github.com/YunoHost-Apps/invoiceninja_ynh/issues
* Official app website: <https://invoiceninja.org>
* Official admin documentation: <https://docs.invoiceninja.com/index.html>
* Upstream app code repository: <https://github.com/invoiceninja/invoiceninja>
* YunoHost documentation for this app: <https://yunohost.org/app_invoiceninja>
* Report a bug: <https://github.com/YunoHost-Apps/invoiceninja_ynh/issues>
## Developer info
Please send your pull request to the [testing branch](https://github.com/YunoHost-Apps/invoiceninja_ynh/tree/testing).
To try the testing branch, please proceed like that.
```
``` bash
sudo yunohost app install https://github.com/YunoHost-Apps/invoiceninja_ynh/tree/testing --debug
or
sudo yunohost app upgrade invoiceninja -u https://github.com/YunoHost-Apps/invoiceninja_ynh/tree/testing --debug
```
**More info regarding app packaging:** https://yunohost.org/packaging_apps
**More info regarding app packaging:** <https://yunohost.org/packaging_apps>

View file

@ -1,25 +1,29 @@
<!--
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.
-->
# InvoiceNinja pour YunoHost
[![Niveau d'intégration](https://dash.yunohost.org/integration/invoiceninja.svg)](https://dash.yunohost.org/appci/app/invoiceninja) ![](https://ci-apps.yunohost.org/ci/badges/invoiceninja.status.svg) ![](https://ci-apps.yunohost.org/ci/badges/invoiceninja.maintain.svg)
[![Niveau d'intégration](https://dash.yunohost.org/integration/invoiceninja.svg)](https://dash.yunohost.org/appci/app/invoiceninja) ![Statut du fonctionnement](https://ci-apps.yunohost.org/ci/badges/invoiceninja.status.svg) ![Statut de maintenance](https://ci-apps.yunohost.org/ci/badges/invoiceninja.maintain.svg)
[![Installer InvoiceNinja avec YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=invoiceninja)
*[Read this readme in english.](./README.md)*
*[Lire ce readme en français.](./README_fr.md)*
> *Ce package vous permet d'installer InvoiceNinja 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
Créez et envoyez des factures par e-mail, suivez les paiements
**Version incluse :** 4.5.45~ynh1
**Version incluse :** 4.5.47~ynh1
**Démo :** https://app.invoiceninja.com/dashboard
## Captures d'écran
![](./doc/screenshots/screenshot.png)
![Capture d'écran de InvoiceNinja](./doc/screenshots/screenshot.png)
## Avertissements / informations importantes
@ -35,21 +39,22 @@ Si vous n'avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour
## Documentations et ressources
* Site officiel de l'app : https://invoiceninja.org
* Documentation officielle de l'admin : https://docs.invoiceninja.com/index.html
* Dépôt de code officiel de l'app : https://github.com/invoiceninja/invoiceninja
* Documentation YunoHost pour cette app : https://yunohost.org/app_invoiceninja
* Signaler un bug : https://github.com/YunoHost-Apps/invoiceninja_ynh/issues
* Site officiel de l'app : <https://invoiceninja.org>
* Documentation officielle de l'admin : <https://docs.invoiceninja.com/index.html>
* Dépôt de code officiel de l'app : <https://github.com/invoiceninja/invoiceninja>
* Documentation YunoHost pour cette app : <https://yunohost.org/app_invoiceninja>
* Signaler un bug : <https://github.com/YunoHost-Apps/invoiceninja_ynh/issues>
## Informations pour les développeurs
Merci de faire vos pull request sur la [branche testing](https://github.com/YunoHost-Apps/invoiceninja_ynh/tree/testing).
Pour essayer la branche testing, procédez comme suit.
```
``` bash
sudo yunohost app install https://github.com/YunoHost-Apps/invoiceninja_ynh/tree/testing --debug
ou
sudo yunohost app upgrade invoiceninja -u https://github.com/YunoHost-Apps/invoiceninja_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>

View file

@ -12,8 +12,8 @@
setup_private=0
setup_public=0
upgrade=1
# 4.5.18~ynh1
upgrade=1 from_commit=572f98be58975399c5e7fc7d435a4ac5b78765da
# 4.5.45~ynh1
upgrade=1 from_commit=1f60ce6460175f08de8e61d7545a3e16888bd904
backup_restore=1
multi_instance=1
port_already_use=0
@ -21,6 +21,3 @@
;;; Options
Email=
Notification=none
;;; Upgrade options
; commit=572f98be58975399c5e7fc7d435a4ac5b78765da
name=4.5.18~ynh1

View file

@ -29,7 +29,7 @@ MAILGUN_SECRET=
#POSTMARK_API_TOKEN=
PHANTOMJS_CLOUD_KEY='a-demo-key-with-low-quota-per-ip-address'
PHANTOMJS_BIN_PATH=/usr/bin/phantomjs
PHANTOMJS_SECRET=__PHANTOMJS_KEY__
LOG=single

View file

@ -1,6 +1,6 @@
SOURCE_URL=https://download.invoiceninja.com/ninja-v4.5.45.zip
SOURCE_SUM=750d8a841621b327e0d66ec22fbd6fa44c018e7b0986222aec197d57374e5b82
SOURCE_URL=https://download.invoiceninja.com/ninja-v4.5.47.zip
SOURCE_SUM=851e7a546ba1ccb8699dd818c14ce4a3192b521c82aef90e695681818649da71
SOURCE_SUM_PRG=sha256sum
SOURCE_FORMAT=zip
SOURCE_IN_SUBDIR=true
SOURCE_FILENAME=invoiceninja-v4.5.45.zip
SOURCE_FILENAME=invoiceninja-v4.5.47.zip

View file

@ -9,11 +9,6 @@ location ^~ __PATH__/ {
rewrite ^ __PATH__/index.php;
}
# Force usage of https
if ($scheme = http) {
rewrite ^ https://$server_name$request_uri? permanent;
}
# Add headers to serve security related headers
more_set_headers "Strict-Transport-Security: max-age=15768000; includeSubDomains; preload;";
more_set_headers "X-Content-Type-Options: nosniff";

View file

@ -3,9 +3,10 @@
"id": "invoiceninja",
"packaging_format": 1,
"description": {
"en": "Create and email invoices, track payments and expenses, and time tasks"
"en": "Create and email invoices, track payments and expenses",
"fr": "Créez et envoyez des factures par e-mail, suivez les paiements"
},
"version": "4.5.45~ynh1",
"version": "4.5.47~ynh1",
"url": "https://invoiceninja.org",
"upstream": {
"license": "AAL",
@ -21,7 +22,7 @@
"url": "https://github.com/YunoHost-Apps/invoiceninja_ynh/"
},
"requirements": {
"yunohost": ">= 4.1.3"
"yunohost": ">= 4.3.0"
},
"multi_instance": true,
"services": [
@ -33,8 +34,7 @@
"install" : [
{
"name": "domain",
"type": "domain",
"example": "example.com"
"type": "domain"
},
{
"name": "path",
@ -44,8 +44,7 @@
},
{
"name": "admin",
"type": "user",
"example": "johndoe"
"type": "user"
},
{
"name": "language",

View file

@ -5,7 +5,7 @@
#=================================================
# dependencies used by the app
pkg_dependencies=""
pkg_dependencies="phantomjs"
YNH_PHP_VERSION="7.3"

View file

@ -84,6 +84,13 @@ db_user=$db_name
ynh_app_setting_set --app=$app --key=db_name --value=$db_name
ynh_mysql_setup_db --db_user=$db_user --db_name=$db_name
#=================================================
# INSTALL DEPENDENCIES
#=================================================
ynh_script_progression --message="Installing dependencies..."
ynh_install_app_dependencies $pkg_dependencies
#=================================================
# DOWNLOAD, CHECK AND UNPACK SOURCE
#=================================================

View file

@ -32,6 +32,14 @@ ynh_script_progression --message="Removing the MySQL database..."
# Remove a database if it exists, along with the associated user
ynh_mysql_remove_db --db_user=$db_user --db_name=$db_name
#=================================================
# REMOVE DEPENDENCIES
#=================================================
ynh_script_progression --message="Removing dependencies..."
# Remove metapackage and its dependencies
ynh_remove_app_dependencies
#=================================================
# REMOVE APP MAIN DIR
#=================================================

15
scripts/restore Executable file → Normal file
View file

@ -38,10 +38,7 @@ phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
#=================================================
ynh_script_progression --message="Validating restoration parameters..."
ynh_webpath_available --domain=$domain --path_url=$path_url \
|| ynh_die --message="Path not available: ${domain}${path_url}"
test ! -d $final_path \
|| ynh_die --message="There is already a directory: $final_path "
test ! -d $final_path || ynh_die --message="There is already a directory: $final_path "
#=================================================
# STANDARD RESTORATION STEPS
@ -88,7 +85,15 @@ ynh_mysql_setup_db --db_user=$db_user --db_name=$db_name --db_pwd=$db_pwd
ynh_mysql_connect_as --user=$db_user --password=$db_pwd --database=$db_name < ./db.sql
#=================================================
# RESTORE VARIOUS FILES
# REINSTALL DEPENDENCIES
#=================================================
ynh_script_progression --message="Reinstalling dependencies..."
# Define and install dependencies
ynh_install_app_dependencies $pkg_dependencies
#=================================================
# RESTORE THE CRON FILE
#=================================================
ynh_script_progression --message="Restoring various files..."

View file

@ -93,13 +93,20 @@ then
ynh_script_progression --message="Upgrading source files..."
# Download, check integrity, uncompress and patch the source from app.src
ynh_setup_source --dest_dir="$final_path"
ynh_setup_source --dest_dir="$final_path" --keep=".env"
fi
chmod 750 "$final_path"
chmod -R o-rwx "$final_path"
chown -R $app:www-data "$final_path"
#=================================================
# UPGRADE DEPENDENCIES
#=================================================
ynh_script_progression --message="Upgrading dependencies..."
ynh_install_app_dependencies $pkg_dependencies
#=================================================
# NGINX CONFIGURATION
#=================================================
@ -143,11 +150,11 @@ pushd "$final_path"
php$phpversion artisan down
# Optimize the framework for better performance
php$phpversion artisan optimize --force
php$phpversion artisan optimize
# Run the database migrations
php$phpversion artisan migrate --force
php$phpversion artisan db:seed --class=UpdateSeeder --force
php$phpversion artisan db:seed --force
# Bring the application out of maintenance mode
php$phpversion artisan up