Add latest changes from gitlab-org/gitlab@master

This commit is contained in:
GitLab Bot 2021-10-09 00:12:30 +00:00
parent 59e6c2df22
commit 2c41816276
31 changed files with 66 additions and 42 deletions

View file

@ -0,0 +1,3 @@
import { initDiffStatsDropdown } from '~/init_diff_stats_dropdown';
initDiffStatsDropdown();

View file

@ -0,0 +1,3 @@
import { mountApplications } from '~/pages/shared/wikis/edit';
mountApplications();

View file

@ -0,0 +1,3 @@
import initClonePanel from '~/clone_panel';
initClonePanel();

View file

@ -1,5 +1,3 @@
import { initDiffStatsDropdown } from '~/init_diff_stats_dropdown';
import initWikis from '~/pages/shared/wikis';
import Wikis from '~/pages/shared/wikis/wikis';
initWikis();
initDiffStatsDropdown();
export default new Wikis();

View file

@ -0,0 +1,3 @@
import { mountApplications as mountEditApplications } from '~/pages/shared/wikis/async_edit';
mountEditApplications();

View file

@ -0,0 +1,11 @@
export const mountApplications = async () => {
const el = document.querySelector('.js-wiki-edit-page');
if (el) {
const { mountApplications: mountEditApplications } = await import(
/* webpackChunkName: 'wiki_edit' */ './edit'
);
mountEditApplications();
}
};

View file

