<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Thu, Dec 1, 2016 at 6:53 AM, Marco Ceppi <span dir="ltr"><<a href="mailto:marco.ceppi@canonical.com" target="_blank">marco.ceppi@canonical.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_quote"><span class="gmail-"><div dir="ltr">On Thu, Dec 1, 2016 at 5:00 AM Adam Collard <<a href="mailto:adam.collard@canonical.com" target="_blank">adam.collard@canonical.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr" class="gmail-m_-4435182454390462090gmail_msg"><div class="gmail_quote gmail-m_-4435182454390462090gmail_msg"><div dir="ltr" class="gmail-m_-4435182454390462090gmail_msg">On Thu, 1 Dec 2016 at 04:02 Nate Finch <<a href="mailto:nate.finch@canonical.com" class="gmail-m_-4435182454390462090gmail_msg" target="_blank">nate.finch@canonical.com</a>> wrote:<br class="gmail-m_-4435182454390462090gmail_msg"></div><blockquote class="gmail_quote gmail-m_-4435182454390462090gmail_msg" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr" class="gmail-m_-4435182454390462090gmail_msg">On IRC, someone was lamenting the fact that the Ubuntu charm takes longer to deploy now, because it has been updated to exercise more of Juju's features.  My response was - just make a minimal charm, it's easy.  And then of course, I had to figure out how minimal you can get.  Here it is:<div class="gmail-m_-4435182454390462090gmail_msg"><br class="gmail-m_-4435182454390462090gmail_msg"></div><div class="gmail-m_-4435182454390462090gmail_msg">It's just a directory with a metadata.yaml in it with these contents:<div class="gmail-m_-4435182454390462090gmail_msg"><br class="gmail-m_-4435182454390462090gmail_msg"></div><div class="gmail-m_-4435182454390462090gmail_msg"><div class="gmail-m_-4435182454390462090gmail_msg"><font class="gmail-m_-4435182454390462090gmail_msg" face="monospace">name: min</font></div><div class="gmail-m_-4435182454390462090gmail_msg"><font class="gmail-m_-4435182454390462090gmail_msg" face="monospace">summary: nope</font></div><div class="gmail-m_-4435182454390462090gmail_msg"><font class="gmail-m_-4435182454390462090gmail_msg" face="monospace">description: nope</font></div><div class="gmail-m_-4435182454390462090gmail_msg"><font class="gmail-m_-4435182454390462090gmail_msg" face="monospace">series:</font></div><div class="gmail-m_-4435182454390462090gmail_msg"><font class="gmail-m_-4435182454390462090gmail_msg" face="monospace">  - xenial</font></div></div><div class="gmail-m_-4435182454390462090gmail_msg"><font class="gmail-m_-4435182454390462090gmail_msg" face="monospace"><br class="gmail-m_-4435182454390462090gmail_msg"></font></div><div class="gmail-m_-4435182454390462090gmail_msg"><span style="line-height:18px" class="gmail-m_-4435182454390462090gmail_msg">(obviously you can set the series to whatever you want)</span></div><div class="gmail-m_-4435182454390462090gmail_msg"><span style="line-height:18px" class="gmail-m_-4435182454390462090gmail_msg">No other files or directories are needed.</span></div></div></div></blockquote></div></div><div dir="ltr" class="gmail-m_-4435182454390462090gmail_msg"><div class="gmail_quote gmail-m_-4435182454390462090gmail_msg"><div class="gmail-m_-4435182454390462090gmail_msg"><br class="gmail-m_-4435182454390462090gmail_msg">This is neat, but doesn't detract from the bloat in the ubuntu charm.<br class="gmail-m_-4435182454390462090gmail_msg"></div></div></div></blockquote><div><br></div></span><div>I'm happy to work though changes to the Ubuntu charm to decrease "bloat".</div><span class="gmail-"><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr" class="gmail-m_-4435182454390462090gmail_msg"><div class="gmail_quote gmail-m_-4435182454390462090gmail_msg"><div class="gmail-m_-4435182454390462090gmail_msg">IMHO
 the bloat in the ubuntu charm isn't from support for Juju features, but
 the switch to reactive plus conflicts in layer-base wanting to a) 
support lots of toolchains to allow layers above it to be slimmer and b)
 be a suitable base for "just deploy me" ubuntu.</div></div></div></blockquote><div><br></div></span><div>But it is to support the reactive framework, where we utilize newer Juju features, like status and application-version to make the charm rich despite it's minimal goal set. Honestly, a handful of cached wheelhouses and some apt packages don't strike me as bloat, but I do want to make sure the Ubuntu charm works for those using it. So,</div></div></div></blockquote><div><br></div><div>I think a minimal wheelhouse to provide a consistent charm hook runtime is very reasonable and definitely not the problem here.</div><div><br></div><div>There are too many packages that get installed by default with the reactive framework that most charms don't need. When I deploy the ubuntu charm (but this applies to any charm built with reactive and layer:basic), I also get:</div><div><br></div><div>2016-12-01 17:45:47 INFO install The following NEW packages will be installed:</div><div>2016-12-01 17:45:47 INFO install   binutils build-essential cpp cpp-5 dpkg-dev fakeroot g++ g++-5 gc</div><div>c gcc-5</div><div>2016-12-01 17:45:47 INFO install   libalgorithm-diff-perl libalgorithm-diff-xs-perl libalgorithm-mer</div><div>ge-perl</div><div>2016-12-01 17:45:47 INFO install   libasan2 libatomic1 libc-dev-bin libc6-dev libcc1-0 libcilkrts5 l</div><div>ibdpkg-perl</div><div>2016-12-01 17:45:47 INFO install   libexpat1-dev libfakeroot libfile-fcntllock-perl libgcc-5-dev libgomp1</div><div>2016-12-01 17:45:47 INFO install   libisl15 libitm1 liblsan0 libmpc3 libmpx0 libpython3-dev libpython3.5-dev</div><div>2016-12-01 17:45:47 INFO install   libquadmath0 libstdc++-5-dev libtsan0 libubsan0 linux-libc-dev make</div><div>2016-12-01 17:45:47 INFO install   manpages-dev python-pip-whl python3-dev python3-pip python3-setuptools</div><div>2016-12-01 17:45:47 INFO install   python3-wheel python3.5-dev</div><div><br></div><div>None of my charms need build-essential or a g++ compiler, that's a lot of unnecessary dependencies! Can we get rid of most of these? Would installing the bare minimum with --no-install-recommends help?<br></div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_quote"><div><br></div><div>What's the real problem with the Ubuntu charm today?</div><div>How does it not achieve it's goal of providing a relatively blank Ubuntu machine? What are people using the Ubuntu charm for?</div><div><br></div><div>Other than demos, hacks/workarounds, and testing I'm not clear on the purpose of an Ubuntu charm in a model serves.</div><span class="gmail-HOEnZb"><font color="#888888"><div><br></div><div>Marco</div></font></span></div></div>
<br>--<br>
Juju-dev mailing list<br>
<a href="mailto:Juju-dev@lists.ubuntu.com">Juju-dev@lists.ubuntu.com</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/juju-dev" rel="noreferrer" target="_blank">https://lists.ubuntu.com/<wbr>mailman/listinfo/juju-dev</a><br>
<br></blockquote></div><br></div></div>