forked from gitlabhq/gitlabhq
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add latest changes from gitlab-org/gitlab@master
- Loading branch information
GitLab Bot
committed
Jun 18, 2020
1 parent
16210ba
commit aed2039
Showing
35 changed files
with
464 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# frozen_string_literal: true | ||
|
||
module Types | ||
class UntrustedRegexp < Types::BaseScalar | ||
description 'A regexp containing patterns sourced from user input' | ||
|
||
def self.coerce_input(input_value, _) | ||
return unless input_value | ||
|
||
Gitlab::UntrustedRegexp.new(input_value) | ||
|
||
input_value | ||
rescue RegexpError => e | ||
message = "#{input_value} is an invalid regexp: #{e.message}" | ||
raise GraphQL::CoercionError, message | ||
end | ||
|
||
def self.coerce_result(ruby_value, _) | ||
ruby_value.to_s | ||
end | ||
end | ||
end |
5 changes: 5 additions & 0 deletions
5
.../unreleased/220789-10io-add-missing-attributes-to-graphql-container-expiration-policy.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
title: Add regex fields to the container expiration policy update mutation | ||
merge_request: 34389 | ||
author: | ||
type: added |
5 changes: 5 additions & 0 deletions
5
changelogs/unreleased/implement_vulnerability_stats_model.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
title: Create vulnerability_statistics table | ||
merge_request: 34289 | ||
author: | ||
type: added |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
title: Updates Helm version to 2.16.7, which has some fixes | ||
merge_request: 34452 | ||
author: | ||
type: fixed |
30 changes: 30 additions & 0 deletions
30
db/migrate/20200610130002_create_vulnerability_statistics.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# frozen_string_literal: true | ||
|
||
class CreateVulnerabilityStatistics < ActiveRecord::Migration[6.0] | ||
include Gitlab::Database::MigrationHelpers | ||
|
||
DOWNTIME = false | ||
|
||
def up | ||
with_lock_retries do | ||
create_table :vulnerability_statistics do |t| | ||
t.timestamps_with_timezone null: false | ||
t.references :project, null: false, foreign_key: { on_delete: :cascade } | ||
t.integer :total, default: 0, null: false | ||
t.integer :critical, default: 0, null: false | ||
t.integer :high, default: 0, null: false | ||
t.integer :medium, default: 0, null: false | ||
t.integer :low, default: 0, null: false | ||
t.integer :unknown, default: 0, null: false | ||
t.integer :info, default: 0, null: false | ||
t.integer :letter_grade, limit: 1, index: true, null: false | ||
end | ||
end | ||
end | ||
|
||
def down | ||
with_lock_retries do | ||
drop_table :vulnerability_statistics # rubocop:disable Migration/DropTable | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.