Orchestration charms
Casey Marshall
casey.marshall at canonical.com
Wed Jan 11 12:03:54 UTC 2017
Hi Simon,
I'm glad you asked about this. The need for certain services to operate on
the controller for autoscaling and other purposes has come up before.
Juju's considering exposing different aspects of the controller as
applications -- for monitoring, log access and other aspects of operating
the Juju controller itself. Controller API access for applications that use
the Juju "control plane" would be a natural fit.
In the short term, I think a good approach would be to create a charm that
can be placed onto the controller machine, that exposes an endpoint which
1) creates a new user with the necessary access permissions, as requested
by the relation, and 2) provides the user/password over the relation.
With the current stable Juju release (2.0.2) this does have a limitation,
in that the "API access" application would need to be in the same model as
your autoscaler -- so you'd have to deploy both into the "controller"
model. However, Juju will soon be adding support for relating applications
across models in the same controller, so I think this would be a good
forward-compatible design.
-Casey
On Mon, Jan 9, 2017 at 11:53 AM, Simon Kollberg <
simon.kollberg at elastisys.com> wrote:
> Hello Juju people!
>
> I'm currently working on a charm with a some what special characteristics.
> We
> call it the CharmScaler. The purpose of the charm is to automatically scale
> the number of units of a charm depending on the current usage of the
> application. Much like the autoscaling in Kubernetes and AWS.
>
> To do this the charm utilizes the newly created Juju Python library. Just
> like
> you can control your own deployment with the Juju client, the CharmScaler
> is
> able to do operations on the controller it has access to. Giving charms
> privileges like this really opens up a whole new world of possibilities
> where
> in charms will be able to orchestrate other charms in numerous ways not
> possible before.
>
> Right now, the user needs to manually provide credentials (via the charm
> config) to the CharmScaler enabling it to connect and execute operations on
> the Juju controller. What I would love to see is a way to make certain
> charms
> have special access - some kind of "orchestrator charm privilege" where the
> necessary credentials needed by the python lib would be passed to the charm
> automagically.
>
> I really have the feeling having this kind of "orchestrator charm"
> functionality in Juju would benefit the community greatly. Though, I do
> think
> it should be something more ingrained in Juju itself rather than making
> developers come up with their own tricks to provide the charms with
> credentials.
>
> Let me know what you think!
>
> - Simon
>
> --
> Juju mailing list
> Juju at lists.ubuntu.com
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/juju
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/juju/attachments/20170111/c39cfa8a/attachment.html>
More information about the Juju
mailing list