<div dir="ltr"><div><div><div>Hello Denis,<br><br></div>Thanks for the email.  You are correct that you would use the "juju upgrade-charm" command to update the contents of your web application.  You would implement the upgrade-charm hook to do what is necessary to update your web application.<br>
<br>There
 is an excellent example of an existing charm written by Robert Ayres that you can 
look at here: 
<a href="https://manage.jujucharms.com/~robert-ayres/precise/j2ee-deployer">https://manage.jujucharms.com/~robert-ayres/precise/j2ee-deployer</a><br><br>If you have charm tools installed you can download this example to your computer:<br>
juju charm get cs:~robert-ayres/precise/j2ee-deployer<br><br></div>The README file details how you can use the j2ee-deployer charm to deploy webapps and update them as necessary.  This would be a great model to use for your own charm.<br>
<br></div>Let me know if you need any more help on this!<br><br clear="all"><div class="gmail_extra"><div><div dir="ltr">   - Matt Bruzek <<a href="mailto:matthew.bruzek@canonical.com" target="_blank">matthew.bruzek@canonical.com</a>><br>
</div></div>
<br><br><div class="gmail_quote">On Tue, Jul 1, 2014 at 9:47 PM, Denis Weerasiri <span dir="ltr"><<a href="mailto:ddweerasiri@gmail.com" target="_blank">ddweerasiri@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">Hi, <div>I mentioned the command as "charm-update". But it should have been "upgrade-charm"</div><div><a href="https://juju.ubuntu.com/docs/authors-charm-upgrades.html" target="_blank">https://juju.ubuntu.com/docs/authors-charm-upgrades.html</a><br>


</div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Jul 2, 2014 at 12:44 PM, Denis Weerasiri <span dir="ltr"><<a href="mailto:ddweerasiri@gmail.com" target="_blank">ddweerasiri@gmail.com</a>></span> wrote:<br>


<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi,<div>Support I have written a charm to deploy a web application on top of tomcat. And now I need to redeploy the web application when I update the source repository of the web application. What is the best practice to do this?</div>



<div>What I have in mind is to write a new version of charm and use charm-update command. So juju will re-deploy the web application.<span><font color="#888888"><br clear="all"><div><br></div>-- <br><div dir="ltr">

Thanks,<br>Denis Weerasiri<div><br>
</div><div>Sent from my iPhone</div></div>
</font></span></div></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr">Thanks,<br>Denis Weerasiri<div><br></div><div>Sent from my iPhone</div></div>
</div>
</div></div><br>--<br>
Juju mailing list<br>
<a href="mailto:Juju@lists.ubuntu.com">Juju@lists.ubuntu.com</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/juju" target="_blank">https://lists.ubuntu.com/mailman/listinfo/juju</a><br>
<br></blockquote></div><br></div></div>