Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Is there a way with juju commands to clear the juju charm cache for a particular charm from a running bootstrap node?

I'm writing a charm and for during development when I've made changes to a charm but don't commit a revision update I want to be able to iterate quicker.

share|improve this question

2 Answers 2

up vote 6 down vote accepted

You can use the -u option to juju deploy to speed iteration during development of your charms:

  -u, --upgrade         Deploy the charm on disk, increments revision if
                        needed

e.g.,

juju deploy -u charm-name
share|improve this answer
    
Does this actually force juju's charm cache to clear itself? For example, I tried the -u switch after rewriting a charm and resetting its revision 0. Juju kept using its cached version and would not take my new version from disk. –  mars Mar 29 '13 at 15:53
    
It doesn't clear the cache, but it should force the updated version to be deployed... –  sarnold Apr 3 '13 at 4:41

I recently tried this and got:

$ juju deploy -u --repository=./charms local:trusty/node-app openmotion

Added charm "local:trusty/node-app-24" to the environment. --upgrade (or -u) is deprecated and ignored; charms are always deployed with a unique revision.`

So it seems -u is no longer necessary, at least as of juju 1.18.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.