gitlab-org--gitlab-foss/app/policies/clusters/cluster_policy.rb
2017-10-23 11:36:35 +03:00

12 lines
241 B
Ruby

module Clusters
class ClusterPolicy < BasePolicy
alias_method :cluster, :subject
delegate { cluster.project }
rule { can?(:master_access) }.policy do
enable :update_cluster
enable :admin_cluster
end
end
end