juju publish is coming

Gustavo Niemeyer gustavo at niemeyer.net
Mon Apr 1 16:00:36 UTC 2013


Hey folks,

This one has been on my wishlist since we introduced the charm store
about a year ago, and it should make a huge difference when working
with the store, so I decided to take a look at it.

This isn't quite working on tip yet, but the first branches are
starting to land, and it'll work very soon now once I manage to break
it down further into clear pieces for review.

Here are a few examples of the command working:

1) When the charm is refused by the store, that is informed
immediately through the revision process itself:

$ juju publish -v
2013/04/01 12:40:30 INFO JUJU:juju:publish local digest is
gustavo at niemeyer.net-20130401142448-cpt1j3zizl08hhfz
2013/04/01 12:40:30 INFO JUJU:juju:publish sending charm to the charm store...
2013/04/01 12:40:43 INFO JUJU:juju:publish charm sent; waiting for it
to be published...
2013/04/01 12:41:15 ERROR JUJU:juju:publish juju publish command
failed: local content
could not be published: invalid revision file
error: local content could not be published: invalid revision file

2) When it succeeds, the revisioned charm URL is shown *after* the
charm is available:

$ juju publish -v
2013/04/01 12:52:35 INFO JUJU:juju:publish local digest is
gustavo at niemeyer.net-20130401155227-h0jzjk7rg6k3ej6s
2013/04/01 12:52:35 INFO JUJU:juju:publish sending charm to the charm store...
2013/04/01 12:52:47 INFO JUJU:juju:publish charm sent; waiting for it
to be published...
2013/04/01 12:53:29 INFO JUJU:juju:publish local content published at
2013-04-01T15:53:28Z as cs:~niemeyer/precise/ubuntu-3
cs:~niemeyer/precise/ubuntu-3

3) Attempting to publish content again is handled properly:

$ juju publish -v
2013/04/01 12:54:25 INFO JUJU:juju:publish local digest is
gustavo at niemeyer.net-20130401155227-h0jzjk7rg6k3ej6s
2013/04/01 12:54:25 INFO JUJU:juju:publish local content published at
2013-04-01T15:53:28Z as cs:~niemeyer/precise/ubuntu-3
cs:~niemeyer/precise/ubuntu-3

4) Without -v, the command runs silently, and ends in an error or with
the new revisioned URL being shown:

$ juju publish
cs:~niemeyer/precise/ubuntu-3


gustavo @ http://niemeyer.net



More information about the Juju mailing list