Update sending_email.md (#512)
Some checks failed
Deploy CI - 12.0 / deploy (push) Has been cancelled

* Update sending_email.md

* Update sending_email.md
This commit is contained in:
Ranjiwei 2025-04-25 18:11:39 +08:00 committed by GitHub
parent fdc855e1c5
commit 36e8ebbd75
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -65,6 +65,28 @@ interval = 30m
```
## Add S/MIME signature to email
If you want the email signed by S/MIME, please add the config in `seahub_settings.py`
```python
ENABLE_SMIME = True
SMIME_CERTS_DIR = /opt/seafile/seahub-data/smime-certs # including cert.pem and private_key.pem
```
The certificate can be generated by the openssl command, or you can apply to the certificate manufacturer, it is up to you.
For example, generate the certs using the following command:
```
mkdir -p /opt/seafile/seahub-data/smime-certs
cd /opt/seafile/seahub-data/smime-certs
openssl req -x509 -newkey rsa:4096 -keyout private_key.pem -outform PEM -out cert.pem -days 3650 -nodes
```
!!! tip
Some email clients may not verify the email signed by certs generated by command line. So it's better to apply the certs from a manufacture
## Customize email messages
The simplest way to customize the email messages is setting the `SITE_NAME` variable in `seahub_settings.py`. If it is not enough for your case, you can customize the email templates.