Unify deployment_platform interface with EE

This commit is contained in:
Lin Jen-Shin 2018-03-07 18:14:25 +08:00
parent cfe203fa3a
commit 0917e81783
2 changed files with 3 additions and 2 deletions

View File

@ -1,5 +1,6 @@
module DeploymentPlatform
def deployment_platform
# EE would override this and utilize the extra argument
def deployment_platform(environment: nil)
@deployment_platform ||=
find_cluster_platform_kubernetes ||
find_kubernetes_service_integration ||

View File

@ -225,7 +225,7 @@ class Environment < ActiveRecord::Base
end
def deployment_platform
project.deployment_platform
project.deployment_platform(environment: self)
end
private