36a01a88ce
Kubernetes deployments on new clusters will now have a separate namespace per project environment, instead of sharing a single namespace for the project. Behaviour of existing clusters is unchanged. All new functionality is controlled by the :kubernetes_namespace_per_environment feature flag, which is safe to enable/disable at any time.
15 lines
376 B
Ruby
15 lines
376 B
Ruby
# frozen_string_literal: true
|
|
|
|
module Gitlab
|
|
module Prometheus
|
|
module QueryVariables
|
|
def self.call(environment)
|
|
{
|
|
ci_environment_slug: environment.slug,
|
|
kube_namespace: environment.deployment_namespace || '',
|
|
environment_filter: %{container_name!="POD",environment="#{environment.slug}"}
|
|
}
|
|
end
|
|
end
|
|
end
|
|
end
|