@ -1,6 +1,5 @@
import $ from 'jquery';
import Vue from 'vue';
import ShortcutsWiki from '~/behaviors/shortcuts/shortcuts_wiki';
import { convertObjectPropsToCamelCase } from '~/lib/utils/common_utils';
import csrf from '~/lib/utils/csrf';
import Translate from '~/vue_shared/translate';
@ -9,14 +8,8 @@ import ZenMode from '../../../zen_mode';
import deleteWikiModal from './components/delete_wiki_modal.vue';
import wikiAlert from './components/wiki_alert.vue';
import wikiForm from './components/wiki_form.vue';
import Wikis from './wikis';
const createModalVueApp = () => {
new Wikis(); // eslint-disable-line no-new
new ShortcutsWiki(); // eslint-disable-line no-new
new ZenMode(); // eslint-disable-line no-new
new GLForm($('.wiki-form')); // eslint-disable-line no-new
const deleteWikiModalWrapperEl = document.getElementById('delete-wiki-modal-wrapper');
if (deleteWikiModalWrapperEl) {
@ -85,7 +78,10 @@ const createWikiFormApp = () => {
}
};
export default () => {
export const mountApplications = () => {
new ZenMode(); // eslint-disable-line no-new
new GLForm($('.wiki-form')); // eslint-disable-line no-new
createModalVueApp();
createAlertVueApp();
createWikiFormApp();

View file

@ -1,6 +1,7 @@
import { GlBreakpointInstance as bp } from '@gitlab/ui/dist/utils';
import Tracking from '~/tracking';
import showToast from '~/vue_shared/plugins/global_toast';
import ShortcutsWiki from '~/behaviors/shortcuts/shortcuts_wiki';
const TRACKING_EVENT_NAME = 'view_wiki_page';
const TRACKING_CONTEXT_SCHEMA = 'iglu:com.gitlab/wiki_page_context/jsonschema/1-0-1';
@ -20,6 +21,7 @@ export default class Wikis {
Wikis.trackPageView();
Wikis.showToasts();
Wikis.initShortcuts();
}
handleToggleSidebar(e) {
@ -64,4 +66,8 @@ export default class Wikis {
const toasts = document.querySelectorAll('.js-toast-message');
toasts.forEach((toast) => showToast(toast.dataset.message));
}
static initShortcuts() {
new ShortcutsWiki(); // eslint-disable-line no-new
}
}

View file

@ -4,7 +4,7 @@
- if @error
#js-wiki-error{ data: { error: @error, wiki_page_path: wiki_page_path(@wiki, @page) } }
.wiki-page-header.top-area.has-sidebar-toggle.flex-column.flex-lg-row
.js-wiki-edit-page.wiki-page-header.top-area.has-sidebar-toggle.flex-column.flex-lg-row
= wiki_sidebar_toggle_button
%h3.page-title.gl-flex-grow-1

View file

@ -6,7 +6,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w
# Web terminals **(FREE)**
With the introduction of the [Kubernetes integration](../../user/project/clusters/index.md),
With the introduction of the [Kubernetes integration](../../user/infrastructure/clusters/index.md),
GitLab can store and use credentials for a Kubernetes cluster.
GitLab uses these credentials to provide access to
[web terminals](../../ci/environments/index.md#web-terminals) for environments.

View file

@ -250,7 +250,7 @@ Parameters:
NOTE:
`name`, `api_url`, `ca_cert` and `token` can only be updated if the cluster was added
through the ["Add existing Kubernetes cluster"](../user/project/clusters/add_remove_clusters.md#add-existing-cluster) option or
through the ["Add existing Kubernetes cluster"](../user/project/clusters/add_existing_cluster.md) option or
through the ["Add existing cluster to group"](#add-existing-cluster-to-group) endpoint.
Example request:

View file

@ -8,7 +8,9 @@ info: To determine the technical writer assigned to the Stage/Group associated w
> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/36001) in GitLab 13.2.
Instance-level Kubernetes clusters allow you to connect a Kubernetes cluster to the GitLab instance, which enables you to use the same cluster across multiple projects. [More information](../user/instance/clusters/index.md)
With [instance-level Kubernetes clusters](../user/instance/clusters/index.md),
you can connect a Kubernetes cluster to the GitLab instance and use the same cluster across all of
the projects within your instance.
NOTE:
Users need the Administrator role to use these endpoints.
@ -240,7 +242,7 @@ Parameters:
NOTE:
`name`, `api_url`, `ca_cert` and `token` can only be updated if the cluster was added
through the [Add existing Kubernetes cluster](../user/project/clusters/add_remove_clusters.md#add-existing-cluster) option or
through the [Add existing Kubernetes cluster](../user/project/clusters/add_existing_cluster.md) option or
through the [Add existing instance cluster](#add-existing-instance-cluster) endpoint.
Example request:

View file

@ -19,7 +19,7 @@ GitLab:
- Tracks your deployments, so you always know what is deployed on your
servers.
If you have a deployment service like [Kubernetes](../../user/project/clusters/index.md)
If you have a deployment service like [Kubernetes](../../user/infrastructure/clusters/index.md)
associated with your project, you can use it to assist with your deployments.
You can even access a [web terminal](#web-terminals) for your environment from within GitLab.
@ -175,7 +175,7 @@ You can find the play button in the pipelines, environments, deployments, and jo
> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/27630) in GitLab 12.6.
If you are deploying to a [Kubernetes cluster](../../user/project/clusters/index.md)
If you are deploying to a [Kubernetes cluster](../../user/infrastructure/clusters/index.md)
associated with your project, you can configure these deployments from your
`.gitlab-ci.yml` file.
@ -634,7 +634,7 @@ Metric charts can be embedded in GitLab Flavored Markdown. See [Embedding Metric
### Web terminals
If you deploy to your environments with the help of a deployment service (for example,
the [Kubernetes integration](../../user/project/clusters/index.md)), GitLab can open
the [Kubernetes integration](../../user/infrastructure/clusters/index.md)), GitLab can open
a terminal session to your environment. You can then debug issues without leaving your web browser.
The Web terminal is a container-based deployment, which often lack basic tools (like an editor),

View file

@ -65,7 +65,7 @@ GitLab CI/CD supports numerous configuration options:
| [SSH keys for CI/CD](ssh_keys/index.md) | Using SSH keys in your CI pipelines. |
| [Pipeline triggers](triggers/index.md) | Trigger pipelines through the API. |
| [Pipelines for Merge Requests](pipelines/merge_request_pipelines.md) | Design a pipeline structure for running a pipeline in merge requests. |
| [Integrate with Kubernetes clusters](../user/project/clusters/index.md) | Connect your project to Google Kubernetes Engine (GKE) or an existing Kubernetes cluster. |
| [Integrate with Kubernetes clusters](../user/infrastructure/clusters/index.md) | Connect your project to Google Kubernetes Engine (GKE) or an existing Kubernetes cluster. |
| [Optimize GitLab and GitLab Runner for large repositories](large_repositories/index.md) | Recommended strategies for handling large repositories. |
| [`.gitlab-ci.yml` full reference](yaml/index.md) | All the attributes you can use with GitLab CI/CD. |

View file

@ -2224,7 +2224,7 @@ For more information, see
> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/27630) in GitLab 12.6.
Use the `kubernetes` keyword to configure deployments to a
[Kubernetes cluster](../../user/project/clusters/index.md) that is associated with your project.
[Kubernetes cluster](../../user/infrastructure/clusters/index.md) that is associated with your project.
For example:

View file

@ -7,7 +7,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w
# Kubernetes integration - development guidelines **(FREE)**
This document provides various guidelines when developing for the GitLab
[Kubernetes integration](../user/project/clusters/index.md).
[Kubernetes integration](../user/infrastructure/clusters/index.md).
## Development

View file

@ -196,7 +196,7 @@ subgraph "CNG-mirror pipeline"
stop a Review App manually, and is also started by GitLab once a merge
request's branch is deleted after being merged.
- The Kubernetes cluster is connected to the `gitlab` projects using the
[GitLab Kubernetes integration](../../user/project/clusters/index.md). This basically
[GitLab Kubernetes integration](../../user/infrastructure/clusters/index.md). This basically
allows to have a link to the Review App directly from the merge request widget.
### Auto-stopping of Review Apps

View file

@ -41,7 +41,7 @@ In Google's side:
1. You should now be able to see a Client ID and Client secret. Note them down
or keep this page open as you need them later.
1. To enable projects to access [Google Kubernetes Engine](../user/project/clusters/index.md), you must also
1. To enable projects to access [Google Kubernetes Engine](../user/infrastructure/clusters/index.md), you must also
enable these APIs:
- Google Kubernetes Engine API
- Cloud Resource Manager API

View file

@ -94,6 +94,6 @@ an environment.
## More features
- Deploy to different [environments](../ci/environments/index.md).
- Connect your project to a [Kubernetes cluster](../user/project/clusters/index.md).
- Connect your project to a [Kubernetes cluster](../user/infrastructure/clusters/index.md).
- See how your application is used and analyze events with [Product Analytics](product_analytics.md).
- Create, toggle, and remove [Feature Flags](feature_flags.md).

View file

@ -30,7 +30,7 @@ This dashboard requires Kubernetes v1.14 or higher, due to the
in Kubernetes 1.14.
This dashboard displays CPU, memory, network and disk metrics for the pods in your
[connected K8s cluster](../../../user/project/clusters/index.md). It provides a
[connected Kubernetes cluster](../../../user/infrastructure/clusters/index.md). It provides a
[variable selector](templating_variables.md#metric_label_values-variable-type)
at the top of the dashboard to select which pod's metrics to display.

View file

@ -1335,7 +1335,7 @@ that contain required, sensitive information. If the key is lost, GitLab can't
decrypt those columns, preventing access to the following items:
- [CI/CD variables](../ci/variables/index.md)
- [Kubernetes / GCP integration](../user/project/clusters/index.md)
- [Kubernetes / GCP integration](../user/infrastructure/clusters/index.md)
- [Custom Pages domains](../user/project/pages/custom_domains_ssl_tls_certification/index.md)
- [Project error tracking](../operations/error_tracking.md)
- [Runner authentication](../ci/runners/index.md)

View file

@ -97,9 +97,8 @@ To make full use of Auto DevOps with Kubernetes, you need:
To enable deployments, you need:
1. A [Kubernetes 1.12+ cluster](../../user/project/clusters/index.md) for your
project. The easiest way is to create a
[new cluster using the GitLab UI](../../user/project/clusters/add_remove_clusters.md#create-new-cluster).
1. A [Kubernetes 1.12+ cluster](../../user/infrastructure/clusters/index.md) for your
project.
For Kubernetes 1.16+ clusters, you must perform additional configuration for
[Auto Deploy for Kubernetes 1.16+](stages.md#kubernetes-116).
1. For external HTTP traffic, an Ingress controller is required. For regular

View file

@ -13,4 +13,4 @@ code, and use CI/CD to generate your application. Include packages in your app a
- [Merge requests](../user/project/merge_requests/index.md)
- [CI/CD](../ci/index.md)
- [Packages & Registries](../user/packages/index.md)
- [Application infrastructure](../user/project/clusters/index.md)
- [Application infrastructure](../user/infrastructure/index.md)

View file

@ -60,7 +60,7 @@ differentiate the new cluster from your other clusters.
You can choose to allow GitLab to manage your cluster for you. If GitLab manages
your cluster, resources for your projects are automatically created. See the
[Access controls](../../project/clusters/add_remove_clusters.md#access-controls)
[Access controls](../../project/clusters/cluster_access.md)
section for details on which resources GitLab creates for you.
For clusters not managed by GitLab, project-specific resources aren't created
@ -172,7 +172,7 @@ documentation for project-level clusters.
## More information
For information on integrating GitLab and Kubernetes, see
[Kubernetes clusters](../../project/clusters/index.md).
[Kubernetes clusters](../../infrastructure/clusters/index.md).
<!-- ## Troubleshooting

View file

@ -35,7 +35,7 @@ DevSecOps pipeline by default targeted at Kubernetes based deployments. To suppo
all the GitLab features, GitLab offers a cluster management project for easy onboarding.
The deploy boards provide quick insights into your cluster, including pod logs tailing.
Learn more about the [GitLab integration with Kubernetes](../project/clusters/index.md).
Learn more about the [GitLab integration with Kubernetes](clusters/index.md).
## Runbooks in GitLab

View file

@ -39,4 +39,4 @@ are deployed to the Kubernetes cluster, see the documentation for
## More information
For information on integrating GitLab and Kubernetes, see
[Kubernetes clusters](../../project/clusters/index.md).
[Kubernetes clusters](../../infrastructure/clusters/index.md).

View file

@ -72,8 +72,8 @@ The following table lists project permissions available for each role:
| [CI/CD](../ci/index.md):<br>Run Web IDE's Interactive Web Terminals **(ULTIMATE ONLY)** | | | | ✓ | ✓ |
| [CI/CD](../ci/index.md):<br>Use [environment terminals](../ci/environments/index.md#web-terminals) | | | | ✓ | ✓ |
| [CI/CD](../ci/index.md):<br>Delete pipelines | | | | | ✓ |
| [Clusters](project/clusters/index.md):<br>View pod logs | | | ✓ | ✓ | ✓ |
| [Clusters](project/clusters/index.md):<br>Manage clusters | | | | ✓ | ✓ |
| [Clusters](infrastructure/clusters/index.md):<br>View [pod logs](project/clusters/kubernetes_pod_logs.md) | | | ✓ | ✓ | ✓ |
| [Clusters](infrastructure/clusters/index.md):<br>Manage clusters | | | | ✓ | ✓ |
| [Container Registry](packages/container_registry/index.md):<br>Create, edit, delete cleanup policies | | | ✓ | ✓ | ✓ |
| [Container Registry](packages/container_registry/index.md):<br>Remove a container registry image | | | ✓ | ✓ | ✓ |
| [Container Registry](packages/container_registry/index.md):<br>Update container registry | | | ✓ | ✓ | ✓ |

View file

@ -90,7 +90,7 @@ canary deployment is promoted to production.
Here's an example setup flow from scratch:
1. Prepare an [Auto DevOps-enabled](../../topics/autodevops/index.md) project.
1. Set up a [Kubernetes Cluster](../../user/project/clusters/index.md) in your project.
1. Set up a [Kubernetes Cluster](../../user/infrastructure/clusters/index.md) in your project.
1. Install [NGINX Ingress](https://github.com/kubernetes/ingress-nginx/tree/master/charts/ingress-nginx) in your cluster.
1. Set up [the base domain](../../user/project/clusters/gitlab_managed_clusters.md#base-domain) based on the Ingress
Endpoint assigned above.

View file

@ -90,7 +90,7 @@ To display the deploy boards for a specific [environment](../../ci/environments/
1. [Configure GitLab Runner](../../ci/runners/index.md) with the [`docker`](https://docs.gitlab.com/runner/executors/docker.html) or
[`kubernetes`](https://docs.gitlab.com/runner/executors/kubernetes.html) executor.
1. Configure the [Kubernetes integration](clusters/index.md) in your project for the
1. Configure the [Kubernetes integration](../infrastructure/clusters/index.md) in your project for the
cluster. The Kubernetes namespace is of particular note as you need it
for your deployment scripts (exposed by the `KUBE_NAMESPACE` deployment variable).
1. Ensure Kubernetes annotations of `app.gitlab.com/env: $CI_ENVIRONMENT_SLUG`

View file

@ -81,7 +81,7 @@ Projects include the following [features](https://about.gitlab.com/features/):
browse, and download job artifacts.
- [Pipeline settings](../../ci/pipelines/settings.md): Set up Git strategy (how jobs fetch your repository),
timeout (the maximum amount of time a job can run), custom path for `.gitlab-ci.yml`, test coverage parsing, pipeline visibility, and more.
- [Kubernetes cluster integration](clusters/index.md): Connect your GitLab project
- [Kubernetes cluster integration](../infrastructure/clusters/index.md): Connect your GitLab project
with a Kubernetes cluster.
- [Feature Flags](../../operations/feature_flags.md): Ship different features
by dynamically toggling functionality. **(PREMIUM)**

View file

@ -12,7 +12,7 @@ GitLab has support for automatically detecting and monitoring Kubernetes metrics
## Requirements
The [Prometheus](../prometheus.md) and [Kubernetes](../../clusters/index.md)
The [Prometheus](../prometheus.md) and [Kubernetes](../../../infrastructure/clusters/index.md)
integration services must be enabled.
## Metrics supported