lib/kubernetes-deploy/kubernetes_resource/pod.rb in kubernetes-deploy-0.19.0 vs lib/kubernetes-deploy/kubernetes_resource/pod.rb in kubernetes-deploy-0.20.0
- old
+ new
@@ -3,19 +3,21 @@
class Pod < KubernetesResource
TIMEOUT = 10.minutes
FAILED_PHASE_NAME = "Failed"
- def initialize(namespace:, context:, definition:, logger:, parent: nil, deploy_started_at: nil)
+ def initialize(namespace:, context:, definition:, logger:,
+ statsd_tags: nil, parent: nil, deploy_started_at: nil)
@parent = parent
@deploy_started_at = deploy_started_at
@containers = definition.fetch("spec", {}).fetch("containers", []).map { |c| Container.new(c) }
unless @containers.present?
logger.summary.add_paragraph("Rendered template content:\n#{definition.to_yaml}")
raise FatalDeploymentError, "Template is missing required field spec.containers"
end
@containers += definition["spec"].fetch("initContainers", []).map { |c| Container.new(c, init_container: true) }
- super(namespace: namespace, context: context, definition: definition, logger: logger)
+ super(namespace: namespace, context: context, definition: definition,
+ logger: logger, statsd_tags: statsd_tags)
end
def sync(mediator)
super
raise_predates_deploy_error if exists? && unmanaged? && !deploy_started?