debian-mirror-gitlab/app/models/ci/pipeline_metadata.rb

15 lines
455 B
Ruby
Raw Normal View History

2022-11-25 23:54:43 +05:30
# frozen_string_literal: true
module Ci
class PipelineMetadata < Ci::ApplicationRecord
self.primary_key = :pipeline_id
belongs_to :pipeline, class_name: "Ci::Pipeline", inverse_of: :pipeline_metadata
belongs_to :project, class_name: "Project", inverse_of: :pipeline_metadata
validates :pipeline, presence: true
validates :project, presence: true
2023-01-13 00:05:48 +05:30
validates :name, presence: true, length: { minimum: 1, maximum: 255 }
2022-11-25 23:54:43 +05:30
end
end