Puppet+Kubernetes : Can I use already existing kubrernetes YAML files while using the kubernetes module?

0 votes
I already have YAML files describing my Kubernetes resources, Is there any way that I can reuse it while using puppetlabs/kubernetes module?

Should I re-write all those as per the constraints of the puppetlabs/kubernetes  module? What's the way forward?
Aug 22, 2019 in Puppet by Karan
• 8,040 points
67 views

1 answer to this question.

0 votes

Yes, you could re-use them.

You may already have YAML files describing your Kubernetes resources,In this case the module includes an experimental puppet kubernetes convert command for just this situation.

puppet kubernetes convert examples/guestbook.yaml

The above command will output to stdout the Puppet equivalent to the YAML description of Kubernetes resources, including correctly handling multi-document files like the example guestbook.

puppet kubernetes convert examples/guestbook.yaml > guestbook.pp
puppet apply --test guestbook.pp

If you want to then use that Puppet file the simplest way to do so is to redirect the output to a file and then run it with Puppet as shown above.

answered Aug 22, 2019 by Sirajul
• 45,590 points

Related Questions In Puppet

0 votes
1 answer
0 votes
1 answer

Puppet+Kubernetes : How do i install the kubernetes module via Bolt?

In order to get started with using ...READ MORE

answered Aug 23, 2019 in Puppet by Sirajul
• 45,590 points
54 views
0 votes
1 answer

How do i start using the kubernetes module if i'm using r10k for code management?

Add this declaration to your Puppetfile: mod 'puppetlabs-kubernetes', ...READ MORE

answered Aug 23, 2019 in Puppet by Sirajul
• 45,590 points
42 views
0 votes
1 answer
0 votes
1 answer
0 votes
3 answers

Error while joining cluster with node

Hi Kalgi after following above steps it ...READ MORE

answered Jan 17, 2019 in Others by anonymous
4,242 views
+3 votes
1 answer

Installing Web UI (Dashboard):kubernetes-dashboard on main Ubuntu 16.04.6 LTS (Xenial Xerus) server

Follow these steps: $ kubeadm reset $ kubeadm init ...READ MORE

answered Apr 11, 2019 in Kubernetes by Kalgi
• 50,110 points

reshown Apr 12, 2019 by Kalgi 1,153 views
0 votes
1 answer

Docker with puppet: Can I validate the puppetlabs/docker module?

Yes, you can! This module is compliant with ...READ MORE

answered Aug 16, 2019 in Puppet by Sirajul
• 45,590 points
32 views
0 votes
1 answer