Skip to content
Snippets Groups Projects
Commit c384315a authored by GitLab Bot's avatar GitLab Bot
Browse files

Add latest changes from gitlab-org/gitlab@master

parent e1e017dd
No related branches found
No related tags found
No related merge requests found
Showing
with 214 additions and 70 deletions
Loading
Loading
@@ -3,7 +3,7 @@
class InstanceStatistics::ConversationalDevelopmentIndexController < InstanceStatistics::ApplicationController
# rubocop: disable CodeReuse/ActiveRecord
def index
@metric = ConversationalDevelopmentIndex::Metric.order(:created_at).last&.present
@metric = DevOpsScore::Metric.order(:created_at).last&.present
end
# rubocop: enable CodeReuse/ActiveRecord
end
# frozen_string_literal: true
 
module ConversationalDevelopmentIndexHelper
module DevOpsScoreHelper
def score_level(score)
if score < 33.33
'low'
Loading
Loading
# frozen_string_literal: true
 
module ConversationalDevelopmentIndex
module DevOpsScore
class Card
attr_accessor :metric, :title, :description, :feature, :blog, :docs
 
Loading
Loading
# frozen_string_literal: true
 
module ConversationalDevelopmentIndex
module DevOpsScore
class IdeaToProductionStep
attr_accessor :metric, :title, :features
 
Loading
Loading
# frozen_string_literal: true
 
module ConversationalDevelopmentIndex
module DevOpsScore
class Metric < ApplicationRecord
include Presentable
 
Loading
Loading
# frozen_string_literal: true
 
module ConversationalDevelopmentIndex
module DevOpsScore
class MetricPresenter < Gitlab::View::Presenter::Simple
def cards
[
Loading
Loading
Loading
Loading
@@ -38,7 +38,7 @@ class SubmitUsagePingService
def store_metrics(response)
return unless response['conv_index'].present?
 
ConversationalDevelopmentIndex::Metric.create!(
DevOpsScore::Metric.create!(
response['conv_index'].slice(*METRICS)
)
end
Loading
Loading
---
title: CI template for installing cluster applications
merge_request: 20822
author:
type: added
---
title: Move operations project routes under - scope
merge_request: 20456
author:
type: deprecated
---
title: Add e2e qa test for email delivery
merge_request: 20675
author: Diego Louzán
type: other
Loading
Loading
@@ -209,6 +209,55 @@ constraints(::Constraints::ProjectUrlConstrainer.new) do
get :production
end
end
concerns :clusterable
namespace :serverless do
scope :functions do
get '/:environment_id/:id', to: 'functions#show'
get '/:environment_id/:id/metrics', to: 'functions#metrics', as: :metrics
end
resources :functions, only: [:index]
end
resources :environments, except: [:destroy] do
member do
post :stop
get :terminal
get :metrics
get :additional_metrics
get :metrics_dashboard
get '/terminal.ws/authorize', to: 'environments#terminal_websocket_authorize', constraints: { format: nil }
get '/prometheus/api/v1/*proxy_path', to: 'environments/prometheus_api#proxy', as: :prometheus_api
end
collection do
get :metrics, action: :metrics_redirect
get :folder, path: 'folders/*id', constraints: { format: /(html|json)/ }
get :search
end
resources :deployments, only: [:index] do
member do
get :metrics
get :additional_metrics
end
end
end
resources :error_tracking, only: [:index], controller: :error_tracking do
collection do
get ':issue_id/details',
to: 'error_tracking#details',
as: 'details'
get ':issue_id/stack_trace',
to: 'error_tracking#stack_trace',
as: 'stack_trace'
post :list_projects
end
end
end
# End of the /-/ scope.
 
Loading
Loading
@@ -373,43 +422,6 @@ constraints(::Constraints::ProjectUrlConstrainer.new) do
end
end
 
concerns :clusterable
resources :environments, except: [:destroy] do
member do
post :stop
get :terminal
get :metrics
get :additional_metrics
get :metrics_dashboard
get '/terminal.ws/authorize', to: 'environments#terminal_websocket_authorize', constraints: { format: nil }
get '/prometheus/api/v1/*proxy_path', to: 'environments/prometheus_api#proxy', as: :prometheus_api
end
collection do
get :metrics, action: :metrics_redirect
get :folder, path: 'folders/*id', constraints: { format: /(html|json)/ }
get :search
end
resources :deployments, only: [:index] do
member do
get :metrics
get :additional_metrics
end
end
end
namespace :serverless do
scope :functions do
get '/:environment_id/:id', to: 'functions#show'
get '/:environment_id/:id/metrics', to: 'functions#metrics', as: :metrics
end
resources :functions, only: [:index]
end
draw :legacy_builds
 
resources :hooks, only: [:index, :create, :edit, :update, :destroy], constraints: { id: /\d+/ } do
Loading
Loading
@@ -507,18 +519,6 @@ constraints(::Constraints::ProjectUrlConstrainer.new) do
end
end
 
resources :error_tracking, only: [:index], controller: :error_tracking do
collection do
get ':issue_id/details',
to: 'error_tracking#details',
as: 'details'
get ':issue_id/stack_trace',
to: 'error_tracking#stack_trace',
as: 'stack_trace'
post :list_projects
end
end
scope :usage_ping, controller: :usage_ping do
post :web_ide_clientside_preview
end
Loading
Loading
@@ -540,7 +540,9 @@ constraints(::Constraints::ProjectUrlConstrainer.new) do
:project_members, :deploy_keys, :deploy_tokens,
:labels, :milestones, :services, :boards, :releases,
:forks, :group_links, :import, :avatar, :mirror,
:cycle_analytics, :mattermost, :variables, :triggers)
:cycle_analytics, :mattermost, :variables, :triggers,
:environments, :protected_environments, :error_tracking,
:serverless, :clusters, :audit_events)
end
 
