Comment 9 for bug 1834374

Revision history for this message
George Kraft (cynerva) wrote :

From your output of `lxc profile show juju-kubernetes`, it looks like the profile wasn't applied correctly. The profile from your output is the default one created by Juju, not the one from our CDK-on-LXD documentation. Can you try applying the profile again?

> I have a 5 machine lab environment that I want to use to house multiple environments simultaneously. I have successfully deployed kubernetes against MaaS using juju a number of times. However, once this is done, the machines are marked as deployed, so if I were to try to deploy a mongodb stack against it (even if I used containers as targets,) juju sees those nodes as deployed.

You should be able to deploy multiple units to a small number of machines using the Juju CLI. For example, if you want to deploy mongodb to an LXD container on machine 2 while it's already in use, you'd do:

juju deploy mongodb --to lxd:2

> If there's an easier way to achieve this with juju and maas, without a lxd cluster per say, I'd be all ears on that. Thanks again for your help.

I believe the most common approach for this type of scenario is to run your Juju controller and models on a MAAS cloud, and use placement directives to tell Juju to deploy to LXD containers as needed (see above).

One benefit to this approach is that you could run troublesome units like kubernetes-worker directly on bare metal, while still utilizing LXD for the remaining units that don't have problems with it.

What you're trying seems reasonable, too, though. It just hasn't been tested well, so you may run into issues we're not aware of.