Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'doc/user/project/service_desk.md')
-rw-r--r--doc/user/project/service_desk.md341
1 files changed, 252 insertions, 89 deletions
diff --git a/doc/user/project/service_desk.md b/doc/user/project/service_desk.md
index 8d525965f96..b508fbcf676 100644
--- a/doc/user/project/service_desk.md
+++ b/doc/user/project/service_desk.md
@@ -43,8 +43,8 @@ Meanwhile:
## Configure Service Desk
-To start using Service Desk for a project, you must first turn it on.
-By default, Service Desk is turned off.
+By default, Service Desk is active in new projects.
+If it's not active, you can do it in the project's settings.
Prerequisites:
@@ -64,7 +64,7 @@ To enable Service Desk in your project:
1. Expand **Service Desk**.
1. Turn on the **Activate Service Desk** toggle.
1. Optional. Complete the fields.
- - [Add a suffix](#configure-a-custom-email-address-suffix) to your Service Desk email address.
+ - [Add a suffix](#configure-a-suffix-for-service-desk-alias-email) to your Service Desk email address.
- If the list below **Template to append to all Service Desk issues** is empty, create a
[description template](description_templates.md) in your repository.
1. Select **Save changes**.
@@ -81,81 +81,73 @@ To improve your Service Desk project's security, you should:
- [Enable Akismet](../../integration/akismet.md) on your GitLab instance to add spam checking to this service.
Unblocked email spam can result in many spam issues being created.
-### Create customized email templates
+### Customize emails sent to the requester
> - Moved from GitLab Premium to GitLab Free in 13.2.
> - `UNSUBSCRIBE_URL`, `SYSTEM_HEADER`, `SYSTEM_FOOTER`, and `ADDITIONAL_TEXT` placeholders [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/285512) in GitLab 15.9.
+> - `%{ISSUE_DESCRIPTION}` [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/223751) in GitLab 16.0.
+> - `%{ISSUE_URL}` [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/408793) in GitLab 16.1.
-An email is sent to the author when:
-
-- A user submits a new issue using Service Desk.
-- A new note is created on a Service Desk issue.
-
-You can customize the body of these email messages with templates.
+An email is sent to the requester when:
-#### Email header and footer **(FREE SELF)**
+- A requester submits a new ticket by emailing Service Desk.
+- A new public comment is added on a Service Desk ticket.
+ - Editing a comment does not trigger a new email to be sent.
-> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/344819) in GitLab 15.9.
+You can customize the body of these email messages with Service Desk email templates. The templates
+can include [GitLab Flavored Markdown](../markdown.md) and [some HTML tags](../markdown.md#inline-html).
+For example, you can format the emails to include a header and footer in accordance with your
+organization's brand guidelines. You can also include the following placeholders to display dynamic
+content specific to the Service Desk ticket or your GitLab instance.
-Instance administrators can add a small header or footer to the GitLab instance and make them
-visible in the email template. For more information, see
-[System header and footer messages](../admin_area/appearance.md#system-header-and-footer-messages).
+| Placeholder | `thank_you.md` | `new_note.md` | Description
+| ---------------------- | ---------------------- | ---------------------- | -----------
+| `%{ISSUE_ID}` | **{check-circle}** Yes | **{check-circle}** Yes | Ticket IID.
+| `%{ISSUE_PATH}` | **{check-circle}** Yes | **{check-circle}** Yes | Project path appended with the ticket IID.
+| `%{ISSUE_URL}` | **{check-circle}** Yes | **{check-circle}** Yes | URL of the ticket. External participants can only view the ticket if the project is public and ticket is not confidential (Service Desk tickets are confidential by default).
+| `%{ISSUE_DESCRIPTION}` | **{check-circle}** Yes | **{check-circle}** Yes | Ticket description. If a user has edited the description, it may contain sensitive information that is not intended to be delivered to external participants. Use this placeholder with care and ideally only if you never modify descriptions or your team is aware of the template design.
+| `%{UNSUBSCRIBE_URL}` | **{check-circle}** Yes | **{check-circle}** Yes | Unsubscribe URL.
+| `%{NOTE_TEXT}` | **{dotted-circle}** No | **{check-circle}** Yes | The new comment added to the ticket by a user. Take care to include this placeholder in `new_note.md`. Otherwise, the requesters may never see the updates on their Service Desk ticket.
#### Thank you email
-> - `%{ISSUE_DESCRIPTION}` [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/223751) in GitLab 16.0.
-> - `%{ISSUE_URL}` [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/408793) in GitLab 16.1.
-
-When a user submits an issue through Service Desk, GitLab sends a **thank you email**.
+When a requester submits an issue through Service Desk, GitLab sends a **thank you email**.
+Without additional configuration, GitLab sends the default thank you email.
-To create a custom email template, in the `.gitlab/service_desk_templates/`
-directory in your repository, create a file named `thank_you.md`.
+To create a custom thank you email template:
-You can use these placeholders to be automatically replaced in each email:
+1. In the `.gitlab/service_desk_templates/` directory of your repository, create a file named `thank_you.md`.
+1. Populate the Markdown file with text, [GitLab Flavored Markdown](../markdown.md),
+ [some selected HTML tags](../markdown.md#inline-html), and placeholders to customize the reply
+ to Service Desk requesters.
-- `%{ISSUE_ID}`: Issue IID.
-- `%{ISSUE_PATH}`: Project path appended with the issue IID.
-- `%{ISSUE_URL}`: URL to the issue. External participants can only view the issue if the project is public
- and issue is not confidential (Service Desk issues are confidential by default).
-- `%{ISSUE_DESCRIPTION}`: Issue description based on the original email.
-- `%{UNSUBSCRIBE_URL}`: Unsubscribe URL.
-- `%{SYSTEM_HEADER}`: [System header message](../admin_area/appearance.md#system-header-and-footer-messages).
-- `%{SYSTEM_FOOTER}`: [System footer message](../admin_area/appearance.md#system-header-and-footer-messages).
-- `%{ADDITIONAL_TEXT}`: [Custom additional text](../admin_area/settings/email.md#custom-additional-text).
+#### New note email
-Because Service Desk issues are created as [confidential](issues/confidential_issues.md) (only project members can see them),
-the response email does not contain the issue link.
+When a Service Desk ticket has a new public comment, GitLab sends a **new note email**.
+Without additional configuration, GitLab sends the content of the comment.
-#### New note email
+To keep your emails on brand, you can create a custom new note email template. To do so:
-> - `%{ISSUE_DESCRIPTION}` [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/223751) in GitLab 16.0.
-> - `%{ISSUE_URL}` [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/408793) in GitLab 16.1.
+1. In the `.gitlab/service_desk_templates/` directory in your repository, create a file named `new_note.md`.
+1. Populate the Markdown file with text, [GitLab Flavored Markdown](../markdown.md),
+ [some selected HTML tags](../markdown.md#inline-html), and placeholders to customize the new note
+ email. Be sure to include the `%{NOTE_TEXT}` in the template to make sure the email recipient can
+ read the contents of the comment.
-When a user-submitted issue receives a new comment, GitLab sends a **new note email**.
+#### Instance-level email header, footer, and additional text **(FREE SELF)**
-To create a custom email template, in the `.gitlab/service_desk_templates/`
-directory in your repository, create a file named `new_note.md`.
+> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/344819) in GitLab 15.9.
-You can use these placeholders to be automatically replaced in each email:
+Instance administrators can add a header, footer or additional text to the GitLab instance and apply
+them to all emails sent from GitLab. If you're using a custom `thank_you.md` or `new_note.md`, to include
+this content, add `%{SYSTEM_HEADER}`, `%{SYSTEM_FOOTER}`, or `%{ADDITIONAL_TEXT}` to your templates.
-- `%{ISSUE_ID}`: Issue IID.
-- `%{ISSUE_PATH}`: Project path appended with the issue IID.
-- `%{ISSUE_URL}`: URL to the issue. External participants can only view the issue if the project is public
- and issue is not confidential (Service Desk issues are confidential by default).
-- `%{ISSUE_DESCRIPTION}`: Issue description at the time email is generated.
- If a user has edited the description, it might contain sensitive information that is not intended
- to be delivered to external participants. Use this placeholder only if you never modify
- descriptions or your team is aware of the template design.
-- `%{NOTE_TEXT}`: Note text.
-- `%{UNSUBSCRIBE_URL}`: Unsubscribe URL.
-- `%{SYSTEM_HEADER}`: [System header message](../admin_area/appearance.md#system-header-and-footer-messages).
-- `%{SYSTEM_FOOTER}`: [System footer message](../admin_area/appearance.md#system-header-and-footer-messages).
-- `%{ADDITIONAL_TEXT}`: [Custom additional text](../admin_area/settings/email.md#custom-additional-text).
+For more information, see [System header and footer messages](../../administration/appearance.md#system-header-and-footer-messages) and [custom additional text](../../administration/settings/email.md#custom-additional-text).
-### Use a custom template for Service Desk issues
+### Use a custom template for Service Desk tickets
You can select one [description template](description_templates.md#create-an-issue-template)
-**per project** to be appended to every new Service Desk issue's description.
+**per project** to be appended to every new Service Desk ticket's description.
You can set description templates at various levels:
@@ -200,27 +192,26 @@ To edit the custom email display name:
1. Below **Email display name**, enter a new name.
1. Select **Save changes**.
-### Use a custom email address **(FREE SELF)**
+### Use an additional Service Desk alias email **(FREE SELF)**
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/2201) in GitLab 13.0.
> - [Feature flag removed](https://gitlab.com/gitlab-org/gitlab/-/issues/284656) in GitLab 13.8.
-You can use a custom email address with Service Desk.
+You can use an additional alias email address for Service Desk on an instance level.
To do this, you must configure
-a [custom mailbox](#configure-a-custom-mailbox). You can also configure a
-[custom suffix](#configure-a-custom-email-address-suffix).
+a [`service_desk_email`](#configure-service-desk-alias-email) in the instance configuration. You can also configure a
+[custom suffix](#configure-a-suffix-for-service-desk-alias-email) that replaces the default `-issue-` portion on the sub-addressing part.
-#### Configure a custom mailbox
+#### Configure Service Desk alias email
NOTE:
-On GitLab.com a custom mailbox is already configured with `contact-project+%{key}@incoming.gitlab.com` as the email address, you can still configure the
-[custom suffix](#configure-a-custom-email-address-suffix) in project settings.
+On GitLab.com a custom mailbox is already configured with `contact-project+%{key}@incoming.gitlab.com` as the email address. You can still configure the
+[custom suffix](#configure-a-suffix-for-service-desk-alias-email) in project settings.
Service Desk uses the [incoming email](../../administration/incoming_email.md)
-configuration by default. However, by using the `service_desk_email` configuration,
-you can customize the mailbox used by Service Desk. This allows you to have
-a separate email address for Service Desk by also configuring a [custom suffix](#configure-a-custom-email-address-suffix)
+configuration by default. However, to have a separate email address for Service Desk,
+configure `service_desk_email` with a [custom suffix](#configure-a-suffix-for-service-desk-alias-email)
in project settings.
Prerequisites:
@@ -413,14 +404,19 @@ read about [Helm IMAP secrets](https://docs.gitlab.com/charts/installation/secre
##### Microsoft Graph
-> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/214900) in GitLab 13.11.
> - Alternative Azure deployments [introduced](https://gitlab.com/gitlab-org/omnibus-gitlab/-/merge_requests/5978) in GitLab 14.9.
+> - [Introduced for self-compiled (source) installs](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/116494) in GitLab 15.11.
-Service Desk can be configured to read Microsoft Exchange Online mailboxes with the Microsoft
+`service_desk_email` can be configured to read Microsoft Exchange Online mailboxes with the Microsoft
Graph API instead of IMAP. Set up an OAuth 2.0 application for Microsoft Graph
[the same way as for incoming email](../../administration/incoming_email.md#microsoft-graph).
-- Example for Linux package installations:
+::Tabs
+
+:::TabTitle Linux package (Omnibus)
+
+1. Edit `/etc/gitlab/gitlab.rb` and add the following lines, substituting
+ the values you want:
```ruby
gitlab_rails['service_desk_email_enabled'] = true
@@ -430,33 +426,200 @@ Graph API instead of IMAP. Set up an OAuth 2.0 application for Microsoft Graph
gitlab_rails['service_desk_email_log_file'] = "/var/log/gitlab/mailroom/mail_room_json.log"
gitlab_rails['service_desk_email_inbox_method'] = 'microsoft_graph'
gitlab_rails['service_desk_email_inbox_options'] = {
- 'tenant_id': '<YOUR-TENANT-ID>',
- 'client_id': '<YOUR-CLIENT-ID>',
- 'client_secret': '<YOUR-CLIENT-SECRET>',
- 'poll_interval': 60 # Optional
+ 'tenant_id': '<YOUR-TENANT-ID>',
+ 'client_id': '<YOUR-CLIENT-ID>',
+ 'client_secret': '<YOUR-CLIENT-SECRET>',
+ 'poll_interval': 60 # Optional
+ }
+ ```
+
+ For Microsoft Cloud for US Government or [other Azure deployments](https://learn.microsoft.com/en-us/graph/deployments),
+ configure the `azure_ad_endpoint` and `graph_endpoint` settings. For example:
+
+ ```ruby
+ gitlab_rails['service_desk_email_inbox_options'] = {
+ 'azure_ad_endpoint': 'https://login.microsoftonline.us',
+ 'graph_endpoint': 'https://graph.microsoft.us',
+ 'tenant_id': '<YOUR-TENANT-ID>',
+ 'client_id': '<YOUR-CLIENT-ID>',
+ 'client_secret': '<YOUR-CLIENT-SECRET>',
+ 'poll_interval': 60 # Optional
}
```
+:::TabTitle Helm chart (Kubernetes)
+
+1. Create the [Kubernetes Secret containing the OAuth 2.0 application client secret](https://docs.gitlab.com/charts/installation/secrets.html#microsoft-graph-client-secret-for-service-desk-emails):
+
+ ```shell
+ kubectl create secret generic service-desk-email-client-secret --from-literal=secret=<YOUR-CLIENT_SECRET>
+ ```
+
+1. Create the [Kubernetes Secret for the GitLab Service Desk email auth token](https://docs.gitlab.com/charts/installation/secrets.html#gitlab-service-desk-email-auth-token).
+ Replace `<name>` with the name of the [Helm release name](https://helm.sh/docs/intro/using_helm/) for the GitLab installation:
+
+ ```shell
+ kubectl create secret generic <name>-service-desk-email-auth-token --from-literal=authToken=$(head -c 512 /dev/urandom | LC_CTYPE=C tr -cd 'a-zA-Z0-9' | head -c 32 | base64)
+ ```
+
+1. Export the Helm values:
+
+ ```shell
+ helm get values gitlab > gitlab_values.yaml
+ ```
+
+1. Edit `gitlab_values.yaml`:
+
+ ```yaml
+ global:
+ appConfig:
+ serviceDeskEmail:
+ enabled: true
+ address: "project_contact+%{key}@example.onmicrosoft.com"
+ user: "project_contact@example.onmicrosoft.com"
+ mailbox: inbox
+ inboxMethod: microsoft_graph
+ azureAdEndpoint: https://login.microsoftonline.com
+ graphEndpoint: https://graph.microsoft.com
+ tenantId: "YOUR-TENANT-ID"
+ clientId: "YOUR-CLIENT-ID"
+ clientSecret:
+ secret: service-desk-email-client-secret
+ key: secret
+ deliveryMethod: webhook
+ authToken:
+ secret: <name>-service-desk-email-auth-token
+ key: authToken
+ ```
+
+ For Microsoft Cloud for US Government or [other Azure deployments](https://learn.microsoft.com/en-us/graph/deployments),
+configure the `azureAdEndpoint` and `graphEndpoint` settings. These fields are case-sensitive:
+
+ ```yaml
+ global:
+ appConfig:
+ serviceDeskEmail:
+ [..]
+ azureAdEndpoint: https://login.microsoftonline.us
+ graphEndpoint: https://graph.microsoft.us
+ [..]
+ ```
+
+1. Save the file and apply the new values:
+
+ ```shell
+ helm upgrade -f gitlab_values.yaml gitlab gitlab/gitlab
+ ```
+
+:::TabTitle Docker
+
+1. Edit `docker-compose.yml`:
+
+ ```yaml
+ version: "3.6"
+ services:
+ gitlab:
+ environment:
+ GITLAB_OMNIBUS_CONFIG: |
+ gitlab_rails['service_desk_email_enabled'] = true
+ gitlab_rails['service_desk_email_address'] = "project_contact+%{key}@example.onmicrosoft.com"
+ gitlab_rails['service_desk_email_email'] = "project_contact@example.onmicrosoft.com"
+ gitlab_rails['service_desk_email_mailbox_name'] = "inbox"
+ gitlab_rails['service_desk_email_log_file'] = "/var/log/gitlab/mailroom/mail_room_json.log"
+ gitlab_rails['service_desk_email_inbox_method'] = 'microsoft_graph'
+ gitlab_rails['service_desk_email_inbox_options'] = {
+ 'tenant_id': '<YOUR-TENANT-ID>',
+ 'client_id': '<YOUR-CLIENT-ID>',
+ 'client_secret': '<YOUR-CLIENT-SECRET>',
+ 'poll_interval': 60 # Optional
+ }
+ ```
+
+1. Save the file and restart GitLab:
+
+ ```shell
+ docker compose up -d
+ ```
+
For Microsoft Cloud for US Government or [other Azure deployments](https://learn.microsoft.com/en-us/graph/deployments),
-configure the `azure_ad_endpoint` and `graph_endpoint` settings.
+configure the `azure_ad_endpoint` and `graph_endpoint` settings:
-- Example for Microsoft Cloud for US Government:
+1. Edit `docker-compose.yml`:
-```ruby
-gitlab_rails['service_desk_email_inbox_options'] = {
- 'azure_ad_endpoint': 'https://login.microsoftonline.us',
- 'graph_endpoint': 'https://graph.microsoft.us',
- 'tenant_id': '<YOUR-TENANT-ID>',
- 'client_id': '<YOUR-CLIENT-ID>',
- 'client_secret': '<YOUR-CLIENT-SECRET>',
- 'poll_interval': 60 # Optional
-}
-```
+ ```yaml
+ version: "3.6"
+ services:
+ gitlab:
+ environment:
+ GITLAB_OMNIBUS_CONFIG: |
+ gitlab_rails['service_desk_email_enabled'] = true
+ gitlab_rails['service_desk_email_address'] = "project_contact+%{key}@example.onmicrosoft.com"
+ gitlab_rails['service_desk_email_email'] = "project_contact@example.onmicrosoft.com"
+ gitlab_rails['service_desk_email_mailbox_name'] = "inbox"
+ gitlab_rails['service_desk_email_log_file'] = "/var/log/gitlab/mailroom/mail_room_json.log"
+ gitlab_rails['service_desk_email_inbox_method'] = 'microsoft_graph'
+ gitlab_rails['service_desk_email_inbox_options'] = {
+ 'azure_ad_endpoint': 'https://login.microsoftonline.us',
+ 'graph_endpoint': 'https://graph.microsoft.us',
+ 'tenant_id': '<YOUR-TENANT-ID>',
+ 'client_id': '<YOUR-CLIENT-ID>',
+ 'client_secret': '<YOUR-CLIENT-SECRET>',
+ 'poll_interval': 60 # Optional
+ }
+ ```
+
+1. Save the file and restart GitLab:
+
+ ```shell
+ docker compose up -d
+ ```
+
+:::TabTitle Self-compiled (source)
-The Microsoft Graph API is not yet supported in source installations.
-For more information, see [issue 326169](https://gitlab.com/gitlab-org/gitlab/-/issues/326169).
+1. Edit `/home/git/gitlab/config/gitlab.yml`:
+
+ ```yaml
+ service_desk_email:
+ enabled: true
+ address: "project_contact+%{key}@example.onmicrosoft.com"
+ user: "project_contact@example.onmicrosoft.com"
+ mailbox: "inbox"
+ delivery_method: webhook
+ log_path: "log/mailroom.log"
+ secret_file: .gitlab-mailroom-secret
+ inbox_method: "microsoft_graph"
+ inbox_options:
+ tenant_id: "<YOUR-TENANT-ID>"
+ client_id: "<YOUR-CLIENT-ID>"
+ client_secret: "<YOUR-CLIENT-SECRET>"
+ poll_interval: 60 # Optional
+ ```
+
+ For Microsoft Cloud for US Government or [other Azure deployments](https://learn.microsoft.com/en-us/graph/deployments),
+ configure the `azure_ad_endpoint` and `graph_endpoint` settings. For example:
+
+ ```yaml
+ service_desk_email:
+ enabled: true
+ address: "project_contact+%{key}@example.onmicrosoft.com"
+ user: "project_contact@example.onmicrosoft.com"
+ mailbox: "inbox"
+ delivery_method: webhook
+ log_path: "log/mailroom.log"
+ secret_file: .gitlab-mailroom-secret
+ inbox_method: "microsoft_graph"
+ inbox_options:
+ azure_ad_endpoint: "https://login.microsoftonline.us"
+ graph_endpoint: "https://graph.microsoft.us"
+ tenant_id: "<YOUR-TENANT-ID>"
+ client_id: "<YOUR-CLIENT-ID>"
+ client_secret: "<YOUR-CLIENT-SECRET>"
+ poll_interval: 60 # Optional
+ ```
+
+::EndTabs
-#### Configure a custom email address suffix
+#### Configure a suffix for Service Desk alias email
You can set a custom suffix in your project's Service Desk settings.
@@ -467,7 +630,7 @@ When configured, the custom suffix creates a new Service Desk email address, con
Prerequisites:
-- You must have configured a [custom mailbox](#configure-a-custom-mailbox).
+- You must have configured a [Service Desk alias email](#configure-service-desk-alias-email).
1. On the left sidebar, at the top, select **Search GitLab** (**{search}**) to find your project.
1. Select **Settings > General**.
@@ -702,7 +865,7 @@ HTML emails show HTML formatting, such as:
> - [Enabled on GitLab.com and self-managed](https://gitlab.com/gitlab-org/gitlab/-/issues/386860) in GitLab 15.10.
FLAG:
-On self-managed GitLab, by default this feature is available. To hide the feature per project or for your entire instance, ask an administrator to [disable the feature flag](../../administration/feature_flags.md) named `service_desk_new_note_email_native_attachments`.
+On self-managed GitLab, by default this feature is available. To hide the feature per project or for your entire instance, an administrator can [disable the feature flag](../../administration/feature_flags.md) named `service_desk_new_note_email_native_attachments`.
On GitLab.com, this feature is available.
If a comment contains any attachments and their total size is less than or equal to 10 MB, these