Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
95e58281
Commit
95e58281
authored
Sep 29, 2021
by
GitLab Bot
Browse files
Options
Browse Files
Download
Plain Diff
Automatic merge of gitlab-org/gitlab master
parents
037aaec6
920bd863
Changes
12
Show whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
40 additions
and
6 deletions
+40
-6
.gitlab/ci/rules.gitlab-ci.yml
.gitlab/ci/rules.gitlab-ci.yml
+0
-1
app/assets/javascripts/packages_and_registries/settings/project/constants.js
...pts/packages_and_registries/settings/project/constants.js
+1
-0
app/graphql/types/container_expiration_policy_older_than_enum.rb
...phql/types/container_expiration_policy_older_than_enum.rb
+1
-0
app/models/container_expiration_policy.rb
app/models/container_expiration_policy.rb
+1
-0
config/metrics/counts_all/20210915082040_projects_with_expiration_policy_enabled_with_older_than_set_to_60d.yml
..._expiration_policy_enabled_with_older_than_set_to_60d.yml
+22
-0
doc/api/graphql/reference/index.md
doc/api/graphql/reference/index.md
+1
-0
spec/frontend/packages_and_registries/settings/project/settings/__snapshots__/utils_spec.js.snap
...ettings/project/settings/__snapshots__/utils_spec.js.snap
+6
-0
spec/frontend/packages_and_registries/settings/project/settings/components/__snapshots__/settings_form_spec.js.snap
...tings/components/__snapshots__/settings_form_spec.js.snap
+1
-1
spec/graphql/types/container_expiration_policy_older_than_enum_spec.rb
...types/container_expiration_policy_older_than_enum_spec.rb
+1
-1
spec/helpers/container_expiration_policies_helper_spec.rb
spec/helpers/container_expiration_policies_helper_spec.rb
+1
-0
spec/lib/gitlab/usage_data_spec.rb
spec/lib/gitlab/usage_data_spec.rb
+4
-3
spec/support/helpers/usage_data_helpers.rb
spec/support/helpers/usage_data_helpers.rb
+1
-0
No files found.
.gitlab/ci/rules.gitlab-ci.yml
View file @
95e58281
...
...
@@ -653,7 +653,6 @@
.rails:rules:decomposed-databases:
rules
:
-
<<
:
*if-merge-request-run-decomposed
allow_failure
:
true
.rails:rules:ee-and-foss-migration:
rules
:
...
...
app/assets/javascripts/packages_and_registries/settings/project/constants.js
View file @
95e58281
...
...
@@ -73,6 +73,7 @@ export const OLDER_THAN_OPTIONS = [
{
key
:
'
SEVEN_DAYS
'
,
variable
:
7
,
default
:
false
},
{
key
:
'
FOURTEEN_DAYS
'
,
variable
:
14
,
default
:
false
},
{
key
:
'
THIRTY_DAYS
'
,
variable
:
30
,
default
:
false
},
{
key
:
'
SIXTY_DAYS
'
,
variable
:
60
,
default
:
false
},
{
key
:
'
NINETY_DAYS
'
,
variable
:
90
,
default
:
true
},
];
...
...
app/graphql/types/container_expiration_policy_older_than_enum.rb
View file @
95e58281
...
...
@@ -6,6 +6,7 @@ module Types
'7d'
:
'SEVEN_DAYS'
,
'14d'
:
'FOURTEEN_DAYS'
,
'30d'
:
'THIRTY_DAYS'
,
'60d'
:
'SIXTY_DAYS'
,
'90d'
:
'NINETY_DAYS'
}.
freeze
...
...
app/models/container_expiration_policy.rb
View file @
95e58281
...
...
@@ -74,6 +74,7 @@ class ContainerExpirationPolicy < ApplicationRecord
'7d'
:
_
(
'%{days} days until tags are automatically removed'
)
%
{
days:
7
},
'14d'
:
_
(
'%{days} days until tags are automatically removed'
)
%
{
days:
14
},
'30d'
:
_
(
'%{days} days until tags are automatically removed'
)
%
{
days:
30
},
'60d'
:
_
(
'%{days} days until tags are automatically removed'
)
%
{
days:
60
},
'90d'
:
_
(
'%{days} days until tags are automatically removed'
)
%
{
days:
90
}
}
end
...
...
config/metrics/counts_all/20210915082040_projects_with_expiration_policy_enabled_with_older_than_set_to_60d.yml
0 → 100644
View file @
95e58281
---
data_category
:
optional
key_path
:
counts.projects_with_expiration_policy_enabled_with_older_than_set_to_60d
description
:
A count of projects with the cleanup policy set delete tags older than
60 days
product_section
:
ops
product_stage
:
package
product_group
:
group::package
product_category
:
container registry
value_type
:
number
status
:
active
time_frame
:
all
data_source
:
database
distribution
:
-
ee
-
ce
tier
:
-
free
-
premium
-
ultimate
performance_indicator_type
:
[]
milestone
:
"
14.4"
doc/api/graphql/reference/index.md
View file @
95e58281
...
...
@@ -15460,6 +15460,7 @@ Conan file types.
|
<a
id=
"containerexpirationpolicyolderthanenumfourteen_days"
></a>
`FOURTEEN_DAYS`
| 14 days until tags are automatically removed. |
|
<a
id=
"containerexpirationpolicyolderthanenumninety_days"
></a>
`NINETY_DAYS`
| 90 days until tags are automatically removed. |
|
<a
id=
"containerexpirationpolicyolderthanenumseven_days"
></a>
`SEVEN_DAYS`
| 7 days until tags are automatically removed. |
|
<a
id=
"containerexpirationpolicyolderthanenumsixty_days"
></a>
`SIXTY_DAYS`
| 60 days until tags are automatically removed. |
|
<a
id=
"containerexpirationpolicyolderthanenumthirty_days"
></a>
`THIRTY_DAYS`
| 30 days until tags are automatically removed. |
### `ContainerRepositoryCleanupStatus`
...
...
spec/frontend/packages_and_registries/settings/project/settings/__snapshots__/utils_spec.js.snap
View file @
95e58281
...
...
@@ -99,6 +99,12 @@ Array [
"label": "30 days",
"variable": 30,
},
Object {
"default": false,
"key": "SIXTY_DAYS",
"label": "60 days",
"variable": 60,
},
Object {
"default": true,
"key": "NINETY_DAYS",
...
...
spec/frontend/packages_and_registries/settings/project/settings/components/__snapshots__/settings_form_spec.js.snap
View file @
95e58281
...
...
@@ -44,7 +44,7 @@ exports[`Settings Form Keep Regex matches snapshot 1`] = `
exports[`Settings Form OlderThan matches snapshot 1`] = `
<expiration-dropdown-stub
data-testid="older-than-dropdown"
formoptions="[object Object],[object Object],[object Object],[object Object],[object Object]"
formoptions="[object Object],[object Object],[object Object],[object Object],[object Object]
,[object Object]
"
label="Remove tags older than:"
name="older-than"
value="FOURTEEN_DAYS"
...
...
spec/graphql/types/container_expiration_policy_older_than_enum_spec.rb
View file @
95e58281
...
...
@@ -3,7 +3,7 @@
require
'spec_helper'
RSpec
.
describe
GitlabSchema
.
types
[
'ContainerExpirationPolicyOlderThanEnum'
]
do
let_it_be
(
:expected_values
)
{
%w[SEVEN_DAYS FOURTEEN_DAYS THIRTY_DAYS NINETY_DAYS]
}
let_it_be
(
:expected_values
)
{
%w[SEVEN_DAYS FOURTEEN_DAYS THIRTY_DAYS
SIXTY_DAYS
NINETY_DAYS]
}
it_behaves_like
'exposing container expiration policy option'
,
:older_than
end
spec/helpers/container_expiration_policies_helper_spec.rb
View file @
95e58281
...
...
@@ -40,6 +40,7 @@ RSpec.describe ContainerExpirationPoliciesHelper do
{
key:
'7d'
,
label:
'7 days until tags are automatically removed'
},
{
key:
'14d'
,
label:
'14 days until tags are automatically removed'
},
{
key:
'30d'
,
label:
'30 days until tags are automatically removed'
},
{
key:
'60d'
,
label:
'60 days until tags are automatically removed'
},
{
key:
'90d'
,
label:
'90 days until tags are automatically removed'
,
default:
true
}
]
...
...
spec/lib/gitlab/usage_data_spec.rb
View file @
95e58281
...
...
@@ -662,13 +662,13 @@ RSpec.describe Gitlab::UsageData, :aggregate_failures do
subject
{
described_class
.
data
[
:counts
]
}
it
'gathers usage data'
do
expect
(
subject
[
:projects_with_expiration_policy_enabled
]).
to
eq
1
8
expect
(
subject
[
:projects_with_expiration_policy_enabled
]).
to
eq
1
9
expect
(
subject
[
:projects_with_expiration_policy_disabled
]).
to
eq
5
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_keep_n_unset
]).
to
eq
1
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_keep_n_set_to_1
]).
to
eq
1
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_keep_n_set_to_5
]).
to
eq
1
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_keep_n_set_to_10
]).
to
eq
1
2
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_keep_n_set_to_10
]).
to
eq
1
3
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_keep_n_set_to_25
]).
to
eq
1
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_keep_n_set_to_50
]).
to
eq
1
...
...
@@ -676,9 +676,10 @@ RSpec.describe Gitlab::UsageData, :aggregate_failures do
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_older_than_set_to_7d
]).
to
eq
1
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_older_than_set_to_14d
]).
to
eq
1
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_older_than_set_to_30d
]).
to
eq
1
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_older_than_set_to_60d
]).
to
eq
1
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_older_than_set_to_90d
]).
to
eq
14
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_cadence_set_to_1d
]).
to
eq
1
4
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_cadence_set_to_1d
]).
to
eq
1
5
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_cadence_set_to_7d
]).
to
eq
1
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_cadence_set_to_14d
]).
to
eq
1
expect
(
subject
[
:projects_with_expiration_policy_enabled_with_cadence_set_to_1month
]).
to
eq
1
...
...
spec/support/helpers/usage_data_helpers.rb
View file @
95e58281
...
...
@@ -112,6 +112,7 @@ module UsageDataHelpers
projects_with_expiration_policy_enabled_with_older_than_set_to_7d
projects_with_expiration_policy_enabled_with_older_than_set_to_14d
projects_with_expiration_policy_enabled_with_older_than_set_to_30d
projects_with_expiration_policy_enabled_with_older_than_set_to_60d
projects_with_expiration_policy_enabled_with_older_than_set_to_90d
projects_with_expiration_policy_enabled_with_cadence_set_to_1d
projects_with_expiration_policy_enabled_with_cadence_set_to_7d
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment