Commit 44fdf983 authored by GitLab Bot's avatar GitLab Bot

Add latest changes from gitlab-org/gitlab@12-10-stable-ee

parent bc9fa07b
......@@ -37,7 +37,7 @@ If applicable, any groups/projects that are happy to have this feature turned on
- [ ] Coordinate a time to enable the flag with `#production` and `#g_delivery` on slack.
- [ ] Announce on the issue an estimated time this will be enabled on GitLab.com
- [ ] Enable on GitLab.com by running chatops command in `#production`
- [ ] Cross post chatops slack command to `#support_gitlab-com` and in your team channel
- [ ] Cross post chatops slack command to `#support_gitlab-com` ([more guidance when this is necessary in the dev docs](https://docs.gitlab.com/ee/development/feature_flags/controls.html#where-to-run-commands)) and in your team channel
- [ ] Announce on the issue that the flag has been enabled
- [ ] Remove feature flag and add changelog entry
- [ ] After the flag removal is deployed, [clean up the feature flag](https://docs.gitlab.com/ee/development/feature_flags/controls.html#cleaning-up) by running chatops command in `#production` channel
......
This diff is collapsed.
<script>
import { mapActions, mapState } from 'vuex';
import { mapActions, mapGetters, mapState } from 'vuex';
import { GlAlert, GlSprintf, GlLink } from '@gitlab/ui';
import { s__ } from '~/locale';
......@@ -15,8 +15,15 @@ export default {
GlLink,
},
i18n: {
unavailableFeatureText: s__(
'ContainerRegistry|Currently, the Container Registry tag expiration feature is not available for projects created before GitLab version 12.8. For updates and more information, visit Issue %{linkStart}#196124%{linkEnd}',
unavailableFeatureTitle: s__(
`ContainerRegistry|Container Registry tag expiration and retention policy is disabled`,
),
unavailableFeatureIntroText: s__(
`ContainerRegistry|The Container Registry tag expiration and retention policies for this project have not been enabled.`,
),
unavailableUserFeatureText: s__(`ContainerRegistry|Please contact your administrator.`),
unavailableAdminFeatureText: s__(
`ContainerRegistry| Please visit the %{linkStart}administration settings%{linkEnd} to enable this feature.`,
),
fetchSettingsErrorText: FETCH_SETTINGS_ERROR_MESSAGE,
},
......@@ -26,10 +33,19 @@ export default {
};
},
computed: {
...mapState(['isDisabled']),
...mapState(['isAdmin', 'adminSettingsPath']),
...mapGetters({ isDisabled: 'getIsDisabled' }),
showSettingForm() {
return !this.isDisabled && !this.fetchSettingsError;
},
showDisabledFormMessage() {
return this.isDisabled && !this.fetchSettingsError;
},
unavailableFeatureMessage() {
return this.isAdmin
? this.$options.i18n.unavailableAdminFeatureText
: this.$options.i18n.unavailableUserFeatureText;
},
},
mounted() {
this.fetchSettings().catch(() => {
......@@ -59,16 +75,21 @@ export default {
</ul>
<settings-form v-if="showSettingForm" />
<template v-else>
<gl-alert v-if="isDisabled" :dismissible="false">
<p>
<gl-sprintf :message="$options.i18n.unavailableFeatureText">
<template #link="{content}">
<gl-link href="https://gitlab.com/gitlab-org/gitlab/issues/196124" target="_blank">
<gl-alert
v-if="showDisabledFormMessage"
:dismissible="false"
:title="$options.i18n.unavailableFeatureTitle"
variant="tip"
>
{{ $options.i18n.unavailableFeatureIntroText }}
<gl-sprintf :message="unavailableFeatureMessage">
<template #link="{ content }">
<gl-link :href="adminSettingsPath" target="_blank">
{{ content }}
</gl-link>
</template>
</gl-sprintf>
</p>
</gl-alert>
<gl-alert v-else-if="fetchSettingsError" variant="warning" :dismissible="false">
<gl-sprintf :message="$options.i18n.fetchSettingsErrorText" />
......
......@@ -5,11 +5,7 @@ export const setInitialState = ({ commit }, data) => commit(types.SET_INITIAL_ST
export const updateSettings = ({ commit }, data) => commit(types.UPDATE_SETTINGS, data);
export const toggleLoading = ({ commit }) => commit(types.TOGGLE_LOADING);
export const receiveSettingsSuccess = ({ commit }, data) => {
if (data) {
commit(types.SET_SETTINGS, data);
} else {
commit(types.SET_IS_DISABLED, true);
}
};
export const resetSettings = ({ commit }) => commit(types.RESET_SETTINGS);
......
......@@ -19,3 +19,7 @@ export const getSettings = (state, getters) => ({
});
export const getIsEdited = state => !isEqual(state.original, state.settings);
export const getIsDisabled = state => {
return !(state.original || state.enableHistoricEntries);
};
......@@ -3,4 +3,3 @@ export const UPDATE_SETTINGS = 'UPDATE_SETTINGS';
export const TOGGLE_LOADING = 'TOGGLE_LOADING';
export const SET_SETTINGS = 'SET_SETTINGS';
export const RESET_SETTINGS = 'RESET_SETTINGS';
export const SET_IS_DISABLED = 'SET_IS_DISABLED';
import { parseBoolean } from '~/lib/utils/common_utils';
import * as types from './mutation_types';
export default {
......@@ -8,19 +9,19 @@ export default {
keepN: JSON.parse(initialState.keepNOptions),
olderThan: JSON.parse(initialState.olderThanOptions),
};
state.enableHistoricEntries = parseBoolean(initialState.enableHistoricEntries);
state.isAdmin = parseBoolean(initialState.isAdmin);
state.adminSettingsPath = initialState.adminSettingsPath;
},
[types.UPDATE_SETTINGS](state, data) {
state.settings = { ...state.settings, ...data.settings };
},
[types.SET_SETTINGS](state, settings) {
state.settings = settings;
state.settings = settings ?? state.settings;
state.original = Object.freeze(settings);
},
[types.SET_IS_DISABLED](state, isDisabled) {
state.isDisabled = isDisabled;
},
[types.RESET_SETTINGS](state) {
state.settings = { ...state.original };
state.settings = Object.assign({}, state.original);
},
[types.TOGGLE_LOADING](state) {
state.isLoading = !state.isLoading;
......
......@@ -8,9 +8,17 @@ export default () => ({
*/
isLoading: false,
/*
* Boolean to determine if the user is allowed to interact with the form
* Boolean to determine if the user is an admin
*/
isDisabled: false,
isAdmin: false,
/*
* String containing the full path to the admin config page for CI/CD
*/
adminSettingsPath: '',
/*
* Boolean to determine if project created before 12.8 can use this feature
*/
enableHistoricEntries: false,
/*
* This contains the data shown and manipulated in the UI
* Has the following structure:
......@@ -24,9 +32,9 @@ export default () => ({
*/
settings: {},
/*
* Same structure as settings, above but Frozen object and used only in case the user clicks 'cancel'
* Same structure as settings, above but Frozen object and used only in case the user clicks 'cancel', initialized to null
*/
original: {},
original: null,
/*
* Contains the options used to populate the form selects
*/
......
......@@ -202,7 +202,7 @@ const fileExtensionIcons = {
flv: 'movie',
vob: 'movie',
ogv: 'movie',
ogg: 'movie',
ogg: 'music',
gifv: 'movie',
avi: 'movie',
mov: 'movie',
......
......@@ -496,6 +496,10 @@ class ApplicationController < ActionController::Base
html_request? && !devise_controller?
end
def public_visibility_restricted?
Gitlab::CurrentSettings.restricted_visibility_levels.include? Gitlab::VisibilityLevel::PUBLIC
end
def set_usage_stats_consent_flag
return unless current_user
return if sessionless_user?
......
# frozen_string_literal: true
class Explore::ApplicationController < ApplicationController
skip_before_action :authenticate_user!
skip_before_action :authenticate_user!, unless: :public_visibility_restricted?
layout 'explore'
end
# frozen_string_literal: true
class HelpController < ApplicationController
skip_before_action :authenticate_user!
skip_before_action :authenticate_user!, unless: :public_visibility_restricted?
layout 'help'
......
......@@ -51,6 +51,10 @@ module ExploreHelper
links.any? { |link| explore_nav_link?(link) }
end
def public_visibility_restricted?
Gitlab::CurrentSettings.restricted_visibility_levels.include? Gitlab::VisibilityLevel::PUBLIC
end
private
def get_explore_nav_links
......
......@@ -74,7 +74,7 @@ module ServicesHelper
def scoped_integration_path(integration)
if @project.present?
project_settings_integration_path(@project, integration)
project_service_path(@project, integration)
elsif @group.present?
group_settings_integration_path(@group, integration)
else
......
......@@ -14,6 +14,7 @@ class ApplicationSetting < ApplicationRecord
add_authentication_token_field :static_objects_external_storage_auth_token
belongs_to :self_monitoring_project, class_name: "Project", foreign_key: 'instance_administration_project_id'
belongs_to :push_rule
alias_attribute :self_monitoring_project_id, :instance_administration_project_id
belongs_to :instance_administrators_group, class_name: "Group"
......
......@@ -15,6 +15,8 @@ class AlertsService < Service
before_validation :ensure_token, if: :activated?
def url
return if instance? || template?
url_helpers.project_alerts_notify_url(project, format: :json)
end
......
......@@ -9,3 +9,5 @@ class ProjectSetting < ApplicationRecord
where(primary_key => safe_find_or_create_by(attrs))
end
end
ProjectSetting.prepend_if_ee('EE::ProjectSetting')
......@@ -56,7 +56,12 @@ module Groups
end
def tree_exporter
Gitlab::ImportExport::Group::TreeSaver.new(group: @group, current_user: @current_user, shared: @shared, params: @params)
Gitlab::ImportExport::Group::LegacyTreeSaver.new(
group: @group,
current_user: @current_user,
shared: @shared,
params: @params
)
end
def file_saver
......
......@@ -38,7 +38,9 @@
%hr.footer-fixed
.container.footer-container
.footer-links
- if !public_visibility_restricted?
= link_to _("Explore"), explore_root_path
= link_to _("Help"), help_path
= link_to _("About GitLab"), "https://about.gitlab.com/"
= footer_message
......@@ -14,6 +14,7 @@
%hr
.container
.footer-links
- if !public_visibility_restricted?
= link_to _("Explore"), explore_root_path
= link_to _("Help"), help_path
= link_to _("About GitLab"), "https://about.gitlab.com/"
......
#js-registry-settings{ data: { project_id: @project.id,
cadence_options: cadence_options.to_json,
keep_n_options: keep_n_options.to_json,
older_than_options: older_than_options.to_json} }
older_than_options: older_than_options.to_json,
is_admin: current_user&.admin.to_s,
admin_settings_path: ci_cd_admin_application_settings_path(anchor: 'js-registry-settings'),
enable_historic_entries: Gitlab::CurrentSettings.try(:container_expiration_policies_enable_historic_entries).to_s} }
......@@ -10,7 +10,7 @@
- if @service.respond_to?(:detailed_description)
%p= @service.detailed_description
.col-lg-9
= form_for(@service, as: :service, url: project_service_path(@project, @service.to_param), method: :put, html: { class: 'gl-show-field-errors integration-settings-form js-integration-settings-form', data: { 'can-test' => @service.can_test?, 'test-url' => test_project_service_path(@project, @service) } }) do |form|
= form_for(@service, as: :service, url: scoped_integration_path(@service), method: :put, html: { class: 'gl-show-field-errors integration-settings-form js-integration-settings-form', data: { 'can-test' => @service.can_test?, 'test-url' => test_project_service_path(@project, @service) } }) do |form|
= render 'shared/service_settings', form: form, service: @service
- if @service.editable?
.footer-block.row-content-block
......
.js-alerts-service-settings{ data: { activated: @service.activated?.to_s,
form_path: project_service_path(@project, @service.to_param),
authorization_key: @service.token, url: @service.url, learn_more_url: 'https://docs.gitlab.com/ee/user/project/integrations/generic_alerts.html' } }
form_path: scoped_integration_path(@service),
authorization_key: @service.token, url: @service.url || _('<namespace / project>'), learn_more_url: 'https://docs.gitlab.com/ee/user/project/integrations/generic_alerts.html' } }
- run_actions_text = s_("ProjectService|Perform common operations on GitLab project: %{project_name}") % { project_name: @project.full_name }
- pretty_name = @project&.full_name || _('<project name>')
- run_actions_text = s_("ProjectService|Perform common operations on GitLab project: %{project_name}") % { project_name: pretty_name }
%p= s_("ProjectService|To set up this service:")
%ul.list-unstyled.indent-list
......@@ -20,7 +21,7 @@
.form-group
= label_tag :display_name, _('Display name'), class: 'col-12 col-form-label label-bold'
.col-12.input-group
= text_field_tag :display_name, "GitLab / #{@project.full_name}", class: 'form-control form-control-sm', readonly: 'readonly'
= text_field_tag :display_name, "GitLab / #{pretty_name}", class: 'form-control form-control-sm', readonly: 'readonly'
.input-group-append
= clipboard_button(target: '#display_name', class: 'input-group-text')
......@@ -38,6 +39,7 @@
%p
= s_('MattermostService|Suggestions:')
%code= 'gitlab'
- if @project
%code= @project.path # Path contains no spaces, but dashes
%code= @project.full_path
......
- pretty_name = defined?(@project) ? @project.full_name : 'namespace / path'
- run_actions_text = "Perform common operations on GitLab project: #{pretty_name}"
- pretty_name = @project&.full_name || _('<project name>')
- run_actions_text = s_("ProjectService|Perform common operations on GitLab project: %{project_name}") % { project_name: pretty_name }
.info-well
.well-segment
......@@ -31,6 +31,8 @@
%p
= _("Suggestions:")
%code= 'gitlab'
%code= 'project'
- if @project
%code= @project.path # Path contains no spaces, but dashes
%code= @project.full_path
......
---
title: Add an endpoint to allow group admin users to purge the dependency proxy for a group
merge_request: 27843
author:
type: added
---
title: Add Nginx error percentage metric
merge_request: 28983
author:
type: added
---
title: Add Prometheus alerts automatically after Prometheus Service was created
merge_request: 28503
author:
type: added
---
title: Resolve Unable to expand multiple downstream pipelines.
merge_request: 27029
author:
type: fixed
---
title: Update detected languages for dependency scanning in no dind mode
merge_request: 27723
author:
type: fixed
---
title: Update detected languages for sast in no dind mode
merge_request: 27831
author:
type: fixed
---
title: Add limit metric to lists
merge_request: 25532
author:
type: added
---
title: Add usage data metrics for instance level clusters and clusters with management projects
merge_request: 28510
author:
type: added
---
title: Add ability to filter commits by author
merge_request: 28509
author:
type: added
---
title: Add unlock_membership_to_ldap boolean to Groups
merge_request: 26474
author:
type: added
---
title: Fix archived corrupted projects not displaying in admin
merge_request: 25171
author: erickcspice
type: fixed
---
title: "Add support for system note metadata in project Import/Export"
merge_request: 27853
author: Melvin Vermeeren
type: added
---
title: Use Ruby 2.7 in specs to remove Ruby 2.1/2.2/2.3
merge_request: 27269
author: Takuya Noguchi
type: other
---
title: Hide admin user actions for ghost and bot users
merge_request: 27162
author:
type: fixed
---
title: Update query labels dynamically for embedded charts
merge_request: 29034
author:
type: other
---
title: Fix right sidebar when scrollbars are always visible
merge_request: 27314
author: Shawn @CasualBot
type: fixed
---
title: Highlight line which includes search term is code search results
merge_request: 22914
author: Alex Terekhov (terales)
type: added
---
title: Improve Advanced global search performance by using routing
merge_request: 27398
author:
type: performance
---
title: Add issues to graphQL group endpoint
merge_request: 27789
author:
type: added
---
title: Add added_lines and removed_lines columns to merge_request_metrics table
merge_request: 28658
author:
type: added
---
title: Adds filter by name to the packages list
merge_request: 27586
author:
type: added
---
title: Adds branch information to the package details title section
merge_request: 27488
author:
type: added
---
title: Improve API response for archived project searchs
merge_request: 27717
author:
type: performance
---
title: Improve API response for descending internal project searches
merge_request: 28038
author:
type: performance
---
title: Improve SAST NO_DIND file detection with proper boundary conditions
merge_request: 28036
author:
type: fixed
---
title: Resolve an N+1 in merge request CI variables
merge_request: 28688
author:
type: performance
---
title: Support multiple Evidences for a Release
merge_request: 26509
author:
type: changed
---
title: Remove open in file view link from Web IDE
merge_request: 28705
author:
type: removed
---
title: Fix Web IDE not showing diff when opening commit tab
merge_request: 29439
author:
type: fixed
---
title: Allow 0 for pages size limit setting in admin settings
merge_request: 28086
author:
type: fixed
---
title: Update Active checkbox component to use toggle
merge_request: 27778
author:
type: added
---
title: Make search redaction more robust
merge_request: 29166
author:
type: changed
---
title: Fix wrong colors displayed in charts
merge_request: 28095
author:
type: fixed
---
title: Upload a design by copy/pasting the file into the Design Tab
merge_request: 27776
author:
type: added
---
title: Add read_api scope to personal access tokens for granting read only API access
merge_request: 28944
author:
type: added
---
title: Only enable searching of projects by full path / name on certain dropdowns
merge_request: 21910
author:
type: changed
---
title: Added the clone button for Snippet view
merge_request: 28840
author:
type: added
---
title: Prevent wrong environment being used when processing Prometheus alert
merge_request: 29119
author:
type: fixed
---
title: Add user_details.bio column and migrate data from users.bio
merge_request: 27773
author:
type: changed
---
title: Added Edit Title shared component
merge_request: 27582
author:
type: added
---
title: Validate uniqueness of project_id and type when a new project service is created
merge_request: 26308
author:
type: fixed
---
title: Create model to store Terraform state files
merge_request: 26619
author:
type: added
---
title: Add terraform report to merge request widget
merge_request: 27700
author:
type: added
---
title: Refresh metrics dashboard data without reloading the page
merge_request: 28756
author:
type: added
---
title: Improve logs filters on mobile, simplify kubernetes API logs filters
merge_request: 27484
author:
type: added
---
title: Improve logs dropdown with more clear labels
merge_request: 26635
author:
type: added
---
title: Add filtered search for elastic search in logs
merge_request: 27654
author:
type: added
---
title: Start merge request for custom dashboard if new branch is provided
merge_request: 27189
author:
type: added
---
title: Reduce number of SQL queries for service templates
merge_request: 27396
author:
type: performance
---
title: Improve performance of the container repository cleanup tags service
merge_request: 27441
author:
type: performance
---
title: Optimize ldap keys counters query performance in usage data
merge_request: 27309
author:
type: performance
---
title: Enable container expiration policies by default for new projects
merge_request: 28480
author:
type: changed
---
title: Add status column to container_registry
merge_request: 28682
author:
type: changed
---
title: Amend GraphQL merge requests resolver to check for project presence
merge_request: 27783
author:
type: fixed
---
title: Add app server type to usage ping
merge_request: 28189
author:
type: added
---
title: Rename "Project Services" to "Integrations" in frontend and docs
merge_request: 26244
author:
type: changed
---
title: Enable Workhorse upload acceleration for Project Import uploads via UI
merge_request: 27332
author:
type: performance
---
title: Add application setting to enable container expiration and retention policies
on pre 12.8 projects
merge_request: 28479
author:
type: added
---
title: Update icons in Sentry Error Tracking list for ignored/resolved errors
merge_request: 27125
author:
type: other
---
title: Optimize ci builds non distinct counters in usage data
merge_request: 28027
author:
type: performance
---
title: Optimize ci builds counters in usage data
merge_request: 27770
author:
type: performance
---
title: Optimize suggestions counters
merge_request: 26443
author:
type: performance
---
title: Fix managed_free_namespaces scope to only groups without a license or a free license
merge_request: 27356
author:
type: fixed
---
title: Move bots functionality to user_type column
merge_request: 26981
author:
type: performance
---
title: Optimize projects_enforcing_code_owner_approval counter query performance for usage ping
merge_request: 27526
author:
type: performance
---
title: Optimize template_repositories query by using batch counting
merge_request: 27352
author:
type: performance
---
title: Optimize projects_reporting_ci_cd_back_to_github query performance for usage data
merge_request: 27533
author:
type: performance
---
title: Optimize projects_service_active queries performance in usage data
merge_request: 27093
author:
type: performance
---
title: Optimize projects_mirrored_with_pipelines_enabled query performance in usage data
merge_request: 27110
author:
type: performance
---
title: Optimize usage ping queries by using batch counting
merge_request: 27455
author:
type: performance
---
title: Consume remaining LinkLFsObjectsProjects jobs
merge_request: 27558
author:
type: other
---
title: Fix not working File upload from Project overview page.
merge_request: 26828
author: Gilang Gumilar
type: fixed
---
title: Cache ES enabled namespaces and projects
merge_request: 27348
author:
type: performance
---
title: Fix incorrect regex used in FileUploader#extract_dynamic_path
merge_request: 28683
author:
type: fixed
---
title: Fix assignee dropdown on new issue page
merge_request: 26971
author:
type: fixed
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
File mode changed from 100755 to 100644
File mode changed from 100755 to 100644
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment