State of the "Best Practices Guide"

Thierry Fauck@linux.vnet.ibm.com thierry at linux.vnet.ibm.com
Wed Mar 4 16:11:01 UTC 2015


Hi,
May I add two tips that can help

 1. When you use the python template, the charmhelpers package download
    and use is done for you, but it then prevents your script to be run
    with as a simple python script since usually
    /usr/local/lib/python2.7/dist-packages is not a default.

  * Default path under juju is:

    sys.path= ['/var/lib/juju/agents/unit-kimchi-0/charm/hooks',
    '/usr/lib/python2.7',
    '/usr/lib/python2.7/plat-powerpc64le-linux-gnu',
    '/usr/lib/python2.7/lib-tk', '/usr/lib/python2.7/lib-old',
    '/usr/lib/python2.7/lib-dynload',
    '/usr/local/lib/python2.7/dist-packages',
    '/usr/lib/python2.7/dist-packages',
    '/usr/lib/python2.7/dist-packages/PILcompat']

  * log() functions found in hookenv.py is not available and will raise
    an error.

 1. if you run under "local" environment and your LXC machine get
    unexpected network errors try to disable IPv6 on main host.

That's all for now

Thierry

On 03/02/2015 06:18 PM, Charles Butler wrote:
> juju upgrade-charm --force, get that iterative action without a 
> teardown/redeploy in an error state
>
>
>
> On Mon, Mar 2, 2015 at 11:51 AM, Nick Veitch 
> <nick.veitch at canonical.com <mailto:nick.veitch at canonical.com>> wrote:
>
>     Hi,
>     I should clarify that the tips on this page are for charm authors -
>     i.e. writing charms.
>
>     If you have any tips for using Juju, we'd be happy to hear those
>     too though!
>
>
>
>     On 2 March 2015 at 16:30, Jorge O. Castro <jorge at ubuntu.com
>     <mailto:jorge at ubuntu.com>> wrote:
>     > Hi everyone,
>     >
>     > We have a best practices guide in the docs, initially it was a
>     brain dump of
>     > what Canonical IS was doing with Juju:
>     >
>     > https://jujucharms.com/docs/authors-charm-best-practice
>     >
>     > However if you look at the history of the page it hasn't been
>     touched in a
>     > long time, and there are tons of new tips and tricks that we
>     have neglected
>     > to put on this page. In many cases we've just added the tip to the
>     > corresponding page in the docs, so the question becomes, do any
>     of you have
>     > any tips/tricks that can help this page be more useful to users?
>     >
>     > --
>     > Juju mailing list
>     > Juju at lists.ubuntu.com <mailto:Juju at lists.ubuntu.com>
>     > Modify settings or unsubscribe at:
>     > https://lists.ubuntu.com/mailman/listinfo/juju
>     >
>
>
>
>     --
>     Nick Veitch
>     nick.veitch at canonical.com <mailto:nick.veitch at canonical.com>
>
>     --
>     Juju mailing list
>     Juju at lists.ubuntu.com <mailto:Juju at lists.ubuntu.com>
>     Modify settings or unsubscribe at:
>     https://lists.ubuntu.com/mailman/listinfo/juju
>
>
>
>
> -- 
> All the best,
>
> Charles Butler <charles.butler at canonical.com 
> <mailto:charles.butler at canonical.com>> - Juju Charmer
> Come see the future of datacenter orchestration: http://jujucharms.com
>
>


-- 
Thierry Fauck @ linux.vnet.ibm

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/juju/attachments/20150304/e34d5e13/attachment.html>


More information about the Juju mailing list