doc/packaging_apps_multiinstance_fr.md
2016-02-24 23:05:46 +01:00

23 lines
No EOL
728 B
Markdown
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<a class="btn btn-lg btn-default" href="packaging_apps_fr">Packaging dapplication</a>
### Multi-instances
Le multi-instance est la capacité dune application a être installée plusieurs fois.
#### Scripts
Lorsque YunoHost installe une seconde fois lapplication, il passe au script en dernier paramètre `id__2` avec `id` provenant du manifeste. La valeur après l`id` est incrémentée.
Récupération de la dernière variable passée aux scripts :
```bash
APP=${!#}
```
Utilisation de la variable :
```bash
sudo yunohost app checkurl $domain$path -a $APP
```
#### Manifeste
Passer la variable `multi_instance` à `true` dans le [manifeste](packaging_apps_manifest_fr) :
```json
"multi_instance": "true",
```