[libvirt] [PATCH 0/4] docs: Use CDNJS, update JavaScript libraries

Daniel P. Berrangé berrange at redhat.com
Tue Jun 18 09:39:40 UTC 2019


On Tue, Jun 18, 2019 at 11:19:20AM +0200, Andrea Bolognani wrote:
> On Tue, 2019-06-18 at 09:48 +0100, Daniel P. Berrangé wrote:
> > On Tue, Jun 18, 2019 at 10:12:39AM +0200, Andrea Bolognani wrote:
> > > We're carrying around embedded copies of a few JavaScript libraries
> > > for use in our homepage, and we've been unforgivably bad at keeping
> > > them up to date.
> > > 
> > > Instead of serving JavaScript from libvirt.org, use CDNJS so that
> > > users will get better performance and the load on our Web server
> > > will decrease (win-win!); at the same time, move from the positively
> > > ancient versions we're currently using to the freshest ones
> > > available.
> > 
> > I'm in favour of updating the code of course, but I'd like to keep it
> > self-contained on our own site, certainly not support cloudflare.
> 
> Why? CDNJS is a completely open source project that just so happens
> to be hosted on, and sponsored by, CloudFlare.

I don't see us having any real problem with self-hosting the content
we have done since this was first added. There's not much of it, our
site is not a high traffic site, and we've got many much larger files
hosted.

> Including minimized JavaScript files in release archives as we're
> doing right now is also pretty sketchy, since it's basically the same
> as shipping pre-built binaries instead of the corresponding sources.
> Debian has a fairly strict policy against it, which is how I came to
> realized it was an issue in the first place, but I'd be surprised if
> other distributions were happy with the situation.

I'm fine if we put non-minimized JS in GIT & (optionally) minimize  it
during build.

> We're only using JavaScript for the fancy blog roll on the homepage
> and global search drop-down menu anyway, both of which are only
> relevant to libvirt.org and should be scrapped when installing
> documentation on the end user's machine. I'm working on a follow-up
> series that does just that.

Is there really a benefit to disabling it locally ?  IMHO it is fine to
have it locally, not least as it lets people changing the website see
it in the same way it will look when published live.

Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|




More information about the libvir-list mailing list