lib/metatron/templates/pod.rb in metatron-0.2.2 vs lib/metatron/templates/pod.rb in metatron-0.2.3
- old
+ new
@@ -6,28 +6,18 @@
class Pod < Template
include Concerns::Annotated
include Concerns::PodProducer
include Concerns::Namespaced
- # rubocop:disable Metrics/AbcSize
def render
{
apiVersion:,
kind:,
metadata: {
labels: { "#{label_namespace}/name": name }.merge(additional_labels),
name:
- }.merge(formatted_annotations).merge(formatted_namespace),
- spec: {
- terminationGracePeriodSeconds:,
- containers: containers.map(&:render),
- init_containers: init_containers.any? ? init_containers.map(&:render) : nil
- }.merge(formatted_volumes)
- .merge(formatted_security_context)
- .merge(formatted_tolerations)
- .compact
- }
+ }.merge(formatted_annotations).merge(formatted_namespace)
+ }.merge(pod_spec)
end
- # rubocop:enable Metrics/AbcSize
end
end
end