メールから課題およびコメントを作成する
JIRAはメールサーバー、または外部メールサービスによって受信された着信メッセージに基づいて、新しい課題の作成や、既存の課題についてのコメントを作成するように構成することができます。
This is especially useful in a helpdesk or support scenario, where users send support queries via email that you wish to track with JIRA. Subsequent email messages about the issue (for example, responses to Email Notifications) can be automatically recorded as comments. Additionally, any attachments in the emails can automatically be attached to the issue (with appropriate configuration).
メールから課題やコメント作成を行う設定をする
ステップ1:メールサーバー/サービスを設定する
POP または IMAP メール メッセージ
To set up issue and comment creation from email, you will need to create a mail account for a POP or IMAP mail server that JIRA can access – typically, one mail account for each JIRA project. For example, for the 'ABC' project, you might establish an account abc-issues@example.com
JIRA will periodically scan for new email messages received by your mail account (via a service) and appropriately create issues or comments for any emails it finds (via a mail handler).
Jira のメール ハンドラーは任意で新しい送信者に対して新しいユーザー アカウントを作成することができます。詳細については、「新しい課題を作成または既存の課題にコメントを追加する」セクションを参照してください。
注 — JIRA がメール サーバ/サービスでメッセージをハンドリングする方法:
- メールアカウントの場合、JIRAは、メールアカウントの[受信トレイ]フォルダで受信した電子メールメッセージをスキャンします。しかし、IMAPメール・サーバーでは、メールアカウント内の別のフォルダを指定することができます。
- JIRAが正常にメッセージを処理する場合、JIRAはメールアカウントからのメッセージ(POPまたはIMAPメールサーバー上の)やファイルシステムからのメッセージ(ファイル・システム・メッセージ用)を削除します。
- JIRAが正常にメッセージを処理しない場合、メッセージはメールアカウントまたはファイル・システム上のいずれかのままになります。
ステップ2:メールハンドラーを設定する
メールサーバー/サービスからのメッセージを受信するようにJIRAを設定したら、「メール・ハンドラ 'を介してこれらのメッセージを処理するようにJIRAを設定します。
To configure a JIRA mail handler:
- Log in as a user with the JIRA Administrators global permission.
- Choose > System. Select Mail > Incoming Mail to open the Incoming Mail page.
Keyboard shortcut: g + g + start typing incoming mail
- [メール ハンドラー] セクションで [受信メール ハンドラの追加] をクリック (または既存のメール ハンドラーの横の [編集] リンクをクリック) して、[メール ハンドラー] ダイアログ ボックスを開きます。
- 名前を特定します。メールハンドラーの名前は、メールハンドラーが何をするか、説明します。例えば、「IMAPメールサーバからの課題作成やコメント」 です。
- メールサーバー(上記のステップ1で設定した) を選択します。これは、POPまたはIMAPメールサーバーまたは、ファイル・システムにメッセージを書き込む、外部メールサービスのローカルファイル オプションがあります。
- メールハンドラの実行時間の間(分単位)の 遅延を設定します。前のステップで指定した、サーバをスキャンするJIRAの頻度を効果的に定義します。
- この課題 ドロップダウン リスト から、メールハンドラーのタイプを選択します。詳細については、以下の「メールハンドラー」セクションを参照してください。
- IMAPメールサーバまたはサーバフィールド内の、ローカルファイルオプションのいずれかを選択した場合フォルダ名フィールドが ハンドラー ドロップダウンリストの下に表示されます:
- IMAPメールサーバーでは、メールハンドラーにメールアカウントの「受信トレイ」以外のフォルダから新しいメッセージをスキャンさせたい場合は、そのフォルダの名前を指定します。
- For the Local Files option, if your file messages are being written to a subdirectory within the
import/mail
subdirectory of the JIRA Home Directory, specify the subdirectory structure (withinimport/mail
) here.
- Click Next to continue with specifying the remaining options specific to mail Handler you selected above. For more information, refer to the Mail Handlers section below.
- (Optional) Click the Test button to test your mail handler. If you are using Local Files as the server, copy a saved email that contains a "Subject: " line to the configured directory. JIRA will remove this file after it is parsed, or log a message about why an issue could not be created. You may have to specify the project, issuetype and reporterusername properties as a minimum configuration.
A sample email file might look like this:To: jira@example.com
From: some-jira-user@example.com
Subject: (TEST-123) issue summary title here
Body of the email goes here
- Add / Save ボタンをクリックしてメールハンドラー設定を保存します。
注 - JIRAのメールハンドラーとサービス間の関係:
メール ハンドラ
JIRAには、次の既定のメールハンドラが用意されています。
JIRA Service Desk uses a built-in email processor to manage incoming emails in service desk projects. It's purpose-built for service desk projects and works differently from JIRA mail handlers. Issues created via JIRA email handlers don't show up as service desk customer requests. For this reason, we don't recommend using a JIRA mail handler for service desk projects.
メールハンドラーでJIRAの課題とコメントを作成する方法の詳細については、課題/コメントの作成 を参照してください。 (以下参照)
また、以下のヒントも参照してください。メールハンドラーの利用の秘訣 ー JIRAで電子メールメッセージの以下のタイプを処理可能にするためのメールハンドラーの微調整のヒントについて
- JIRAユーザーアカウントなしで送られてきたメール
新規課題の作成または既存の課題にコメントの追加
このメッセージハンドラは、新規で課題を作成、または既存の課題にコメントを追加します。件名に課題キーが含まれている場合、メッセージはその問題にコメントとして追加されます。課題キーが見つからない場合は、新規課題としてデフォルトプロジェクトに作成されます。
新規の課題作成、または既存の課題にコメントを追加する設定にする場合のメールハンドラー;
- メール ハンドラーの設定を開始していない場合は、開始します (上記)。
新規課題を作成または既存の課題にコメントを追加ダイアログ ボックスで、次のフィールド/オプションを入力します。
プロジェクト このハンドラーが新しい課題を作成した際の既定のプロジェクトのプロジェクト キーを指定します (
JRA
など)。注意:
- このフィールドは課題の作成にのみ関連するもので、課題のコメントには関係しません。
- メール メッセージの件名行に課題キーが含まれ、その課題キーが Jira インストール内に存在する場合、ハンドラーは課題が格納されているプロジェクトにかかわらず、メール メッセージのコンテンツを課題のコメントとして追加します。
課題タイプ 新しい課題の既定の課題タイプを選択します。 引用を取り除く Select this check box to remove quoted text from from an email message's body (e.g. from previous email replies) before the body's content is added to the JIRA issue's comment.
If you find this feature is not working correctly, you can use the workaround explained here:
JRASERVER-28444 - "Add a comment from a non quoted email body" does not set the Strip Quotes to be TRUE Closed
メール アドレスのキャッチ
指定した場合、"To:"、"Cc:"、"Bcc:" 行にこのフィールドで指定した受信者を含むメール メッセージのみが処理されます。例:
issues@mycompany.com
Upon specifying an address here, all email messages whose To:, Cc:, Bcc: lines contain addresses other than the Catch Email Address are ignored. This is useful if you have multiple aliases for the same mail account (e.g.
foo-support@example-co.com
andbar-support@example-co.com
aliases forsupport@example-co.com
) for multiple mail services (e.g. each one to create issues in separate JIRA projects).注: 実践では、 このオプションが訳に立つことはあまりないため、 より一般的な既定の報告者と混同しないでください。メールハンドラごとに 1 つのキャッチ電子メールアドレスと 1 つの課題のみを指定できます。
In addition, there is a known bug in JIRA 6.4 to JIRA 7.0.1, which means that multiple email handlers that are used to create issues in different projects when an email is sent to multiple aliases will not process the email correctly. This has been fixed in JIRA 7.0.2. For more information, see
JRASERVER-41831 - Duplicate issues creation fails - Creating multiple issues by one Email Closed .
一括 このオプションは、ヘッダーで優先順位フィールドが一括に設定されている、または自動送信フィールドがnoに設定されている「一括」電子メールメッセージにのみ影響します。これらのメッセージは一般的時に同サービスによって送信されます。これらの電子メールメッセージを受信すると、選択したオプションに応じて次の操作が実行されます。
- メールを無視して、何もしない。
- メールを転送する (メールの転送テキスト フィールドで設定されたアドレスへの転送など)。
- メールを完全に削除する。
一般的に、bulk=forward と転送メール アドレスを設定することは、ループを防ぐため (例: 別の Jira インストール) に有用です。
メール転送 これを指定し、このメールサービスが受信した電子メールメッセージを処理できない場合、この問題を示す電子メールメッセージはこのフィールドで指定した電子メールアドレスに転送されます。
ユーザーの作成 Select this check box if you want JIRA to create new user accounts from any received email messages whose From: field contains an address that does not match one associated with an existing JIRA user account. This allows the creator of the email message to be notified of subsequent updates to the issue, which can be achieved by configuring the relevant project's notification scheme to notify the Reporter of updates.
これらの新しく作成された Jira ユーザー アカウントのユーザ名とメール アドレスは、受信メッセージの From: フィールドで指定されるメール アドレスになります。新しい Jira ユーザーのパスワードはランダムに生成され、Jira のユーザー アカウントについて通知するメールがアドレスに送信されます。
Users created this way will be added to the 'jira-users' group and given application access to JIRA (and therefore take up a license).
Note: this option is not compatible with Default Reporter field option below and as such, choosing the Create Users option will hide the Default Reporter option.
既定の報告者 Specify the username of a default reporter, which will be used if the email address in the From: field of any received messages does not match the address associated with that of an existing JIRA user — for example, a JIRA username such as
emailed-reporter
注意:
- This option is not available if the Create Users check box is selected.
- Please ensure that the user specified in this field has the Create I ssues project permission for the relevant Project (specified above) as well as the Create Comments project permission for the other relevant projects to which this mail handler should add comments.
- 課題を作成してこのオプションを指定すると、送信者を特定できるよう、メール メッセージの From: フィールド アドレスは課題の説明フィールドの末尾に短いメッセージとして追加されます。
ユーザーの通知 上記の「ユーザーの作成」オプションでアカウントを作成したユーザーに、JIRA が通知する電子メールメッセージを送信しないよう設定する場合は、このチェックボックスをオフにします。
注: このオプションは、「ユーザーの作成」チェックボックスがオンになっている場合にのみ機能します。
CC 担当者 Select this check box if you want JIRA to automatically assign the issue created to a JIRA user:
- Who's email address (registered with their JIRA account) matches the first matching address encountered in the To:, then Cc: and then Bcc: field of the email message received.
- 関連するプロジェクトで割り当て可能なユーザー プロジェクト権限も持っているユーザー (上記で指定)。
CC ウォッチャー Select this check box if you want JIRA to automatically add JIRA users to the issue created, where those users' email addresses (registered with their JIRA accounts) match addresses encountered in the To:, Cc: or Bcc: fields of the email message received.
Please note that when an issue is created, new JIRA users created by the Create Users option (above) cannot also be added to the issue's watchers list by this CC Watchers option. JIRA users must already exist in JIRA's userbase, and must have an email address.
- メール ハンドラーのテストと保存 (上記)。
引用符なしのメール本文からコメントを追加する
このメッセージ ハンドラーはコメントを作成しますが、メール メッセージ本文の非引用部分のみを使用します。引用行とは、「>」や「|」記号で開始する行です。これらのテキスト行はコメントには追加されません。コメントが追加される課題は、メールの件名にある最初の課題キーから選択されます。コメントの作成者はメール メッセージの From: フィールドのアドレスから取得されます。
「メールの非引用本文からコメントを追加する」メール ハンドラーを設定するには:
- メール ハンドラーの設定を開始していない場合は、開始します (上記)。
メール本文の非引用部分からコメントを追加するダイアログ ボックスで、次のフィールド/オプションを入力します。
メール アドレスのキャッチ 指定した場合、"To:"、"Cc:"、"Bcc:" 行にこのフィールドで指定した受信者を含むメール メッセージのみが処理されます。例: issues@mycompany.com
Upon specifying an address here, all email messages whose To:, Cc:, Bcc: lines contain addresses other than the Catch Email Address are ignored. This is useful if you have multiple aliases for the same mail account (e.g.
foo-support@example-co.com
andbar-support@example-co.com
aliases forsupport@example-co.com
) for multiple mail services (e.g. each one to create issues in separate JIRA projects).注: 実際の本番環境では、このオプションはあまり使われません。より一般的な既定の報告者と混同しないようにしてください。メール ハンドラーごとに、キャッチする 1 つのメール アドレスと 1 つの課題タイプのみを指定できます。
一括 このオプションは、ヘッダーで優先順位フィールドが一括に設定されている、または自動送信フィールドがnoに設定されている「一括」電子メールメッセージにのみ影響します。これらのメッセージは一般的時に同サービスによって送信されます。これらの電子メールメッセージを受信すると、選択したオプションに応じて次の操作が実行されます。
- メールを無視して、何もしない。
- メールを転送する (メールの転送テキスト フィールドで設定されたアドレスへの転送など)。
- メールを完全に削除する。
メール転送 これを指定し、このメールサービスが受信した電子メールメッセージを処理できない場合、この問題を示す電子メールメッセージはこのフィールドで指定した電子メールアドレスに転送されます。
ユーザーの作成 Select this check box if you want JIRA to create new user accounts from any received email messages whose From: field contains an address that does not match one associated with an existing JIRA user account. This allows the creator of the email message to be notified of subsequent updates to the issue, which can be achieved by configuring the relevant project's notification scheme to notify the Reporter of updates.
新しく作成した JIRA ユーザアカウントのこれらのユーザ名とメールアドレスは、メッセージの送信者:フィールドで指定したメールアドレスになります。新しいユーザのパスワードはランダムに生成され、JIRA のアカウントについて知らせるメールが新しいユーザに送信されます。
Users created this way will be added to the 'jira-users' group and given application access to JIRA (and therefore take up a license).
Note: this option is not compatible with Default Reporter field option below and as such, choosing the Create Users option will hide the Default Reporter option.
既定の報告者 Specify the username of a default reporter, which will be used if the email address in the From: field of any received messages does not match the address associated with that of an existing JIRA user — for example, a JIRA username such as
emailed-reporter
注意:
- This option is not available if the Create Users check box is selected.
- このフィールドで指定したユーザーに、関連するプロジェクトの課題の作成プロジェクト権限 (上記で指定)、およびメール ハンドラーがコメントを追加する他の関連プロジェクトのコメントの作成プロジェクト権限があることを確認してください。
ユーザーの通知 上記の「ユーザーの作成」オプションでアカウントを作成したユーザーに、JIRA が通知する電子メールメッセージを送信しないよう設定する場合は、このチェックボックスをオフにします。
注: このオプションは、「ユーザーの作成」チェックボックスがオンになっている場合にのみ機能します。
メール ハンドラーのテストと保存 (上記)。
メール本文全体でコメントを追加する
このメッセージ ハンドラーは、受信したメール メッセージの本文全体をもとにコメントを作成します。コメントが追加される課題は、メールの件名で見つかった最初の課題キーから選択されます。コメントの作成者はメール メッセージの From: フィールドのアドレスから取得されます。
「メール本文を使用してコメントを追加する」ようにメール ハンドラーを設定するには:
- メール ハンドラーの設定を開始していない場合は、開始します (上記)。
メールの本文全体を使用してコメントを追加するダイアログ ボックスで、次のフィールド/オプションを入力します。
メール アドレスのキャッチ 指定した場合、"To:"、"Cc:"、"Bcc:" 行にこのフィールドで指定した受信者を含むメール メッセージのみが処理されます。例: issues@mycompany.com
Upon specifying an address here, all email messages whose To:, Cc:, Bcc: lines contain addresses other than the Catch Email Address are ignored. This is useful if you have multiple aliases for the same mail account (e.g.
foo-support@example-co.com
andbar-support@example-co.com
aliases forsupport@example-co.com
) for multiple mail services (e.g. each one to create issues in separate JIRA projects).注: 実際の本番環境では、このオプションはあまり使われません。より一般的な既定の報告者と混同しないようにしてください。メール ハンドラーごとに、キャッチする 1 つのメール アドレスと 1 つの課題タイプのみを指定できます。
一括 このオプションは、ヘッダーで優先順位フィールドが一括に設定されている、または自動送信フィールドがnoに設定されている「一括」電子メールメッセージにのみ影響します。これらのメッセージは一般的時に同サービスによって送信されます。これらの電子メールメッセージを受信すると、選択したオプションに応じて次の操作が実行されます。
- メールを無視して、何もしない。
- メールを転送する (メールの転送テキスト フィールドで設定されたアドレスへの転送など)。
- メールを完全に削除する。
メール転送 これを指定し、このメールサービスが受信した電子メールメッセージを処理できない場合、この問題を示す電子メールメッセージはこのフィールドで指定した電子メールアドレスに転送されます。
ユーザーの作成 Select this check box if you want JIRA to create new user accounts from any received email messages whose From: field contains an address that does not match one associated with an existing JIRA user account. This allows the creator of the email message to be notified of subsequent updates to the issue, which can be achieved by configuring the relevant project's notification scheme to notify the Reporter of updates.
新しく作成した JIRA ユーザアカウントのこれらのユーザ名とメールアドレスは、メッセージの送信者:フィールドで指定したメールアドレスになります。新しいユーザのパスワードはランダムに生成され、JIRA のアカウントについて知らせるメールが新しいユーザに送信されます。
Users created this way will be added to the 'jira-users' group and given application access to JIRA (and therefore take up a license).
Note: this option is not compatible with Default Reporter field option below and as such, choosing the Create Users option will hide the Default Reporter option.
既定の報告者 Specify the username of a default reporter, which will be used if the email address in the From: field of any received messages does not match the address associated with that of an existing JIRA user — for example, a JIRA username such as
emailed-reporter
注意:
- This option is not available if the Create Users check box is selected.
- このフィールドで指定したユーザーに、関連するプロジェクトの課題の作成プロジェクト権限 (上記で指定)、およびメール ハンドラーがコメントを追加する他の関連プロジェクトのコメントの作成プロジェクト権限があることを確認してください。
ユーザーの通知 上記の「ユーザーの作成」オプションでアカウントを作成したユーザーに、JIRA が通知する電子メールメッセージを送信しないよう設定する場合は、このチェックボックスをオフにします。
注: このオプションは、「ユーザーの作成」チェックボックスがオンになっている場合にのみ機能します。
- メール ハンドラーのテストと保存 (上記)。
各メールのメッセージから新規課題の作成
このメッセージ ハンドラーは、受信したメッセージごとに新しい課題を作成します。
「各メール メッセージから新しい課題を作成する」ようにメール ハンドラーを設定するには:
- メール ハンドラーの設定を開始していない場合は、開始します (上記)。
「各メール メッセージから新規課題を作成する」ダイアログ ボックスで、次のフィールド/オプションを入力します。
プロジェクト このハンドラーが新しい課題を作成した際の既定のプロジェクトのプロジェクト キーを指定します (
JRA
など)。注意:
- このフィールドは課題の作成にのみ関連するもので、課題のコメントには関係しません。
- メール メッセージの件名行に課題キーが含まれ、その課題キーが Jira インストール内に存在する場合、ハンドラーは課題が格納されているプロジェクトにかかわらず、メール メッセージのコンテンツを課題のコメントとして追加します。
課題タイプ 新しい課題の既定の課題タイプを選択します。 メール アドレスのキャッチ
指定した場合、"To:"、"Cc:"、"Bcc:" 行にこのフィールドで指定した受信者を含むメール メッセージのみが処理されます。例:
issues@mycompany.com
Upon specifying an address here, all email messages whose To:, Cc:, Bcc: lines contain addresses other than the Catch Email Address are ignored. This is useful if you have multiple aliases for the same mail account (e.g.
foo-support@example-co.com
andbar-support@example-co.com
aliases forsupport@example-co.com
) for multiple mail services (e.g. each one to create issues in separate JIRA projects).注: 実際の本番環境では、このオプションはあまり使われません。より一般的な既定の報告者と混同しないようにしてください。メール ハンドラーごとに、キャッチする 1 つのメール アドレスと 1 つの課題タイプのみを指定できます。
一括 このオプションは、ヘッダーで優先順位フィールドが一括に設定されている、または自動送信フィールドがnoに設定されている「一括」電子メールメッセージにのみ影響します。これらのメッセージは一般的時に同サービスによって送信されます。これらの電子メールメッセージを受信すると、選択したオプションに応じて次の操作が実行されます。
- メールを無視して、何もしない。
- メールを転送する (メールの転送テキスト フィールドで設定されたアドレスへの転送など)。
- メールを完全に削除する。
メール転送 これを指定し、このメールサービスが受信した電子メールメッセージを処理できない場合、この問題を示す電子メールメッセージはこのフィールドで指定した電子メールアドレスに転送されます。
ユーザーの作成 Select this check box if you want JIRA to create new user accounts from any received email messages whose From: field contains an address that does not match one associated with an existing JIRA user account. This allows the creator of the email message to be notified of subsequent updates to the issue, which can be achieved by configuring the relevant project's notification scheme to notify the Reporter of updates.
新しく作成した JIRA ユーザアカウントのこれらのユーザ名とメールアドレスは、メッセージの送信者:フィールドで指定したメールアドレスになります。新しいユーザのパスワードはランダムに生成され、JIRA のアカウントについて知らせるメールが新しいユーザに送信されます。
Users created this way will be added to the 'jira-users' group and given application access to JIRA (and therefore take up a license).
Note: this option is not compatible with Default Reporter field option below and as such, choosing the Create Users option will hide the Default Reporter option.
既定の報告者 Specify the username of a default reporter, which will be used if the email address in the From: field of any received messages does not match the address associated with that of an existing JIRA user — for example, a JIRA username such as
emailed-reporter
注意:
- This option is not available if the Create Users check box is selected.
- このフィールドで指定したユーザーに、関連するプロジェクトの課題の作成プロジェクト権限 (上記で指定)、およびメール ハンドラーがコメントを追加する他の関連プロジェクトのコメントの作成プロジェクト権限があることを確認してください。
- 課題を作成してこのオプションを指定すると、送信者を特定できるよう、メール メッセージの From: フィールド アドレスは課題の説明フィールドの末尾に短いメッセージとして追加されます。
ユーザーの通知 上記の「ユーザーの作成」オプションでアカウントを作成したユーザーに、JIRA が通知する電子メールメッセージを送信しないよう設定する場合は、このチェックボックスをオフにします。
注: このオプションは、「ユーザーの作成」チェックボックスがオンになっている場合にのみ機能します。
CC 担当者 Select this check box if you want JIRA to automatically assign the issue created to a JIRA user:
- Who's email address (registered with their JIRA account) matches the first matching address encountered in the To: , then Cc: and then Bcc: field of the email message received.
- 関連するプロジェクトで割り当て可能なユーザー プロジェクト権限も持っているユーザー (上記で指定)。
CC ウォッチャー Select this check box if you want JIRA to automatically add JIRA users to the issue created, where those users' email addresses (registered with their JIRA accounts) match addresses encountered in the To:, Cc: or Bcc: fields of the email message received.
Please note that when an issue is created, new JIRA users created by the Create Users option (above) cannot also be added to the issue's watchers list by this CC Watchers option. JIRA users must already exist in JIRA's userbase, and must have an email address.
- メール ハンドラーのテストと保存 (上記)。
メール本文の指定したマーカーまたはセパレーターの前にコメントを追加する
このメッセージ ハンドラーは、メール メッセージの本文からコメントを作成しますが、指定の正規表現 (regex) と一致するマーカーまたは区切り記号以降の本文をすべて無視します。
Lotus Notes や Outlook などのメール システムの場合、メール メッセージのコア コンテンツは、"---- Original Message ----
" や "Extranet\n email.address/DOM/REG/CONT/CORP@CORPMAIL
" などの決まった文字列で、本文内にある他のコンテンツ (返信済や転送済など) と互いに区切られます。そのため、有効な regex を取得できるこのメッセージ ハンドラーを使用して、さまざまなメール システムで、不要なコンテンツからコアをフィルターすることができます。
また、コメントが追加される課題は、メールの件名で見つかった最初の課題キーから選択されることに注意してください。
メールの本文中で指定されたマーカーまたはセパレータの前にコメントを追加 メール ハンドラーは、受信したメール メッセージに関する次の動作を行います。
- (メール ハンドラーで指定された) regex パターンが見つかった場合、メール メッセージ本文の、最初に一致した regex パターンの前のテキストがコメントに使用され、本文の残りの部分は破棄されます。
- (メール ハンドラーで指定された) regex パターンが見つからない場合、メール メッセージ本文のテキスト全体がコメントに使用されます。
- regex パターンがメール ハンドラーで指定されていない場合、メール メッセージ本文のテキスト全体がコメントに使用されます。
- メール ハンドラーに指定された regex 表現に誤りがある場合、メール メッセージ本文のテキスト全体がコメントに使用されます。
「メール本文中で指定されたマーカーまたはセパレーターの前にコメントを追加」メール ハンドラーを設定するには:
- メール ハンドラーの設定を開始していない場合は、開始します (上記)。
メールの本文中に指定されたマーカーまたはセパレータの前にコメントを追加ダイアログ ボックスで、次のフィールド/オプションを入力します。
スプリット正規表現 メール メッセージのメール本文の内容を本文の他の (返信または転送された) 内容から分割する文字列に一致する正規表現を指定します。
注意:
- regex の先頭と末尾に区切り文字 (通常は "
/
" ) を付ける必要があります。 - 各メール ハンドラーのフィールド/オプションを分割するためにカンマが使用されるため、正規表現ではカンマを使用できません。これは、メール ハンドラーが Jira サービスに統合されていて、エスケープ構文が存在しないためです。
例:
/----\s*Original Message\s*----/
または
/_____________*/
メール アドレスのキャッチ 指定した場合、"To:"、"Cc:"、"Bcc:" 行にこのフィールドで指定した受信者を含むメール メッセージのみが処理されます。例: issues@mycompany.com
Upon specifying an address here, all email messages whose To:, Cc:, Bcc: lines contain addresses other than the Catch Email Address are ignored. This is useful if you have multiple aliases for the same mail account (e.g.
foo-support@example-co.com
andbar-support@example-co.com
aliases forsupport@example-co.com
) for multiple mail services (e.g. each one to create issues in separate JIRA projects).注: 実際の本番環境では、このオプションはあまり使われません。より一般的な既定の報告者と混同しないようにしてください。メール ハンドラーごとに、キャッチする 1 つのメール アドレスと 1 つの課題タイプのみを指定できます。
一括 このオプションは、ヘッダーで優先順位フィールドが一括に設定されている、または自動送信フィールドがnoに設定されている「一括」電子メールメッセージにのみ影響します。これらのメッセージは一般的時に同サービスによって送信されます。これらの電子メールメッセージを受信すると、選択したオプションに応じて次の操作が実行されます。
- メールを無視して、何もしない。
- メールを転送する (メールの転送テキスト フィールドで設定されたアドレスへの転送など)。
- メールを完全に削除する。
メール転送 これを指定し、このメールサービスが受信した電子メールメッセージを処理できない場合、この問題を示す電子メールメッセージはこのフィールドで指定した電子メールアドレスに転送されます。
ユーザーの作成 Select this check box if you want JIRA to create new user accounts from any received email messages whose From: field contains an address that does not match one associated with an existing JIRA user account. This allows the creator of the email message to be notified of subsequent updates to the issue, which can be achieved by configuring the relevant project's notification scheme to notify the Reporter of updates.
新しく作成した JIRA ユーザアカウントのこれらのユーザ名とメールアドレスは、メッセージの送信者:フィールドで指定したメールアドレスになります。新しいユーザのパスワードはランダムに生成され、JIRA のアカウントについて知らせるメールが新しいユーザに送信されます。
Users created this way will be added to the 'jira-users' group and given application access to JIRA (and therefore take up a license).
Note: this option is not compatible with Default Reporter field option below and as such, choosing the Create Users option will hide the Default Reporter option.
既定の報告者 Specify the username of a default reporter, which will be used if the email address in the From: field of any received messages does not match the address associated with that of an existing JIRA user — for example, a JIRA username such as
emailed-reporter
注意:
- This option is not available if the Create Users check box is selected.
- このフィールドで指定したユーザーに、関連するプロジェクトの課題の作成プロジェクト権限 (上記で指定)、およびメール ハンドラーがコメントを追加する他の関連プロジェクトのコメントの作成プロジェクト権限があることを確認してください。
ユーザーの通知 上記の「ユーザーの作成」オプションでアカウントを作成したユーザーに、JIRA が通知する電子メールメッセージを送信しないよう設定する場合は、このチェックボックスをオフにします。
注: このオプションは、「ユーザーの作成」チェックボックスがオンになっている場合にのみ機能します。
- regex の先頭と末尾に区切り文字 (通常は "
- メール ハンドラーのテストと保存 (上記)。
課題とコメントの作成
Jira がそれぞれの受信メール メッセージを処理し、既存の課題へのコメントまたは新しい課題として追加する過程については、次のポイントをご確認ください。
- メール メッセージの件名は、既存の課題キーについて調べられます。
- 件名に課題キーが見つかった場合、その課題キーを使用して、メール メッセージ本文のコンテンツが課題へのコメントとして処理および追加されます。
- subject に課題キーが見つからない場合は、in-reply-to header が調べられます。
- メール メッセージが、作成済みの課題から生成された別のメール メッセージに対する返信だと分かった場合、本文はその課題へのコメントとして処理および追加されます。
- メール メッセージが応答でない場合、新しい課題が作成されます。
For example, an email message to a mail account foo@example-co.com
on a POP or IMAP mail server configured against a JIRA server will be processed as follows:
- 課題の作成:
- The subject of the email message will become the issue summary.
Since all issues require a summary, each email message intended for issue creation should include a subject.
- メール メッセージの本文は課題の説明になります。
- 上記の情報を使用して、プロジェクト「JRA」にバグが作成されます。(基本的には上記のメール ハンドラー設定に基づいています。)
- Any attachments to the email message will become attachments to the issue (assuming attachments have been enabled in JIRA).
To ensure compatibility with various operating systems, any of the following characters in the filename will be replaced with an underscore character: \, /, ", %, :, $, ?, *, <, |, >.
- 受信メールが高い優先度に設定されている場合、対応する課題は JIRA システムで設定されている既定の優先度よりも高い優先度で作成されます。
- The subject of the email message will become the issue summary.
- コメントの作成
- メールの本文は課題のコメントになります。
Any attachments to the email will become attachments to the issue (assuming attachments have been enabled in JIRA).
メール ハンドラの便利なヒント
JIRA ユーザー アカウントを持たない人から送信されたメール メッセージを JIRA が処理できるようにするには、
- メール サーバー/サービスで「匿名」/「ダミー」メール アカウントを作成します (上記)。
- メール フィールドが以前の手順で作成したメール アカウントと一致する、同等の「匿名」/「ダミー」JIRA ユーザー アカウントを作成します。
- このメール アカウントからのメッセージを処理するようメール ハンドラー (上記) を構成する場合、既定報告者をこの「匿名/ダミー」Jira ユーザー アカウントへ設定します。
ベスト プラクティス (Jira メール メッセージの前処理)
JIRA 本番環境サーバーの場合、次のメール メッセージ事前処理を設定することをお勧めします。
Back up messages to a folder
- JIRA のメール ハンドラーは、正常に処理されたメール メッセージをメール サーバーから削除するため、メールをバックアップ フォルダーに送信して、JIRA が処理したメールの記録が利用可能なことを確認してください。
Set up filters to avoid mail loops
メール フォルダーに JIRA メール通知への返信が含まれる場合は、自動返信やバウンス メールをフィルタリングするルールを設定します。
これを行わない場合、「オフィス不在」通知などの自動応答システムと JIRA との間のメール ループが発生する可能性が高くなります。JIRA は送信メールに「Precedence:bulk」ヘッダー (無効にしていない場合) と「Auto-Submitted」ヘッダーを設定しますが、一部の自動応答システムはこれを無視します。メールがバウンスまたは自動応答の場合、完全な検出方法はありません。次の規則 (procmail 形式) は、ほとんどの自動返信を検出します。^From:.*mailer-daemon@ ^Auto-Submitted:.auto- ^Content-Type:\ multipart/report;\ report-type=delivery-status ^Subject:\ Delivery\ Status\ Notification ^Subject:\ Undeliverable ^Subject: Returned Mail: ^From:\ System\ Administrator ^Precedence:\ auto_reply ^Subject:.*autoreply ^Subject:.*Account\ signup
これらの規則を使用しても、通常のメールと区別するためのヘッダー設定を行っていない自動応答を受け取る場合があります。こうした事例では、その送信者を除外するフィルターを手動で更新する必要があります。
Set up filters for large attachments
- 大容量の添付ファイル付きのメールをキャッチするフィルターを設定します。JIRA は標準の JavaMail ライブラリを使用してメールを解析していて、大容量の添付ファイルがあると、すぐにメモリ不足となります (たとえば、ヒープサイズ 512 MBヒープで 50 MBを超える場合)。未処理のメールは削除されないため、メール サービスを実行するたびにそのメールが再処理されます(OutOfMemoryError を発生させるもう一つの原因となります)。ほとんどのメール サーバーは大容量の添付ファイルの付いたメールを承諾しないよう設定されているため、実践では、この問題に遭遇することはめったにありません。メール サーバーが大容量の添付ファイルをそのまま JIRA に引渡すことはないと確信できない場合は、フィルターを設定して、JIRA が大容量の添付ファイル受け取らないようにするのが一番です。
Set up spam filters
- JIRA がスパムを処理する(そして、おそらくは課題を作成する)必要がないように、スパムをフィルタリングするルールを設定します。
トラブルシューティング
(上記)新しいメール ハンドラを作成(または既存のものを編集)するたび、メールハンドラの設定が期待通りに動作することを確認するテストできるテストボタンが利用可能になります。
一般的な問題