debian-mirror-gitlab/app/models/ci/pipeline_metadata.rb
2023-01-12 18:35:48 +00:00

14 lines
455 B
Ruby

# 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
validates :name, presence: true, length: { minimum: 1, maximum: 255 }
end
end