sakai 学习社区

 找回密码
 立即注册

QQ登录

只需一步,快速开始

查看: 802|回复: 5

sakai发送邮件配置

[复制链接]

37

主题

64

帖子

656

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
656
发表于 2016-9-20 16:27:24 | 显示全部楼层 |阅读模式
1、说明
     版本:sakai11
     本贴只配置发送邮件。
     以163邮箱为例。

2、修改sakai.properties
  1. ## OUTGOING EMAIL
  2. # SMTP server for outgoing emails.
  3. smtp@org.sakaiproject.email.api.EmailService=smtp.163.com

  4. # SMTP port to connect to outgoing SMTP Server
  5. # DEFAULT: 25
  6. smtpPort@org.sakaiproject.email.api.EmailService=25

  7. # UserName to connect to SMTP server (Optional)
  8. smtpUser@org.sakaiproject.email.api.EmailService=your username

  9. # Password for connection to SMTP server (Optional)
  10. smtpPassword@org.sakaiproject.email.api.EmailService=your password

  11. # Use SSL/TLS to connect to the SMPT server
  12. # DEFAULT: false
  13. smtpUseSSL@org.sakaiproject.email.api.EmailService=true

  14. # Run in test mode - email will be written to the log rather than sent
  15. # NOTE: this will work even if no other settings have been set
  16. # DEFAULT: false
  17. # testMode@org.sakaiproject.email.api.EmailService=true

  18. # Show additional debugging information in the logs when email is being processed (sent or received)
  19. # Mostly should only use this if there are problems with the email processing and you are debugging.
  20. # DEFAULT: false
  21. #smtpDebug@org.sakaiproject.email.api.EmailService=true

  22. # Set the default from address for the Sakai email service
  23. # DEFAULT: postmaster@serverName
  24. smtpFrom@org.sakaiproject.email.api.EmailService=xxxxxx@163.com

  25. # Email address to send errors caught by the portal, and user bug reports in response.
  26. # DEFAULT: none (null)
  27. # portal.error.email=

  28. # Email address used as the "from" address for any email sent by any Sakai tool.
  29. # If the value is not set, the tools will use no-reply@${serverName} or postmaster@${serverName}
  30. # DEFAULT: none (null)
  31. setup.request=xxxxxx@163.com

  32. # Comma-separated list of domain names that are not allowed in guest accounts
  33. # This property is useful for preventing the accidental creation of guest accounts
  34. # for users (based on email address) that already have an external account (based on
  35. # username).  For instance, if this property is set to umich.edu, then a user
  36. # trying to add knoop@umich.edu to a site will receive an error, as there is an
  37. # expectation that a "knoop" user should already exist.
  38. # Example: umich.edu
  39. # DEFAULT: null (all domains are valid)
  40. # invalidEmailInIdAccountString=

  41. # Email notifications reply FROM preference
  42. # Set this to true to send notifications from the triggering user email addresses for announcements
  43. # instead of from a general server email address (no-reply@...)
  44. # OLD (deprecated) config value: emailFromReplyable@org.sakaiproject.event.api.NotificationService
  45. # DEFAULT: false (use the no-reply@... instead)
  46. notify.email.from.replyable = true

  47. # Email notifications reply TO preference
  48. # Set this to true to send notifications with the to field set to a user email instead of a general server email address
  49. # OLD (deprecated) config value: emailToReplyable@org.sakaiproject.event.api.NotificationService
  50. # DEFAULT: false (use the server address instead of the user)
  51. notify.email.to.replyable = true

  52. # DEFAULT: postmaster
  53. # mail.prohibitedaliases.count=1
  54. # mail.prohibitedaliases.1=postmaster
  55. # ALTERNATELY: a list of comma separated list of aliases
  56. # mail.prohibitedaliases=postmaster, adminuser

  57. # Connection timeout for SMTP server. Not set by default
  58. # DEFAULT: none (null)
  59. # mail.smtp.connectiontimeout=

  60. # Timeout for SMTP server. Not set by default
  61. # DEFAULT: none (null)
  62. # mail.smtp.timeout=

  63. # Replacing From addresses in email
  64. # Major mail providers are starting to use DMARC, to demand that all mail From addresses from their domain
  65. # must be signed. Since we can't sign messages for another mail service, this means that email passed through
  66. # the archiver or generated by Mailtool / Messages will fail the test, and be rejected.
  67. # By default we now replace From addresses with postmaster@site, and move the original From address to
  68. # Reply-To. These properties control that behavior.
  69. #
  70. # Should we replace the From address? true|false
  71. # Can also be an email address. If not specified the new from address is postmaster@site.
  72. # Example: mailagent@sakai.myinstitution.edu
  73. # false if you don't want any replacement
  74. # DEFAULT: true
  75. mail.sendfromsakai=false

  76. # Should we have exceptions for the replacement? Any from address matching this Java regular expression
  77. # will be retained unmodified. You might want to include addresses within your own institution, since
  78. # they shouldn't cause any trouble unless your own institution is using DMAEC.
  79. # Note that mail addresses using your Sakai instance's server name will always be exceptions
  80. # DEFAULT: missing, no exceptions
  81. #mail.sendfromsakai.exceptions=.*[@.]institution\\.edu

  82. # When replacing the From address, what text should we use. {} will be
  83. # replaced with the original From address, e.g. John Smith (jsmith@site.edu)
  84. # DEFAULT: {}
  85. #mail.sendfromsakai.fromtext=On behalf of {}

  86. # The number of messages above which searching is disabled
  87. # DEFAULT: 2500
  88. # sakai.mailbox.search-threshold=

  89. # DEFAULT: true
  90. # mail.*.sendpartial=false
复制代码


3、验证
到任意站点的“站点信息”中,添加站点成员。测试发送邮件是否能成功。

回复

使用道具 举报

0

主题

7

帖子

88

积分

注册会员

Rank: 2

积分
88
发表于 2016-9-20 21:01:54 | 显示全部楼层
smtp@org.sakaiproject.email.api.EmailService=smtp.163.com
smtpPort@org.sakaiproject.email.api.EmailService=25
smtpUser@org.sakaiproject.email.api.EmailService=<xxxx@163.com>
smtpPassword@org.sakaiproject.email.api.EmailService=<aaaa>
smtpUseSSL@org.sakaiproject.email.api.EmailService=false
smtpFrom@org.sakaiproject.email.api.EmailService=xxxx@163.com
setup.request=xxxx@163.com
notify.email.from.replyable = true
notify.email.to.replyable = true
mail.sendfromsakai=false
其中ssl的设置为true或false均不行,用户名和密码位置加<>和不加也不行,请指点下!
回复 支持 反对

使用道具 举报

37

主题

64

帖子

656

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
656
 楼主| 发表于 2016-9-21 15:00:01 | 显示全部楼层
smtpUser 不需要带@163.com, 只写前面的xxxx。并且不需要<>
回复 支持 反对

使用道具 举报

37

主题

64

帖子

656

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
656
 楼主| 发表于 2016-12-27 13:12:07 | 显示全部楼层
类似于:
smtp@org.sakaiproject.email.api.EmailService=smtp.163.com
smtpPort@org.sakaiproject.email.api.EmailService=25
smtpUser@org.sakaiproject.email.api.EmailService=yushanyuan
smtpPassword@org.sakaiproject.email.api.EmailService=emailpasswd
smtpUseSSL@org.sakaiproject.email.api.EmailService=false
smtpFrom@org.sakaiproject.email.api.EmailService=yushanyuan@163.com
setup.request=yushanyuan@163.com
notify.email.from.replyable = true
notify.email.to.replyable = true
mail.sendfromsakai=false
回复 支持 反对

使用道具 举报

1

主题

6

帖子

47

积分

新手上路

Rank: 1

积分
47
发表于 2017-3-31 09:05:12 | 显示全部楼层
请问您可以介绍一下sakai10是如何配置的吗?
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|手机版|小黑屋|sakai 社区  

GMT+8, 2017-7-24 18:26 , Processed in 0.032704 second(s), 15 queries , Apc On.

Powered by Discuz! X3.2

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表