diff options
26 files changed, 66 insertions, 20 deletions
diff --git a/GITLAB_KAS_VERSION b/GITLAB_KAS_VERSION index c915b5db730..188dd74f5f5 100644 --- a/GITLAB_KAS_VERSION +++ b/GITLAB_KAS_VERSION @@ -1 +1 @@ -15.4.0 +15.5.0 diff --git a/app/assets/javascripts/boards/components/board_card_inner.vue b/app/assets/javascripts/boards/components/board_card_inner.vue index 93beb014099..3a2b11a649d 100644 --- a/app/assets/javascripts/boards/components/board_card_inner.vue +++ b/app/assets/javascripts/boards/components/board_card_inner.vue @@ -250,7 +250,8 @@ export default { >{{ item.title }}</a > </h4> - <board-card-move-to-position :item="item" :list="list" :index="index" /> + <!-- TODO: remove the condition when https://gitlab.com/gitlab-org/gitlab/-/issues/377862 is resolved --> + <board-card-move-to-position v-if="!isEpicBoard" :item="item" :list="list" :index="index" /> </div> <div v-if="showLabelFooter" class="board-card-labels gl-mt-2 gl-display-flex gl-flex-wrap"> <template v-for="label in orderedLabels"> diff --git a/app/controllers/projects/product_analytics_controller.rb b/app/controllers/projects/product_analytics_controller.rb index c89cd52530a..8085b0a6334 100644 --- a/app/controllers/projects/product_analytics_controller.rb +++ b/app/controllers/projects/product_analytics_controller.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true class Projects::ProductAnalyticsController < Projects::ApplicationController - before_action :feature_enabled! + before_action :feature_enabled!, only: [:index, :setup, :test, :graphs] before_action :authorize_read_product_analytics! before_action :tracker_variables, only: [:setup, :test] @@ -57,3 +57,5 @@ class Projects::ProductAnalyticsController < Projects::ApplicationController render_404 unless Feature.enabled?(:product_analytics, @project) end end + +Projects::ProductAnalyticsController.prepend_mod_with('Projects::ProductAnalyticsController') diff --git a/app/graphql/types/ci/job_type.rb b/app/graphql/types/ci/job_type.rb index 8da6532dcd8..4447a10a74e 100644 --- a/app/graphql/types/ci/job_type.rb +++ b/app/graphql/types/ci/job_type.rb @@ -56,6 +56,8 @@ module Types description: 'Indicates the job is active.' field :artifacts, Types::Ci::JobArtifactType.connection_type, null: true, description: 'Artifacts generated by the job.' + field :browse_artifacts_path, GraphQL::Types::String, null: true, + description: "URL for browsing the artifact's archive." field :cancelable, GraphQL::Types::Boolean, null: false, method: :cancelable?, description: 'Indicates the job can be canceled.' field :commit_path, GraphQL::Types::String, null: true, @@ -177,6 +179,10 @@ module Types ::Gitlab::Routing.url_helpers.project_job_path(object.project, object) end + def browse_artifacts_path + ::Gitlab::Routing.url_helpers.browse_project_job_artifacts_path(object.project, object) + end + def coverage object&.coverage end diff --git a/app/views/admin/application_settings/_issue_limits.html.haml b/app/views/admin/application_settings/_issue_limits.html.haml index 431e2a64c46..147aab443b2 100644 --- a/app/views/admin/application_settings/_issue_limits.html.haml +++ b/app/views/admin/application_settings/_issue_limits.html.haml @@ -6,4 +6,4 @@ = f.label :issues_create_limit, _('Maximum number of requests per minute') = f.number_field :issues_create_limit, class: 'form-control gl-form-input' - = f.submit _('Save changes'), class: "gl-button btn btn-confirm", data: { qa_selector: 'save_changes_button' } + = f.submit _('Save changes'), data: { qa_selector: 'save_changes_button' }, pajamas_button: true diff --git a/app/views/admin/application_settings/_note_limits.html.haml b/app/views/admin/application_settings/_note_limits.html.haml index 40760b3c45e..99cf0ebc669 100644 --- a/app/views/admin/application_settings/_note_limits.html.haml +++ b/app/views/admin/application_settings/_note_limits.html.haml @@ -1,4 +1,4 @@ -= form_for @application_setting, url: network_admin_application_settings_path(anchor: 'js-note-limits-settings'), html: { class: 'fieldset-form' } do |f| += gitlab_ui_form_for @application_setting, url: network_admin_application_settings_path(anchor: 'js-note-limits-settings'), html: { class: 'fieldset-form' } do |f| = form_errors(@application_setting) %fieldset @@ -12,4 +12,4 @@ = _('List of users who are allowed to exceed the rate limit. Example: username1, username2') - = f.submit _('Save changes'), class: "gl-button btn btn-confirm", data: { qa_selector: 'save_changes_button' } + = f.submit _('Save changes'), data: { qa_selector: 'save_changes_button' }, pajamas_button: true diff --git a/app/views/admin/application_settings/_performance.html.haml b/app/views/admin/application_settings/_performance.html.haml index e0ba8d93fbd..86a01e1785e 100644 --- a/app/views/admin/application_settings/_performance.html.haml +++ b/app/views/admin/application_settings/_performance.html.haml @@ -23,4 +23,4 @@ .form-text.text-muted = _('Threshold number of changes (branches or tags) in a single push above which a bulk push event is created (default is 3).') - = f.submit _('Save changes'), class: "gl-button btn btn-confirm" + = f.submit _('Save changes'), pajamas_button: true diff --git a/app/views/admin/application_settings/_protected_paths.html.haml b/app/views/admin/application_settings/_protected_paths.html.haml index 1f3f67c71c7..3a7a951d137 100644 --- a/app/views/admin/application_settings/_protected_paths.html.haml +++ b/app/views/admin/application_settings/_protected_paths.html.haml @@ -21,4 +21,4 @@ - relative_url_link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: relative_url_link } = _('All paths are relative to the GitLab URL. Do not include %{relative_url_link_start}relative URLs%{relative_url_link_end}.').html_safe % { relative_url_link_start: relative_url_link_start, relative_url_link_end: '</a>'.html_safe } - = f.submit _('Save changes'), class: 'gl-button btn btn-confirm' + = f.submit _('Save changes'), pajamas_button: true diff --git a/app/views/admin/application_settings/_whats_new.html.haml b/app/views/admin/application_settings/_whats_new.html.haml index 3248969ca16..986402ad5f1 100644 --- a/app/views/admin/application_settings/_whats_new.html.haml +++ b/app/views/admin/application_settings/_whats_new.html.haml @@ -5,4 +5,4 @@ .gl-mb-4 = f.gitlab_ui_radio_component :whats_new_variant, variant, whats_new_variants_label(variant), help_text: whats_new_variants_description(variant) - = f.submit _('Save changes'), class: "gl-button btn btn-confirm" + = f.submit _('Save changes'), pajamas_button: true diff --git a/app/views/profiles/keys/_form.html.haml b/app/views/profiles/keys/_form.html.haml index 6f7eb21b7e0..b37a0d9cc1a 100644 --- a/app/views/profiles/keys/_form.html.haml +++ b/app/views/profiles/keys/_form.html.haml @@ -1,6 +1,6 @@ - max_date = ::Gitlab::CurrentSettings.max_ssh_key_lifetime_from_now.to_date if ssh_key_expiration_policy_enabled? %div - = form_for [:profile, @key], html: { class: 'js-requires-input' } do |f| + = gitlab_ui_form_for [:profile, @key], html: { class: 'js-requires-input' } do |f| = form_errors(@key) .form-group @@ -29,4 +29,4 @@ button_options: { class: 'js-add-ssh-key-validation-confirm-submit' }) do = _("Yes, add it") .gl-mt-3 - = f.submit s_('Profiles|Add key'), class: "gl-button btn btn-confirm js-add-ssh-key-validation-original-submit qa-add-key-button" + = f.submit s_('Profiles|Add key'), class: "js-add-ssh-key-validation-original-submit qa-add-key-button", pajamas_button: true diff --git a/app/views/profiles/passwords/edit.html.haml b/app/views/profiles/passwords/edit.html.haml index 75b272cefe8..99c89dcebb4 100644 --- a/app/views/profiles/passwords/edit.html.haml +++ b/app/views/profiles/passwords/edit.html.haml @@ -14,7 +14,7 @@ = _('Change your password') - else = _('Change your password or recover your current one') - = form_for @user, url: profile_password_path, method: :put, html: {class: "update-password"} do |f| + = gitlab_ui_form_for @user, url: profile_password_path, method: :put, html: {class: "update-password"} do |f| = form_errors(@user) - unless @user.password_automatically_set? @@ -31,6 +31,7 @@ = f.label :password_confirmation, _('Password confirmation'), class: 'label-bold' = f.password_field :password_confirmation, required: true, autocomplete: 'new-password', class: 'form-control gl-form-input', data: { qa_selector: 'confirm_password_field' } .gl-mt-3.gl-mb-3 - = f.submit _('Save password'), class: "gl-button btn btn-confirm gl-mr-3", data: { qa_selector: 'save_password_button' } + = f.submit _('Save password'), class: "gl-mr-3", data: { qa_selector: 'save_password_button' }, pajamas_button: true - unless @user.password_automatically_set? - = link_to _('I forgot my password'), reset_profile_password_path, method: :put + = render Pajamas::ButtonComponent.new(href: reset_profile_password_path, variant: :link, method: :put) do + = _('I forgot my password') diff --git a/app/views/profiles/passwords/new.html.haml b/app/views/profiles/passwords/new.html.haml index 6f260eb4cc0..a0a9077afe4 100644 --- a/app/views/profiles/passwords/new.html.haml +++ b/app/views/profiles/passwords/new.html.haml @@ -3,7 +3,7 @@ %h1.page-title.gl-font-size-h-display= _('Set up new password') %hr -= form_for @user, url: profile_password_path, method: :post do |f| += gitlab_ui_form_for @user, url: profile_password_path, method: :post do |f| %p.slead = _('Please set a new password before proceeding.') %br @@ -29,4 +29,4 @@ .col-sm-10 = f.password_field :password_confirmation, required: true, autocomplete: 'new-password', class: 'form-control gl-form-input', data: { qa_selector: 'confirm_password_field' } .form-actions - = f.submit _('Set new password'), class: 'gl-button btn btn-confirm', data: { qa_selector: 'set_new_password_button' } + = f.submit _('Set new password'), data: { qa_selector: 'set_new_password_button' }, pajamas_button: true diff --git a/app/views/projects/cleanup/_show.html.haml b/app/views/projects/cleanup/_show.html.haml index c53205b6c58..d00d9f62999 100644 --- a/app/views/projects/cleanup/_show.html.haml +++ b/app/views/projects/cleanup/_show.html.haml @@ -16,7 +16,7 @@ .settings-content - url = cleanup_namespace_project_settings_repository_path(@project.namespace, @project) - = form_for @project, url: url, method: :post, authenticity_token: true, html: { class: 'js-requires-input' } do |f| + = gitlab_ui_form_for @project, url: url, method: :post, authenticity_token: true, html: { class: 'js-requires-input' } do |f| %fieldset.gl-mt-0.gl-mb-3 .gl-mb-3 %h5.gl-mt-0 @@ -29,4 +29,4 @@ .form-text.text-muted = _("The maximum file size is %{size}.") % { size: number_to_human_size(Gitlab::CurrentSettings.max_attachment_size.megabytes) } - = f.submit _('Start cleanup'), class: 'gl-button btn btn-confirm' + = f.submit _('Start cleanup'), pajamas_button: true diff --git a/app/views/projects/default_branch/_show.html.haml b/app/views/projects/default_branch/_show.html.haml index 23b46e02202..04712cd59f7 100644 --- a/app/views/projects/default_branch/_show.html.haml +++ b/app/views/projects/default_branch/_show.html.haml @@ -26,4 +26,4 @@ _("Auto-close referenced issues on default branch"), help_text: (help_text + " " + help_icon).html_safe - = f.submit _('Save changes'), class: "gl-button btn btn-confirm", data: { qa_selector: 'save_changes_button' } + = f.submit _('Save changes'), data: { qa_selector: 'save_changes_button' }, pajamas_button: true diff --git a/doc/api/graphql/reference/index.md b/doc/api/graphql/reference/index.md index 4424e278648..c47cea4a1de 100644 --- a/doc/api/graphql/reference/index.md +++ b/doc/api/graphql/reference/index.md @@ -10466,6 +10466,7 @@ CI/CD variables for a GitLab instance. | <a id="cijobactive"></a>`active` | [`Boolean!`](#boolean) | Indicates the job is active. | | <a id="cijoballowfailure"></a>`allowFailure` | [`Boolean!`](#boolean) | Whether the job is allowed to fail. | | <a id="cijobartifacts"></a>`artifacts` | [`CiJobArtifactConnection`](#cijobartifactconnection) | Artifacts generated by the job. (see [Connections](#connections)) | +| <a id="cijobbrowseartifactspath"></a>`browseArtifactsPath` | [`String`](#string) | URL for browsing the artifact's archive. | | <a id="cijobcancelable"></a>`cancelable` | [`Boolean!`](#boolean) | Indicates the job can be canceled. | | <a id="cijobcommitpath"></a>`commitPath` | [`String`](#string) | Path to the commit that triggered the job. | | <a id="cijobcoverage"></a>`coverage` | [`Float`](#float) | Coverage level of the job. | diff --git a/doc/ci/variables/index.md b/doc/ci/variables/index.md index c38b44f8a98..81004b5ba42 100644 --- a/doc/ci/variables/index.md +++ b/doc/ci/variables/index.md @@ -682,7 +682,10 @@ The order of precedence for variables is (from highest to lowest): - [Manual pipeline run variables](#override-a-variable-when-running-a-pipeline-manually). - Variables added when [creating a pipeline with the API](../../api/pipelines.md#create-a-new-pipeline). 1. Project [variables](#custom-cicd-variables). -1. Group [variables](#add-a-cicd-variable-to-a-group). +1. Group [variables](#add-a-cicd-variable-to-a-group). If the same variable name exists in a + group and its subgroups, the job uses the value from the closest subgroup. For example, if + you have `Group > Subgroup 1 > Subgroup 2 > Project`, the variable defined in + `Subgroup 2` takes precedence. 1. Instance [variables](#add-a-cicd-variable-to-an-instance). 1. [Inherited variables](#pass-an-environment-variable-to-another-job). 1. Variables defined in jobs in the `.gitlab-ci.yml` file. diff --git a/doc/user/application_security/secret_detection/index.md b/doc/user/application_security/secret_detection/index.md index fe6159606a9..df6bb19ac25 100644 --- a/doc/user/application_security/secret_detection/index.md +++ b/doc/user/application_security/secret_detection/index.md @@ -120,6 +120,10 @@ To enable Secret Detection using a merge request: Pipelines now include a Secret Detection job, and the results are included in the merge request widget. +## Responding to a leaked secret + +If the scanner detects a secret we recommend you rotate it immediately. [Purging a file from the repository's history](../../project/repository/reducing_the_repo_size_using_git.md#purge-files-from-repository-history) may not be effective in removing all references to the file. Also, the secret remains in any forks of the repository. + ## Configure scan settings The Secret Detection scan settings can be changed through [CI/CD variables](#available-cicd-variables) diff --git a/lib/gitlab/ci/templates/Pages/Gatsby.gitlab-ci.yml b/lib/gitlab/ci/templates/Pages/Gatsby.gitlab-ci.yml index 9da50439be8..88ed73b41e7 100644 --- a/lib/gitlab/ci/templates/Pages/Gatsby.gitlab-ci.yml +++ b/lib/gitlab/ci/templates/Pages/Gatsby.gitlab-ci.yml @@ -20,3 +20,4 @@ pages: - public rules: - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH + environment: production diff --git a/lib/gitlab/ci/templates/Pages/Jekyll.gitlab-ci.yml b/lib/gitlab/ci/templates/Pages/Jekyll.gitlab-ci.yml index e0ad2e55f7d..8b07454af24 100644 --- a/lib/gitlab/ci/templates/Pages/Jekyll.gitlab-ci.yml +++ b/lib/gitlab/ci/templates/Pages/Jekyll.gitlab-ci.yml @@ -36,3 +36,4 @@ pages: only: variables: - $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH + environment: production diff --git a/lib/gitlab/ci/templates/Pages/Lektor.gitlab-ci.yml b/lib/gitlab/ci/templates/Pages/Lektor.gitlab-ci.yml index 9b5c1198c6c..e86337ae23c 100644 --- a/lib/gitlab/ci/templates/Pages/Lektor.gitlab-ci.yml +++ b/lib/gitlab/ci/templates/Pages/Lektor.gitlab-ci.yml @@ -15,3 +15,4 @@ pages: - public rules: - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH + environment: production diff --git a/lib/gitlab/ci/templates/Pages/Nanoc.gitlab-ci.yml b/lib/gitlab/ci/templates/Pages/Nanoc.gitlab-ci.yml index a3ce96da244..b0511abd109 100644 --- a/lib/gitlab/ci/templates/Pages/Nanoc.gitlab-ci.yml +++ b/lib/gitlab/ci/templates/Pages/Nanoc.gitlab-ci.yml @@ -15,3 +15,4 @@ pages: - public rules: - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH + environment: production diff --git a/lib/gitlab/ci/templates/Pages/Octopress.gitlab-ci.yml b/lib/gitlab/ci/templates/Pages/Octopress.gitlab-ci.yml index 4abdf66a21c..c89050eede7 100644 --- a/lib/gitlab/ci/templates/Pages/Octopress.gitlab-ci.yml +++ b/lib/gitlab/ci/templates/Pages/Octopress.gitlab-ci.yml @@ -18,3 +18,4 @@ pages: - public rules: - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH + environment: production diff --git a/locale/gitlab.pot b/locale/gitlab.pot index 4e4aebd22a8..516a979f862 100644 --- a/locale/gitlab.pot +++ b/locale/gitlab.pot @@ -11994,6 +11994,9 @@ msgstr "" msgid "DashboardProjects|Trending" msgstr "" +msgid "Dashboards" +msgstr "" + msgid "Dashboard|%{firstProject} and %{secondProject}" msgstr "" diff --git a/qa/qa/page/component/namespace_select.rb b/qa/qa/page/component/namespace_select.rb index 41a9975003f..9b483162f1b 100644 --- a/qa/qa/page/component/namespace_select.rb +++ b/qa/qa/page/component/namespace_select.rb @@ -20,6 +20,8 @@ module QA def select_namespace(item) click_element :namespaces_list + wait_for_requests + within_element(:namespaces_list) do fill_element(:namespaces_list_search, item) diff --git a/spec/frontend/boards/board_card_inner_spec.js b/spec/frontend/boards/board_card_inner_spec.js index ab80f306ec5..3ebc51c4bcb 100644 --- a/spec/frontend/boards/board_card_inner_spec.js +++ b/spec/frontend/boards/board_card_inner_spec.js @@ -595,5 +595,10 @@ describe('Board card component', () => { expect(findEpicCountablesTotalWeight().text()).toBe('15'); expect(findEpicProgressTooltip().text()).toBe('10 of 15 weight completed'); }); + + it('does not render the move to position icon', () => { + createWrapper(); + expect(findMoveToPositionComponent().exists()).toBe(false); + }); }); }); diff --git a/spec/graphql/types/ci/job_type_spec.rb b/spec/graphql/types/ci/job_type_spec.rb index b3dee082d1f..ce1558c4097 100644 --- a/spec/graphql/types/ci/job_type_spec.rb +++ b/spec/graphql/types/ci/job_type_spec.rb @@ -13,6 +13,7 @@ RSpec.describe Types::Ci::JobType do active allow_failure artifacts + browse_artifacts_path cancelable commitPath coverage @@ -64,4 +65,16 @@ RSpec.describe Types::Ci::JobType do is_expected.to eq("/#{project.full_path}/-/jobs/#{build.id}") end end + + describe '#browse_artifacts_path' do + subject { resolve_field(:browse_artifacts_path, build, current_user: user, object_type: described_class) } + + let_it_be(:project) { create(:project) } + let(:user) { create(:user) } + let(:build) { create(:ci_build, :artifacts, project: project, user: user) } + + it 'returns the path to browse the artifacts of the job' do + is_expected.to eq("/#{project.full_path}/-/jobs/#{build.id}/artifacts/browse") + end + end end |