mirror of
https://github.com/YunoHost-Apps/pyinventory_ynh.git
synced 2024-09-03 20:16:09 +02:00
Merge pull request #57 from YunoHost-Apps/testing
Add info about emails into README
This commit is contained in:
commit
ad51260980
1 changed files with 29 additions and 1 deletions
30
README.md
30
README.md
|
@ -22,7 +22,35 @@ Pull requests welcome ;)
|
||||||
## Settings and upgrades
|
## Settings and upgrades
|
||||||
|
|
||||||
Almost everything related to PyInventory's configuration is handled in a `"../conf/settings.py"` file.
|
Almost everything related to PyInventory's configuration is handled in a `"../conf/settings.py"` file.
|
||||||
You can edit the file `$final_path/local_settings.py` to enable or disable features.
|
You can edit the file `/opt/yunohost/pyinventory/local_settings.py` to enable or disable features.
|
||||||
|
|
||||||
|
Test sending emails:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
ssh admin@yourdomain.tld
|
||||||
|
root@yunohost:~# cd /opt/yunohost/pyinventory/
|
||||||
|
root@yunohost:/opt/yunohost/pyinventory# source venv/bin/activate
|
||||||
|
(venv) root@yunohost:/opt/yunohost/pyinventory# ./manage.py sendtestemail --admins
|
||||||
|
```
|
||||||
|
|
||||||
|
Background info: Error mails are send to all [settings.ADMINS](https://docs.djangoproject.com/en/2.2/ref/settings/#std:setting-ADMINS). By default the YunoHost admin is inserted here.
|
||||||
|
To check current ADMINS run:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
(venv) root@yunohost:/opt/yunohost/pyinventory# ./manage.py sendtestemail --admins
|
||||||
|
```
|
||||||
|
|
||||||
|
If you prefere to send error emails to a extrnal email address, just do something like this:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
echo "ADMINS = (('Your Name', 'example@domain.tld'),)" >> /opt/yunohost/pyinventory/local_settings.py
|
||||||
|
```
|
||||||
|
|
||||||
|
To check the effective settings, run this:
|
||||||
|
```bash
|
||||||
|
(venv) root@yunohost:/opt/yunohost/pyinventory# ./manage.py diffsettings
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
# Miscellaneous
|
# Miscellaneous
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue