summaryrefslogtreecommitdiff
path: root/app/models/project_auto_devops.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/models/project_auto_devops.rb')
-rw-r--r--app/models/project_auto_devops.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/models/project_auto_devops.rb b/app/models/project_auto_devops.rb
index 7af3b6870e2..9a52edbff8e 100644
--- a/app/models/project_auto_devops.rb
+++ b/app/models/project_auto_devops.rb
@@ -6,6 +6,10 @@ class ProjectAutoDevops < ActiveRecord::Base
validates :domain, allow_blank: true, hostname: { allow_numeric_hostname: true }
+ def has_domain?
+ domain.present?
+ end
+
def variables
variables = []
variables << { key: 'AUTO_DEVOPS_DOMAIN', value: domain, public: true } if domain.present?