summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-07-22 18:09:27 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-07-22 18:09:27 +0000
commit3ce55b46dfae23d14818ed2630891be8aa3e83e0 (patch)
treebe2b93cf35b854871d8cbb2c22a8d5c11d6caf03 /doc
parentd1cb802bac5dc182342adb9b8f71dbf466cfa501 (diff)
downloadgitlab-ce-3ce55b46dfae23d14818ed2630891be8aa3e83e0.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'doc')
-rw-r--r--doc/.vale/gitlab/Acronyms.yml1
-rw-r--r--doc/administration/high_availability/nfs.md14
-rw-r--r--doc/ci/introduction/index.md2
-rw-r--r--doc/development/api_graphql_styleguide.md4
-rw-r--r--doc/development/api_styleguide.md2
-rw-r--r--doc/development/documentation/styleguide.md140
-rw-r--r--doc/development/geo/framework.md32
-rw-r--r--doc/user/clusters/applications.md6
-rw-r--r--doc/user/project/labels.md2
9 files changed, 156 insertions, 47 deletions
diff --git a/doc/.vale/gitlab/Acronyms.yml b/doc/.vale/gitlab/Acronyms.yml
index d166e71491c..c347c663bbf 100644
--- a/doc/.vale/gitlab/Acronyms.yml
+++ b/doc/.vale/gitlab/Acronyms.yml
@@ -68,6 +68,7 @@ exceptions:
- SSH
- SSL
- SSO
+ - SVG
- SVN
- TCP
- TIP
diff --git a/doc/administration/high_availability/nfs.md b/doc/administration/high_availability/nfs.md
index 6e8dc2c6c57..63ae0e4193a 100644
--- a/doc/administration/high_availability/nfs.md
+++ b/doc/administration/high_availability/nfs.md
@@ -35,6 +35,20 @@ kernel version:
If you are using that kernel version, be sure to upgrade GitLab to avoid
errors.
+## Fast lookup of authorized SSH keys
+
+The [fast SSH key lookup](../operations/fast_ssh_key_lookup.md) feature can improve
+performance of GitLab instances even if they're using block storage.
+
+[Fast SSH key lookup](../operations/fast_ssh_key_lookup.md) is a replacement for
+`authorized_keys` (in `/var/opt/gitlab/.ssh`) using the GitLab database.
+
+NFS increases latency, so fast lookup is recommended if `/var/opt/gitlab`
+is moved to NFS.
+
+We are investigating the use of
+[fast lookup as the default](https://gitlab.com/groups/gitlab-org/-/epics/3104).
+
## NFS Server features
### Required features
diff --git a/doc/ci/introduction/index.md b/doc/ci/introduction/index.md
index db18624d4e9..c97f4e51d30 100644
--- a/doc/ci/introduction/index.md
+++ b/doc/ci/introduction/index.md
@@ -230,7 +230,7 @@ syntax and with its attributes.
This document [introduces the concepts of GitLab CI/CD in the scope of GitLab Pages](../../user/project/pages/getting_started/pages_from_scratch.md), for deploying static websites.
Although it's meant for users who want to write their own Pages
script from scratch, it also serves as an introduction to the setup process for GitLab CI/CD.
-It covers the very first general steps of writing a CI/CD configuration
+It covers the first general steps of writing a CI/CD configuration
file, so we recommend you read through it to understand GitLab's CI/CD
logic, and learn how to write your own script (or tweak an
existing one) for any application.
diff --git a/doc/development/api_graphql_styleguide.md b/doc/development/api_graphql_styleguide.md
index 92e6add9f17..4ca13dc9e01 100644
--- a/doc/development/api_graphql_styleguide.md
+++ b/doc/development/api_graphql_styleguide.md
@@ -1204,3 +1204,7 @@ See the [schema reference](../api/graphql/reference/index.md) for details.
This generated GraphQL documentation needs to be updated when the schema changes.
For information on generating GraphQL documentation and schema files, see
[updating the schema documentation](rake_tasks.md#update-graphql-documentation-and-schema-definitions).
+
+To help our readers, you should also add a new page to our [GraphQL API](../api/graphql/index.md) documentation.
+For guidance, see the [GraphQL API](documentation/styleguide.md#graphql-api) section
+of our documentation style guide.
diff --git a/doc/development/api_styleguide.md b/doc/development/api_styleguide.md
index 651332b4e62..5fb5e1c1b13 100644
--- a/doc/development/api_styleguide.md
+++ b/doc/development/api_styleguide.md
@@ -13,7 +13,7 @@ Always use an [Entity](https://gitlab.com/gitlab-org/gitlab/blob/master/lib/api/
## Documentation
-API endpoints must come with [documentation](documentation/styleguide.md#api), unless it is internal or behind a feature flag.
+API endpoints must come with [documentation](documentation/styleguide.md#restful-api), unless it is internal or behind a feature flag.
The docs should be in the same merge request, or, if strictly necessary,
in a follow-up with the same milestone as the original merge request.
diff --git a/doc/development/documentation/styleguide.md b/doc/development/documentation/styleguide.md
index fb60a9b172c..d67fc696ad9 100644
--- a/doc/development/documentation/styleguide.md
+++ b/doc/development/documentation/styleguide.md
@@ -1135,48 +1135,39 @@ Usage examples:
[Bootstrap utility class](https://getbootstrap.com/docs/4.4/utilities/float/):
`**{tanuki, 32, float-right}**` renders as: **{tanuki, 32, float-right}**
-### Use GitLab SVGs to describe UI elements
+### When to use icons
-When using GitLab SVGs to describe screen elements, also include the name or tooltip of the element as text.
+Icons should be used sparingly, and only in ways that aid and do not hinder the readability of the
+text.
-For example, for references to the Admin Area:
+For example, the following adds little to the accompanying text:
-- Correct: `**{admin}** **Admin Area > Settings**` (**{admin}** **Admin Area > Settings**)
-- Incorrect: `**{admin}** **> Settings**` (**{admin}** **> Settings**)
+```markdown
+1. Go to **{home}** **Project overview > Details**
+```
-This will ensure that the source Markdown remains readable and should help with accessibility.
+1. Go to **{home}** **Project overview > Details**
-The following are examples of source Markdown for menu items with their published output:
+However, the following might help the reader connect the text to the user interface:
```markdown
-1. Go to **{home}** **Project overview > Details**
-1. Go to **{doc-text}** **Repository > Branches**
-1. Go to **{issues}** **Issues > List**
-1. Go to **{merge-request}** **Merge Requests**
-1. Go to **{rocket}** **CI/CD > Pipelines**
-1. Go to **{shield}** **Security & Compliance > Configuration**
-1. Go to **{cloud-gear}** **Operations > Metrics**
-1. Go to **{package}** **Packages > Container Registry**
-1. Go to **{chart}** **Project Analytics > Code Review**
-1. Go to **{book}** **Wiki**
-1. Go to **{snippet}** **Snippets**
-1. Go to **{users}** **Members**
-1. Select the **More actions** **{ellipsis_v}** icon > **Hide stage**
+| Section | Description |
+|:-------------------------|:----------------------------------------------------------------------------------------------------------------------------|
+| **{overview}** Overview | View your GitLab Dashboard, and administer projects, users, groups, jobs, Runners, and Gitaly servers. |
+| **{monitor}** Monitoring | View GitLab system information, and information on background jobs, logs, health checks, requests profiles, and audit logs. |
+| **{messages}** Messages | Send and manage broadcast messages for your users. |
```
-1. Go to **{home}** **Project overview > Details**
-1. Go to **{doc-text}** **Repository > Branches**
-1. Go to **{issues}** **Issues > List**
-1. Go to **{merge-request}** **Merge Requests**
-1. Go to **{rocket}** **CI/CD > Pipelines**
-1. Go to **{shield}** **Security & Compliance > Configuration**
-1. Go to **{cloud-gear}** **Operations > Metrics**
-1. Go to **{package}** **Packages > Container Registry**
-1. Go to **{chart}** **Project Analytics > Code Review**
-1. Go to **{book}** **Wiki**
-1. Go to **{snippet}** **Snippets**
-1. Go to **{users}** **Members**
-1. Select the **More actions** **{ellipsis_v}** icon > **Hide stage**
+| Section | Description |
+|:-------------------------|:----------------------------------------------------------------------------------------------------------------------------|
+| **{overview}** Overview | View your GitLab Dashboard, and administer projects, users, groups, jobs, Runners, and Gitaly servers. |
+| **{monitor}** Monitoring | View GitLab system information, and information on background jobs, logs, health checks, requests profiles, and audit logs. |
+| **{messages}** Messages | Send and manage broadcast messages for your users. |
+
+Use an icon when you find youself having to describe an interface element. For example:
+
+- Do: Click the Admin Area icon ( **{admin}** ).
+- Don't: Click the Admin Area icon (the wrench icon).
## Alert boxes
@@ -1622,10 +1613,10 @@ Learn how to [document features deployed behind flags](feature_flags.md).
For guidance on developing GitLab with feature flags, see
[Feature flags in development of GitLab](../feature_flags/index.md).
-## API
+## RESTful API
-Here is a list of must-have items. Use them in the exact order that appears
-on this document. Further explanation is given below.
+Here is a list of must-have items for RESTful API documentation. Use them in the
+exact order that appears on this document. Further explanation is given below.
- Every method must have the REST API request. For example:
@@ -1816,3 +1807,80 @@ exclude specific users when requesting a list of users for a project, you would
```shell
curl --request PUT --header "PRIVATE-TOKEN: <your_access_token>" --data "skip_users[]=<user_id>" --data "skip_users[]=<user_id>" https://gitlab.example.com/api/v4/projects/<project_id>/users
```
+
+## GraphQL API
+
+GraphQL APIs are different from [RESTful APIs](#restful-api). Reference information is
+generated automatically in our [GraphQL reference](../../api/graphql/reference/index.md).
+
+However, it's helpful to include examples on how to use GraphQL for different "use cases",
+with samples that readers can use directly in the [GraphiQL explorer](../api_graphql_styleguide.md#graphiql).
+
+This section describes the steps required to add your GraphQL examples to GitLab documentation.
+
+### Add a dedicated GraphQL page
+
+To create a dedicated GraphQL page, create a new `.md` file in the `doc/api/graphql/` directory.
+Give that file a functional name, such as `import_from_specific_location.md`.
+
+### Start the page with an explanation
+
+Include a page title that describes the GraphQL functionality in a few words, such as:
+
+```markdown
+# Search for [substitute kind of data]
+```
+
+Describe the search. One sentence may be all you need. More information may help
+readers learn how to use the example for their GitLab deployments.
+
+### Include a procedure using the GraphiQL explorer
+
+The GraphiQL explorer can help readers test queries with working deployments. Set up the section with the following:
+
+- Use the following title:
+
+ ```markdown
+ ## Set up the GraphiQL explorer
+ ```
+
+- Include a code block with the query that anyone can include in their instance of
+ the GraphiQL explorer:
+
+ ````markdown
+ ```graphql
+ query {
+ <insert queries here>
+ }
+ ```
+ ````
+
+- Tell the user what to do:
+
+ ```markdown
+ 1. Open the GraphiQL explorer tool in the following URL: `https://gitlab.com/-/graphql-explorer`.
+ 1. Paste the `query` listed above into the left window of your GraphiQL explorer tool.
+ 1. Click Play to get the result shown here:
+ ```
+
+- Include a screenshot of the result in the GraphiQL explorer. Follow the naming
+ convention described in the [Save the image](#save-the-image) section.
+- Follow up with an example of what you can do with the output.
+ Make sure the example is something that readers can do on their own deployments.
+- Include a link to the [GraphQL API resources](../../api/graphql/reference/index.md).
+
+### Add the GraphQL example to the Table of Contents
+
+You'll need to open a second MR, against the [GitLab Docs repository](https://gitlab.com/gitlab-org/gitlab-docs/).
+
+We store our Table of Contents in the `default-nav.yaml` file, in the `content/_data`
+subdirectory. You can find the GraphQL section under the following line:
+
+```yaml
+ - category_title: GraphQL
+```
+
+Be aware that CI tests for that second MR will fail with a bad link until the main MR
+that adds the new GraphQL page is merged.
+
+And that's all you need!
diff --git a/doc/development/geo/framework.md b/doc/development/geo/framework.md
index 5c9b01466d6..c5ba926dd04 100644
--- a/doc/development/geo/framework.md
+++ b/doc/development/geo/framework.md
@@ -360,11 +360,33 @@ Widgets should now be replicated by Geo!
DOWNTIME = false
def change
- add_column :widgets, :verification_retry_at, :datetime_with_timezone
- add_column :widgets, :verified_at, :datetime_with_timezone
- add_column :widgets, :verification_checksum, :binary, using: 'verification_checksum::bytea'
- add_column :widgets, :verification_failure, :string
- add_column :widgets, :verification_retry_count, :integer
+ change_table(:widgets) do |t|
+ t.integer :verification_retry_count, limit: 2
+ t.column :verification_retry_at, :datetime_with_timezone
+ t.column :verified_at, :datetime_with_timezone
+ t.binary :verification_checksum, using: 'verification_checksum::bytea'
+
+ # rubocop:disable Migration/AddLimitToTextColumns
+ t.text :verification_failure
+ # rubocop:enable Migration/AddLimitToTextColumns
+ end
+ end
+ end
+ ```
+
+ Adding a `text` column also [requires](../database/strings_and_the_text_data_type.md#add-a-text-column-to-an-existing-table)
+ setting a limit:
+
+ ```ruby
+ # frozen_string_literal: true
+
+ class AddVerificationFailureLimitToWidgets < ActiveRecord::Migration[6.0]
+ DOWNTIME = false
+
+ disable_ddl_transaction!
+
+ def change
+ add_text_limit :widgets, :verification_failure, 255
end
end
```
diff --git a/doc/user/clusters/applications.md b/doc/user/clusters/applications.md
index 507ba25850d..90f4782e0be 100644
--- a/doc/user/clusters/applications.md
+++ b/doc/user/clusters/applications.md
@@ -311,7 +311,7 @@ This feature:
For example:
```shell
- kubectl logs -n gitlab-managed-apps $(kubectl get pod -n gitlab-managed-apps -l app=nginx-ingress,component=controller --no-headers=true -o custom-columns=:metadata.name) modsecurity-log -f
+ kubectl -n gitlab-managed-apps logs -l app=nginx-ingress,component=controller -c modsecurity-log -f
```
To enable WAF, switch its respective toggle to the enabled position when installing or updating [Ingress application](#ingress).
@@ -1004,7 +1004,7 @@ The Cilium monitor log for traffic is logged out by the
`cilium-monitor` sidecar container. You can check these logs with the following command:
```shell
-kubectl -n gitlab-managed-apps logs cilium-XXXX cilium-monitor
+kubectl -n gitlab-managed-apps logs -l k8s-app=cilium -c cilium-monitor
```
You can disable the monitor log in `.gitlab/managed-apps/cilium/values.yaml`:
@@ -1127,7 +1127,7 @@ falco:
You can check these logs with the following command:
```shell
-kubectl logs -l app=falco -n gitlab-managed-apps
+kubectl -n gitlab-managed-apps logs -l app=falco
```
NOTE: **Note:**
diff --git a/doc/user/project/labels.md b/doc/user/project/labels.md
index 9886ef91f16..5bb31d54e08 100644
--- a/doc/user/project/labels.md
+++ b/doc/user/project/labels.md
@@ -43,7 +43,7 @@ To assign a label to an issue, merge request or epic:
click on them. You can search repeatedly and add more labels.
1. Click **X** or anywhere outside the label section and the labels are applied.
-You can also assign a label with the [`/assign @username` quick action](quick_actions.md).
+You can also assign a label with the [`/label ~label1 ~label2` quick action](quick_actions.md).
## Label management