Add latest changes from gitlab-org/gitlab@master
This commit is contained in:
parent
1c4773ed84
commit
c7ad2610df
|
|
@ -102,6 +102,7 @@
|
|||
"PostgreSQL",
|
||||
"Prometheus",
|
||||
"Puma",
|
||||
"puma-worker-killer",
|
||||
"Python",
|
||||
"Rake",
|
||||
"Redis",
|
||||
|
|
|
|||
|
|
@ -177,7 +177,7 @@ export default {
|
|||
@cancel="cancel"
|
||||
@submit="submit"
|
||||
>
|
||||
<template slot="body">
|
||||
<template #body>
|
||||
<p v-if="isDeleteForm">{{ __('Are you sure you want to delete this board?') }}</p>
|
||||
<form v-else class="js-board-config-modal" @submit.prevent>
|
||||
<div v-if="!readonly" class="append-bottom-20">
|
||||
|
|
|
|||
|
|
@ -115,7 +115,7 @@ export default {
|
|||
v-for="tabView in aliveTabViews"
|
||||
v-show="isActiveView(tabView.name)"
|
||||
:key="tabView.name"
|
||||
class="flex-fill js-tab-view"
|
||||
class="flex-fill gl-overflow-hidden js-tab-view"
|
||||
>
|
||||
<component :is="tabView.component" />
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -225,7 +225,7 @@ export function insertMarkdownText({
|
|||
} else if (tag.indexOf(textPlaceholder) > -1) {
|
||||
textToInsert = tag.replace(textPlaceholder, selected);
|
||||
} else {
|
||||
textToInsert = String(startChar) + tag + selected + (wrap ? tag : ' ');
|
||||
textToInsert = String(startChar) + tag + selected + (wrap ? tag : '');
|
||||
}
|
||||
|
||||
if (removedFirstNewLine) {
|
||||
|
|
|
|||
|
|
@ -258,7 +258,7 @@ export default {
|
|||
<note-header v-once :author="author" :created-at="note.created_at" :note-id="note.id">
|
||||
<slot slot="note-header-info" name="note-header-info"></slot>
|
||||
<span v-if="commit" v-html="actionText"></span>
|
||||
<span v-else class="d-none d-sm-inline">·</span>
|
||||
<span v-else-if="note.created_at" class="d-none d-sm-inline">·</span>
|
||||
</note-header>
|
||||
<note-actions
|
||||
:author-id="author.id"
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ Once deleted, it cannot be undone or recovered.`),
|
|||
kind="danger"
|
||||
@submit="onSubmit"
|
||||
>
|
||||
<template slot="body" slot-scope="props">
|
||||
<template #body="props">
|
||||
<p v-html="props.text"></p>
|
||||
</template>
|
||||
</deprecated-modal>
|
||||
|
|
|
|||
|
|
@ -110,6 +110,7 @@ export default {
|
|||
<gl-new-dropdown
|
||||
:text="dropdownText"
|
||||
:disabled="hasSearchParam"
|
||||
toggle-class="gl-py-3"
|
||||
class="gl-dropdown w-100 mt-2 mt-sm-0"
|
||||
>
|
||||
<gl-new-dropdown-header>
|
||||
|
|
|
|||
|
|
@ -9,6 +9,10 @@ table {
|
|||
* This is a temporary workaround until we fix the neutral
|
||||
* color palette in https://gitlab.com/gitlab-org/gitlab/-/issues/213570
|
||||
*
|
||||
* The overwrites here affected the security dashboard tables, when removing
|
||||
* this code, table-th-transparent and original-text-color classes should
|
||||
* be removed there.
|
||||
*
|
||||
* Remove this code as soon as this happens
|
||||
*/
|
||||
&.gl-table {
|
||||
|
|
@ -54,6 +58,11 @@ table {
|
|||
background: none;
|
||||
color: $gl-text-color-secondary;
|
||||
}
|
||||
|
||||
&.original-gl-th {
|
||||
@include gl-text-gray-700;
|
||||
border-bottom: 1px solid $cycle-analytics-light-gray;
|
||||
}
|
||||
}
|
||||
|
||||
td {
|
||||
|
|
|
|||
|
|
@ -186,7 +186,6 @@ class Projects::BranchesController < Projects::ApplicationController
|
|||
end
|
||||
|
||||
def confidential_issue_project
|
||||
return unless helpers.create_confidential_merge_request_enabled?
|
||||
return if params[:confidential_issue_project_id].blank?
|
||||
|
||||
confidential_issue_project = Project.find(params[:confidential_issue_project_id])
|
||||
|
|
|
|||
|
|
@ -187,7 +187,7 @@ class Projects::IssuesController < Projects::ApplicationController
|
|||
|
||||
def create_merge_request
|
||||
create_params = params.slice(:branch_name, :ref).merge(issue_iid: issue.iid)
|
||||
create_params[:target_project_id] = params[:target_project_id] if helpers.create_confidential_merge_request_enabled?
|
||||
create_params[:target_project_id] = params[:target_project_id]
|
||||
result = ::MergeRequests::CreateFromIssueService.new(project, current_user, create_params).execute
|
||||
|
||||
if result[:status] == :success
|
||||
|
|
|
|||
|
|
@ -9,6 +9,10 @@ module Resolvers
|
|||
required: false,
|
||||
description: 'Filter milestones by state'
|
||||
|
||||
argument :include_descendants, GraphQL::BOOLEAN_TYPE,
|
||||
required: false,
|
||||
description: 'Return also milestones in all subgroups and subprojects'
|
||||
|
||||
type Types::MilestoneType, null: true
|
||||
|
||||
def resolve(**args)
|
||||
|
|
@ -26,16 +30,16 @@ module Resolvers
|
|||
state: args[:state] || 'all',
|
||||
start_date: args[:start_date],
|
||||
end_date: args[:end_date]
|
||||
}.merge(parent_id_parameter)
|
||||
}.merge(parent_id_parameter(args))
|
||||
end
|
||||
|
||||
def parent
|
||||
@parent ||= object.respond_to?(:sync) ? object.sync : object
|
||||
end
|
||||
|
||||
def parent_id_parameter
|
||||
def parent_id_parameter(args)
|
||||
if parent.is_a?(Group)
|
||||
{ group_ids: parent.id }
|
||||
group_parameters(args)
|
||||
elsif parent.is_a?(Project)
|
||||
{ project_ids: parent.id }
|
||||
end
|
||||
|
|
@ -46,5 +50,26 @@ module Resolvers
|
|||
def authorize!
|
||||
Ability.allowed?(context[:current_user], :read_milestone, parent) || raise_resource_not_available_error!
|
||||
end
|
||||
|
||||
def group_parameters(args)
|
||||
return { group_ids: parent.id } unless include_descendants?(args)
|
||||
|
||||
{
|
||||
group_ids: parent.self_and_descendants.public_or_visible_to_user(current_user).select(:id),
|
||||
project_ids: group_projects.with_issues_or_mrs_available_for_user(current_user)
|
||||
}
|
||||
end
|
||||
|
||||
def include_descendants?(args)
|
||||
args[:include_descendants].present? && Feature.enabled?(:group_milestone_descendants, parent)
|
||||
end
|
||||
|
||||
def group_projects
|
||||
GroupProjectsFinder.new(
|
||||
group: parent,
|
||||
current_user: current_user,
|
||||
options: { include_subgroups: true }
|
||||
).execute
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -138,17 +138,12 @@ module IssuesHelper
|
|||
can?(current_user, :create_issue, project)
|
||||
end
|
||||
|
||||
def create_confidential_merge_request_enabled?
|
||||
Feature.enabled?(:create_confidential_merge_request, @project, default_enabled: true)
|
||||
end
|
||||
|
||||
def show_new_branch_button?
|
||||
can_create_confidential_merge_request? || !@issue.confidential?
|
||||
end
|
||||
|
||||
def can_create_confidential_merge_request?
|
||||
@issue.confidential? && !@project.private? &&
|
||||
create_confidential_merge_request_enabled? &&
|
||||
can?(current_user, :create_merge_request_in, @project)
|
||||
end
|
||||
|
||||
|
|
|
|||
|
|
@ -96,7 +96,7 @@ module ApplicationSettingImplementation
|
|||
plantuml_url: nil,
|
||||
polling_interval_multiplier: 1,
|
||||
project_export_enabled: true,
|
||||
protected_ci_variables: false,
|
||||
protected_ci_variables: true,
|
||||
push_event_hooks_limit: 3,
|
||||
push_event_activities_limit: 3,
|
||||
raw_blob_request_limit: 300,
|
||||
|
|
|
|||
|
|
@ -40,9 +40,10 @@
|
|||
- if note.system
|
||||
%span.system-note-message
|
||||
= markdown_field(note, :note)
|
||||
%span.system-note-separator
|
||||
·
|
||||
%a.system-note-separator{ href: "##{dom_id(note)}" }= time_ago_with_tooltip(note.created_at, placement: 'bottom', html_class: 'note-created-ago')
|
||||
- if note.created_at
|
||||
%span.system-note-separator
|
||||
·
|
||||
%a.system-note-separator{ href: "##{dom_id(note)}" }= time_ago_with_tooltip(note.created_at, placement: 'bottom', html_class: 'note-created-ago')
|
||||
- unless note.system?
|
||||
.note-actions
|
||||
- if note.for_personal_snippet?
|
||||
|
|
|
|||
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
title: Remove a lonely dot in Batch Comments.
|
||||
merge_request: 31783
|
||||
author: Gilang Gumilar
|
||||
type: changed
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
title: Make protected_ci_variables setting enabled by default
|
||||
merge_request: 31715
|
||||
author:
|
||||
type: changed
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
title: Fix misalignment of author dropdown on the commits search page
|
||||
merge_request: 31686
|
||||
author:
|
||||
type: other
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
title: Fix no scroll when overflow in IDE right pane
|
||||
merge_request: 31961
|
||||
author:
|
||||
type: fixed
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
title: Remove extra spaces from markdown toolbar items
|
||||
merge_request: 31288
|
||||
author:
|
||||
type: other
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
title: Removes create_confidential_merge_request feature flag leandrogs
|
||||
merge_request: 31968
|
||||
author: Leandro Silva
|
||||
type: other
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
title: Update deprecated slot syntax in ./app/assets/javascripts/boards/components/board_form.vue
|
||||
merge_request: 32005
|
||||
author: Gilang Gumilar
|
||||
type: changed
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
title: Update deprecated slot syntax in ./app/assets/javascripts/pages/milestones/shared/components/delete_milestone_modal.vue
|
||||
merge_request: 31990
|
||||
author: Gilang Gumilar
|
||||
type: changed
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
class ChangeDefaultValueOfProtectedCiVariablesOfApplicationSettingsToTrue < ActiveRecord::Migration[6.0]
|
||||
DOWNTIME = false
|
||||
|
||||
def change
|
||||
change_column_default :application_settings, :protected_ci_variables, from: false, to: true
|
||||
end
|
||||
end
|
||||
|
|
@ -349,7 +349,7 @@ CREATE TABLE public.application_settings (
|
|||
diff_max_patch_bytes integer DEFAULT 102400 NOT NULL,
|
||||
archive_builds_in_seconds integer,
|
||||
commit_email_hostname character varying,
|
||||
protected_ci_variables boolean DEFAULT false NOT NULL,
|
||||
protected_ci_variables boolean DEFAULT true NOT NULL,
|
||||
runners_registration_token_encrypted character varying,
|
||||
local_markdown_version integer DEFAULT 0 NOT NULL,
|
||||
first_day_of_week integer DEFAULT 0 NOT NULL,
|
||||
|
|
@ -13768,5 +13768,6 @@ COPY "schema_migrations" (version) FROM STDIN;
|
|||
20200508091106
|
||||
20200511092714
|
||||
20200511145545
|
||||
20200512085150
|
||||
\.
|
||||
|
||||
|
|
|
|||
|
|
@ -167,6 +167,10 @@ queried over UDP. To overcome this issue, you can use TCP for querying by settin
|
|||
|
||||
### Forking
|
||||
|
||||
NOTE: **Note:**
|
||||
Starting with GitLab 13.0, Puma is the default web server used in GitLab
|
||||
all-in-one package based installations as well as GitLab Helm chart deployments.
|
||||
|
||||
If you use an application server that forks, such as Unicorn, you _have to_
|
||||
update your Unicorn configuration to start service discovery _after_ a fork.
|
||||
Failure to do so will lead to service discovery only running in the parent
|
||||
|
|
|
|||
|
|
@ -91,7 +91,7 @@ There is an [issue where support is being discussed](https://gitlab.com/gitlab-o
|
|||
# Fill with the hash generated by `gitlab-ctl pg-password-md5 gitlab`
|
||||
postgresql['sql_user_password'] = '<md5_hash_of_your_password>'
|
||||
|
||||
# Every node that runs Unicorn or Sidekiq needs to have the database
|
||||
# Every node that runs Puma or Sidekiq needs to have the database
|
||||
# password specified as below. If you have a high-availability setup, this
|
||||
# must be present in all application nodes.
|
||||
gitlab_rails['db_password'] = '<your_password_here>'
|
||||
|
|
@ -273,7 +273,7 @@ There is an [issue where support is being discussed](https://gitlab.com/gitlab-o
|
|||
1. Stop application server and Sidekiq
|
||||
|
||||
```shell
|
||||
gitlab-ctl stop unicorn
|
||||
gitlab-ctl stop puma
|
||||
gitlab-ctl stop sidekiq
|
||||
```
|
||||
|
||||
|
|
|
|||
|
|
@ -261,7 +261,7 @@ Configure the tracking database.
|
|||
redis_exporter['enable'] = false
|
||||
repmgr['enable'] = false
|
||||
sidekiq['enable'] = false
|
||||
unicorn['enable'] = false
|
||||
puma['enable'] = false
|
||||
```
|
||||
|
||||
After making these changes, [reconfigure GitLab](../../restart_gitlab.md#omnibus-gitlab-reconfigure) so the changes take effect.
|
||||
|
|
@ -354,7 +354,7 @@ On the secondary the following GitLab frontend services will be enabled:
|
|||
- `registry`
|
||||
- `remote-syslog`
|
||||
- `sidekiq`
|
||||
- `unicorn`
|
||||
- `puma`
|
||||
|
||||
Verify these services by running `sudo gitlab-ctl status` on the frontend
|
||||
application servers.
|
||||
|
|
@ -407,7 +407,7 @@ application servers above, with some changes to run only the `sidekiq` service:
|
|||
redis['enable'] = false
|
||||
redis_exporter['enable'] = false
|
||||
repmgr['enable'] = false
|
||||
unicorn['enable'] = false
|
||||
puma['enable'] = false
|
||||
|
||||
##
|
||||
## The unique identifier for the Geo node.
|
||||
|
|
|
|||
|
|
@ -177,7 +177,7 @@ from [owasp.org](https://owasp.org/).
|
|||
|
||||
### What databases and application servers support the application?
|
||||
|
||||
- PostgreSQL >= 9.6, Redis, Sidekiq, Unicorn.
|
||||
- PostgreSQL >= 9.6, Redis, Sidekiq, Puma.
|
||||
|
||||
### How will database connection strings, encryption keys, and other sensitive components be stored, accessed, and protected from unauthorized detection?
|
||||
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ The following list depicts what the network architecture of Gitaly is:
|
|||
- A GitLab server can use one or more Gitaly servers.
|
||||
- Gitaly addresses must be specified in such a way that they resolve
|
||||
correctly for ALL Gitaly clients.
|
||||
- Gitaly clients are: Unicorn, Sidekiq, GitLab Workhorse,
|
||||
- Gitaly clients are: Puma/Unicorn, Sidekiq, GitLab Workhorse,
|
||||
GitLab Shell, Elasticsearch Indexer, and Gitaly itself.
|
||||
- A Gitaly server must be able to make RPC calls **to itself** via its own
|
||||
`(Gitaly address, Gitaly token)` pair as specified in `/config/gitlab.yml`.
|
||||
|
|
@ -195,7 +195,7 @@ authentication](https://gitlab.com/gitlab-org/gitaly/blob/master/doc/configurati
|
|||
postgresql['enable'] = false
|
||||
redis['enable'] = false
|
||||
nginx['enable'] = false
|
||||
unicorn['enable'] = false
|
||||
puma['enable'] = false
|
||||
sidekiq['enable'] = false
|
||||
gitlab_workhorse['enable'] = false
|
||||
grafana['enable'] = false
|
||||
|
|
|
|||
|
|
@ -207,7 +207,7 @@ application server, or a Gitaly node.
|
|||
nginx['enable'] = false
|
||||
prometheus['enable'] = false
|
||||
grafana['enable'] = false
|
||||
unicorn['enable'] = false
|
||||
puma['enable'] = false
|
||||
sidekiq['enable'] = false
|
||||
gitlab_workhorse['enable'] = false
|
||||
gitaly['enable'] = false
|
||||
|
|
@ -421,7 +421,7 @@ documentation](index.md#3-gitaly-server-configuration).
|
|||
nginx['enable'] = false
|
||||
prometheus['enable'] = false
|
||||
grafana['enable'] = false
|
||||
unicorn['enable'] = false
|
||||
puma['enable'] = false
|
||||
sidekiq['enable'] = false
|
||||
gitlab_workhorse['enable'] = false
|
||||
prometheus_monitoring['enable'] = false
|
||||
|
|
|
|||
|
|
@ -162,7 +162,7 @@ If you enable Monitoring, it must be enabled on **all** GitLab servers.
|
|||
node_exporter['listen_address'] = '0.0.0.0:9100'
|
||||
gitlab_workhorse['prometheus_listen_addr'] = '0.0.0.0:9229'
|
||||
sidekiq['listen_address'] = "0.0.0.0"
|
||||
unicorn['listen'] = '0.0.0.0'
|
||||
puma['listen'] = '0.0.0.0'
|
||||
|
||||
# Add the monitoring node's IP address to the monitoring whitelist and allow it to
|
||||
# scrape the NGINX metrics. Replace placeholder `monitoring.gitlab.example.com` with
|
||||
|
|
@ -174,9 +174,11 @@ If you enable Monitoring, it must be enabled on **all** GitLab servers.
|
|||
1. Run `sudo gitlab-ctl reconfigure` to compile the configuration.
|
||||
|
||||
CAUTION: **Warning:**
|
||||
After changing `unicorn['listen']` in `gitlab.rb`, and running `sudo gitlab-ctl reconfigure`,
|
||||
it can take an extended period of time for Unicorn to complete reloading after receiving a `HUP`.
|
||||
For more information, see the [issue](https://gitlab.com/gitlab-org/omnibus-gitlab/issues/4401).
|
||||
If running Unicorn, after changing `unicorn['listen']` in `gitlab.rb`, and
|
||||
running `sudo gitlab-ctl reconfigure`, it can take an extended period of time
|
||||
for Unicorn to complete reloading after receiving a `HUP`. For more
|
||||
information, see the
|
||||
[issue](https://gitlab.com/gitlab-org/omnibus-gitlab/issues/4401).
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ Omnibus:
|
|||
redis['enable'] = false
|
||||
redis_exporter['enable'] = false
|
||||
sidekiq['enable'] = false
|
||||
unicorn['enable'] = false
|
||||
puma['enable'] = false
|
||||
node_exporter['enable'] = false
|
||||
gitlab_exporter['enable'] = false
|
||||
```
|
||||
|
|
|
|||
|
|
@ -165,7 +165,7 @@ Refer to your preferred Load Balancer's documentation for further guidance.
|
|||
|
||||
1. Run `gitlab-ctl reconfigure`
|
||||
|
||||
1. On the node running Unicorn, make sure the following is set in `/etc/gitlab/gitlab.rb`
|
||||
1. On the node running Puma, make sure the following is set in `/etc/gitlab/gitlab.rb`
|
||||
|
||||
```ruby
|
||||
gitlab_rails['db_host'] = 'PGBOUNCER_HOST'
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ Omnibus:
|
|||
## Disable all other services
|
||||
sidekiq['enable'] = false
|
||||
gitlab_workhorse['enable'] = false
|
||||
unicorn['enable'] = false
|
||||
puma['enable'] = false
|
||||
postgresql['enable'] = false
|
||||
nginx['enable'] = false
|
||||
prometheus['enable'] = false
|
||||
|
|
|
|||
|
|
@ -88,7 +88,7 @@ you want using steps 1 and 2 from the GitLab downloads page.
|
|||
postgresql['enable'] = false
|
||||
redis['enable'] = false
|
||||
redis_exporter['enable'] = false
|
||||
unicorn['enable'] = false
|
||||
puma['enable'] = false
|
||||
gitlab_exporter['enable'] = false
|
||||
```
|
||||
|
||||
|
|
@ -119,7 +119,7 @@ postgres_exporter['enable'] = false
|
|||
postgresql['enable'] = false
|
||||
redis['enable'] = false
|
||||
redis_exporter['enable'] = false
|
||||
unicorn['enable'] = false
|
||||
puma['enable'] = false
|
||||
gitlab_exporter['enable'] = false
|
||||
|
||||
########################################
|
||||
|
|
|
|||
|
|
@ -79,7 +79,7 @@ Learn how to install, configure, update, and maintain your GitLab instance.
|
|||
|
||||
- [Rake tasks](../raketasks/README.md): Perform various tasks for maintenance, backups, automatic webhooks setup, and more.
|
||||
- [Backup and restore](../raketasks/backup_restore.md): Backup and restore your GitLab instance.
|
||||
- [Operations](operations/index.md): Keeping GitLab up and running (clean up Redis sessions, moving repositories, Sidekiq MemoryKiller, Unicorn).
|
||||
- [Operations](operations/index.md): Keeping GitLab up and running (clean up Redis sessions, moving repositories, Sidekiq MemoryKiller, Puma).
|
||||
- [Restart GitLab](restart_gitlab.md): Learn how to restart GitLab and its components.
|
||||
- [Invalidate Markdown cache](invalidate_markdown_cache.md): Invalidate any cached Markdown.
|
||||
|
||||
|
|
|
|||
|
|
@ -12,8 +12,8 @@ In the following table you can see the phases a log goes through:
|
|||
|
||||
| Phase | State | Condition | Data flow | Stored path |
|
||||
| -------------- | ------------ | ----------------------- | -----------------------------------------| ----------- |
|
||||
| 1: patching | log | When a job is running | GitLab Runner => Unicorn => file storage | `#{ROOT_PATH}/gitlab-ci/builds/#{YYYY_mm}/#{project_id}/#{job_id}.log` |
|
||||
| 2: overwriting | log | When a job is finished | GitLab Runner => Unicorn => file storage | `#{ROOT_PATH}/gitlab-ci/builds/#{YYYY_mm}/#{project_id}/#{job_id}.log` |
|
||||
| 1: patching | log | When a job is running | GitLab Runner => Puma => file storage | `#{ROOT_PATH}/gitlab-ci/builds/#{YYYY_mm}/#{project_id}/#{job_id}.log` |
|
||||
| 2: overwriting | log | When a job is finished | GitLab Runner => Puma => file storage | `#{ROOT_PATH}/gitlab-ci/builds/#{YYYY_mm}/#{project_id}/#{job_id}.log` |
|
||||
| 3: archiving | archived log | After a job is finished | Sidekiq moves log to artifacts folder | `#{ROOT_PATH}/gitlab-rails/shared/artifacts/#{disk_hash}/#{YYYY_mm_dd}/#{job_id}/#{job_artifact_id}/job.log` |
|
||||
| 4: uploading | archived log | After a log is archived | Sidekiq moves archived log to [object storage](#uploading-logs-to-object-storage) (if configured) | `#{bucket_name}/#{disk_hash}/#{YYYY_mm_dd}/#{job_id}/#{job_artifact_id}/job.log` |
|
||||
|
||||
|
|
|
|||
|
|
@ -538,8 +538,18 @@ This file lives in `/var/log/gitlab/gitaly/current` and is produced by [runit](h
|
|||
|
||||
This file lives in `/var/log/gitlab/gitlab-rails/grpc.log` for Omnibus GitLab packages. Native [gRPC](https://grpc.io/) logging used by Gitaly.
|
||||
|
||||
## `puma_stderr.log` & `puma_stdout.log`
|
||||
|
||||
This file lives in `/var/log/gitlab/puma/puma_stderr.log` and `/var/log/gitlab/puma/puma_stdout.log` for
|
||||
Omnibus GitLab packages or in `/home/git/gitlab/log/puma_stderr.log` and `/home/git/gitlab/log/puma_stdout.log`
|
||||
for installations from source.
|
||||
|
||||
## `unicorn_stderr.log` & `unicorn_stdout.log`
|
||||
|
||||
NOTE: **Note:**
|
||||
Starting with GitLab 13.0, Puma is the default web server used in GitLab
|
||||
all-in-one package based installations as well as GitLab Helm chart deployments.
|
||||
|
||||
This file lives in `/var/log/gitlab/unicorn/unicorn_stderr.log` and `/var/log/gitlab/unicorn/unicorn_stdout.log` for
|
||||
Omnibus GitLab packages or in `/home/git/gitlab/log/unicorn_stderr.log` and `/home/git/gitlab/log/unicorn_stdout.log`
|
||||
for installations from source.
|
||||
|
|
@ -565,12 +575,6 @@ I, [2015-02-13T07:16:01.534501 #13379] INFO -- : worker=1 spawned pid=13379
|
|||
I, [2015-02-13T07:16:01.534848 #13379] INFO -- : worker=1 ready
|
||||
```
|
||||
|
||||
## `puma_stderr.log` & `puma_stdout.log`
|
||||
|
||||
This file lives in `/var/log/gitlab/puma/puma_stderr.log` and `/var/log/gitlab/puma/puma_stdout.log` for
|
||||
Omnibus GitLab packages or in `/home/git/gitlab/log/puma_stderr.log` and `/home/git/gitlab/log/puma_stdout.log`
|
||||
for installations from source.
|
||||
|
||||
## `repocheck.log`
|
||||
|
||||
This file lives in `/var/log/gitlab/gitlab-rails/repocheck.log` for
|
||||
|
|
@ -657,7 +661,7 @@ will be generated in `/var/log/gitlab/gitlab-rails/sidekiq_exporter.log` for
|
|||
Omnibus GitLab packages or in `/home/git/gitlab/log/sidekiq_exporter.log` for
|
||||
installations from source.
|
||||
|
||||
If Prometheus metrics and the Web Exporter are both enabled, Unicorn/Puma will
|
||||
If Prometheus metrics and the Web Exporter are both enabled, Puma/Unicorn will
|
||||
start a Web server and listen to the defined port (default: `8083`). Access logs
|
||||
will be generated in `/var/log/gitlab/gitlab-rails/web_exporter.log` for
|
||||
Omnibus GitLab packages or in `/home/git/gitlab/log/web_exporter.log` for
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@ Keep your GitLab instance up and running smoothly.
|
|||
- [Sidekiq MemoryKiller](sidekiq_memory_killer.md): Configure Sidekiq MemoryKiller
|
||||
to restart Sidekiq.
|
||||
- [Multiple Sidekiq processes](extra_sidekiq_processes.md): Configure multiple Sidekiq processes to ensure certain queues always have dedicated workers, no matter the number of jobs that need to be processed. **(CORE ONLY)**
|
||||
- [Puma](puma.md): Understand Puma and puma-worker-killer.
|
||||
- [Unicorn](unicorn.md): Understand Unicorn and unicorn-worker-killer.
|
||||
- Speed up SSH operations by [Authorizing SSH users via a fast,
|
||||
indexed lookup to the GitLab database](fast_ssh_key_lookup.md), and/or
|
||||
|
|
|
|||
|
|
@ -3,7 +3,9 @@
|
|||
## Puma
|
||||
|
||||
As of GitLab 12.9, [Puma](https://github.com/puma/puma) has replaced [Unicorn](https://yhbt.net/unicorn/).
|
||||
as the default web server.
|
||||
as the default web server. Starting with 13.0, both all-in-one package based
|
||||
installations as well as Helm chart based installations will run Puma instead of
|
||||
Unicorn unless explicitly specified not to.
|
||||
|
||||
## Why switch to Puma?
|
||||
|
||||
|
|
|
|||
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
The GitLab Rails application code suffers from memory leaks. For web requests
|
||||
this problem is made manageable using
|
||||
[`unicorn-worker-killer`](https://github.com/kzk/unicorn-worker-killer) which
|
||||
restarts Unicorn worker processes in between requests when needed. The Sidekiq
|
||||
[`puma-worker-killer`](https://github.com/schneems/puma_worker_killer) which
|
||||
restarts Puma worker processes if it exceeds a memory limit. The Sidekiq
|
||||
MemoryKiller applies the same approach to the Sidekiq processes used by GitLab
|
||||
to process background jobs.
|
||||
|
||||
Unlike unicorn-worker-killer, which is enabled by default for all GitLab
|
||||
installations since GitLab 6.4, the Sidekiq MemoryKiller is enabled by default
|
||||
Unlike puma-worker-killer, which is enabled by default for all GitLab
|
||||
installations since GitLab 13.0, the Sidekiq MemoryKiller is enabled by default
|
||||
_only_ for Omnibus packages. The reason for this is that the MemoryKiller
|
||||
relies on runit to restart Sidekiq after a memory-induced shutdown and GitLab
|
||||
installations from source do not all use runit or an equivalent.
|
||||
|
|
|
|||
|
|
@ -1,5 +1,9 @@
|
|||
# Understanding Unicorn and unicorn-worker-killer
|
||||
|
||||
NOTE: **Note:**
|
||||
Starting with GitLab 13.0, Puma is the default web server used in GitLab
|
||||
all-in-one package based installations as well as GitLab Helm chart deployments.
|
||||
|
||||
## Unicorn
|
||||
|
||||
GitLab uses [Unicorn](https://yhbt.net/unicorn/), a pre-forking Ruby web
|
||||
|
|
|
|||
|
|
@ -472,7 +472,7 @@ To configure GitLab Pages on a separate server:
|
|||
postgresql['enable'] = false
|
||||
redis['enable'] = false
|
||||
prometheus['enable'] = false
|
||||
unicorn['enable'] = false
|
||||
puma['enable'] = false
|
||||
sidekiq['enable'] = false
|
||||
gitlab_workhorse['enable'] = false
|
||||
gitaly['enable'] = false
|
||||
|
|
|
|||
|
|
@ -165,7 +165,7 @@ column.
|
|||
| Redis Sentinel | High availability for Redis | [Redis Sentinel configuration](../high_availability/redis.md) | Yes |
|
||||
| [Gitaly](../../development/architecture.md#gitaly) ([2](#footnotes)) ([7](#footnotes)) ([10](#footnotes)) | Provides access to Git repositories | [Gitaly configuration](../gitaly/index.md#running-gitaly-on-its-own-server) | Yes |
|
||||
| [Sidekiq](../../development/architecture.md#sidekiq) | Asynchronous/background jobs | [Sidekiq configuration](../high_availability/sidekiq.md) | Yes |
|
||||
| [GitLab application services](../../development/architecture.md#unicorn)([1](#footnotes)) | Unicorn/Puma, Workhorse, GitLab Shell - serves front-end requests (UI, API, Git over HTTP/SSH) | [GitLab app scaling configuration](../high_availability/gitlab.md) | Yes |
|
||||
| [GitLab application services](../../development/architecture.md#unicorn)([1](#footnotes)) | Puma/Unicorn, Workhorse, GitLab Shell - serves front-end requests (UI, API, Git over HTTP/SSH) | [GitLab app scaling configuration](../high_availability/gitlab.md) | Yes |
|
||||
| [Prometheus](../../development/architecture.md#prometheus) and [Grafana](../../development/architecture.md#grafana) | GitLab environment monitoring | [Monitoring node for scaling](../high_availability/monitoring_node.md) | Yes |
|
||||
|
||||
## Footnotes
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ If you have used the [Omnibus packages](https://about.gitlab.com/install/) to in
|
|||
you should already have `gitlab-ctl` in your `PATH`.
|
||||
|
||||
`gitlab-ctl` interacts with the Omnibus packages and can be used to restart the
|
||||
GitLab Rails application (Unicorn) as well as the other components, like:
|
||||
GitLab Rails application (Puma) as well as the other components, like:
|
||||
|
||||
- GitLab Workhorse
|
||||
- Sidekiq
|
||||
|
|
@ -45,7 +45,7 @@ ok: run: nginx: (pid 11309) 0s
|
|||
ok: run: postgresql: (pid 11316) 1s
|
||||
ok: run: redis: (pid 11325) 0s
|
||||
ok: run: sidekiq: (pid 11331) 1s
|
||||
ok: run: unicorn: (pid 11338) 0s
|
||||
ok: run: puma: (pid 11338) 0s
|
||||
```
|
||||
|
||||
To restart a component separately, you can append its service name to the
|
||||
|
|
@ -110,25 +110,25 @@ sudo service gitlab restart
|
|||
The output should be similar to this:
|
||||
|
||||
```plaintext
|
||||
Shutting down GitLab Unicorn
|
||||
Shutting down GitLab Puma
|
||||
Shutting down GitLab Sidekiq
|
||||
Shutting down GitLab Workhorse
|
||||
Shutting down GitLab MailRoom
|
||||
...
|
||||
GitLab is not running.
|
||||
Starting GitLab Unicorn
|
||||
Starting GitLab Puma
|
||||
Starting GitLab Sidekiq
|
||||
Starting GitLab Workhorse
|
||||
Starting GitLab MailRoom
|
||||
...
|
||||
The GitLab Unicorn web server with pid 28059 is running.
|
||||
The GitLab Puma web server with pid 28059 is running.
|
||||
The GitLab Sidekiq job dispatcher with pid 28176 is running.
|
||||
The GitLab Workhorse with pid 28122 is running.
|
||||
The GitLab MailRoom email processor with pid 28114 is running.
|
||||
GitLab and all its components are up and running.
|
||||
```
|
||||
|
||||
This should restart Unicorn, Sidekiq, GitLab Workhorse, and [Mailroom](reply_by_email.md)
|
||||
This should restart Puma, Sidekiq, GitLab Workhorse, and [Mailroom](reply_by_email.md)
|
||||
(if enabled). The init service file that does all the magic can be found on
|
||||
your server in `/etc/init.d/gitlab`.
|
||||
|
||||
|
|
@ -142,7 +142,7 @@ If you are using other init systems, like systemd, you can check the
|
|||
|
||||
There is no single command to restart the entire GitLab application installed via
|
||||
the [cloud native Helm Chart](https://docs.gitlab.com/charts/). Usually, it should be
|
||||
enough to restart a specific component separately (for example, `gitaly`, `unicorn`,
|
||||
enough to restart a specific component separately (for example, `gitaly`, `puma`,
|
||||
`workhorse`, or `gitlab-shell`) by deleting all the pods related to it:
|
||||
|
||||
```shell
|
||||
|
|
|
|||
|
|
@ -52,7 +52,7 @@ and they will assist you with any issues you are having.
|
|||
- Check logs via Kubectl:
|
||||
|
||||
```shell
|
||||
kubectl logs <unicorn pod> -c dependencies
|
||||
kubectl logs <webservice pod> -c dependencies
|
||||
```
|
||||
|
||||
- How to tail all Kubernetes cluster events in real time:
|
||||
|
|
@ -87,20 +87,20 @@ and they will assist you with any issues you are having.
|
|||
- Minimal config that can be used to test a Kubernetes Helm chart can be found
|
||||
[here](https://gitlab.com/gitlab-org/charts/gitlab/issues/620).
|
||||
|
||||
- Tailing logs of a separate pod. An example for a Unicorn pod:
|
||||
- Tailing logs of a separate pod. An example for a Webservice pod:
|
||||
|
||||
```shell
|
||||
kubectl logs gitlab-unicorn-7656fdd6bf-jqzfs -c unicorn
|
||||
kubectl logs gitlab-webservice-54fbf6698b-hpckq -c webservice
|
||||
```
|
||||
|
||||
- Tail and follow all pods that share a label (in this case, `unicorn`):
|
||||
- Tail and follow all pods that share a label (in this case, `webservice`):
|
||||
|
||||
```shell
|
||||
# all containers in the unicorn pods
|
||||
kubectl logs -f -l app=unicorn --all-containers=true --max-log-requests=50
|
||||
# all containers in the webservice pods
|
||||
kubectl logs -f -l app=webservice --all-containers=true --max-log-requests=50
|
||||
|
||||
# only the unicorn containers in all unicorn pods
|
||||
kubectl logs -f -l app=unicorn -c unicorn --max-log-requests=50
|
||||
# only the webservice containers in all webservice pods
|
||||
kubectl logs -f -l app=webservice -c webservice --max-log-requests=50
|
||||
```
|
||||
|
||||
- One can stream logs from all containers at once, similar to the Omnibus
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@ For source installations the following settings are nested under `uploads:` and
|
|||
|---------|-------------|---------|
|
||||
| `enabled` | Enable/disable object storage | `false` |
|
||||
| `remote_directory` | The bucket name where Uploads will be stored| |
|
||||
| `direct_upload` | Set to true to remove Unicorn from the Upload path. Workhorse handles the actual Artifact Upload to Object Storage while Unicorn does minimal processing to keep track of the upload. There is no need for local shared storage. The option may be removed if support for a single storage type for all files is introduced. Read more on [direct upload](../development/uploads.md#direct-upload). | `false` |
|
||||
| `direct_upload` | Set to true to remove Puma from the Upload path. Workhorse handles the actual Artifact Upload to Object Storage while Puma does minimal processing to keep track of the upload. There is no need for local shared storage. The option may be removed if support for a single storage type for all files is introduced. Read more on [direct upload](../development/uploads.md#direct-upload). | `false` |
|
||||
| `background_upload` | Set to false to disable automatic upload. Option may be removed once upload is direct to S3 (if `direct_upload` is set to `true` it will override `background_upload`) | `true` |
|
||||
| `proxy_download` | Set to true to enable proxying all files served. Option allows to reduce egress traffic as this allows clients to download directly from remote storage instead of proxying all data | `false` |
|
||||
| `connection` | Various connection options described below | |
|
||||
|
|
|
|||
|
|
@ -4110,6 +4110,11 @@ type Group {
|
|||
"""
|
||||
first: Int
|
||||
|
||||
"""
|
||||
Return also milestones in all subgroups and subprojects
|
||||
"""
|
||||
includeDescendants: Boolean
|
||||
|
||||
"""
|
||||
Returns the last _n_ elements from the list.
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -11439,6 +11439,16 @@
|
|||
},
|
||||
"defaultValue": null
|
||||
},
|
||||
{
|
||||
"name": "includeDescendants",
|
||||
"description": "Return also milestones in all subgroups and subprojects",
|
||||
"type": {
|
||||
"kind": "SCALAR",
|
||||
"name": "Boolean",
|
||||
"ofType": null
|
||||
},
|
||||
"defaultValue": null
|
||||
},
|
||||
{
|
||||
"name": "after",
|
||||
"description": "Returns the elements in the list that come after the specified cursor.",
|
||||
|
|
|
|||
Binary file not shown.
|
After Width: | Height: | Size: 100 KiB |
|
|
@ -2,6 +2,81 @@
|
|||
|
||||
Development guides that are specific to CI/CD are listed here.
|
||||
|
||||
## CI Architecture overview
|
||||
|
||||
The following is a simplified diagram of the CI architecture. Some details are left out in order to focus on
|
||||
the main components.
|
||||
|
||||

|
||||
<!-- Editable diagram available at https://app.diagrams.net/#G1LFl-KW4fgpBPzz8VIH9rsOlAH4t0xwKj -->
|
||||
|
||||
On the left side we have the events that can trigger a pipeline based on various events (trigged by a user or automation):
|
||||
|
||||
- A `git push` is the most common event that triggers a pipeline.
|
||||
- The [Web API](../../api/pipelines.md#create-a-new-pipeline).
|
||||
- A user clicking the "Run Pipeline" button in the UI.
|
||||
- When a [merge request is created or updated](../../ci/merge_request_pipelines/index.md#pipelines-for-merge-requests).
|
||||
- When an MR is added to a [Merge Train](../../ci/merge_request_pipelines/pipelines_for_merged_results/merge_trains/index.md#merge-trains-premium).
|
||||
- A [scheduled pipeline](../../ci/pipelines/schedules.md#pipeline-schedules).
|
||||
- When project is [subscribed to an upstream project](../../ci/multi_project_pipelines.md#trigger-a-pipeline-when-an-upstream-project-is-rebuilt).
|
||||
- When [Auto DevOps](../../topics/autodevops/index.md) is enabled.
|
||||
- When GitHub integration is used with [external pull requests](../../ci/ci_cd_for_external_repos/index.md#pipelines-for-external-pull-requests).
|
||||
- When an upstream pipeline contains a [bridge job](../../ci/yaml/README.md#trigger) which triggers a downstream pipeline.
|
||||
|
||||
Triggering any of these events will invoke the [`CreatePipelineService`](https://gitlab.com/gitlab-org/gitlab/-/blob/master/app/services/ci/create_pipeline_service.rb)
|
||||
which takes as input event data and the user triggering it, then will attempt to create a pipeline.
|
||||
|
||||
The `CreatePipelineService` relies heavily on the [`YAML Processor`](https://gitlab.com/gitlab-org/gitlab/-/blob/master/lib/gitlab/ci/yaml_processor.rb)
|
||||
component, which is responsible for taking in a YAML blob as input and returns the abstract data structure of a
|
||||
pipeline (including stages and all jobs). This component also validates the structure of the YAML while
|
||||
processing it, and returns any syntax or semantic errors. The `YAML Processor` component is where we define
|
||||
[all the keywords](../../ci/yaml/README.md) available to structure a pipeline.
|
||||
|
||||
The `CreatePipelineService` receives the abstract data structure returned by the `YAML Processor`,
|
||||
which then converts it to persisted models (pipeline, stages, jobs, etc.). After that, the pipeline is ready
|
||||
to be processed. Processing a pipeline means running the jobs in order of execution (stage or DAG)
|
||||
until either one of the following:
|
||||
|
||||
- All expected jobs have been executed.
|
||||
- Failures interrupt the pipeline execution.
|
||||
|
||||
The component that processes a pipeline is [`ProcessPipelineService`](https://gitlab.com/gitlab-org/gitlab/-/blob/master/app/services/ci/process_pipeline_service.rb),
|
||||
which is responsible for moving all the pipeline's jobs to a completed state. When a pipeline is created, all its
|
||||
jobs are initially in `created` state. This services looks at what jobs in `created` stage are eligible
|
||||
to be processed based on the pipeline structure. Then it moves them into the `pending` state, which means
|
||||
they can now [be picked up by a Runner](#job-scheduling). After a job has been executed it can complete
|
||||
successfully or fail. Each status transition for job within a pipeline triggers this service again, which
|
||||
looks for the next jobs to be transitioned towards completion. While doing that, `ProcessPipelineService`
|
||||
updates the status of jobs, stages and the overall pipeline.
|
||||
|
||||
On the right side of the diagram we have a list of [Runners](../../ci/runners/README.md#configuring-gitlab-runners)
|
||||
connected to the GitLab instance. These can be Shared Runners, Group Runners or Project-specific Runners.
|
||||
The communication between Runners and the Rails server occurs through a set of API endpoints, grouped as
|
||||
the `Runner API Gateway`.
|
||||
|
||||
We can register, delete and verify Runners, which also causes read/write queries to the database. After a Runner is connected,
|
||||
it keeps asking for the next job to execute. This invokes the [`RegisterJobService`](https://gitlab.com/gitlab-org/gitlab/blob/master/app/services/ci/register_job_service.rb)
|
||||
which will pick the next job and assign it to the Runner. At this point the job will transition to a
|
||||
`running` state, which again triggers `ProcessPipelineService` due to the status change.
|
||||
For more details read [Job scheduling](#job-scheduling)).
|
||||
|
||||
While a job is being executed, the Runner sends logs back to the server as well any possible artifacts
|
||||
that need to be stored. Also, a job may depend on artifacts from previous jobs in order to run. In this
|
||||
case the Runner will download them using a dedicated API endpoint.
|
||||
|
||||
Artifacts are stored in object storage, while metadata is kept in the database. An important example of artifacts
|
||||
is reports (JUnit, SAST, DAST, etc.) which are parsed and rendered in the merge request.
|
||||
|
||||
Job status transitions are not all automated. A user may run [manual jobs](../../ci/yaml/README.md#whenmanual), cancel a pipeline, retry
|
||||
specific failed jobs or the entire pipeline. Anything that
|
||||
causes a job to change status will trigger `ProcessPipelineService`, as it's responsible for
|
||||
tracking the status of the entire pipeline.
|
||||
|
||||
A special type of job is the [bridge job](../../ci/yaml/README.md#trigger) which is executed server-side
|
||||
when transitioning to the `pending` state. This job is responsible for creating a downstream pipeline, such as
|
||||
a multi-project or child pipeline. The workflow loop starts again
|
||||
from the `CreatePipelineService` every time a downstream pipeline is triggered.
|
||||
|
||||
## Job scheduling
|
||||
|
||||
When a Pipeline is created all its jobs are created at once for all stages, with an initial state of `created`. This makes it possible to visualize the full content of a pipeline.
|
||||
|
|
|
|||
|
|
@ -14,4 +14,5 @@ This is a partial list of the [RSpec metadata](https://relishapp.com/rspec/rspec
|
|||
| `:reliable` | The test has been [promoted to a reliable test](https://about.gitlab.com/handbook/engineering/quality/guidelines/reliable-tests/#promoting-an-existing-test-to-reliable) meaning it passes consistently in all pipelines, including merge requests. |
|
||||
| `:requires_admin` | The test requires an admin account. Tests with the tag are excluded when run against Canary and Production environments. |
|
||||
| `:runner` | The test depends on and will set up a GitLab Runner instance, typically to run a pipeline. |
|
||||
| `:gitaly_ha` | The test will run against a GitLab instance where repositories are stored on redundant Gitaly nodes behind a Praefect node. All nodes are separate containers in a minimal version of [our recommended highly available configuration](../../../administration/gitaly/praefect.md#requirements-for-configuring-a-gitaly-cluster). Tests that use this tag have a longer setup time since there are three additional containers that need to be started. |
|
||||
| `:skip_live_env` | The test will be excluded when run against live deployed environments such as Staging, Canary, and Production. |
|
||||
|
|
|
|||
2
qa/qa.rb
2
qa/qa.rb
|
|
@ -143,6 +143,7 @@ module QA
|
|||
autoload :Mattermost, 'qa/scenario/test/integration/mattermost'
|
||||
autoload :ObjectStorage, 'qa/scenario/test/integration/object_storage'
|
||||
autoload :SMTP, 'qa/scenario/test/integration/smtp'
|
||||
autoload :GitalyHA, 'qa/scenario/test/integration/gitaly_ha'
|
||||
end
|
||||
|
||||
module Sanity
|
||||
|
|
@ -449,6 +450,7 @@ module QA
|
|||
autoload :Shellout, 'qa/service/shellout'
|
||||
autoload :KubernetesCluster, 'qa/service/kubernetes_cluster'
|
||||
autoload :Omnibus, 'qa/service/omnibus'
|
||||
autoload :PraefectManager, 'qa/service/praefect_manager'
|
||||
|
||||
module ClusterProvider
|
||||
autoload :Base, 'qa/service/cluster_provider/base'
|
||||
|
|
|
|||
|
|
@ -0,0 +1,13 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module QA
|
||||
module Scenario
|
||||
module Test
|
||||
module Integration
|
||||
class GitalyHA < Test::Instance::All
|
||||
tags :gitaly_ha
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module QA
|
||||
module Service
|
||||
class PraefectManager
|
||||
include Service::Shellout
|
||||
|
||||
def initialize
|
||||
@praefect = 'praefect'
|
||||
@first_node = 'gitaly1'
|
||||
@second_node = 'gitaly2'
|
||||
@primary_node = @first_node
|
||||
@secondary_node = @second_node
|
||||
end
|
||||
|
||||
def stop_primary_node
|
||||
shell "docker stop #{@primary_node}"
|
||||
@secondary_node, @primary_node = @primary_node, @secondary_node
|
||||
end
|
||||
|
||||
def reset
|
||||
shell "docker start #{@primary_node}"
|
||||
shell "docker start #{@secondary_node}"
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -0,0 +1,63 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module QA
|
||||
context 'Create' do
|
||||
context 'Gitaly' do
|
||||
describe 'High Availability', :orchestrated, :gitaly_ha do
|
||||
let(:project) do
|
||||
Resource::Project.fabricate! do |project|
|
||||
project.name = 'gitaly_high_availability'
|
||||
end
|
||||
end
|
||||
let(:initial_file) { 'pushed_to_primary.txt' }
|
||||
let(:final_file) { 'pushed_to_secondary.txt' }
|
||||
|
||||
before do
|
||||
@praefect_manager = Service::PraefectManager.new
|
||||
Flow::Login.sign_in
|
||||
end
|
||||
|
||||
after do
|
||||
@praefect_manager.reset
|
||||
end
|
||||
|
||||
it 'makes sure that automatic failover is happening' do
|
||||
Resource::Repository::ProjectPush.fabricate! do |push|
|
||||
push.project = project
|
||||
push.commit_message = 'pushed to primary gitaly node'
|
||||
push.new_branch = true
|
||||
push.file_name = initial_file
|
||||
push.file_content = "This should exist on both nodes"
|
||||
end
|
||||
|
||||
@praefect_manager.stop_primary_node
|
||||
|
||||
project.visit!
|
||||
|
||||
Page::Project::Show.perform do |show|
|
||||
show.wait_until do
|
||||
show.has_name?(project.name)
|
||||
end
|
||||
expect(show).to have_file(initial_file)
|
||||
end
|
||||
|
||||
Resource::Repository::Commit.fabricate_via_api! do |commit|
|
||||
commit.project = project
|
||||
commit.add_files([
|
||||
{
|
||||
file_path: 'committed_to_primary.txt',
|
||||
content: 'This should exist on both nodes too'
|
||||
}
|
||||
])
|
||||
end
|
||||
|
||||
project.visit!
|
||||
|
||||
Page::Project::Show.perform do |show|
|
||||
expect(show).to have_file(final_file)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module QA
|
||||
context 'Monitor' do
|
||||
context 'Monitor', quarantine: { issue: 'https://gitlab.com/gitlab-org/gitlab/-/issues/217705', type: :flaky } do
|
||||
describe 'with Prometheus Gitlab-managed cluster', :orchestrated, :kubernetes, :docker, :runner do
|
||||
before :all do
|
||||
Flow::Login.sign_in
|
||||
|
|
|
|||
|
|
@ -124,55 +124,37 @@ describe Projects::BranchesController do
|
|||
)
|
||||
end
|
||||
|
||||
context 'create_confidential_merge_request feature is enabled' do
|
||||
context 'user cannot update issue' do
|
||||
let(:issue) { create(:issue, project: confidential_issue_project) }
|
||||
|
||||
it 'does not post a system note' do
|
||||
expect(SystemNoteService).not_to receive(:new_issue_branch)
|
||||
|
||||
create_branch_with_confidential_issue_project
|
||||
end
|
||||
end
|
||||
|
||||
context 'user can update issue' do
|
||||
before do
|
||||
stub_feature_flags(create_confidential_merge_request: true)
|
||||
confidential_issue_project.add_reporter(user)
|
||||
end
|
||||
|
||||
context 'user cannot update issue' do
|
||||
context 'issue is under the specified project' do
|
||||
let(:issue) { create(:issue, project: confidential_issue_project) }
|
||||
|
||||
it 'does not post a system note' do
|
||||
expect(SystemNoteService).not_to receive(:new_issue_branch)
|
||||
it 'posts a system note' do
|
||||
expect(SystemNoteService).to receive(:new_issue_branch).with(issue, confidential_issue_project, user, "1-feature-branch", branch_project: project)
|
||||
|
||||
create_branch_with_confidential_issue_project
|
||||
end
|
||||
end
|
||||
|
||||
context 'user can update issue' do
|
||||
before do
|
||||
confidential_issue_project.add_reporter(user)
|
||||
context 'issue is not under the specified project' do
|
||||
it 'does not post a system note' do
|
||||
expect(SystemNoteService).not_to receive(:new_issue_branch)
|
||||
|
||||
create_branch_with_confidential_issue_project
|
||||
end
|
||||
|
||||
context 'issue is under the specified project' do
|
||||
let(:issue) { create(:issue, project: confidential_issue_project) }
|
||||
|
||||
it 'posts a system note' do
|
||||
expect(SystemNoteService).to receive(:new_issue_branch).with(issue, confidential_issue_project, user, "1-feature-branch", branch_project: project)
|
||||
|
||||
create_branch_with_confidential_issue_project
|
||||
end
|
||||
end
|
||||
|
||||
context 'issue is not under the specified project' do
|
||||
it 'does not post a system note' do
|
||||
expect(SystemNoteService).not_to receive(:new_issue_branch)
|
||||
|
||||
create_branch_with_confidential_issue_project
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
context 'create_confidential_merge_request feature is disabled' do
|
||||
before do
|
||||
stub_feature_flags(create_confidential_merge_request: false)
|
||||
end
|
||||
|
||||
it 'posts a system note on project' do
|
||||
expect(SystemNoteService).to receive(:new_issue_branch).with(issue, project, user, "1-feature-branch", branch_project: project)
|
||||
|
||||
create_branch_with_confidential_issue_project
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -1452,24 +1452,8 @@ describe Projects::IssuesController do
|
|||
let(:target_project) { fork_project(project, user, repository: true) }
|
||||
let(:target_project_id) { target_project.id }
|
||||
|
||||
context 'create_confidential_merge_request feature is enabled' do
|
||||
before do
|
||||
stub_feature_flags(create_confidential_merge_request: true)
|
||||
end
|
||||
|
||||
it 'creates a new merge request', :sidekiq_might_not_need_inline do
|
||||
expect { create_merge_request }.to change(target_project.merge_requests, :count).by(1)
|
||||
end
|
||||
end
|
||||
|
||||
context 'create_confidential_merge_request feature is disabled' do
|
||||
before do
|
||||
stub_feature_flags(create_confidential_merge_request: false)
|
||||
end
|
||||
|
||||
it 'creates a new merge request' do
|
||||
expect { create_merge_request }.to change(project.merge_requests, :count).by(1)
|
||||
end
|
||||
it 'creates a new merge request', :sidekiq_might_not_need_inline do
|
||||
expect { create_merge_request }.to change(target_project.merge_requests, :count).by(1)
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
|
|
@ -164,17 +164,7 @@ describe 'User creates branch and merge request on issue page', :js do
|
|||
context 'when issue is confidential' do
|
||||
let(:issue) { create(:issue, :confidential, project: project) }
|
||||
|
||||
it 'disables the create branch button' do
|
||||
stub_feature_flags(create_confidential_merge_request: false)
|
||||
|
||||
visit project_issue_path(project, issue)
|
||||
|
||||
expect(page).not_to have_css('.create-mr-dropdown-wrap')
|
||||
end
|
||||
|
||||
it 'enables the create branch button when feature flag is enabled' do
|
||||
stub_feature_flags(create_confidential_merge_request: true)
|
||||
|
||||
it 'enables the create branch button' do
|
||||
visit project_issue_path(project, issue)
|
||||
|
||||
expect(page).to have_css('.create-mr-dropdown-wrap')
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ describe('init markdown', () => {
|
|||
insertMarkdownText({
|
||||
textArea,
|
||||
text: textArea.value,
|
||||
tag: '*',
|
||||
tag: '* ',
|
||||
blockTag: null,
|
||||
selected: '',
|
||||
wrap: false,
|
||||
|
|
@ -43,7 +43,7 @@ describe('init markdown', () => {
|
|||
insertMarkdownText({
|
||||
textArea,
|
||||
text: textArea.value,
|
||||
tag: '*',
|
||||
tag: '* ',
|
||||
blockTag: null,
|
||||
selected: '',
|
||||
wrap: false,
|
||||
|
|
@ -61,7 +61,7 @@ describe('init markdown', () => {
|
|||
insertMarkdownText({
|
||||
textArea,
|
||||
text: textArea.value,
|
||||
tag: '*',
|
||||
tag: '* ',
|
||||
blockTag: null,
|
||||
selected: '',
|
||||
wrap: false,
|
||||
|
|
@ -79,7 +79,7 @@ describe('init markdown', () => {
|
|||
insertMarkdownText({
|
||||
textArea,
|
||||
text: textArea.value,
|
||||
tag: '*',
|
||||
tag: '* ',
|
||||
blockTag: null,
|
||||
selected: '',
|
||||
wrap: false,
|
||||
|
|
|
|||
|
|
@ -185,7 +185,7 @@ describe('Markdown field component', () => {
|
|||
markdownButton.trigger('click');
|
||||
|
||||
return wrapper.vm.$nextTick(() => {
|
||||
expect(textarea.value).toContain('* testing');
|
||||
expect(textarea.value).toContain('* testing');
|
||||
});
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -17,14 +17,6 @@ describe Mutations::DesignManagement::Delete do
|
|||
let(:mutation) { described_class.new(object: nil, context: { current_user: user }, field: nil) }
|
||||
|
||||
before do
|
||||
# TODO these tests are being temporarily skipped unless run in EE,
|
||||
# as we are in the process of moving Design Management to FOSS in 13.0
|
||||
# in steps. In the current step the services have not yet been moved,
|
||||
# which are used by this mutation.
|
||||
#
|
||||
# See https://gitlab.com/gitlab-org/gitlab/-/issues/212566#note_327724283.
|
||||
skip 'See https://gitlab.com/gitlab-org/gitlab/-/issues/212566#note_327724283' unless Gitlab.ee?
|
||||
|
||||
stub_const('Errors', Gitlab::Graphql::Errors, transfer_nested_constants: true)
|
||||
end
|
||||
|
||||
|
|
|
|||
|
|
@ -37,14 +37,6 @@ describe Mutations::DesignManagement::Upload do
|
|||
|
||||
context "when the feature is available" do
|
||||
before do
|
||||
# TODO these tests are being temporarily skipped unless run in EE,
|
||||
# as we are in the process of moving Design Management to FOSS in 13.0
|
||||
# in steps. In the current step the services have not yet been moved,
|
||||
# which are used by this mutation.
|
||||
#
|
||||
# See https://gitlab.com/gitlab-org/gitlab/-/issues/212566#note_327724283.
|
||||
skip 'See https://gitlab.com/gitlab-org/gitlab/-/issues/212566#note_327724283' unless Gitlab.ee?
|
||||
|
||||
enable_design_management
|
||||
end
|
||||
|
||||
|
|
|
|||
|
|
@ -8,14 +8,14 @@ describe Resolvers::MilestoneResolver do
|
|||
describe '#resolve' do
|
||||
let_it_be(:current_user) { create(:user) }
|
||||
|
||||
def resolve_group_milestones(args = {}, context = { current_user: current_user })
|
||||
resolve(described_class, obj: group, args: args, ctx: context)
|
||||
end
|
||||
|
||||
context 'for group milestones' do
|
||||
let_it_be(:now) { Time.now }
|
||||
let_it_be(:group) { create(:group, :private) }
|
||||
|
||||
def resolve_group_milestones(args = {}, context = { current_user: current_user })
|
||||
resolve(described_class, obj: group, args: args, ctx: context)
|
||||
end
|
||||
|
||||
before do
|
||||
group.add_developer(current_user)
|
||||
end
|
||||
|
|
@ -89,5 +89,25 @@ describe Resolvers::MilestoneResolver do
|
|||
end
|
||||
end
|
||||
end
|
||||
|
||||
context 'when including descendant milestones in a public group' do
|
||||
let_it_be(:group) { create(:group, :public) }
|
||||
let(:args) { { include_descendants: true } }
|
||||
|
||||
it 'finds milestones only in accessible projects and groups' do
|
||||
accessible_group = create(:group, :private, parent: group)
|
||||
accessible_project = create(:project, group: accessible_group)
|
||||
accessible_group.add_developer(current_user)
|
||||
inaccessible_group = create(:group, :private, parent: group)
|
||||
inaccessible_project = create(:project, :private, group: group)
|
||||
milestone1 = create(:milestone, group: group)
|
||||
milestone2 = create(:milestone, group: accessible_group)
|
||||
milestone3 = create(:milestone, project: accessible_project)
|
||||
create(:milestone, group: inaccessible_group)
|
||||
create(:milestone, project: inaccessible_project)
|
||||
|
||||
expect(resolve_group_milestones(args)).to match_array([milestone1, milestone2, milestone3])
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@ describe Gitlab::Kubernetes::Helm::Parsers::ListV2 do
|
|||
it 'raises an error on invalid JSON' do
|
||||
expect do
|
||||
described_class.new('')
|
||||
end.to raise_error(described_class::ParserError, 'A JSON text must at least contain two octets!')
|
||||
end.to raise_error(described_class::ParserError)
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
|
|
@ -342,3 +342,19 @@ describe PersonalSnippet, 'Mentionable' do
|
|||
end
|
||||
end
|
||||
end
|
||||
|
||||
describe DesignManagement::Design do
|
||||
describe '#store_mentions!' do
|
||||
it_behaves_like 'mentions in notes', :design do
|
||||
let(:note) { create(:diff_note_on_design) }
|
||||
let(:mentionable) { note.noteable }
|
||||
end
|
||||
end
|
||||
|
||||
describe 'load mentions' do
|
||||
it_behaves_like 'load mentions from DB', :design do
|
||||
let(:note) { create(:diff_note_on_design) }
|
||||
let(:mentionable) { note.noteable }
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -2876,7 +2876,7 @@ describe Repository do
|
|||
end
|
||||
|
||||
describe '#lfs_enabled?' do
|
||||
let_it_be(:project) { create(:project, :repository, lfs_enabled: true) }
|
||||
let_it_be(:project) { create(:project, :repository, :design_repo, lfs_enabled: true) }
|
||||
|
||||
subject { repository.lfs_enabled? }
|
||||
|
||||
|
|
@ -2933,5 +2933,21 @@ describe Repository do
|
|||
is_expected.to be_falsy
|
||||
end
|
||||
end
|
||||
|
||||
context 'for a design repository' do
|
||||
let(:repository) { project.design_repository }
|
||||
|
||||
it 'returns true when LFS is enabled' do
|
||||
stub_lfs_setting(enabled: true)
|
||||
|
||||
is_expected.to be_truthy
|
||||
end
|
||||
|
||||
it 'returns false when LFS is disabled' do
|
||||
stub_lfs_setting(enabled: false)
|
||||
|
||||
is_expected.to be_falsy
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ describe 'Milestones through GroupQuery' do
|
|||
|
||||
let_it_be(:user) { create(:user) }
|
||||
let_it_be(:now) { Time.now }
|
||||
let_it_be(:group) { create(:group, :private) }
|
||||
let_it_be(:group) { create(:group) }
|
||||
let_it_be(:milestone_1) { create(:milestone, group: group) }
|
||||
let_it_be(:milestone_2) { create(:milestone, group: group, state: :closed, start_date: now, due_date: now + 1.day) }
|
||||
let_it_be(:milestone_3) { create(:milestone, group: group, start_date: now, due_date: now + 2.days) }
|
||||
|
|
@ -17,10 +17,6 @@ describe 'Milestones through GroupQuery' do
|
|||
let(:milestone_data) { graphql_data['group']['milestones']['edges'] }
|
||||
|
||||
describe 'Get list of milestones from a group' do
|
||||
before do
|
||||
group.add_developer(user)
|
||||
end
|
||||
|
||||
context 'when the request is correct' do
|
||||
before do
|
||||
fetch_milestones(user)
|
||||
|
|
@ -51,6 +47,48 @@ describe 'Milestones through GroupQuery' do
|
|||
end
|
||||
end
|
||||
|
||||
context 'when including milestones from decendants' do
|
||||
let_it_be(:accessible_group) { create(:group, :private, parent: group) }
|
||||
let_it_be(:accessible_project) { create(:project, group: accessible_group) }
|
||||
let_it_be(:inaccessible_group) { create(:group, :private, parent: group) }
|
||||
let_it_be(:inaccessible_project) { create(:project, :private, group: group) }
|
||||
let_it_be(:submilestone_1) { create(:milestone, group: accessible_group) }
|
||||
let_it_be(:submilestone_2) { create(:milestone, project: accessible_project) }
|
||||
let_it_be(:submilestone_3) { create(:milestone, group: inaccessible_group) }
|
||||
let_it_be(:submilestone_4) { create(:milestone, project: inaccessible_project) }
|
||||
|
||||
let(:args) { { include_descendants: true } }
|
||||
|
||||
before do
|
||||
accessible_group.add_developer(user)
|
||||
end
|
||||
|
||||
it 'returns milestones also from subgroups and subprojects visible to user' do
|
||||
fetch_milestones(user, args)
|
||||
|
||||
expect_array_response(
|
||||
milestone_1.to_global_id.to_s, milestone_2.to_global_id.to_s,
|
||||
milestone_3.to_global_id.to_s, milestone_4.to_global_id.to_s,
|
||||
submilestone_1.to_global_id.to_s, submilestone_2.to_global_id.to_s
|
||||
)
|
||||
end
|
||||
|
||||
context 'when group_milestone_descendants is disabled' do
|
||||
before do
|
||||
stub_feature_flags(group_milestone_descendants: false)
|
||||
end
|
||||
|
||||
it 'ignores descendant milestones' do
|
||||
fetch_milestones(user, args)
|
||||
|
||||
expect_array_response(
|
||||
milestone_1.to_global_id.to_s, milestone_2.to_global_id.to_s,
|
||||
milestone_3.to_global_id.to_s, milestone_4.to_global_id.to_s
|
||||
)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def fetch_milestones(user = nil, args = {})
|
||||
post_graphql(milestones_query(args), current_user: user)
|
||||
end
|
||||
|
|
|
|||
|
|
@ -29,14 +29,6 @@ describe "deleting designs" do
|
|||
end
|
||||
|
||||
before do
|
||||
# TODO these tests are being temporarily skipped unless run in EE,
|
||||
# as we are in the process of moving Design Management to FOSS in 13.0
|
||||
# in steps. In the current step the services have not yet been moved,
|
||||
# which are used by this mutation.
|
||||
#
|
||||
# See https://gitlab.com/gitlab-org/gitlab/-/issues/212566#note_327724283.
|
||||
skip 'See https://gitlab.com/gitlab-org/gitlab/-/issues/212566#note_327724283' unless Gitlab.ee?
|
||||
|
||||
enable_design_management
|
||||
|
||||
project.add_developer(developer)
|
||||
|
|
|
|||
|
|
@ -24,14 +24,6 @@ describe "uploading designs" do
|
|||
let(:mutation_response) { graphql_mutation_response(:design_management_upload) }
|
||||
|
||||
before do
|
||||
# TODO these tests are being temporarily skipped unless run in EE,
|
||||
# as we are in the process of moving Design Management to FOSS in 13.0
|
||||
# in steps. In the current step the services have not yet been moved,
|
||||
# which are used by this mutation.
|
||||
#
|
||||
# See https://gitlab.com/gitlab-org/gitlab/-/issues/212566#note_327724283.
|
||||
skip 'See https://gitlab.com/gitlab-org/gitlab/-/issues/212566#note_327724283' unless Gitlab.ee?
|
||||
|
||||
enable_design_management
|
||||
|
||||
project.add_developer(current_user)
|
||||
|
|
|
|||
|
|
@ -6,16 +6,6 @@ describe 'Getting designs related to an issue' do
|
|||
include GraphqlHelpers
|
||||
include DesignManagementTestHelpers
|
||||
|
||||
before_all do
|
||||
# TODO these tests are being temporarily skipped unless run in EE,
|
||||
# as we are in the process of moving Design Management to FOSS in 13.0
|
||||
# in steps. In the current step the services have not yet been moved,
|
||||
# which are used by the `:with_smaller_image_versions` factory trait.
|
||||
#
|
||||
# See https://gitlab.com/gitlab-org/gitlab/-/issues/212566#note_327724283.
|
||||
skip 'See https://gitlab.com/gitlab-org/gitlab/-/issues/212566#note_327724283' unless Gitlab.ee?
|
||||
end
|
||||
|
||||
let_it_be(:design) { create(:design, :with_smaller_image_versions, versions_count: 1) }
|
||||
let_it_be(:current_user) { design.project.owner }
|
||||
let(:design_query) do
|
||||
|
|
|
|||
|
|
@ -29,7 +29,6 @@ RSpec.shared_examples 'variable list' do
|
|||
page.within('.js-ci-variable-list-section .js-row:last-child') do
|
||||
find('.js-ci-variable-input-key').set('key')
|
||||
find('.js-ci-variable-input-value').set('key_value')
|
||||
find('.ci-variable-protected-item .js-project-feature-toggle').click
|
||||
|
||||
expect(find('.js-ci-variable-input-protected', visible: false).value).to eq('true')
|
||||
end
|
||||
|
|
@ -173,6 +172,7 @@ RSpec.shared_examples 'variable list' do
|
|||
page.within('.js-ci-variable-list-section .js-row:last-child') do
|
||||
find('.js-ci-variable-input-key').set('unprotected_key')
|
||||
find('.js-ci-variable-input-value').set('unprotected_value')
|
||||
find('.ci-variable-protected-item .js-project-feature-toggle').click
|
||||
|
||||
expect(find('.js-ci-variable-input-protected', visible: false).value).to eq('false')
|
||||
end
|
||||
|
|
@ -207,7 +207,6 @@ RSpec.shared_examples 'variable list' do
|
|||
page.within('.js-ci-variable-list-section .js-row:last-child') do
|
||||
find('.js-ci-variable-input-key').set('protected_key')
|
||||
find('.js-ci-variable-input-value').set('protected_value')
|
||||
find('.ci-variable-protected-item .js-project-feature-toggle').click
|
||||
|
||||
expect(find('.js-ci-variable-input-protected', visible: false).value).to eq('true')
|
||||
end
|
||||
|
|
|
|||
|
|
@ -119,4 +119,16 @@ describe 'gitlab:uploads:migrate and migrate_to_local rake tasks' do
|
|||
|
||||
it_behaves_like 'enqueue upload migration jobs in batch', batch: 4
|
||||
end
|
||||
|
||||
context 'for DesignManagement::DesignV432x230Uploader' do
|
||||
let(:uploader_class) { DesignManagement::DesignV432x230Uploader }
|
||||
let(:model_class) { DesignManagement::Action }
|
||||
let(:mounted_as) { :image_v432x230 }
|
||||
|
||||
before do
|
||||
create_list(:design_action, 10, :with_image_v432x230)
|
||||
end
|
||||
|
||||
it_behaves_like 'enqueue upload migration jobs in batch', batch: 4
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -65,4 +65,16 @@ describe ObjectStorage::MigrateUploadsWorker do
|
|||
end
|
||||
end
|
||||
end
|
||||
|
||||
context 'for DesignManagement::DesignV432x230Uploader' do
|
||||
let(:model_class) { DesignManagement::Action }
|
||||
let!(:design_actions) { create_list(:design_action, 10, :with_image_v432x230) }
|
||||
let(:mounted_as) { :image_v432x230 }
|
||||
|
||||
before do
|
||||
stub_uploads_object_storage(DesignManagement::DesignV432x230Uploader)
|
||||
end
|
||||
|
||||
it_behaves_like 'uploads migration worker'
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -471,4 +471,17 @@ describe PostReceive do
|
|||
it_behaves_like 'snippet changes actions'
|
||||
end
|
||||
end
|
||||
|
||||
describe 'processing design changes' do
|
||||
let(:gl_repository) { "design-#{project.id}" }
|
||||
|
||||
it 'does not do anything' do
|
||||
worker = described_class.new
|
||||
|
||||
expect(worker).not_to receive(:process_wiki_changes)
|
||||
expect(worker).not_to receive(:process_project_changes)
|
||||
|
||||
described_class.new.perform(gl_repository, key_id, base64_changes)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Reference in New Issue