mirror of
https://github.com/YunoHost/doc.git
synced 2024-09-03 20:06:26 +02:00
[fix] Remove empty example in hooks
This commit is contained in:
parent
a6161af916
commit
ac65563882
2 changed files with 8 additions and 105 deletions
|
@ -33,4 +33,4 @@ Si vous empaquetez une application, vous ne devez pas mettre vous-même le hook
|
||||||
```
|
```
|
||||||
Dans le dossier des hooks, créer un script bash appelé avec le type de hook que vous voulez créer par exemple `post_create_user`.
|
Dans le dossier des hooks, créer un script bash appelé avec le type de hook que vous voulez créer par exemple `post_create_user`.
|
||||||
|
|
||||||
## [Liste des hooks et leurs variables](/packaging_apps_hooks_fr)
|
## -> [Liste des hooks et leurs variables](https://yunohost.org/en/packaging_apps_hooks)
|
||||||
|
|
|
@ -73,12 +73,6 @@ The admin of $domain
|
||||||
|
|
||||||
echo $message | mail -s "Welcome on $domain !" $YNH_USER_MAIL
|
echo $message | mail -s "Welcome on $domain !" $YNH_USER_MAIL
|
||||||
```
|
```
|
||||||
|
|
||||||
###### Add the user to samba
|
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
|
|
||||||
|
@ -103,10 +97,6 @@ This hooks is run at the end of the command `yunohost user delete` or equivalent
|
||||||
```bash
|
```bash
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
```
|
```
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
|
|
||||||
|
@ -146,11 +136,6 @@ If you have not asked for changing your password, you probably should contact th
|
||||||
|
|
||||||
echo $message | mail -s "Your password has been changed on $domain !" $YNH_USER_USERNAME
|
echo $message | mail -s "Your password has been changed on $domain !" $YNH_USER_USERNAME
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
|
|
||||||
|
@ -172,10 +157,6 @@ This hooks is run at the end of the command `yunohost user permission add` or eq
|
||||||
##### No waited return
|
##### No waited return
|
||||||
|
|
||||||
##### Examples
|
##### Examples
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
|
|
||||||
|
@ -197,11 +178,6 @@ This hooks is run at the end of the command `yunohost user permission remove` or
|
||||||
##### No waited return
|
##### No waited return
|
||||||
|
|
||||||
##### Examples
|
##### Examples
|
||||||
|
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
|
|
||||||
|
@ -230,10 +206,6 @@ This hooks is run at the end of the command `yunohost domain add` or equivalent
|
||||||
```bash
|
```bash
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
|
|
||||||
|
@ -253,14 +225,6 @@ This hooks is run at the end of the command `yunohost domain remove` or equivale
|
||||||
##### No waited return
|
##### No waited return
|
||||||
|
|
||||||
##### Examples
|
##### Examples
|
||||||
|
|
||||||
######
|
|
||||||
```bash
|
|
||||||
```
|
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
|
|
||||||
|
@ -283,12 +247,9 @@ This hooks is run at the end of the command `yunohost domain cert update` or equ
|
||||||
|
|
||||||
###### Restart a service after cert renewal
|
###### Restart a service after cert renewal
|
||||||
```bash
|
```bash
|
||||||
|
#!/bin/bash
|
||||||
systemctl restart gemserv
|
systemctl restart gemserv
|
||||||
```
|
```
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
|
|
||||||
|
@ -338,10 +299,6 @@ if [[ "$1" == "XXXX.nohost.me" ]] ; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
|
|
||||||
|
@ -366,15 +323,8 @@ This hooks is run at the end of the command `yunohost app change-url` or equival
|
||||||
##### No waited return
|
##### No waited return
|
||||||
|
|
||||||
##### Examples
|
##### Examples
|
||||||
|
|
||||||
######
|
|
||||||
```bash
|
|
||||||
```
|
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
### post_app_upgrade
|
### post_app_upgrade
|
||||||
[details summary="<i>Triggered on app upgrade</i>" class="helper-card-subtitle text-muted"]
|
[details summary="<i>Triggered on app upgrade</i>" class="helper-card-subtitle text-muted"]
|
||||||
|
|
||||||
|
@ -411,12 +361,8 @@ if [[ "$app" == "etherpad_mypads" ]]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
### post_app_install
|
### post_app_install
|
||||||
[details summary="<i>Triggered at the end of an app installation</i>" class="helper-card-subtitle text-muted"]
|
[details summary="<i>Triggered at the end of an app installation</i>" class="helper-card-subtitle text-muted"]
|
||||||
|
|
||||||
|
@ -436,18 +382,9 @@ This hooks is run at the end of the command `yunohost app install` or equivalent
|
||||||
##### No waited return
|
##### No waited return
|
||||||
|
|
||||||
##### Examples
|
##### Examples
|
||||||
|
|
||||||
######
|
|
||||||
```bash
|
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
```
|
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
|
|
||||||
### post_app_remove
|
### post_app_remove
|
||||||
[details summary="<i>Triggered after removing an app</i>" class="helper-card-subtitle text-muted"]
|
[details summary="<i>Triggered after removing an app</i>" class="helper-card-subtitle text-muted"]
|
||||||
|
|
||||||
|
@ -467,17 +404,6 @@ This hooks is run at the end of the command `yunohost app remove` or equivalent
|
||||||
##### No waited return
|
##### No waited return
|
||||||
|
|
||||||
##### Examples
|
##### Examples
|
||||||
|
|
||||||
######
|
|
||||||
```bash
|
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
```
|
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
## Backup / Restore
|
## Backup / Restore
|
||||||
|
@ -524,11 +450,6 @@ ynh_backup "/etc/yunohost/hooks.d/backup/99-conf_custom"
|
||||||
ynh_backup "/etc/yunohost/hooks.d/restore/99-conf_custom"
|
ynh_backup "/etc/yunohost/hooks.d/restore/99-conf_custom"
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
### restore
|
### restore
|
||||||
|
@ -548,7 +469,7 @@ This hooks is run at the end of the command `yunohost backup restore` or equival
|
||||||
|
|
||||||
##### Examples
|
##### Examples
|
||||||
|
|
||||||
######
|
###### restore custom files
|
||||||
```bash
|
```bash
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
@ -574,11 +495,8 @@ ynh_restore_file "/etc/yunohost/hooks.d/restore/99-conf_custom"
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
### backup_method
|
### backup_method
|
||||||
[details summary="<i>Define a new way to backup and restore files</i>" class="helper-card-subtitle text-muted"]
|
[details summary="<i>Define a new way to backup and restore files</i>" class="helper-card-subtitle text-muted"]
|
||||||
|
|
||||||
|
@ -640,11 +558,6 @@ esac
|
||||||
exit 0
|
exit 0
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
## Configuration and firewall
|
## Configuration and firewall
|
||||||
|
@ -670,11 +583,6 @@ This hooks is run at the end of the command `yunohost firewall reload` or equiva
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
iptables -A OUTPUT -p tcp -m tcp --dport 25 -j ACCEPT
|
iptables -A OUTPUT -p tcp -m tcp --dport 25 -j ACCEPT
|
||||||
```
|
```
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
### conf_regen
|
### conf_regen
|
||||||
|
@ -713,10 +621,5 @@ postfix_conf=$pending_dir/../postfix/etc/postfix/main.cf
|
||||||
echo '
|
echo '
|
||||||
compatibility_level = 2' >> $postfix_conf
|
compatibility_level = 2' >> $postfix_conf
|
||||||
```
|
```
|
||||||
|
|
||||||
##### Hook changelog
|
|
||||||
-
|
|
||||||
|
|
||||||
|
|
||||||
[/details]
|
[/details]
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue