lib/metatron/templates/secret.rb in metatron-0.1.8 vs lib/metatron/templates/secret.rb in metatron-0.1.9
- old
+ new
@@ -3,10 +3,11 @@
module Metatron
module Templates
# The Secret Kubernetes resource
class Secret < Template
include Concerns::Annotated
+ include Concerns::Namespaced
attr_accessor :additional_labels, :type, :data
def initialize(name, data = {})
super(name)
@@ -20,10 +21,10 @@
apiVersion:,
kind:,
metadata: {
name:,
labels: { "#{label_namespace}/name": name }.merge(additional_labels)
- }.merge(formatted_annotations),
+ }.merge(formatted_annotations).merge(formatted_namespace),
type:,
stringData: data
}
end
end