debian-mirror-gitlab/app/models/concerns/enums/ci/commit_status.rb

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

46 lines
1.6 KiB
Ruby
Raw Normal View History

2021-03-08 18:12:59 +05:30
# frozen_string_literal: true
module Enums
module Ci
module CommitStatus
# Returns the Hash to use for creating the `failure_reason` enum for
# `CommitStatus`.
def self.failure_reasons
{
unknown_failure: nil,
script_failure: 1,
api_failure: 2,
stuck_or_timeout_failure: 3,
runner_system_failure: 4,
missing_dependency_failure: 5,
runner_unsupported: 6,
stale_schedule: 7,
job_execution_timeout: 8,
archived_failure: 9,
unmet_prerequisites: 10,
scheduler_failure: 11,
data_integrity_failure: 12,
forward_deployment_failure: 13,
2021-04-29 21:17:54 +05:30
user_blocked: 14,
project_deleted: 15,
2021-06-08 01:23:25 +05:30
ci_quota_exceeded: 16,
pipeline_loop_detected: 17,
2021-09-04 01:27:46 +05:30
no_matching_runner: 18, # not used anymore, but cannot be deleted because of old data
2021-09-30 23:02:18 +05:30
trace_size_exceeded: 19,
2021-11-11 11:23:49 +05:30
builds_disabled: 20,
2021-11-18 22:05:49 +05:30
environment_creation_failure: 21,
2022-01-26 12:08:38 +05:30
deployment_rejected: 22,
2021-03-08 18:12:59 +05:30
insufficient_bridge_permissions: 1_001,
downstream_bridge_project_not_found: 1_002,
invalid_bridge_trigger: 1_003,
bridge_pipeline_is_child_pipeline: 1_006, # not used anymore, but cannot be deleted because of old data
downstream_pipeline_creation_failed: 1_007,
secrets_provider_not_found: 1_008,
reached_max_descendant_pipelines_depth: 1_009
}
end
end
end
end
2021-06-08 01:23:25 +05:30
Enums::Ci::CommitStatus.prepend_mod_with('Enums::Ci::CommitStatus')