Commit b7d8c817 authored by Achilleas Pipinellis's avatar Achilleas Pipinellis

Merge branch 'docs-code-block-style' into 'master'

Docs: Fix spacing of code blocks

See merge request gitlab-org/gitlab-ce!30453
parents 84b49ef3 5abfc57e
# GitLab Container Registry administration # GitLab Container Registry administration
> **Notes:**
>
> - [Introduced][ce-4040] in GitLab 8.8. > - [Introduced][ce-4040] in GitLab 8.8.
> - Container Registry manifest `v1` support was added in GitLab 8.9 to support > - Container Registry manifest `v1` support was added in GitLab 8.9 to support
> Docker versions earlier than 1.10. > Docker versions earlier than 1.10.
...@@ -219,7 +217,7 @@ look like: ...@@ -219,7 +217,7 @@ look like:
1. Open `/home/git/gitlab/config/gitlab.yml`, find the `registry` entry and 1. Open `/home/git/gitlab/config/gitlab.yml`, find the `registry` entry and
configure it with the following settings: configure it with the following settings:
``` ```yaml
registry: registry:
enabled: true enabled: true
host: registry.gitlab.example.com host: registry.gitlab.example.com
...@@ -261,7 +259,7 @@ Registry application itself. ...@@ -261,7 +259,7 @@ Registry application itself.
1. Open `/home/git/gitlab/config/gitlab.yml`, find the `registry` entry and 1. Open `/home/git/gitlab/config/gitlab.yml`, find the `registry` entry and
set `enabled` to `false`: set `enabled` to `false`:
``` ```yaml
registry: registry:
enabled: false enabled: false
``` ```
...@@ -293,7 +291,7 @@ the Container Registry by themselves, follow the steps below. ...@@ -293,7 +291,7 @@ the Container Registry by themselves, follow the steps below.
1. Open `/home/git/gitlab/config/gitlab.yml`, find the `default_projects_features` 1. Open `/home/git/gitlab/config/gitlab.yml`, find the `default_projects_features`
entry and configure it so that `container_registry` is set to `false`: entry and configure it so that `container_registry` is set to `false`:
``` ```yaml
## Default project features settings ## Default project features settings
default_projects_features: default_projects_features:
issues: true issues: true
...@@ -348,7 +346,7 @@ The default location where images are stored in source installations, is ...@@ -348,7 +346,7 @@ The default location where images are stored in source installations, is
1. Open `/home/git/gitlab/config/gitlab.yml`, find the `registry` entry and 1. Open `/home/git/gitlab/config/gitlab.yml`, find the `registry` entry and
change the `path` setting: change the `path` setting:
``` ```yaml
registry: registry:
path: shared/registry path: shared/registry
``` ```
...@@ -455,7 +453,7 @@ In the examples below we set the Registry's port to `5001`. ...@@ -455,7 +453,7 @@ In the examples below we set the Registry's port to `5001`.
1. Open the configuration file of your Registry server and edit the 1. Open the configuration file of your Registry server and edit the
[`http:addr`][registry-http-config] value: [`http:addr`][registry-http-config] value:
``` ```yaml
http http
addr: localhost:5001 addr: localhost:5001
``` ```
...@@ -512,7 +510,7 @@ You can use GitLab as an auth endpoint and use a non-bundled Container Registry. ...@@ -512,7 +510,7 @@ You can use GitLab as an auth endpoint and use a non-bundled Container Registry.
1. Open `/home/git/gitlab/config/gitlab.yml`, and edit the configuration settings under `registry`: 1. Open `/home/git/gitlab/config/gitlab.yml`, and edit the configuration settings under `registry`:
``` ```yaml
## Container Registry ## Container Registry
registry: registry:
...@@ -694,9 +692,9 @@ You can add a configuration option for backwards compatibility. ...@@ -694,9 +692,9 @@ You can add a configuration option for backwards compatibility.
A Docker connection error can occur when there are special characters in either the group, A Docker connection error can occur when there are special characters in either the group,
project or branch name. Special characters can include: project or branch name. Special characters can include:
* Leading underscore - Leading underscore
* Trailing hyphen/dash - Trailing hyphen/dash
* Double hyphen/dash - Double hyphen/dash
To get around this, you can [change the group path](../user/group/index.md#changing-a-groups-path), To get around this, you can [change the group path](../user/group/index.md#changing-a-groups-path),
[change the project path](../user/project/settings/index.md#renaming-a-repository) or change the [change the project path](../user/project/settings/index.md#renaming-a-repository) or change the
......
...@@ -30,6 +30,7 @@ Because Rubular doesn't understand `%{issue_ref}`, you can replace this by ...@@ -30,6 +30,7 @@ Because Rubular doesn't understand `%{issue_ref}`, you can replace this by
```ruby ```ruby
gitlab_rails['gitlab_issue_closing_pattern'] = "\b((?:[Cc]los(?:e[sd]|ing)|\b[Ff]ix(?:e[sd]|ing)?) +(?:(?:issues? +)?%{issue_ref}(?:(?:, *| +and +)?))+)" gitlab_rails['gitlab_issue_closing_pattern'] = "\b((?:[Cc]los(?:e[sd]|ing)|\b[Ff]ix(?:e[sd]|ing)?) +(?:(?:issues? +)?%{issue_ref}(?:(?:, *| +and +)?))+)"
``` ```
1. [Reconfigure] GitLab for the changes to take effect. 1. [Reconfigure] GitLab for the changes to take effect.
**For installations from source** **For installations from source**
......
# Jobs artifacts administration # Jobs artifacts administration
> **Notes:**
>
> - Introduced in GitLab 8.2 and GitLab Runner 0.7.0. > - Introduced in GitLab 8.2 and GitLab Runner 0.7.0.
> - Starting with GitLab 8.4 and GitLab Runner 1.0, the artifacts archive format changed to `ZIP`. > - Starting with GitLab 8.4 and GitLab Runner 1.0, the artifacts archive format changed to `ZIP`.
> - Starting with GitLab 8.17, builds are renamed to jobs. > - Starting with GitLab 8.17, builds are renamed to jobs.
...@@ -87,8 +85,6 @@ _The artifacts are stored by default in ...@@ -87,8 +85,6 @@ _The artifacts are stored by default in
### Using object storage ### Using object storage
> **Notes:**
>
> - [Introduced](https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/1762) in > - [Introduced](https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/1762) in
> [GitLab Premium](https://about.gitlab.com/pricing/) 9.4. > [GitLab Premium](https://about.gitlab.com/pricing/) 9.4.
> - Since version 9.5, artifacts are [browsable](../user/project/pipelines/job_artifacts.md#browsing-artifacts), > - Since version 9.5, artifacts are [browsable](../user/project/pipelines/job_artifacts.md#browsing-artifacts),
......
...@@ -27,7 +27,7 @@ To change the location where the job logs will be stored, follow the steps below ...@@ -27,7 +27,7 @@ To change the location where the job logs will be stored, follow the steps below
1. Edit `/etc/gitlab/gitlab.rb` and add or amend the following line: 1. Edit `/etc/gitlab/gitlab.rb` and add or amend the following line:
``` ```ruby
gitlab_ci['builds_directory'] = '/mnt/to/gitlab-ci/builds' gitlab_ci['builds_directory'] = '/mnt/to/gitlab-ci/builds'
``` ```
......
...@@ -43,6 +43,7 @@ To enable the Packages feature: ...@@ -43,6 +43,7 @@ To enable the Packages feature:
packages: packages:
enabled: true enabled: true
``` ```
1. [Restart GitLab] for the changes to take effect. 1. [Restart GitLab] for the changes to take effect.
## Changing the storage path ## Changing the storage path
...@@ -76,6 +77,7 @@ To change the local storage path: ...@@ -76,6 +77,7 @@ To change the local storage path:
enabled: true enabled: true
storage_path: shared/packages storage_path: shared/packages
``` ```
1. [Restart GitLab] for the changes to take effect. 1. [Restart GitLab] for the changes to take effect.
### Using object storage ### Using object storage
......
...@@ -18,7 +18,7 @@ The instructions make the assumption that you will be using the email address `i ...@@ -18,7 +18,7 @@ The instructions make the assumption that you will be using the email address `i
sudo apt-get install postfix sudo apt-get install postfix
``` ```
When asked about the environment, select 'Internet Site'. When asked to confirm the hostname, make sure it matches `gitlab.example.com`. When asked about the environment, select 'Internet Site'. When asked to confirm the hostname, make sure it matches gitlab.example.com`.
1. Install the `mailutils` package. 1. Install the `mailutils` package.
...@@ -179,15 +179,19 @@ Courier, which we will install later to add IMAP authentication, requires mailbo ...@@ -179,15 +179,19 @@ Courier, which we will install later to add IMAP authentication, requires mailbo
``` ```
And start `imapd`: And start `imapd`:
```sh ```sh
imapd start imapd start
``` ```
1. The courier-authdaemon isn't started after installation. Without it, imap authentication will fail: 1. The courier-authdaemon isn't started after installation. Without it, imap authentication will fail:
```sh ```sh
sudo service courier-authdaemon start sudo service courier-authdaemon start
``` ```
You can also configure courier-authdaemon to start on boot: You can also configure courier-authdaemon to start on boot:
```sh ```sh
sudo systemctl enable courier-authdaemon sudo systemctl enable courier-authdaemon
``` ```
......
...@@ -109,7 +109,7 @@ _The uploads are stored by default in ...@@ -109,7 +109,7 @@ _The uploads are stored by default in
``` ```
>**Note:** >**Note:**
If you are using AWS IAM profiles, be sure to omit the AWS access key and secret access key/value pairs. >If you are using AWS IAM profiles, be sure to omit the AWS access key and secret access key/value pairs.
```ruby ```ruby
gitlab_rails['uploads_object_store_connection'] = { gitlab_rails['uploads_object_store_connection'] = {
......
...@@ -121,9 +121,9 @@ Parameters: ...@@ -121,9 +121,9 @@ Parameters:
- `id` (required) - The ID or [URL-encoded path of the project](README.md#namespaced-path-encoding) owned by the authenticated user - `id` (required) - The ID or [URL-encoded path of the project](README.md#namespaced-path-encoding) owned by the authenticated user
- `sha` (optional) - The commit SHA to download. A tag, branch reference, or SHA can be used. This defaults to the tip of the default branch if not specified. For example: - `sha` (optional) - The commit SHA to download. A tag, branch reference, or SHA can be used. This defaults to the tip of the default branch if not specified. For example:
```sh ```sh
curl --header "PRIVATE-TOKEN: <your_access_token>" https://gitlab.com/api/v4/projects/<project_id>/repository/archive?sha=<commit_sha> curl --header "PRIVATE-TOKEN: <your_access_token>" https://gitlab.com/api/v4/projects/<project_id>/repository/archive?sha=<commit_sha>
``` ```
## Compare branches, tags or commits ## Compare branches, tags or commits
......
...@@ -484,9 +484,11 @@ When making a request to an HTTP Endpoint (think `/users/sign_in`) the request w ...@@ -484,9 +484,11 @@ When making a request to an HTTP Endpoint (think `/users/sign_in`) the request w
Below we describe the different pathing that HTTP vs. SSH Git requests will take. There is some overlap with the Web Request Cycle but also some differences. Below we describe the different pathing that HTTP vs. SSH Git requests will take. There is some overlap with the Web Request Cycle but also some differences.
### Web Request (80/443) ### Web Request (80/443)
TODO TODO
### SSH Request (22) ### SSH Request (22)
TODO TODO
## System Layout ## System Layout
...@@ -505,7 +507,9 @@ To summarize here's the [directory structure of the `git` user home directory](. ...@@ -505,7 +507,9 @@ To summarize here's the [directory structure of the `git` user home directory](.
### Processes ### Processes
ps aux | grep '^git' ```sh
ps aux | grep '^git'
```
GitLab has several components to operate. As a system user (i.e. any user that is not the `git` user) it requires a persistent database (MySQL/PostreSQL) and redis database. It also uses Apache httpd or Nginx to proxypass Unicorn. As the `git` user it starts Sidekiq and Unicorn (a simple ruby HTTP server running on port `8080` by default). Under the GitLab user there are normally 4 processes: `unicorn_rails master` (1 process), `unicorn_rails worker` (2 processes), `sidekiq` (1 process). GitLab has several components to operate. As a system user (i.e. any user that is not the `git` user) it requires a persistent database (MySQL/PostreSQL) and redis database. It also uses Apache httpd or Nginx to proxypass Unicorn. As the `git` user it starts Sidekiq and Unicorn (a simple ruby HTTP server running on port `8080` by default). Under the GitLab user there are normally 4 processes: `unicorn_rails master` (1 process), `unicorn_rails worker` (2 processes), `sidekiq` (1 process).
......
...@@ -1038,8 +1038,8 @@ to avoid conflicts during CE to EE merge. ...@@ -1038,8 +1038,8 @@ to avoid conflicts during CE to EE merge.
Until the work completed to merge the ce and ee codebases, which is tracked on [epic &802](https://gitlab.com/groups/gitlab-org/-/epics/802), there exists times in which some changes for EE require specific changes to the CE Until the work completed to merge the ce and ee codebases, which is tracked on [epic &802](https://gitlab.com/groups/gitlab-org/-/epics/802), there exists times in which some changes for EE require specific changes to the CE
code base. Examples of backports include the following: code base. Examples of backports include the following:
* Features intended or originally built for EE that are later decided to move to CE - Features intended or originally built for EE that are later decided to move to CE
* Sometimes some code in CE may impact the EE feature - Sometimes some code in CE may impact the EE feature
Here is a workflow to make sure those changes end up backported safely into CE too. Here is a workflow to make sure those changes end up backported safely into CE too.
......
...@@ -26,7 +26,7 @@ See the [Rails guides] for more info. ...@@ -26,7 +26,7 @@ See the [Rails guides] for more info.
feature and fill in the details for your specific IMAP server and email feature and fill in the details for your specific IMAP server and email
account: account:
Configuration for Gmail / Google Apps, assumes mailbox gitlab-incoming@gmail.com Configuration for Gmail / Google Apps, assumes mailbox `gitlab-incoming@gmail.com`:
```yaml ```yaml
incoming_email: incoming_email:
...@@ -91,10 +91,10 @@ for the format of the email key: ...@@ -91,10 +91,10 @@ for the format of the email key:
Examples of valid email keys: Examples of valid email keys:
- `gitlab-org-gitlab-ce-20-Author_Token12345678-issue` (create a new issue) - `gitlab-org-gitlab-ce-20-Author_Token12345678-issue` (create a new issue)
- `gitlab-org-gitlab-ce-20-Author_Token12345678-merge-request` (create a new merge request) - `gitlab-org-gitlab-ce-20-Author_Token12345678-merge-request` (create a new merge request)
- `1234567890abcdef1234567890abcdef-unsubscribe` (unsubscribe from a conversation) - `1234567890abcdef1234567890abcdef-unsubscribe` (unsubscribe from a conversation)
- `1234567890abcdef1234567890abcdef` (reply to a conversation) - `1234567890abcdef1234567890abcdef` (reply to a conversation)
Please note that the action `-issue-` is used in GitLab Premium as the handler for the Service Desk feature. Please note that the action `-issue-` is used in GitLab Premium as the handler for the Service Desk feature.
...@@ -103,10 +103,10 @@ Please note that the action `-issue-` is used in GitLab Premium as the handler f ...@@ -103,10 +103,10 @@ Please note that the action `-issue-` is used in GitLab Premium as the handler f
Although we continue to support the older legacy format, no new features should use a legacy format. Although we continue to support the older legacy format, no new features should use a legacy format.
These are the only valid legacy formats for an email handler: These are the only valid legacy formats for an email handler:
- `path/to/project+namespace` - `path/to/project+namespace`
- `path/to/project+namespace+action` - `path/to/project+namespace+action`
- `namespace` - `namespace`
- `namespace+action` - `namespace+action`
Please note that `path/to/project` is used in GitLab Premium as handler for the Service Desk feature. Please note that `path/to/project` is used in GitLab Premium as handler for the Service Desk feature.
......
...@@ -30,8 +30,8 @@ Completed 200 OK in 166ms (Views: 117.4ms | ActiveRecord: 27.2ms) ...@@ -30,8 +30,8 @@ Completed 200 OK in 166ms (Views: 117.4ms | ActiveRecord: 27.2ms)
These logs suffer from a number of problems: These logs suffer from a number of problems:
1. They often lack timestamps or other contextual information (e.g. project ID, user) 1. They often lack timestamps or other contextual information (e.g. project ID, user)
2. They may span multiple lines, which make them hard to find via Elasticsearch. 1. They may span multiple lines, which make them hard to find via Elasticsearch.
3. They lack a common structure, which make them hard to parse by log 1. They lack a common structure, which make them hard to parse by log
forwarders, such as Logstash or Fluentd. This also makes them hard to forwarders, such as Logstash or Fluentd. This also makes them hard to
search. search.
......
...@@ -95,7 +95,9 @@ Sherlock is a custom profiling tool built into GitLab. Sherlock is _only_ ...@@ -95,7 +95,9 @@ Sherlock is a custom profiling tool built into GitLab. Sherlock is _only_
available when running GitLab in development mode _and_ when setting the available when running GitLab in development mode _and_ when setting the
environment variable `ENABLE_SHERLOCK` to a non empty value. For example: environment variable `ENABLE_SHERLOCK` to a non empty value. For example:
ENABLE_SHERLOCK=1 bundle exec rails s ```sh
ENABLE_SHERLOCK=1 bundle exec rails s
```
Recorded transactions can be found by navigating to `/sherlock/transactions`. Recorded transactions can be found by navigating to `/sherlock/transactions`.
...@@ -106,7 +108,9 @@ Bullet adds quite a bit of logging noise it's disabled by default. To enable ...@@ -106,7 +108,9 @@ Bullet adds quite a bit of logging noise it's disabled by default. To enable
Bullet, set the environment variable `ENABLE_BULLET` to a non-empty value before Bullet, set the environment variable `ENABLE_BULLET` to a non-empty value before
starting GitLab. For example: starting GitLab. For example:
ENABLE_BULLET=true bundle exec rails s ```sh
ENABLE_BULLET=true bundle exec rails s
```
Bullet will log query problems to both the Rails log as well as the Chrome Bullet will log query problems to both the Rails log as well as the Chrome
console. console.
......
...@@ -7,11 +7,15 @@ support subgroups, GitLab project and group routes use the wildcard ...@@ -7,11 +7,15 @@ support subgroups, GitLab project and group routes use the wildcard
character to match project and group routes. For example, we might have character to match project and group routes. For example, we might have
a path such as: a path such as:
/gitlab-com/customer-success/north-america/west/customerA ```
/gitlab-com/customer-success/north-america/west/customerA
```
However, paths can be ambiguous. Consider the following example: However, paths can be ambiguous. Consider the following example:
/gitlab-com/edit ```
/gitlab-com/edit
```
It's ambiguous whether there is a subgroup named `edit` or whether It's ambiguous whether there is a subgroup named `edit` or whether
this is a special endpoint to edit the `gitlab-com` group. this is a special endpoint to edit the `gitlab-com` group.
...@@ -25,8 +29,10 @@ number of [reserved names](../user/reserved_names.md). ...@@ -25,8 +29,10 @@ number of [reserved names](../user/reserved_names.md).
We have a number of global routes. For example: We have a number of global routes. For example:
/-/health ```
/-/metrics /-/health
/-/metrics
```
## Group routes ## Group routes
...@@ -34,10 +40,12 @@ Every group route must be under the `/-/` scope. ...@@ -34,10 +40,12 @@ Every group route must be under the `/-/` scope.
Examples: Examples:
gitlab-org/-/edit ```
gitlab-org/-/activity gitlab-org/-/edit
gitlab-org/-/security/dashboard gitlab-org/-/activity
gitlab-org/serverless/-/activity gitlab-org/-/security/dashboard
gitlab-org/serverless/-/activity
```
To achieve that, use the `scope '-'` method. To achieve that, use the `scope '-'` method.
...@@ -48,10 +56,12 @@ client or other software requires something different. ...@@ -48,10 +56,12 @@ client or other software requires something different.
Examples: Examples:
gitlab-org/gitlab-ce/-/activity ```
gitlab-org/gitlab-ce/-/jobs/123 gitlab-org/gitlab-ce/-/activity
gitlab-org/gitlab-ce/-/settings/repository gitlab-org/gitlab-ce/-/jobs/123
gitlab-org/serverless/runtimes/-/settings/repository gitlab-org/gitlab-ce/-/settings/repository
gitlab-org/serverless/runtimes/-/settings/repository
```
Currently, only some project routes are placed under the `/-/` scope. However, Currently, only some project routes are placed under the `/-/` scope. However,
you can help us migrate more of them! To migrate project routes: you can help us migrate more of them! To migrate project routes:
......
...@@ -94,7 +94,9 @@ on the amount of data indexed). ...@@ -94,7 +94,9 @@ on the amount of data indexed).
To keep naming of these indexes consistent please use the following naming To keep naming of these indexes consistent please use the following naming
pattern: pattern:
index_TABLE_on_COLUMN_trigram ```
index_TABLE_on_COLUMN_trigram
```
For example, a GIN/trigram index for `issues.title` would be called For example, a GIN/trigram index for `issues.title` would be called
`index_issues_on_title_trigram`. `index_issues_on_title_trigram`.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment