Class: Metatron::Templates::Pod
- Inherits:
-
Metatron::Template
- Object
- Metatron::Template
- Metatron::Templates::Pod
- Defined in:
- lib/metatron/templates/pod.rb
Overview
Template for basic Pod k8s resource
Instance Attribute Summary
Attributes inherited from Metatron::Template
#additional_labels, #api_version, #kind, #label_namespace, #name
Instance Method Summary collapse
Methods included from Concerns::Namespaced
#formatted_namespace, included, #namespaced_initialize
Methods included from Concerns::PodProducer
#formatted_affinity, #formatted_containers, #formatted_image_pull_secrets, #formatted_init_containers, #formatted_node_selector, #formatted_pod_annotations, #formatted_security_context, #formatted_tolerations, #formatted_volumes, included, #pod_metadata, #pod_producer_initialize, #pod_spec, #pod_template, #volume_claim_templates
Methods included from Concerns::Annotated
#annotated_initialize, #formatted_annotations, included
Methods inherited from Metatron::Template
#initialize, initializer, initializers, metatron_template_class?, nearest_metatron_ancestor
Constructor Details
This class inherits a constructor from Metatron::Template
Instance Method Details
#render ⇒ Object
11 12 13 14 15 16 17 18 19 20 |
# File 'lib/metatron/templates/pod.rb', line 11 def render { apiVersion:, kind:, metadata: { labels: { "#{label_namespace}/name": name }.merge(additional_labels), name: }.merge(formatted_annotations).merge(formatted_namespace) }.merge(pod_spec) end |