- Generate Google Application Password:
Obtain a Google Application Password for secure authentication. You can generate one in your Google Account settings, especially if two-factor authentication is enabled. - Edit Gitea Configuration:
Use a text editor to modify the Gitea configuration file (/etc/gitea/app.ini). Add the following settings under the [mailer] section:
[mailer]
ENABLED = true
SMTP_ADDR = smtp.gmail.com
SMTP_PORT = 465
FROM = <google gmail account email address>
USER = <google gmail account email address>
PASSWD = <google app password here>
PROTOCOL = smtps
Adjust the values according to your Gmail account and the generated application password. - Restart Gitea:
Restart the Gitea service to apply the new configuration:
$ systemctl restart gitea - Test Email Configuration:
Access the Admin Settings screen in Gitea, and initiate a test email. This step ensures that the Gmail integration is functioning correctly.
By following these steps, you'll enable Gitea to use your Gmail account for sending email notifications and other communication. Ensure that the provided Gmail application password is secure and follows best practices for authentication.
No comments:
Post a Comment