Add latest changes from gitlab-org/gitlab@master
This commit is contained in:
parent
a1d7324742
commit
a51e52bf5b
|
@ -1 +1 @@
|
||||||
b2e2ec1069625c4a4f220b0ec72154b1f2bdf834
|
e4ff30e44b6ac21f33290bbe7a9cbbd42f98d4d1
|
||||||
|
|
|
@ -123,7 +123,7 @@ class GroupsController < Groups::ApplicationController
|
||||||
if Groups::UpdateService.new(@group, current_user, group_params).execute
|
if Groups::UpdateService.new(@group, current_user, group_params).execute
|
||||||
redirect_to edit_group_path(@group, anchor: params[:update_section]), notice: "Group '#{@group.name}' was successfully updated."
|
redirect_to edit_group_path(@group, anchor: params[:update_section]), notice: "Group '#{@group.name}' was successfully updated."
|
||||||
else
|
else
|
||||||
@group.path = @group.path_before_last_save || @group.path_was
|
@group.reset
|
||||||
render action: "edit"
|
render action: "edit"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -0,0 +1,5 @@
|
||||||
|
---
|
||||||
|
title: Prevent accidental group deletion if path rename fails
|
||||||
|
merge_request: 40353
|
||||||
|
author:
|
||||||
|
type: fixed
|
|
@ -0,0 +1,5 @@
|
||||||
|
---
|
||||||
|
title: Fix exception handling when a concurrent backup fails
|
||||||
|
merge_request: 40451
|
||||||
|
author:
|
||||||
|
type: fixed
|
|
@ -13,7 +13,7 @@ last_update: 2019-07-03
|
||||||
In a [basic configuration](../pipelines/pipeline_architectures.md#basic-pipelines), GitLab runs a pipeline each time
|
In a [basic configuration](../pipelines/pipeline_architectures.md#basic-pipelines), GitLab runs a pipeline each time
|
||||||
changes are pushed to a branch.
|
changes are pushed to a branch.
|
||||||
|
|
||||||
If you want the pipeline to run jobs **only** when merge requests are created or updated,
|
If you want the pipeline to run jobs **only** on commits to a branch that is associated with a merge request,
|
||||||
you can use *pipelines for merge requests*.
|
you can use *pipelines for merge requests*.
|
||||||
|
|
||||||
In the UI, these pipelines are labeled as `detached`. Otherwise, these pipelines appear the same
|
In the UI, these pipelines are labeled as `detached`. Otherwise, these pipelines appear the same
|
||||||
|
|
|
@ -26,4 +26,4 @@ all security features are configured by default.
|
||||||
To view a project's security configuration:
|
To view a project's security configuration:
|
||||||
|
|
||||||
1. Go to the project's home page.
|
1. Go to the project's home page.
|
||||||
1. In the left sidebar, go to **Security & Configuration** > **Configuration**.
|
1. In the left sidebar, go to **Security & Compliance** > **Configuration**.
|
||||||
|
|
|
@ -153,7 +153,7 @@ always take the latest SAST artifact available.
|
||||||
For a project that does not have a `.gitlab-ci.yml` file, you can enable SAST with a basic
|
For a project that does not have a `.gitlab-ci.yml` file, you can enable SAST with a basic
|
||||||
configuration using the **SAST Configuration** page:
|
configuration using the **SAST Configuration** page:
|
||||||
|
|
||||||
1. From the project's home page, go to **Security & Configuration** > **Configuration** in the
|
1. From the project's home page, go to **Security & Compliance** > **Configuration** in the
|
||||||
left sidebar.
|
left sidebar.
|
||||||
1. Click **Enable via Merge Request** on the Static Application Security Testing (SAST) row.
|
1. Click **Enable via Merge Request** on the Static Application Security Testing (SAST) row.
|
||||||
1. Enter the appropriate SAST details into the fields on the page. See [Available variables](#available-variables)
|
1. Enter the appropriate SAST details into the fields on the page. See [Available variables](#available-variables)
|
||||||
|
|
|
@ -182,12 +182,12 @@ module Backup
|
||||||
queue.push(project)
|
queue.push(project)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
raise errors.pop unless errors.empty?
|
||||||
|
ensure
|
||||||
queue.close
|
queue.close
|
||||||
ActiveSupport::Dependencies.interlock.permit_concurrent_loads do
|
ActiveSupport::Dependencies.interlock.permit_concurrent_loads do
|
||||||
threads.each(&:join)
|
threads.each(&:join)
|
||||||
end
|
end
|
||||||
|
|
||||||
raise errors.pop unless errors.empty?
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def dump_project(project)
|
def dump_project(project)
|
||||||
|
|
|
@ -41,11 +41,11 @@ module Gitlab
|
||||||
end
|
end
|
||||||
|
|
||||||
def self.keep_latest_artifacts_for_ref_enabled?(project)
|
def self.keep_latest_artifacts_for_ref_enabled?(project)
|
||||||
::Feature.enabled?(:keep_latest_artifacts_for_ref, project, default_enabled: false)
|
::Feature.enabled?(:keep_latest_artifacts_for_ref, project, default_enabled: true)
|
||||||
end
|
end
|
||||||
|
|
||||||
def self.destroy_only_unlocked_expired_artifacts_enabled?
|
def self.destroy_only_unlocked_expired_artifacts_enabled?
|
||||||
::Feature.enabled?(:destroy_only_unlocked_expired_artifacts, default_enabled: false)
|
::Feature.enabled?(:destroy_only_unlocked_expired_artifacts, default_enabled: true)
|
||||||
end
|
end
|
||||||
|
|
||||||
def self.bulk_insert_on_create?(project)
|
def self.bulk_insert_on_create?(project)
|
||||||
|
|
|
@ -555,6 +555,21 @@ RSpec.describe GroupsController do
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
context 'when there is a conflicting group path' do
|
||||||
|
render_views
|
||||||
|
|
||||||
|
let!(:conflict_group) { create(:group, path: SecureRandom.hex(12) ) }
|
||||||
|
let!(:old_name) { group.name }
|
||||||
|
|
||||||
|
it 'does not render references to the conflicting group' do
|
||||||
|
put :update, params: { id: group.to_param, group: { path: conflict_group.path } }
|
||||||
|
|
||||||
|
expect(response).to have_gitlab_http_status(:ok)
|
||||||
|
expect(group.reload.name).to eq(old_name)
|
||||||
|
expect(response.body).not_to include(conflict_group.path)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
context 'when a project inside the group has container repositories' do
|
context 'when a project inside the group has container repositories' do
|
||||||
before do
|
before do
|
||||||
stub_container_registry_config(enabled: true)
|
stub_container_registry_config(enabled: true)
|
||||||
|
|
|
@ -19,7 +19,7 @@ RSpec.describe Backup::Repository do
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
describe '#dump', quarantine: 'https://gitlab.com/gitlab-org/gitlab/-/issues/241251' do
|
describe '#dump' do
|
||||||
before do
|
before do
|
||||||
allow(Gitlab.config.repositories.storages).to receive(:keys).and_return(storage_keys)
|
allow(Gitlab.config.repositories.storages).to receive(:keys).and_return(storage_keys)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue