Hi! I've recently added 2 new plugins to validate k8s resources:<p>deployments
statefull sets
config maps
secrets
They are written on Raku and have Raku API.<p>For example, to verify k8s deployment and access it's entries:<p><pre><code> my %data = task-run "dpl check", "k8s-deployment-check" %(
name => "animals",
namespace => "pets",
cat => %(
command => "/usr/bin/cat",
args => [
"eat", "milk", "fish"
],
env => [
"ENABLE_LOGGING"
]
volume-mounts => {
foo-bar => "/opt/foo/bar",
}
)
);
# Access k8s resource
say %data.keys.perl;
# ("env", "image", "imagePullPolicy", "command",
# "terminationMessagePolicy", "name", "envFrom", "ports",
# "__data__",
# "args",
# "terminationMessagePath", "livenessProbe", "resources", "volumeMounts").Seq
say %data.command;</code></pre>
Find more information here:<p>https://github.com/melezhik/sparrow-plugins/tree/master/k8s-config-check<p>https://github.com/melezhik/sparrow-plugins/tree/master/k8s-deployment-check<p>I'd like to hear if this useful for others.<p>Thanks