project_auto_devops.rb 306 Bytes
Newer Older
1 2
class ProjectAutoDevops < ActiveRecord::Base
  belongs_to :project
Zeger-Jan van de Weg's avatar
Zeger-Jan van de Weg committed
3

4
  validates :domain, allow_blank: true, hostname: { allow_numeric_hostname: true }
5 6 7 8 9 10

  def variables
    variables = []
    variables << { key: 'AUTO_DEVOPS_DOMAIN', value: domain, public: true } if domain.present?
    variables
  end
11
end