Charming with Resources

Rick Harding rick.harding at canonical.com
Thu Sep 29 15:06:41 UTC 2016


We didn't do an original 0byte resource because that's almost promised to
fail. The thought was, in order to publish the charm into the store then
you need some minimal resource that the charm will accept. If it's a django
charm, a hello world application; if a file server, a demo image; etc. Just
having a 0byte charm means the deploy is probably going to come up in some
awkward error state that the end user has to track down "why did this fail"
vs something obvious and documented.

On Thu, Sep 29, 2016 at 10:59 AM Charles Butler <
charles.butler at canonical.com> wrote:

> TL;DR - would it be helpful to just initialize every resource stream, at
> index 0, a zero byte resource?  This aids users who are publishing charms
> with copyrighted bins, or proprietary components. And give an immediately
> publishable resource for streams.
>
>
> It occurred to me this week while we were revving through the kubernetes
> publication process, that on initial publish its best to have zero byte
> resources at index 0. So its easy to remember - "man which resource was the
> zero byte one?" it just corresponds to 0.
>
> Instead of having users touch, gzip, etc a null resource, would it be
> feasible to make the charm store have this convention by default? Every
> charm that declares a resource, that resource, in turn gets a resource-0
> allocated for zero byte, freeing the publisher of the charm to use the
> provided null resource?  seems like a better UX than asking the user to
> jump through hoops of say:
>
> touch null && gzip null && charm attach mycharm big-resource=null.gz
>
> There's likely a reason we didn't do this by default and I'm interested in
> hearing it. However, I'm more interested in finding out if we can
> streamline resource publication for our vendors and community.
>
> All the best,
>
> Charles
> --
> Juju Charmer
> Canonical Group Ltd.
> Ubuntu - Linux for human beings | www.ubuntu.com
> Juju - The fastest way to model your application | www.jujucharms.com
> --
> 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/20160929/92ee18af/attachment.html>


More information about the Juju mailing list