# rubocop: disable Cop/PutProjectRoutesUnderScope
Loading
Loading
Gitlab::Seeder.quiet do
conversational_development_index_metric = ConversationalDevelopmentIndex::Metric.new(
dev_ops_score_metric = DevOpsScore::Metric.new(
leader_issues: 10.2,
instance_issues: 3.2,
 
Loading
Loading
@@ -31,10 +31,10 @@ Gitlab::Seeder.quiet do
instance_service_desk_issues: 15.1
)
 
if conversational_development_index_metric.save
if dev_ops_score_metric.save
print '.'
else
puts conversational_development_index_metric.errors.full_messages
puts dev_ops_score_metric.errors.full_messages
print 'F'
end
end
Loading
Loading
@@ -4,12 +4,18 @@ type: reference
 
# Smartcard authentication **(PREMIUM ONLY)**
 
> [Introduced](https://gitlab.com/gitlab-org/gitlab/issues/33669) in GitLab 12.6,
if a user has a pre-existing username and password, they can still use that to log
in by default. However, this can be disabled.
GitLab supports authentication using smartcards.
 
## Existing password authentication
> [Introduced](https://gitlab.com/gitlab-org/gitlab/issues/33669) in GitLab 12.6.
By default, existing users can continue to log in with a username and password when smartcard
authentication is enabled.
To force existing users to use only smartcard authentication,
[disable username and password authentication](../../user/admin_area/settings/sign_in_restrictions.md#password-authentication-enabled).
## Authentication methods
 
GitLab supports two authentication methods:
Loading
Loading
@@ -88,10 +94,7 @@ Certificate:
 
### Authentication against an LDAP server
 
> [Introduced](https://gitlab.com/gitlab-org/gitlab/issues/7693) in
[GitLab Premium](https://about.gitlab.com/pricing/) 11.8 as an experimental
feature. Smartcard authentication against an LDAP server may change or be
removed completely in future releases.
> [Introduced](https://gitlab.com/gitlab-org/gitlab/issues/7693) in [GitLab Premium](https://about.gitlab.com/pricing/) 11.8 as an experimental feature. Smartcard authentication against an LDAP server may change or be removed completely in future releases.
 
GitLab implements a standard way of certificate matching following
[RFC4523](https://tools.ietf.org/html/rfc4523). It uses the
Loading
Loading
Loading
Loading
@@ -78,7 +78,7 @@ document.addEventListener('DOMContentLoaded', () => new Vue({
render(createElement) {
return createElement('my-component', {
props: {
endpoint: this.isLoading,
endpoint: this.endpoint,
},
});
},
Loading
Loading
Loading
Loading
@@ -429,6 +429,69 @@ administrator to run following command within a Rails console:
Feature.enable(:enable_cluster_application_crossplane)
```
 
## Install using GitLab CI (alpha)
> [Introduced](https://gitlab.com/gitlab-org/gitlab/merge_requests/20822) in GitLab 12.6.
CAUTION: **Warning:**
This is an _alpha_ feature, and it is subject to change at any time without
prior notice.
This alternative method allows users to install GitLab-managed
applications using GitLab CI. It also allows customization of the
install using Helm `values.yaml` files.
Supported applications:
- [Ingress](#install-ingress-using-gitlab-ci)
### Usage
To install applications using GitLab CI:
1. Connect the cluster to a [cluster management project](management_project.md).
1. In that project, add a `.gitlab-ci.yml` file with the following content:
```yaml
include:
- template: Managed-Cluster-Applications.gitlab-ci.yml
```
1. Add a `.gitlab/managed-apps/config.yaml` file to define which
applications you would like to install. Define the `installed` key as
`true` to install the application and `false` to uninstall the
application. For example, to install Ingress:
```yaml
ingress:
installed: true
```
1. Optionally, define `.gitlab/managed-apps/<application>/values.yaml` file to
customize values for the installed application.
A GitLab CI pipeline will then run on the `master` branch to install the
applications you have configured.
### Install Ingress using GitLab CI
To install ingress, define the `.gitlab/managed-apps/config.yaml` file
with:
```yaml
ingress:
installed: true
```
Ingress will then be installed into the `gitlab-managed-apps` namespace
of your cluster.
You can customize the installation of Ingress by defining
`.gitlab/managed-apps/ingress/values.yaml` file in your cluster
management project. Refer to the
[chart](https://github.com/helm/charts/tree/master/stable/nginx-ingress)
for the available configuration options.
## Upgrading applications
 
> [Introduced](https://gitlab.com/gitlab-org/gitlab-foss/merge_requests/24789) in GitLab 11.8.
Loading
Loading
Loading
Loading
@@ -481,7 +481,7 @@ It is possible to display metrics charts within [GitLab Flavored Markdown](../..
NOTE: **Note:**
Requires [Kubernetes](prometheus_library/kubernetes.md) metrics.
 
To display a metric chart, include a link of the form `https://<root_url>/<project>/environments/<environment_id>/metrics`.
To display a metric chart, include a link of the form `https://<root_url>/<project>/-/environments/<environment_id>/metrics`.
 
A single chart may also be embedded. You can generate a link to the chart via the dropdown located on the right side of the chart:
 
Loading
Loading
apply:
stage: deploy
image: "registry.gitlab.com/gitlab-org/cluster-integration/cluster-applications:v0.1.0"
environment:
name: production
variables:
TILLER_NAMESPACE: gitlab-managed-apps
GITLAB_MANAGED_APPS_FILE: $CI_PROJECT_DIR/.gitlab/managed-apps/config.yaml
INGRESS_VALUES_FILE: $CI_PROJECT_DIR/.gitlab/managed-apps/ingress/values.yaml
script:
- gitlab-managed-apps /usr/local/share/gitlab-managed-apps/helmfile.yaml
only:
refs:
- master
Loading
Loading
@@ -15,6 +15,7 @@ module QA
#
module Flow
autoload :Login, 'qa/flow/login'
autoload :Project, 'qa/flow/project'
end
 
##
Loading
Loading
@@ -33,6 +34,7 @@ module QA
autoload :Fixtures, 'qa/runtime/fixtures'
autoload :Logger, 'qa/runtime/logger'
autoload :GPG, 'qa/runtime/gpg'
autoload :MailHog, 'qa/runtime/mail_hog'
 
module API
autoload :Client, 'qa/runtime/api/client'
Loading
Loading
@@ -130,6 +132,7 @@ module QA
autoload :Kubernetes, 'qa/scenario/test/integration/kubernetes'
autoload :Mattermost, 'qa/scenario/test/integration/mattermost'
autoload :ObjectStorage, 'qa/scenario/test/integration/object_storage'
autoload :SMTP, 'qa/scenario/test/integration/smtp'
end
 
module Sanity
Loading
Loading
@@ -422,6 +425,7 @@ module QA
autoload :Maven, 'qa/service/docker_run/maven'
autoload :NodeJs, 'qa/service/docker_run/node_js'
autoload :GitlabRunner, 'qa/service/docker_run/gitlab_runner'
autoload :MailHog, 'qa/service/docker_run/mail_hog'
end
end
 
Loading
Loading
# frozen_string_literal: true
module QA
module Flow
module Project
module_function
def add_member(project:, username:)
project.visit!
Page::Project::Menu.perform(&:go_to_members_settings)
Page::Project::Settings::Members.perform do |member_settings|
member_settings.add_member(username)
end
end
end
end
end
Loading
Loading
@@ -156,6 +156,8 @@ module QA
def perform(&block)
visit(url)
 
simulate_slow_connection if Runtime::Env.simulate_slow_connection?
page_class.validate_elements_present!
 
if QA::Runtime::Env.qa_cookies
Loading
Loading
@@ -178,6 +180,28 @@ module QA
def clear!
visit(url)
reset_session!
@network_conditions_configured = false
end
private
def simulate_slow_connection
return if @network_conditions_configured
QA::Runtime::Logger.info(
<<~MSG.tr("\n", " ")
Simulating a slow connection with additional latency
of #{Runtime::Env.slow_connection_latency} ms and a maximum
throughput of #{Runtime::Env.slow_connection_throughput} kbps
MSG
)
Capybara.current_session.driver.browser.network_conditions = {
latency: Runtime::Env.slow_connection_latency,
throughput: Runtime::Env.slow_connection_throughput * 1000
}
@network_conditions_configured = true
end
end
end
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment