插件 » Redmine Email Fetcher 把邮件提取到Redmine(Redmine 4.*兼容版)
基本介绍
作者: | redmineplugins.cn Admin | |
---|---|---|
主页: | https://github.com/luismaia/redmine_email_fetcher | |
版本库: | https://github.com/luismaia/redmine_email_fetcher | |
创建于: | 2020-04-12 | |
当前版本: | 0.3.1 | |
兼容性: | 4.1.*, 4.0.*, 3.4.*, 3.3.*, 3.2.*, 3.1.*, 3.0.*, 2.6.*, 2.5.*, 2.4.*, 2.3.*, 2.2.*, 2.1.* |
Redmine Email Fetcher插件是对 “Redmine Receiving emails"功能的图形化扩展,简化邮件提取功能的配置。支持同时定义多个邮件账号,定期按规则收取邮件并写入Redmine。
具体功能:
- 保存IMAP 和 POP3 邮件账户配置
- 将邮件账号与特定项目绑定,支持issue的跟踪标签(tracker)、分类(categories) 、优先级(priority)等属性
- 支持手动邮件账户测试和手动提取邮件
- 支持计划任务按预制的邮件配置提取所有邮件并写人redmine
安装指导
插件安装
- 解压并拷贝整个插件目录到Redmine的plugins目录下。 确保插件目录名为redmine_email_fetcher。
- 在redmine的目录下执行如下命令,完成插件必要的gems安装和插件数据库迁移
bundle install RAILS_ENV=production bundle exec rake redmine:plugins:migrate
- 重新启动Redmine
如果插件安装成功,在Redmine的 管理→插件 里可以看到所列出的 Redmine Email Fetcher插件。同时在管理界面中新增Fetch emails子菜单,用于邮件提取的详细参数设置。
插件安装后为Redmine新增一个task,指令如下
rake -T redmine:plugins:email_fetcher RAILS_ENV=production
插件卸载
- 在Redmine目录下执行
RAILS_ENV=production rake redmine:plugins:migrate NAME=redmine_email_fetcher VERSION=0
- 删除插件文件夹
- 重新启动redmine
配置方法
- 邮件配置属性
- Configuration type 邮件账户配置类型
- IMAP
- POP3
- Is configuration active? 定义邮件账户是否激活或是否应该同步
- True ,Task fetch_all_emails 表示任务该同步所有邮件
- False,Task fetch_all_emails 表示忽略邮件
- Last successful fetch at (只读)显示最后一次邮件同步到redmine的时间
- Configuration type 邮件账户配置类型
- Email Attributes 邮件属性
- Host - The IMAP or POP3 server host (e.g. 127.0.0.1).
- Port - The IMAP or POP3 server port. Eg., 993.
- SSL - SSL usage? (Default: True) [Options: True, False]
- Username - The IMAP or POP3 email account username (e.g. it@domain.com).
- Password - The IMAP or POP3 email account password.
- Folder name - The email folder name from where the emails should be fetched:
- IMAP - Any folder name is possible, but the test function will validate that this folder is reachable after login) (e.g. REDMINE).
- POP3 - Since this is an old protocol, only the INBOX folder is allowed (in fact you can’t change this option)
- On success move to folder (IMAP only) - (optional) This IMAP attribute allows configuration of where successfully received emails should be moved to, instead of deleting them (e.g. ARCHIVE).
- On failure move to folder (IMAP only) - (optional) This IMAP attribute allows configuration of where ignored emails should be moved (e.g. IGNORED).
- Use APOP? (POP3 only) - This POP3 attribute allows specifying if APOP authentication should be used (default: false).
- On failure delete email (POP3 only) - This POP3 attribute allows specifying whether emails which could not be processed successfully are deleted from the server
(default: false - default behaviour is to leave them on the server).
- Unknown Sender Actions (in Redmine):
- Method for unknown users - How to handle emails from an unknown user where ACTION can be one of the following values:
- accept - the sender is considered as an anonymous user and the email is accepted (default). If you choose this option you must activate the Custom field owner-email, where the sender email address will be stored. Without this field activated, the email fetch will fail, since this information is required to send information back to the sender (the Redmine Helpdesk plugin may be a nice addition).
- ignore - The email is ignored.
- create - A user account is created for the sender (username/password are sent back to the user) and the email is accepted.
- Use no_account_notice - Suppressing account generation notification (default False).
- Use no_permission_check - Disable permission checking when receiving the email (default True).
- Default group for new reporters - (optional) Automatically adding new users to some group(s) (e.g. group1,group2).
- Method for unknown users - How to handle emails from an unknown user where ACTION can be one of the following values:
- Default Issue creation (in Redmine) Attributes:
- Tracker - Target tracker (in case no tracker is specified in email content).
- Category name - (optional) Name of the default category (in case no category is specified in email content).
- Priority name - (optional) Name of the default priority (in case no priority is specified in email content).
- allow_override - (optional) Allow email content to override attributes specified by previous options ATTRS is a comma separated list of attributes (e.g. project,tracker,category,priority).
- Project - Target default project (in case no project is specified in email content).
更多参数详细解释请参考Redmine官方wiki页面 RedmineReceivingEmails
利用Rake tasks制定计划任务
- Redmine Email Fetcher的有效任务:
# rake -T redmine:plugins:email_fetcher rake redmine:plugins:email_fetcher:fetch_all_emails # Fetch all active email accounts emails to Redmine
- This task can be used for periodic synchronization. For example:
# fetch all active email accounts emails to Redmine @ every 5 minutes */5 * * * * www-data /usr/bin/rake -f /opt/redmine/Rakefile --silent redmine:plugins:email_fetcher:fetch_all_emails RAILS_ENV=production 2>&- 1>&-
- The tasks recognize three environment variables:
- DRY_RUN - Performs a run without changing the database.
- LOG_LEVEL - Controls the rake task verbosity. The possible values are:
- silent: Nothing is written to the output.
- error: Only errors are written to the output.
- change: Only writes errors and changes made to the user/group’s base.
- debug: Detailed information about the execution is visible to help identify errors. This is the default value.
版本更新
积分(10)
0.3.1 (2020-04-12)
兼容性: Redmine 2.1.*, 2.2.*, 2.3.*, 2.4.*, 2.5.*, 2.6.*, 3.0.*, 3.1.*, 3.2.*, 3.3.*, 3.4.*, 4.0.*, 4.1.*
- 修复作者原版插件不支持Redmine4.*的问题
- 修复email fetcher图标错位的问题
文件
redmine_email_fetcher-0.3.1.zip (51.3 KB)
没有任何数据可供显示
问题
# | 跟踪 | 状态 | 作者 | 主题 | 更新于 |
---|---|---|---|---|---|
84 | 报错 | 已解决 | out man | 关于crontab定时任务中执行sh脚本不执行,但手工运行正常的问题解决 | 2020-07-13 22:13 |
231 | 咨询 | 已解决 | Jiang Bin | redmine windows 版本貌似不能获取邮件,NameError (uninitialized constant Redmine::IMAP) | 2021-07-28 09:24 |
553 | 报错 | 待反馈 | tang xiaocan | 安装报错 | 2023-08-25 17:31 |
评论
添加评论