Welcome to mirror list, hosted at ThFree Co, Russian Federation.

pipeline_variable.rb « ci « models « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 84ca4833cd7e9c95772ab8de32f62e2bf14b1859 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# frozen_string_literal: true

module Ci
  class PipelineVariable < ApplicationRecord
    extend Gitlab::Ci::Model
    include Ci::HasVariable

    belongs_to :pipeline

    alias_attribute :secret_value, :value

    validates :key, uniqueness: { scope: :pipeline_id }

    def hook_attrs
      { key: key, value: value }
    end
  end
end