1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/diaspora_ynh.git synced 2024-09-03 18:26:13 +02:00

Add mail capabilities and choose an admin

This commit is contained in:
Augustin Trancart 2019-12-12 23:49:25 +01:00
parent 8c790e23b5
commit 0f5b01ef7c
3 changed files with 18 additions and 7 deletions

View file

@ -552,14 +552,14 @@ configuration: ## Section
mail: ## Section
## First you need to enable it.
#enable: true
enable: true
## Sender address used in mail sent by Diaspora.
#sender_address: 'no-reply@example.org'
sender_address: 'no-reply@{{ domain }}'
## This selects which mailer should be used. Use 'smtp' for a smtp
## connection or 'sendmail' to use the sendmail binary.
#method: 'smtp'
method: 'sendmail'
## Ignore if method isn't 'smtp'.
smtp: ## Section
@ -596,7 +596,7 @@ configuration: ## Section
sendmail: ## Section
## The path to the sendmail binary (default='/usr/sbin/sendmail')
#location: '/usr/sbin/sendmail'
location: '/usr/sbin/sendmail'
## Use exim and sendmail (default=false)
#exim_fix: false
@ -608,11 +608,10 @@ configuration: ## Section
## This doesn't make the user an admin but is used when a generic
## admin contact is needed, much like the postmaster role in mail
## systems. Set only the username, NOT the full ID.
#account: "podmaster"
account: "{{ admin }}"
## E-mail address to contact the administrator.
# TODO
#podmin_email: 'podmin@example.org'
podmin_email: '{{ admin_email }}'
## Settings related to relays
# TODO

View file

@ -51,6 +51,15 @@
"fr": "Est-ce un site public ?"
},
"default": true
},
{
"name": "admin",
"type": "user",
"ask": {
"en": "Choose the diaspora* administrator (must be an existing YunoHost user)",
"fr": "Choisissez l'administrateur de diaspora* (doit être un utilisateur YunoHost)"
},
"example": "johndoe"
}
]
}

View file

@ -31,6 +31,8 @@ ynh_abort_if_errors
domain=$YNH_APP_ARG_DOMAIN
path_url=$YNH_APP_ARG_PATH
is_public=$YNH_APP_ARG_IS_PUBLIC
admin=$YNH_APP_ARG_ADMIN
admin_email=$(ynh_user_get_info --username=$admin --key=mail)
# This is a multi-instance app, meaning it can be installed several times independently
@ -128,6 +130,7 @@ export domain
export path_url
export db_pass
export final_path
export admin
#=================================================
# CONFIGURE DIASPORA