lib/metatron/templates/stateful_set.rb in metatron-0.1.8 vs lib/metatron/templates/stateful_set.rb in metatron-0.1.9

- old
+ new

@@ -4,10 +4,11 @@ module Templates # Template for basic StatefulSet k8s resource class StatefulSet < Template include Concerns::Annotated include Concerns::PodProducer + include Concerns::Namespaced attr_accessor :replicas, :service_name, :pod_management_policy, :enable_service_links def initialize(name, replicas: 1) super(name) @@ -29,10 +30,10 @@ apiVersion:, kind:, metadata: { name:, labels: { "#{label_namespace}/name": name }.merge(additional_labels) - }.merge(formatted_annotations), + }.merge(formatted_annotations).merge(formatted_namespace), spec: { replicas:, serviceName:, enableServiceLinks:, strategy: { type: "RollingUpdate", rollingUpdate: { maxSurge: 2, maxUnavailable: 0 } },